* Fix the batch edit button and remove redundant buttons from toolbar on the product view page within program module.

This commit is contained in:
chentao
2023-06-28 10:02:17 +08:00
parent b1b0119694
commit d28542a2da
2 changed files with 5 additions and 36 deletions
+1 -1
View File
@@ -38,7 +38,7 @@ window.iconRenderProductView = function(value, row)
* @access public
* @return void
*/
onClickBatchEdit = function(event)
window.onClickBatchEdit = function(event)
{
event.stopPropagation();
event.preventDefault();
+4 -35
View File
@@ -20,27 +20,9 @@ $fnGenerateCreateProgramBtns = function() use ($lang, $browseType)
{
$items = array();
hasPriv('program', 'create') ? $items[] = array
(
'text' => $lang->program->create,
'icon' => 'plus',
'url' => createLink('program', 'create')
) : null;
hasPriv('product', 'create') ? $items[] = array
(
'text' => $lang->program->createProduct,
'icon' => 'plus',
'url' => createLink('product', 'create')
) : null;
hasPriv('product', 'manageLine') ? $items[] = array
(
'text' => $lang->program->manageLine,
'icon' => 'edit',
'data-toggle' => 'modal',
'data-url' => createLink('product', 'manageLine', $browseType)
) : null;
hasPriv('program', 'create') && $items[] = array('text' => $lang->program->create, 'icon' => 'plus', 'url' => createLink('program', 'create'));
hasPriv('product', 'create') && $items[] = array('text' => $lang->program->createProduct, 'icon' => 'plus', 'url' => createLink('product', 'create'));
hasPriv('product', 'manageLine') && $items[] = array('text' => $lang->program->manageLine, 'icon' => 'edit', 'data-url' => createLink('product', 'manageLine', $browseType), 'data-toggle' => 'modal' );
return btnGroup
(
@@ -279,19 +261,6 @@ featureBar
toolbar
(
item(set(array(
'text' => $lang->program->export,
'icon' => 'export',
'class'=> 'ghost',
'url' => createLink('program', 'exportTable')
))),
div(setClass('nav-divider')),
item(set(array(
'text' => $lang->program->edit,
'icon' => 'edit',
'class'=> 'ghost',
'url' => createLink('program', 'exportTable')
))),
$fnGenerateCreateProgramBtns()
);
@@ -316,7 +285,7 @@ dtable
'text' => $lang->edit,
'btnType' => 'secondary',
'url' => createLink('product', 'batchEdit'),
'onClick' => jsRaw('onClickBatchEdit')
'onClick' => jsRaw('window.onClickBatchEdit')
) : null
)
)),