|
21 | 21 | * @author Txmod Xoops <support@txmodxoops.org> |
22 | 22 | * |
23 | 23 | */ |
24 | | -$GLOBALS['xoopsOption']['template_main'] = 'tdmcreate_settings.tpl'; |
| 24 | + |
| 25 | +// Define main template |
| 26 | +$templateMain = 'tdmcreate_settings.tpl'; |
25 | 27 |
|
26 | 28 | include __DIR__ . '/header.php'; |
27 | 29 |
|
28 | 30 | // Recovered value of argument op in the URL $ |
29 | | -$op = \Xmf\Request::getString('op', 'list'); |
30 | | - |
| 31 | +$op = \Xmf\Request::getString('op', 'list'); |
31 | 32 | $setId = \Xmf\Request::getInt('set_id'); |
32 | 33 |
|
33 | 34 | switch ($op) { |
34 | 35 | case 'list': |
35 | 36 | default: |
36 | 37 | $start = \Xmf\Request::getInt('start', 0); |
37 | 38 | $limit = \Xmf\Request::getInt('limit', $helper->getConfig('settings_adminpager')); |
38 | | - // Define main template |
39 | | - // $templateMain = 'tdmcreate_settings.tpl'; |
40 | 39 | $GLOBALS['xoTheme']->addScript('modules/tdmcreate/assets/js/functions.js'); |
41 | 40 | $GLOBALS['xoTheme']->addStylesheet('modules/tdmcreate/assets/css/admin/style.css'); |
42 | 41 | $GLOBALS['xoopsTpl']->assign('navigation', $adminObject->displayNavigation('settings.php')); |
|
65 | 64 | } |
66 | 65 | break; |
67 | 66 | case 'new': |
68 | | - // Define main template |
69 | | - // $templateMain = 'tdmcreate_settings.tpl'; |
70 | 67 | $GLOBALS['xoTheme']->addScript('modules/tdmcreate/assets/js/functions.js'); |
71 | 68 | $GLOBALS['xoopsTpl']->assign('navigation', $adminObject->displayNavigation('settings.php')); |
72 | 69 | $adminObject->addItemButton(_AM_TDMCREATE_SETTINGS_LIST, 'settings.php', 'list'); |
|
135 | 132 | $settingsObj->setVar('set_comments', in_array('comments', $settingOption)); |
136 | 133 | $settingsObj->setVar('set_notifications', in_array('notifications', $settingOption)); |
137 | 134 | $settingsObj->setVar('set_permissions', in_array('permissions', $settingOption)); |
138 | | - $settingsObj->setVar('set_inroot_copy', in_array('inroot', $settingOption)); |
| 135 | + //$settingsObj->setVar('set_inroot_copy', in_array('inroot', $settingOption)); |
139 | 136 | if (\Xmf\Request::hasVar('set_type')) { |
140 | 137 | $settingsObj->setVar('set_type', \Xmf\Request::getString('set_type', '', 'POST')); |
141 | 138 | } |
|
149 | 146 | $GLOBALS['xoopsTpl']->assign('form', $form->render()); |
150 | 147 | break; |
151 | 148 | case 'edit': |
152 | | - // Define main template |
153 | | - // $templateMain = 'tdmcreate_settings.tpl'; |
154 | 149 | $GLOBALS['xoopsTpl']->assign('navigation', $adminObject->displayNavigation('settings.php')); |
155 | 150 | $adminObject->addItemButton(_AM_TDMCREATE_ADD_SETTING, 'settings.php?op=new', 'add'); |
156 | 151 | $adminObject->addItemButton(_AM_TDMCREATE_SETTINGS_LIST, 'settings.php', 'list'); |
|
0 commit comments