fix: 重写耗材模块
This commit is contained in:
79
src/views/inventory/supplier/config/content.ts
Normal file
79
src/views/inventory/supplier/config/content.ts
Normal file
@@ -0,0 +1,79 @@
|
||||
import Api from "@/api/product/vendor";
|
||||
import type { IContentConfig } from "@/components/CURD/types";
|
||||
|
||||
const contentConfig: IContentConfig = {
|
||||
pageName: "sys:user",
|
||||
table: {
|
||||
border: true,
|
||||
highlightCurrentRow: true,
|
||||
},
|
||||
pagination: {
|
||||
background: true,
|
||||
layout: "prev,pager,next,jumper,total,sizes",
|
||||
pageSize: 20,
|
||||
pageSizes: [10, 20, 30, 50],
|
||||
},
|
||||
indexAction: function (params) {
|
||||
return Api.getList({});
|
||||
},
|
||||
deleteAction: function (id) {
|
||||
return Api.delete(id);
|
||||
},
|
||||
modifyAction: function (data) {
|
||||
return Api.edit(data);
|
||||
},
|
||||
pk: "id",
|
||||
toolbar: ["add"],
|
||||
defaultToolbar: ["refresh", "filter", "search"],
|
||||
cols: [
|
||||
// { type: "selection", width: 50, align: "center" },
|
||||
{
|
||||
label: "供应商",
|
||||
align: "center",
|
||||
prop: "name",
|
||||
},
|
||||
{
|
||||
label: "联系人",
|
||||
align: "center",
|
||||
prop: "contactName",
|
||||
},
|
||||
{
|
||||
label: "联系人电话",
|
||||
align: "center",
|
||||
prop: "telephone",
|
||||
},
|
||||
{
|
||||
label: "地址",
|
||||
align: "center",
|
||||
prop: "address",
|
||||
},
|
||||
{
|
||||
label: "备注",
|
||||
align: "center",
|
||||
prop: "remark",
|
||||
},
|
||||
{
|
||||
label: "创建时间",
|
||||
align: "center",
|
||||
prop: "createTime",
|
||||
},
|
||||
{
|
||||
label: "状态",
|
||||
align: "center",
|
||||
prop: "status",
|
||||
templet: 'custom',
|
||||
slotName: 'switch'
|
||||
},
|
||||
|
||||
{
|
||||
label: "操作",
|
||||
align: "center",
|
||||
fixed: "right",
|
||||
width: 280,
|
||||
templet: "tool",
|
||||
operat: ["edit", 'delete'],
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
export default contentConfig;
|
||||
Reference in New Issue
Block a user