Commit b60297ec by yuzhenWang

Merge branch 'wyz' into 'test'

按需求修改

See merge request !144
parents 8367be89 2b3989c6
This source diff could not be displayed because it is too large. You can view the blob instead.
...@@ -273,7 +273,7 @@ ...@@ -273,7 +273,7 @@
</CommonDialog> </CommonDialog>
<!-- 设置出账年月弹窗 --> <!-- 设置出账年月弹窗 -->
<CommonDialog <CommonDialog
dialogTitle="设置本期出账金额" dialogTitle="设置本期出账年月(实)"
dialogWidth="80%" dialogWidth="80%"
:openDialog="settingBillYearMonthFlag" :openDialog="settingBillYearMonthFlag"
:showAction="true" :showAction="true"
...@@ -452,7 +452,7 @@ const editTableRef = ref(null) ...@@ -452,7 +452,7 @@ const editTableRef = ref(null)
const splitTableColumns = ref([ const splitTableColumns = ref([
{ {
prop: 'splitRatio', prop: 'splitRatio',
label: '出账比例', label: '出账比例(%)',
editType: 'input', editType: 'input',
inputType: 'decimal', // integer / decimalNumber / decimal inputType: 'decimal', // integer / decimalNumber / decimal
decimalDigits: 2, // 小数位数,默认2 decimalDigits: 2, // 小数位数,默认2
...@@ -542,38 +542,7 @@ const splitTableColumns = ref([ ...@@ -542,38 +542,7 @@ const splitTableColumns = ref([
required: true, required: true,
width: 150 width: 150
}, },
// {
// prop: 'amount',
// label: '原币种金额',
// editType: 'input',
// inputType: 'decimalNumber', // integer / decimalNumber / decimal
// decimalDigits: 2, // 小数位数,默认2
// required: true
// },
// {
// prop: 'originalAmount',
// label: '本次出账原币种金额',
// editType: 'input',
// inputType: 'decimalNumber', // integer / decimalNumber / decimal
// decimalDigits: 2, // 小数位数,默认2
// required: true
// },
// {
// prop: 'exchangeRate',
// label: '结算汇率',
// editType: 'input',
// inputType: 'decimal', // integer / decimalNumber / decimal
// decimalDigits: 2, // 小数位数,默认2
// required: true
// },
// {
// prop: 'hkdAmount',
// label: '港币出账金额',
// editType: 'input',
// inputType: 'decimalNumber', // integer / decimalNumber / decimal
// decimalDigits: 2, // 小数位数,默认2
// required: true
// },
{ {
prop: 'payoutYearMonth', prop: 'payoutYearMonth',
label: '出账年月(估)', label: '出账年月(估)',
...@@ -710,7 +679,8 @@ const confirmRateExchange = async () => { ...@@ -710,7 +679,8 @@ const confirmRateExchange = async () => {
const res = await editExchangeRateApi(formData) const res = await editExchangeRateApi(formData)
ElMessage.success('结算汇率修改成功') ElMessage.success('结算汇率修改成功')
rateExchangeFlag.value = false rateExchangeFlag.value = false
loadTableData() const params = searchFormRef.value.getFormData()
loadTableData(params)
} catch (error) { } catch (error) {
ElMessage.error('结算汇率修改失败') ElMessage.error('结算汇率修改失败')
rateExchangeFlag.value = true rateExchangeFlag.value = true
...@@ -1006,7 +976,8 @@ const handleSpiltSubmit = async () => { ...@@ -1006,7 +976,8 @@ const handleSpiltSubmit = async () => {
console.log('分期出账结果', res) console.log('分期出账结果', res)
installmentsBillFlag.value = false installmentsBillFlag.value = false
ElMessage.success('分期出账已保存') ElMessage.success('分期出账已保存')
loadTableData() const searchParams = searchFormRef.value.getFormData()
loadTableData(searchParams)
} catch (error) { } catch (error) {
installmentsBillFlag.value = true installmentsBillFlag.value = true
console.log('分期出账错误', error) console.log('分期出账错误', error)
...@@ -1039,9 +1010,18 @@ const addSpiltRecord = () => { ...@@ -1039,9 +1010,18 @@ const addSpiltRecord = () => {
id: generateId(), // 必须有 rowIdKey 对应的字段(默认 'id') id: generateId(), // 必须有 rowIdKey 对应的字段(默认 'id')
payoutCurrency: 'HKD', payoutCurrency: 'HKD',
ruleCurrency: selectedRow.value.ruleCurrency, ruleCurrency: selectedRow.value.ruleCurrency,
originalCurrency: selectedRow.value.originalCurrency originalCurrency: selectedRow.value.originalCurrency,
hkdToPayoutRate: '1'
} }
if (selectedRow.value.originalCurrency && selectedRow.value.originalCurrency == 'HKD') {
newRow.originalToHkdRate = '1'
}
// if (selectedRow.value.payoutCurrency && selectedRow.value.payoutCurrency == 'HKD') {
// newRow.hkdToPayoutRate = '1'
// }
console.log('====================================')
console.log('newRow', newRow)
console.log('====================================')
// 插入到表格数据最前面 // 插入到表格数据最前面
splitTableData.value.push(newRow) splitTableData.value.push(newRow)
} }
...@@ -1380,11 +1360,13 @@ loadTableData() ...@@ -1380,11 +1360,13 @@ loadTableData()
// 分页事件 // 分页事件
const handleSizeChange = val => { const handleSizeChange = val => {
pageSize.value = val pageSize.value = val
loadTableData() const params = searchFormRef.value.getFormData()
loadTableData(params)
} }
const handleCurrentChange = val => { const handleCurrentChange = val => {
currentPage.value = val currentPage.value = val
loadTableData() const params = searchFormRef.value.getFormData()
loadTableData(params)
} }
// 表格数据 // 表格数据
const tableData = ref([]) const tableData = ref([])
...@@ -1407,15 +1389,13 @@ const handleSelect = (e, row) => { ...@@ -1407,15 +1389,13 @@ const handleSelect = (e, row) => {
ruleCurrency: row.ruleCurrency, ruleCurrency: row.ruleCurrency,
originalCurrency: row.originalCurrency, originalCurrency: row.originalCurrency,
payoutCurrency: row.payoutCurrency, payoutCurrency: row.payoutCurrency,
hkdToPayoutRate: row.hkdToPayoutRate ? row.hkdToPayoutRate : '', hkdToPayoutRate: '',
exchangeRate: row.exchangeRate ? row.exchangeRate : '', exchangeRate: row.exchangeRate ? row.exchangeRate : '',
originalToHkdRate: row.originalToHkdRate ? row.originalToHkdRate : '', originalToHkdRate: '',
payoutAmount: row.payoutAmount ? Number(row.payoutAmount).toFixed(2) : '', payoutAmount: row.payoutAmount ? Number(row.payoutAmount).toFixed(2) : '',
ruleAmount: row.ruleAmount ? Number(row.ruleAmount).toFixed(2) : '', ruleAmount: row.ruleAmount ? Number(row.ruleAmount).toFixed(2) : '',
hkdAmount: row.hkdAmount ? Number(row.hkdAmount).toFixed(2) : '' hkdAmount: row.hkdAmount ? Number(row.hkdAmount).toFixed(2) : ''
} }
rateExchangeFlag.value = true rateExchangeFlag.value = true
} }
} }
...@@ -1465,6 +1445,7 @@ const updatePayoutAmountapi = async data => { ...@@ -1465,6 +1445,7 @@ const updatePayoutAmountapi = async data => {
const updatePayRollStatusDisable = ref(true) const updatePayRollStatusDisable = ref(true)
const multipleSelection = ref([]) const multipleSelection = ref([])
const handleSelectionChange = val => { const handleSelectionChange = val => {
multipleSelection.value = val multipleSelection.value = val
console.log('全选:', val) console.log('全选:', val)
// 完成检核按钮是否禁用 // 完成检核按钮是否禁用
...@@ -1481,7 +1462,8 @@ const submitSettingBillYearMonth = async () => { ...@@ -1481,7 +1462,8 @@ const submitSettingBillYearMonth = async () => {
if (res.code === 200) { if (res.code === 200) {
settingBillYearMonthFlag.value = false settingBillYearMonthFlag.value = false
ElMessage.success('完成检核,等待关账') ElMessage.success('完成检核,等待关账')
loadTableData() const params = searchFormRef.value.getFormData()
loadTableData(params)
} }
} catch (error) { } catch (error) {
console.error('检核失败:', error) console.error('检核失败:', error)
......
...@@ -376,10 +376,9 @@ const addReceivablesFormConfig = [ ...@@ -376,10 +376,9 @@ const addReceivablesFormConfig = [
visible: formData => formData.commissionBizType === 'R', visible: formData => formData.commissionBizType === 'R',
rules: [{ pattern: /^\d+$/, message: '只能输入正整数', trigger: 'blur' }] rules: [{ pattern: /^\d+$/, message: '只能输入正整数', trigger: 'blur' }]
}, },
// 等待key
{ {
type: 'month', type: 'month',
prop: 'commissionDateMonth', prop: 'commissionDate',
label: '入账月(估)', label: '入账月(估)',
placeholder: '请选择' placeholder: '请选择'
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment