app-form-view 0.0.1 → 0.0.2
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/README.md +1 -1
- package/dist/css/style.css +157 -206
- package/dist/index.js +567 -2
- package/package.json +7 -5
- package/scripts/rollup.config.base.js +100 -68
- package/scripts/rollup.config.build.js +32 -29
- package/scripts/rollup.config.dev.js +18 -21
- package/scripts/rollup.config.prod.js +12 -2
- package/src/assets/css/app-form.css +50 -14
- package/src/assets/css/global.css +12 -12
- package/src/assets/scss/_flex.scss +31 -34
- package/src/assets/scss/app-form.scss +184 -1
- package/src/assets/scss/global.scss +179 -1
- package/src/components/appForm/Checkbox.vue +5 -0
- package/src/components/appForm/Input.vue +2 -2
- package/src/components/appForm/SearchApi.vue +1 -1
- package/src/components/appForm/Table.vue +21 -3
- package/src/components/appForm/select.vue +5 -5
- package/src/components/form/SearchSelect.vue +3 -3
- package/src/components/form/Table.vue +1 -1
- package/src/index.js +1 -1
- package/src/views/build/FieldMappingDialog.vue +0 -7
- package/src/views/build/RightPanel.vue +0 -1
- package/src/views/build/index.vue +0 -15
- package/src/views/build/viewAppForm.vue +150 -111
- package/src/views/build/viewForm.vue +2 -2
- package/static/plugins/css/app-form.css +3 -1
- package/static/plugins/scss/app-form.scss +5 -0
|
@@ -12,14 +12,14 @@
|
|
|
12
12
|
}
|
|
13
13
|
|
|
14
14
|
.flex-row {
|
|
15
|
-
-webkit-box-orient:
|
|
15
|
+
-webkit-box-orient: horizontal;
|
|
16
16
|
-ms-flex-direction: row;
|
|
17
17
|
-webkit-flex-direction: row;
|
|
18
18
|
flex-direction: row;
|
|
19
19
|
}
|
|
20
20
|
|
|
21
21
|
.flex-row-reverse {
|
|
22
|
-
-webkit-box-orient:
|
|
22
|
+
-webkit-box-orient: horizontal;
|
|
23
23
|
-ms-flex-direction: row-reverse;
|
|
24
24
|
-webkit-flex-direction: row-reverse;
|
|
25
25
|
flex-direction: row-reverse;
|
|
@@ -61,8 +61,8 @@
|
|
|
61
61
|
}
|
|
62
62
|
|
|
63
63
|
.justify-content-space-around {
|
|
64
|
-
-webkit-box-pack:
|
|
65
|
-
-ms-flex-pack:
|
|
64
|
+
-webkit-box-pack: space-around;
|
|
65
|
+
-ms-flex-pack: space-around;
|
|
66
66
|
-webkit-justify-content: space-around;
|
|
67
67
|
justify-content: space-around;
|
|
68
68
|
}
|
|
@@ -96,66 +96,63 @@
|
|
|
96
96
|
}
|
|
97
97
|
|
|
98
98
|
.flex-wrap-nowrap {
|
|
99
|
-
-webkit-box-wrap: nowrap;
|
|
100
99
|
-ms-flex-wrap: nowrap;
|
|
101
100
|
-webkit-flex-wrap: nowrap;
|
|
102
101
|
flex-wrap: nowrap;
|
|
103
102
|
}
|
|
104
103
|
|
|
105
104
|
.flex-wrap-wrap {
|
|
106
|
-
-webkit-box-wrap: wrap;
|
|
107
105
|
-ms-flex-wrap: wrap;
|
|
108
106
|
-webkit-flex-wrap: wrap;
|
|
109
107
|
flex-wrap: wrap;
|
|
110
108
|
}
|
|
111
109
|
|
|
112
110
|
.flex-wrap-reverse {
|
|
113
|
-
-
|
|
114
|
-
-
|
|
115
|
-
|
|
116
|
-
flex-wrap: reverse;
|
|
111
|
+
-ms-flex-wrap: wrap-reverse;
|
|
112
|
+
-webkit-flex-wrap: wrap-reverse;
|
|
113
|
+
flex-wrap: wrap-reverse;
|
|
117
114
|
}
|
|
118
115
|
|
|
119
116
|
.align-content-start {
|
|
120
|
-
-webkit-box-
|
|
121
|
-
-ms-flex-
|
|
122
|
-
-webkit-align-
|
|
123
|
-
|
|
117
|
+
-webkit-box-lines: start;
|
|
118
|
+
-ms-flex-line-pack: start;
|
|
119
|
+
-webkit-align-content: flex-start;
|
|
120
|
+
align-content: flex-start;
|
|
124
121
|
}
|
|
125
122
|
|
|
126
123
|
.align-content-end {
|
|
127
|
-
-webkit-box-
|
|
128
|
-
-ms-flex-
|
|
129
|
-
-webkit-align-
|
|
130
|
-
|
|
124
|
+
-webkit-box-lines: end;
|
|
125
|
+
-ms-flex-line-pack: end;
|
|
126
|
+
-webkit-align-content: flex-end;
|
|
127
|
+
align-content: flex-end;
|
|
131
128
|
}
|
|
132
129
|
|
|
133
130
|
.align-content-center {
|
|
134
|
-
-webkit-box-
|
|
135
|
-
-ms-flex-
|
|
136
|
-
-webkit-align-
|
|
137
|
-
|
|
131
|
+
-webkit-box-lines: center;
|
|
132
|
+
-ms-flex-line-pack: center;
|
|
133
|
+
-webkit-align-content: center;
|
|
134
|
+
align-content: center;
|
|
138
135
|
}
|
|
139
136
|
|
|
140
137
|
.align-content-between {
|
|
141
|
-
-webkit-box-
|
|
142
|
-
-ms-flex-
|
|
143
|
-
-webkit-align-
|
|
144
|
-
|
|
138
|
+
-webkit-box-lines: justify;
|
|
139
|
+
-ms-flex-line-pack: justify;
|
|
140
|
+
-webkit-align-content: space-between;
|
|
141
|
+
align-content: space-between;
|
|
145
142
|
}
|
|
146
143
|
|
|
147
144
|
.align-content-around {
|
|
148
|
-
-webkit-box-
|
|
149
|
-
-ms-flex-
|
|
150
|
-
-webkit-align-
|
|
151
|
-
|
|
145
|
+
-webkit-box-lines: space-around;
|
|
146
|
+
-ms-flex-line-pack: space-around;
|
|
147
|
+
-webkit-align-content: space-around;
|
|
148
|
+
align-content: space-around;
|
|
152
149
|
}
|
|
153
150
|
|
|
154
151
|
.align-content-stretch {
|
|
155
|
-
-webkit-box-
|
|
156
|
-
-ms-flex-
|
|
157
|
-
-webkit-align-
|
|
158
|
-
|
|
152
|
+
-webkit-box-lines: stretch;
|
|
153
|
+
-ms-flex-line-pack: stretch;
|
|
154
|
+
-webkit-align-content: stretch;
|
|
155
|
+
align-content: stretch;
|
|
159
156
|
}
|
|
160
157
|
|
|
161
158
|
.flex-item-auto {
|
|
@@ -1,4 +1,182 @@
|
|
|
1
|
-
|
|
1
|
+
.flex {
|
|
2
|
+
display: -webkit-box;
|
|
3
|
+
display: -ms-flexbox;
|
|
4
|
+
display: flex;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.inline-flex {
|
|
8
|
+
display: -webkit-inline-box;
|
|
9
|
+
display: -ms-inline-flexbox;
|
|
10
|
+
display: -webkit-inline-flex;
|
|
11
|
+
display: inline-flex;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.flex-row {
|
|
15
|
+
-webkit-box-orient: horizontal;
|
|
16
|
+
-ms-flex-direction: row;
|
|
17
|
+
-webkit-flex-direction: row;
|
|
18
|
+
flex-direction: row;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.flex-row-reverse {
|
|
22
|
+
-webkit-box-orient: horizontal;
|
|
23
|
+
-ms-flex-direction: row-reverse;
|
|
24
|
+
-webkit-flex-direction: row-reverse;
|
|
25
|
+
flex-direction: row-reverse;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.flex-column {
|
|
29
|
+
-webkit-box-orient: vertical;
|
|
30
|
+
-ms-flex-direction: column;
|
|
31
|
+
-webkit-flex-direction: column;
|
|
32
|
+
flex-direction: column;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.flex-column-reverse {
|
|
36
|
+
-webkit-box-orient: vertical;
|
|
37
|
+
-ms-flex-direction: column-reverse;
|
|
38
|
+
-webkit-flex-direction: column-reverse;
|
|
39
|
+
flex-direction: column-reverse;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.justify-content-center {
|
|
43
|
+
-webkit-box-pack: center;
|
|
44
|
+
-ms-flex-pack: center;
|
|
45
|
+
-webkit-justify-content: center;
|
|
46
|
+
justify-content: center;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.justify-content-end {
|
|
50
|
+
-webkit-box-pack: end;
|
|
51
|
+
-ms-flex-pack: end;
|
|
52
|
+
-webkit-justify-content: flex-end;
|
|
53
|
+
justify-content: flex-end;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.justify-content-space-between {
|
|
57
|
+
-webkit-box-pack: justify;
|
|
58
|
+
-ms-flex-pack: justify;
|
|
59
|
+
-webkit-justify-content: space-between;
|
|
60
|
+
justify-content: space-between;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.justify-content-space-around {
|
|
64
|
+
-webkit-box-pack: space-around;
|
|
65
|
+
-ms-flex-pack: space-around;
|
|
66
|
+
-webkit-justify-content: space-around;
|
|
67
|
+
justify-content: space-around;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.align-items-start {
|
|
71
|
+
-webkit-box-align: start;
|
|
72
|
+
-ms-flex-align: start;
|
|
73
|
+
-webkit-align-items: flex-start;
|
|
74
|
+
align-items: flex-start;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.align-items-end {
|
|
78
|
+
-webkit-box-align: end;
|
|
79
|
+
-ms-flex-align: end;
|
|
80
|
+
-webkit-align-items: flex-end;
|
|
81
|
+
align-items: flex-end;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.align-items-center {
|
|
85
|
+
-webkit-box-align: center;
|
|
86
|
+
-ms-flex-align: center;
|
|
87
|
+
-webkit-align-items: center;
|
|
88
|
+
align-items: center;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.align-items-baseline {
|
|
92
|
+
-webkit-box-align: baseline;
|
|
93
|
+
-ms-flex-align: baseline;
|
|
94
|
+
-webkit-align-items: baseline;
|
|
95
|
+
align-items: baseline;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.flex-wrap-nowrap {
|
|
99
|
+
-ms-flex-wrap: nowrap;
|
|
100
|
+
-webkit-flex-wrap: nowrap;
|
|
101
|
+
flex-wrap: nowrap;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.flex-wrap-wrap {
|
|
105
|
+
-ms-flex-wrap: wrap;
|
|
106
|
+
-webkit-flex-wrap: wrap;
|
|
107
|
+
flex-wrap: wrap;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.flex-wrap-reverse {
|
|
111
|
+
-ms-flex-wrap: wrap-reverse;
|
|
112
|
+
-webkit-flex-wrap: wrap-reverse;
|
|
113
|
+
flex-wrap: wrap-reverse;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.align-content-start {
|
|
117
|
+
-webkit-box-lines: start;
|
|
118
|
+
-ms-flex-line-pack: start;
|
|
119
|
+
-webkit-align-content: flex-start;
|
|
120
|
+
align-content: flex-start;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.align-content-end {
|
|
124
|
+
-webkit-box-lines: end;
|
|
125
|
+
-ms-flex-line-pack: end;
|
|
126
|
+
-webkit-align-content: flex-end;
|
|
127
|
+
align-content: flex-end;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.align-content-center {
|
|
131
|
+
-webkit-box-lines: center;
|
|
132
|
+
-ms-flex-line-pack: center;
|
|
133
|
+
-webkit-align-content: center;
|
|
134
|
+
align-content: center;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.align-content-between {
|
|
138
|
+
-webkit-box-lines: justify;
|
|
139
|
+
-ms-flex-line-pack: justify;
|
|
140
|
+
-webkit-align-content: space-between;
|
|
141
|
+
align-content: space-between;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.align-content-around {
|
|
145
|
+
-webkit-box-lines: space-around;
|
|
146
|
+
-ms-flex-line-pack: space-around;
|
|
147
|
+
-webkit-align-content: space-around;
|
|
148
|
+
align-content: space-around;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.align-content-stretch {
|
|
152
|
+
-webkit-box-lines: stretch;
|
|
153
|
+
-ms-flex-line-pack: stretch;
|
|
154
|
+
-webkit-align-content: stretch;
|
|
155
|
+
align-content: stretch;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
.flex-item-auto {
|
|
159
|
+
flex: auto;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
.flex-item {
|
|
163
|
+
flex: 1;
|
|
164
|
+
overflow: hidden;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.flex-item-overflowX {
|
|
168
|
+
flex: 1;
|
|
169
|
+
overflow: hidden;
|
|
170
|
+
width: 0;
|
|
171
|
+
min-width: 0;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.flex-item-overflowY {
|
|
175
|
+
flex: 1;
|
|
176
|
+
overflow: hidden;
|
|
177
|
+
height: 0;
|
|
178
|
+
min-height: 0;
|
|
179
|
+
}
|
|
2
180
|
:root {
|
|
3
181
|
/* 主色调 */
|
|
4
182
|
--primary-color: #1989fa;
|
|
@@ -81,9 +259,13 @@ button[disabled]{
|
|
|
81
259
|
height:100%;
|
|
82
260
|
overflow:hidden;
|
|
83
261
|
.bottom-btns{
|
|
262
|
+
gap:15px;
|
|
263
|
+
padding-left: 10px;
|
|
264
|
+
padding-right: 10px;
|
|
84
265
|
.widget-button{
|
|
85
266
|
display:flex;
|
|
86
267
|
margin:0;
|
|
268
|
+
|
|
87
269
|
flex-direction: column;
|
|
88
270
|
align-items: center;
|
|
89
271
|
color: #646566;
|
|
@@ -101,6 +283,7 @@ button[disabled]{
|
|
|
101
283
|
height: 40px;
|
|
102
284
|
font-size: 14px;
|
|
103
285
|
margin-right: 5px;
|
|
286
|
+
flex:1;
|
|
104
287
|
background: linear-gradient(to right, var(--primary-color-60), var(--primary-color));
|
|
105
288
|
.icon{color:#fff;margin:0 5px 0 0;}
|
|
106
289
|
}
|
|
@@ -1,4 +1,182 @@
|
|
|
1
|
-
|
|
1
|
+
.flex {
|
|
2
|
+
display: -webkit-box;
|
|
3
|
+
display: -ms-flexbox;
|
|
4
|
+
display: flex;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.inline-flex {
|
|
8
|
+
display: -webkit-inline-box;
|
|
9
|
+
display: -ms-inline-flexbox;
|
|
10
|
+
display: -webkit-inline-flex;
|
|
11
|
+
display: inline-flex;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.flex-row {
|
|
15
|
+
-webkit-box-orient: horizontal;
|
|
16
|
+
-ms-flex-direction: row;
|
|
17
|
+
-webkit-flex-direction: row;
|
|
18
|
+
flex-direction: row;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.flex-row-reverse {
|
|
22
|
+
-webkit-box-orient: horizontal;
|
|
23
|
+
-ms-flex-direction: row-reverse;
|
|
24
|
+
-webkit-flex-direction: row-reverse;
|
|
25
|
+
flex-direction: row-reverse;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.flex-column {
|
|
29
|
+
-webkit-box-orient: vertical;
|
|
30
|
+
-ms-flex-direction: column;
|
|
31
|
+
-webkit-flex-direction: column;
|
|
32
|
+
flex-direction: column;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.flex-column-reverse {
|
|
36
|
+
-webkit-box-orient: vertical;
|
|
37
|
+
-ms-flex-direction: column-reverse;
|
|
38
|
+
-webkit-flex-direction: column-reverse;
|
|
39
|
+
flex-direction: column-reverse;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.justify-content-center {
|
|
43
|
+
-webkit-box-pack: center;
|
|
44
|
+
-ms-flex-pack: center;
|
|
45
|
+
-webkit-justify-content: center;
|
|
46
|
+
justify-content: center;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.justify-content-end {
|
|
50
|
+
-webkit-box-pack: end;
|
|
51
|
+
-ms-flex-pack: end;
|
|
52
|
+
-webkit-justify-content: flex-end;
|
|
53
|
+
justify-content: flex-end;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.justify-content-space-between {
|
|
57
|
+
-webkit-box-pack: justify;
|
|
58
|
+
-ms-flex-pack: justify;
|
|
59
|
+
-webkit-justify-content: space-between;
|
|
60
|
+
justify-content: space-between;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.justify-content-space-around {
|
|
64
|
+
-webkit-box-pack: space-around;
|
|
65
|
+
-ms-flex-pack: space-around;
|
|
66
|
+
-webkit-justify-content: space-around;
|
|
67
|
+
justify-content: space-around;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.align-items-start {
|
|
71
|
+
-webkit-box-align: start;
|
|
72
|
+
-ms-flex-align: start;
|
|
73
|
+
-webkit-align-items: flex-start;
|
|
74
|
+
align-items: flex-start;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.align-items-end {
|
|
78
|
+
-webkit-box-align: end;
|
|
79
|
+
-ms-flex-align: end;
|
|
80
|
+
-webkit-align-items: flex-end;
|
|
81
|
+
align-items: flex-end;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.align-items-center {
|
|
85
|
+
-webkit-box-align: center;
|
|
86
|
+
-ms-flex-align: center;
|
|
87
|
+
-webkit-align-items: center;
|
|
88
|
+
align-items: center;
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
.align-items-baseline {
|
|
92
|
+
-webkit-box-align: baseline;
|
|
93
|
+
-ms-flex-align: baseline;
|
|
94
|
+
-webkit-align-items: baseline;
|
|
95
|
+
align-items: baseline;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.flex-wrap-nowrap {
|
|
99
|
+
-ms-flex-wrap: nowrap;
|
|
100
|
+
-webkit-flex-wrap: nowrap;
|
|
101
|
+
flex-wrap: nowrap;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.flex-wrap-wrap {
|
|
105
|
+
-ms-flex-wrap: wrap;
|
|
106
|
+
-webkit-flex-wrap: wrap;
|
|
107
|
+
flex-wrap: wrap;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.flex-wrap-reverse {
|
|
111
|
+
-ms-flex-wrap: wrap-reverse;
|
|
112
|
+
-webkit-flex-wrap: wrap-reverse;
|
|
113
|
+
flex-wrap: wrap-reverse;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.align-content-start {
|
|
117
|
+
-webkit-box-lines: start;
|
|
118
|
+
-ms-flex-line-pack: start;
|
|
119
|
+
-webkit-align-content: flex-start;
|
|
120
|
+
align-content: flex-start;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
.align-content-end {
|
|
124
|
+
-webkit-box-lines: end;
|
|
125
|
+
-ms-flex-line-pack: end;
|
|
126
|
+
-webkit-align-content: flex-end;
|
|
127
|
+
align-content: flex-end;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.align-content-center {
|
|
131
|
+
-webkit-box-lines: center;
|
|
132
|
+
-ms-flex-line-pack: center;
|
|
133
|
+
-webkit-align-content: center;
|
|
134
|
+
align-content: center;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
.align-content-between {
|
|
138
|
+
-webkit-box-lines: justify;
|
|
139
|
+
-ms-flex-line-pack: justify;
|
|
140
|
+
-webkit-align-content: space-between;
|
|
141
|
+
align-content: space-between;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.align-content-around {
|
|
145
|
+
-webkit-box-lines: space-around;
|
|
146
|
+
-ms-flex-line-pack: space-around;
|
|
147
|
+
-webkit-align-content: space-around;
|
|
148
|
+
align-content: space-around;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.align-content-stretch {
|
|
152
|
+
-webkit-box-lines: stretch;
|
|
153
|
+
-ms-flex-line-pack: stretch;
|
|
154
|
+
-webkit-align-content: stretch;
|
|
155
|
+
align-content: stretch;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
.flex-item-auto {
|
|
159
|
+
flex: auto;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
.flex-item {
|
|
163
|
+
flex: 1;
|
|
164
|
+
overflow: hidden;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
.flex-item-overflowX {
|
|
168
|
+
flex: 1;
|
|
169
|
+
overflow: hidden;
|
|
170
|
+
width: 0;
|
|
171
|
+
min-width: 0;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.flex-item-overflowY {
|
|
175
|
+
flex: 1;
|
|
176
|
+
overflow: hidden;
|
|
177
|
+
height: 0;
|
|
178
|
+
min-height: 0;
|
|
179
|
+
}
|
|
2
180
|
body,
|
|
3
181
|
html {
|
|
4
182
|
width: 100%;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<van-field v-model="innerValue" :label="conf.hideLabel ? '' : conf.label" v-bind="filterAttrs"
|
|
3
|
-
@input="handleChange" @clear="handleClear" />
|
|
2
|
+
<van-field v-model="innerValue" :label="conf.hideLabel ? '' : conf.label" v-bind="filterAttrs"
|
|
3
|
+
:rules="mode == 'view' ? [] : rules" @input="handleChange" @clear="handleClear" />
|
|
4
4
|
</template>
|
|
5
5
|
|
|
6
6
|
<script>
|
|
@@ -31,7 +31,7 @@ export default {
|
|
|
31
31
|
const { ...rest } = this.attrs;
|
|
32
32
|
const { widget } = this.conf;
|
|
33
33
|
rest.type = widget == 'password' ? 'password' : widget == 'inputNumber' ? 'number' : widget == 'textarea' ? 'textarea' : 'text'
|
|
34
|
-
if (this.mode == 'view') { rest.readonly = true; rest.
|
|
34
|
+
if (this.mode == 'view') { rest.readonly = true; rest.clearable = false }
|
|
35
35
|
if (rest.class == 'form-control') rest.class = ''
|
|
36
36
|
return rest;
|
|
37
37
|
}
|
|
@@ -139,14 +139,32 @@ export default {
|
|
|
139
139
|
},
|
|
140
140
|
onConfirm(rows) {
|
|
141
141
|
this.showRPicker = false
|
|
142
|
-
|
|
142
|
+
let rowArray = Array.isArray(rows) ? rows : [rows],
|
|
143
|
+
data = []
|
|
144
|
+
rowArray.forEach((row) => {
|
|
145
|
+
const emptyRow = {}
|
|
146
|
+
this.conf.columnsData.forEach((col) => {
|
|
147
|
+
if (
|
|
148
|
+
this.conf.referenceAddApi &&
|
|
149
|
+
this.conf.referenceAddApi.mappings &&
|
|
150
|
+
this.conf.referenceAddApi.mappings.filter((item) => item.name == col.name).length > 0
|
|
151
|
+
) {
|
|
152
|
+
emptyRow[col.name] =
|
|
153
|
+
row[this.conf.referenceAddApi.mappings.filter((item) => item.name == col.name)[0].field]
|
|
154
|
+
} else {
|
|
155
|
+
emptyRow[col.name] = col.defaultValue || ''
|
|
156
|
+
}
|
|
157
|
+
})
|
|
158
|
+
JSON.stringify(emptyRow) !== '{}' && data.push(emptyRow)
|
|
159
|
+
})
|
|
160
|
+
this.innerValue = JSON.stringify(data)
|
|
161
|
+
this.tableData = [...data.map(item => {
|
|
143
162
|
return {
|
|
144
163
|
...item,
|
|
145
164
|
checked: false
|
|
146
165
|
}
|
|
147
166
|
})]
|
|
148
|
-
console.log(rows)
|
|
149
|
-
this.innerValue = JSON.stringify(this.tableData)
|
|
167
|
+
console.log(rows, 'onConfirm', this.tableData, this.tableColumns)
|
|
150
168
|
this.$emit('input', this.innerValue)
|
|
151
169
|
//this.updateCallback(rows)
|
|
152
170
|
//this.$emit('input', this.innerValue);
|
|
@@ -6,10 +6,10 @@
|
|
|
6
6
|
<van-field v-model="innerValueLabel" :label="conf.hideLabel ? '' : conf.label" v-bind="filterAttrs"
|
|
7
7
|
:rules="rules" @click-right-icon="showPicker = true" right-icon="arrow"></van-field>
|
|
8
8
|
<van-popup v-model="showPicker" position="bottom" get-container="#myForm" class="select-popup" closeable
|
|
9
|
-
:style="{ height: '40%' }">
|
|
10
|
-
<div class="custom-picker-container">
|
|
11
|
-
<van-sticky>
|
|
12
|
-
<van-nav-bar title="选择" :border="false" />
|
|
9
|
+
:style="{ height: attrs.multiple ? '40%' : 'auto' }">
|
|
10
|
+
<div class="custom-picker-container flex flex-column h100">
|
|
11
|
+
<van-sticky class="w100">
|
|
12
|
+
<van-nav-bar :title="'选择' + conf.label" :border="false" />
|
|
13
13
|
</van-sticky>
|
|
14
14
|
|
|
15
15
|
<div class="popup-body scroll-wrap" v-if="attrs.multiple">
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
</div>
|
|
24
24
|
</div>
|
|
25
25
|
|
|
26
|
-
<van-picker :columns="selectOptions" value-key="label"
|
|
26
|
+
<van-picker :columns="selectOptions" value-key="label" ref="myPicker" v-else>
|
|
27
27
|
</van-picker>
|
|
28
28
|
<div class="bottom-btn">
|
|
29
29
|
<van-button type="primary" round block @click="onConfirm" icon="checked">确认</van-button>
|
|
@@ -145,16 +145,16 @@ export default {
|
|
|
145
145
|
</script>
|
|
146
146
|
|
|
147
147
|
<style scoped>
|
|
148
|
-
|
|
148
|
+
.bs-suggest-ul {
|
|
149
149
|
max-height: 300px;
|
|
150
150
|
overflow-y: auto;
|
|
151
151
|
}
|
|
152
152
|
|
|
153
|
-
|
|
153
|
+
.bs-suggest-ul li {
|
|
154
154
|
padding: 6px 12px;
|
|
155
155
|
}
|
|
156
156
|
|
|
157
|
-
|
|
157
|
+
.bs-suggest-ul li.active {
|
|
158
158
|
background-color: #337ab7;
|
|
159
159
|
color: #fff;
|
|
160
160
|
}
|
package/src/index.js
CHANGED
|
@@ -16,7 +16,7 @@ import createStore from './store/index'
|
|
|
16
16
|
import ElementUI from 'element-ui';
|
|
17
17
|
import 'element-ui/lib/theme-chalk/index.css';
|
|
18
18
|
import Build from './views/build/index.vue'
|
|
19
|
-
//import Build from './views/build/
|
|
19
|
+
//import Build from './views/build/viewForm.vue'
|
|
20
20
|
import FormItem from '@/components/form/FormItem.vue'
|
|
21
21
|
import Form from '@/components/form/Form.vue'
|
|
22
22
|
import SubRow from '@/components/form/SubRow.vue'
|
|
@@ -178,8 +178,6 @@ export default {
|
|
|
178
178
|
</script>
|
|
179
179
|
|
|
180
180
|
<style scoped>
|
|
181
|
-
.dialog-footer {}
|
|
182
|
-
|
|
183
181
|
.el-select {
|
|
184
182
|
margin: 0 auto;
|
|
185
183
|
}
|
|
@@ -197,11 +195,6 @@ export default {
|
|
|
197
195
|
color: #409eff;
|
|
198
196
|
}
|
|
199
197
|
|
|
200
|
-
.flex {
|
|
201
|
-
display: flex;
|
|
202
|
-
align-items: center;
|
|
203
|
-
}
|
|
204
|
-
|
|
205
198
|
.align-center {
|
|
206
199
|
align-items: center;
|
|
207
200
|
}
|
|
@@ -1076,7 +1076,6 @@ export default {
|
|
|
1076
1076
|
this.changeActiveData('allowedFileType')
|
|
1077
1077
|
},
|
|
1078
1078
|
changeActiveData(key) {
|
|
1079
|
-
console.log(this.activeDataOptions[key])
|
|
1080
1079
|
if (this.activeDataOptions[key] !== undefined && this.currentData[key] !== this.activeData[key]) {
|
|
1081
1080
|
this.$emit('update', key, this.activeData[key])
|
|
1082
1081
|
}
|
|
@@ -1797,19 +1797,4 @@ $lighterBlue: #1e88e5;
|
|
|
1797
1797
|
}
|
|
1798
1798
|
|
|
1799
1799
|
}
|
|
1800
|
-
|
|
1801
|
-
/* 全局美化滚动条(窄滚动条) */
|
|
1802
|
-
/deep/ ::-webkit-scrollbar {
|
|
1803
|
-
width: 3px !important;
|
|
1804
|
-
height: 3px !important;
|
|
1805
|
-
}
|
|
1806
|
-
|
|
1807
|
-
/deep/ ::-webkit-scrollbar-thumb {
|
|
1808
|
-
background: #ccc !important;
|
|
1809
|
-
border-radius: 3px !important;
|
|
1810
|
-
}
|
|
1811
|
-
|
|
1812
|
-
/deep/ ::-webkit-scrollbar-track {
|
|
1813
|
-
background: transparent !important;
|
|
1814
|
-
}
|
|
1815
1800
|
</style>
|