|
@@ -97,45 +97,47 @@ export default {
|
|
|
watch: {
|
|
|
id: {
|
|
|
handler(newVal, oldVal) {
|
|
|
- this.getorderDetail(data => {
|
|
|
- getDataDictionary({
|
|
|
- pageNum: 1,
|
|
|
- pageSize: -1,
|
|
|
- params: [
|
|
|
- { param: 'a.status', compare: '=', value: 'ON' },
|
|
|
- { param: 'a.dict_type', compare: '=', value: 'SALES_TYPE' }
|
|
|
- ]
|
|
|
- }).then(res => {
|
|
|
- this.SALES_TYPE_LIST = res.data.records
|
|
|
- .filter(item => {
|
|
|
- if (this.orderInfo?.isImportExcel) {
|
|
|
- return Number(item.dictCode) < 100
|
|
|
- } else {
|
|
|
- return Number(item.dictCode) >= 100
|
|
|
- }
|
|
|
+ if (newVal !== oldVal) {
|
|
|
+ this.getorderDetail(data => {
|
|
|
+ getDataDictionary({
|
|
|
+ pageNum: 1,
|
|
|
+ pageSize: -1,
|
|
|
+ params: [
|
|
|
+ { param: 'a.status', compare: '=', value: 'ON' },
|
|
|
+ { param: 'a.dict_type', compare: '=', value: 'SALES_TYPE' }
|
|
|
+ ]
|
|
|
+ }).then(res => {
|
|
|
+ this.SALES_TYPE_LIST = res.data.records
|
|
|
+ .filter(item => {
|
|
|
+ if (this.orderInfo?.isImportExcel) {
|
|
|
+ return Number(item.dictCode) < 100
|
|
|
+ } else {
|
|
|
+ return Number(item.dictCode) >= 100
|
|
|
+ }
|
|
|
+ })
|
|
|
+ .map(item => ({
|
|
|
+ value: Number(item.dictCode),
|
|
|
+ label: item.dictValue
|
|
|
+ }))
|
|
|
+ })
|
|
|
+ if (!!~[1, 2, 3].indexOf(this?.workOrderType)) {
|
|
|
+ this.$nextTick(() => {
|
|
|
+ // 获取地址信息
|
|
|
+ this.getinitlbslist()
|
|
|
+ // 获取可选师傅
|
|
|
+ this.getWorkers()
|
|
|
+ this.getWebsitFun()
|
|
|
+ })
|
|
|
+ } else if (this.workOrderType == 4) {
|
|
|
+ this.$nextTick(() => {
|
|
|
+ // 获取维保单详情
|
|
|
+ this.getWeiBaoDetail()
|
|
|
+ this.getWebsitFun()
|
|
|
})
|
|
|
- .map(item => ({
|
|
|
- value: Number(item.dictCode),
|
|
|
- label: item.dictValue
|
|
|
- }))
|
|
|
+ }
|
|
|
})
|
|
|
- if (!!~[1, 2, 3].indexOf(this?.workOrderType)) {
|
|
|
- this.$nextTick(() => {
|
|
|
- // 获取地址信息
|
|
|
- this.getinitlbslist()
|
|
|
- // 获取可选师傅
|
|
|
- this.getWorkers()
|
|
|
- this.getWebsitFun()
|
|
|
- })
|
|
|
- } else if (this.workOrderType == 4) {
|
|
|
- this.$nextTick(() => {
|
|
|
- // 获取维保单详情
|
|
|
- this.getWeiBaoDetail()
|
|
|
- this.getWebsitFun()
|
|
|
- })
|
|
|
- }
|
|
|
- })
|
|
|
- this.getOrderBaseLogList()
|
|
|
+ this.getOrderBaseLogList()
|
|
|
+ }
|
|
|
},
|
|
|
deep: true,
|
|
|
immediate: true
|