|
@@ -1258,7 +1258,7 @@ export default {
|
|
handler() {
|
|
handler() {
|
|
// 数组变化开启自动保存
|
|
// 数组变化开启自动保存
|
|
this.startAutoSave()
|
|
this.startAutoSave()
|
|
- }
|
|
|
|
|
|
+ },
|
|
},
|
|
},
|
|
// 监听 eqptImpPageData 的变化
|
|
// 监听 eqptImpPageData 的变化
|
|
eqptImpPageData: {
|
|
eqptImpPageData: {
|
|
@@ -1266,7 +1266,7 @@ export default {
|
|
handler() {
|
|
handler() {
|
|
// 数组变化开启自动保存
|
|
// 数组变化开启自动保存
|
|
this.startAutoSaveImp()
|
|
this.startAutoSaveImp()
|
|
- }
|
|
|
|
|
|
+ },
|
|
},
|
|
},
|
|
// 监听 eqptNonSPageData 的变化
|
|
// 监听 eqptNonSPageData 的变化
|
|
eqptNonSPageData: {
|
|
eqptNonSPageData: {
|
|
@@ -1274,8 +1274,8 @@ export default {
|
|
handler() {
|
|
handler() {
|
|
// 数组变化开启自动保存
|
|
// 数组变化开启自动保存
|
|
this.startAutoSaveNonS()
|
|
this.startAutoSaveNonS()
|
|
- }
|
|
|
|
- }
|
|
|
|
|
|
+ },
|
|
|
|
+ },
|
|
},
|
|
},
|
|
created() {
|
|
created() {
|
|
this.getBaseInfo()
|
|
this.getBaseInfo()
|
|
@@ -1292,8 +1292,8 @@ export default {
|
|
// 激活倒计时
|
|
// 激活倒计时
|
|
this.autoSaveTimer = setTimeout(() => {
|
|
this.autoSaveTimer = setTimeout(() => {
|
|
// 倒计时结束,执行方法
|
|
// 倒计时结束,执行方法
|
|
- this.autoSaveTimer = null;
|
|
|
|
- this.autoSaveBatch();
|
|
|
|
|
|
+ this.autoSaveTimer = null
|
|
|
|
+ this.autoSaveBatch()
|
|
}, this.countdownDuration)
|
|
}, this.countdownDuration)
|
|
}
|
|
}
|
|
},
|
|
},
|
|
@@ -1306,8 +1306,8 @@ export default {
|
|
// 激活倒计时
|
|
// 激活倒计时
|
|
this.autoSaveImpTimer = setTimeout(() => {
|
|
this.autoSaveImpTimer = setTimeout(() => {
|
|
// 倒计时结束,执行方法
|
|
// 倒计时结束,执行方法
|
|
- this.autoSaveImpTimer = null;
|
|
|
|
- this.autoSaveBatchImp();
|
|
|
|
|
|
+ this.autoSaveImpTimer = null
|
|
|
|
+ this.autoSaveBatchImp()
|
|
}, this.countdownDuration)
|
|
}, this.countdownDuration)
|
|
}
|
|
}
|
|
},
|
|
},
|
|
@@ -1320,8 +1320,8 @@ export default {
|
|
// 激活倒计时
|
|
// 激活倒计时
|
|
this.autoSaveNonSTimer = setTimeout(() => {
|
|
this.autoSaveNonSTimer = setTimeout(() => {
|
|
// 倒计时结束,执行方法
|
|
// 倒计时结束,执行方法
|
|
- this.autoSaveNonSTimer = null;
|
|
|
|
- this.autoSaveBatchNonS();
|
|
|
|
|
|
+ this.autoSaveNonSTimer = null
|
|
|
|
+ this.autoSaveBatchNonS()
|
|
}, this.countdownDuration)
|
|
}, this.countdownDuration)
|
|
}
|
|
}
|
|
},
|
|
},
|
|
@@ -1368,30 +1368,30 @@ export default {
|
|
// tab切换时保存测算信息销毁计时器
|
|
// tab切换时保存测算信息销毁计时器
|
|
if (this.activeName === 'all') {
|
|
if (this.activeName === 'all') {
|
|
this.getEqptDataPage()
|
|
this.getEqptDataPage()
|
|
- clearTimeout(this.autoSaveImpTimer);
|
|
|
|
- this.autoSaveImpTimer = null;
|
|
|
|
- clearTimeout(this.autoSaveNonSTimer);
|
|
|
|
- this.autoSaveNonSTimer = null;
|
|
|
|
- this.autoSaveBatchImp();
|
|
|
|
- this.autoSaveBatchNonS();
|
|
|
|
|
|
+ clearTimeout(this.autoSaveImpTimer)
|
|
|
|
+ this.autoSaveImpTimer = null
|
|
|
|
+ clearTimeout(this.autoSaveNonSTimer)
|
|
|
|
+ this.autoSaveNonSTimer = null
|
|
|
|
+ this.autoSaveBatchImp()
|
|
|
|
+ this.autoSaveBatchNonS()
|
|
}
|
|
}
|
|
if (this.activeName === 'imported') {
|
|
if (this.activeName === 'imported') {
|
|
this.getImpEqptDataPage()
|
|
this.getImpEqptDataPage()
|
|
- clearTimeout(this.autoSaveTimer);
|
|
|
|
- this.autoSaveTimer = null;
|
|
|
|
- clearTimeout(this.autoSaveNonSTimer);
|
|
|
|
- this.autoSaveNonSTimer = null;
|
|
|
|
- this.autoSaveBatch();
|
|
|
|
- this.autoSaveBatchNonS();
|
|
|
|
|
|
+ clearTimeout(this.autoSaveTimer)
|
|
|
|
+ this.autoSaveTimer = null
|
|
|
|
+ clearTimeout(this.autoSaveNonSTimer)
|
|
|
|
+ this.autoSaveNonSTimer = null
|
|
|
|
+ this.autoSaveBatch()
|
|
|
|
+ this.autoSaveBatchNonS()
|
|
}
|
|
}
|
|
if (this.activeName === 'nonStandard') {
|
|
if (this.activeName === 'nonStandard') {
|
|
this.getNonSEqptDataPage()
|
|
this.getNonSEqptDataPage()
|
|
- clearTimeout(this.autoSaveImpTimer);
|
|
|
|
- this.autoSaveImpTimer = null;
|
|
|
|
- clearTimeout(this.autoSaveTimer);
|
|
|
|
- this.autoSaveTimer = null;
|
|
|
|
- this.autoSaveBatchImp();
|
|
|
|
- this.autoSaveBatch();
|
|
|
|
|
|
+ clearTimeout(this.autoSaveImpTimer)
|
|
|
|
+ this.autoSaveImpTimer = null
|
|
|
|
+ clearTimeout(this.autoSaveTimer)
|
|
|
|
+ this.autoSaveTimer = null
|
|
|
|
+ this.autoSaveBatchImp()
|
|
|
|
+ this.autoSaveBatch()
|
|
}
|
|
}
|
|
},
|
|
},
|
|
// 新增机器设备信息
|
|
// 新增机器设备信息
|
|
@@ -1523,10 +1523,10 @@ export default {
|
|
message: '数据载入成功!',
|
|
message: '数据载入成功!',
|
|
type: 'success',
|
|
type: 'success',
|
|
})
|
|
})
|
|
- this.autoSaveAtive = true;
|
|
|
|
|
|
+ this.autoSaveAtive = true
|
|
})
|
|
})
|
|
}
|
|
}
|
|
- this.getEqptLifeIfrRefs();
|
|
|
|
|
|
+ this.getEqptLifeIfrRefs()
|
|
})
|
|
})
|
|
},
|
|
},
|
|
// 分页查询进口设备信息
|
|
// 分页查询进口设备信息
|
|
@@ -1548,7 +1548,7 @@ export default {
|
|
message: '数据载入成功!',
|
|
message: '数据载入成功!',
|
|
type: 'success',
|
|
type: 'success',
|
|
})
|
|
})
|
|
- this.autoSaveImpAtive = true;
|
|
|
|
|
|
+ this.autoSaveImpAtive = true
|
|
})
|
|
})
|
|
}
|
|
}
|
|
})
|
|
})
|
|
@@ -1572,7 +1572,7 @@ export default {
|
|
message: '数据载入成功!',
|
|
message: '数据载入成功!',
|
|
type: 'success',
|
|
type: 'success',
|
|
})
|
|
})
|
|
- this.autoSaveNonSAtive = true;
|
|
|
|
|
|
+ this.autoSaveNonSAtive = true
|
|
})
|
|
})
|
|
}
|
|
}
|
|
this.getEqptGnEvpList()
|
|
this.getEqptGnEvpList()
|
|
@@ -2041,6 +2041,35 @@ export default {
|
|
// 动态赋值,属性名由变量 propName 指定
|
|
// 动态赋值,属性名由变量 propName 指定
|
|
item[propName] = value
|
|
item[propName] = value
|
|
})
|
|
})
|
|
|
|
+ // 主要是解决批量赋值时对应的@change事件不触发
|
|
|
|
+ switch (propName) {
|
|
|
|
+ // 批量赋值给作价方法的特殊处理
|
|
|
|
+ case 'valuationMethod':
|
|
|
|
+ if (value === '物价指数调整法') {
|
|
|
|
+ this.eqptPageData.forEach((item) => {
|
|
|
|
+ // 动态赋值,属性名由变量 propName 指定
|
|
|
|
+ const date = new Date(item.purchaseDate)
|
|
|
|
+ let year = date.getFullYear().toString()
|
|
|
|
+ const params = { ppiName: null, ppiType: null }
|
|
|
|
+ params.ppiName = year
|
|
|
|
+ params.ppiType = '通用设备制造业'
|
|
|
|
+ getPPIByNameType(params).then((res) => {
|
|
|
|
+ if (res.data && res.data.ppi) {
|
|
|
|
+ item.inquiryBasis = '(' + res.data.id + ')' + res.data.ppiName + '年:' + res.data.ppi
|
|
|
|
+ this.countPrice(item)
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ break
|
|
|
|
+ // 经济使用年限和尚可使用年限
|
|
|
|
+ case 'economicServiceLife':
|
|
|
|
+ case 'remainingUsefulLife':
|
|
|
|
+ this.eqptPageData.forEach((item) => {
|
|
|
|
+ this.countDepreciationRate(item);
|
|
|
|
+ })
|
|
|
|
+ break
|
|
|
|
+ }
|
|
}
|
|
}
|
|
if (this.activeName === 'imported') {
|
|
if (this.activeName === 'imported') {
|
|
this.eqptImpPageData.forEach((item) => {
|
|
this.eqptImpPageData.forEach((item) => {
|