|
@@ -128,7 +128,7 @@
|
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
<el-dialog title="导入箱档案" append-to-body :visible.sync="excelBox" width="555px" :close-on-click-modal="false"
|
|
<el-dialog title="导入箱档案" append-to-body :visible.sync="excelBox" width="555px" :close-on-click-modal="false"
|
|
|
v-dialog-drag>
|
|
v-dialog-drag>
|
|
|
- <avue-form :option="excelOption" v-model="excelForm" table-loading="excelLoading"
|
|
|
|
|
|
|
+ <avue-form v-if="excelBox" :option="excelOption" v-model="excelForm" table-loading="excelLoading"
|
|
|
:upload-before="uploadBefore" :upload-after="uploadAfter">
|
|
:upload-before="uploadBefore" :upload-after="uploadAfter">
|
|
|
<template slot="excelTemplate">
|
|
<template slot="excelTemplate">
|
|
|
<el-button type="primary" @click="derivation">
|
|
<el-button type="primary" @click="derivation">
|
|
@@ -223,7 +223,7 @@ export default {
|
|
|
selectionList: [],
|
|
selectionList: [],
|
|
|
optionStateTwo: {
|
|
optionStateTwo: {
|
|
|
menuBtn: false,
|
|
menuBtn: false,
|
|
|
- span: 24,
|
|
|
|
|
|
|
+ span: 12,
|
|
|
column: [{
|
|
column: [{
|
|
|
label: '起租日期',
|
|
label: '起租日期',
|
|
|
prop: 'rentDate',
|
|
prop: 'rentDate',
|
|
@@ -770,14 +770,14 @@ export default {
|
|
|
if (type === '起租') {
|
|
if (type === '起租') {
|
|
|
this.optionState = this.optionStateTwo
|
|
this.optionState = this.optionStateTwo
|
|
|
}else if (type === '退租') {
|
|
}else if (type === '退租') {
|
|
|
- this.optionState = this.optionStateTwo
|
|
|
|
|
|
|
+ this.optionState = this.optionStateThree
|
|
|
this.formState.rentDate = dateFormat(new Date(), "yyyy-MM-dd") + " 23:59:59"
|
|
this.formState.rentDate = dateFormat(new Date(), "yyyy-MM-dd") + " 23:59:59"
|
|
|
} else if (type === '计算租金'){
|
|
} else if (type === '计算租金'){
|
|
|
this.optionState = this.optionStateFour
|
|
this.optionState = this.optionStateFour
|
|
|
for (let item of this.selectionList) {
|
|
for (let item of this.selectionList) {
|
|
|
for (let li of this.selectionList) {
|
|
for (let li of this.selectionList) {
|
|
|
if (item.rentEndDate !== li.rentEndDate) {
|
|
if (item.rentEndDate !== li.rentEndDate) {
|
|
|
- return this.$message.error("当前租金期间不一样,请重新选择")
|
|
|
|
|
|
|
+ return this.$message.error(`${item.code} - ${item.rentEndDate},选择重复请重新选择`)
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
@@ -785,6 +785,13 @@ export default {
|
|
|
const endDate = new Date(date.getFullYear(), date.getMonth() + 1, 0);
|
|
const endDate = new Date(date.getFullYear(), date.getMonth() + 1, 0);
|
|
|
this.formState.rentStartDate = this.selectionList[0].rentEndDate
|
|
this.formState.rentStartDate = this.selectionList[0].rentEndDate
|
|
|
this.formState.rentCalculationDate = dateFormat(endDate, "yyyy-MM-dd") + " 23:59:59"
|
|
this.formState.rentCalculationDate = dateFormat(endDate, "yyyy-MM-dd") + " 23:59:59"
|
|
|
|
|
+ if (this.selectionList[0].rentEndDate){
|
|
|
|
|
+ let curDate = new Date(this.selectionList[0].rentEndDate);
|
|
|
|
|
+ let endDateTime = new Date((curDate/1000+86400)*1000)
|
|
|
|
|
+ this.formState.rentStartDate = new Date((curDate/1000+86400)*1000)
|
|
|
|
|
+ const endDateTwo = new Date(endDateTime.getFullYear(), endDateTime.getMonth() + 1, 0);
|
|
|
|
|
+ this.formState.rentCalculationDate = dateFormat(endDateTwo, "yyyy-MM-dd") + " 23:59:59"
|
|
|
|
|
+ }
|
|
|
}else if(type === '撤销租金'){
|
|
}else if(type === '撤销租金'){
|
|
|
return this.$confirm('此操作将撤销租金并删除费用, 是否继续?', '提示', {
|
|
return this.$confirm('此操作将撤销租金并删除费用, 是否继续?', '提示', {
|
|
|
confirmButtonText: '确定',
|
|
confirmButtonText: '确定',
|