부터: 3.0.0
저자: Jack P.
상속: extends Traq\Controllers\AppController
예제 #1
0
파일: CustomFields.php 프로젝트: nirix/traq
 public function __construct()
 {
     parent::__construct();
     $this->addCrumb($this->translate('custom_fields'), $this->generateUrl('project_settings_custom_fields'));
     $this->before(['edit', 'save', 'destroy'], function () {
         $this->object = CustomField::find(Request::$properties->get('id'));
         if (!$this->object || $this->object->project_id != $this->currentProject['id']) {
             return $this->show404();
         }
     });
 }
예제 #2
0
 public function __construct()
 {
     parent::__construct();
     $this->title($this->translate('components'));
     $this->before(['edit', 'save', 'destroy'], function () {
         $this->object = Component::find(Request::$properties->get('id'));
         if (!$this->object || $this->object->project_id != $this->currentProject['id']) {
             return $this->show404();
         }
     });
 }
예제 #3
0
 public function __construct()
 {
     parent::__construct();
     $this->title($this->translate('milestones'));
     $this->before(['edit', 'save', 'delete', 'destroy'], function () {
         $this->object = Milestone::find(Request::$properties->get('id'));
         if (!$this->object || $this->object->project_id != $this->currentProject['id']) {
             return $this->show404();
         }
     });
     $this->after('save', function () {
         if ($this->object->isBeingCompleted) {
             Timeline::milestoneCompletedEvent($this->currentUser, $this->object)->save();
         }
     });
 }
예제 #4
0
파일: Members.php 프로젝트: dasklney/traq
 public function __construct()
 {
     parent::__construct();
     $this->title($this->translate("members"));
 }
예제 #5
0
 public function __construct()
 {
     parent::__construct();
     $this->title(l('custom_fields'));
 }
예제 #6
0
 public function __construct()
 {
     parent::__construct();
     // Set Form::select() options
     View::set('options', array('defaults' => array(array('label' => l('allow'), 'value' => 1), array('label' => l('deny'), 'value' => 0)), 'all' => array(array('label' => l('defaults'), 'value' => -1), array('label' => l('allow'), 'value' => 1), array('label' => l('deny'), 'value' => 0))));
 }
예제 #7
0
파일: Members.php 프로젝트: nirix/traq
 public function __construct()
 {
     parent::__construct();
     $this->addCrumb($this->translate('members'), $this->generateUrl('project_settings_members'));
 }