扣数维护逻辑调整

dev-scheduling
zhangdi 2 months ago
parent 16859092bb
commit 0f1406997e
  1. 4
      src/api/productionManagement/deductionPreserve.js
  2. 17
      src/views/productionManagement/deductionPreserve/editDialog.vue
  3. 17
      src/views/productionManagement/deductionPreserve/index.vue

@ -18,9 +18,7 @@ export const getWorkOrderByCardNo = (params) => {
return request({
url: '/blade-desk/deductionPreserve/workOrderByCardNo',
method: 'get',
params: {
...params,
},
params: params,
});
};

@ -22,6 +22,10 @@ export default {
type: String,
default: '',
},
rowItem:{
type: Object,
default: () => ({})
}
},
data() {
return {
@ -78,17 +82,10 @@ export default {
},
mounted() {
this.openShow = this.showDialog;
// this.getWorkOrderByCardNo()
this.form = this.rowItem
},
methods: {
getWorkOrderByCardNo() {
getWorkOrderByCardNo({
cardNo: this.cardNo,
}).then(res => {
console.log(res, 'res');
this.form = res.data.data;
});
},
closeDialog(type) {
this.openShow = false;
this.$emit('closeDialog', type);
@ -105,9 +102,11 @@ export default {
done();
})
.catvh(err => {
this.closeDialog(true);
this.saveLoading = false;
});
} else {
this.closeDialog(true);
console.log('error submit!!');
return false;
}

@ -36,13 +36,14 @@
:showDialog="editOpen"
:cardNo="cardNo"
@closeDialog="closeDialog"
:rowItem="rowItem"
></editDialog>
</basic-container>
</template>
<script>
import editDialog from './editDialog.vue';
import { getList } from '@/api/productionManagement/deductionPreserve';
import { getList,getWorkOrderByCardNo } from '@/api/productionManagement/deductionPreserve';
export default {
components: {
@ -205,20 +206,28 @@ export default {
},
data: [],
rowItem:{}
};
},
methods: {
//
queryOrder() {
this.editOpen = true;
this.loading = true;
getWorkOrderByCardNo({cardNo:this.cardNo}).then(res => {
this.rowItem = res.data.data
this.editOpen = true;
this.loading = false
}).catch(err=>{
this.loading = false
})
},
closeDialog(type) {
this.isRushOpen = false;
this.isBatchOpen = false;
this.editOpen = false;
if(type){
this.onLoad(this.page, this.query);
if (type) {
this.onLoad(this.page, this.query);
}
},

Loading…
Cancel
Save