* Refactor actions of the execution list.
This commit is contained in:
@@ -197,6 +197,7 @@ $config->execution->actionList['edit']['icon'] = 'edit';
|
||||
$config->execution->actionList['edit']['text'] = $lang->execution->edit;
|
||||
$config->execution->actionList['edit']['hint'] = $lang->execution->edit;
|
||||
$config->execution->actionList['edit']['url'] = helper::createLink('execution', 'edit', "executionID={rawID}");
|
||||
$config->execution->actionList['edit']['data-size'] = 'lg';
|
||||
$config->execution->actionList['edit']['data-toggle'] = 'modal';
|
||||
|
||||
$config->execution->actionList['close']['icon'] = 'off';
|
||||
|
||||
@@ -1,11 +1,10 @@
|
||||
function showTask()
|
||||
$(document).off('click', '#showTask').on('click', '#showTask', function()
|
||||
{
|
||||
var show = $('#showTask').is(':checked') ? 1 : 0;
|
||||
const show = $(this).is(':checked') ? 1 : 0;
|
||||
$.cookie.set('showTask', show, {expires:config.cookieLife, path:config.webRoot});
|
||||
|
||||
const link = $.createLink('project', 'execution', 'status=' + status + '&projectID=' + projectID + '&orderBy=' + orderBy + '&productID=' + productID);
|
||||
loadPage(link);
|
||||
}
|
||||
loadCurrentPage();
|
||||
});
|
||||
|
||||
$(document).off('click','.batch-btn').on('click', '.batch-btn', function()
|
||||
{
|
||||
|
||||
@@ -35,20 +35,13 @@ if($canBatchAction)
|
||||
|
||||
if($canBatchChangeStatus)
|
||||
{
|
||||
$statusList = array();
|
||||
$statusItems = array();
|
||||
foreach($lang->execution->statusList as $key => $value)
|
||||
{
|
||||
$statusList[] = array('text' => $value, 'class' => 'batch-btn ajax-btn', 'data-url' => createLink('execution', 'batchChangeStatus', "status=$key"));
|
||||
$statusItems[] = array('text' => $value, 'innerClass' => 'batch-btn ajax-btn', 'data-url' => createLink('execution', 'batchChangeStatus', "status=$key"));
|
||||
}
|
||||
|
||||
menu
|
||||
(
|
||||
set::id('navStatus'),
|
||||
set::className('dropdown-menu'),
|
||||
set::items($statusList)
|
||||
);
|
||||
|
||||
$footToolbar['items'][] = array('caret' => 'up', 'text' => $lang->statusAB, 'className' => 'btn btn-caret size-sm secondary', 'url' => '#navStatus', 'data-toggle' => 'dropdown', 'data-placement' => 'top-start');
|
||||
$footToolbar['items'][] = array('caret' => 'up', 'text' => $lang->statusAB, 'className' => 'btn btn-caret size-sm secondary', 'items' => $statusItems, 'type' => 'dropdown', 'data-placement' => 'top-start');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -73,7 +66,6 @@ $fnGenerateCols = function() use ($config, $project)
|
||||
};
|
||||
|
||||
/* zin: Define the feature bar on main menu. */
|
||||
$checked = $this->cookie->showTask ? 'checked' : '';
|
||||
$productMenuLink = createLink(
|
||||
$this->app->rawModule,
|
||||
$this->app->rawMethod,
|
||||
@@ -108,10 +100,9 @@ featureBar
|
||||
(
|
||||
set::id('showTask'),
|
||||
set::name('showTask'),
|
||||
set::checked($checked),
|
||||
set::checked($this->cookie->showTask ? 'checked' : ''),
|
||||
set::text($lang->programplan->stageCustom->task),
|
||||
set::rootClass('ml-4'),
|
||||
on::change('showTask')
|
||||
)
|
||||
)
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user