verce-vue-test 0.0.154 → 0.0.156
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -1,32 +1,34 @@
|
|
|
1
|
-
import baseHttpClient
|
|
2
|
-
type HttpRequestOptions,
|
|
3
|
-
type TamResponse,
|
|
4
|
-
} from '@/utils/baseHttpClient'
|
|
5
|
-
import type {
|
|
6
|
-
ForeignCurrencyAuthorizationFilter,
|
|
7
|
-
ForeignCurrencyAuthorizationQueryResponseBody,
|
|
8
|
-
ForeignCurrencyAuthorizationReviewRequestBody,
|
|
9
|
-
} from './types'
|
|
1
|
+
import baseHttpClient from '@/utils/baseHttpClient'
|
|
10
2
|
|
|
11
3
|
/** 外币授权页面接口入口;TAM 公共报文头由 baseHttpClient 自动补齐。 */
|
|
12
4
|
const API = {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
5
|
+
accountBankQueryAPI: async (ccy: any) => {
|
|
6
|
+
const response = (await baseHttpClient.post(
|
|
7
|
+
'/TAM/0001/140201002',
|
|
8
|
+
{ ccy: String(ccy ?? '').trim() },
|
|
9
|
+
)) as any
|
|
10
|
+
|
|
11
|
+
const bankAcctList = response.body.bankAcctList
|
|
12
|
+
if (!Array.isArray(bankAcctList)) {
|
|
13
|
+
throw new Error('账户行接口返回结构不正确')
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
return [...new Set(
|
|
17
|
+
bankAcctList
|
|
18
|
+
.map((item) => String(item ?? '').trim())
|
|
19
|
+
.filter(Boolean),
|
|
20
|
+
)].map((bankAcct) => ({ bankAcct, bankName: bankAcct }))
|
|
21
|
+
},
|
|
22
|
+
|
|
23
|
+
queryAPI: (params: any) => baseHttpClient.post(
|
|
17
24
|
'/TAM/0001/140207001',
|
|
18
25
|
params,
|
|
19
|
-
|
|
20
|
-
),
|
|
26
|
+
) as any,
|
|
21
27
|
|
|
22
|
-
reviewAPI: (
|
|
23
|
-
params: ForeignCurrencyAuthorizationReviewRequestBody,
|
|
24
|
-
options?: HttpRequestOptions,
|
|
25
|
-
) => baseHttpClient.post<TamResponse<any>>(
|
|
28
|
+
reviewAPI: (params: any) => baseHttpClient.post(
|
|
26
29
|
'/TAM/0001/120207001',
|
|
27
30
|
params,
|
|
28
|
-
|
|
29
|
-
),
|
|
31
|
+
) as any,
|
|
30
32
|
}
|
|
31
33
|
|
|
32
34
|
export default API
|
|
@@ -9,12 +9,9 @@ import {
|
|
|
9
9
|
RefreshLeft,
|
|
10
10
|
Search,
|
|
11
11
|
} from '@element-plus/icons-vue'
|
|
12
|
-
import {
|
|
13
|
-
queryAccountBanks,
|
|
14
|
-
type AccountBankOption,
|
|
15
|
-
} from '@/api/account-bank'
|
|
16
12
|
import API from './api'
|
|
17
13
|
import { toAuthorizationRow } from './adapter'
|
|
14
|
+
import { foreignCurrencyAuthorizationBusinessContext } from './runtime'
|
|
18
15
|
import {
|
|
19
16
|
businessChannelOptions,
|
|
20
17
|
businessTypeOptions,
|
|
@@ -51,7 +48,7 @@ const detailEditForm = reactive({
|
|
|
51
48
|
rejectReason: '',
|
|
52
49
|
})
|
|
53
50
|
const reviewAction = ref<any>(null)
|
|
54
|
-
const accountBankOptions = ref<
|
|
51
|
+
const accountBankOptions = ref<any[]>([])
|
|
55
52
|
const accountBankLoading = ref(false)
|
|
56
53
|
|
|
57
54
|
let activeQueryController: AbortController | null = null
|
|
@@ -105,13 +102,8 @@ async function loadRows() {
|
|
|
105
102
|
{
|
|
106
103
|
...appliedFilters.value,
|
|
107
104
|
custCode: appliedFilters.value.custCode.trim(),
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
signal: controller.signal,
|
|
111
|
-
tamHead: {
|
|
112
|
-
pageIndex: currentPage.value,
|
|
113
|
-
pageSize: pageSize.value,
|
|
114
|
-
},
|
|
105
|
+
pageIndex: currentPage.value,
|
|
106
|
+
pageSize: pageSize.value,
|
|
115
107
|
},
|
|
116
108
|
)
|
|
117
109
|
|
|
@@ -150,6 +142,14 @@ function handleReset() {
|
|
|
150
142
|
Object.assign(filterForm, createDefaultForeignCurrencyAuthorizationFilter())
|
|
151
143
|
}
|
|
152
144
|
|
|
145
|
+
function getCurrentLocalDate() {
|
|
146
|
+
const currentDate = new Date()
|
|
147
|
+
const year = currentDate.getFullYear()
|
|
148
|
+
const month = String(currentDate.getMonth() + 1).padStart(2, '0')
|
|
149
|
+
const day = String(currentDate.getDate()).padStart(2, '0')
|
|
150
|
+
return `${year}-${month}-${day}`
|
|
151
|
+
}
|
|
152
|
+
|
|
153
153
|
async function handlePaginationChange(pagination: { page: number; pageSize: number }) {
|
|
154
154
|
currentPage.value = pagination.page
|
|
155
155
|
pageSize.value = pagination.pageSize
|
|
@@ -159,9 +159,9 @@ async function handlePaginationChange(pagination: { page: number; pageSize: numb
|
|
|
159
159
|
function openDetail(row: ForeignCurrencyAuthorizationRow) {
|
|
160
160
|
detailRecord.value = row
|
|
161
161
|
Object.assign(detailEditForm, {
|
|
162
|
-
author: row.author,
|
|
162
|
+
author: row.author || foreignCurrencyAuthorizationBusinessContext.currentUserName,
|
|
163
163
|
nostro: row.nostro,
|
|
164
|
-
valueDate: row.valueDate,
|
|
164
|
+
valueDate: row.valueDate || getCurrentLocalDate(),
|
|
165
165
|
rejectReason: row.rejectReason,
|
|
166
166
|
})
|
|
167
167
|
pageMode.value = 'detail'
|
|
@@ -181,10 +181,7 @@ async function handleAccountBankVisibleChange(visible: boolean) {
|
|
|
181
181
|
accountBankLoading.value = true
|
|
182
182
|
|
|
183
183
|
try {
|
|
184
|
-
const result = await
|
|
185
|
-
{ ccy: detailRecord.value.currency },
|
|
186
|
-
{ signal: controller.signal },
|
|
187
|
-
)
|
|
184
|
+
const result = await API.accountBankQueryAPI(detailRecord.value.currency)
|
|
188
185
|
if (controller.signal.aborted || accountBankRequestController !== controller) return
|
|
189
186
|
accountBankOptions.value = result
|
|
190
187
|
} catch (error) {
|
|
@@ -512,7 +509,7 @@ onBeforeUnmount(() => {
|
|
|
512
509
|
<div class="detail-content">
|
|
513
510
|
<section class="detail-section">
|
|
514
511
|
<h3>基本信息</h3>
|
|
515
|
-
<el-descriptions :column="
|
|
512
|
+
<el-descriptions :column="4" border size="small" class="detail-descriptions">
|
|
516
513
|
<el-descriptions-item label="记录ID">{{ detailRecord.id }}</el-descriptions-item>
|
|
517
514
|
<el-descriptions-item label="大额报备日期">{{ detailRecord.forecastDate }}</el-descriptions-item>
|
|
518
515
|
<el-descriptions-item label="计划汇款日期">{{ detailRecord.planDate }}</el-descriptions-item>
|
|
@@ -549,7 +546,7 @@ onBeforeUnmount(() => {
|
|
|
549
546
|
|
|
550
547
|
<section class="detail-section">
|
|
551
548
|
<h3>客户信息</h3>
|
|
552
|
-
<el-descriptions :column="
|
|
549
|
+
<el-descriptions :column="4" border size="small" class="detail-descriptions">
|
|
553
550
|
<el-descriptions-item label="客户分类">
|
|
554
551
|
{{ getOptionLabel(customerKindOptions, detailRecord.custKind) }}
|
|
555
552
|
</el-descriptions-item>
|
|
@@ -559,7 +556,7 @@ onBeforeUnmount(() => {
|
|
|
559
556
|
<el-descriptions-item label="客户号/证件号">
|
|
560
557
|
{{ detailRecord.custCode }}
|
|
561
558
|
</el-descriptions-item>
|
|
562
|
-
<el-descriptions-item label="客户名称" :span="
|
|
559
|
+
<el-descriptions-item label="客户名称" :span="4">
|
|
563
560
|
{{ detailRecord.custName }}
|
|
564
561
|
</el-descriptions-item>
|
|
565
562
|
</el-descriptions>
|
|
@@ -567,7 +564,7 @@ onBeforeUnmount(() => {
|
|
|
567
564
|
|
|
568
565
|
<section class="detail-section">
|
|
569
566
|
<h3>汇款信息</h3>
|
|
570
|
-
<el-descriptions :column="
|
|
567
|
+
<el-descriptions :column="4" border size="small" class="detail-descriptions">
|
|
571
568
|
<el-descriptions-item label="收款银行开户行" :span="2">
|
|
572
569
|
{{ detailRecord.pyeBankAgt }}
|
|
573
570
|
</el-descriptions-item>
|
|
@@ -580,7 +577,7 @@ onBeforeUnmount(() => {
|
|
|
580
577
|
<el-descriptions-item label="最终收款行 SWIFTCODE">
|
|
581
578
|
{{ detailRecord.rdfibic }}
|
|
582
579
|
</el-descriptions-item>
|
|
583
|
-
<el-descriptions-item label="账户行" :span="
|
|
580
|
+
<el-descriptions-item label="账户行" :span="4">
|
|
584
581
|
<el-select
|
|
585
582
|
v-model="detailEditForm.nostro"
|
|
586
583
|
class="detail-edit-control"
|
|
@@ -617,7 +614,7 @@ onBeforeUnmount(() => {
|
|
|
617
614
|
|
|
618
615
|
<section class="detail-section is-last">
|
|
619
616
|
<h3>报备与授权信息</h3>
|
|
620
|
-
<el-descriptions :column="
|
|
617
|
+
<el-descriptions :column="4" border size="small" class="detail-descriptions">
|
|
621
618
|
<el-descriptions-item label="报备人">{{ detailRecord.linkMan }}</el-descriptions-item>
|
|
622
619
|
<el-descriptions-item label="联系电话">{{ detailRecord.linkWay }}</el-descriptions-item>
|
|
623
620
|
<el-descriptions-item label="复核人">{{ detailRecord.supervisor }}</el-descriptions-item>
|
|
@@ -634,7 +631,7 @@ onBeforeUnmount(() => {
|
|
|
634
631
|
<el-descriptions-item label="报备说明" :span="2">
|
|
635
632
|
{{ displayValue(detailRecord.posRemark) }}
|
|
636
633
|
</el-descriptions-item>
|
|
637
|
-
<el-descriptions-item label="拒绝原因" :span="
|
|
634
|
+
<el-descriptions-item label="拒绝原因" :span="4">
|
|
638
635
|
<el-input
|
|
639
636
|
v-model="detailEditForm.rejectReason"
|
|
640
637
|
class="detail-edit-control"
|
|
@@ -903,14 +900,23 @@ onBeforeUnmount(() => {
|
|
|
903
900
|
}
|
|
904
901
|
|
|
905
902
|
.detail-descriptions :deep(.detail-edit-control .el-input__wrapper),
|
|
903
|
+
.detail-descriptions :deep(.detail-edit-control .el-select__wrapper),
|
|
906
904
|
.detail-descriptions :deep(.detail-edit-control .el-textarea__inner) {
|
|
907
905
|
border-radius: 5px;
|
|
908
|
-
box-shadow: 0 0 0 1px #
|
|
906
|
+
box-shadow: 0 0 0 1px #8aa7cf inset;
|
|
907
|
+
transition: box-shadow .16s ease, background-color .16s ease;
|
|
909
908
|
}
|
|
910
909
|
|
|
911
910
|
.detail-descriptions :deep(.detail-edit-control .el-input__wrapper:hover),
|
|
911
|
+
.detail-descriptions :deep(.detail-edit-control .el-select__wrapper:hover),
|
|
912
912
|
.detail-descriptions :deep(.detail-edit-control .el-textarea__inner:hover) {
|
|
913
|
-
box-shadow: 0 0 0 1px #
|
|
913
|
+
box-shadow: 0 0 0 1px #4f80c3 inset;
|
|
914
|
+
}
|
|
915
|
+
|
|
916
|
+
.detail-descriptions :deep(.detail-edit-control .el-input__wrapper.is-focus),
|
|
917
|
+
.detail-descriptions :deep(.detail-edit-control .el-select__wrapper.is-focused),
|
|
918
|
+
.detail-descriptions :deep(.detail-edit-control .el-textarea__inner:focus) {
|
|
919
|
+
box-shadow: 0 0 0 1px #1f62d6 inset, 0 0 0 3px rgba(31, 98, 214, .14);
|
|
914
920
|
}
|
|
915
921
|
|
|
916
922
|
.detail-actions {
|