|
|
@ -11,187 +11,193 @@ |
|
|
|
</div> |
|
|
|
<div class="listconadd"> |
|
|
|
<div class="titwu"><span>付款申请</span></div> |
|
|
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formadd"> |
|
|
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
|
|
|
<el-row style="border-top: 1px solid #e0e3eb"> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>申请日期</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
<el-form-item><span>{{ formobj.createTime }}</span></el-form-item> |
|
|
|
<div class="span-sty">申请部门</div> |
|
|
|
<el-form-item><span class="addinputInfo">{{ formobj.deptName }}</span></el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>申请人</span> |
|
|
|
<el-col :span="8"> |
|
|
|
<div class="span-sty">申请人</div> |
|
|
|
<el-form-item><span class="addinputInfo">{{ formobj.name }}</span></el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
<el-form-item><span>{{ formobj.name }}</span></el-form-item> |
|
|
|
<div class="span-sty">申请日期</div> |
|
|
|
<el-form-item><span class="addinputInfo">{{ formobj.createTime }}</span></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>款项类别</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
<el-col :span="6"> |
|
|
|
<div class="span-sty">品牌</div> |
|
|
|
<el-form-item> |
|
|
|
<el-select v-model="formobj.costTypeValue" clearable filterable @change="changeCostType" placeholder="请选择"> |
|
|
|
<el-option v-for="item in costType_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"></el-option> |
|
|
|
<el-select class="addinputInfo" v-model="formobj.carBrandName" filterable placeholder="请选择" @change="changeCarBrand" clearable> |
|
|
|
<el-option v-for="item in carBrand_list" :key="item.sid" :label="item.brandName" :value="item.brandName"/> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>款项名称</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
<el-col :span="6"> |
|
|
|
<div class="span-sty">款项范围</div> |
|
|
|
<el-form-item> |
|
|
|
<el-select v-model="formobj.costTitleValue" clearable filterable @change="changeCostTitle" placeholder="请选择"> |
|
|
|
<el-option v-for="item in costTitle_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"></el-option> |
|
|
|
<el-select class="addinputInfo" v-model="formobj.costRangeValue" clearable filterable @change="changeCostRange" placeholder="请选择"> |
|
|
|
<el-option v-for="item in costRange_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"></el-option> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>业务编号</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
<el-col :span="6"> |
|
|
|
<div class="span-sty">款项类别</div> |
|
|
|
<el-form-item> |
|
|
|
<el-input v-model="formobj.busSid" class="addinputw" placeholder="" clearable/> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>付款单位名称</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
<el-form-item> |
|
|
|
<el-select v-model="formobj.payCompany" filterable placeholder="请选择" @change="changePayCompany" clearable> |
|
|
|
<el-option v-for="item in payCompany_list" :key="item.sid" :label="item.name" :value="item.name"/> |
|
|
|
<el-select class="addinputInfo" v-model="formobj.costTypeValue" clearable filterable @change="changeCostType" placeholder="请选择"> |
|
|
|
<el-option v-for="item in costType_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"></el-option> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>收款单位名称</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
<el-col :span="6"> |
|
|
|
<div class="span-sty"><span class="icon">*</span>是否涉及车辆</div> |
|
|
|
<el-form-item> |
|
|
|
<el-select v-model="formobj.receiveCompany" filterable placeholder="请选择" @change="changeReceiveCompany" clearable> |
|
|
|
<el-option v-for="item in receiveCompany_list" :key="item.sid" :label="item.manufacturerName" :value="item.manufacturerName"/> |
|
|
|
</el-select> |
|
|
|
<el-radio-group class="addinputInfo" v-model="formobj.isVeh"> |
|
|
|
<el-radio label="1">是</el-radio> |
|
|
|
<el-radio label="0">否</el-radio> |
|
|
|
</el-radio-group> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>付款备注</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="20"> |
|
|
|
<el-col :span="8"> |
|
|
|
<div class="span-sty">付款单位</div> |
|
|
|
<el-form-item> |
|
|
|
<el-input v-model="formobj.remarks" placeholder="更多配置" clearable/> |
|
|
|
<el-select class="addinputInfo" v-model="formobj.payCompany" filterable placeholder="请选择" @change="changePayCompany" clearable> |
|
|
|
<el-option v-for="item in payCompany_list" :key="item.sid" :label="item.name" :value="item.name"/> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span>品牌</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
<div class="span-sty">付款申请备注</div> |
|
|
|
<el-form-item> |
|
|
|
<el-select v-model="formobj.carBrandName" filterable placeholder="请选择" @change="changeCarBrand" clearable> |
|
|
|
<el-option v-for="item in carBrand_list" :key="item.sid" :label="item.brandName" :value="item.brandName"/> |
|
|
|
</el-select> |
|
|
|
<el-input class="addinputInfo addinputw" v-model="formobj.remarks" placeholder="" clearable/> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="4" class="tleftb"> |
|
|
|
<span><span class="icon">*</span>是否涉及车辆</span> |
|
|
|
</el-col> |
|
|
|
<el-col :span="8"> |
|
|
|
<div class="span-sty"><span class="icon">*</span>是否事业部领导审批</div> |
|
|
|
<el-form-item> |
|
|
|
<el-radio v-model="formobj.isVeh" label="1">是</el-radio> |
|
|
|
<el-radio v-model="formobj.isVeh" label="0">否</el-radio> |
|
|
|
<el-radio-group class="addinputInfo" v-model="formobj.isLeaderSp"> |
|
|
|
<el-radio label="1">是</el-radio> |
|
|
|
<el-radio label="0">否</el-radio> |
|
|
|
</el-radio-group> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<div class="title"> |
|
|
|
<div class="title titleOne"> |
|
|
|
<div>付款明细</div> |
|
|
|
<div> |
|
|
|
<el-button type="primary" size="mini" icon="el-icon-plus" class="btntopblueline" @click="handleAdd()">添加</el-button> |
|
|
|
</div> |
|
|
|
<el-button type="primary" size="mini" icon="el-icon-plus" class="btntopblueline" @click="handleAdd()">添加</el-button> |
|
|
|
</div> |
|
|
|
<el-table :key="tableKey" :data="formobj.detailsList" :index="index" border style="width: 100%" show-summary :summary-method="getSummaries"> |
|
|
|
<el-table-column fixed width="80px" label="序号" type="index" :index="index + 1" align="center"/> |
|
|
|
<el-table-column fixed prop="name" label="操作" width="100px" align="center" header-align="center"> |
|
|
|
<el-table-column fixed width="80" label="序号" type="index" :index="index + 1" align="center"/> |
|
|
|
<el-table-column fixed label="操作" width="180" align="center"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-button size="mini" type="danger" @click="handleDelete(scope.$index)">删除 |
|
|
|
</el-button> |
|
|
|
<el-button size="mini" type="danger" @click="handleDelete(scope.$index)">删除</el-button> |
|
|
|
<el-button size="mini" type="primary" @click="handleAddPayment(scope.row, scope.$index)">新增付款信息</el-button> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="付款方式" align="center"> |
|
|
|
<el-table-column label="款项名称" align="center" width="200"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-select v-model="scope.row.paymentType" placeholder="请选择" filterable @change="changePaymentType($event, scope.row)"> |
|
|
|
<el-option v-for="item in payment_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"/> |
|
|
|
<el-select v-model="scope.row.costTitleValue" clearable filterable @change="changeCostTitle($event, scope.row)" placeholder="请选择"> |
|
|
|
<el-option v-for="item in costTitle_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"></el-option> |
|
|
|
</el-select> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="厂家回款通路" align="center"> |
|
|
|
<el-table-column label="付款方式" align="center" width="200"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-select v-model="scope.row.actualPay" placeholder="请选择" filterable @change="changeActualPay($event, scope.row)"> |
|
|
|
<el-option v-for="item in actualPay_list" :key="item.bankAccount" :label="item.actualPay" :value="item.actualPay"/> |
|
|
|
<el-select v-model="scope.row.paymentType" placeholder="请选择" filterable @change="changePaymentType($event, scope.row)"> |
|
|
|
<el-option v-for="item in payment_list" :key="item.dictKey" :label="item.dictValue" :value="item.dictValue"/> |
|
|
|
</el-select> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="开户行" align="center"> |
|
|
|
<el-table-column label="厂家回款通路" align="center" width="200"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<span>{{ scope.row.bank }}</span> |
|
|
|
<el-select v-model="scope.row.actualPay" placeholder="请选择" filterable @change="changeActualPay($event, scope.row)"> |
|
|
|
<el-option v-for="item in actualPay_list" :key="item.actualPaySid" :label="item.actualPay" :value="item.actualPay"/> |
|
|
|
</el-select> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="收款银行账号" align="center"> |
|
|
|
<el-table-column prop="receiveCompany" label="收款单位" align="center" width="150" /> |
|
|
|
<el-table-column prop="bank" label="开户行" align="center" width="140" /> |
|
|
|
<el-table-column prop="receivingAccount" label="收款银行账号" align="center" width="160" /> |
|
|
|
<el-table-column prop="payAccount" label="付款金额(元)" align="center" width="150"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<span>{{ scope.row.receivingAccount }}</span> |
|
|
|
<el-input v-model="scope.row.payAccount" placeholder="" clearable @keyup.native="scope.row.payAccount = getNumber(scope.row.payAccount, 2)" @keydown.native="scope.row.payAccount = getNumber(scope.row.payAccount, 2)"></el-input> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column prop="payAccount" label="付款金额(元)" align="center"> |
|
|
|
<el-table-column label="付款备注" align="center" min-width="200"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-input v-model="scope.row.payAccount" placeholder="" clearable @keyup.native="UpNumberOne($event, scope.row)" @keydown.native="UpNumberOne($event, scope.row)"></el-input> |
|
|
|
<el-input v-model="scope.row.remarks" placeholder="" clearable></el-input> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="付款备注" align="center"> |
|
|
|
<el-table-column label="关联付款详情" align="center" width="120"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-input v-model="scope.row.remarks" placeholder="" clearable></el-input> |
|
|
|
<el-button type="primary" size="mini" v-show="scope.row.finPaymentapplyDetailsBelowList.length > 0" @click="handleLookPayment(scope.row, scope.$index)">查看</el-button> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column prop="payAccountTotal" label="关联付款金额" align="center" width="140"/> |
|
|
|
</el-table> |
|
|
|
<div v-show="formobj.isVeh === '1'"> |
|
|
|
<div class="title"> |
|
|
|
<div v-show="formobj.costTypeKey == '001' && formobj.isVeh == '1'"><!-- 款项类别为主车厂家采购且是否涉及车辆为是时显示 --> |
|
|
|
<div class="title titleOne"> |
|
|
|
<div>车辆列表</div> |
|
|
|
<div> |
|
|
|
<el-button type="primary" size="mini" icon="el-icon-plus" class="btntopblueline" @click="handleselect()">选择</el-button> |
|
|
|
<div style="display: flex;flex-direction: row;justify-content: flex-start;align-items: center;"> |
|
|
|
<div style="margin-right: 10px"> |
|
|
|
<span><span class="icon">*</span>是否已销售:</span> |
|
|
|
<el-radio-group v-model="formobj.isSales"> |
|
|
|
<el-radio label="1">是</el-radio> |
|
|
|
<el-radio label="0">否</el-radio> |
|
|
|
</el-radio-group> |
|
|
|
</div> |
|
|
|
<div style="margin-right: 10px"> |
|
|
|
<span><span class="icon">*</span>款项是否已交清:</span> |
|
|
|
<el-radio-group v-model="formobj.isSettle"> |
|
|
|
<el-radio label="1">是</el-radio> |
|
|
|
<el-radio label="0">否</el-radio> |
|
|
|
</el-radio-group> |
|
|
|
</div> |
|
|
|
<el-button type="primary" size="mini" icon="el-icon-plus" class="btntopblueline" @click="toSelect()">选择</el-button> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<el-table :key="vehicleKey" :data="formobj.vehicleList" :index="index" border style="width: 100%" show-summary :summary-method="getSummaries"> |
|
|
|
<el-table-column fixed width="80px" label="序号" type="index" :index="index + 1" align="center"/> |
|
|
|
<el-table-column fixed prop="name" label="操作" width="100px" align="center" header-align="center"> |
|
|
|
<el-table-column fixed width="80" label="序号" type="index" :index="index + 1" align="center" /> |
|
|
|
<el-table-column fixed label="操作" width="100" align="center"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-button size="mini" type="danger" @click="Delete(scope.$index)">删除 |
|
|
|
</el-button> |
|
|
|
<el-button size="mini" type="danger" @click="toDelete(scope.$index)">删除</el-button> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="车型" align="center"> |
|
|
|
<el-table-column prop="modelName" label="车型" align="center" min-width="180" /> |
|
|
|
<el-table-column prop="vinNo" label="车架号" align="center" width="160" /> |
|
|
|
<el-table-column prop="marketSegmentsValue" label="版本" align="center" width="100" /> |
|
|
|
<el-table-column prop="carColor" label="颜色" align="center" width="100" /> |
|
|
|
<el-table-column prop="emissionStandardValue" label="排放" align="center" width="100" /> |
|
|
|
<el-table-column prop="tranCaseTypeValue" label="变速箱" align="center" width="110" /> |
|
|
|
<el-table-column prop="rearAxleValue" label="后桥" align="center" width="100" /> |
|
|
|
<el-table-column prop="libraryAge" label="厂家库龄" align="center" width="120" /> |
|
|
|
<el-table-column prop="orgLibraryAge" label="公司库龄" align="center" width="120" /> |
|
|
|
<el-table-column label="上装名称" align="center" width="130"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<span>{{ scope.row.modelName }}</span> |
|
|
|
<span class="bluezi" @click="lookTops(scope.row)">{{ scope.row.topName }}</span> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="车架号" align="center"> |
|
|
|
<el-table-column prop="insideCode" label="内部编码" align="center" width="120" /> |
|
|
|
<el-table-column prop="money" label="厂家结算价" align="center" width="130" /> |
|
|
|
<el-table-column label="合同/销售订单编号" align="center" width="180"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<span>{{ scope.row.vinNo }}</span> |
|
|
|
<span>{{ scope.row.contractNo }}/{{ scope.row.saleBillNo }}</span> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column label="厂家结算价" prop="money" align="center"> |
|
|
|
<el-table-column prop="customerName" label="客户名称" align="center" width="120" /> |
|
|
|
<el-table-column prop="saleTypeValue" label="销售订单类型" align="center" width="150" /> |
|
|
|
<el-table-column prop="settlementStatusValue" label="买断状态" align="center" width="120" /> |
|
|
|
<el-table-column label="是否申请买断" align="center" width="140"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<span>{{ scope.row.money }}</span> |
|
|
|
<el-radio-group v-if="scope.row.settlementStatusValue != '已买断'" v-model="scope.row.isSettle"> |
|
|
|
<el-radio label="1">是</el-radio> |
|
|
|
<el-radio label="0">否</el-radio> |
|
|
|
</el-radio-group> |
|
|
|
<span v-else>{{ scope.row.isSettle }}</span> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
@ -200,95 +206,149 @@ |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<!--End 添加修改部分--> |
|
|
|
<vehcile v-show="viewState == 2" ref="divVehicle" @backData="backData" @doback="closePage"/> |
|
|
|
<!-- 主车车辆列表选择车辆 --> |
|
|
|
<vehcile v-show="viewState == 2" ref="divVehicle" @backData="backData" @doback="resetState"/> |
|
|
|
<!-- 付款明细表新增关联付款信息 --> |
|
|
|
<el-dialog :visible.sync="paymentVisible" width="70%" :show-close="false"> |
|
|
|
<el-form class="formaddcopy02"> |
|
|
|
<div class="title titleOne"> |
|
|
|
<div>关联付款信息列表</div> |
|
|
|
<el-button type="primary" size="mini" class="btntopblueline" v-show="paymentBtn" @click="paymentAdd">新增</el-button> |
|
|
|
</div> |
|
|
|
<el-table :key="paymentKey" :data="paymentInformation.list" :index="index" border style="width: 100%"> |
|
|
|
<el-table-column fixed width="80" label="序号" type="index" :index="index + 1" align="center" /> |
|
|
|
<el-table-column fixed label="操作" width="180" align="center"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<el-button size="mini" type="danger" v-show="paymentBtn" @click="paymentDelete(scope.$index)">删除</el-button> |
|
|
|
<el-button size="mini" type="primary" @click="paymentLook(scope.row)">查看</el-button> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
<el-table-column prop="costTitleValue" label="款项名称" align="center" width="120" /> |
|
|
|
<el-table-column prop="paymentType" label="付款方式" align="center" width="120" /> |
|
|
|
<el-table-column prop="receiveCompany" label="收款单位名称" align="center" width="160" /> |
|
|
|
<el-table-column prop="bank" label="开户行" align="center" width="120" /> |
|
|
|
<el-table-column prop="receivingAccount" label="银行账号" align="center" width="120" /> |
|
|
|
<el-table-column prop="payAccount" label="付款金额" align="center" width="120" /> |
|
|
|
<el-table-column prop="remarks" label="付款备注" align="center" min-width="200" /> |
|
|
|
<el-table-column prop="isPay" label="后期是否有平仓付款" align="center" width="180"> |
|
|
|
<template slot-scope="scope"> |
|
|
|
<span>{{ scope.row.isPay == '1' ? '是' : '否' }}</span> |
|
|
|
</template> |
|
|
|
</el-table-column> |
|
|
|
</el-table> |
|
|
|
</el-form> |
|
|
|
<div style="text-align: center;padding-top: 5px"> |
|
|
|
<el-button size="small" type="primary" v-show="paymentBtn" @click="paymentSave">保存</el-button> |
|
|
|
<el-button size="small" @click="paymentClose">关闭</el-button> |
|
|
|
</div> |
|
|
|
</el-dialog> |
|
|
|
<!-- 关联付款信息新增 --> |
|
|
|
<paymentInformationAdd v-show="viewState == 3" ref="divPaymentInformation" @backInformation="backInformation" @doback="resetStateByInformation" /> |
|
|
|
<!-- 关联付款信息详情 --> |
|
|
|
<paymentInformationInfo v-show="viewState == 4" ref="divPaymentInformationInfo" @doback="resetStateByInformation" /> |
|
|
|
<!-- 查看上装配置信息 --> |
|
|
|
<tops v-show="viewState == 5" ref="divTops" @doback="resetState" /> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
|
|
|
|
<script> |
|
|
|
import req from '@/api/anruifinmanagement/payment' |
|
|
|
import { |
|
|
|
typeValues, |
|
|
|
getOrgSidByPath, |
|
|
|
fetchBySid, |
|
|
|
getGysByOrgSid, |
|
|
|
getListOrg, |
|
|
|
brandDown, |
|
|
|
selectNameByOrg |
|
|
|
} from '@/api/jichuxinxi/dictcommons' |
|
|
|
import { typeValues, getOrgSidByPath, fetchBySid, getListOrg, brandDown, selectNameByOrg } from '@/api/jichuxinxi/dictcommons' |
|
|
|
import vehcile from './relation/vehcile' |
|
|
|
import paymentInformationAdd from './relation/paymentInformationAdd' |
|
|
|
import paymentInformationInfo from './relation/paymentInformationInfo' |
|
|
|
import tops from '@/components/publicPage/tops' |
|
|
|
|
|
|
|
export default { |
|
|
|
name: 'fukuanshenqingAdd', |
|
|
|
name: 'PaymentAdd', |
|
|
|
components: { |
|
|
|
vehcile |
|
|
|
vehcile, |
|
|
|
paymentInformationAdd, |
|
|
|
paymentInformationInfo, |
|
|
|
tops |
|
|
|
}, |
|
|
|
data() { |
|
|
|
return { |
|
|
|
viewTitle: '', |
|
|
|
viewState: 1, |
|
|
|
submitdisabled: false, |
|
|
|
tableKey: 0, |
|
|
|
index: 0, |
|
|
|
vehicleKey: 1, |
|
|
|
viewState: 1, |
|
|
|
paymentKey: 2, |
|
|
|
index: 0, |
|
|
|
carBrand_list: [], |
|
|
|
costRange_list: [], |
|
|
|
costType_list: [], |
|
|
|
costTitle_list: [], |
|
|
|
payCompany_list: [], |
|
|
|
receiveCompany_list: [], |
|
|
|
payment_list: [], |
|
|
|
actualPay_list: [], |
|
|
|
formobj: { |
|
|
|
busSid: '', |
|
|
|
comment: '', |
|
|
|
costTitleKey: '', |
|
|
|
costTitleValue: '', |
|
|
|
costTypeKey: '', |
|
|
|
costTypeValue: '', |
|
|
|
createBySid: '', |
|
|
|
instanceId: '', |
|
|
|
name: '', |
|
|
|
payCompany: '', |
|
|
|
payCompanySid: '', |
|
|
|
receiveCompany: '', |
|
|
|
receiveCompanySid: '', |
|
|
|
remarks: '', |
|
|
|
sid: '', |
|
|
|
taskId: '', |
|
|
|
isVeh: '', |
|
|
|
carBrandName: '', |
|
|
|
carBrandSid: '', |
|
|
|
orgPath: '', |
|
|
|
billNo: '', // 申请编号 |
|
|
|
name: '', // 申请人姓名 |
|
|
|
deptSid: '', // 申请部门sid |
|
|
|
deptName: '', // 申请部门名称 |
|
|
|
createTime: '', // 申请日期 |
|
|
|
costRangeKey: '', // 款项范围Key |
|
|
|
costRangeValue: '', // 款项范围value |
|
|
|
isLeaderSp: '', // 是否事业部领导审批,1是0否 |
|
|
|
isSales: '', // 是否已销售 |
|
|
|
isSettle: '', // 款项是否已交清 |
|
|
|
costTypeKey: '', // 款项类别key |
|
|
|
costTypeValue: '', // 款项类别value |
|
|
|
cost: '', // 金额 |
|
|
|
payCompanySid: '', // 付款单位sid |
|
|
|
payCompany: '', // 付款单位名称 |
|
|
|
busSid: '', // 关联业务sid |
|
|
|
createOrgSid: '', // 创建组织 |
|
|
|
useOrgSid: '', // 使用组织 |
|
|
|
procInstId: '', // 流程实例id |
|
|
|
taskId: '', // 任务id |
|
|
|
isVeh: '', // 是否涉及车辆,1是,0否 |
|
|
|
paymentTotal: '', // 付款明细合计 |
|
|
|
carTotal: '', // 车辆金额合计 |
|
|
|
carBrandSid: '', // 品牌sid |
|
|
|
carBrandName: '', // 品牌名称 |
|
|
|
orgSidPath: '', |
|
|
|
detailsList: [], |
|
|
|
vehicleList: [] |
|
|
|
}, |
|
|
|
rules: {}, |
|
|
|
submitdisabled: false |
|
|
|
paymentVisible: false, // 付款明细表 -- 新增付款信息弹框 |
|
|
|
paymentBtn: false, // 付款明细表 -- 新增付款信息弹框 -- 页面按钮是否显示隐藏 |
|
|
|
paymentInformation: { // 关联付款信息列表 |
|
|
|
index: '', |
|
|
|
liquidationPayment: '', // 平仓款名称 |
|
|
|
list: [] |
|
|
|
} |
|
|
|
} |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
newDate() { |
|
|
|
let date = new Date() |
|
|
|
let year = date.getFullYear() // 年 |
|
|
|
let month = date.getMonth() + 1 // 月 |
|
|
|
let day = date.getDate() // 日 |
|
|
|
if (month < 10) { |
|
|
|
month = '0' + month |
|
|
|
} |
|
|
|
if (day < 10) { |
|
|
|
day = '0' + day |
|
|
|
} |
|
|
|
this.formobj.createTime = year + '-' + month + '-' + day |
|
|
|
}, |
|
|
|
UpNumberOne(e, row) { |
|
|
|
e.target.value = e.target.value.replace(/[^\d]/g, '') // 清除“数字”和“.”"-"以外的字符 |
|
|
|
e.target.value = e.target.value.replace(/^00/, '0') // 开头不能有两个0 |
|
|
|
if (e.target.value.indexOf('.') < 0 && e.target.value !== '' && e.target.value !== '-') { |
|
|
|
// 以上已经过滤,此处控制的是如果没有小数点,首位不能为类似于 01、02的金额 |
|
|
|
console.log(e.target.value) |
|
|
|
e.target.value = parseFloat(e.target.value) |
|
|
|
getNumber(val, limit) { |
|
|
|
val = val.replace(/[^0-9.]/g, '') // 保留数字 |
|
|
|
val = val.replace(/^00/, '0.') // 开头不能有两个0 |
|
|
|
val = val.replace(/^\./g, '0.') // 开头为小数点转换为0. |
|
|
|
val = val.replace(/\.{2,}/g, '.') // 两个以上的小数点转换成一个 |
|
|
|
val = val.replace('.', '$#$').replace(/\./g, '').replace('$#$', '.'); // 只保留一个小数点 |
|
|
|
/^0\d+/.test(val) ? val = val.slice(1) : '' // 两位以上数字开头不能为0 |
|
|
|
const str = '^(\\d+)\\.(\\d{' + limit + '}).*$' |
|
|
|
const reg = new RegExp(str) |
|
|
|
if (limit === 0) { |
|
|
|
// 不需要小数点 |
|
|
|
val = val.replace(reg, '$1') |
|
|
|
} else { |
|
|
|
// 通过正则保留小数点后指定的位数 |
|
|
|
val = val.replace(reg, '$1.$2') |
|
|
|
} |
|
|
|
row.payAccount = e.target.value |
|
|
|
return val |
|
|
|
}, |
|
|
|
DataDictionary() { |
|
|
|
typeValues({ type: 'payCostType' }).then((res) => { |
|
|
|
init() { |
|
|
|
typeValues({ type: 'paymentScope' }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.costRange_list = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
typeValues({ type: 'paymentCategory' }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.costType_list = res.data |
|
|
|
} |
|
|
@ -308,16 +368,11 @@ export default { |
|
|
|
this.payment_list = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
getPathSidByUserSid() { |
|
|
|
getOrgSidByPath({ orgPath: window.sessionStorage.getItem('defaultOrgPath') }).then((response) => { |
|
|
|
if (response.success) { |
|
|
|
getGysByOrgSid({ orgSid: response.data }).then((resp) => { |
|
|
|
if (resp.success) { |
|
|
|
this.formobj.payCompanySid = response.data |
|
|
|
this.receiveCompany_list = resp.data |
|
|
|
} |
|
|
|
}) |
|
|
|
this.formobj.createOrgSid = response.data |
|
|
|
this.formobj.useOrgSid = response.data |
|
|
|
this.formobj.payCompanySid = response.data |
|
|
|
fetchBySid(response.data).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.formobj.payCompany = res.data.name |
|
|
@ -332,19 +387,26 @@ export default { |
|
|
|
}) |
|
|
|
}, |
|
|
|
showAdd() { |
|
|
|
this.newDate() |
|
|
|
this.DataDictionary() |
|
|
|
this.getPathSidByUserSid() |
|
|
|
this.init() |
|
|
|
this.$nextTick(() => { |
|
|
|
this.$refs['form_obj'].clearValidate() |
|
|
|
}) |
|
|
|
this.viewTitle = '【新增】付款申请' |
|
|
|
this.formobj.createBySid = window.sessionStorage.getItem('userSid') |
|
|
|
this.formobj.name = window.sessionStorage.getItem('name') |
|
|
|
this.formobj.deptName = window.sessionStorage.getItem('defaultOrgPathName').substring(window.sessionStorage.getItem('defaultOrgPathName').lastIndexOf('/') + 1) |
|
|
|
this.formobj.deptSid = window.sessionStorage.getItem('defaultOrgPath').substring(window.sessionStorage.getItem('defaultOrgPath').lastIndexOf('/') + 1) |
|
|
|
this.formobj.orgPath = window.sessionStorage.getItem('defaultOrgPath') |
|
|
|
this.viewTitle = '【新增】付款申请' |
|
|
|
var nowDate = new Date() |
|
|
|
var date = { |
|
|
|
year: nowDate.getFullYear(), |
|
|
|
month: nowDate.getMonth() + 1, |
|
|
|
day: nowDate.getDate() |
|
|
|
} |
|
|
|
this.formobj.createTime = date.year + '-' + (date.month >= 10 ? date.month : '0' + date.month) + '-' + (date.day >= 10 ? date.day : '0' + date.day) |
|
|
|
}, |
|
|
|
showEdit(row) { |
|
|
|
this.DataDictionary() |
|
|
|
this.init() |
|
|
|
this.$nextTick(() => { |
|
|
|
this.$refs['form_obj'].clearValidate() |
|
|
|
}) |
|
|
@ -363,151 +425,234 @@ export default { |
|
|
|
this.formobj = row |
|
|
|
}) |
|
|
|
}, |
|
|
|
changeCarBrand(value) { |
|
|
|
const choose = this.carBrand_list.filter((item) => item.brandName === value) |
|
|
|
if (choose.length > 0 && choose !== null) { |
|
|
|
this.formobj.carBrandSid = choose[0].sid |
|
|
|
selectNameByOrg({ carBrandSid: this.formobj.carBrandSid }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.actualPay_list = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
} else { |
|
|
|
this.formobj.carBrandSid = '' |
|
|
|
this.actualPay_list = [] |
|
|
|
} |
|
|
|
}, |
|
|
|
changeCostRange(value) { |
|
|
|
const choose = this.costRange_list.filter((item) => item.dictValue === value) |
|
|
|
if (choose.length > 0 && choose !== null) { |
|
|
|
this.formobj.costRangeKey = choose[0].dictKey |
|
|
|
} else { |
|
|
|
this.formobj.costRangeKey = '' |
|
|
|
} |
|
|
|
}, |
|
|
|
changeCostType(value) { |
|
|
|
const choose = this.costType_list.filter((item) => item.dictValue === value) |
|
|
|
if (choose.length > 0 && choose !== null) { |
|
|
|
this.formobj.costTypeKey = choose[0].dictKey |
|
|
|
} else { |
|
|
|
this.formobj.costTypeKey = '' |
|
|
|
} |
|
|
|
}, |
|
|
|
changePayCompany(value) { |
|
|
|
const choose = this.payCompany_list.filter((item) => item.name === value) |
|
|
|
if (choose.length > 0 && choose !== null) { |
|
|
|
this.formobj.payCompanySid = choose[0].sid |
|
|
|
} else { |
|
|
|
this.formobj.payCompanySid = '' |
|
|
|
} |
|
|
|
}, |
|
|
|
handleAdd() { |
|
|
|
if (this.formobj.carBrandName === '') { |
|
|
|
this.$message({ showClose: true, type: 'error', message: '请先选择品牌' }) |
|
|
|
return |
|
|
|
} |
|
|
|
this.formobj.detailsList.push({ |
|
|
|
costTitleKey: '', |
|
|
|
costTitleValue: '', |
|
|
|
paymentType: '', |
|
|
|
paymentTypeKey: '', |
|
|
|
actualPay: '', |
|
|
|
receiveCompany: '', |
|
|
|
receiveCompanySid: '', |
|
|
|
bank: '', |
|
|
|
receivingAccount: '', |
|
|
|
payAccount: '', |
|
|
|
remarks: '', |
|
|
|
paymentType: '', |
|
|
|
paymentTypeKey: '', |
|
|
|
receivingAccount: '' |
|
|
|
isPay: '', |
|
|
|
payAccountTotal: '', |
|
|
|
finPaymentapplyDetailsBelowList: [] |
|
|
|
}) |
|
|
|
}, |
|
|
|
handleDelete(index) { |
|
|
|
this.formobj.detailsList.splice(index, 1) |
|
|
|
}, |
|
|
|
handleselect() { |
|
|
|
this.viewState = 2 |
|
|
|
this.$refs['divVehicle'].showData(this.formobj.vehicleList) |
|
|
|
handleAddPayment(row, index) { |
|
|
|
if (row.paymentType === '') { |
|
|
|
this.$message({ showClose: true, type: 'error', message: '付款方式不能为空' }) |
|
|
|
return |
|
|
|
} |
|
|
|
this.paymentVisible = true |
|
|
|
this.paymentBtn = true |
|
|
|
this.paymentInformation.index = index |
|
|
|
this.paymentInformation.liquidationPayment = this.formobj.createTime + row.paymentType + '平仓款' |
|
|
|
this.paymentInformation.list = JSON.parse(JSON.stringify(row.finPaymentapplyDetailsBelowList)) |
|
|
|
}, |
|
|
|
handleLookPayment(row, index) { |
|
|
|
this.paymentVisible = true |
|
|
|
this.paymentBtn = false |
|
|
|
this.paymentInformation.inde = index |
|
|
|
this.paymentInformation.liquidationPayment = this.formobj.createTime + row.paymentType + '平仓款' |
|
|
|
this.paymentInformation.list = JSON.parse(JSON.stringify(row.finPaymentapplyDetailsBelowList)) |
|
|
|
}, |
|
|
|
paymentAdd() { |
|
|
|
this.paymentVisible = false |
|
|
|
this.viewState = 3 |
|
|
|
this.$refs['divPaymentInformation'].showAdd(this.formobj.useOrgSid, this.paymentInformation.liquidationPayment) |
|
|
|
}, |
|
|
|
backInformation(value) { |
|
|
|
this.viewState = 1 |
|
|
|
this.paymentVisible = true |
|
|
|
value = JSON.parse(JSON.stringify(value)) |
|
|
|
this.paymentInformation.list.push({ |
|
|
|
sid: '', // sid |
|
|
|
costTitleKey: value.costTitleKey, // 款项名称,数据字典 |
|
|
|
costTitleValue: value.costTitleValue, // 款项名称 |
|
|
|
paymentTypeKey: value.paymentTypeKey, // 付款方式key |
|
|
|
paymentType: value.paymentType, // 付款方式value |
|
|
|
receiveCompany: value.receiveCompany, // 收款单位名称 |
|
|
|
receiveCompanySid: value.receiveCompanySid, // 收款单位sid |
|
|
|
bank: value.bank, // 开户行 |
|
|
|
receivingAccount: value.receivingAccount, // 收款银行账号 |
|
|
|
payAccount: value.payAccount, // 付款金额 |
|
|
|
detailSid: '', // 付款申请明细sid |
|
|
|
isPay: value.isPay, // 后期是否有平仓付款 |
|
|
|
remarks: value.remarks, // 付款备注 |
|
|
|
finPaymentapplyDetailsBelowEveList: value.finPaymentapplyDetailsBelowEveList |
|
|
|
}) |
|
|
|
}, |
|
|
|
resetStateByInformation() { |
|
|
|
this.viewState = 1 |
|
|
|
this.paymentVisible = true |
|
|
|
}, |
|
|
|
paymentDelete(index) { |
|
|
|
this.paymentInformation.list.splice(index, 1) |
|
|
|
}, |
|
|
|
paymentLook(row) { |
|
|
|
this.paymentVisible = false |
|
|
|
this.viewState = 4 |
|
|
|
this.$refs['divPaymentInformationInfo'].showInfo(row) |
|
|
|
}, |
|
|
|
Delete(index) { |
|
|
|
paymentSave() { |
|
|
|
if (this.formobj.detailsList.length > 0) { |
|
|
|
this.formobj.detailsList[this.paymentInformation.index].finPaymentapplyDetailsBelowList = this.paymentInformation.list |
|
|
|
this.formobj.detailsList.forEach((e) => { |
|
|
|
if (e.finPaymentapplyDetailsBelowList.length > 0) { |
|
|
|
e.finPaymentapplyDetailsBelowList.forEach((k) => { |
|
|
|
e.payAccountTotal = Math.round((parseFloat(e.payAccountTotal !== '' ? e.payAccountTotal : 0) + parseFloat(k.payAccount !== '' ? k.payAccount : 0)) * 100) / 100 |
|
|
|
}) |
|
|
|
} else { |
|
|
|
e.payAccountTotal = '' |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
this.paymentClose() |
|
|
|
}, |
|
|
|
paymentClose() { |
|
|
|
this.paymentVisible = false |
|
|
|
this.paymentBtn = false |
|
|
|
this.paymentInformation = { |
|
|
|
index: '', |
|
|
|
liquidationPayment: '', |
|
|
|
list: [] |
|
|
|
} |
|
|
|
}, |
|
|
|
toSelect() { |
|
|
|
if (this.formobj.isSettle !== '' && this.formobj.isSales !== '') { |
|
|
|
this.viewState = 2 |
|
|
|
this.$refs['divVehicle'].showData(this.formobj.vehicleList, this.formobj.useOrgSid, this.formobj.isSales, this.formobj.isSettle) |
|
|
|
} else { |
|
|
|
this.$message({ showClose: true, type: 'error', message: '是否已销售和款项是否已交清,请选择是或否' }) |
|
|
|
} |
|
|
|
}, |
|
|
|
toDelete(index) { |
|
|
|
this.formobj.vehicleList.splice(index, 1) |
|
|
|
}, |
|
|
|
// 车型常用配置列表--新增确定返回的数据 |
|
|
|
// 选择车辆--确定返回的数据 |
|
|
|
backData(value) { |
|
|
|
this.viewState = 1 |
|
|
|
value = JSON.parse(JSON.stringify(value)) |
|
|
|
if (value.length > 0) { |
|
|
|
value.forEach((e) => { |
|
|
|
this.formobj.vehicleList.push({ |
|
|
|
vinNo: e.vinNo, |
|
|
|
vehiSid: e.vehiSid, |
|
|
|
modelName: e.modelName, |
|
|
|
applySid: '', |
|
|
|
modelName: e.vehicleAlias, |
|
|
|
modelSid: e.modelSid, |
|
|
|
vinNo: e.vinNo, |
|
|
|
vehiSid: e.sid, |
|
|
|
money: e.money, |
|
|
|
configSid: e.configSid |
|
|
|
configSid: e.configSid, |
|
|
|
marketSegmentsValue: e.marketSegmentsValue, |
|
|
|
carColor: e.carColor, |
|
|
|
emissionStandardValue: e.emissionStandardValue, |
|
|
|
tranCaseTypeValue: e.tranCaseTypeValue, |
|
|
|
rearAxleValue: e.rearAxleValue, |
|
|
|
libraryAge: e.libraryAge, |
|
|
|
orgLibraryAge: e.orgLibraryAge, |
|
|
|
topName: e.topName, |
|
|
|
topSid: e.topSid, |
|
|
|
insideCode: e.insideCode, |
|
|
|
contractNo: e.contractNo, |
|
|
|
saleBillNo: e.saleBillNo, |
|
|
|
customerName: e.customerName, |
|
|
|
saleTypeValue: e.saleTypeValue, |
|
|
|
settlementStatusValue: e.settlementStatusValue, |
|
|
|
isSettle: e.settlementStatusValue === '已买断' ? '——' : '' |
|
|
|
}) |
|
|
|
}) |
|
|
|
} |
|
|
|
}, |
|
|
|
changeCarBrand(value) { |
|
|
|
let bb = null |
|
|
|
this.carBrand_list.forEach((e) => { |
|
|
|
if (e.brandName === value) { |
|
|
|
bb = { |
|
|
|
name: e.brandName, |
|
|
|
sid: e.sid |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
this.formobj.carBrandSid = bb.sid |
|
|
|
selectNameByOrg({ carBrandSid: this.formobj.carBrandSid }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.actualPay_list = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
lookTops(row) { |
|
|
|
this.viewState = 5 |
|
|
|
this.$refs['divTops'].showInfo({ sid: row.topSid }) |
|
|
|
}, |
|
|
|
changeCostTitle(value, row) { |
|
|
|
const choose = this.costTitle_list.filter((item) => item.dictValue === value) |
|
|
|
if (choose.length > 0 && choose !== null) { |
|
|
|
row.costTitleKey = choose[0].dictKey |
|
|
|
} else { |
|
|
|
row.costTitleKey = '' |
|
|
|
} |
|
|
|
}, |
|
|
|
changePaymentType(value, row) { |
|
|
|
let bb = null |
|
|
|
this.payment_list.forEach((e) => { |
|
|
|
if (e.dictValue === value) { |
|
|
|
bb = { |
|
|
|
value: e.dictValue, |
|
|
|
key: e.dictKey |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
row.paymentTypeKey = bb.key |
|
|
|
const choose = this.payment_list.filter((item) => item.dictValue === value) |
|
|
|
if (choose.length > 0 && choose !== null) { |
|
|
|
row.paymentTypeKey = choose[0].dictKey |
|
|
|
} else { |
|
|
|
row.paymentTypeKey = '' |
|
|
|
} |
|
|
|
}, |
|
|
|
changeActualPay(value, row) { |
|
|
|
let bb = null |
|
|
|
this.actualPay_list.forEach((e) => { |
|
|
|
if (e.actualPay === value) { |
|
|
|
bb = { |
|
|
|
actualPay: e.actualPay, |
|
|
|
bankAccount: e.bankAccount, |
|
|
|
depositBank: e.depositBank |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
row.actualPay = bb.actualPay |
|
|
|
row.bank = bb.depositBank |
|
|
|
row.receivingAccount = bb.bankAccount |
|
|
|
}, |
|
|
|
changeCostType(value) { |
|
|
|
let bb = null |
|
|
|
this.costType_list.forEach((e) => { |
|
|
|
if (e.dictValue === value) { |
|
|
|
bb = { |
|
|
|
key: e.dictKey, |
|
|
|
value: e.dictValue |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
this.formobj.costTypeKey = bb.key |
|
|
|
}, |
|
|
|
changeCostTitle(value) { |
|
|
|
let bb = null |
|
|
|
this.costTitle_list.forEach((e) => { |
|
|
|
if (e.dictValue === value) { |
|
|
|
bb = { |
|
|
|
key: e.dictKey, |
|
|
|
value: e.dictValue |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
this.formobj.costTitleKey = bb.key |
|
|
|
}, |
|
|
|
changePayCompany(value) { |
|
|
|
let bb = null |
|
|
|
this.payCompany_list.forEach((e) => { |
|
|
|
if (e.name === value) { |
|
|
|
bb = { |
|
|
|
name: e.name, |
|
|
|
sid: e.sid |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
this.formobj.payCompanySid = bb.sid |
|
|
|
}, |
|
|
|
changeReceiveCompany(value) { |
|
|
|
let bb = null |
|
|
|
this.receiveCompany_list.forEach((e) => { |
|
|
|
if (e.manufacturerName === value) { |
|
|
|
bb = { |
|
|
|
manufacturerName: e.manufacturerName, |
|
|
|
sid: e.sid |
|
|
|
} |
|
|
|
} |
|
|
|
}) |
|
|
|
this.formobj.receiveCompanySid = bb.sid |
|
|
|
const choose = this.actualPay_list.filter((item) => item.actualPay === value) |
|
|
|
if (choose.length > 0 && choose !== null) { |
|
|
|
row.actualPay = choose[0].actualPay |
|
|
|
row.receiveCompany = choose[0].manufacturerName |
|
|
|
row.bank = choose[0].depositBank |
|
|
|
row.receivingAccount = choose[0].bankAccount |
|
|
|
} else { |
|
|
|
row.actualPay = '' |
|
|
|
row.bank = '' |
|
|
|
row.receivingAccount = '' |
|
|
|
} |
|
|
|
}, |
|
|
|
saveOrUpdate() { |
|
|
|
this.$refs['form_obj'].validate((valid) => { |
|
|
|
if (valid) { |
|
|
|
this.submitdisabled = true |
|
|
|
req.saveOrUpdate(this.formobj).then((resp) => { |
|
|
|
this.submitdisabled = false |
|
|
|
if (resp.success) { |
|
|
|
this.$message({ |
|
|
|
showClose: true, |
|
|
|
type: 'success', |
|
|
|
message: resp.msg |
|
|
|
}) |
|
|
|
this.$message({ showClose: true, type: 'success', message: resp.msg }) |
|
|
|
this.handleReturn('true') |
|
|
|
} |
|
|
|
}).catch(() => { |
|
|
@ -527,13 +672,8 @@ export default { |
|
|
|
if (valid) { |
|
|
|
this.submitdisabled = true |
|
|
|
req.submitVehicleApply(this.formobj, this.formobj.sid).then((resp) => { |
|
|
|
this.submitdisabled = false |
|
|
|
if (resp.success) { |
|
|
|
this.$message({ |
|
|
|
showClose: true, |
|
|
|
type: 'success', |
|
|
|
message: resp.msg |
|
|
|
}) |
|
|
|
this.$message({ showClose: true, type: 'success', message: resp.msg }) |
|
|
|
this.handleReturn('true') |
|
|
|
} |
|
|
|
}).catch(() => { |
|
|
@ -564,7 +704,7 @@ export default { |
|
|
|
} |
|
|
|
}, 0) |
|
|
|
sums[index] += '' |
|
|
|
this.formobj.payAccountAll = sums[index] += '' |
|
|
|
this.formobj.paymentTotal = sums[index] += '' |
|
|
|
} else if (column.property === 'money') { |
|
|
|
sums[index] = values.reduce((prev, curr) => { |
|
|
|
const value = Number(curr) |
|
|
@ -575,45 +715,61 @@ export default { |
|
|
|
} |
|
|
|
}, 0) |
|
|
|
sums[index] += '' |
|
|
|
this.formobj.money = sums[index] += '' |
|
|
|
} else { |
|
|
|
if (!values.every(value => isNaN(value))) { |
|
|
|
sums[index] = values.reduce((prev, curr) => { |
|
|
|
const value = Number(curr) |
|
|
|
if (!isNaN(value)) { |
|
|
|
return prev + curr |
|
|
|
} else { |
|
|
|
return prev |
|
|
|
} |
|
|
|
}, 0) |
|
|
|
sums[index] += '' |
|
|
|
this.amount = sums[index] += '' |
|
|
|
} else { |
|
|
|
sums[index] = '' |
|
|
|
} |
|
|
|
this.formobj.carTotal = sums[index] += '' |
|
|
|
} |
|
|
|
}) |
|
|
|
return sums |
|
|
|
}, |
|
|
|
resetState() { |
|
|
|
this.viewState = 1 |
|
|
|
}, |
|
|
|
handleReturn(isreload) { |
|
|
|
if (isreload === 'true') this.$emit('reloadlist') |
|
|
|
this.formobj = {} |
|
|
|
this.submitdisabled = false |
|
|
|
this.$refs['form_obj'].resetFields() |
|
|
|
this.$emit('doback') |
|
|
|
}, |
|
|
|
closePage() { |
|
|
|
this.viewState = 1 |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
</script> |
|
|
|
|
|
|
|
<style scoped> |
|
|
|
.title { |
|
|
|
.span-sty { |
|
|
|
width: 150px !important; |
|
|
|
} |
|
|
|
.addinputInfo { |
|
|
|
margin-left: 140px !important; |
|
|
|
} |
|
|
|
.formaddcopy02 .el-row .el-col /deep/ .el-form-item .addinputw { |
|
|
|
margin-left: 140px !important; |
|
|
|
width: calc(100% - 135px); |
|
|
|
} |
|
|
|
/deep/ .el-form-item__error { |
|
|
|
margin-left: 140px !important; |
|
|
|
} |
|
|
|
.formaddcopy02 .el-row .el-col /deep/ .el-form-item .el-radio-group { |
|
|
|
display: inline; |
|
|
|
line-height: 1px; |
|
|
|
vertical-align: middle; |
|
|
|
} |
|
|
|
.titleOne { |
|
|
|
padding: 7px; |
|
|
|
display: flex; |
|
|
|
flex-direction: row; |
|
|
|
justify-content: space-between; |
|
|
|
align-items: center; |
|
|
|
} |
|
|
|
/* 覆盖element-ui的单选按钮样式 */ |
|
|
|
/deep/.titleOne .el-radio__input.is-checked .el-radio__inner { |
|
|
|
border-color: #409EFF; /* 未选中状态下的边框颜色 */ |
|
|
|
background-color: #409EFF; /* 选中后的背景色 */ |
|
|
|
} |
|
|
|
/* 如果需要改变选中后对勾的颜色 */ |
|
|
|
/deep/.titleOne .el-radio__input.is-checked .el-radio__inner:after { |
|
|
|
background-color: #000000; /* 对勾的颜色 */ |
|
|
|
} |
|
|
|
/deep/.titleOne .el-radio__input.is-checked+.el-radio__label { |
|
|
|
color: #000000; /* 选中后的字体颜色 */ |
|
|
|
} |
|
|
|
</style> |
|
|
|