Example #1
0
	  					<li class="dropdown-submenu pull-left" >
	  						<a tabindex="-1" href="#" ><i class="icon-signal" ></i>&nbsp;Priority</a>
	  						
	  						<ul class="dropdown-menu" >
	  							<?php 
            $p = new IssuePriority(IssuePriority::CRITICAL);
            ?>
									<li><a tabindex="-1" href="javascript:updateIssuesPriority(<?php 
            echo IssuePriority::CRITICAL;
            ?>
, <?php 
            echo $issue->issue_id;
            ?>
)" >
											<?php 
            $p->setPriority(IssuePriority::CRITICAL);
            echo $p->getLabel(false);
            echo '&nbsp;&nbsp;';
            echo $p->getName();
            ?>
</a></li>
									<li><a tabindex="-1" href="javascript:updateIssuesPriority(<?php 
            echo IssuePriority::NORMAL;
            ?>
, <?php 
            echo $issue->issue_id;
            ?>
)" >
											<?php 
            $p->setPriority(IssuePriority::NORMAL);
            echo $p->getLabel(false);
Example #2
0
 //////// UPDATE ISSUES STATE
 case 'setissuesstate':
     $issueIds = @$_POST['issueIds'];
     $state = @$_POST['state'];
     if (ReportHelper::checkState($state)) {
         if (!empty($issueIds)) {
             if (DBHelper::updateIssuesState(explode(',', $issueIds), $state)) {
                 echo 'O:';
                 $state = new IssueState($state);
                 $priority = new IssuePriority();
                 $label = $state->getLabel(true);
                 $issueIds = explode(',', $issueIds);
                 $sep = '';
                 foreach ($issueIds as $issueId) {
                     $res = DbHelper::selectRow(TBL_ISSUES, ISSUE_ID . '=' . $issueId, ISSUE_PRIORITY);
                     $priority->setPriority($res[0][0]);
                     echo $sep, $label, '|', IssueHelper::getHiliteBgColorClass($state, $priority), '|', strtolower($state->getName());
                     $sep = '||';
                 }
             } else {
                 echo "K:Error occured while trying to update issue(s) state :\n\n" . DBHelper::getLastError();
             }
         } else {
             echo 'K:Issue id(s) is not valid !';
         }
     } else {
         echo 'K:This state is not valid and can\'t be applyed !';
     }
     break;
     //////// UPDATE ISSUES PRIORITY
 //////// UPDATE ISSUES PRIORITY