追述加工国税

This commit is contained in:
zhangdingyu
2019-12-31 17:04:22 +08:00
parent e39e3d31b6
commit d1547f2318
3 changed files with 24 additions and 16 deletions

View File

@@ -422,14 +422,22 @@ export default {
},
watch: {
// 如果路由有变化,会再次执行该方法
'$route': {
handler(route) {
const _this = this
if (route.name === 'InitialProduction') {
_this.typeChange()
}
'$route'(to) {
const _this = this
console.log(to, 2222)
if (to.name === 'InitialProduction') {
_this.typeChange()
}
}
// '$route': {
// handler(route) {
// const _this = this
// console.log(route.name)
// if (route.name === 'InitialProduction') {
// _this.typeChange()
// }
// }
// }
},
created() {
// this.typeChange()
@@ -503,10 +511,12 @@ export default {
})
},
typeChange() {
console.log(Cookie.get('machineValue'), 1111111)
this.toolNumValue = ''
this.toolNum = []
this.NumValue = ''
this.Num = []
if (Cookie.get('machineValue') !== undefined) {
this.toolNumValue = ''
this.NumValue = ''
this.Num = []
getToolNum().then(response => {
for (let i = 0; i < response.data.length; i++) {
this.toolNum.push({
@@ -524,9 +534,6 @@ export default {
Cookie.remove('group')
})
} else {
this.toolNumValue = ''
this.NumValue = ''
this.Num = []
getToolNum().then(response => {
for (let i = 0; i < response.data.length; i++) {
this.toolNum.push({