udpate 混料批次编辑

This commit is contained in:
lb
2023-03-15 14:57:54 +08:00
parent 977dbb7c41
commit a94d5c2715
6 changed files with 30 additions and 26 deletions

View File

@@ -29,9 +29,9 @@ export default function () {
prop: "operations",
name: "操作",
fixed: "right",
width: 160,
width: 120,
subcomponent: TableOperaionComponent,
options: ['add', { name: 'edit', enable: injectRow => { return 'task' in injectRow && injectRow.task === 'Manual'} }] // 只有 injectRow.task 为手动时,才允许编辑
options: [{ name: 'edit', enable: injectRow => { return 'task' in injectRow && injectRow.task === 'Manual' } }] // 只有 injectRow.task 为手动时,才允许编辑
},
];

View File

@@ -24,7 +24,7 @@ export default {
computed: {
// 混料订单id
id() {
return this.$route.params.id || "";
return this.$route.query.id || "";
},
},
data() {
@@ -39,10 +39,10 @@ export default {
},
watch: {
$route: {
handler: function (val) {
if (val.params.id) {
handler: function (route) {
if (route.query.id) {
this.triggerUpdateKey = Math.random().toString()
console.log('[$oute changed] val.params.id', val.params.id, this.triggerUpdateKey)
console.log('[$oute changed] val.params.id', route.query.id, this.triggerUpdateKey)
}
},
immediate: true,

View File

@@ -212,7 +212,7 @@ export default {
case 'view-batch': {
this.$router.push({
name: toRouter,
params: {
query: {
id: data // 混料订单id
}
})