1 | <?php |
---|
2 | |
---|
3 | /***************************************************************************\ |
---|
4 | * Expresso - Expresso Messenger * |
---|
5 | * - Alexandre Correia / Rodrigo Souza * |
---|
6 | * ------------------------------------------------------------------------- * |
---|
7 | * This program is free software; you can redistribute it and/or modify it * |
---|
8 | * under the terms of the GNU General Public License as published by the * |
---|
9 | * Free Software Foundation; either version 2 of the License, or (at your * |
---|
10 | * option) any later version. * |
---|
11 | \***************************************************************************/ |
---|
12 | |
---|
13 | class uiconfig |
---|
14 | { |
---|
15 | private $uimodule; |
---|
16 | |
---|
17 | public $public_functions = array( |
---|
18 | 'configAudit' => True, |
---|
19 | 'configPermission' => True, |
---|
20 | 'configServer' => True, |
---|
21 | 'css' => True |
---|
22 | ); |
---|
23 | |
---|
24 | function __construct() |
---|
25 | { |
---|
26 | //$GLOBALS['phpgw']->common->phpgw_header(); |
---|
27 | } |
---|
28 | |
---|
29 | public final function configPermission() |
---|
30 | { |
---|
31 | if( !$GLOBALS['phpgw']->acl->check('run',1,'admin') ) |
---|
32 | { |
---|
33 | $GLOBALS['phpgw']->redirect_link('/admin/index.php'); |
---|
34 | } |
---|
35 | |
---|
36 | $GLOBALS['phpgw_info']['flags']['app_header'] = lang('Admin') .' - ' . 'Permissões de Acesso'; |
---|
37 | //echo parse_navbar(); |
---|
38 | |
---|
39 | $GLOBALS['phpgw']->template->set_file(array('jabberit_messenger'=>'configItens.tpl')); |
---|
40 | $GLOBALS['phpgw']->template->set_block('jabberit_messenger','configPermission'); |
---|
41 | $GLOBALS['phpgw']->template->set_var(array( |
---|
42 | 'action_url_back' => "./admin", |
---|
43 | 'label_config1' => lang("Enable the Expresso Messenger inside of the modules"), |
---|
44 | 'label_config2' => "Habilitar adição de novos contatos somente por grupos", |
---|
45 | 'label_config3' => lang("Restrict group"), |
---|
46 | 'label_config4' => lang("Free organization for group"), |
---|
47 | 'value_config1' => $GLOBALS['phpgw']->link('/index.php','menuaction=jabberit_messenger.uimodule.edit_conf'), |
---|
48 | 'value_config2' => $GLOBALS['phpgw']->link('/index.php','menuaction=jabberit_messenger.uigroupsldap.edit'), |
---|
49 | 'value_config3' => $GLOBALS['phpgw']->link('/index.php','menuaction=jabberit_messenger.uigroupslocked.editGroups'), |
---|
50 | 'value_config4' => $GLOBALS['phpgw']->link('/index.php','menuaction=jabberit_messenger.uienabledgroups.getGroups'), |
---|
51 | 'value_image1' => "jabberit_messenger/templates/default/images/app.gif", |
---|
52 | 'value_image2' => "jabberit_messenger/templates/default/images/group.gif", |
---|
53 | 'value_image3' => "jabberit_messenger/templates/default/images/group_deny.gif", |
---|
54 | 'value_image4' => "jabberit_messenger/templates/default/images/group_add.gif" |
---|
55 | )); |
---|
56 | |
---|
57 | $GLOBALS['phpgw']->template->pparse('out','configPermission'); |
---|
58 | |
---|
59 | } |
---|
60 | |
---|
61 | public final function configServer() |
---|
62 | { |
---|
63 | if( !$GLOBALS['phpgw']->acl->check('run',1,'admin') ) |
---|
64 | { |
---|
65 | $GLOBALS['phpgw']->redirect_link('/admin/index.php'); |
---|
66 | } |
---|
67 | |
---|
68 | $GLOBALS['phpgw_info']['flags']['app_header'] = lang('Admin') .' - ' . 'Configurações do Servidor'; |
---|
69 | //echo parse_navbar(); |
---|
70 | |
---|
71 | $GLOBALS['phpgw']->template->set_file(array('jabberit_messenger'=>'configItens.tpl')); |
---|
72 | $GLOBALS['phpgw']->template->set_block('jabberit_messenger','configServer'); |
---|
73 | $GLOBALS['phpgw']->template->set_var(array( |
---|
74 | 'action_url_back' => "./admin", |
---|
75 | 'label_config1' => lang("Site Configuration Jabber"), |
---|
76 | 'label_config2' => lang("Map organization for realm jabber"), |
---|
77 | 'value_config1' => $GLOBALS['phpgw']->link('/index.php','menuaction=admin.uiconfig.index&appname=jabberit_messenger'), |
---|
78 | 'value_config2' => $GLOBALS['phpgw']->link('/index.php','menuaction=jabberit_messenger.uihostsjabber.edit_conf'), |
---|
79 | 'value_image1' => "jabberit_messenger/templates/default/images/navbar.png", |
---|
80 | 'value_image2' => "jabberit_messenger/templates/default/images/gear.png", |
---|
81 | )); |
---|
82 | |
---|
83 | $GLOBALS['phpgw']->template->pparse('out','configServer'); |
---|
84 | |
---|
85 | } |
---|
86 | |
---|
87 | } |
---|
88 | ?> |
---|