phpgroupware-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Phpgroupware-cvs] api class.account_mgr.php, 1.1.2.7, 1.1.2.8 class.bas


From: Joseph Engo <address@hidden>
Subject: [Phpgroupware-cvs] api class.account_mgr.php, 1.1.2.7, 1.1.2.8 class.base.php, 1.1.1.1.2.6, 1.1.1.1.2.7 class.phpgw.php, 1.1.1.1.2.11, 1.1.1.1.2.12
Date: Tue, 28 Oct 2003 10:13:31 +0000

Update of /cvsroot/phpgroupware/api
In directory subversions:/tmp/cvs-serv15056/api

Modified Files:
      Tag: proposal-branch
        class.account_mgr.php class.base.php class.phpgw.php 
Log Message:
Started working on the preferences interface, its not fully working it 
currently only displays the static values
It doesn't save or read the users preferences yet


Index: class.account_mgr.php
===================================================================
RCS file: /cvsroot/phpgroupware/api/Attic/class.account_mgr.php,v
retrieving revision 1.1.2.7
retrieving revision 1.1.2.8
diff -C2 -d -r1.1.2.7 -r1.1.2.8
*** class.account_mgr.php       28 Oct 2003 05:26:34 -0000      1.1.2.7
--- class.account_mgr.php       28 Oct 2003 10:13:29 -0000      1.1.2.8
***************
*** 20,24 ****
                function api_account_mgr()
                {
!                       if(!$GLOBALS['api_account_mgr_menus_loaded'])
                        {
                                $appmenu[] = array(
--- 20,24 ----
                function api_account_mgr()
                {
!                       if (! $GLOBALS['api_account_mgr_menus_loaded'])
                        {
                                $appmenu[] = array(

Index: class.base.php
===================================================================
RCS file: /cvsroot/phpgroupware/api/class.base.php,v
retrieving revision 1.1.1.1.2.6
retrieving revision 1.1.1.1.2.7
diff -C2 -d -r1.1.1.1.2.6 -r1.1.1.1.2.7
*** class.base.php      28 Oct 2003 08:52:07 -0000      1.1.1.1.2.6
--- class.base.php      28 Oct 2003 10:13:29 -0000      1.1.1.1.2.7
***************
*** 30,33 ****
--- 30,238 ----
        class api_base
        {
+               var $prefs = array(
+                       0 => array(
+                               'type'   => 'selectbox',
+                               'name'   => 'timezone',
+                               'label'  => 'Timezone',
+                               'values' => array(
+                                       0 => array(
+                                               'value'    => '-5',
+                                               'text'     => '-5 Eastern'
+                                       ),
+                               )
+                       ),
+                       1 => array(
+                               'type'        => 'selectbox',
+                               'name'        => 'date_format',
+                               'label'       => 'Date format',
+                               'values' => array(
+                                       0 => array(
+                                               'value'    => 'm/d/Y',
+                                               'text'     => 'm/d/Y'
+                                       ),
+                                       1 => array(
+                                               'value'    => 'Y/m/d',
+                                               'text'     => 'Y/m/d'
+                                       ),
+                               )
+                       ),
+                       2 => array(
+                               'type'        => 'selectbox',
+                               'name'        => 'time_format',
+                               'label'       => 'Time format',
+                               'values' => array(
+                                       0 => array(
+                                               'value'    => '12',
+                                               'text'     => '12 Hour'
+                                       ),
+                                       1 => array(
+                                               'value'    => '24',
+                                               'text'     => '24 Hour'
+                                       ),
+                               )
+                       ),
+                       3 => array(
+                               'type'        => 'inputbox',
+                               'name'        => 'nextmatchs',
+                               'label'       => 'Number of records per page',
+                               'value'       => '15'
+                       ),
+                       4 => array(
+                               'type'        => 'selectbox',
+                               'name'        => 'language',
+                               'label'       => 'Language',
+                               'values' => array(
+                                       0 => array(
+                                               'value'    => 'ar',
+                                               'text'     => 'Arabic'
+                                       ),
+                                       1 => array(
+                                               'value'    => 'bg',
+                                               'text'     => 'Bulgarian'
+                                       ),
+                                       2 => array(
+                                               'value'    => 'ca',
+                                               'text'     => 'Catalan'
+                                       ),
+                                       3 => array(
+                                               'value'    => 'zh-CN',
+                                               'text'     => 'Chinese 
(Simplified)'
+                                       ),
+                                       4 => array(
+                                               'value'    => 'zh-TW',
+                                               'text'     => 'Chinese 
(Traditional)'
+                                       ),
+                                       5 => array(
+                                               'value'    => 'hr',
+                                               'text'     => 'Croatian'
+                                       ),
+                                       6 => array(
+                                               'value'    => 'cs',
+                                               'text'     => 'Czech'
+                                       ),
+                                       7 => array(
+                                               'value'    => 'da',
+                                               'text'     => 'Danish'
+                                       ),
+                                       8 => array(
+                                               'value'    => 'nl',
+                                               'text'     => 'Dutch'
+                                       ),
+                                       9 => array(
+                                               'value'    => 'en',
+                                               'text'     => 'English'
+                                       ),
+                                       10 => array(
+                                               'value'    => 'et',
+                                               'text'     => 'Estonian'
+                                       ),
+                                       11 => array(
+                                               'value'    => 'fi',
+                                               'text'     => 'Finnish'
+                                       ),
+                                       12 => array(
+                                               'value'    => 'fr',
+                                               'text'     => 'French'
+                                       ),
+                                       13 => array(
+                                               'value'    => 'de',
+                                               'text'     => 'German'
+                                       ),
+                                       14 => array(
+                                               'value'    => 'el',
+                                               'text'     => 'Greek'
+                                       ),
+                                       15 => array(
+                                               'value'    => 'iw',
+                                               'text'     => 'Hebrew'
+                                       ),
+                                       16 => array(
+                                               'value'    => 'hu',
+                                               'text'     => 'Hungarian'
+                                       ),
+                                       17 => array(
+                                               'value'    => 'is',
+                                               'text'     => 'Icelandic'
+                                       ),
+                                       18 => array(
+                                               'value'    => 'it',
+                                               'text'     => 'Italian'
+                                       ),
+                                       19 => array(
+                                               'value'    => 'ja',
+                                               'text'     => 'Japanese'
+                                       ),
+                                       20 => array(
+                                               'value'    => 'ko',
+                                               'text'     => 'Korean'
+                                       ),
+                                       21 => array(
+                                               'value'    => 'lv',
+                                               'text'     => 'Latvian'
+                                       ),
+                                       22 => array(
+                                               'value'    => 'lt',
+                                               'text'     => 'Lithuanian'
+                                       ),
+                                       23 => array(
+                                               'value'    => 'no',
+                                               'text'     => 'Norwegian'
+                                       ),
+                                       24 => array(
+                                               'value'    => 'pl',
+                                               'text'     => 'Polish'
+                                       ),
+                                       25 => array(
+                                               'value'    => 'pt',
+                                               'text'     => 'Portuguese'
+                                       ),
+                                       26 => array(
+                                               'value'    => 'ro',
+                                               'text'     => 'Romanian'
+                                       ),
+                                       27 => array(
+                                               'value'    => 'is',
+                                               'text'     => 'Icelandic'
+                                       ),
+                                       28 => array(
+                                               'value'    => 'pt',
+                                               'text'     => 'Portuguese'
+                                       ),
+                                       29 => array(
+                                               'value'    => 'ro',
+                                               'text'     => 'Romanian'
+                                       ),
+                                       30 => array(
+                                               'value'    => 'ru',
+                                               'text'     => 'Russian'
+                                       ),
+                                       31 => array(
+                                               'value'    => 'sr',
+                                               'text'     => 'Serbian'
+                                       ),
+                                       32 => array(
+                                               'value'    => 'sk',
+                                               'text'     => 'Slovak'
+                                       ),
+                                       34 => array(
+                                               'value'    => 'sl',
+                                               'text'     => 'Slovenian'
+                                       ),
+                                       35 => array(
+                                               'value'    => 'es',
+                                               'text'     => 'Spanish'
+                                       ),
+                                       36 => array(
+                                               'value'    => 'sv',
+                                               'text'     => 'Swedish'
+                                       ),
+                                       37 => array(
+                                               'value'    => 'tr',
+                                               'text'     => 'Turksih'
+                                       )
+                               )
+                       )
+               );
+ 
                /*!
                @function start
***************
*** 71,74 ****
                        
$GLOBALS['phpgw_xml_apinode']->add_node('About','title');
                        return array('blah');
!               }               
        }
--- 276,315 ----
                        
$GLOBALS['phpgw_xml_apinode']->add_node('About','title');
                        return array('blah');
!               }
! 
!               function prefs()
!               {
!                       $args = new safe_args();
!                       $args->set('appname','##REQUIRD##','string');
!                       $args->set('form_submit','##NOTSET##','any');
!                       $args = $args->get(func_get_args(),__LINE__,__FILE__);
! 
!                       $GLOBALS['phpgw']->add_xsl('api.widgets');
!                       
$GLOBALS['phpgw_xml_apinode']->add_node('Preferences','title');
! 
!                       if ($args['appname'] == 'api')
!                       {
!                               $obj = CreateObject('api_base');
!                       }
!                       else
!                       {
!                               $obj = CreateObject($args['appname'] . '_base');
!                       }
! 
!                       if (! is_array($obj->prefs) && ! count($obj->prefs))
!                       {
!                               $GLOBALS['msgbox']->add(lang('Preferences not 
available or missing for this application'),__LINE__,__FILE__, 'warning');
!                               return array();
!                       }
! 
!                       if ($args['form_submit'])
!                       {
!                               $GLOBALS['msgbox']->add(lang('Preferences have 
been saved'),__LINE__,__FILE__, 'notice');
!                       }       
!                       $result['pref_widget'] = $obj->prefs;
! 
!                       return $result;
!               }
        }
+ 
+ 

Index: class.phpgw.php
===================================================================
RCS file: /cvsroot/phpgroupware/api/class.phpgw.php,v
retrieving revision 1.1.1.1.2.11
retrieving revision 1.1.1.1.2.12
diff -C2 -d -r1.1.1.1.2.11 -r1.1.1.1.2.12
*** class.phpgw.php     28 Oct 2003 08:52:07 -0000      1.1.1.1.2.11
--- class.phpgw.php     28 Oct 2003 10:13:29 -0000      1.1.1.1.2.12
***************
*** 201,206 ****
                        {
                                $menu[] = array(
!                                       'title' => lang('Preferences', 
'##NOTSET##', 'api'),
!                                       'op'    => 'api.base.prefs',
                                );
                        }
--- 201,206 ----
                        {
                                $menu[] = array(
!                                       'title'     => lang('Preferences', 
'##NOTSET##', 'api'),
!                                       'op'        => 
'api.base.prefs&appname=api'
                                );
                        }





reply via email to

[Prev in Thread] Current Thread [Next in Thread]