* Fix the issue of adding stakeholders.
This commit is contained in:
@@ -448,6 +448,7 @@ class stakeholder extends control
|
||||
$this->view->position[] = $this->lang->stakeholder->view;
|
||||
|
||||
$this->view->stakeholder = $stakeholder;
|
||||
$this->view->projectID = $stakeholder->objectID;
|
||||
$this->view->issueList = $this->stakeholder->getStakeholderIssue($stakeholder->user);
|
||||
|
||||
$this->display();
|
||||
|
||||
@@ -4,18 +4,16 @@ class stakeholderModel extends model
|
||||
/**
|
||||
* Create a stakeholder.
|
||||
*
|
||||
* @param int programID
|
||||
* @param int objectID
|
||||
* @access public
|
||||
* @return int|bool
|
||||
*/
|
||||
public function create($programID = 0)
|
||||
public function create($objectID = 0)
|
||||
{
|
||||
$stakeholder = new stdclass();
|
||||
$data = fixer::input('post')
|
||||
->setIF($programID == 0, 'objectType', 'project')
|
||||
->setIF($programID != 0, 'objectType', 'program')
|
||||
->setIF($programID == 0, 'objectID', $this->session->project)
|
||||
->setIF($programID != 0, 'objectID', $programID)
|
||||
->setDefault('objectType', $this->app->openApp)
|
||||
->setDefault('objectID', $objectID)
|
||||
->setDefault('createdBy', $this->app->user->account)
|
||||
->setDefault('createdDate', helper::today())
|
||||
->stripTags($this->config->stakeholder->editor->create['id'], $this->config->allowedTags)
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
<span><?php echo $lang->stakeholder->viewIssue;?></span>
|
||||
</h2>
|
||||
<div class="pull-right">
|
||||
<?php common::printLink('issue', 'create', 'from=stakeholder&owner=' . $stakeholder->user, "<i class='icon icon-plus'></i>" . $lang->issue->create, '', "class='btn btn-primary'");?>
|
||||
<?php common::printLink('issue', 'create', "projectID=$projectID&from=stakeholder&owner=" . $stakeholder->user, "<i class='icon icon-plus'></i>" . $lang->issue->create, '', "class='btn btn-primary'");?>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user