|
|
|
@ -44,7 +44,7 @@
|
|
|
|
|
</template>
|
|
|
|
|
<template v-if="column.dataIndex == 'amount'">
|
|
|
|
|
<a-input-number @change="onSelectChangeDetail" :precision="2" size="small" :controls="false"
|
|
|
|
|
:max="record.restAmount" v-model:value="record.amount" />
|
|
|
|
|
:max="record.maxRestAmount" v-model:value="record.restAmount" />
|
|
|
|
|
</template>
|
|
|
|
|
</template>
|
|
|
|
|
<template #footer>
|
|
|
|
@ -112,12 +112,12 @@
|
|
|
|
|
</a-spin>
|
|
|
|
|
</div>
|
|
|
|
|
</a-modal>
|
|
|
|
|
<a-modal width="400px" @cancel="exchangeFlag = false" @ok="handleSureExhange" :visible="exchangeFlag"
|
|
|
|
|
<a-modal width="500px" @cancel="exchangeFlag = false" @ok="handleSureExhange" :visible="exchangeFlag"
|
|
|
|
|
title="币别汇率折算">
|
|
|
|
|
<div>
|
|
|
|
|
<div v-for="(item, index) in exchangarr" :key="index">
|
|
|
|
|
<div style="margin-bottom: 15px;margin-top: 10px">
|
|
|
|
|
<span class="bold" style="margin-right: 10px;width:46px;display: inline-block">1{{ item.currencyTo
|
|
|
|
|
<span class="bold" style="margin-right: 10px;width:66px;display: inline-block">1{{ item.currencyTo
|
|
|
|
|
}}
|
|
|
|
|
=</span>
|
|
|
|
|
<a-input-number :addon-after="item.currencyFrom" :precision="4" size="small" :controls="false"
|
|
|
|
@ -202,7 +202,8 @@ const [registerTable1, { getSelectRows: getSelectRowsDetail, setTableData }] = u
|
|
|
|
|
pagination: false,
|
|
|
|
|
striped: false,
|
|
|
|
|
rowSelection: {
|
|
|
|
|
onChange: onSelectChangeDetail
|
|
|
|
|
onChange: onSelectChangeDetail,
|
|
|
|
|
fixed: true,
|
|
|
|
|
},
|
|
|
|
|
maxHeight: '900',
|
|
|
|
|
bordered: true,
|
|
|
|
@ -314,6 +315,9 @@ const onRowClick = (record, index) => {
|
|
|
|
|
}
|
|
|
|
|
PaymentFreeSettlementGetFees(data).then(res => {
|
|
|
|
|
if (res.succeeded) {
|
|
|
|
|
res.data.items.forEach(item=>{
|
|
|
|
|
item.maxRestAmount = item.restAmount
|
|
|
|
|
})
|
|
|
|
|
setTableData(res.data.items)
|
|
|
|
|
}
|
|
|
|
|
loading.value = false
|
|
|
|
@ -555,8 +559,8 @@ function handleSureExhange() {
|
|
|
|
|
list.forEach(item => {
|
|
|
|
|
item.originalCurrency = item.currency
|
|
|
|
|
item.currency = currency.value
|
|
|
|
|
item.originalAmount = item.amount
|
|
|
|
|
item.amount = Number((Number(item.amount) * Number(item.exchangeRate)).toFixed(2))
|
|
|
|
|
item.originalAmount = item.restAmount
|
|
|
|
|
item.restAmount = Number((Number(item.restAmount) * Number(item.exchangeRate)).toFixed(2))
|
|
|
|
|
})
|
|
|
|
|
emits('updateListFree', list, currency.value)
|
|
|
|
|
}
|
|
|
|
@ -642,11 +646,12 @@ function init() {
|
|
|
|
|
}
|
|
|
|
|
const totalAmount = ref(0)
|
|
|
|
|
function onSelectChangeDetail() {
|
|
|
|
|
console.log('list', 111)
|
|
|
|
|
const list = getSelectRowsDetail()
|
|
|
|
|
if (route.query.type == 'free') {
|
|
|
|
|
totalAmount.value = 0
|
|
|
|
|
list.forEach(item => {
|
|
|
|
|
totalAmount.value += Number(item.amount)
|
|
|
|
|
totalAmount.value += Number(item.restAmount)
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|