Merge branch 'master_xieqiyu_25027' into 'master'
* Fix bug#25027. See merge request easycorp/zentaopms!4545
This commit is contained in:
@@ -4168,4 +4168,23 @@ class execution extends control
|
||||
echo json_encode($executions);
|
||||
}
|
||||
|
||||
/**
|
||||
* AJAX: Get execution kanban data.
|
||||
*
|
||||
* @param int $executionID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
public function ajaxGetExecutionKanban($executionID)
|
||||
{
|
||||
$execution = $this->execution->getByID($executionID);
|
||||
if($this->app->tab == 'execution' and $execution->type == 'kanban')
|
||||
{
|
||||
$execLaneType = $this->session->execLaneType ? $this->session->execLaneType : 'all';
|
||||
$execGroupBy = $this->session->execGroupBy ? $this->session->execGroupBy : 'default';
|
||||
$rdSearchValue = $this->session->rdSearchValue ? $this->session->rdSearchValue : '';
|
||||
$kanbanData = $this->loadModel('kanban')->getRDKanban($executionID, $execLaneType, 'id_desc', 0, $execGroupBy, $rdSearchValue);
|
||||
echo json_encode($kanbanData);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -9,10 +9,19 @@ $(function()
|
||||
/**
|
||||
* Go back.
|
||||
*
|
||||
* @param int $executionID
|
||||
* @access public
|
||||
* @return void
|
||||
*/
|
||||
function goback()
|
||||
function goback(executionID)
|
||||
{
|
||||
parent.location.reload();
|
||||
var link = createLink('execution', 'ajaxGetExecutionKanban', "executionID=" + executionID);
|
||||
$.get(link, function(data)
|
||||
{
|
||||
if(data)
|
||||
{
|
||||
kanbanData = $.parseJSON(data);
|
||||
parent.updateKanban(kanbanData);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
</div>
|
||||
<div class='btn-toolbar'>
|
||||
<?php if(isonlybody()):?>
|
||||
<?php echo html::commonButton('<i class="icon icon-sm"></i> ' . $lang->goback, 'onclick="goback()"', 'btn');?>
|
||||
<?php echo html::commonButton('<i class="icon icon-sm"></i> ' . $lang->goback, "onclick='goback($executionID)'", 'btn');?>
|
||||
<?php else:?>
|
||||
<?php echo html::backButton('','','btn');?>
|
||||
<?php endif;?>
|
||||
|
||||
Reference in New Issue
Block a user