Refactoring in admin_group_delete.php and .tpl.
authorNik Okuntseff <support@anuko.com>
Thu, 5 Apr 2018 12:44:09 +0000 (12:44 +0000)
committerNik Okuntseff <support@anuko.com>
Thu, 5 Apr 2018 12:44:09 +0000 (12:44 +0000)
WEB-INF/templates/admin_group_delete.tpl
WEB-INF/templates/footer.tpl
admin_group_delete.php

index a8b0712..57164d4 100644 (file)
@@ -1,20 +1,20 @@
-{$forms.teamForm.open}
+{$forms.groupForm.open}
 <table cellspacing="4" cellpadding="7" border="0">
   <tr>
     <td>
       <table cellspacing="0" cellpadding="0" border="0">
         <tr>
-          <td colspan="2" align="center"><b>{$team_to_delete|escape}</b></td>
+          <td colspan="2" align="center"><b>{$group_to_delete|escape}</b></td>
         </tr>
         <tr>
           <td colspan="2" align="center">&nbsp;</td>
         </tr>
         <tr>
-          <td align="right">{$forms.teamForm.btn_delete.control}&nbsp;</td>
-          <td align="left">&nbsp;{$forms.teamForm.btn_cancel.control}</td>
+          <td align="right">{$forms.groupForm.btn_delete.control}&nbsp;</td>
+          <td align="left">&nbsp;{$forms.groupForm.btn_cancel.control}</td>
         </tr>
       </table>
     </td>
   </tr>
 </table>
-{$forms.teamForm.close}
+{$forms.groupForm.close}
index abe93b4..dc988c9 100644 (file)
@@ -12,7 +12,7 @@
       <br>
       <table cellspacing="0" cellpadding="4" width="100%" border="0">
         <tr>
-          <td align="center">&nbsp;Anuko Time Tracker 1.17.86.4228 | Copyright &copy; <a href="https://www.anuko.com/lp/tt_3.htm" target="_blank">Anuko</a> |
+          <td align="center">&nbsp;Anuko Time Tracker 1.17.86.4229 | Copyright &copy; <a href="https://www.anuko.com/lp/tt_3.htm" target="_blank">Anuko</a> |
             <a href="https://www.anuko.com/lp/tt_4.htm" target="_blank">{$i18n.footer.credits}</a> |
             <a href="https://www.anuko.com/lp/tt_5.htm" target="_blank">{$i18n.footer.license}</a> |
             <a href="https://www.anuko.com/lp/tt_7.htm" target="_blank">{$i18n.footer.improve}</a>
index 476f504..418b7fb 100644 (file)
@@ -38,10 +38,10 @@ if (!ttAccessAllowed('administer_site')) {
 // End of access checks.
 
 $group_id = (int)$request->getParameter('id');
-$team_details = ttTeamHelper::getTeamDetails($group_id);
-$team_name = $team_details['team_name'];
+$group_details = ttTeamHelper::getTeamDetails($group_id); // TODO: refactor this.
+$group_name = $group_details['team_name'];
 
-$form = new Form('teamForm');
+$form = new Form('groupForm');
 $form->addInput(array('type'=>'hidden','name'=>'id','value'=>$group_id));
 $form->addInput(array('type'=>'submit','name'=>'btn_delete','value'=>$i18n->get('label.delete')));
 $form->addInput(array('type'=>'submit','name'=>'btn_cancel','value'=>$i18n->get('button.cancel')));
@@ -64,7 +64,7 @@ if ($request->isPost()) {
   }
 } // isPost
 
-$smarty->assign('team_to_delete', $team_name);
+$smarty->assign('group_to_delete', $group_name);
 $smarty->assign('forms', array($form->getName()=>$form->toArray()));
 $smarty->assign('title', $i18n->get('title.delete_group'));
 $smarty->assign('content_page_name', 'admin_group_delete.tpl');