t20-common-lib 0.15.20 → 0.15.22
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 +1 -1
- package/packages/dynamic-form/mixins/fileUpload.js +5 -4
- package/packages/dynamic-form/src/components/Amount.vue +1 -1
- package/packages/dynamic-form/src/components/AmountRange.vue +2 -6
- package/packages/dynamic-form/src/components/CheckboxGroup.vue +0 -1
- package/packages/dynamic-form/src/components/DMY.vue +2 -6
- package/packages/dynamic-form/src/components/Date.vue +0 -1
- package/packages/dynamic-form/src/components/DateRange.vue +0 -1
- package/packages/dynamic-form/src/components/Input.vue +0 -1
- package/packages/dynamic-form/src/components/InputNumber.vue +0 -1
- package/packages/dynamic-form/src/components/InputNumberRange.vue +0 -1
- package/packages/dynamic-form/src/components/RadioGroup.vue +0 -1
- package/packages/dynamic-form/src/components/Rate.vue +0 -1
- package/packages/dynamic-form/src/components/Switch.vue +0 -1
- package/packages/dynamic-form/src/components/Textarea.vue +0 -1
- package/packages/dynamic-form/src/main.vue +5 -4
package/package.json
CHANGED
|
@@ -18,7 +18,7 @@ export const fileUploadTableMixin = {
|
|
|
18
18
|
data() {
|
|
19
19
|
return {
|
|
20
20
|
fileUploadTableData: [],
|
|
21
|
-
fileAction:
|
|
21
|
+
fileAction: '/api/neams/eamsbaserecord/save',
|
|
22
22
|
seeTypes: /\.(jpg|png|gif|svg|pdf|swf|xlsx|xls|docx|doc)$/i,
|
|
23
23
|
dataPorp: {
|
|
24
24
|
fileAccept: '.rar,.zip,.doc,.docx,.pdf,image/*,.xls,.xlsx',
|
|
@@ -93,15 +93,16 @@ export const fileUploadTableMixin = {
|
|
|
93
93
|
const { file } = options
|
|
94
94
|
const data = new FormData()
|
|
95
95
|
data.append('file', file)
|
|
96
|
+
const uploadParam = this.uploadParam || {}
|
|
96
97
|
data.append(
|
|
97
98
|
'data',
|
|
98
99
|
JSON.stringify({
|
|
99
|
-
syscode:
|
|
100
|
-
appno:
|
|
100
|
+
syscode: uploadParam.syscode,
|
|
101
|
+
appno: uploadParam.appno,
|
|
101
102
|
bussValue: this.mapdata[row.type],
|
|
102
103
|
attno: row.type,
|
|
103
104
|
bussId:
|
|
104
|
-
|
|
105
|
+
uploadParam && uploadParam.paymentTemplate === 'REQUEST_PAYOUT' ? '' : uploadParam.bussId,
|
|
105
106
|
cltno: JSON.parse(sessionStorage.getItem('userInfo') || '{}').cltNo,
|
|
106
107
|
memo: file.name,
|
|
107
108
|
recordname: file.name,
|
|
@@ -51,9 +51,7 @@ export default {
|
|
|
51
51
|
return "";
|
|
52
52
|
},
|
|
53
53
|
set(val) {
|
|
54
|
-
|
|
55
|
-
this.$emit("input", nextValue);
|
|
56
|
-
this.$emit("change", nextValue);
|
|
54
|
+
this.$emit("input", `${val},${this._value2 || this._value2===0?this._value2 : ''}`);
|
|
57
55
|
},
|
|
58
56
|
},
|
|
59
57
|
_value2: {
|
|
@@ -64,9 +62,7 @@ export default {
|
|
|
64
62
|
return "";
|
|
65
63
|
},
|
|
66
64
|
set(val) {
|
|
67
|
-
|
|
68
|
-
this.$emit("input", nextValue);
|
|
69
|
-
this.$emit("change", nextValue);
|
|
65
|
+
this.$emit("input", `${this._value1},${val || val===0?val : ''}`);
|
|
70
66
|
},
|
|
71
67
|
},
|
|
72
68
|
},
|
|
@@ -79,9 +79,7 @@ export default {
|
|
|
79
79
|
return "";
|
|
80
80
|
},
|
|
81
81
|
set(val) {
|
|
82
|
-
|
|
83
|
-
this.$emit("input", nextValue);
|
|
84
|
-
this.$emit("change", nextValue);
|
|
82
|
+
this.$emit("input", `${val}${this.value2}`);
|
|
85
83
|
},
|
|
86
84
|
},
|
|
87
85
|
value2: {
|
|
@@ -94,9 +92,7 @@ export default {
|
|
|
94
92
|
return "D";
|
|
95
93
|
},
|
|
96
94
|
set(val) {
|
|
97
|
-
|
|
98
|
-
this.$emit("input", nextValue);
|
|
99
|
-
this.$emit("change", nextValue);
|
|
95
|
+
this.$emit("input", `${this.value1}${val}`);
|
|
100
96
|
},
|
|
101
97
|
},
|
|
102
98
|
},
|
|
@@ -78,8 +78,8 @@
|
|
|
78
78
|
</N20-anchor-item>
|
|
79
79
|
</N20-anchor>
|
|
80
80
|
<div slot="footer">
|
|
81
|
-
<el-button type="primary" @click="submit('
|
|
82
|
-
<el-button @click="submit('
|
|
81
|
+
<el-button type="primary" @click="submit('SUBMIT')">{{ $lc('提交') }}</el-button>
|
|
82
|
+
<el-button @click="submit('SAVE')">{{ $lc('保存') }}</el-button>
|
|
83
83
|
</div>
|
|
84
84
|
</T20-Form-Page>
|
|
85
85
|
</template>
|
|
@@ -95,6 +95,7 @@ const context = require.context('./components/', true, /\.vue$/)
|
|
|
95
95
|
const demoComponents = {}
|
|
96
96
|
context.keys().forEach(key => {
|
|
97
97
|
const component = context(key).default
|
|
98
|
+
if (!component || !component.name) return
|
|
98
99
|
demoComponents[component.name] = component
|
|
99
100
|
})
|
|
100
101
|
|
|
@@ -445,10 +446,10 @@ export default {
|
|
|
445
446
|
})
|
|
446
447
|
},
|
|
447
448
|
// 第一步仅做模板渲染校验,提交逻辑后续步骤再扩展
|
|
448
|
-
async submit() {
|
|
449
|
+
async submit(operate) {
|
|
449
450
|
const valid = await this.$refs.dynamicForms.validate()
|
|
450
451
|
if (!valid) return
|
|
451
|
-
const payload = { formData: this.formData }
|
|
452
|
+
const payload = { formData: this.formData, operate }
|
|
452
453
|
if (this.needFile) {
|
|
453
454
|
payload.fileUploadTableData = (this.fileUploadTableData || []).filter(t => t.beid)
|
|
454
455
|
}
|