|
@@ -483,7 +483,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import {addDemand,getDemandDetail, getDemandSonDetail} from '@/api/purchase/purchaseDemand.js'
|
|
|
+import {addDemand,getDemandDetail, getDemandSonDetail, editDemand} from '@/api/purchase/purchaseDemand.js'
|
|
|
export default {
|
|
|
name: 'addDemandList',
|
|
|
props: ['pageStu','row', 'disable'],
|
|
@@ -541,12 +541,12 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
} else if (this.pageStu == 'edit') {
|
|
|
- // editAddress(this.basicForm).then(res => {
|
|
|
- // if (res.code === 200) {
|
|
|
- // this.$modal.msgSuccess("编辑成功");
|
|
|
- // this.back()
|
|
|
- // }
|
|
|
- // })
|
|
|
+ editDemand(this.basicForm).then(res => {
|
|
|
+ if (res.code === 200) {
|
|
|
+ this.$modal.msgSuccess("编辑成功");
|
|
|
+ this.back()
|
|
|
+ }
|
|
|
+ })
|
|
|
}
|
|
|
},
|
|
|
submit() {},
|
|
@@ -651,6 +651,9 @@ export default {
|
|
|
},
|
|
|
delLine(row) {
|
|
|
console.log('删除行:', row)
|
|
|
+ this.basicForm.puDemandItemList = this.basicForm.puDemandItemList.filter(item => {
|
|
|
+ return item.id !== row.id
|
|
|
+ })
|
|
|
},
|
|
|
back() {
|
|
|
this.$emit('jugislist', true)
|