|
@@ -43,9 +43,14 @@
|
|
|
<script>
|
|
<script>
|
|
|
import fileDoc from '../doc/index.vue'
|
|
import fileDoc from '../doc/index.vue'
|
|
|
import {
|
|
import {
|
|
|
- saleordersendrecordInfo
|
|
|
|
|
|
|
+ saleordersendrecordInfo,
|
|
|
|
|
+ saleordersendconfirmSave,
|
|
|
|
|
+ saleordersendconfirmInfo
|
|
|
} from '@/api/saleManage/saleorder/index.js'
|
|
} from '@/api/saleManage/saleorder/index.js'
|
|
|
-
|
|
|
|
|
|
|
+ import {
|
|
|
|
|
+ processInstanceCreateAPI,
|
|
|
|
|
+ processInstancePage
|
|
|
|
|
+ } from '@/api/wt/index.js'
|
|
|
export default {
|
|
export default {
|
|
|
components: {fileDoc},
|
|
components: {fileDoc},
|
|
|
data() {
|
|
data() {
|
|
@@ -60,13 +65,10 @@
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
onLoad(options={}) {
|
|
onLoad(options={}) {
|
|
|
- console.log(options,'====')
|
|
|
|
|
// 详情
|
|
// 详情
|
|
|
if(options.id){
|
|
if(options.id){
|
|
|
this.getInfo(options.id)
|
|
this.getInfo(options.id)
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
-
|
|
|
|
|
},
|
|
},
|
|
|
computed: {
|
|
computed: {
|
|
|
|
|
|
|
@@ -74,25 +76,22 @@
|
|
|
|
|
|
|
|
methods: {
|
|
methods: {
|
|
|
back() {
|
|
back() {
|
|
|
- uni.navigateBack({
|
|
|
|
|
|
|
+ uni.switchTab({
|
|
|
url: '/pages/index/index'
|
|
url: '/pages/index/index'
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
async getInfo(id) {
|
|
async getInfo(id) {
|
|
|
-
|
|
|
|
|
const data = await saleordersendrecordInfo(id);
|
|
const data = await saleordersendrecordInfo(id);
|
|
|
-
|
|
|
|
|
if (data) {
|
|
if (data) {
|
|
|
this.info = data;
|
|
this.info = data;
|
|
|
this.info.sendId = this.info.id
|
|
this.info.sendId = this.info.id
|
|
|
this.info.sendNo = this.info.docNo
|
|
this.info.sendNo = this.info.docNo
|
|
|
this.info.docNo = ''
|
|
this.info.docNo = ''
|
|
|
this.info.id = ''
|
|
this.info.id = ''
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
},
|
|
},
|
|
|
- handleSubmit() {
|
|
|
|
|
|
|
+ async handleSubmit() {
|
|
|
if(!this.info.sendNo){
|
|
if(!this.info.sendNo){
|
|
|
uni.showModal({
|
|
uni.showModal({
|
|
|
title: `请选择发货单`,
|
|
title: `请选择发货单`,
|
|
@@ -100,12 +99,9 @@
|
|
|
icon: 'error',
|
|
icon: 'error',
|
|
|
confirmText: '确认',
|
|
confirmText: '确认',
|
|
|
showCancel: false, // 是否显示取消按钮,默认为 true
|
|
showCancel: false, // 是否显示取消按钮,默认为 true
|
|
|
- success: res => {
|
|
|
|
|
- if (res.confirm) {
|
|
|
|
|
- this.back()
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
|
|
+
|
|
|
})
|
|
})
|
|
|
|
|
+ return
|
|
|
}
|
|
}
|
|
|
if(!this.info.repliedFiles.length){
|
|
if(!this.info.repliedFiles.length){
|
|
|
uni.showModal({
|
|
uni.showModal({
|
|
@@ -114,35 +110,48 @@
|
|
|
icon: 'error',
|
|
icon: 'error',
|
|
|
confirmText: '确认',
|
|
confirmText: '确认',
|
|
|
showCancel: false, // 是否显示取消按钮,默认为 true
|
|
showCancel: false, // 是否显示取消按钮,默认为 true
|
|
|
- success: res => {
|
|
|
|
|
- if (res.confirm) {
|
|
|
|
|
- this.back()
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
|
|
+
|
|
|
})
|
|
})
|
|
|
|
|
+ return
|
|
|
}
|
|
}
|
|
|
- // this.currentRow.status = status
|
|
|
|
|
- // logistictraklistnoteUpdateAPI(this.currentRow)
|
|
|
|
|
- // uni.showModal({
|
|
|
|
|
- // title: `此工单执行成功`,
|
|
|
|
|
- // content: '',
|
|
|
|
|
- // confirmText: '确认',
|
|
|
|
|
- // showCancel: false, // 是否显示取消按钮,默认为 true
|
|
|
|
|
- // success: res => {
|
|
|
|
|
- // if (res.confirm) {
|
|
|
|
|
- // this.back()
|
|
|
|
|
- // }
|
|
|
|
|
- // }
|
|
|
|
|
- // })
|
|
|
|
|
|
|
+ try{
|
|
|
|
|
+ //后台不提供接口
|
|
|
|
|
+ let id = await saleordersendconfirmSave(this.info)
|
|
|
|
|
+ let data = await saleordersendconfirmInfo(id)
|
|
|
|
|
+ let list = await processInstancePage({pageNo: 1,pageSize: 1,reset: true,key: 'sales_sendconfirm_approve'})
|
|
|
|
|
+ let params = {
|
|
|
|
|
+ businessId: data.id,
|
|
|
|
|
+ businessKey : 'sales_sendconfirm_approve',
|
|
|
|
|
+ formCreateUserId: data.createUserId,
|
|
|
|
|
+ processDefinitionId: list?.list[0]?.processDefinition.id,
|
|
|
|
|
+ variables: {
|
|
|
|
|
+ businessCode: data.docNo
|
|
|
|
|
+ },
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ await processInstanceCreateAPI(params)
|
|
|
|
|
+ uni.showModal({
|
|
|
|
|
+ title: `提交成功`,
|
|
|
|
|
+ content: '',
|
|
|
|
|
+ confirmText: '确认',
|
|
|
|
|
+ showCancel: false, // 是否显示取消按钮,默认为 true
|
|
|
|
|
+ success:()=> {
|
|
|
|
|
+ this.back()
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
|
|
+ })
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+ }catch{
|
|
|
|
|
+
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
},
|
|
},
|
|
|
handleInvoiceList() {
|
|
handleInvoiceList() {
|
|
|
uni.navigateTo({
|
|
uni.navigateTo({
|
|
|
url: `/pages/invoiceConfirm/invoice`
|
|
url: `/pages/invoiceConfirm/invoice`
|
|
|
})
|
|
})
|
|
|
},
|
|
},
|
|
|
- handleAssign() {
|
|
|
|
|
- this.$refs.transferRef.open(this.currentRow)
|
|
|
|
|
- },
|
|
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
</script>
|
|
</script>
|