vue2server7 7.0.12 → 7.0.14
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.
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div class="number-range" :class="{ 'is-disabled': disabled }">
|
|
2
|
+
<div class="number-range" :class="{ 'is-disabled': disabled, 'is-error': showInternalError }">
|
|
3
3
|
<el-input
|
|
4
4
|
v-model="minDisplay"
|
|
5
5
|
class="number-range__input"
|
|
6
|
+
:class="{ 'is-error': showInternalError }"
|
|
6
7
|
:placeholder="minPlaceholder"
|
|
7
8
|
:disabled="disabled"
|
|
8
9
|
clearable
|
|
@@ -15,6 +16,7 @@
|
|
|
15
16
|
<el-input
|
|
16
17
|
v-model="maxDisplay"
|
|
17
18
|
class="number-range__input"
|
|
19
|
+
:class="{ 'is-error': showInternalError }"
|
|
18
20
|
:placeholder="maxPlaceholder"
|
|
19
21
|
:disabled="disabled"
|
|
20
22
|
clearable
|
|
@@ -23,22 +25,30 @@
|
|
|
23
25
|
@blur="onMaxBlur"
|
|
24
26
|
@clear="onMaxClear"
|
|
25
27
|
/>
|
|
28
|
+
<span v-if="showInternalError" class="number-range__error">结束值不能小于起始值</span>
|
|
26
29
|
</div>
|
|
27
30
|
</template>
|
|
28
31
|
|
|
29
32
|
<script lang="ts">
|
|
30
33
|
import type { FormItemRule } from 'element-plus'
|
|
31
34
|
|
|
32
|
-
export type RangeValue = [number | null, number | null]
|
|
35
|
+
export type RangeValue = [number | string | null, number | string | null]
|
|
33
36
|
type ValidatorCb = (error?: Error) => void
|
|
34
37
|
|
|
38
|
+
/** 将字符串/数字统一转为 number,空值返回 null */
|
|
39
|
+
function toNum(val: unknown): number | null {
|
|
40
|
+
if (val === null || val === undefined || val === '') return null
|
|
41
|
+
const n = Number(val)
|
|
42
|
+
return Number.isNaN(n) ? null : n
|
|
43
|
+
}
|
|
44
|
+
|
|
35
45
|
export interface NumberRangeProps {
|
|
36
|
-
/** 数组模式绑定值 [min, max],与 start/end
|
|
46
|
+
/** 数组模式绑定值 [min, max],与 start/end 二选一;值可以是 string 或 number */
|
|
37
47
|
modelValue?: RangeValue
|
|
38
|
-
/** 双字段模式 -
|
|
39
|
-
start?: number | null
|
|
40
|
-
/** 双字段模式 -
|
|
41
|
-
end?: number | null
|
|
48
|
+
/** 双字段模式 - 起始值(支持 string 类型数字) */
|
|
49
|
+
start?: number | string | null
|
|
50
|
+
/** 双字段模式 - 结束值(支持 string 类型数字) */
|
|
51
|
+
end?: number | string | null
|
|
42
52
|
minPlaceholder?: string
|
|
43
53
|
maxPlaceholder?: string
|
|
44
54
|
/** 两个输入框之间的分隔文字 */
|
|
@@ -82,10 +92,10 @@ export function rangeRequired(
|
|
|
82
92
|
trigger,
|
|
83
93
|
validator: startField
|
|
84
94
|
? (_r: unknown, _v: unknown, cb: ValidatorCb, source: Record<string, unknown>) =>
|
|
85
|
-
cb(source[startField] == null
|
|
95
|
+
cb(toNum(source[startField]) == null ? new Error(message) : undefined)
|
|
86
96
|
: (_r: unknown, v: unknown, cb: ValidatorCb) => {
|
|
87
97
|
const arr = v as RangeValue | undefined
|
|
88
|
-
cb(!Array.isArray(arr) || arr[0] == null || arr[1] == null ? new Error(message) : undefined)
|
|
98
|
+
cb(!Array.isArray(arr) || toNum(arr[0]) == null || toNum(arr[1]) == null ? new Error(message) : undefined)
|
|
89
99
|
}
|
|
90
100
|
}
|
|
91
101
|
}
|
|
@@ -99,18 +109,24 @@ export function rangeRule(
|
|
|
99
109
|
return {
|
|
100
110
|
trigger,
|
|
101
111
|
validator: startField
|
|
102
|
-
? (_r: unknown, v: unknown, cb: ValidatorCb, source: Record<string, unknown>) =>
|
|
103
|
-
|
|
112
|
+
? (_r: unknown, v: unknown, cb: ValidatorCb, source: Record<string, unknown>) => {
|
|
113
|
+
const startNum = toNum(source[startField])
|
|
114
|
+
const endNum = toNum(v)
|
|
115
|
+
cb(startNum != null && endNum != null && endNum < startNum ? new Error(message) : undefined)
|
|
116
|
+
}
|
|
104
117
|
: (_r: unknown, v: unknown, cb: ValidatorCb) => {
|
|
105
118
|
const arr = v as RangeValue | undefined
|
|
106
|
-
|
|
119
|
+
const minNum = toNum(arr?.[0])
|
|
120
|
+
const maxNum = toNum(arr?.[1])
|
|
121
|
+
cb(minNum != null && maxNum != null && maxNum < minNum ? new Error(message) : undefined)
|
|
107
122
|
}
|
|
108
123
|
}
|
|
109
124
|
}
|
|
110
125
|
</script>
|
|
111
126
|
|
|
112
127
|
<script setup lang="ts">
|
|
113
|
-
import { ref, watch, computed } from 'vue'
|
|
128
|
+
import { ref, watch, computed, inject } from 'vue'
|
|
129
|
+
import { formItemContextKey } from 'element-plus'
|
|
114
130
|
|
|
115
131
|
const props = withDefaults(defineProps<NumberRangeProps>(), {
|
|
116
132
|
modelValue: undefined,
|
|
@@ -133,18 +149,22 @@ const emit = defineEmits<{
|
|
|
133
149
|
change: [value: RangeValue]
|
|
134
150
|
}>()
|
|
135
151
|
|
|
152
|
+
/** 检测是否处于 el-form-item 内,有则交给 form 校验,无则组件内部校验 */
|
|
153
|
+
const formItemContext = inject(formItemContextKey, undefined)
|
|
154
|
+
const useInternalValidation = computed(() => !formItemContext)
|
|
155
|
+
|
|
136
156
|
/** 根据是否传入 modelValue 自动判断绑定模式 */
|
|
137
157
|
const isArrayMode = computed(() => props.modelValue !== undefined)
|
|
138
158
|
|
|
139
|
-
function getInitMin(): number | null
|
|
140
|
-
return isArrayMode.value ? props.modelValue?.[0] : props.start
|
|
159
|
+
function getInitMin(): number | null {
|
|
160
|
+
return toNum(isArrayMode.value ? props.modelValue?.[0] : props.start)
|
|
141
161
|
}
|
|
142
|
-
function getInitMax(): number | null
|
|
143
|
-
return isArrayMode.value ? props.modelValue?.[1] : props.end
|
|
162
|
+
function getInitMax(): number | null {
|
|
163
|
+
return toNum(isArrayMode.value ? props.modelValue?.[1] : props.end)
|
|
144
164
|
}
|
|
145
165
|
|
|
146
|
-
function toDisplay(val: number | null
|
|
147
|
-
if (val === null
|
|
166
|
+
function toDisplay(val: number | null): string {
|
|
167
|
+
if (val === null) return ''
|
|
148
168
|
return String(val)
|
|
149
169
|
}
|
|
150
170
|
|
|
@@ -200,6 +220,12 @@ const rangeInvalid = computed(() => {
|
|
|
200
220
|
|
|
201
221
|
const isValid = computed(() => !rangeInvalid.value)
|
|
202
222
|
|
|
223
|
+
/** 内部校验:仅在无 el-form-item 且两个输入框都失焦后展示 */
|
|
224
|
+
const blurred = ref(false)
|
|
225
|
+
const showInternalError = computed(() =>
|
|
226
|
+
useInternalValidation.value && blurred.value && rangeInvalid.value
|
|
227
|
+
)
|
|
228
|
+
|
|
203
229
|
/** 根据绑定模式 emit 对应事件 */
|
|
204
230
|
function emitValue(): void {
|
|
205
231
|
const minVal = formatNum(parseNum(minDisplay.value))
|
|
@@ -252,6 +278,7 @@ function onMinBlur(): void {
|
|
|
252
278
|
minDisplay.value = ''
|
|
253
279
|
}
|
|
254
280
|
emitValue()
|
|
281
|
+
if (!minFocused.value && !maxFocused.value) blurred.value = true
|
|
255
282
|
}
|
|
256
283
|
|
|
257
284
|
function onMaxBlur(): void {
|
|
@@ -266,9 +293,11 @@ function onMaxBlur(): void {
|
|
|
266
293
|
maxDisplay.value = ''
|
|
267
294
|
}
|
|
268
295
|
emitValue()
|
|
296
|
+
if (!minFocused.value && !maxFocused.value) blurred.value = true
|
|
269
297
|
}
|
|
270
298
|
|
|
271
299
|
function validate(): boolean {
|
|
300
|
+
blurred.value = true
|
|
272
301
|
return isValid.value
|
|
273
302
|
}
|
|
274
303
|
|
|
@@ -278,13 +307,14 @@ defineExpose({ validate, isValid })
|
|
|
278
307
|
watch(
|
|
279
308
|
() => isArrayMode.value ? props.modelValue : [props.start, props.end],
|
|
280
309
|
(val) => {
|
|
281
|
-
const newMin = toDisplay(val?.[0]
|
|
282
|
-
const newMax = toDisplay(val?.[1]
|
|
310
|
+
const newMin = toDisplay(toNum(val?.[0]))
|
|
311
|
+
const newMax = toDisplay(toNum(val?.[1]))
|
|
283
312
|
if (newMin !== minDisplay.value) minDisplay.value = newMin
|
|
284
313
|
if (newMax !== maxDisplay.value) maxDisplay.value = newMax
|
|
285
|
-
if ((val?.[0] == null
|
|
314
|
+
if (toNum(val?.[0]) == null && toNum(val?.[1]) == null) {
|
|
286
315
|
minFocused.value = false
|
|
287
316
|
maxFocused.value = false
|
|
317
|
+
blurred.value = false
|
|
288
318
|
}
|
|
289
319
|
},
|
|
290
320
|
{ deep: true }
|
|
@@ -293,15 +323,16 @@ watch(
|
|
|
293
323
|
|
|
294
324
|
<style scoped>
|
|
295
325
|
.number-range {
|
|
296
|
-
display:
|
|
326
|
+
display: flex;
|
|
297
327
|
align-items: center;
|
|
298
328
|
gap: 8px;
|
|
329
|
+
width: 100%;
|
|
299
330
|
flex-wrap: wrap;
|
|
300
|
-
position: relative;
|
|
301
331
|
}
|
|
302
332
|
|
|
303
333
|
.number-range__input {
|
|
304
|
-
|
|
334
|
+
flex: 1;
|
|
335
|
+
min-width: 0;
|
|
305
336
|
}
|
|
306
337
|
|
|
307
338
|
.number-range__separator {
|
|
@@ -313,4 +344,16 @@ watch(
|
|
|
313
344
|
.number-range.is-disabled .number-range__separator {
|
|
314
345
|
color: var(--el-text-color-placeholder);
|
|
315
346
|
}
|
|
347
|
+
|
|
348
|
+
.number-range__input.is-error :deep(.el-input__wrapper) {
|
|
349
|
+
box-shadow: 0 0 0 1px var(--el-color-danger) inset;
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
.number-range__error {
|
|
353
|
+
width: 100%;
|
|
354
|
+
color: var(--el-color-danger);
|
|
355
|
+
font-size: 12px;
|
|
356
|
+
line-height: 1;
|
|
357
|
+
padding-top: 2px;
|
|
358
|
+
}
|
|
316
359
|
</style>
|
|
@@ -0,0 +1,363 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<section class="page position-report-page">
|
|
3
|
+
<h1 class="title">头寸报备信息</h1>
|
|
4
|
+
|
|
5
|
+
<el-form
|
|
6
|
+
ref="formRef"
|
|
7
|
+
:model="form"
|
|
8
|
+
:rules="rules"
|
|
9
|
+
label-width="140px"
|
|
10
|
+
label-suffix=":"
|
|
11
|
+
class="report-form"
|
|
12
|
+
>
|
|
13
|
+
<!-- 第一行 -->
|
|
14
|
+
<el-row :gutter="24">
|
|
15
|
+
<el-col :span="8">
|
|
16
|
+
<el-form-item label="头寸报备编号" prop="reportNo">
|
|
17
|
+
<el-input v-model="form.reportNo" placeholder="系统自动生成" disabled />
|
|
18
|
+
</el-form-item>
|
|
19
|
+
</el-col>
|
|
20
|
+
<el-col :span="8">
|
|
21
|
+
<el-form-item label="业务类型" prop="bizType">
|
|
22
|
+
<el-input v-model="form.bizType" disabled />
|
|
23
|
+
</el-form-item>
|
|
24
|
+
</el-col>
|
|
25
|
+
<el-col :span="8">
|
|
26
|
+
<el-form-item label="客户分类" prop="customerType">
|
|
27
|
+
<el-select v-model="form.customerType" placeholder="请选择" style="width: 100%">
|
|
28
|
+
<el-option label="对公" value="对公" />
|
|
29
|
+
<el-option label="对私" value="对私" />
|
|
30
|
+
</el-select>
|
|
31
|
+
</el-form-item>
|
|
32
|
+
</el-col>
|
|
33
|
+
</el-row>
|
|
34
|
+
|
|
35
|
+
<!-- 第二行 -->
|
|
36
|
+
<el-row :gutter="24">
|
|
37
|
+
<el-col :span="8">
|
|
38
|
+
<el-form-item label="是否集团" prop="isGroup">
|
|
39
|
+
<el-select v-model="form.isGroup" placeholder="请选择" style="width: 100%">
|
|
40
|
+
<el-option label="是" value="是" />
|
|
41
|
+
<el-option label="否" value="否" />
|
|
42
|
+
</el-select>
|
|
43
|
+
</el-form-item>
|
|
44
|
+
</el-col>
|
|
45
|
+
<el-col :span="8">
|
|
46
|
+
<el-form-item label="对公组织架构代码" prop="orgCode">
|
|
47
|
+
<el-input v-model="form.orgCode" placeholder="请输入" />
|
|
48
|
+
</el-form-item>
|
|
49
|
+
</el-col>
|
|
50
|
+
<el-col :span="8">
|
|
51
|
+
<el-form-item label="客户名称" prop="customerName">
|
|
52
|
+
<el-input v-model="form.customerName" placeholder="请输入" />
|
|
53
|
+
</el-form-item>
|
|
54
|
+
</el-col>
|
|
55
|
+
</el-row>
|
|
56
|
+
|
|
57
|
+
<!-- 第三行 -->
|
|
58
|
+
<el-row :gutter="24">
|
|
59
|
+
<el-col :span="8">
|
|
60
|
+
<el-form-item label="投付款币种金额" prop="currency">
|
|
61
|
+
<div style="display: flex; gap: 8px; width: 100%">
|
|
62
|
+
<el-select v-model="form.currency" placeholder="币种" style="width: 140px; flex-shrink: 0">
|
|
63
|
+
<el-option label="CNY - 人民币" value="CNY" />
|
|
64
|
+
<el-option label="USD - 美元" value="USD" />
|
|
65
|
+
<el-option label="EUR - 欧元" value="EUR" />
|
|
66
|
+
<el-option label="HKD - 港币" value="HKD" />
|
|
67
|
+
</el-select>
|
|
68
|
+
<el-input v-model="form.amount" placeholder="金额" />
|
|
69
|
+
</div>
|
|
70
|
+
</el-form-item>
|
|
71
|
+
</el-col>
|
|
72
|
+
<el-col :span="8">
|
|
73
|
+
<el-form-item label="汇款起息日" prop="valueDate">
|
|
74
|
+
<el-date-picker
|
|
75
|
+
v-model="form.valueDate"
|
|
76
|
+
type="date"
|
|
77
|
+
placeholder="请选择日期"
|
|
78
|
+
format="YYYY-MM-DD"
|
|
79
|
+
value-format="YYYY-MM-DD"
|
|
80
|
+
style="width: 100%"
|
|
81
|
+
/>
|
|
82
|
+
</el-form-item>
|
|
83
|
+
</el-col>
|
|
84
|
+
<el-col :span="8">
|
|
85
|
+
<el-form-item label="账户名称" prop="accountName">
|
|
86
|
+
<el-input v-model="form.accountName" placeholder="请输入" />
|
|
87
|
+
</el-form-item>
|
|
88
|
+
</el-col>
|
|
89
|
+
</el-row>
|
|
90
|
+
|
|
91
|
+
<!-- 第四行 -->
|
|
92
|
+
<el-row :gutter="24">
|
|
93
|
+
<el-col :span="8">
|
|
94
|
+
<el-form-item label="计划汇/收日期" prop="planDate">
|
|
95
|
+
<el-date-picker
|
|
96
|
+
v-model="form.planDate"
|
|
97
|
+
type="date"
|
|
98
|
+
placeholder="请选择日期"
|
|
99
|
+
format="YYYY-MM-DD"
|
|
100
|
+
value-format="YYYY-MM-DD"
|
|
101
|
+
style="width: 100%"
|
|
102
|
+
/>
|
|
103
|
+
</el-form-item>
|
|
104
|
+
</el-col>
|
|
105
|
+
<el-col :span="8">
|
|
106
|
+
<el-form-item label="预备日期" prop="prepareDate">
|
|
107
|
+
<el-date-picker
|
|
108
|
+
v-model="form.prepareDate"
|
|
109
|
+
type="date"
|
|
110
|
+
placeholder="请选择日期"
|
|
111
|
+
format="YYYY-MM-DD"
|
|
112
|
+
value-format="YYYY-MM-DD"
|
|
113
|
+
style="width: 100%"
|
|
114
|
+
/>
|
|
115
|
+
</el-form-item>
|
|
116
|
+
</el-col>
|
|
117
|
+
<el-col :span="8">
|
|
118
|
+
<el-form-item label="报备创号" prop="createNo">
|
|
119
|
+
<el-input v-model="form.createNo" placeholder="请输入" />
|
|
120
|
+
</el-form-item>
|
|
121
|
+
</el-col>
|
|
122
|
+
</el-row>
|
|
123
|
+
|
|
124
|
+
<!-- 第五行 -->
|
|
125
|
+
<el-row :gutter="24">
|
|
126
|
+
<el-col :span="8">
|
|
127
|
+
<el-form-item label="是否议叙" prop="isNegotiate">
|
|
128
|
+
<el-select v-model="form.isNegotiate" placeholder="请选择" style="width: 100%">
|
|
129
|
+
<el-option label="是" value="是" />
|
|
130
|
+
<el-option label="否" value="否" />
|
|
131
|
+
</el-select>
|
|
132
|
+
</el-form-item>
|
|
133
|
+
</el-col>
|
|
134
|
+
<el-col :span="8">
|
|
135
|
+
<el-form-item label="原银行业务编号" prop="origBizNo">
|
|
136
|
+
<el-input v-model="form.origBizNo" placeholder="请输入" />
|
|
137
|
+
</el-form-item>
|
|
138
|
+
</el-col>
|
|
139
|
+
<el-col :span="8">
|
|
140
|
+
<el-form-item label="联户行" prop="linkedBank">
|
|
141
|
+
<el-select v-model="form.linkedBank" placeholder="请选择" filterable style="width: 100%">
|
|
142
|
+
<el-option label="CIPSCNSHXXX" value="CIPSCNSHXXX" />
|
|
143
|
+
<el-option label="BKCHCNBJXXX" value="BKCHCNBJXXX" />
|
|
144
|
+
</el-select>
|
|
145
|
+
</el-form-item>
|
|
146
|
+
</el-col>
|
|
147
|
+
</el-row>
|
|
148
|
+
|
|
149
|
+
<!-- 第六行 -->
|
|
150
|
+
<el-row :gutter="24">
|
|
151
|
+
<el-col :span="8">
|
|
152
|
+
<el-form-item label="收款银行" prop="receivingBank">
|
|
153
|
+
<el-input v-model="form.receivingBank" placeholder="请输入" />
|
|
154
|
+
</el-form-item>
|
|
155
|
+
</el-col>
|
|
156
|
+
<el-col :span="8">
|
|
157
|
+
<el-form-item label="收款银行开户行" prop="receivingBankCode">
|
|
158
|
+
<el-input v-model="form.receivingBankCode" placeholder="请输入" />
|
|
159
|
+
</el-form-item>
|
|
160
|
+
</el-col>
|
|
161
|
+
<el-col :span="8">
|
|
162
|
+
<el-form-item label="收款银行开户行名" prop="receivingBankName">
|
|
163
|
+
<el-input v-model="form.receivingBankName" placeholder="请输入" />
|
|
164
|
+
</el-form-item>
|
|
165
|
+
</el-col>
|
|
166
|
+
</el-row>
|
|
167
|
+
|
|
168
|
+
<!-- 第七行 -->
|
|
169
|
+
<el-row :gutter="24">
|
|
170
|
+
<el-col :span="8">
|
|
171
|
+
<el-form-item label="邮件通知覆盖产品" prop="emailProduct">
|
|
172
|
+
<el-select v-model="form.emailProduct" placeholder="请选择" style="width: 100%">
|
|
173
|
+
<el-option label="产品A" value="A" />
|
|
174
|
+
<el-option label="产品B" value="B" />
|
|
175
|
+
</el-select>
|
|
176
|
+
</el-form-item>
|
|
177
|
+
</el-col>
|
|
178
|
+
<el-col :span="8">
|
|
179
|
+
<el-form-item label="多币种汇款产品" prop="multiCurrencyProduct">
|
|
180
|
+
<el-select v-model="form.multiCurrencyProduct" placeholder="请选择" style="width: 100%">
|
|
181
|
+
<el-option label="产品A" value="A" />
|
|
182
|
+
<el-option label="产品B" value="B" />
|
|
183
|
+
</el-select>
|
|
184
|
+
</el-form-item>
|
|
185
|
+
</el-col>
|
|
186
|
+
<el-col :span="8">
|
|
187
|
+
<el-form-item label="自贸区标识" prop="ftzFlag">
|
|
188
|
+
<el-checkbox v-model="form.ftzFlag" />
|
|
189
|
+
</el-form-item>
|
|
190
|
+
</el-col>
|
|
191
|
+
</el-row>
|
|
192
|
+
|
|
193
|
+
<!-- 第八行 -->
|
|
194
|
+
<el-row :gutter="24">
|
|
195
|
+
<el-col :span="8">
|
|
196
|
+
<el-form-item label="报备人" prop="reporter">
|
|
197
|
+
<el-input v-model="form.reporter" placeholder="请输入" />
|
|
198
|
+
</el-form-item>
|
|
199
|
+
</el-col>
|
|
200
|
+
<el-col :span="8">
|
|
201
|
+
<el-form-item label="联系电话" prop="phone">
|
|
202
|
+
<el-input v-model="form.phone" placeholder="请输入" />
|
|
203
|
+
</el-form-item>
|
|
204
|
+
</el-col>
|
|
205
|
+
<el-col :span="8">
|
|
206
|
+
<el-form-item label="报备部门" prop="department">
|
|
207
|
+
<el-input v-model="form.department" placeholder="请输入" />
|
|
208
|
+
</el-form-item>
|
|
209
|
+
</el-col>
|
|
210
|
+
</el-row>
|
|
211
|
+
|
|
212
|
+
<!-- 第九行 -->
|
|
213
|
+
<el-row :gutter="24">
|
|
214
|
+
<el-col :span="16">
|
|
215
|
+
<el-form-item label="报备说明" prop="remark">
|
|
216
|
+
<el-input v-model="form.remark" type="textarea" :rows="2" placeholder="请输入" />
|
|
217
|
+
</el-form-item>
|
|
218
|
+
</el-col>
|
|
219
|
+
<el-col :span="8">
|
|
220
|
+
<el-form-item label="登记" prop="register">
|
|
221
|
+
<el-input v-model="form.register" placeholder="请输入" />
|
|
222
|
+
</el-form-item>
|
|
223
|
+
</el-col>
|
|
224
|
+
</el-row>
|
|
225
|
+
|
|
226
|
+
<!-- 第十行 -->
|
|
227
|
+
<el-row :gutter="24">
|
|
228
|
+
<el-col :span="8">
|
|
229
|
+
<el-form-item label="使用状态" prop="useStatus">
|
|
230
|
+
<el-select v-model="form.useStatus" placeholder="请选择" style="width: 100%">
|
|
231
|
+
<el-option label="未使用" value="未使用" />
|
|
232
|
+
<el-option label="已使用" value="已使用" />
|
|
233
|
+
</el-select>
|
|
234
|
+
</el-form-item>
|
|
235
|
+
</el-col>
|
|
236
|
+
<el-col :span="8">
|
|
237
|
+
<el-form-item label="当前状态" prop="currentStatus">
|
|
238
|
+
<el-input v-model="form.currentStatus" placeholder="请输入" disabled />
|
|
239
|
+
</el-form-item>
|
|
240
|
+
</el-col>
|
|
241
|
+
<el-col :span="8">
|
|
242
|
+
<el-form-item label="业务大区" prop="bizRegion">
|
|
243
|
+
<el-input v-model="form.bizRegion" placeholder="请输入" />
|
|
244
|
+
</el-form-item>
|
|
245
|
+
</el-col>
|
|
246
|
+
</el-row>
|
|
247
|
+
</el-form>
|
|
248
|
+
|
|
249
|
+
<div class="footer">
|
|
250
|
+
<el-button type="danger" @click="onFlowLog">操作流水</el-button>
|
|
251
|
+
<div class="footer-right">
|
|
252
|
+
<el-button type="danger" @click="onSubmit">提交</el-button>
|
|
253
|
+
<el-button type="danger" @click="onSave">保存</el-button>
|
|
254
|
+
<el-button type="danger" @click="onClose">关闭</el-button>
|
|
255
|
+
</div>
|
|
256
|
+
</div>
|
|
257
|
+
</section>
|
|
258
|
+
</template>
|
|
259
|
+
|
|
260
|
+
<script>
|
|
261
|
+
export default {
|
|
262
|
+
name: 'PositionReportPage',
|
|
263
|
+
data() {
|
|
264
|
+
return {
|
|
265
|
+
form: {
|
|
266
|
+
reportNo: '',
|
|
267
|
+
bizType: '跨境人民币业务(进口)',
|
|
268
|
+
customerType: '对公',
|
|
269
|
+
isGroup: '',
|
|
270
|
+
orgCode: '5903887-5',
|
|
271
|
+
customerName: '长期应收长期预收客户(5927)',
|
|
272
|
+
currency: 'CNY',
|
|
273
|
+
amount: '100,000,000.00',
|
|
274
|
+
valueDate: '',
|
|
275
|
+
accountName: '',
|
|
276
|
+
planDate: '2026-03-23',
|
|
277
|
+
prepareDate: '2026-03-23',
|
|
278
|
+
createNo: '183423',
|
|
279
|
+
isNegotiate: '否',
|
|
280
|
+
origBizNo: '',
|
|
281
|
+
linkedBank: 'CIPSCNSHXXX',
|
|
282
|
+
receivingBank: '',
|
|
283
|
+
receivingBankCode: 'BKCHCNBJXXX',
|
|
284
|
+
receivingBankName: '中国银行国际金融有限公司',
|
|
285
|
+
emailProduct: '',
|
|
286
|
+
multiCurrencyProduct: '',
|
|
287
|
+
ftzFlag: false,
|
|
288
|
+
reporter: '0601bx',
|
|
289
|
+
phone: '13051636/66',
|
|
290
|
+
department: 'HGS1:利率及外汇业务处',
|
|
291
|
+
remark: '',
|
|
292
|
+
register: '登记(后端周四)',
|
|
293
|
+
useStatus: '未使用',
|
|
294
|
+
currentStatus: '自行撤区',
|
|
295
|
+
bizRegion: '报关系统'
|
|
296
|
+
},
|
|
297
|
+
rules: {
|
|
298
|
+
customerType: [{ required: true, message: '请选择客户分类', trigger: 'change' }],
|
|
299
|
+
orgCode: [{ required: true, message: '请输入对公组织架构代码', trigger: 'blur' }],
|
|
300
|
+
customerName: [{ required: true, message: '请输入客户名称', trigger: 'blur' }],
|
|
301
|
+
currency: [{ required: true, message: '请选择币种', trigger: 'change' }],
|
|
302
|
+
planDate: [{ required: true, message: '请选择计划日期', trigger: 'change' }],
|
|
303
|
+
reporter: [{ required: true, message: '请输入报备人', trigger: 'blur' }],
|
|
304
|
+
phone: [{ required: true, message: '请输入联系电话', trigger: 'blur' }]
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
},
|
|
308
|
+
methods: {
|
|
309
|
+
onFlowLog() {
|
|
310
|
+
this.$message.info('查看操作流水')
|
|
311
|
+
},
|
|
312
|
+
onSubmit() {
|
|
313
|
+
this.$refs.formRef.validate((valid) => {
|
|
314
|
+
if (!valid) return
|
|
315
|
+
this.$message.success('提交成功')
|
|
316
|
+
})
|
|
317
|
+
},
|
|
318
|
+
onSave() {
|
|
319
|
+
this.$message.success('保存成功')
|
|
320
|
+
},
|
|
321
|
+
onClose() {
|
|
322
|
+
this.$router.back()
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
</script>
|
|
327
|
+
|
|
328
|
+
<style scoped>
|
|
329
|
+
.position-report-page {
|
|
330
|
+
padding: 20px;
|
|
331
|
+
}
|
|
332
|
+
|
|
333
|
+
.title {
|
|
334
|
+
font-size: 18px;
|
|
335
|
+
margin-bottom: 20px;
|
|
336
|
+
padding-bottom: 12px;
|
|
337
|
+
border-bottom: 1px solid #ebeef5;
|
|
338
|
+
}
|
|
339
|
+
|
|
340
|
+
.report-form {
|
|
341
|
+
max-width: 1400px;
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
.report-form :deep(.el-form-item__label) {
|
|
345
|
+
font-weight: normal;
|
|
346
|
+
white-space: nowrap;
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
.footer {
|
|
350
|
+
display: flex;
|
|
351
|
+
justify-content: space-between;
|
|
352
|
+
align-items: center;
|
|
353
|
+
margin-top: 24px;
|
|
354
|
+
padding-top: 16px;
|
|
355
|
+
border-top: 1px solid #ebeef5;
|
|
356
|
+
max-width: 1400px;
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
.footer-right {
|
|
360
|
+
display: flex;
|
|
361
|
+
gap: 8px;
|
|
362
|
+
}
|
|
363
|
+
</style>
|
|
@@ -2,6 +2,7 @@ import TablePage from '../pages/TablePage.vue'
|
|
|
2
2
|
import CascaderPage from '../pages/CascaderPage.vue'
|
|
3
3
|
import ExportExcelPage from '../pages/ExportExcelPage.vue'
|
|
4
4
|
import ImportTablePage from '../pages/ImportTablePage.vue'
|
|
5
|
+
import PositionReportPage from '../pages/PositionReportPage.vue'
|
|
5
6
|
|
|
6
7
|
export const routes = [
|
|
7
8
|
{
|
|
@@ -43,5 +44,14 @@ export const routes = [
|
|
|
43
44
|
title: '导入表格',
|
|
44
45
|
showInMenu: true
|
|
45
46
|
}
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
path: '/position-report',
|
|
50
|
+
name: 'PositionReport',
|
|
51
|
+
component: PositionReportPage,
|
|
52
|
+
meta: {
|
|
53
|
+
title: '头寸报备',
|
|
54
|
+
showInMenu: true
|
|
55
|
+
}
|
|
46
56
|
}
|
|
47
57
|
]
|