// milestone
- $this->change_status = array();
- $this->resolve_status = array();
- if ($this->id) {
-
- // for coder's they can only change this ticke to certian states
-
- //print_r($groups);
- // Nasty - I really do not like the acl code in this ...
- require_once 'MTrack/TicketState.php';
-
- $ST = new MTrackTicketState;
- $ST = $ST->enumerate();
- //print_r($ST);
- unset($ST['closed']);
- unset($ST[$this->issue->status]);
-
- $this->change_status = empty($ST) ? array() : array_keys($ST);
-
- $ac = MTrackAuth::getUserClass($this->authUser->userid);
- //var_dump($ac);exit;
-// KLUDGE! - remove later...
- if ($ac == 'admin') {
-
- $this->resolve_status= array('fixed');
- $R = new MTrackResolution;
- $resolutions = $R->enumerate();
- unset($resolutions['fixed']);
-
- $this->resolve_status= array_keys($resolutions);
- array_unshift($this->resolve_status, 'fixed');
- // $html .= $this->mtrack_chg_status('action', 'resolve', 'Resolve as:', 'resolution', $resolutions, $this->issue );
- }
-
- // } else {
- // $html .= mtrack_radio('action', 'reopen', $_POST['action']);
- // $html .= " <label for='reopen'>Reopen ticket</label><br>\n";
- // }
-
- }
- $this->elements = HTML_Template_Flexy_Factory::fromArray($this->issue->toArray(), $this->elements);
- if (!empty($_POST)) {
- $this->elements = HTML_Template_Flexy_Factory::fromArray($_POST, $this->elements);
- }
-