|
@@ -36,8 +36,8 @@
|
|
:disabled="disabled"
|
|
:disabled="disabled"
|
|
type="date"
|
|
type="date"
|
|
placeholder="请选择应收账款起始日"
|
|
placeholder="请选择应收账款起始日"
|
|
- @change="getEndDate"
|
|
|
|
value-format="yyyy-MM-dd"
|
|
value-format="yyyy-MM-dd"
|
|
|
|
+ @change="getEndDate"
|
|
>
|
|
>
|
|
</el-date-picker>
|
|
</el-date-picker>
|
|
</el-form-item>
|
|
</el-form-item>
|
|
@@ -84,7 +84,7 @@
|
|
incomeExpenditurePlanList: ruleForm.incomeExpenditurePlanList || [],
|
|
incomeExpenditurePlanList: ruleForm.incomeExpenditurePlanList || [],
|
|
planIrrStr: ruleForm.planIrrStr
|
|
planIrrStr: ruleForm.planIrrStr
|
|
}"
|
|
}"
|
|
- :disabled="disabled"
|
|
|
|
|
|
+ :disabled="disabled"
|
|
@getTrrData="getTrrData"
|
|
@getTrrData="getTrrData"
|
|
>
|
|
>
|
|
</revenue-expenditure-plan>
|
|
</revenue-expenditure-plan>
|
|
@@ -103,7 +103,7 @@
|
|
|
|
|
|
<script>
|
|
<script>
|
|
import { getLimitExpenditureDatails, getExpenditurePlan, getTrr, reviewQuotaDisburseSubmit } from '@/api/financingManage'
|
|
import { getLimitExpenditureDatails, getExpenditurePlan, getTrr, reviewQuotaDisburseSubmit } from '@/api/financingManage'
|
|
-import { parseTime } from "@/utils";
|
|
|
|
|
|
+import { parseTime } from '@/utils'
|
|
export default {
|
|
export default {
|
|
components: {
|
|
components: {
|
|
FinancingInfo: () => import('./components/FinancingInfo'),
|
|
FinancingInfo: () => import('./components/FinancingInfo'),
|
|
@@ -199,7 +199,7 @@ export default {
|
|
const { startDate, term } = this.ruleForm
|
|
const { startDate, term } = this.ruleForm
|
|
if (startDate && term) {
|
|
if (startDate && term) {
|
|
const endDateGetTime = new Date(`${startDate} 00:00:00`).getTime() + (3600 * 1000 * 24 * term)
|
|
const endDateGetTime = new Date(`${startDate} 00:00:00`).getTime() + (3600 * 1000 * 24 * term)
|
|
- this.ruleForm.endDate = parseTime(endDateGetTime)
|
|
|
|
|
|
+ this.ruleForm.endDate = parseTime(endDateGetTime)
|
|
}
|
|
}
|
|
},
|
|
},
|
|
async automaticGeneration() {
|
|
async automaticGeneration() {
|
|
@@ -223,18 +223,18 @@ export default {
|
|
// const { id } = this.$route.params
|
|
// const { id } = this.$route.params
|
|
const { taskId } = this.$route.query
|
|
const { taskId } = this.$route.query
|
|
var params = {
|
|
var params = {
|
|
- Loading: true,
|
|
|
|
|
|
+ Loading: true
|
|
}
|
|
}
|
|
if (this.ruleForm.approvalConclusion === 'pass') {
|
|
if (this.ruleForm.approvalConclusion === 'pass') {
|
|
- if(type === 'submit') {
|
|
|
|
|
|
+ if (type === 'submit') {
|
|
const { startDate, endDate } = this.ruleForm
|
|
const { startDate, endDate } = this.ruleForm
|
|
- if(!startDate) {
|
|
|
|
|
|
+ if (!startDate) {
|
|
this.$message.warning('请选择应收账款起始日')
|
|
this.$message.warning('请选择应收账款起始日')
|
|
- return
|
|
|
|
|
|
+ return
|
|
}
|
|
}
|
|
- if(!endDate) {
|
|
|
|
|
|
+ if (!endDate) {
|
|
this.$message.warning('请选择应收账款结束日')
|
|
this.$message.warning('请选择应收账款结束日')
|
|
- return
|
|
|
|
|
|
+ return
|
|
}
|
|
}
|
|
}
|
|
}
|
|
const financingInfo = await this.$refs.financingInfo.getParams(type)
|
|
const financingInfo = await this.$refs.financingInfo.getParams(type)
|
|
@@ -254,11 +254,11 @@ export default {
|
|
...assignment,
|
|
...assignment,
|
|
taskId
|
|
taskId
|
|
}
|
|
}
|
|
- if(!assignment.reviewTransferReceivable.confirm) {
|
|
|
|
|
|
+ if (!assignment.reviewTransferReceivable.confirm) {
|
|
params.reviewBasicContractList = []
|
|
params.reviewBasicContractList = []
|
|
}
|
|
}
|
|
- }else {
|
|
|
|
- const { approvalConclusion, approvalComments,financingBasicInfoId, id } = this.ruleForm
|
|
|
|
|
|
+ } else {
|
|
|
|
+ const { approvalConclusion, approvalComments, financingBasicInfoId, id } = this.ruleForm
|
|
params = {
|
|
params = {
|
|
...params,
|
|
...params,
|
|
approvalConclusion,
|
|
approvalConclusion,
|
|
@@ -271,30 +271,30 @@ export default {
|
|
return params
|
|
return params
|
|
},
|
|
},
|
|
async submit(type) {
|
|
async submit(type) {
|
|
-
|
|
|
|
- if(type === 'temp') {
|
|
|
|
- let data = await this.getParams(type)
|
|
|
|
|
|
+ if (type === 'temp') {
|
|
|
|
+ const data = await this.getParams(type)
|
|
data.visible = type !== 'temp'
|
|
data.visible = type !== 'temp'
|
|
reviewQuotaDisburseSubmit(data).then(() => {
|
|
reviewQuotaDisburseSubmit(data).then(() => {
|
|
this.$message.warning('暂存成功')
|
|
this.$message.warning('暂存成功')
|
|
this.$router.go(-1)
|
|
this.$router.go(-1)
|
|
})
|
|
})
|
|
- }else {
|
|
|
|
- this.$refs.ruleForm.validate(async (valid) => {
|
|
|
|
- if(valid) {
|
|
|
|
- let data = await this.getParams(type)
|
|
|
|
|
|
+ } else {
|
|
|
|
+ await this.automaticGeneration()
|
|
|
|
+ this.$refs.ruleForm.validate(async(valid) => {
|
|
|
|
+ if (valid) {
|
|
|
|
+ const data = await this.getParams(type)
|
|
data.visible = type !== 'temp'
|
|
data.visible = type !== 'temp'
|
|
- reviewQuotaDisburseSubmit(data).then(() => {
|
|
|
|
- this.$message.warning('提交成功')
|
|
|
|
- this.$router.go(-1)
|
|
|
|
- })
|
|
|
|
- }else {
|
|
|
|
|
|
+ setTimeout(() => {
|
|
|
|
+ reviewQuotaDisburseSubmit(data).then(() => {
|
|
|
|
+ this.$message.warning('提交成功')
|
|
|
|
+ this.$router.go(-1)
|
|
|
|
+ })
|
|
|
|
+ }, 500)
|
|
|
|
+ } else {
|
|
return false
|
|
return false
|
|
}
|
|
}
|
|
-
|
|
|
|
})
|
|
})
|
|
}
|
|
}
|
|
-
|
|
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|