Files
JY1.0/src/views/MarketingCenter/ComprehensiveInquiryMS/index.vue
2020-02-24 09:32:44 +08:00

945 lines
45 KiB
Vue
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<template>
<div>
<el-card>
<el-row>
<el-select v-if="false" v-model="entryNameValue" clearable filterable placeholder="项目名称" style="margin-right:5px;width:150px" size="small">
<el-option
v-for="item in entryName"
:key="item.value"
:label="item.label"
:value="item.value"/>
</el-select>
<el-input v-model="customerName1" clearable size="small" style="width:200px;margin: 0px 10px" placeholder="合同编号或客户名称" @keyup.enter.native="PageSize = 30;PageCurrent = 1;fetchTableData1()"/>
<el-button type="primary" icon="el-icon-search" size="small" style="margin-left: 10px" plain @click="PageSize = 30;PageCurrent = 1;fetchTableData1()">查询</el-button>
</el-row>
</el-card>
<el-card>
<el-col :span="17.6">
<el-table v-loading="listLoading" :data="tableData1" :header-cell-style="{fontFamily:'YouYuan',fontSize:'13px',fontWeight:200}" stripe highlight-current-row style="margin-top: 3px" height="580" border size="mini" @row-click="selectMachine">
<el-table-column align="center" label="项目名称" prop="项目名称" width="130" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.项目名称 }}
</template>
</el-table-column>
<el-table-column align="center" label="客户名称" prop="客户名称" width="150" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.客户名称 }}
</template>
</el-table-column>
<el-table-column align="center" label="付款方式" width="77">
<template slot-scope="scope">
{{ scope.row.付款方式 }}
</template>
</el-table-column>
<el-table-column align="center" label="合同总额(万元)" width="124">
<template slot-scope="scope">
{{ Number(scope.row.合同总金额).toFixed(2) }}
</template>
</el-table-column>
<!--<el-table-column align="center" label="已付(万元)" width="95">-->
<!--<template slot-scope="scope">-->
<!--{{ Number(scope.row.已支付).toFixed(2) }}-->
<!--</template>-->
<!--</el-table-column>-->
<el-table-column align="center" label="签订日期" width="84">
<template slot-scope="scope">
{{ scope.row.合同签订日期&&scope.row.合同签订日期!=='1900/1/1' ? scope.row.合同签订日期 : '-' }}
</template>
</el-table-column>
<el-table-column align="center" label="发货节点" width="84">
<template slot-scope="scope">
{{ scope.row.发货节点&&scope.row.发货节点!=='1900/1/1' ? scope.row.发货节点 : '-' }}
</template>
</el-table-column>
<el-table-column align="center" label="销售经理" prop="营销经理" width="78">
<template slot-scope="scope">
{{ scope.row.营销经理 }}
</template>
</el-table-column>
<el-table-column align="center" label="合同编号" prop="合同编号" width="117">
<template slot-scope="scope">
<template>
<span slot="reference" type="mini">{{ scope.row.合同编号 }}</span>
</template>
</template>
</el-table-column>
<el-table-column align="center" label="信息备注" width="120" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.合同信息备注 }}
</template>
</el-table-column>
</el-table>
<div class="block">
<el-pagination
:current-page="PageCurrent"
:page-sizes="[10, 20, 30, 40]"
:page-size="PageSize"
:total="total"
layout="total, sizes, prev, pager, next, jumper"
@size-change="handleSizeChange"
@current-change="handleCurrentChange"/>
</div>
</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>
<template slot-scope="scope">
{{ scope.row.机床图号 }}
</template>
</el-table-column>
<el-table-column label="设备名称" align="center" min-width="90" show-overflow-tooltip>
<template slot-scope="scope">
{{ scope.row.机床名称 }}
</template>
</el-table-column>
<el-table-column label="设备状态" align="center" width="80">
<template slot-scope="scope">
{{ scope.row.机床状态 }}
</template>
</el-table-column>
</el-table>
</el-col>
</el-card>
<!--营销经理选择-->
<el-dialog v-el-drag-dialog :visible.sync="dialogFormVisiblePeople" title="营销经理" center width="30%">
<span>责权省份: </span>
<el-select v-model="ProvinceValue" clearable filterable placeholder="请选择省份" size="small" @change="changeProvince">
<el-option
v-for="item in Province"
:key="item.value"
:label="item.label"
: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-column label="营销经理" align="center" >
<template slot-scope="scope">
{{ scope.row.姓名 }}
</template>
</el-table-column>
<el-table-column label="性别" align="center">
<template slot-scope="scope">
{{ scope.row.性别 }}
</template>
</el-table-column>
</el-table>
</div>
<div slot="footer" class="dialog-footer">
<el-button @click="offName">取消</el-button>
<el-button type="primary" @click="getName">确认</el-button>
</div>
</el-dialog>
<el-card v-if="false" class="box-card">
<div class="block" style="border: 1px solid rgb(220, 223, 230)">
<el-carousel :autoplay="true" trigger="click" height="100px">
<el-carousel-item>
<el-button type="text" style="margin: 3px;padding: 0px;" @click="goToContractCapitalManagement">收款情况</el-button>
<el-table
v-loading="listLoadingContractCapitalManagement"
:data="tableDataContractCapitalManagement"
style="width: 99%;"
height="100"
border
stripe
size="mini">
<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="150">
<template slot-scope="scope">
{{ scope.row.合同总金额.toFixed(2) }}
</template>
</el-table-column>
<el-table-column align="center" label="已到账金额(万元)" width="150">
<template slot-scope="scope">
{{ scope.row.已支付.toFixed(2) }}
</template>
</el-table-column>
<el-table-column align="center" label="未到账金额(万元)" width="150">
<template slot-scope="scope">
<el-tag size="small" style="width: 100px" type="warning">{{ scope.row.未支付金额.toFixed(2) }}</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="付款进度" width="150">
<template slot-scope="scope">
<div style="width: 130px">
<el-progress :text-inside="true" :stroke-width="18" :percentage="parseFloat(scope.row.付款百分比)" status="success" />
</div>
</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="260">
<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="130">
<template slot-scope="scope">
{{ scope.row.电话 }}
</template>
</el-table-column>
<el-table-column align="center" label="银行账号" width="200">
<template slot-scope="scope">
{{ scope.row.银行账号 }}
</template>
</el-table-column>
<el-table-column align="center" label="税号">
<template slot-scope="scope">
{{ scope.row.税号 }}
</template>
</el-table-column>
</el-table>
</el-carousel-item>
<el-carousel-item>
<el-button type="text" style="margin: 3px;padding: 0px;" @click="goToInvoiceRecord">开票情况</el-button>
<el-table
v-loading="listLoadingInvoiceRecord"
:data="tableDataInvoiceRecord"
style="width: 99%"
height="100"
border
stripe
size="mini">
<el-table-column
align="center"
label="序号"
type="index"
width="50"/>
<el-table-column align="center" label="发票抬头" width="200">
<template slot-scope="scope">
{{ scope.row.客户名称 }}
</template>
</el-table-column>
<el-table-column align="center" label="纳税人识别号" width="180">
<template slot-scope="scope">
{{ scope.row.税号 }}
</template>
</el-table-column>
<el-table-column align="center" label="开票电话" width="120">
<template slot-scope="scope">
{{ scope.row.传真 }}
</template>
</el-table-column>
<el-table-column align="center" label="开票地址" width="200">
<template slot-scope="scope">
{{ scope.row.地址 }}
</template>
</el-table-column>
<el-table-column align="center" label="开户行" width="120">
<template slot-scope="scope">
{{ scope.row.开户行 }}
</template>
</el-table-column>
<el-table-column align="center" label="银行账号" width="160">
<template slot-scope="scope">
{{ scope.row.银行账号 }}
</template>
</el-table-column>
<el-table-column align="center" label="开票金额(含税)" width="150">
<template slot-scope="scope">
{{ Number(scope.row.开票金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column align="center" label="开票时间" width="150">
<template slot-scope="scope">
{{ scope.row.开票时间 }}
</template>
</el-table-column>
<el-table-column align="center" label="备注">
<template slot-scope="scope">
{{ scope.row.备注 }}
</template>
</el-table-column>
</el-table>
</el-carousel-item>
<el-carousel-item>
<el-button type="text" style="margin: 3px;padding: 0px;" @click="goToInvoiceDeliveryManagement">发货情况</el-button>
<el-table
v-loading="tableDataLoadingDeliveryManagement"
id="tb"
:data="tableDataDeliveryManagement"
highlight-current-row
style="width: 99%"
height="100"
border
stripe
size="mini"
>
<el-table-column align="center" label="发货单号">
<template slot-scope="scope">
{{ scope.row.发货单号 }}
</template>
</el-table-column>
<el-table-column align="center" label="收货地址" width="230">
<template slot-scope="scope">
{{ scope.row.省份 + scope.row.市名 + scope.row.详细地址 }}
</template>
</el-table-column>
<el-table-column align="center" label="收货人">
<template slot-scope="scope">
{{ scope.row.联系人 }}
</template>
</el-table-column>
<el-table-column align="center" label="联系电话">
<template slot-scope="scope">
{{ scope.row.联系方式 }}
</template>
</el-table-column>
<el-table-column align="center" label="车辆牌号">
<template slot-scope="scope">
{{ scope.row.车辆牌号 }}
</template>
</el-table-column>
<el-table-column align="center" label="发货日期">
<template slot-scope="scope">
{{ scope.row.发货日期 }}
</template>
</el-table-column>
<el-table-column align="center" label="运输状态">
<template slot-scope="scope">
{{ scope.row.运输状态 }}
</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.签收人 }}
</template>
</el-table-column>
</el-table>
</el-carousel-item>
<el-carousel-item>
<el-button type="text" style="margin: 3px;padding: 0px;" @click="goToBidBond">投标保证金</el-button>
<el-table
v-loading="tableData1LoadingBidBond"
:data="tableDataBidBond"
style="width: 99%"
height="100"
border
stripe
size="mini">
<el-table-column align="center" label="投标结果" width="190">
<template slot-scope="scope">
<el-radio-group v-model="scope.row.投标结果">
<el-radio :disabled="scope.row.是否禁用已中标" label="1">已中标</el-radio>
<el-radio :disabled="scope.row.是否禁用未中标" label="2">未中标</el-radio>
</el-radio-group>
</template>
</el-table-column>
<el-table-column align="center" label="公布日期" width="100">
<template slot-scope="scope">
{{ !scope.row.公布日期 ? '未公布' : scope.row.公布日期.substring(0 , scope.row.公布日期.length - 8) }}
</template>
</el-table-column>
<el-table-column align="center" label="招标企业" width="180">
<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="120">
<template slot-scope="scope">
{{ scope.row.联系电话 }}
</template>
</el-table-column>
<el-table-column align="center" label="保证金金额" width="100">
<template slot-scope="scope">
<el-tag style="width: 80px" size="small">{{ Number(scope.row.保证金金额).toFixed(2) }}</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="中标服务费" width="100">
<template slot-scope="scope">
{{ Number(scope.row.中标服务费).toFixed(2) }}
</template>
</el-table-column>
<el-table-column align="center" label="转履约保证金金额" width="150">
<template slot-scope="scope">
{{ Number(scope.row.转履约保证金金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column align="center" label="应收回金额" width="100">
<template slot-scope="scope">
{{ Number(scope.row.应收回金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column align="center" label="实收回金额" width="100">
<template slot-scope="scope">
<el-tag v-if="parseInt(scope.row.是否收回) === 2" size="small" type="success" style="width: 66px">{{ Number(scope.row.应收回金额).toFixed(2) }}</el-tag>
<el-tag v-else slot="reference" type="danger" size="small" style="width: 66px">未收回</el-tag>
</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="150">
<template slot-scope="scope">
{{ scope.row.保证金类型 }}
</template>
</el-table-column>
<el-table-column align="center" label="投标日期" width="150">
<template slot-scope="scope">
{{ scope.row.投标日期.substring(0, scope.row.投标日期.length - 8) }}
</template>
</el-table-column>
<el-table-column align="center" label="计划收回日期" width="150">
<template slot-scope="scope">
{{ !scope.row.预计收回日期 ? '结果未公布' : scope.row.预计收回日期.substring(0, scope.row.预计收回日期.length - 8) }}
</template>
</el-table-column>
<el-table-column align="center" label="实际收回日期" width="150">
<template slot-scope="scope">
{{ !scope.row.实际收回日期 ? '未收回' : scope.row.实际收回日期.substring(0, scope.row.实际收回日期.length - 8) }}
</template>
</el-table-column>
<el-table-column align="center" label="状态" width="120">
<template slot-scope="scope">
<el-tag v-if="scope.row.预计收回日期===''||scope.row.预计收回日期===null" slot="reference" size="small" style="width: 66px">未公布</el-tag>
<el-tag v-else-if="scope.row.预计收回日期!==''&&scope.row.预计收回日期!==null&&parseInt(scope.row.是否收回)===2" slot="reference" type="success" size="small" style="width: 66px">已收回</el-tag>
<el-tag v-else-if="scope.row.预计收回日期!==''&&scope.row.预计收回日期!==null&&parseInt(scope.row.状态) ===0" slot="reference" type="primary" size="small" style="width: 66px">未开始</el-tag>
<el-tag v-else-if="scope.row.预计收回日期!==''&&scope.row.预计收回日期!==null&&parseInt(scope.row.状态) ===1" slot="reference" type="warning" size="small" style="width: 66px">即将拖期</el-tag>
<el-tag v-else-if="scope.row.预计收回日期!==''&&scope.row.预计收回日期!==null&&parseInt(scope.row.状态) ===2" slot="reference" type="danger" size="small" style="width: 66px">已拖期</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="备注">
<template slot-scope="scope">
{{ scope.row.备注 }}
</template>
</el-table-column>
</el-table>
</el-carousel-item>
<el-carousel-item>
<el-button type="text" style="margin: 3px;padding: 0px;" @click="goToPerformanceBond">履约保证金</el-button>
<el-table
v-loading="listLoadingPerformanceBond"
v-show="showPerformanceBond"
:data="tableDataPerformanceBond"
style="width: 99%"
height="100"
border
stripe
size="mini">
<el-table-column align="center" label="履约保证金金额">
<template slot-scope="scope">
<el-tag type="primary" size="small">{{ Number(scope.row.履约保证金金额).toFixed(2) }}</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="保证金类型">
<template slot-scope="scope">
{{ scope.row.保证金类型 }}
</template>
</el-table-column>
<el-table-column align="center" label="收回条件">
<template slot-scope="scope">
{{ scope.row.执行进度名 }}
</template>
</el-table-column>
<el-table-column align="center" label="截止时间">
<template slot-scope="scope">
{{ scope.row.提前X天提醒我 }}天内收回
</template>
</el-table-column>
<el-table-column align="center" label="是否收回">
<template slot-scope="scope">
<el-tag v-if="parseInt(scope.row.是否收回) === 1" slot="reference" size="small" type="success" style="width: 66px">已收回</el-tag>
<el-tag v-else-if="parseInt(scope.row.是否收回) === 0" slot="reference" type="danger" size="small" style="width: 66px">未收回</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="实际收回日期">
<template slot-scope="scope">
{{ scope.row.实际收回日期 === '' || scope.row.实际收回日期 === null ? scope.row.实际收回日期 = '暂未收回' : scope.row.实际收回日期 }}
</template>
</el-table-column>
<el-table-column align="center" label="状态">
<template slot-scope="scope">
<el-popover
placement="top-start"
title="收回计划"
width="200"
trigger="hover">
<div v-show="(scope.row.计划收款日期 === '' || scope.row.计划收款日期 === null) && parseInt(scope.row.是否收回)!== 1 " style="text-align: center">
<h4>{{ scope.row.执行进度名 }} 未完成</h4>
</div>
<div v-show="scope.row.计划收款日期 !== '' && scope.row.计划收款日期 !== null && parseInt(scope.row.是否收回)!== 1">
<h4>{{ scope.row.执行进度名 }}{{ scope.row.节点日期 }}完成计划于{{ scope.row.计划收款日期 }}进行收款距离计划截止还剩{{ parseInt(scope.row.剩余天数) > 0 ? scope.row.剩余天数 : 0 }}</h4>
</div>
<div v-show="parseInt(scope.row.是否收回)=== 1 " style="text-align: center">
<h4>已于{{ scope.row.实际收回日期 }}收回</h4>
</div>
<el-tag v-if="scope.row.计划收款日期!==''&& scope.row.计划收款日期!==null && parseInt(scope.row.是否收回) === 0 && parseInt(scope.row.状态) === 1" slot="reference" size="small" type="warning" style="width: 66px">即将拖期</el-tag>
<el-tag v-else-if="scope.row.计划收款日期!==''&& scope.row.计划收款日期!==null &&parseInt(scope.row.是否收回) === 0 && parseInt(scope.row.状态) === 2" slot="reference" type="danger" size="small" style="width: 66px">已经拖期</el-tag>
<el-tag v-else-if="scope.row.计划收款日期!==''&& scope.row.计划收款日期!==null &&parseInt(scope.row.是否收回) === 0 && parseInt(scope.row.状态) === 0" slot="reference" type="primer" size="small" style="width: 66px">无计划</el-tag>
<el-tag v-else-if="scope.row.计划收款日期!==''&& scope.row.计划收款日期!==null &&parseInt(scope.row.是否收回) === 1" slot="reference" type="success" size="small" style="width: 66px">已完成</el-tag>
<el-tag v-else-if="scope.row.计划收款日期===''||scope.row.计划收款日期===null" slot="reference" size="small" style="width: 66px">进度未完</el-tag>
</el-popover>
</template>
</el-table-column>
</el-table>
<div v-show="performanceGuaranteeShow" style="width: 300px;margin: 0 auto;">
<viewer>
<img :src="url" height="250px" style="margin: 0 auto;border: 1px solid black" alt="">
</viewer>
</div>
</el-carousel-item>
<el-carousel-item>
<el-button type="text" style="margin: 3px;padding: 0px;" @click="goToSafetyMargin">安全保证金</el-button>
<el-table
v-loading="listLoadingSafetyMargin"
:data="tableDataSafetyMargin"
style="width: 99%"
height="100"
border
stripe
size="mini">
<el-table-column align="center" label="保证金金额" width="100">
<template slot-scope="scope">
<el-tag type="primary" size="small">{{ Number(scope.row.保证金金额).toFixed(2) }}</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="交付日期" width="150">
<template slot-scope="scope">
{{ !!scope.row.交付日期 ? scope.row.交付日期.substring(0, scope.row.交付日期.length - 8) : scope.row.交付日期 }}
</template>
</el-table-column>
<el-table-column align="center" label="收回条件" width="130">
<template slot-scope="scope">
{{ scope.row.执行进度名 }}
</template>
</el-table-column>
<el-table-column align="center" label="截止时间(天)" width="150">
<template slot-scope="scope">
{{ scope.row.提前x天提醒 }}天内收回
</template>
</el-table-column>
<el-table-column align="center" label="扣款金额" width="100">
<template slot-scope="scope">
{{ Number(scope.row.扣款金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column label="应收回金额" align="center" width="120">
<template slot-scope="scope">
{{ Number(scope.row.应收回金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column label="实际收回金额" align="center" width="120">
<template slot-scope="scope">
{{ scope.row.实际收回日期 === '' || scope.row.实际收回日期 === null ? '0' : Number(scope.row.应收回金额).toFixed(2) }}
</template>
</el-table-column>
<el-table-column align="center" label="是否收回" width="100">
<template slot-scope="scope">
<el-tag v-if="parseInt(scope.row.是否收回) === 2" slot="reference" size="small" type="success" style="width: 66px">已收回</el-tag>
<el-tag v-else-if="parseInt(scope.row.是否收回) === 1" slot="reference" type="danger" size="small" style="width: 66px">未收回</el-tag>
</template>
</el-table-column>
<el-table-column align="center" label="实际收回日期" width="130">
<template slot-scope="scope">
{{ scope.row.实际收回日期 === '' || scope.row.实际收回日期 === null ? '未收回' : scope.row.实际收回日期 }}
</template>
</el-table-column>
<el-table-column align="center" label="状态" width="100">
<template slot-scope="scope">
<el-popover
placement="top-start"
title="收回计划"
width="200"
trigger="hover">
<div v-show="(scope.row.预计收回日期 === '' || scope.row.预计收回日期 === null) && parseInt(scope.row.是否收回)!== 2 " style="text-align: center">
<h4>{{ scope.row.执行进度名 }} 未完成</h4>
</div>
<div v-show="scope.row.预计收回日期 !== '' && scope.row.预计收回日期 !== null && parseInt(scope.row.是否收回)!== 2">
<h4>{{ scope.row.执行进度名 }}{{ !scope.row.节点日期 ? scope.row.节点日期 : scope.row.节点日期.substring(0, scope.row.预计收回日期.length - 8) }}完成计划于{{ !scope.row.预计收回日期 ? scope.row.预计收回日期 : scope.row.预计收回日期.substring(0, scope.row.预计收回日期.length - 8) }}进行收款距离计划截止还剩{{ parseInt(scope.row.剩余天数) > 0 ? scope.row.剩余天数 : 0 }}</h4>
</div>
<div v-show="parseInt(scope.row.是否收回)=== 2 " style="text-align: center">
<h4>已于{{ !scope.row.实际收回日期 ? scope.row.实际收回日期 : scope.row.实际收回日期.substring(0, scope.row.实际收回日期.length - 8) }}收回</h4>
</div>
<el-tag v-if="scope.row.预计收回日期!==''&& scope.row.预计收回日期!==null && parseInt(scope.row.是否收回) === 1 && parseInt(scope.row.状态) === 1" slot="reference" size="small" type="warning" style="width: 66px">即将拖期</el-tag>
<el-tag v-else-if="scope.row.预计收回日期!==''&& scope.row.预计收回日期!==null &&parseInt(scope.row.是否收回) === 1 && parseInt(scope.row.状态) === 2" slot="reference" type="danger" size="small" style="width: 66px">已经拖期</el-tag>
<el-tag v-else-if="scope.row.预计收回日期!==''&& scope.row.预计收回日期!==null &&parseInt(scope.row.是否收回) === 1 && parseInt(scope.row.状态) === 0" slot="reference" type="primer" size="small" style="width: 66px">无计划</el-tag>
<el-tag v-else-if="scope.row.预计收回日期!==''&& scope.row.预计收回日期!==null &&parseInt(scope.row.是否收回) === 2" slot="reference" type="success" size="small" style="width: 66px">已完成</el-tag>
<el-tag v-else-if="scope.row.预计收回日期===''||scope.row.预计收回日期===null" slot="reference" size="small" style="width: 66px">进度未完</el-tag>
<div v-show="false">{{ scope.row.预计收回日期===''||scope.row.预计收回日期===null || parseInt(scope.row.是否收回) === 2 ? scope.row.是否禁用收回 = true : scope.row.是否禁用收回 = false }}</div>
</el-popover>
</template>
</el-table-column>
<el-table-column align="center" label="备注">
<template slot-scope="scope">
{{ scope.row.备注 }}
</template>
</el-table-column>
</el-table>
</el-carousel-item>
</el-carousel>
</div>
</el-card>
</div>
</template>
<script>
import request from '@/utils/request'
import elInput from 'element-ui/packages/input'
import { readImg } from '@/utils/request'
import { initProject, selectProvince, SelectMarketingManager, searchTable1, selectMachine, searchTableDataInvoiceRecord, searchTableContractCapitalManagement, searchTableSafetyMargin, searchTableBidBond, typeOfPerformanceBond, searchTableDataPerformanceBond, searchTableDataDeliveryManagement } from '@/api/MarketingCenter/ComprehensiveInquiryMS'
export default {
components: {
elInput
},
data() {
return {
customerName1: '',
customerName1_check: '',
tableDataLoadingDeliveryManagement: false,
tableDataDeliveryManagement: [],
dialogVisible: false,
dialogImageUrl: '',
fileList: [],
performanceGuaranteeShow: false,
showPerformanceBond: false,
listLoadingPerformanceBond: false,
tableDataPerformanceBond: [],
tableDataContractCapitalManagement: [],
listLoadingContractCapitalManagement: false,
tableDataSafetyMargin: [],
listLoadingSafetyMargin: false,
tableData1LoadingBidBond: false,
tableDataBidBond: [],
entryNameValue: '',
entryName: [],
entryNameValue_check: null,
MarketingManagerValue: '',
peopleid_check: '',
startTime: '',
machine: '',
machine_check: '',
startTime_check: null,
endTime: '',
endTime_check: null,
param: '',
PageSize: 30,
PageCurrent: 1,
total: null,
dialogFormVisiblePeople: false,
Province: '',
ProvinceValue: '',
tableData3: [],
peopleid: '',
peoplename: '',
listLoading: false,
expands: [],
tableData1: [],
tableData2: [],
projectNum: '',
listLoadingInvoiceRecord: false,
tableDataInvoiceRecord: [],
a: 1,
b: 1,
url: ''
}
},
created() {
this.init()
this.fetchTableData1()
},
methods: {
init() {
this.getSelect(initProject, ['项目名称', '项目流水号'], 'entryName')
this.getSelect(selectProvince, ['省份', '省份流水号'], 'Province')
},
openName() {
this.dialogFormVisiblePeople = true
this.ProvinceValue = ''
this.tableData3 = []
},
changeProvince() {
SelectMarketingManager(this.ProvinceValue).then(response => {
this.tableData3 = response.data
})
},
offName() {
this.dialogFormVisiblePeople = false
this.peopleid = ''
this.c = ''
},
getName() {
this.dialogFormVisiblePeople = false
this.MarketingManagerValue = this.peoplename
},
handleChange(row) {
this.peopleid = row.营销经理流水号
this.peoplename = row.姓名
},
fetchTableData1() {
if (this.customerName1 === '' || this.customerName1 === null) { this.customerName1_check = 0 } else { this.customerName1_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 }
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.machine === '' || this.machine === null) { this.machine_check = 0 } else { this.machine_check = 1 }
this.listLoading = true
this.getTable(searchTable1, [this.PageCurrent, this.PageSize, this.entryNameValue, this.peopleid, this.entryNameValue_check, this.peopleid_check, this.startTime_check, this.endTime_check, this.startTime, this.endTime, this.machine_check, this.machine, this.customerName1_check, this.customerName1], ['tableData1', 'total', 'listLoading'])
this.tableDataInvoiceRecord = []
this.tableDataContractCapitalManagement = []
this.tableDataSafetyMargin = []
},
getRowKeys(row) {
return row.项目流水号
},
selectMachine(row) {
if (this.a === 1) {
this.expands.push(row.项目流水号)
this.b = row.项目流水号
this.a = 0
} else {
if (this.b === row.项目流水号) {
this.expands = []
this.a = 1
} else {
this.expands = []
this.expands.push(row.项目流水号)
this.a = 0
this.b = row.项目流水号
}
}
selectMachine(row.项目流水号).then(response => {
console.log(response.data)
this.tableData2 = response.data
})
this.projectNum = row.项目流水号
},
fetchTableData(row) {
this.projectNum = row.项目流水号
this.getFileList()
this.listLoadingInvoiceRecord = true
this.listLoadingContractCapitalManagement = true
this.listLoadingSafetyMargin = true
this.tableData1LoadingBidBond = true
this.listLoadingPerformanceBond = true
this.tableDataLoadingDeliveryManagement = true
searchTableDataInvoiceRecord(this.projectNum).then(response => {
this.listLoadingInvoiceRecord = false
const data = response.data
for (let i = 0; i < data.length; i++) {
data[i].开票时间 = data[i].开票时间.substring(0, data[i].开票时间.length - 8)
}
this.tableDataInvoiceRecord = data
})
searchTableContractCapitalManagement(this.projectNum).then(response => {
this.listLoadingContractCapitalManagement = false
const data = response.data
for (let i = 0; i < data.length; i++) {
if (parseFloat(data[i].付款百分比) >= 99.9) {
data[i].付款百分比 = 100
}
}
this.tableDataContractCapitalManagement = data
})
searchTableSafetyMargin(this.projectNum).then(response => {
this.listLoadingSafetyMargin = false
this.tableDataSafetyMargin = response.data
})
searchTableBidBond(this.projectNum).then(response => {
this.tableData1LoadingBidBond = false
const data = response.data
for (let i = 0; i < data.length; i++) {
data[i].投标结果 = (data[i].投标结果).toString()
if (parseInt(data[i].投标结果) === 1) {
data[i].是否禁用已中标 = false
data[i].是否禁用未中标 = true
} else if (parseInt(data[i].投标结果) === 2) {
data[i].是否禁用已中标 = true
data[i].是否禁用未中标 = false
} else {
data[i].是否禁用已中标 = false
data[i].是否禁用未中标 = false
}
}
this.tableDataBidBond = data
})
typeOfPerformanceBond(this.projectNum).then(response => {
const data = response.data[0].履约保证金类型
return parseInt(data)
}).then(data => {
if (data === 1) {
this.performanceGuaranteeShow = false
this.showPerformanceBond = true
searchTableDataPerformanceBond(this.projectNum).then(response => {
this.listLoadingPerformanceBond = false
const data = response.data
for (let i = 0; i < data.length; i++) {
data[i].实际收回日期 !== '' && data[i].实际收回日期 !== null ? data[i].实际收回日期 = data[i].实际收回日期.substring(0, data[i].实际收回日期.length - 8) : data[i].实际收回日期
data[i].节点日期 !== '' && data[i].节点日期 !== null ? data[i].节点日期 = data[i].节点日期.substring(0, data[i].节点日期.length - 8) : data[i].节点日期
data[i].计划收款日期 !== '' && data[i].计划收款日期 !== null ? data[i].计划收款日期 = data[i].计划收款日期.substring(0, data[i].计划收款日期.length - 8) : data[i].计划收款日期
}
this.tableDataPerformanceBond = data
})
} else {
this.performanceGuaranteeShow = true
this.showPerformanceBond = false
}
})
searchTableDataDeliveryManagement(this.projectNum).then(response => {
this.tableDataLoadingDeliveryManagement = false
const data = response.data
for (let i = 0; i < data.length; i++) {
data[i].发货日期 = data[i].发货日期.substring(0, data[i].发货日期.length - 9)
data[i].运输状态 === 0 ? data[i].运输状态 = '运输中' : data[i].运输状态 = '已签收'
}
this.tableDataDeliveryManagement = data
})
},
handleSizeChange(val) {
this.PageCurrent = 1
this.PageSize = val
this.fetchTableData1()
this.tableDataInvoiceRecord = []
this.tableDataContractCapitalManagement = []
this.tableDataSafetyMargin = []
},
handleCurrentChange(val) {
this.PageCurrent = val
this.fetchTableData1()
this.tableDataInvoiceRecord = []
this.tableDataContractCapitalManagement = []
this.tableDataSafetyMargin = []
},
goToInvoiceRecord() {
this.$router.push({ path: '/InvoiceRecord/index' })
},
goToContractCapitalManagement() {
this.$router.push({ path: '/ContractCapitalManagement/index' })
},
goToSafetyMargin() {
this.$router.push({ path: '/SafetyMargin/index' })
},
goToBidBond() {
this.$router.push({ path: '/BidBond/index' })
},
goToPerformanceBond() {
this.$router.push({ path: '/PerformanceBond/index' })
},
goToInvoiceDeliveryManagement() {
this.$router.push({ path: '/DeliveryManagement/index' })
},
handlePictureCardPreview(file) {
this.dialogImageUrl = file.url
this.dialogVisible = true
},
async getFileList() {
const { data } = await request({
url: '',
method: 'post',
data: {
type: '3',
name: `select * from 合同信息管理_履约保证金_履约保函 where 是否启用 = 1 and 项目流水号 = ${this.projectNum}`
}
})
this.url = readImg + data[0].文件标识
},
async handleRemove(file, fileList) {
const { data } = await request({
url: '',
method: 'post',
data: {
type: '4',
name: `update 合同信息管理_履约保证金_履约保函 set 是否启用 = 0 where 履约保函流水号 = ${file._id}`
}
})
if (data[0].result === '0') {
this.$message.error('上传失败')
}
},
beforeUpload(file) {
const isJPG = /^image\/.*/.test(file.type)
const isLt4M = file.size / 1024 / 1024 < 4
const isInvoiceNum = !!this.projectId
if (!isJPG) {
this.$message.error('只能上传图片。。')
}
if (!isLt4M) {
this.$message.error('上传图片大小不能超过 4MB!')
}
return isJPG && isLt4M && isInvoiceNum
},
onSuccess(res, file, fileList) {
fileList = []
if (res[0].result === '1') {
this.getFileList()
} else {
this.$message.error('上传失败')
}
}
}
}
</script>
<style scoped>
.el-carousel__item h3 {
color: #475669;
font-size: 14px;
opacity: 0.75;
line-height: 150px;
margin: 0;
}
.el-carousel__item:nth-child(2n) {
background-color: white;
}
.el-carousel__item:nth-child(2n+1) {
background-color: white;
}
</style>
<style lang="scss">
/*.subTableHeader {*/
/*th {*/
/*background: #8ff4ea !important;*/
/*color: black;*/
/*}*/
/*tr.el-table__row td {*/
/*background-color: #d8e5f6 !important;*/
/*}*/
/*tr.el-table__row.el-table__row--striped td {*/
/*background: #e9f0f9 !important;*/
/*}*/
/*}*/
.subTableHeader {
th {
background: #7eaced !important;
color: #FFFFFF;
}
tr.el-table__row td {
background-color: #d8e5f6 !important;
}
tr.el-table__row.el-table__row--striped td {
background: #e9f0f9 !important;
}
}
</style>