|
|
@ -74,41 +74,35 @@ |
|
|
|
<!--End查询列表部分--> |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<el-dialog center :visible.sync="dialogVisible" width="70%"> |
|
|
|
<!-- 新增、编辑融资平仓付款信息 --> |
|
|
|
<el-dialog center :visible.sync="dialogVisible" width="70%" :show-close="false"> |
|
|
|
<el-form ref="form_obj" :model="formobj" :rules="rules" class="formaddcopy02"> |
|
|
|
<el-row style="border-top: 1px solid #E0E3EB"> |
|
|
|
<el-col :span="12"> |
|
|
|
<div class="span-sty">款项名称</div> |
|
|
|
<el-form-item><el-input class="addinputInfo addinputw" v-model="formobj.costTitleValue" clearable placeholder="" /></el-form-item> |
|
|
|
<el-select class="addinputInfo" v-model="formobj.costTitleValue" placeholder="请选择" @change="changeCostTitle" filterable clearable> |
|
|
|
<el-option v-for="item in costTitle_list" :key="item.detailSid" :label="item.closFundName" :value="item.closFundName"/> |
|
|
|
</el-select> |
|
|
|
</el-col> |
|
|
|
<el-col :span="12"> |
|
|
|
<div class="span-sty">融资付款开通日期</div> |
|
|
|
<el-form-item><el-date-picker class="addinputInfo" v-model="formobj.openDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期" /></el-form-item> |
|
|
|
<div class="span-sty">期数</div> |
|
|
|
<el-form-item><el-input class="addinputInfo addinputw" @keyup.native="formobj.period = getNumber(formobj.period, 0)" v-model="formobj.period" clearable placeholder="" /></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="12"> |
|
|
|
<div class="span-sty">期数</div> |
|
|
|
<el-form-item><el-input class="addinputInfo addinputw" @keyup.native="formobj.period = getNumber(formobj.period, 0)" v-model="formobj.period" clearable placeholder="" /></el-form-item> |
|
|
|
<div class="span-sty">平仓付款日期</div> |
|
|
|
<el-form-item><el-date-picker class="addinputInfo" v-model="formobj.exePayDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期" /></el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="12"> |
|
|
|
<div class="span-sty">付款单位</div> |
|
|
|
<el-form-item> |
|
|
|
<el-select class="addinputInfo" v-model="formobj.payCompany" placeholder="请选择" @change="changePayCompany" filterable clearable> |
|
|
|
<el-option v-for="item in payCompany_list" :key="item.companyInvoicingSid" :label="item.companyInvoicingName" :value="item.companyInvoicingName"/> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
<div class="span-sty">平仓付款金额</div> |
|
|
|
<el-form-item><el-input class="addinputInfo addinputw" @keyup.native="formobj.exePayPrice = getNumber(formobj.exePayPrice, 2)" v-model="formobj.exePayPrice" clearable placeholder="" /></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="12"> |
|
|
|
<div class="span-sty">银行账号</div> |
|
|
|
<el-form-item> |
|
|
|
<el-select class="addinputInfo" v-model="formobj.receivingAccount" placeholder="请选择" @change="receiveCompanyChange" clearable filterable> |
|
|
|
<el-option v-for="item in receiveCompany_list" :key="item.sid" :label="item.receivingAccount" :value="item.receivingAccount"></el-option> |
|
|
|
</el-select> |
|
|
|
|
|
|
|
</el-form-item> |
|
|
|
<div class="span-sty">付款单位</div> |
|
|
|
<el-form-item><span class="addinputInfo">{{ formobj.payCompany }}</span></el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="12"> |
|
|
|
<div class="span-sty">收款单位</div> |
|
|
@ -116,21 +110,21 @@ |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="24"> |
|
|
|
<el-col :span="12"> |
|
|
|
<div class="span-sty">开户行</div> |
|
|
|
<el-form-item><span class="addinputInfo">{{ formobj.bank }}</span></el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="12"> |
|
|
|
<div class="span-sty">平仓付款日期</div> |
|
|
|
<el-form-item><el-date-picker class="addinputInfo" v-model="formobj.exePayDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期" /></el-form-item> |
|
|
|
</el-col> |
|
|
|
<el-col :span="12"> |
|
|
|
<div class="span-sty">平仓付款金额</div> |
|
|
|
<el-form-item><el-input class="addinputInfo addinputw" @keyup.native="formobj.exePayPrice = getNumber(formobj.exePayPrice, 2)" v-model="formobj.exePayPrice" clearable placeholder="" /></el-form-item> |
|
|
|
<div class="span-sty">收款银行账号</div> |
|
|
|
<el-form-item> |
|
|
|
<el-select class="addinputInfo" v-model="formobj.receivingAccount" placeholder="请选择" clearable filterable> |
|
|
|
<el-option v-for="item in receivingAccount_list" :key="item.sid" :label="item.receivingAccount" :value="item.receivingAccount"></el-option> |
|
|
|
</el-select> |
|
|
|
</el-form-item> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
</el-row> |
|
|
|
<el-row> |
|
|
|
<el-col :span="24"> |
|
|
|
<div class="span-sty">备注</div> |
|
|
@ -143,6 +137,21 @@ |
|
|
|
<el-button size="small" @click="handleClose">取消</el-button> |
|
|
|
</div> |
|
|
|
</el-dialog> |
|
|
|
<!-- 修改融资付款开通日期 --> |
|
|
|
<el-dialog :visible.sync="dialogVisibleByDate" width="50%" :show-close="false"> |
|
|
|
<el-form ref="temp_obj" :model="tempobj" :rules="rules" class="formaddcopy02"> |
|
|
|
<el-row style="border-top: 1px solid #E0E3EB"> |
|
|
|
<el-col :span="24"> |
|
|
|
<div class="span-sty">付款开通日期</div> |
|
|
|
<el-date-picker class="addinputInfo" v-model="tempobj.openDate" type="date" clearable value-format="yyyy-MM-dd" placeholder="选择日期"/> |
|
|
|
</el-col> |
|
|
|
</el-row> |
|
|
|
</el-form> |
|
|
|
<div slot="footer" class="dialog-footer" style="text-align: center"> |
|
|
|
<el-button type="primary" size="small" @click="handleDateConfirm">确定</el-button> |
|
|
|
<el-button size="small" @click="handleDateClose">取消</el-button> |
|
|
|
</div> |
|
|
|
</el-dialog> |
|
|
|
</div> |
|
|
|
</template> |
|
|
|
|
|
|
@ -152,7 +161,7 @@ import pageye from '@/components/pagination/pageye' |
|
|
|
import ButtonBar from '@/components/ButtonBar' |
|
|
|
import req from '@/api/anruifinmanagement/financingClosingPayment' |
|
|
|
import payment from '@/api/anruifinmanagement/payment' |
|
|
|
import { getOrgSidByPath, getInvoicingList, fetchBySid } from '@/api/jichuxinxi/dictcommons' |
|
|
|
import { getOrgSidByPath, fetchBySid } from '@/api/jichuxinxi/dictcommons' |
|
|
|
|
|
|
|
export default { |
|
|
|
name: 'FinancingClosingPayment', |
|
|
@ -164,8 +173,15 @@ export default { |
|
|
|
data() { |
|
|
|
return { |
|
|
|
dialogVisible: false, |
|
|
|
dialogVisibleByDate: false, |
|
|
|
tempobj: { |
|
|
|
openDate: '', |
|
|
|
detailSid: '' |
|
|
|
}, |
|
|
|
costTitle_list: [], |
|
|
|
payCompany_list: [], |
|
|
|
receiveCompany_list: [], |
|
|
|
receivingAccount_list: [], |
|
|
|
formobj: { |
|
|
|
sid: '', // sid |
|
|
|
remarks: '', |
|
|
@ -173,7 +189,6 @@ export default { |
|
|
|
costTypeKey: '', |
|
|
|
costTypeValue: '', |
|
|
|
detailSid: '', // 付款申请明细的明细sid |
|
|
|
openDate: '', // 融资付款开通日期 |
|
|
|
period: '', // 期数 |
|
|
|
payCompanySid: '', // 付款单位sid |
|
|
|
payCompany: '', // 付款单位名称 |
|
|
@ -202,6 +217,13 @@ export default { |
|
|
|
btnKey: 'toAdd', |
|
|
|
btnLabel: '新增' |
|
|
|
}, |
|
|
|
{ |
|
|
|
type: 'primary', |
|
|
|
size: 'small', |
|
|
|
icon: '', |
|
|
|
btnKey: 'toEditByDate', |
|
|
|
btnLabel: '编辑融资付款开通日期' |
|
|
|
}, |
|
|
|
{ |
|
|
|
type: 'danger', |
|
|
|
size: 'small', |
|
|
@ -223,6 +245,7 @@ export default { |
|
|
|
tableKey: 0, |
|
|
|
list: [], |
|
|
|
sids: [], // 用于导出的时候保存已选择的SIDs |
|
|
|
multipleSelection: [], |
|
|
|
listLoading: false, |
|
|
|
// 翻页 |
|
|
|
listQuery: { |
|
|
@ -249,20 +272,12 @@ export default { |
|
|
|
}, |
|
|
|
created() { |
|
|
|
// 初始化变量 |
|
|
|
this.init() |
|
|
|
this.getList() |
|
|
|
}, |
|
|
|
mounted() { |
|
|
|
this.$refs['btnbar'].setButtonList(this.btnList) |
|
|
|
}, |
|
|
|
methods: { |
|
|
|
init() { |
|
|
|
getInvoicingList({ orgPath: window.sessionStorage.getItem('defaultOrgPath') }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.payCompany_list = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
getNumber(val, limit) { |
|
|
|
val = val.replace(/[^0-9.]/g, '') // 保留数字 |
|
|
|
val = val.replace(/^00/, '0.') // 开头不能有两个0 |
|
|
@ -296,6 +311,9 @@ export default { |
|
|
|
case 'toAdd': |
|
|
|
this.toAdd() |
|
|
|
break |
|
|
|
case 'toEditByDate': |
|
|
|
this.toEditByDate() |
|
|
|
break |
|
|
|
case 'doDel': |
|
|
|
this.doDel() |
|
|
|
break |
|
|
@ -308,6 +326,7 @@ export default { |
|
|
|
}, |
|
|
|
// 信息条数 获取点击时当前的sid |
|
|
|
handleSelectionChange(row) { |
|
|
|
this.multipleSelection = row |
|
|
|
const aa = [] |
|
|
|
row.forEach(element => { |
|
|
|
aa.push(element.sid) |
|
|
@ -378,6 +397,11 @@ export default { |
|
|
|
this.formobj.useOrgName = respsone.data.name |
|
|
|
} |
|
|
|
}) |
|
|
|
payment.selClosFundName({ useOrgSid: resp.data }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.costTitle_list = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
payment.selectByUseOrgSid({ useOrgSid: resp.data }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.receiveCompany_list = res.data |
|
|
@ -397,27 +421,56 @@ export default { |
|
|
|
req.fetchBySid(row.sid).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.formobj = res.data |
|
|
|
payment.selClosFundName({ useOrgSid: this.formobj.useOrgSid }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.costTitle_list = res.data |
|
|
|
} |
|
|
|
}) |
|
|
|
payment.selectByUseOrgSid({ useOrgSid: this.formobj.useOrgSid }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.receiveCompany_list = res.data |
|
|
|
this.receivingAccount_list = [] |
|
|
|
this.receiveCompany_list.forEach((e) => { |
|
|
|
if (e.companyName === this.formobj.receiveCompany && e.bank === this.formobj.bank) { |
|
|
|
this.receivingAccount_list.push({ |
|
|
|
receivingAccount: e.receivingAccount, |
|
|
|
sid: e.detailSid |
|
|
|
}) |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
changePayCompany(value) { |
|
|
|
const choose = this.payCompany_list.filter((item) => item.companyInvoicingName === value) |
|
|
|
changeCostTitle(value) { |
|
|
|
const choose = this.costTitle_list.filter((item) => item.closFundName === value) |
|
|
|
if (choose.length > 0 && choose !== null) { |
|
|
|
this.formobj.payCompanySid = choose[0].companyInvoicingSid |
|
|
|
} else { |
|
|
|
this.formobj.payCompanySid = '' |
|
|
|
} |
|
|
|
}, |
|
|
|
receiveCompanyChange(value) { |
|
|
|
const choose = this.receiveCompany_list.filter((item) => item.receivingAccount === value) |
|
|
|
if (choose !== null && choose.length > 0) { |
|
|
|
this.formobj.receiveCompanySid = choose[0].sid |
|
|
|
this.formobj.receiveCompany = choose[0].companyName |
|
|
|
this.formobj.detailSid = choose[0].detailSid |
|
|
|
this.formobj.payCompany = choose[0].payCompany |
|
|
|
this.formobj.payCompanySid = choose[0].payCompanySid |
|
|
|
this.formobj.receiveCompanySid = choose[0].receiveCompanySid |
|
|
|
this.formobj.receiveCompany = choose[0].receiveCompany |
|
|
|
this.formobj.bank = choose[0].bank |
|
|
|
this.formobj.receivingAccount = choose[0].receivingAccount |
|
|
|
this.receivingAccount_list = [] |
|
|
|
this.receiveCompany_list.forEach((e) => { |
|
|
|
if (e.companyName === this.formobj.receiveCompany && e.bank === this.formobj.bank) { |
|
|
|
this.receivingAccount_list.push({ |
|
|
|
receivingAccount: e.receivingAccount, |
|
|
|
sid: e.detailSid |
|
|
|
}) |
|
|
|
} |
|
|
|
}) |
|
|
|
} else { |
|
|
|
this.formobj.detailSid = '' |
|
|
|
this.formobj.payCompany = '' |
|
|
|
this.formobj.payCompanySid = '' |
|
|
|
this.formobj.receiveCompanySid = '' |
|
|
|
this.formobj.receiveCompany = '' |
|
|
|
this.formobj.bank = '' |
|
|
|
this.formobj.receivingAccount = '' |
|
|
|
this.receivingAccount_list = [] |
|
|
|
} |
|
|
|
}, |
|
|
|
handleConfirm() { |
|
|
@ -447,7 +500,6 @@ export default { |
|
|
|
costTypeKey: '', |
|
|
|
costTypeValue: '', |
|
|
|
detailSid: '', // 付款申请明细的明细sid |
|
|
|
openDate: '', // 融资付款开通日期 |
|
|
|
period: '', // 期数 |
|
|
|
payCompanySid: '', // 付款单位sid |
|
|
|
payCompany: '', // 付款单位名称 |
|
|
@ -467,6 +519,39 @@ export default { |
|
|
|
createByName: '' |
|
|
|
} |
|
|
|
}, |
|
|
|
toEditByDate() { |
|
|
|
if (this.multipleSelection.length === 1) { |
|
|
|
this.dialogVisibleByDate = true |
|
|
|
this.$nextTick(() => { |
|
|
|
this.$refs['temp_obj'].clearValidate() |
|
|
|
}) |
|
|
|
this.tempobj.openDate = this.multipleSelection[0].openDate |
|
|
|
} else { |
|
|
|
this.$message({ showClose: true, type: 'error', message: '请选择一条记录进行操作' }) |
|
|
|
} |
|
|
|
}, |
|
|
|
handleDateConfirm() { |
|
|
|
this.tempobj.detailSid = this.multipleSelection[0].detailSid |
|
|
|
this.$refs['temp_obj'].validate((valid) => { |
|
|
|
if (valid) { |
|
|
|
req.updateOpenDate({ sid: this.tempobj.detailSid, openDate: this.tempobj.openDate }).then((res) => { |
|
|
|
if (res.success) { |
|
|
|
this.$message({ showClose: true, type: 'success', message: '操作成功' }) |
|
|
|
this.handleDateClose() |
|
|
|
this.getList() |
|
|
|
} |
|
|
|
}) |
|
|
|
} |
|
|
|
}) |
|
|
|
}, |
|
|
|
handleDateClose() { |
|
|
|
this.dialogVisibleByDate = false |
|
|
|
this.$refs['temp_obj'].resetFields() |
|
|
|
this.tempobj = { |
|
|
|
openDate: '', |
|
|
|
detailSid: '' |
|
|
|
} |
|
|
|
}, |
|
|
|
// 删除 |
|
|
|
doDel() { |
|
|
|
if (this.sids.length === 0) { |
|
|
|