刘璐珈
This commit is contained in:
@@ -40,6 +40,11 @@
|
||||
<!-- placeholder="请选择结束日期"/>-->
|
||||
<el-button type="primary" icon="el-icon-search" size="small" style="margin-left: 10px" plain @click="PageSize = 30;PageCurrent = 1;fetchTableData1()">查询</el-button>
|
||||
<el-button type="distribution" icon="el-icon-circle-plus-outline" size="small" style="margin-left: 10px;margin-right: 15px" @click="addBidBond();flag1 = 2">保证金</el-button>
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="导出" placement="top">
|
||||
<div style="display: inline-block">
|
||||
<el-button type="primary" plain class="el-icon-download" size="small" style="margin: 10px 0 0 600px" @click="exportExcel">导出</el-button>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
</el-card>
|
||||
|
||||
<!--投标保证金表格-->
|
||||
@@ -71,27 +76,12 @@
|
||||
{{ scope.row.招标企业 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="项目名称" prop="项目名称" width="160" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.项目名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!--<el-table-column align="center" label="联系人" width="80">-->
|
||||
<!--<template slot-scope="scope">-->
|
||||
<!--{{ scope.row.联系人 }}-->
|
||||
<!--</template>-->
|
||||
<!--</el-table-column>-->
|
||||
<!--<el-table-column align="center" label="联系电话" width="100">-->
|
||||
<!--<template slot-scope="scope">-->
|
||||
<!--{{ scope.row.联系电话 }}-->
|
||||
<!--</template>-->
|
||||
<!--</el-table-column>-->
|
||||
<el-table-column align="center" label="保证金金额(万元)" width="100">
|
||||
<template slot-scope="scope">
|
||||
<span style="width: 80px" size="mini">{{ Number(scope.row.保证金金额).toFixed(2) }}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="投标日期" width="86">
|
||||
<el-table-column align="center" label="缴纳时间" width="86">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.投标日期.substring(0, scope.row.投标日期.length - 8) }}
|
||||
</template>
|
||||
@@ -116,7 +106,7 @@
|
||||
{{ Number(scope.row.应收回金额).toFixed(2) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="实收回(万元)" width="80">
|
||||
<el-table-column align="center" label="已收回(万元)" width="80">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="parseInt(scope.row.是否收回) === 2" size="mini" type="success" style="width: 66px">{{ scope.row.应收回金额 }}</span>
|
||||
<span v-else slot="reference" type="danger" size="mini" style="width: 66px">未收回</span>
|
||||
@@ -151,6 +141,21 @@
|
||||
<!--<el-tag v-else-if="scope.row.预计收回日期!==''&&scope.row.预计收回日期!==null&&parseInt(scope.row.状态) ===2" slot="reference" type="danger" size="mini" style="width: 66px">已拖期</el-tag>-->
|
||||
<!--</template>-->
|
||||
<!--</el-table-column>-->
|
||||
<el-table-column align="center" label="项目名称" prop="项目名称" width="160" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.项目名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="联系人" width="80">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.联系人 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="联系电话" width="100">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.联系电话 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="备注" width="100px" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.备注 }}
|
||||
@@ -336,14 +341,14 @@
|
||||
</el-row>
|
||||
<el-row>
|
||||
<el-col :span="12">
|
||||
<el-form-item label="投标日期" prop="投标日期">
|
||||
<el-form-item label="缴纳时间" prop="投标日期">
|
||||
<el-date-picker
|
||||
v-model="form2.投标日期"
|
||||
style="width: 200px;"
|
||||
value-format="yyyy-MM-dd"
|
||||
size="small"
|
||||
type="date"
|
||||
placeholder="投标日期"/>
|
||||
placeholder="缴纳时间"/>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="12">
|
||||
@@ -455,7 +460,8 @@
|
||||
|
||||
<script>
|
||||
import elInput from 'element-ui/packages/input'
|
||||
import { initType, selectBidBond, getTree, tree, getTablePeople, TakeBack, addBidBond, editBidBond, delBidBond, winningBid, executionProgressID, intProject, submitPerformanceBond } from '@/api/MarketingCenter/BidBond'
|
||||
import { getNowShotTime } from '@/utils/tool'
|
||||
import { initType, selectBidBond, getTree, tree, getTablePeople, TakeBack, addBidBond, editBidBond, delBidBond, winningBid, executionProgressID, intProject, submitPerformanceBond, selectBidBond_excel } from '@/api/MarketingCenter/BidBond'
|
||||
export default {
|
||||
components: {
|
||||
elInput
|
||||
@@ -613,6 +619,79 @@ export default {
|
||||
this.fetchTableData1()
|
||||
},
|
||||
methods: {
|
||||
formatJson(filterVal, jsonData) {
|
||||
return jsonData.map(v => filterVal.map(j => {
|
||||
return v[j]
|
||||
}))
|
||||
},
|
||||
exportExcel() {
|
||||
if (this.TypeOfGoldDepositValue === '' || this.TypeOfGoldDepositValue == null) {
|
||||
this.TypeOfGoldDepositValue_check = 0
|
||||
} else {
|
||||
this.TypeOfGoldDepositValue_check = 1
|
||||
}
|
||||
if (this.Bidder === '' || this.Bidder == null) {
|
||||
this.Bidder_check = 0
|
||||
} else {
|
||||
this.Bidder_check = 1
|
||||
}
|
||||
if (this.TenderingEnterprise === '' || this.TenderingEnterprise == null) {
|
||||
this.TenderingEnterprise_check = 0
|
||||
} else {
|
||||
this.TenderingEnterprise_check = 1
|
||||
}
|
||||
this.dateRange ? this.check1 = 1 : (this.check1 = 0, this.dateRange = '')
|
||||
selectBidBond_excel(this.TypeOfGoldDepositValue_check, this.TypeOfGoldDepositValue, this.Bidder_check, this.peopleid, this.TenderingEnterprise_check, this.TenderingEnterprise, this.check1, this.dateRange[0], this.check1, this.dateRange[1]).then(val => {
|
||||
console.log(val)
|
||||
for (let i = 0; i < val.data.length; i++) {
|
||||
// if (val.data[i].投标结果 !== '' && val.data[i].交付日期 !== null) {
|
||||
// val.data[i].交付日期 = val.data[i].交付日期.substring(0, val.data[i].交付日期.length - 8)
|
||||
// }
|
||||
if (val.data[i].投标结果 === 0) {
|
||||
val.data[i].投标结果 = ''
|
||||
} else if (val.data[i].投标结果 === 1) {
|
||||
val.data[i].投标结果 = '已中标'
|
||||
} else if (val.data[i].投标结果 === 2) {
|
||||
val.data[i].投标结果 = '未中标'
|
||||
}
|
||||
if (val.data[i].公布日期 !== '' && val.data[i].公布日期 !== null) {
|
||||
val.data[i].公布日期 = val.data[i].公布日期.substring(0, val.data[i].公布日期.length - 8)
|
||||
}
|
||||
if (val.data[i].投标日期 !== '' && val.data[i].投标日期 !== null) {
|
||||
val.data[i].投标日期 = val.data[i].投标日期.substring(0, val.data[i].投标日期.length - 8)
|
||||
}
|
||||
// if (val.data[i].投标日期 !== '' && val.data[i].投标日期 !== null) {
|
||||
// val.data[i].投标日期 = val.data[i].投标日期.substring(0, val.data[i].投标日期.length - 8)
|
||||
// }
|
||||
if (parseInt(val.data[i].是否收回) !== 2) {
|
||||
val.data[i].应收回金额 = '未收回'
|
||||
} else {
|
||||
val.data[i].应收回金额 = (val.data[i].应收回金额).toFixed(2)
|
||||
}
|
||||
val.data[i].保证金金额 = (val.data[i].保证金金额).toFixed(2)
|
||||
val.data[i].中标服务费 = (val.data[i].中标服务费).toFixed(2)
|
||||
val.data[i].未收金额 = (val.data[i].未收金额).toFixed(2)
|
||||
val.data[i].转履约保证金金额 = (val.data[i].转履约保证金金额).toFixed(2)
|
||||
}
|
||||
if (val.length !== 0) {
|
||||
import('@/vendor/Export2Excel').then(excel => {
|
||||
const tHeader = ['投标结果', '公布日期', '招标企业', '项目名称', '保证金(万元)', '缴纳时间', '投标人', '中标服务费(万元)', '转履约金(万元)', '已收(万元)', '未收(万元)', '保证金备注']
|
||||
const filterVal = ['投标结果', '公布日期', '招标企业', '项目名称', '保证金金额', '投标日期', '投标人', '中标服务费', '转履约保证金金额', '应收回金额', '未收金额', '备注']
|
||||
const list = val.data
|
||||
const data = this.formatJson(filterVal, list)
|
||||
excel.export_json_to_excel({
|
||||
header: tHeader,
|
||||
data,
|
||||
filename: getNowShotTime() + '投标保证金',
|
||||
autoWidth: true,
|
||||
bookType: 'xlsx'
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('没有导出内容')
|
||||
}
|
||||
})
|
||||
},
|
||||
changeTime() {
|
||||
this.pickerOptions = Object.assign({}, this.pickerOptions, {
|
||||
disabledDate: (time) => {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div class="app-container">
|
||||
<el-card>
|
||||
<span>客户名称:</span>
|
||||
<!--<span>客户名称:</span>-->
|
||||
<el-select v-model="CustomerNameValue" filterable placeholder="请输入客户名称" style="margin: 3px;width: 230px" size="small" clearable>
|
||||
<el-option
|
||||
v-for="item in CustomerName"
|
||||
@@ -22,10 +22,10 @@
|
||||
<!--</el-option>-->
|
||||
<!--</el-select>-->
|
||||
<el-button type="primary" icon="el-icon-search" class="move" size="small" style="margin-left: 10px" plain @click="selectCustomerOfName">查询</el-button>
|
||||
<el-button class="button222" icon="el-icon-circle-plus-outline" size="small" style="margin-top: 3px" @click = "addCustomer();flag1 = 1">客户</el-button>
|
||||
</el-card>
|
||||
<el-card>
|
||||
<!--<el-button type="distribution" icon="el-icon-circle-plus-outline" size="small" style="margin-top: 3px;" @click="addMarketingManager();flag = 1" >添加营销经理</el-button>-->
|
||||
<el-button class="button222" icon="el-icon-circle-plus-outline" size="small" style="margin-top: 3px" @click = "addCustomer();flag1 = 1">客户</el-button>
|
||||
<!--<el-table v-loading="loading3" :data="tableData3" highlight-current-row height="192" size="mini" stripe style="width: 100%;margin-top: 3px;margin-bottom: 0px" border>-->
|
||||
<!--<!–<el-table-column label="责权省份" align="center" min-width="80">–>-->
|
||||
<!--<!–<template slot-scope="scope">–>-->
|
||||
@@ -84,11 +84,12 @@
|
||||
v-loading="loading1"
|
||||
ref="multipleTable"
|
||||
:data="tableData1"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
stripe
|
||||
highlight-current-row
|
||||
tooltip-effect="dark"
|
||||
style="width: 100%; margin-top: 3px;"
|
||||
height="550"
|
||||
height="630"
|
||||
size="mini"
|
||||
border>
|
||||
<el-table-column align="center" label="序号" width="65">
|
||||
@@ -106,7 +107,7 @@
|
||||
</el-col>
|
||||
<el-col :span="20">
|
||||
<el-card>
|
||||
<el-table v-loading="loading2" :data="tableData2" highlight-current-row height="520" size="mini" stripe style="width: 100%;margin-top: 2px" border>
|
||||
<el-table v-loading="loading2" :data="tableData2" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" highlight-current-row height="600" size="mini" stripe style="width: 100%;margin-top: 2px" border>
|
||||
<el-table-column label="客户名称" prop="客户名称" align="center" min-width="180" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.客户名称 }}
|
||||
@@ -217,6 +218,7 @@
|
||||
<div style="float: left;margin-top: 10px;margin-left: 20px;overflow-y: scroll;height: 400px">
|
||||
<el-tree
|
||||
:data="dataPeople"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
:default-expanded-keys="treeData"
|
||||
node-key="id"
|
||||
style="width: 150px;float: left"
|
||||
@@ -225,7 +227,7 @@
|
||||
@node-click="handleNodeClick"
|
||||
/>
|
||||
</div>
|
||||
<el-table :data="ListPeople" height="400" stripe style="width: 400px;float: left;margin-left: 30px" size="mini" highlight-current-row @row-click="handleChange">
|
||||
<el-table :data="ListPeople" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" height="400" stripe style="width: 400px;float: left;margin-left: 30px" size="mini" highlight-current-row @row-click="handleChange">
|
||||
<el-table-column label="考勤编号" align="center" >
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.考勤编号 }}
|
||||
|
||||
@@ -82,12 +82,12 @@
|
||||
</el-col>
|
||||
<el-col :span="6.3">
|
||||
<el-table :data="tableData2" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" class="subTableHeader" border style="text-align: center" size="mini">
|
||||
<el-table-column label="设备型号" align="center" width="90" show-overflow-tooltip>
|
||||
<el-table-column label="设备型号" align="center" width="100" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床图号 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="设备名称" align="center" min-width="90" show-overflow-tooltip>
|
||||
<el-table-column label="设备名称" align="center" min-width="180" show-overflow-tooltip>
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床名称 }}
|
||||
</template>
|
||||
@@ -112,7 +112,7 @@
|
||||
:value="item.value"/>
|
||||
</el-select>
|
||||
<div style="margin-top: 5px">
|
||||
<el-table :data="tableData3" border stripe style="width: 100%; text-align: center;" size="mini" highlight-current-row @row-click="handleChange">
|
||||
<el-table :data="tableData3" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" border stripe style="width: 100%; text-align: center;" size="mini" highlight-current-row @row-click="handleChange">
|
||||
<el-table-column label="营销经理" align="center" >
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.姓名 }}
|
||||
@@ -138,6 +138,7 @@
|
||||
<el-table
|
||||
v-loading="listLoadingContractCapitalManagement"
|
||||
:data="tableDataContractCapitalManagement"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
style="width: 99%;"
|
||||
height="100"
|
||||
border
|
||||
@@ -207,6 +208,7 @@
|
||||
<el-table
|
||||
v-loading="listLoadingInvoiceRecord"
|
||||
:data="tableDataInvoiceRecord"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
style="width: 99%"
|
||||
height="100"
|
||||
border
|
||||
@@ -270,6 +272,7 @@
|
||||
v-loading="tableDataLoadingDeliveryManagement"
|
||||
id="tb"
|
||||
:data="tableDataDeliveryManagement"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
highlight-current-row
|
||||
style="width: 99%"
|
||||
height="100"
|
||||
@@ -329,6 +332,7 @@
|
||||
<el-table
|
||||
v-loading="tableData1LoadingBidBond"
|
||||
:data="tableDataBidBond"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
style="width: 99%"
|
||||
height="100"
|
||||
border
|
||||
@@ -435,6 +439,7 @@
|
||||
v-loading="listLoadingPerformanceBond"
|
||||
v-show="showPerformanceBond"
|
||||
:data="tableDataPerformanceBond"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
style="width: 99%"
|
||||
height="100"
|
||||
border
|
||||
@@ -507,6 +512,7 @@
|
||||
<el-table
|
||||
v-loading="listLoadingSafetyMargin"
|
||||
:data="tableDataSafetyMargin"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
style="width: 99%"
|
||||
height="100"
|
||||
border
|
||||
|
||||
@@ -30,6 +30,11 @@
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"/>
|
||||
<el-button type="primary" icon="el-icon-search" size="small" style="margin-left: 10px" plain @click="PageSize = 30;PageCurrent = 1;tableData2=[];getTableData()">查询</el-button>
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="导出" placement="top">
|
||||
<div style="display: inline-block">
|
||||
<el-button type="primary" plain class="el-icon-download" size="small" style="margin: 10px 0 0 250px" @click="exportExcel">导出</el-button>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
<!--<el-badge :value="value" :max="99" class="item">-->
|
||||
<!--<el-button size="small" plain @click="AccountsReceivable">查看收款信息</el-button>-->
|
||||
<!--</el-badge>-->
|
||||
@@ -167,6 +172,7 @@
|
||||
<el-table
|
||||
:data="tableData2"
|
||||
:summary-method="getSummaries1"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
style="width: 395px;max-height: 440px;text-align: center"
|
||||
highlight-current-row
|
||||
show-summary
|
||||
@@ -206,7 +212,8 @@
|
||||
|
||||
<script>
|
||||
import elInput from 'element-ui/packages/input'
|
||||
import { updateMoney, addMoney, deleteMoney, executionProgressID, getcustomername, searchProjectNumber2, AccountsReceivable, selectProvince, SelectMarketingManager, searchTable1, searchTable2, searchProjectNumber, PaymentPhase, selectMachine } from '@/api//MarketingCenter/ContractCapitalManagement'
|
||||
import { getNowShotTime } from '@/utils/tool'
|
||||
import { updateMoney, addMoney, deleteMoney, executionProgressID, getcustomername, searchProjectNumber2, AccountsReceivable, selectProvince, SelectMarketingManager, searchTable1, searchTable2, searchProjectNumber, PaymentPhase, selectMachine, downloadexcel } from '@/api//MarketingCenter/ContractCapitalManagement'
|
||||
|
||||
export default {
|
||||
components: {
|
||||
@@ -303,7 +310,39 @@ export default {
|
||||
this.getCustomerName()
|
||||
},
|
||||
methods: {
|
||||
// 2020 02 20 刘路加新增怕徐
|
||||
formatJson(filterVal, jsonData) {
|
||||
return jsonData.map(v => filterVal.map(j => {
|
||||
return v[j]
|
||||
}))
|
||||
},
|
||||
exportExcel() {
|
||||
this.dateRange ? this.check1 = 1 : (this.check1 = 0, this.dateRange = '')
|
||||
downloadexcel(this.entryNameValue, this.peopleid, this.customerName, this.check1, this.dateRange[0], this.dateRange[1], this.ordername, this.order).then(val => {
|
||||
for (let i = 0; i < val.data.length; i++) {
|
||||
val.data[i]['合同总金额(万元)'] === null ? val.data[i]['合同总金额(万元)'] = '0.00' : val.data[i]['合同总金额(万元)'] = (val.data[i]['合同总金额(万元)']).toFixed(2)
|
||||
val.data[i]['到账金额(万元)'] === null ? val.data[i]['到账金额(万元)'] = '0.00' : val.data[i]['到账金额(万元)'] = (val.data[i]['到账金额(万元)']).toFixed(2)
|
||||
val.data[i]['未收金额(万元)'] === null ? val.data[i]['未收金额(万元)'] = '0.00' : val.data[i]['未收金额(万元)'] = (val.data[i]['未收金额(万元)']).toFixed(2)
|
||||
}
|
||||
if (val.length !== 0) {
|
||||
import('@/vendor/Export2Excel').then(excel => {
|
||||
const tHeader = ['序号', '合同编号', '项目名称', '客户名称', '付款方式', '合同签订日期', '合同总金额(万元)', '到账金额(万元)', '未收金额(万元)', '营销经理']
|
||||
const filterVal = ['序号', '合同编号', '项目名称', '客户名称', '付款方式', '合同签订日期', '合同总金额(万元)', '到账金额(万元)', '未收金额(万元)', '营销经理']
|
||||
const list = val.data
|
||||
const data = this.formatJson(filterVal, list)
|
||||
excel.export_json_to_excel({
|
||||
header: tHeader,
|
||||
data,
|
||||
filename: getNowShotTime(),
|
||||
autoWidth: true,
|
||||
bookType: 'xlsx'
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('没有导出内容')
|
||||
}
|
||||
})
|
||||
},
|
||||
// 2020 02 20 刘路加新增排序
|
||||
sortChange(column, prop, order) {
|
||||
console.log(column + '-' + column.prop + '-' + column.order, 11111)
|
||||
if (column.prop === '合同编号') {
|
||||
@@ -421,7 +460,6 @@ export default {
|
||||
this.tableData2[index].收款金额 = 0
|
||||
}
|
||||
}).then(() => {
|
||||
console.log(111111111)
|
||||
this.getTableData()
|
||||
})
|
||||
},
|
||||
@@ -560,6 +598,7 @@ export default {
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
/*.el-card {*/
|
||||
/* !*margin-top: 15px;*!*/
|
||||
/*}*/
|
||||
@@ -575,7 +614,7 @@ export default {
|
||||
.el-table td, .el-table th.is-leaf,
|
||||
.el-radio__inner,
|
||||
.el-input__inner{
|
||||
border: 1px solid black!important;
|
||||
/*border: 1px solid black!important;*/
|
||||
width: 150px;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
@@ -586,7 +625,7 @@ export default {
|
||||
/*}*/
|
||||
</style>
|
||||
<style lang="scss">
|
||||
.subTableHeader {
|
||||
>>>.subTableHeader {
|
||||
th {
|
||||
background: #7eaced !important;
|
||||
color: black;
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
@expand-change="selectMachine">
|
||||
<el-table-column type="expand" label="详情" width="50">
|
||||
<template slot-scope="scope">
|
||||
<el-table :data="tableData2" class="subTableHeader" size="mini" border style="width: 482px; text-align: center">
|
||||
<el-table :data="tableData2" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" class="subTableHeader" size="mini" border style="width: 482px; text-align: center">
|
||||
<el-table-column label="机床型号" align="center" width="140">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.机床图号 }}
|
||||
@@ -352,14 +352,14 @@
|
||||
<!--营销经理选择-->
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisiblePeople" title="营销经理" center width="300px">
|
||||
<div style="margin-top: 0px;width: 250px">
|
||||
<el-table :data="tableData4" border style="width: 120px; text-align: center;display: inline-block;vertical-align: top;" size="mini" highlight-current-row @row-click="handleChange1">
|
||||
<el-table :data="tableData4" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" border style="width: 120px; text-align: center;display: inline-block;vertical-align: top;" size="mini" highlight-current-row @row-click="handleChange1">
|
||||
<el-table-column label="部门" align="center" >
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.部门名称 }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<el-table :data="tableData3" border stripe style="width: 120px;height:350px; text-align: center;display: inline-block;vertical-align: top;" size="mini" highlight-current-row @row-click="handleChange">
|
||||
<el-table :data="tableData3" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" border stripe style="width: 120px;height:350px; text-align: center;display: inline-block;vertical-align: top;" size="mini" highlight-current-row @row-click="handleChange">
|
||||
<el-table-column label="销售经理" align="center" >
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.姓名 }}
|
||||
@@ -442,7 +442,18 @@
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogCustomerFormVisible" title="客户选择" center width="400px">
|
||||
<el-input v-model="Customer" clearable size="small" style="width:200px" placeholder="请输入客户名称"/>
|
||||
<el-button type="search" icon="el-icon-search" size="small" style="margin-left: 10px" @click="PageSize1 = 30;PageCurrent1 = 1;fetchCustomerData()">查询</el-button>
|
||||
<el-table v-loading="loading1" :data="CustomerData" highlight-current-row height="300" stripe border show-overflow-tooltip style="height: 350px; margin-top: 10px" size="mini" @row-click="handleCustomerChange">
|
||||
<el-table
|
||||
v-loading="loading1"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
:data="CustomerData"
|
||||
highlight-current-row
|
||||
height="300"
|
||||
stripe
|
||||
border
|
||||
show-overflow-tooltip
|
||||
style="height: 350px; margin-top: 10px"
|
||||
size="mini"
|
||||
@row-click="handleCustomerChange">
|
||||
<el-table-column label="客户名称" align="center" >
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.客户名称 }}
|
||||
@@ -767,7 +778,7 @@ export default {
|
||||
this.ExecutionProgressShow = false
|
||||
this.uploader = false
|
||||
this.ExecutionProgress = null
|
||||
this.listLoading = true
|
||||
// this.listLoading = true
|
||||
var param = []
|
||||
param[0] = ['项目流水号_check', this.entryNameValue_check]
|
||||
param[1] = ['合同ID', this.entryNameValue]
|
||||
|
||||
@@ -1190,17 +1190,18 @@ export default {
|
||||
}
|
||||
</script>
|
||||
<style>
|
||||
.el-textarea__inner,
|
||||
.el-radio__inner,
|
||||
.el-input__inner{
|
||||
border-bottom: 1px solid #dcdfe6!important;
|
||||
}
|
||||
.el-textarea__inner, .el-radio__inner, .el-input__inner{
|
||||
border: 1px solid #dcdfe6!important;
|
||||
}
|
||||
|
||||
</style>
|
||||
|
||||
<style scoped>
|
||||
>>>.el-textarea__inner,
|
||||
>>>.el-radio__inner,
|
||||
>>>.el-input__inner{
|
||||
border-bottom: 1px solid #dcdfe6!important;
|
||||
}
|
||||
>>>.el-textarea__inner,>>> .el-radio__inner,>>> .el-input__inner{
|
||||
border: 1px solid #dcdfe6!important;
|
||||
}
|
||||
.el-divider{
|
||||
margin: 5px;
|
||||
}
|
||||
|
||||
@@ -30,6 +30,11 @@
|
||||
size="small"
|
||||
icon="el-icon-circle-plus-outline"
|
||||
@click.stop="openAddInvoiceRecordingDialog(); flag = 1">开票</el-button>
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="导出" placement="top">
|
||||
<div style="display: inline-block">
|
||||
<el-button type="primary" plain class="el-icon-download" size="small" style="margin: 10px 0 0 70px" @click="exportExcel">导出</el-button>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
</el-row>
|
||||
</el-card>
|
||||
<!--项目表格-->
|
||||
@@ -37,6 +42,7 @@
|
||||
<el-col :span="15">
|
||||
<el-table
|
||||
v-loading="listLoading1"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
:data="tableData1"
|
||||
highlight-current-row
|
||||
style="width: 900px;margin-top: 3px"
|
||||
@@ -124,6 +130,7 @@
|
||||
<el-col :span="9">
|
||||
<el-table
|
||||
v-loading="listLoading2"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
:data="tableData2"
|
||||
:summary-method="getSummaries"
|
||||
show-summary
|
||||
@@ -189,6 +196,7 @@
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisibleRecord" title="开票详情" center width="600px">
|
||||
<el-table
|
||||
v-loading="listLoading2"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
:data="tableData2"
|
||||
:summary-method="getSummaries"
|
||||
show-summary
|
||||
@@ -255,7 +263,7 @@
|
||||
<el-input v-model="name" clearable size="small" style="width: 200px"/>
|
||||
<el-button size="small" type="success" style="margin-left: 10px;" icon="el-icon-search" @click="searchName">查询</el-button>
|
||||
<div style="margin-top: 5px">
|
||||
<el-table :data="dataPeople" border size="mini" stripe style="width: 100%; text-align: center;" highlight-current-row @row-click="handleChange">
|
||||
<el-table :data="dataPeople" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" border size="mini" stripe style="width: 100%; text-align: center;" highlight-current-row @row-click="handleChange">
|
||||
<el-table-column label="销售经理" align="center" >
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.姓名 }}
|
||||
@@ -310,7 +318,18 @@
|
||||
<el-dialog v-el-drag-dialog :visible.sync="dialogCustomerFormVisible" title="选择客户" center width="600px">
|
||||
<el-input v-model="Customer" clearable size="small" style="width:200px" placeholder="请输入客户名称"/>
|
||||
<el-button type="success" icon="el-icon-search" size="small" style="margin-left: 10px" @click="PageSize1 = 30;PageCurrent1 = 1;fetchCustomerData()">查询</el-button>
|
||||
<el-table v-loading="loading1" :data="CustomerData" border stripe size="mini" highlight-current-row height="400" show-overflow-tooltip style="height: 330px; margin-top: 5px" @row-click="handleCustomerChange">
|
||||
<el-table
|
||||
v-loading="loading1"
|
||||
:header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}"
|
||||
:data="CustomerData"
|
||||
border
|
||||
stripe
|
||||
size="mini"
|
||||
highlight-current-row
|
||||
height="400"
|
||||
show-overflow-tooltip
|
||||
style="height: 330px; margin-top: 5px"
|
||||
@row-click="handleCustomerChange">
|
||||
<el-table-column label="省份" align="center" width="80">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.省份 }}
|
||||
@@ -351,7 +370,8 @@
|
||||
|
||||
<script>
|
||||
import elInput from 'element-ui/packages/input'
|
||||
import { initProject, searchTableData1, searchTableData2, revisionOfTaxRate, selectProvince, SelectMarketingManager, fetchCustomerData, addSubmit, editSubmit, delSubmit } from '@/api/MarketingCenter/InvoiceRecord'
|
||||
import { getNowShotTime } from '@/utils/tool'
|
||||
import { initProject, searchTableData1, searchTableData2, revisionOfTaxRate, selectProvince, SelectMarketingManager, fetchCustomerData, addSubmit, editSubmit, delSubmit, searchTableData_Excel } from '@/api/MarketingCenter/InvoiceRecord'
|
||||
export default {
|
||||
components: {
|
||||
elInput
|
||||
@@ -472,6 +492,44 @@ export default {
|
||||
this.fetchTableData1()
|
||||
},
|
||||
methods: {
|
||||
formatJson(filterVal, jsonData) {
|
||||
return jsonData.map(v => filterVal.map(j => {
|
||||
return v[j]
|
||||
}))
|
||||
},
|
||||
exportExcel() {
|
||||
if (this.customerName === '' || this.customerName === null) { this.customerName_check = 0 } else { this.customerName_check = 1 }
|
||||
if (this.entryNameValue === '' || this.entryNameValue === null) { this.entryNameValue_check = 0 } else { this.entryNameValue_check = 1 }
|
||||
if (this.MarketingManagerValue === '' || this.MarketingManagerValue === null) { this.peopleid_check = 0 } else { this.peopleid_check = 1 }
|
||||
this.dateRange ? (this.startTime_check = 1, this.endTime_check = 0) : (this.startTime_check = 0, this.endTime_check = 0, this.dateRange = '')
|
||||
// if (this.startTime === '' || this.startTime === null) { this.startTime_check = 0 } else { this.startTime_check = 1 }
|
||||
// if (this.endTime === '' || this.endTime === null) { this.endTime_check = 0 } else { this.endTime_check = 1 }
|
||||
searchTableData_Excel(this.entryNameValue, this.peopleid, this.entryNameValue_check, this.peopleid_check, this.startTime_check, this.endTime_check, this.dateRange[0], this.dateRange[1], this.customerName, this.customerName_check).then(val => {
|
||||
console.log(val)
|
||||
for (let i = 0; i < val.data.length; i++) {
|
||||
val.data[i].合同金额 === null ? val.data[i].合同金额 = '0.00' : val.data[i].合同金额 = (val.data[i].合同金额).toFixed(2)
|
||||
val.data[i].到账金额 === null ? val.data[i].到账金额 = '0.00' : val.data[i].到账金额 = (val.data[i].到账金额).toFixed(2)
|
||||
val.data[i].开票金额 === null ? val.data[i].开票金额 = '0.00' : val.data[i].开票金额 = (val.data[i].开票金额).toFixed(2)
|
||||
}
|
||||
if (val.length !== 0) {
|
||||
import('@/vendor/Export2Excel').then(excel => {
|
||||
const tHeader = ['序号', '合同编号', '项目名称', '客户名称', '付款方式', '签订日期', '合同金额(万元)', '到账金额(万元)', '开票金额(万元)', '营销经理']
|
||||
const filterVal = ['序号', '合同编号', '项目名称', '客户名称', '付款方式', '签订日期', '合同金额', '到账金额', '开票金额', '营销经理']
|
||||
const list = val.data
|
||||
const data = this.formatJson(filterVal, list)
|
||||
excel.export_json_to_excel({
|
||||
header: tHeader,
|
||||
data,
|
||||
filename: getNowShotTime() + '开票记录',
|
||||
autoWidth: true,
|
||||
bookType: 'xlsx'
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('没有导出内容')
|
||||
}
|
||||
})
|
||||
},
|
||||
opendialogFormVisibleRecordDialog(row) {
|
||||
this.dialogFormVisibleRecord = true
|
||||
this.fetchTableData2(row)
|
||||
|
||||
@@ -164,6 +164,11 @@
|
||||
<el-tag v-else-if="parseInt(scope.row.是否收回) === 0" slot="reference" type="danger" size="mini" style="width: 66px">未收回</el-tag>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="收回金额">
|
||||
<template slot-scope="scope">
|
||||
{{ Number(scope.row.收回金额).toFixed(2) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column align="center" label="实际收回日期">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.实际收回日期 === '' || scope.row.实际收回日期 === null ? scope.row.实际收回日期 = '暂未收回' : scope.row.实际收回日期 }}
|
||||
@@ -266,6 +271,9 @@
|
||||
type="date"
|
||||
placeholder="请选择实际收回日期"/>
|
||||
</el-form-item>
|
||||
<el-form-item label="收回金额(万元)" prop="收回金额">
|
||||
<el-input-number v-model="form.收回金额" :precision="2" :min="0" :step="1" :max="maxrecmoney" style="width: 150px" size="small"/>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button size="small" icon="el-icon-circle-close" @click="callOffTime('form')">取消</el-button>
|
||||
@@ -398,8 +406,10 @@ export default {
|
||||
performanceGuaranteeShow: true,
|
||||
customerName_check: '',
|
||||
customerName: '', // 客户名称
|
||||
maxrecmoney: 0.00,
|
||||
form: {
|
||||
实际收回日期: ''
|
||||
实际收回日期: '',
|
||||
收回金额: ''
|
||||
},
|
||||
form2: {
|
||||
保证金金额: '',
|
||||
@@ -408,7 +418,10 @@ export default {
|
||||
截止时间: 15
|
||||
},
|
||||
rules: { // 表单验证规则
|
||||
实际收回日期: [{ required: true, message: '请选择实际收回日期', trigger: 'change' }]
|
||||
实际收回日期: [{ required: true, message: '请选择实际收回日期', trigger: 'change' }],
|
||||
收回金额: [
|
||||
{ required: true, message: '请输入收回金额', trigger: 'change' },
|
||||
{ required: true, trigger: 'blur', validator: validateValue }]
|
||||
},
|
||||
rules2: { // 表单验证规则
|
||||
保证金金额: [
|
||||
@@ -525,6 +538,9 @@ export default {
|
||||
takeBack(row) {
|
||||
this.addForm('form')
|
||||
this.performanceBondCode = row.履约保证金流水号
|
||||
this.form.收回金额 = Number(row.收回金额).toFixed(2)
|
||||
console.log((row.履约保证金金额).toFixed(2))
|
||||
this.maxrecmoney = row.履约保证金金额
|
||||
this.dialogTimeVisible = true
|
||||
},
|
||||
callOffTime() {
|
||||
@@ -533,7 +549,7 @@ export default {
|
||||
submitTime(formName) {
|
||||
this.$refs[formName].validate((valid) => {
|
||||
if (valid) {
|
||||
takeBack(this.performanceBondCode, this.form.实际收回日期).then(response => {
|
||||
takeBack(this.performanceBondCode, this.form.实际收回日期, this.form.收回金额).then(response => {
|
||||
if (response.data[0].result === '1') {
|
||||
this.$message.success('操作成功')
|
||||
this.dialogTimeVisible = false
|
||||
|
||||
@@ -40,8 +40,12 @@
|
||||
<!-- type="date"-->
|
||||
<!-- placeholder="请选择结束日期"/>-->
|
||||
<el-button type="primary" icon="el-icon-search" size="small" style="margin-left: 10px" plain @click="PageSizeProject = 30;PageCurrentProject = 1;searchTableDataProject()">查询</el-button>
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="导出" placement="top">
|
||||
<div style="display: inline-block">
|
||||
<el-button type="primary" plain class="el-icon-download" size="small" style="margin: 10px 0 0 630px" @click="exportExcel">导出</el-button>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
</el-card>
|
||||
|
||||
<el-card>
|
||||
<el-table
|
||||
v-loading="listLoadingProject"
|
||||
@@ -113,6 +117,11 @@
|
||||
{{ Number(scope.row.已收金额).toFixed(2) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="未收(万元)" align="center" width="100">
|
||||
<template slot-scope="scope">
|
||||
{{ Number(scope.row.未收金额).toFixed(2) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="营销经理" align="center" width="80">
|
||||
<template slot-scope="scope">
|
||||
{{ scope.row.姓名 }}
|
||||
@@ -204,7 +213,6 @@
|
||||
@current-change="handleCurrentChangeProject"/>
|
||||
</div>
|
||||
</el-card>
|
||||
|
||||
<!--安全保证金表格-->
|
||||
<el-card>
|
||||
<el-table
|
||||
@@ -633,7 +641,8 @@
|
||||
|
||||
<script>
|
||||
import elInput from 'element-ui/packages/input'
|
||||
import { initProject, searchTable1, searchTable2, addSafetyMargin, editSafetyMargin, delSafetyMargin, Withdrawing, delWithdrawing, edtWithdrawing, TakeBack, searchTableDataProject, executionProgressID } from '@/api/MarketingCenter/SafetyMargin'
|
||||
import { getNowShotTime } from '@/utils/tool'
|
||||
import { initProject, searchTable1, searchTable2, addSafetyMargin, editSafetyMargin, delSafetyMargin, Withdrawing, delWithdrawing, edtWithdrawing, TakeBack, searchTableDataProject, searchTableDataProject_excel, executionProgressID } from '@/api/MarketingCenter/SafetyMargin'
|
||||
export default {
|
||||
components: {
|
||||
elInput
|
||||
@@ -786,6 +795,68 @@ export default {
|
||||
this.searchTableDataProject()
|
||||
},
|
||||
methods: {
|
||||
formatJson(filterVal, jsonData) {
|
||||
return jsonData.map(v => filterVal.map(j => {
|
||||
return v[j]
|
||||
}))
|
||||
},
|
||||
exportExcel() {
|
||||
if (this.entryNameValue === '' || this.entryNameValue === null) {
|
||||
this.entryNameValue_check = 0
|
||||
} else {
|
||||
this.entryNameValue_check = 1
|
||||
}
|
||||
if (this.startTime === '' || this.startTime === null) {
|
||||
this.startTime_check = 0
|
||||
} else {
|
||||
this.startTime_check = 1
|
||||
}
|
||||
if (this.endTime === '' || this.endTime === null) {
|
||||
this.endTime_check = 0
|
||||
} else {
|
||||
this.endTime_check = 1
|
||||
}
|
||||
if (this.customerName === '' || this.customerName === null) {
|
||||
this.customerName_check = 0
|
||||
} else {
|
||||
this.customerName_check = 1
|
||||
}
|
||||
// llj新增
|
||||
this.dateRange ? this.check1 = 1 : (this.check1 = 0, this.dateRange = '')
|
||||
searchTableDataProject_excel(this.entryNameValue, this.entryNameValue_check, this.check1, this.check1, this.dateRange[0], this.dateRange[1], this.customerName_check, this.customerName).then(val => {
|
||||
console.log(val.data[0])
|
||||
for (let i = 0; i < val.data.length; i++) {
|
||||
val.data[i].保证金金额 === null ? val.data[i].保证金金额 = '0.00' : val.data[i].保证金金额 = (val.data[i].保证金金额).toFixed(2)
|
||||
val.data[i].扣款金额 === null ? val.data[i].扣款金额 = '0.00' : val.data[i].扣款金额 = (val.data[i].扣款金额).toFixed(2)
|
||||
val.data[i].应收回金额 === null ? val.data[i].应收回金额 = '0.00' : val.data[i].应收回金额 = (val.data[i].应收回金额).toFixed(2)
|
||||
val.data[i].已收金额 === null ? val.data[i].已收金额 = '0.00' : val.data[i].已收金额 = (val.data[i].已收金额).toFixed(2)
|
||||
val.data[i].未收金额 === null ? val.data[i].未收金额 = '0.00' : val.data[i].未收金额 = (val.data[i].未收金额).toFixed(2)
|
||||
// val.data[i].扣款金额 === null ? val.data[i].扣款金额 = 0.00 : (val.data[i].扣款金额).toFixed(2)
|
||||
// val.data[i].应收回金额 === null ? 0.00 : (val.data[i].应收回金额).toFixed(2)
|
||||
// val.data[i].已收金额 === null ? 0.00 : (val.data[i].已收金额).toFixed(2)
|
||||
if (val.data[i].交付日期 !== '' && val.data[i].交付日期 !== null) {
|
||||
val.data[i].交付日期 = val.data[i].交付日期.substring(0, val.data[i].交付日期.length - 8)
|
||||
}
|
||||
}
|
||||
if (val.length !== 0) {
|
||||
import('@/vendor/Export2Excel').then(excel => {
|
||||
const tHeader = ['合同编号', '项目名称', '客户名称', '安全金(万元)', '缴纳时间', '扣款金额(万元)', '扣款原因', '应收(万元)', '已收(万元)', '未收(万元)', '营销经理', '合同信息备注', '备注']
|
||||
const filterVal = ['合同编号', '项目名称', '客户名称', '保证金金额', '交付日期', '扣款金额', '扣款原因', '应收回金额', '已收金额', '未收金额', '姓名', '合同信息备注', '备注']
|
||||
const list = val.data
|
||||
const data = this.formatJson(filterVal, list)
|
||||
excel.export_json_to_excel({
|
||||
header: tHeader,
|
||||
data,
|
||||
filename: getNowShotTime() + '安全保证金',
|
||||
autoWidth: true,
|
||||
bookType: 'xlsx'
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('没有导出内容')
|
||||
}
|
||||
})
|
||||
},
|
||||
changeTime() {
|
||||
this.pickerOptions = Object.assign({}, this.pickerOptions, {
|
||||
disabledDate: (time) => {
|
||||
@@ -848,6 +919,7 @@ export default {
|
||||
for (let i = 0; i < data.rows.length; i++) {
|
||||
data.rows[i].合同签订日期 = data.rows[i].合同签订日期.substring(0, data.rows[i].合同签订日期.length - 8)
|
||||
parseInt(data.rows[i].安全保证金类型) === 1 ? data.rows[i].是否禁用增加安全保证金 = true : data.rows[i].是否禁用增加安全保证金 = false
|
||||
data.rows[i].交付日期 = data.rows[i].交付日期.substring(0, data.rows[i].交付日期.length - 8)
|
||||
}
|
||||
|
||||
this.projectTableData = data.rows
|
||||
|
||||
@@ -3,7 +3,25 @@
|
||||
<el-card>
|
||||
<el-input v-model="invoiceNumber" placeholder="发货单号和收货单位" clearable style="width: 200px;margin-right: 10px" size="small" @keyup.enter.native="openSearch"/>
|
||||
<!--<el-input v-model="receivingUnit" placeholder="请输入收货单位" clearable style="width: 150px;margin-right: 10px" size="mini"/>-->
|
||||
<span style="font-size: 13px;margin-left: 10px">发货时间</span>
|
||||
<el-date-picker
|
||||
v-model="dateRange"
|
||||
:picker-options="pickerOptions"
|
||||
size="small"
|
||||
type="daterange"
|
||||
align="center"
|
||||
style="width: 240px;margin: 3px 0"
|
||||
value-format="yyyy-MM-dd"
|
||||
format="yyyy-MM-dd"
|
||||
range-separator="~"
|
||||
start-placeholder="开始日期"
|
||||
end-placeholder="结束日期"/>
|
||||
<el-button type="primary" icon="el-icon-search" size="mini" style="margin-left: 10px" plain @click="openSearch">查询</el-button>
|
||||
<el-tooltip :open-delay="1200" effect="dark" content="导出" placement="top">
|
||||
<div style="display: inline-block">
|
||||
<el-button type="primary" plain class="el-icon-download" size="small" style="margin: 10px 0 0 10px" @click="exportExcel">导出</el-button>
|
||||
</div>
|
||||
</el-tooltip>
|
||||
</el-card>
|
||||
<el-card>
|
||||
<el-col :span="12">
|
||||
@@ -123,10 +141,40 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { InvoiceListSearch, DetailsFeach } from '@/api/MarketingCenter/ShippingInquiries'
|
||||
import { getNowShotTime } from '@/utils/tool'
|
||||
import { InvoiceListSearch, DetailsFeach, InvoiceListSearch_Excel } from '@/api/MarketingCenter/ShippingInquiries'
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
dateRange: '',
|
||||
check1: '',
|
||||
pickerOptions: {
|
||||
shortcuts: [{
|
||||
text: '上季度',
|
||||
onClick(picker) {
|
||||
const end = new Date()
|
||||
const start = new Date()
|
||||
start.setTime(end.getTime() - 3600 * 1000 * 24 * 30 * 3)
|
||||
picker.$emit('pick', [start, end])
|
||||
}
|
||||
}, {
|
||||
text: '过去半年',
|
||||
onClick(picker) {
|
||||
const end = new Date()
|
||||
const start = new Date()
|
||||
start.setTime(end.getTime() - 3600 * 1000 * 24 * 366 / 2)
|
||||
picker.$emit('pick', [start, end])
|
||||
}
|
||||
}, {
|
||||
text: '过去一年',
|
||||
onClick(picker) {
|
||||
const end = new Date()
|
||||
const start = new Date()
|
||||
start.setTime(end.getTime() - 3600 * 1000 * 24 * 365)
|
||||
picker.$emit('pick', [start, end])
|
||||
}
|
||||
}]
|
||||
},
|
||||
tableDataSearchList: [],
|
||||
invoiceNumber: '',
|
||||
receivingUnit: '',
|
||||
@@ -140,11 +188,73 @@ export default {
|
||||
this.openSearch()
|
||||
},
|
||||
methods: {
|
||||
formatJson(filterVal, jsonData) {
|
||||
return jsonData.map(v => filterVal.map(j => {
|
||||
return v[j]
|
||||
}))
|
||||
},
|
||||
exportExcel() {
|
||||
this.tableDataSearchList = []
|
||||
this.invoiceNumber !== null && this.invoiceNumber !== '' ? this.invoiceNumber_check = 1 : this.invoiceNumber_check = 0
|
||||
this.receivingUnit !== null && this.receivingUnit !== '' ? this.receivingUnit_check = 1 : this.receivingUnit_check = 0
|
||||
this.dateRange ? this.check1 = 1 : (this.check1 = 0, this.dateRange = '')
|
||||
InvoiceListSearch_Excel(this.invoiceNumber, this.receivingUnit, this.invoiceNumber_check, this.receivingUnit_check, this.check1, this.dateRange[0], this.dateRange[1]).then(val => {
|
||||
console.log(val)
|
||||
// for (let i = 0; i < val.data.length; i++) {
|
||||
// // if (val.data[i].投标结果 !== '' && val.data[i].交付日期 !== null) {
|
||||
// // val.data[i].交付日期 = val.data[i].交付日期.substring(0, val.data[i].交付日期.length - 8)
|
||||
// // }
|
||||
// if (val.data[i].投标结果 === 0) {
|
||||
// val.data[i].投标结果 = ''
|
||||
// } else if (val.data[i].投标结果 === 1) {
|
||||
// val.data[i].投标结果 = '已中标'
|
||||
// } else if (val.data[i].投标结果 === 2) {
|
||||
// val.data[i].投标结果 = '未中标'
|
||||
// }
|
||||
// if (val.data[i].公布日期 !== '' && val.data[i].公布日期 !== null) {
|
||||
// val.data[i].公布日期 = val.data[i].公布日期.substring(0, val.data[i].公布日期.length - 8)
|
||||
// }
|
||||
// if (val.data[i].投标日期 !== '' && val.data[i].投标日期 !== null) {
|
||||
// val.data[i].投标日期 = val.data[i].投标日期.substring(0, val.data[i].投标日期.length - 8)
|
||||
// }
|
||||
// // if (val.data[i].投标日期 !== '' && val.data[i].投标日期 !== null) {
|
||||
// // val.data[i].投标日期 = val.data[i].投标日期.substring(0, val.data[i].投标日期.length - 8)
|
||||
// // }
|
||||
// if (parseInt(val.data[i].是否收回) !== 2) {
|
||||
// val.data[i].应收回金额 = '未收回'
|
||||
// } else {
|
||||
// val.data[i].应收回金额 = (val.data[i].应收回金额).toFixed(2)
|
||||
// }
|
||||
// val.data[i].保证金金额 = (val.data[i].保证金金额).toFixed(2)
|
||||
// val.data[i].中标服务费 = (val.data[i].中标服务费).toFixed(2)
|
||||
// val.data[i].未收金额 = (val.data[i].未收金额).toFixed(2)
|
||||
// val.data[i].转履约保证金金额 = (val.data[i].转履约保证金金额).toFixed(2)
|
||||
// }
|
||||
if (val.length !== 0) {
|
||||
import('@/vendor/Export2Excel').then(excel => {
|
||||
const tHeader = ['状态', '发货单号', '收货单位', '收货人', '联系电话', '收货地址', '发货日期', '车辆牌号', '司机姓名', '司机电话', '货品类别', '货品编号', '货品名称', '货品规格', '货品型号', '数量', '设计者']
|
||||
const filterVal = ['状态', '发货单号', '收货单位', '收货人', '联系电话', '收货地址', '发货日期', '车辆牌号', '司机姓名', '司机电话', '货品类别', '货品编号', '货品名称', '货品规格', '货品型号', '数量', '设计者']
|
||||
const list = val.data
|
||||
const data = this.formatJson(filterVal, list)
|
||||
excel.export_json_to_excel({
|
||||
header: tHeader,
|
||||
data,
|
||||
filename: getNowShotTime() + '发货记录',
|
||||
autoWidth: true,
|
||||
bookType: 'xlsx'
|
||||
})
|
||||
})
|
||||
} else {
|
||||
this.$message.warning('没有导出内容')
|
||||
}
|
||||
})
|
||||
},
|
||||
openSearch() {
|
||||
this.tableDataSearchList = []
|
||||
this.invoiceNumber !== null && this.invoiceNumber !== '' ? this.invoiceNumber_check = 1 : this.invoiceNumber_check = 0
|
||||
this.receivingUnit !== null && this.receivingUnit !== '' ? this.receivingUnit_check = 1 : this.receivingUnit_check = 0
|
||||
InvoiceListSearch(this.invoiceNumber, this.receivingUnit, this.invoiceNumber_check, this.receivingUnit_check).then(response => {
|
||||
this.dateRange ? this.check1 = 1 : (this.check1 = 0, this.dateRange = '')
|
||||
InvoiceListSearch(this.invoiceNumber, this.receivingUnit, this.invoiceNumber_check, this.receivingUnit_check, this.check1, this.dateRange[0], this.dateRange[1]).then(response => {
|
||||
if (response.data.length !== 0) {
|
||||
this.tableDataSearchList = response.data
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user