[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Fmsystem-commits] [7677]
From: |
Torstein |
Subject: |
[Fmsystem-commits] [7677] |
Date: |
Tue, 20 Sep 2011 10:40:51 +0000 |
Revision: 7677
http://svn.sv.gnu.org/viewvc/?view=rev&root=fmsystem&revision=7677
Author: vator
Date: 2011-09-20 10:40:51 +0000 (Tue, 20 Sep 2011)
Log Message:
-----------
Modified Paths:
--------------
trunk/controller/inc/class.uicontrol.inc.php
Modified: trunk/controller/inc/class.uicontrol.inc.php
===================================================================
--- trunk/controller/inc/class.uicontrol.inc.php 2011-09-20 10:40:32 UTC
(rev 7676)
+++ trunk/controller/inc/class.uicontrol.inc.php 2011-09-20 10:40:51 UTC
(rev 7677)
@@ -28,6 +28,54 @@
public function index()
{
+
//self::set_active_menu('controller::example::normal_tabs');
+
+ $type = phpgw::get_var('type', 'string', 'REQUEST', null);
+
+ switch($type)
+ {
+ case 'default':
+ $selected = 1;
+ $resource_id = 81;
+ break;
+ case 'forced':
+ $selected = 2;
+ $resource_id = 46;
+ break;
+ case 'user':
+ default:
+ $selected = 0;
+ $resource_id = 80;
+ }
+
+ $add_document_link =
$GLOBALS['phpgw']->link('/index.php', array('menuaction'=>
'controller.uiexample.index') );
+ $resource = array('id' => $resource_id,
'add_document_link' => $add_document_link, 'permission' => array('write' =>
true ) );
+
+ $tabs = array
+ (
+ 'details' => array('label' =>
lang('Details'), 'link' => '#details'),
+ 'list' => array('label' =>
lang('list'), 'link' => '#list'),
+ 'dates' => array('label' =>
lang('dates'), 'link' => '#dates'),
+ );
+
+ phpgwapi_yui::tabview_setup('example_tabview');
+
+ $data = array
+ (
+ 'tabs'
=> phpgwapi_yui::tabview_generate($tabs, 'details'),
+ 'resource'
=> $resource,
+ 'date'
=>
$GLOBALS['phpgw']->yuical->add_listener('date',date($GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat'],
time())),
+ 'value_id'
=> !empty($control) ? $control->get_id() : 0,
+ 'img_go_home' =>
'rental/templates/base/images/32x32/actions/go-home.png',
+ 'editable'
=> true,
+ 'procedure_options_array' =>
array('options' => $procedure_options_array)
+ );
+ self::add_javascript('controller', 'yahoo',
'example_normal_tabs.js');
+ self::render_template_xsl('example_normal_tabs', $data);
+ }
+
+ public function edit()
+ {
$GLOBALS['phpgw_info']['flags']['menu_selection'] =
"controller::control";
$repeat_type = $this->bo->get_rpt_type_list();
@@ -70,7 +118,7 @@
foreach ($procedure_array as $procedure)
{
- $procedure_options_array = array
+ $procedure_options_array[] = array
(
'id' => $procedure->get_id(),
'name' => $procedure->get_title()
@@ -78,19 +126,16 @@
);
}
-
-
-
-
$data = array
(
'value_id'
=> !empty($control) ? $control->get_id() : 0,
'img_go_home' =>
'rental/templates/base/images/32x32/actions/go-home.png',
'editable'
=> true,
- 'procedure_options_array' =>
array('options' => $procedure_options_array)
+ 'procedure_options_array' =>
array('options' => $procedure_options_array),
+ 'date' =>
$GLOBALS['phpgw']->yuical->add_listener('date',date($GLOBALS['phpgw_info']['user']['preferences']['common']['dateformat'],
time()))
);
- self::render_template_xsl('control.xsl', $data);
+ self::render_template_xsl('control', $data);
}
public function query()
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Fmsystem-commits] [7677],
Torstein <=