|
@@ -164,67 +164,36 @@ export default {
|
|
|
|
|
|
|
|
|
|
|
|
|
},
|
|
},
|
|
|
- // 提交状态
|
|
|
|
|
- loading: false,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
- removeList: [],
|
|
|
|
|
-
|
|
|
|
|
- // 表格列配置
|
|
|
|
|
columns: [
|
|
columns: [
|
|
|
|
|
+
|
|
|
{
|
|
{
|
|
|
prop: 'code',
|
|
prop: 'code',
|
|
|
- label: '参数编码',
|
|
|
|
|
- showOverflowTooltip: true,
|
|
|
|
|
- align: 'center',
|
|
|
|
|
- minWidth: 110
|
|
|
|
|
|
|
+ label: '编码'
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
prop: 'name',
|
|
prop: 'name',
|
|
|
- label: '参数名称',
|
|
|
|
|
- showOverflowTooltip: true,
|
|
|
|
|
- align: 'center',
|
|
|
|
|
- minWidth: 110
|
|
|
|
|
|
|
+ label: '名称',
|
|
|
|
|
+ showOverflowTooltip: true
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
- align: 'center',
|
|
|
|
|
- prop: 'description',
|
|
|
|
|
- label: '文本描述',
|
|
|
|
|
- showOverflowTooltip: true,
|
|
|
|
|
- minWidth: 110
|
|
|
|
|
|
|
+ prop: 'brandNum',
|
|
|
|
|
+ label: '牌号'
|
|
|
},
|
|
},
|
|
|
-
|
|
|
|
|
{
|
|
{
|
|
|
- prop: 'maxValue',
|
|
|
|
|
- slot: 'maxValue',
|
|
|
|
|
- label: '参数上限',
|
|
|
|
|
- align: 'center',
|
|
|
|
|
-
|
|
|
|
|
|
|
+ prop: 'modelType',
|
|
|
|
|
+ label: '型号'
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
- prop: 'minValue',
|
|
|
|
|
- slot: 'minValue',
|
|
|
|
|
- label: '参数下限',
|
|
|
|
|
- align: 'center',
|
|
|
|
|
-
|
|
|
|
|
|
|
+ prop: 'measuringUnit',
|
|
|
|
|
+ label: '计量单位'
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
- prop: 'defaultValue',
|
|
|
|
|
- slot: 'defaultValue',
|
|
|
|
|
- label: '默认值',
|
|
|
|
|
- align: 'center',
|
|
|
|
|
-
|
|
|
|
|
|
|
+ prop: 'packingUnit',
|
|
|
|
|
+ label: '包装单位'
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- {
|
|
|
|
|
- prop: 'unitName',
|
|
|
|
|
- slot: 'unitName',
|
|
|
|
|
- label: '参数单位',
|
|
|
|
|
- align: 'center',
|
|
|
|
|
- showOverflowTooltip: true
|
|
|
|
|
- },
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
{
|
|
{
|
|
|
columnKey: 'action',
|
|
columnKey: 'action',
|
|
|
label: '操作',
|
|
label: '操作',
|
|
@@ -234,8 +203,18 @@ export default {
|
|
|
slot: 'action',
|
|
slot: 'action',
|
|
|
showOverflowTooltip: true
|
|
showOverflowTooltip: true
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
],
|
|
],
|
|
|
|
|
|
|
|
|
|
+
|
|
|
|
|
+ // 提交状态
|
|
|
|
|
+ loading: false,
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ removeList: [],
|
|
|
|
|
+
|
|
|
|
|
+ tableData: []
|
|
|
|
|
+
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
@@ -250,14 +229,26 @@ export default {
|
|
|
|
|
|
|
|
|
|
|
|
|
openParam() {
|
|
openParam() {
|
|
|
|
|
+ this.tableData = this.$refs.table.getData()
|
|
|
this.$refs.materiaRef.open(this.tableData, '选择物料', '1')
|
|
this.$refs.materiaRef.open(this.tableData, '选择物料', '1')
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
- determineChoose(title, row) {
|
|
|
|
|
-
|
|
|
|
|
|
|
+ chooseModal(data) {
|
|
|
|
|
+ this.$refs.table.setData([...data, ...this.$refs.table.getData()]);
|
|
|
|
|
|
|
|
},
|
|
},
|
|
|
|
|
|
|
|
|
|
+
|
|
|
|
|
+ /* 删除 */
|
|
|
|
|
+ remove(row) {
|
|
|
|
|
+ const data = this.$refs.table.getData() ?? [];
|
|
|
|
|
+ if (row.id) {
|
|
|
|
|
+ this.removeList.push(row.id);
|
|
|
|
|
+ this.$refs.table.setData(data.filter((d) => d.id !== row.id));
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ },
|
|
|
|
|
|
|
|
|
|
|
|
|
/* 表格数据源 */
|
|
/* 表格数据源 */
|
|
@@ -278,8 +269,6 @@ export default {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
});
|
|
});
|
|
|
},
|
|
},
|
|
|
/* 更新visible */
|
|
/* 更新visible */
|
|
@@ -294,9 +283,7 @@ export default {
|
|
|
async visible(visible) {
|
|
async visible(visible) {
|
|
|
if (visible) {
|
|
if (visible) {
|
|
|
|
|
|
|
|
-
|
|
|
|
|
if (this.data) {
|
|
if (this.data) {
|
|
|
- console.log(this.data)
|
|
|
|
|
|
|
|
|
|
this.$util.assignObject(this.form, {
|
|
this.$util.assignObject(this.form, {
|
|
|
...this.data
|
|
...this.data
|