Added Notes config setting on week view config.
authorNik Okuntseff <support@anuko.com>
Sat, 3 Feb 2018 13:36:43 +0000 (13:36 +0000)
committerNik Okuntseff <support@anuko.com>
Sat, 3 Feb 2018 13:36:43 +0000 (13:36 +0000)
WEB-INF/templates/footer.tpl
WEB-INF/templates/week_view.tpl
week_view.php

index 7352465..38bb731 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.10.3870 | 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.10.3871 | 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 9cb14f3..d3253e9 100644 (file)
@@ -6,7 +6,11 @@
   </tr>
   <tr>
     <td align="right" nowrap>{$forms.weekViewForm.week_list.control}</td>
-    <td><label for="week_note">{$i18n.label.week_list}</label> <a href="https://www.anuko.com/lp/tt_12.htm" target="_blank">{$i18n.label.what_is_it}</a></td>
+    <td><label for="week_list">{$i18n.label.week_list}</label> <a href="https://www.anuko.com/lp/tt_12.htm" target="_blank">{$i18n.label.what_is_it}</a></td>
+  </tr>
+  <tr>
+    <td align="right" nowrap>{$forms.weekViewForm.notes.control}</td>
+    <td><label for="notes">{$i18n.label.notes}</label> <a href="https://www.anuko.com/lp/tt_13.htm" target="_blank">{$i18n.label.what_is_it}</a></td>
   </tr>
 
   <tr>
index 2c538d9..7c722da 100644 (file)
@@ -39,21 +39,25 @@ if (!ttAccessCheck(right_manage_team) || !$user->isPluginEnabled('wv')) {
 if ($request->isPost()) {
   $cl_week_note = $request->getParameter('week_note');
   $cl_week_list = $request->getParameter('week_list');
+  $cl_notes = $request->getParameter('notes');
 } else {
   $plugins = explode(',', $user->plugins);
-  $cl_week_note = in_array('wn', $plugins);
-  $cl_week_list = in_array('wl', $plugins);
+  $cl_week_note = in_array('wvn', $plugins);
+  $cl_week_list = in_array('wvl', $plugins);
+  $cl_notes = in_array('wvns', $plugins);
 }
 
 
 $form = new Form('weekViewForm');
 $form->addInput(array('type'=>'checkbox','name'=>'week_note','value'=>$cl_week_note));
 $form->addInput(array('type'=>'checkbox','name'=>'week_list','value'=>$cl_week_list));
+$form->addInput(array('type'=>'checkbox','name'=>'notes','value'=>$cl_notes));
 $form->addInput(array('type'=>'submit','name'=>'btn_save','value'=>$i18n->getKey('button.save')));
 
 if ($request->isPost()){
-  if (!ttTeamHelper::enablePlugin('wn', $cl_week_note) ||
-      !ttTeamHelper::enablePlugin('wl', $cl_week_list)) {
+  if (!ttTeamHelper::enablePlugin('wvn', $cl_week_note) ||
+      !ttTeamHelper::enablePlugin('wvl', $cl_week_list) ||
+      !ttTeamHelper::enablePlugin('wvns', $cl_notes)) {
     $err->add($i18n->getKey('error.db'));
   }
 }