框架适用于各种业务wms、crm、mes系统快速开发

onInit() {
for (let index = 0; index < this.columns.length; index++) {
const column = this.columns[index];
if (column.field == 'Province') {
column.edit = { type: 'select', keep: true };
column.onChange = (row, col) => {
console.log(row.Province);
};
} else if (column.field == 'PhoneNo') {
column.edit = { type: 'text', keep: true };
}
}
this.columns.push({
title: '操作',
field: '操作',
align: 'center',
width: 70,
fixed:'right',
render: (h, { row, column, index }) => {
return (
<div>
<el-button
onClick={($e) => {
this.http.post('/api/Demo_Customer/update', { mainData: row }, true)
.then((x) => {
if (x.status) {
this.$message.info('保存成功');
return;
}
this.$message.error(x.message);
});
}}
style=" height:23px;padding: 0px 8px !important;"
size="small"
type="primary"
plain
>
保存
</el-button>
{}
</div>
);
}
});
}
预览地址 http://pro.volcore.xyz/
开源版地址