|
@@ -30,7 +30,7 @@
|
|
|
@pagination="getList({ ...page, ...params })"
|
|
|
style="margin: 16px 0 0"
|
|
|
>
|
|
|
- <ux-table-column fixed="right" title="操作" align="center" width="180">
|
|
|
+ <ux-table-column fixed="right" title="操作" align="center" width="100">
|
|
|
<template slot-scope="scope">
|
|
|
<el-button
|
|
|
:size="size"
|
|
@@ -45,7 +45,7 @@
|
|
|
|
|
|
<!-- 添加或修改任务对话框 -->
|
|
|
<el-dialog :title="title" :visible.sync="open" width="700px" append-to-body>
|
|
|
- <el-form :size="size" ref="form" :model="form" label-width="80px">
|
|
|
+ <!-- <el-form :size="size" ref="form" :model="form" label-width="80px">
|
|
|
<el-descriptions :column="1">
|
|
|
<el-descriptions-item label="单据来源">{{
|
|
|
form.source
|
|
@@ -81,7 +81,30 @@
|
|
|
@input="useFormQtyChange"
|
|
|
/>
|
|
|
</el-form-item>
|
|
|
- </el-form>
|
|
|
+ </el-form> -->
|
|
|
+ <el-super-form
|
|
|
+ v-model="form"
|
|
|
+ :dict="dict"
|
|
|
+ :rules="rules"
|
|
|
+ :size="$attrs.size"
|
|
|
+ :columns="FormColumns"
|
|
|
+ ref="superForm"
|
|
|
+ label-width="auto"
|
|
|
+ label-position="right"
|
|
|
+ style="padding: 20px"
|
|
|
+ >
|
|
|
+ <template slot="qty" slot-scope="scope">
|
|
|
+ <component
|
|
|
+ v-bind="scope.attr"
|
|
|
+ v-model="scope.row[scope.item.key]"
|
|
|
+ :size="$attrs.size"
|
|
|
+ :source.sync="scope.row"
|
|
|
+ @input="useFormQtyChange"
|
|
|
+ >
|
|
|
+ </component
|
|
|
+ ></template>
|
|
|
+ </el-super-form>
|
|
|
+
|
|
|
<div slot="footer">
|
|
|
<el-button :size="size" type="primary" @click="submitForm"
|
|
|
>确 定</el-button
|
|
@@ -100,19 +123,24 @@ export default {
|
|
|
name: "ownerShip",
|
|
|
dicts: [...dicts],
|
|
|
components: {
|
|
|
+ ElSuperForm: () => import("@/components/super-form/index.vue"),
|
|
|
ElSuperUxTable: () => import("@/components/super-ux-table/index.vue"),
|
|
|
ElSuperSearch: () => import("@/components/super-search/index.vue"),
|
|
|
},
|
|
|
data() {
|
|
|
- const { SearchColumns, TableColumns } = useColumns();
|
|
|
+ const { SearchColumns, TableColumns, FormColumns } = useColumns();
|
|
|
const params = this.$init.params(SearchColumns);
|
|
|
const page = this.$init.page();
|
|
|
+ const rules = this.$init.rules(FormColumns);
|
|
|
+ const form = this.$init.params(FormColumns);
|
|
|
return {
|
|
|
+ page,
|
|
|
+ rules,
|
|
|
+ params,
|
|
|
size: "mini",
|
|
|
SearchColumns,
|
|
|
TableColumns,
|
|
|
- params,
|
|
|
- page,
|
|
|
+ FormColumns,
|
|
|
// 遮罩层
|
|
|
loading: true,
|
|
|
// 选中数组
|
|
@@ -121,8 +149,6 @@ export default {
|
|
|
single: true,
|
|
|
// 非多个禁用
|
|
|
multiple: true,
|
|
|
- // 总条数
|
|
|
- total: 0,
|
|
|
// 列表数据
|
|
|
list: [],
|
|
|
// 弹出层标题
|
|
@@ -130,13 +156,13 @@ export default {
|
|
|
// 是否显示弹出层
|
|
|
open: false,
|
|
|
// 表单参数
|
|
|
- form: {},
|
|
|
+ form: form,
|
|
|
//oldQty
|
|
|
oldQty: 0,
|
|
|
};
|
|
|
},
|
|
|
created() {
|
|
|
- this.getList();
|
|
|
+ this.getList(this.params, this.page);
|
|
|
},
|
|
|
methods: {
|
|
|
/** 查询任务列表 */
|
|
@@ -147,7 +173,7 @@ export default {
|
|
|
...page,
|
|
|
}).then((response) => {
|
|
|
this.list = response.rows;
|
|
|
- this.total = response.total;
|
|
|
+ this.page.total = response.total;
|
|
|
this.loading = false;
|
|
|
});
|
|
|
},
|
|
@@ -210,7 +236,7 @@ export default {
|
|
|
update(this.form).then((response) => {
|
|
|
this.$modal.msgSuccess("修改成功");
|
|
|
this.open = false;
|
|
|
- this.getList();
|
|
|
+ this.getList(this.params, this.page);
|
|
|
});
|
|
|
},
|
|
|
//值改变后
|