예제 #1
0
     $ret = $ts->unApproveSingleItem($id);
     if ($ret) {
         $error = 'Successfully un-approved the item...';
         $output = generateTimesheet($userid, false, true);
     } else {
         $error = 'Error! Database Error thrown.';
         $output = '';
     }
     break;
 case 'rejectitem':
     $id = COM_applyFilter($_REQUEST['id'], true);
     $comment = COM_applyFilter($_REQUEST['comment']);
     $comment = $_REQUEST['comment'];
     $userid = COM_applyFilter($_REQUEST['uid'], true);
     $ts = new nexTime();
     $ret = $ts->rejectSingleItem($id, $comment);
     if ($ret) {
         $error = 'Successfully rejected the item... ';
         $output = generateTimesheet($userid, false, true);
     } else {
         $error = 'Error! Database Error thrown.';
         $output = '';
     }
     break;
 case 'unrejectitem':
     $id = COM_applyFilter($_REQUEST['id'], true);
     $userid = COM_applyFilter($_REQUEST['uid'], true);
     $ts = new nexTime();
     $ret = $ts->unRejectSingleItem($id);
     if ($ret) {
         $error = 'Successfully un-rejected the item...';