fix(goods): 添加属性显示与否演示 add visible check for stock button in admin mallImplement a conditional 'visible' attribute for the 'stock' button within the goods
management section of the admin mall interface, ensuring the button only appears when the goods status is set to 1 (active). This change streamlines the UI by hiding irrelevant options for inactive goods items.
This commit is contained in:
@@ -59,6 +59,9 @@ define(["jquery", "easy-admin"], function ($, ea) {
|
||||
method: 'open',
|
||||
auth: 'stock',
|
||||
class: 'layui-btn layui-btn-xs layui-btn-normal',
|
||||
visible: function (row) {
|
||||
return row.status === 1;
|
||||
},
|
||||
}],
|
||||
'delete']
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user