PageRenderTime 53ms CodeModel.GetById 25ms RepoModel.GetById 1ms app.codeStats 0ms

/gui/templates_c/%%1D^1D0^1D061265%%rolesEdit.tpl.php

https://bitbucket.org/pfernandez/testlink1.9.6
PHP | 304 lines | 280 code | 24 blank | 0 comment | 36 complexity | dd998aa05d4a631d3a385ab2ca4eca35 MD5 | raw file
Possible License(s): GPL-2.0, LGPL-2.1, GPL-3.0
  1. <?php /* Smarty version 2.6.26, created on 2010-09-28 15:27:59
  2. compiled from usermanagement/rolesEdit.tpl */ ?>
  3. <?php require_once(SMARTY_CORE_DIR . 'core.load_plugins.php');
  4. smarty_core_load_plugins(array('plugins' => array(array('function', 'lang_get', 'usermanagement/rolesEdit.tpl', 28, false),array('function', 'config_load', 'usermanagement/rolesEdit.tpl', 65, false),array('modifier', 'basename', 'usermanagement/rolesEdit.tpl', 64, false),array('modifier', 'replace', 'usermanagement/rolesEdit.tpl', 64, false),array('modifier', 'escape', 'usermanagement/rolesEdit.tpl', 98, false),)), $this); ?>
  5. <?php $_smarty_tpl_vars = $this->_tpl_vars;
  6. $this->_smarty_include(array('smarty_include_tpl_file' => "inc_head.tpl", 'smarty_include_vars' => array('openHead' => 'yes','jsValidate' => 'yes','editorType' => $this->_tpl_vars['gui']->editorType)));
  7. $this->_tpl_vars = $_smarty_tpl_vars;
  8. unset($_smarty_tpl_vars);
  9. ?>
  10. <?php $_smarty_tpl_vars = $this->_tpl_vars;
  11. $this->_smarty_include(array('smarty_include_tpl_file' => "inc_del_onclick.tpl", 'smarty_include_vars' => array()));
  12. $this->_tpl_vars = $_smarty_tpl_vars;
  13. unset($_smarty_tpl_vars);
  14. ?>
  15. <?php $_smarty_tpl_vars = $this->_tpl_vars;
  16. $this->_smarty_include(array('smarty_include_tpl_file' => "inc_jsCheckboxes.tpl", 'smarty_include_vars' => array()));
  17. $this->_tpl_vars = $_smarty_tpl_vars;
  18. unset($_smarty_tpl_vars);
  19. ?>
  20. <?php echo '
  21. <script type="text/javascript">
  22. '; ?>
  23. <?php echo lang_get_smarty(array('var' => 'labels','s' => 'btn_save,warning,warning_modify_role,warning_empty_role_name,th_rights,
  24. error_role_no_rights,caption_possible_affected_users,enter_role_notes,
  25. title_user_mgmt,caption_define_role,th_mgttc_rights,th_req_rights,
  26. th_product_rights,th_user_rights,th_kw_rights,th_cf_rights,th_system_rights,
  27. th_platform_rights,
  28. th_rolename,th_tp_rights,btn_cancel'), $this);?>
  29. var alert_box_title = "<?php echo $this->_tpl_vars['labels']['warning']; ?>
  30. ";
  31. var warning_modify_role = "<?php echo $this->_tpl_vars['labels']['warning_modify_role']; ?>
  32. ";
  33. var warning_empty_role_name = "<?php echo $this->_tpl_vars['labels']['warning_empty_role_name']; ?>
  34. ";
  35. var warning_error_role_no_rights = "<?php echo $this->_tpl_vars['labels']['error_role_no_rights']; ?>
  36. ";
  37. <?php echo '
  38. function validateForm(f)
  39. {
  40. if (isWhitespace(f.rolename.value))
  41. {
  42. alert_message(alert_box_title,warning_empty_role_name);
  43. selectField(f, \'rolename\');
  44. return false;
  45. }
  46. if( checkbox_count_checked(f.id) == 0)
  47. {
  48. alert_message(alert_box_title,warning_error_role_no_rights);
  49. return false;
  50. }
  51. return true;
  52. }
  53. </script>
  54. '; ?>
  55. </head>
  56. <body>
  57. <?php $this->assign('cfg_section', ((is_array($_tmp=((is_array($_tmp='usermanagement/rolesEdit.tpl')) ? $this->_run_mod_handler('basename', true, $_tmp) : basename($_tmp)))) ? $this->_run_mod_handler('replace', true, $_tmp, ".tpl", "") : smarty_modifier_replace($_tmp, ".tpl", ""))); ?>
  58. <?php echo smarty_function_config_load(array('file' => "input_dimensions.conf",'section' => $this->_tpl_vars['cfg_section']), $this);?>
  59. <h1 class="title"><?php echo $this->_tpl_vars['labels']['title_user_mgmt']; ?>
  60. - <?php echo $this->_tpl_vars['labels']['caption_define_role']; ?>
  61. </h1>
  62. <?php $_smarty_tpl_vars = $this->_tpl_vars;
  63. $this->_smarty_include(array('smarty_include_tpl_file' => "usermanagement/tabsmenu.tpl", 'smarty_include_vars' => array('grants' => $this->_tpl_vars['gui']->grants,'highlight' => $this->_tpl_vars['gui']->highlight)));
  64. $this->_tpl_vars = $_smarty_tpl_vars;
  65. unset($_smarty_tpl_vars);
  66. ?>
  67. <?php $_smarty_tpl_vars = $this->_tpl_vars;
  68. $this->_smarty_include(array('smarty_include_tpl_file' => "inc_update.tpl", 'smarty_include_vars' => array('user_feedback' => $this->_tpl_vars['gui']->userFeedback)));
  69. $this->_tpl_vars = $_smarty_tpl_vars;
  70. unset($_smarty_tpl_vars);
  71. ?>
  72. <div class="workBack">
  73. <form name="rolesedit" id="rolesedit"
  74. method="post" action="lib/usermanagement/rolesEdit.php"
  75. <?php if ($this->_tpl_vars['tlCfg']->demoMode): ?>
  76. onsubmit="alert('<?php echo lang_get_smarty(array('s' => 'warn_demo'), $this);?>
  77. '); return false;">
  78. <?php else: ?>
  79. <?php if ($this->_tpl_vars['gui']->grants->role_mgmt == 'yes'): ?>
  80. onSubmit="javascript:return validateForm(this);"
  81. <?php else: ?>
  82. onsubmit="return false"
  83. <?php endif; ?>
  84. <?php endif; ?>
  85. >
  86. <input type="hidden" name="roleid" value="<?php echo $this->_tpl_vars['gui']->role->dbID; ?>
  87. " />
  88. <table class="common">
  89. <tr><th><?php echo $this->_tpl_vars['labels']['th_rolename']; ?>
  90. <?php if ($this->_tpl_vars['gui']->mgt_view_events == 'yes' && $this->_tpl_vars['gui']->role->dbID): ?>
  91. <img style="margin-left:5px;" class="clickable" src="<?php echo @TL_THEME_IMG_DIR; ?>
  92. /question.gif" onclick="showEventHistoryFor('<?php echo $this->_tpl_vars['gui']->role->dbID; ?>
  93. ','roles')" alt="<?php echo lang_get_smarty(array('s' => 'show_event_history'), $this);?>
  94. " title="<?php echo lang_get_smarty(array('s' => 'show_event_history'), $this);?>
  95. "/>
  96. <?php endif; ?>
  97. </th></tr>
  98. <tr><td>
  99. <input type="text" name="rolename"
  100. size="<?php echo $this->_config[0]['vars']['ROLENAME_SIZE']; ?>
  101. " maxlength="<?php echo $this->_config[0]['vars']['ROLENAME_MAXLEN']; ?>
  102. " value="<?php echo ((is_array($_tmp=$this->_tpl_vars['gui']->role->name)) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
  103. "/>
  104. <?php $_smarty_tpl_vars = $this->_tpl_vars;
  105. $this->_smarty_include(array('smarty_include_tpl_file' => "error_icon.tpl", 'smarty_include_vars' => array('field' => 'rolename')));
  106. $this->_tpl_vars = $_smarty_tpl_vars;
  107. unset($_smarty_tpl_vars);
  108. ?>
  109. </td></tr>
  110. <tr><th><?php echo $this->_tpl_vars['labels']['th_rights']; ?>
  111. </th></tr>
  112. <tr>
  113. <td>
  114. <table>
  115. <tr>
  116. <td><fieldset class="x-fieldset x-form-label-left"><legend ><?php echo $this->_tpl_vars['labels']['th_tp_rights']; ?>
  117. </legend>
  118. <?php $_from = $this->_tpl_vars['gui']->rightsCfg->tplan_mgmt; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  119. foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['id']):
  120. ?>
  121. <input class="tl-input" type="checkbox" name="grant[<?php echo $this->_tpl_vars['k']; ?>
  122. ]" <?php echo $this->_tpl_vars['gui']->checkboxStatus[$this->_tpl_vars['k']]; ?>
  123. /><?php echo $this->_tpl_vars['id']; ?>
  124. <br />
  125. <?php endforeach; endif; unset($_from); ?>
  126. </fieldset>
  127. </td>
  128. <td>
  129. <fieldset class="x-fieldset x-form-label-left"><legend ><?php echo $this->_tpl_vars['labels']['th_mgttc_rights']; ?>
  130. </legend>
  131. <?php $_from = $this->_tpl_vars['gui']->rightsCfg->tcase_mgmt; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  132. foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['id']):
  133. ?>
  134. <input class="tl-input" type="checkbox" name="grant[<?php echo $this->_tpl_vars['k']; ?>
  135. ]" <?php echo $this->_tpl_vars['gui']->checkboxStatus[$this->_tpl_vars['k']]; ?>
  136. /><?php echo $this->_tpl_vars['id']; ?>
  137. <br />
  138. <?php endforeach; endif; unset($_from); ?>
  139. </fieldset>
  140. </td>
  141. <td>
  142. <fieldset class="x-fieldset x-form-label-left"><legend ><?php echo $this->_tpl_vars['labels']['th_req_rights']; ?>
  143. </legend>
  144. <?php $_from = $this->_tpl_vars['gui']->rightsCfg->req_mgmt; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  145. foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['id']):
  146. ?>
  147. <input class="tl-input" type="checkbox" name="grant[<?php echo $this->_tpl_vars['k']; ?>
  148. ]" <?php echo $this->_tpl_vars['gui']->checkboxStatus[$this->_tpl_vars['k']]; ?>
  149. /><?php echo $this->_tpl_vars['id']; ?>
  150. <br />
  151. <?php endforeach; endif; unset($_from); ?>
  152. </fieldset>
  153. </td>
  154. <td>
  155. <fieldset class="x-fieldset x-form-label-left"><legend ><?php echo $this->_tpl_vars['labels']['th_product_rights']; ?>
  156. </legend>
  157. <?php $_from = $this->_tpl_vars['gui']->rightsCfg->tproject_mgmt; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  158. foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['id']):
  159. ?>
  160. <input class="tl-input" type="checkbox" name="grant[<?php echo $this->_tpl_vars['k']; ?>
  161. ]" <?php echo $this->_tpl_vars['gui']->checkboxStatus[$this->_tpl_vars['k']]; ?>
  162. /><?php echo $this->_tpl_vars['id']; ?>
  163. <br />
  164. <?php endforeach; endif; unset($_from); ?>
  165. </fieldset>
  166. </td>
  167. </tr>
  168. <tr>
  169. <td><fieldset class="x-fieldset x-form-label-left"><legend ><?php echo $this->_tpl_vars['labels']['th_user_rights']; ?>
  170. </legend>
  171. <?php $_from = $this->_tpl_vars['gui']->rightsCfg->user_mgmt; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  172. foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['id']):
  173. ?>
  174. <input class="tl-input" type="checkbox" name="grant[<?php echo $this->_tpl_vars['k']; ?>
  175. ]" <?php echo $this->_tpl_vars['gui']->checkboxStatus[$this->_tpl_vars['k']]; ?>
  176. /><?php echo $this->_tpl_vars['id']; ?>
  177. <br />
  178. <?php endforeach; endif; unset($_from); ?>
  179. </fieldset>
  180. </td>
  181. <td><fieldset class="x-fieldset x-form-label-left"><legend ><?php echo $this->_tpl_vars['labels']['th_kw_rights']; ?>
  182. </legend>
  183. <?php $_from = $this->_tpl_vars['gui']->rightsCfg->kword_mgmt; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  184. foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['id']):
  185. ?>
  186. <input class="tl-input" type="checkbox" name="grant[<?php echo $this->_tpl_vars['k']; ?>
  187. ]" <?php echo $this->_tpl_vars['gui']->checkboxStatus[$this->_tpl_vars['k']]; ?>
  188. /><?php echo $this->_tpl_vars['id']; ?>
  189. <br />
  190. <?php endforeach; endif; unset($_from); ?>
  191. </fieldset>
  192. </td>
  193. <td><fieldset class="x-fieldset x-form-label-left"><legend ><?php echo $this->_tpl_vars['labels']['th_cf_rights']; ?>
  194. </legend>
  195. <?php $_from = $this->_tpl_vars['gui']->rightsCfg->cfield_mgmt; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  196. foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['id']):
  197. ?>
  198. <input class="tl-input" type="checkbox" name="grant[<?php echo $this->_tpl_vars['k']; ?>
  199. ]" <?php echo $this->_tpl_vars['gui']->checkboxStatus[$this->_tpl_vars['k']]; ?>
  200. /><?php echo $this->_tpl_vars['id']; ?>
  201. <br />
  202. <?php endforeach; endif; unset($_from); ?>
  203. </fieldset>
  204. </td>
  205. <td><fieldset class="x-fieldset x-form-label-left"><legend ><?php echo $this->_tpl_vars['labels']['th_system_rights']; ?>
  206. </legend>
  207. <?php $_from = $this->_tpl_vars['gui']->rightsCfg->system_mgmt; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  208. foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['id']):
  209. ?>
  210. <input class="tl-input" type="checkbox" name="grant[<?php echo $this->_tpl_vars['k']; ?>
  211. ]" <?php echo $this->_tpl_vars['gui']->checkboxStatus[$this->_tpl_vars['k']]; ?>
  212. /><?php echo $this->_tpl_vars['id']; ?>
  213. <br />
  214. <?php endforeach; endif; unset($_from); ?>
  215. </fieldset>
  216. </td>
  217. </tr>
  218. <tr>
  219. <td><fieldset class="x-fieldset x-form-label-left"><legend ><?php echo $this->_tpl_vars['labels']['th_platform_rights']; ?>
  220. </legend>
  221. <?php $_from = $this->_tpl_vars['gui']->rightsCfg->platform_mgmt; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  222. foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['id']):
  223. ?>
  224. <input class="tl-input" type="checkbox" name="grant[<?php echo $this->_tpl_vars['k']; ?>
  225. ]" <?php echo $this->_tpl_vars['gui']->checkboxStatus[$this->_tpl_vars['k']]; ?>
  226. /><?php echo $this->_tpl_vars['id']; ?>
  227. <br />
  228. <?php endforeach; endif; unset($_from); ?>
  229. </fieldset>
  230. </td>
  231. <?php $_smarty_tpl_vars = $this->_tpl_vars;
  232. $this->_smarty_include(array('smarty_include_tpl_file' => "bugtrackerRolesEdit.tpl", 'smarty_include_vars' => array()));
  233. $this->_tpl_vars = $_smarty_tpl_vars;
  234. unset($_smarty_tpl_vars);
  235. ?>
  236. </tr>
  237. </table>
  238. </td>
  239. </tr>
  240. <tr><th><?php echo $this->_tpl_vars['labels']['enter_role_notes']; ?>
  241. </th></tr>
  242. <tr>
  243. <td width="80%"><?php echo $this->_tpl_vars['gui']->notes; ?>
  244. </td>
  245. </tr>
  246. </table>
  247. <div class="groupBtn">
  248. <?php if ($this->_tpl_vars['gui']->grants->role_mgmt == 'yes' && $this->_tpl_vars['gui']->role->dbID != @TL_ROLES_NO_RIGHTS): ?>
  249. <input type="hidden" name="doAction" value="<?php echo $this->_tpl_vars['gui']->operation; ?>
  250. " />
  251. <input type="submit" name="role_mgmt" value="<?php echo $this->_tpl_vars['labels']['btn_save']; ?>
  252. "
  253. <?php if ($this->_tpl_vars['gui']->role != null && $this->_tpl_vars['gui']->affectedUsers != null): ?> onClick="return modifyRoles_warning()"<?php endif; ?>
  254. />
  255. <?php endif; ?>
  256. <input type="button" name="cancel" value="<?php echo $this->_tpl_vars['labels']['btn_cancel']; ?>
  257. "
  258. onclick="javascript: location.href=fRoot+'lib/usermanagement/rolesView.php';" />
  259. </div>
  260. <br />
  261. <?php if ($this->_tpl_vars['gui']->affectedUsers != null): ?>
  262. <table class="common" style="width:50%">
  263. <caption><?php echo $this->_tpl_vars['labels']['caption_possible_affected_users']; ?>
  264. </caption>
  265. <?php $_from = $this->_tpl_vars['gui']->affectedUsers; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
  266. foreach ($_from as $this->_tpl_vars['user']):
  267. ?>
  268. <tr>
  269. <td><?php echo ((is_array($_tmp=$this->_tpl_vars['user']->getDisplayName())) ? $this->_run_mod_handler('escape', true, $_tmp) : smarty_modifier_escape($_tmp)); ?>
  270. </td>
  271. </tr>
  272. <?php endforeach; endif; unset($_from); ?>
  273. </table>
  274. <?php endif; ?>
  275. </form>
  276. </div>
  277. </body>
  278. </html>