This commit is contained in:
liushuai
2019-10-31 08:11:24 +08:00
parent d3ce0baf0b
commit ca02868500
15 changed files with 563 additions and 435 deletions

View File

@@ -40,7 +40,7 @@
</el-table-column>
<el-table-column label="请款时间" prop="。请款时间" align="center" min-width="150">
<template slot-scope="scope">
{{ scope.row.请款时间 }}
{{ scope.row.请款时间 ? scope.row.请款时间.split(' ')[0] : '-' }}
</template>
</el-table-column>
<el-table-column label="请款人" prop="姓名" align="center" min-width="80">
@@ -227,7 +227,7 @@
</el-table-column>
<el-table-column label="合同总额" align="center" width="80" prop="合同总额">
<template slot-scope="scope">
{{ scope.row.合同总额 }}
{{ scope.row.合同总额 ? parseInt(scope.row.合同总额 * 100)/100 : '-' }}
</template>
</el-table-column>
<el-table-column label="已付金额" align="center" width="80" prop="已付金额">
@@ -242,7 +242,7 @@
</el-table-column>
<el-table-column label="请款金额" align="center" min-width="120" prop="请款金额">
<template slot-scope="scope">
<el-input-number :precision="2" :max="scope.row.合同总额 - scope.row.已付金额 - scope.row.申请中金额" :disabled="(scope.row.合同总额 - scope.row.已付金额 - scope.row.申请中金额) === 0" v-model="scope.row.请款金额" size="mini" controls-position="right" style="width: 100%;"/>
<el-input-number :precision="2" :max="scope.row.合同总额 - scope.row.已付金额 - scope.row.申请中金额" :disabled="(scope.row.合同总额 - scope.row.已付金额 - scope.row.申请中金额) === 0" :min="0" v-model="scope.row.请款金额" size="mini" controls-position="right" style="width: 100%;"/>
</template>
</el-table-column>
</el-table>
@@ -468,7 +468,8 @@ export default {
})
this.tableData01.map(v => {
this.$set(v, '请款金额', 0)
v.请款金额 = v.合同总额 - v.已付金额 - v.申请中金额
console.log(v.合同总额, v.已付金额, v.申请中金额)
v.请款金额 = v.合同总额 - v.已付金额
return v
})
})
@@ -488,6 +489,8 @@ export default {
this.sumGroup = []
console.log(val)
for (let i = 0; i < val.length; i++) {
console.log(val[i].请款金额)
console.log(parseFloat(val[i].请款金额), 123)
this.SUM += parseFloat(val[i].请款金额)
this.contractGroup.push(val[i].离线合同流水号)
this.sumGroup.push(val[i].请款金额)

View File

@@ -1,62 +1,5 @@
<template>
<div class="app-container">
<el-card>
<div slot="header">
<span>时间段:</span>
<el-date-picker
v-model="dateRange"
:picker-options="pickerOptions"
size="small"
type="daterange"
align="center"
value-format="yyyy-MM-dd"
format="yyyy-MM-dd"
range-separator=""
style="width:300px"
start-placeholder="开始日期"
end-placeholder="结束日期"/>
<el-button type="success" size="small" icon="el-icon-search" style="margin-left: 10px" @click="searchTable0()">查询</el-button>
</div>
<h3>付款计划</h3>
<el-table :data="tableData0" size="mini" border style="max-height: 250px;" height="250px" highlight-current-row @row-click="searchContract">
<el-table-column label="计划状态" prop="计划付款日期" width="100" align="center">
<template slot-scope="scope">
<el-tag v-if="timeToStamp(scope.row.计划付款日期) <= getDate" type="danger" size="small">已拖期</el-tag>
<el-tag v-if="timeToStamp(scope.row.计划付款日期) > getDate" type="success" size="small">未拖期</el-tag>
</template>
</el-table-column>
<el-table-column label="计划付款日期" min-width="100" align="center">
<template slot-scope="scope">
{{ scope.row.计划付款日期.split(' ')[0] }}
</template>
</el-table-column>
<el-table-column label="计划付款金额" min-width="100" align="center">
<template slot-scope="scope">
{{ scope.row.计划付款金额 }}
</template>
</el-table-column>
<el-table-column label="计划付款备注" min-width="100" align="center">
<template slot-scope="scope">
{{ scope.row.计划付款备注 }}
</template>
</el-table-column>
<el-table-column label="采购合同编号" prop="采购合同编号" min-width="100" align="center" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.采购合同编号 }}
</template>
</el-table-column>
<el-table-column label="采购合同名称" prop="采购合同名称" min-width="100" align="center">
<template slot-scope="scope">
{{ scope.row.采购合同名称 }}
</template>
</el-table-column>
<el-table-column label="供应商" prop="供应商名称" min-width="150" align="center">
<template slot-scope="scope">
{{ scope.row.供应商名称 }}
</template>
</el-table-column>
</el-table>
</el-card>
<el-card>
<div slot="header">
@@ -75,14 +18,6 @@
style="margin-left: 10px"
@click="pageCurrent1=1;pageSize1=10;total1=0;searchTable1()">查询</el-button>
<el-button type="primary" size="small" icon="el-icon-goods" style="" @click="requestFund">请款</el-button>
<div>
<span v-show="supplierValue">累计合同总额</span>
<el-input v-show="supplierValue" v-model="totalSum" size="mini" style="width: 100px;" readonly/>
<span v-show="supplierValue">累计付款</span>
<el-input v-show="supplierValue" v-model="totalPay" size="mini" style="width: 100px;" readonly/>
<span v-show="supplierValue">累计欠款</span>
<el-input v-show="supplierValue" v-model="totalDebt" size="mini" style="width: 100px;" readonly/>
</div>
</div>
<h3>请款表</h3>
<el-table v-loading="" :data="tableData1" border style="max-height: 500px;" height="500px" size="mini" stripe>
@@ -93,7 +28,7 @@
</el-table-column>
<el-table-column label="请款时间" prop="请款时间" align="center" min-width="150">
<template slot-scope="scope">
{{ scope.row.请款时间 }}
{{ scope.row.请款时间 ? scope.row.请款时间.split(' ')[0] : '-' }}
</template>
</el-table-column>
<el-table-column label="请款人" prop="姓名" align="center" min-width="80">
@@ -184,7 +119,7 @@
</div>
</el-card>
<el-dialog :visible.sync="dialogVisible2" title="采购合同请款" center style="min-height: 300px" width="1000px">
<el-dialog v-el-drag-dialog :visible.sync="dialogVisible2" title="采购合同请款" center style="min-height: 300px" width="1000px">
<span>供应商</span>
<el-select v-model="supplierValue" placeholder="供应商" filterable clearable size="small">
<el-option
@@ -218,7 +153,7 @@
</el-table-column>
<el-table-column label="合同总额" align="center" width="80" prop="合同总额">
<template slot-scope="scope">
{{ scope.row.合同总额 }}
{{ scope.row.合同总额 ? parseInt(scope.row.合同总额 * 100)/100 : '-' }}
</template>
</el-table-column>
<el-table-column label="已付金额" align="center" width="80" prop="已付金额">
@@ -233,7 +168,7 @@
</el-table-column>
<el-table-column label="请款金额" align="center" min-width="120" prop="请款金额">
<template slot-scope="scope">
<el-input-number :max="scope.row.合同总额 - scope.row.已付金额 - scope.row.申请中金额" :disabled="(scope.row.合同总额 - scope.row.已付金额 - scope.row.申请中金额) === 0" v-model="scope.row.请款金额" :precision="2" size="mini" controls-position="right" style="width: 100%;"/>
<el-input-number :max="scope.row.合同总额 - scope.row.已付金额 - scope.row.申请中金额" :disabled="(scope.row.合同总额 - scope.row.已付金额 - scope.row.申请中金额) === 0" :min="0" v-model="scope.row.请款金额" :precision="2" size="mini" controls-position="right" style="width: 100%;"/>
</template>
</el-table-column>
</el-table>