|
@@ -297,7 +297,8 @@ export default {
|
|
|
progressVisible:false,
|
|
|
siteid:JSON.parse(sessionStorage.getItem('active_account')).siteid,
|
|
|
jsDay:'',
|
|
|
- jsYcDay:''
|
|
|
+ jsYcDay:'',
|
|
|
+ days:""
|
|
|
}
|
|
|
},
|
|
|
methods:{
|
|
@@ -589,10 +590,11 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
})
|
|
|
- this.jsYcDay = res.total - this.jsDay
|
|
|
- if (this.jsYcDay >0){
|
|
|
- const dateAdd = this.addDaysToDate(date, this.jsYcDay)
|
|
|
- this.holidayS(now,dateAdd.toISOString().split('T')[0],Number(this.jsDay + this.jsYcDay),type,sa_orderitemsid)
|
|
|
+ this.days = res.total - this.jsDay
|
|
|
+ if (this.days >0){
|
|
|
+ this.jsYcDay = this.jsYcDay + this.days + this.jsDay
|
|
|
+ const dateAdd = this.addDaysToDate(date, this.days)
|
|
|
+ this.holidayS(now,dateAdd.toISOString().split('T')[0],Number(this.days),type,sa_orderitemsid)
|
|
|
|
|
|
}else {
|
|
|
if (type == '单'){
|
|
@@ -623,14 +625,17 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
})
|
|
|
- this.jsYcDay = res.total - (this.jsDay + this.jsYcDay)
|
|
|
- if (this.jsYcDay >0){
|
|
|
- const dateAdd = this.addDaysToDate(date, this.jsYcDay)
|
|
|
- if (type == '单'){
|
|
|
- this.dayChange(dateAdd.toISOString().split('T')[0],days,sa_orderitemsid)
|
|
|
- }else {
|
|
|
- this.daysChange(dateAdd.toISOString().split('T')[0],this.value3)
|
|
|
- }
|
|
|
+ this.days = res.total - this.jsYcDay
|
|
|
+ if (this.days >0){
|
|
|
+ this.jsYcDay = this.jsYcDay + this.days
|
|
|
+ const dateAdd = this.addDaysToDate(date, this.days)
|
|
|
+ this.holidayS(now,dateAdd.toISOString().split('T')[0],Number(this.days),type,sa_orderitemsid)
|
|
|
+ // if (type == '单'){
|
|
|
+ // this.dayChange(dateAdd.toISOString().split('T')[0],days,sa_orderitemsid)
|
|
|
+ // }else {
|
|
|
+ // this.daysChange(dateAdd.toISOString().split('T')[0],this.value3)
|
|
|
+ // }
|
|
|
+
|
|
|
}else {
|
|
|
if (type == '单'){
|
|
|
this.dayChange(date,days,sa_orderitemsid)
|
|
@@ -673,6 +678,8 @@ export default {
|
|
|
this.listData(this.param.content.pageNumber = 1)
|
|
|
},
|
|
|
setDeliveryDay(val,type,sa_orderitemsid){
|
|
|
+ this.jsYcDay = 0
|
|
|
+ this.jsDay = 0
|
|
|
let nowDate = new Date()
|
|
|
let year = nowDate.getFullYear()
|
|
|
let month = (nowDate.getMonth() + 1) > 10 ? nowDate.getMonth() + 1 : '0' + (nowDate.getMonth() + 1)
|