gyyg-components 0.3.23 → 0.3.25
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/lib/gyyg-components.common.js +109 -109
- package/lib/gyyg-components.umd.js +109 -109
- package/lib/gyyg-components.umd.min.js +109 -109
- package/package.json +1 -1
- package/src/components/MECDefaultText/MECDefaultText.vue +2 -2
- package/src/components/MecDialog/MecDialog.vue +20 -21
- package/src/components/MecDrawer/MecDrawer.vue +5 -1
- package/src/components/MecForm/MecForm.vue +6 -4
- package/src/components/MecInputTable/MecInputTable.vue +1 -1
- package/src/components/MecRadio/MecRadio.vue +4 -0
- package/src/components/MecTable/MecTable.vue +7 -1
- package/src/components/MecTabs/MecTabs.vue +5 -1
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div :class="textType == 'littleTitle' ? 'title' : ''">{{ value }}</div>
|
|
2
|
+
<div :class="textType == 'littleTitle' ? 'title' : ''" :style="style">{{ value }}</div>
|
|
3
3
|
</template>
|
|
4
4
|
<script>
|
|
5
5
|
export default {
|
|
6
6
|
name: 'mec-defaultText',
|
|
7
|
-
props:['value', 'textType']
|
|
7
|
+
props:['value', 'textType', 'style']
|
|
8
8
|
}
|
|
9
9
|
</script>
|
|
10
10
|
<style lang="less" scoped>
|
|
@@ -17,24 +17,19 @@
|
|
|
17
17
|
@closed="closed"
|
|
18
18
|
@close="closeMethod"
|
|
19
19
|
:destroy-on-close="destroyOnClose"
|
|
20
|
-
:modal=
|
|
20
|
+
:modal="modal"
|
|
21
|
+
:close-on-press-escape="false"
|
|
21
22
|
ref="dialog"
|
|
22
23
|
>
|
|
23
|
-
<div
|
|
24
|
-
slot="title"
|
|
25
|
-
style="font-size: 16px; color: #303133;"
|
|
26
|
-
>
|
|
24
|
+
<div slot="title" style="font-size: 16px; color: #303133">
|
|
27
25
|
<el-icon
|
|
28
26
|
:class="titleIcon"
|
|
29
|
-
style="color: #1890ff; font-size: 18px;margin-right: 5px
|
|
27
|
+
style="color: #1890ff; font-size: 18px; margin-right: 5px"
|
|
30
28
|
></el-icon>
|
|
31
29
|
<span>{{ title }}</span>
|
|
32
30
|
</div>
|
|
33
31
|
<slot name="body" />
|
|
34
|
-
<div
|
|
35
|
-
v-if="footer"
|
|
36
|
-
slot="footer"
|
|
37
|
-
>
|
|
32
|
+
<div v-if="footer" slot="footer">
|
|
38
33
|
<slot name="footer" />
|
|
39
34
|
</div>
|
|
40
35
|
</el-dialog>
|
|
@@ -84,12 +79,12 @@ export default {
|
|
|
84
79
|
// 是否显示叉号
|
|
85
80
|
showClose: {
|
|
86
81
|
default: true,
|
|
87
|
-
type: Boolean
|
|
82
|
+
type: Boolean,
|
|
88
83
|
},
|
|
89
84
|
//是否需要遮罩层
|
|
90
85
|
modal: {
|
|
91
86
|
default: true,
|
|
92
|
-
type: Boolean
|
|
87
|
+
type: Boolean,
|
|
93
88
|
},
|
|
94
89
|
dragDialog: {
|
|
95
90
|
type: Boolean,
|
|
@@ -97,16 +92,16 @@ export default {
|
|
|
97
92
|
},
|
|
98
93
|
dialogClass: {
|
|
99
94
|
type: String,
|
|
100
|
-
default: ""
|
|
95
|
+
default: "",
|
|
101
96
|
},
|
|
102
97
|
titleIcon: {
|
|
103
98
|
type: String,
|
|
104
|
-
default:
|
|
99
|
+
default: "",
|
|
105
100
|
},
|
|
106
101
|
height: {
|
|
107
102
|
type: String,
|
|
108
|
-
default:
|
|
109
|
-
}
|
|
103
|
+
default: "auto",
|
|
104
|
+
},
|
|
110
105
|
},
|
|
111
106
|
data() {
|
|
112
107
|
return {
|
|
@@ -116,7 +111,10 @@ export default {
|
|
|
116
111
|
},
|
|
117
112
|
computed: {
|
|
118
113
|
customClass() {
|
|
119
|
-
let className =
|
|
114
|
+
let className =
|
|
115
|
+
this.height !== "auto"
|
|
116
|
+
? this.dialogClass + " haveHeight-dialog"
|
|
117
|
+
: this.dialogClass;
|
|
120
118
|
return className;
|
|
121
119
|
},
|
|
122
120
|
},
|
|
@@ -127,13 +125,12 @@ export default {
|
|
|
127
125
|
methods: {
|
|
128
126
|
open() {
|
|
129
127
|
this.visible = true;
|
|
130
|
-
console.log(this.height)
|
|
131
|
-
if(this.height !==
|
|
128
|
+
console.log(this.height);
|
|
129
|
+
if (this.height !== "auto" && this.height) {
|
|
132
130
|
this.$nextTick(() => {
|
|
133
131
|
this.$refs.dialog.$el.firstElementChild.style.height = this.height;
|
|
134
132
|
});
|
|
135
133
|
}
|
|
136
|
-
|
|
137
134
|
},
|
|
138
135
|
close() {
|
|
139
136
|
this.visible = false;
|
|
@@ -194,6 +191,9 @@ export default {
|
|
|
194
191
|
padding: 20px;
|
|
195
192
|
padding-bottom: 52px;
|
|
196
193
|
height: calc(100% - 50px);
|
|
194
|
+
.el-tabs {
|
|
195
|
+
margin-top: -10px;
|
|
196
|
+
}
|
|
197
197
|
}
|
|
198
198
|
|
|
199
199
|
.el-dialog__footer {
|
|
@@ -221,7 +221,6 @@ export default {
|
|
|
221
221
|
}
|
|
222
222
|
|
|
223
223
|
.custom-table {
|
|
224
|
-
|
|
225
224
|
// 取消表格下边线
|
|
226
225
|
tbody tr:last-child td {
|
|
227
226
|
border-bottom: none !important;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
|
-
<el-drawer :visible.sync="searchDrawerVisible" direction="rtl" :before-close="handleBeforeClose" :modal="
|
|
3
|
+
<el-drawer :visible.sync="searchDrawerVisible" direction="rtl" :before-close="handleBeforeClose" :modal="modal"
|
|
4
4
|
icon="el-icon-search" :size="width">
|
|
5
5
|
<!-- 标题区域 -->
|
|
6
6
|
<div slot="title" class="drawer-title">
|
|
@@ -33,6 +33,10 @@ export default {
|
|
|
33
33
|
title: {
|
|
34
34
|
type: String,
|
|
35
35
|
default: '筛选'
|
|
36
|
+
},
|
|
37
|
+
modal: {
|
|
38
|
+
type: Boolean,
|
|
39
|
+
default: false
|
|
36
40
|
}
|
|
37
41
|
},
|
|
38
42
|
data() {
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
:label-width="item.labelWidth"
|
|
24
24
|
>
|
|
25
25
|
<template slot="label">
|
|
26
|
-
<span v-if="item.label">
|
|
26
|
+
<span v-if="item.label || item.isNotLabelShow">
|
|
27
27
|
<span :style="'color:' + item.labelColor">{{ item.label }}</span>
|
|
28
28
|
<el-tooltip
|
|
29
29
|
v-if="item.tooltip"
|
|
@@ -40,10 +40,10 @@
|
|
|
40
40
|
:is="item['componentName']"
|
|
41
41
|
v-model="item.value"
|
|
42
42
|
:value.sync="item.value"
|
|
43
|
-
:otherValue.sync="item.otherValue"
|
|
43
|
+
:otherValue.sync="item.otherValue"
|
|
44
44
|
:delIdList.sync="item.delIdList"
|
|
45
45
|
v-bind="item"
|
|
46
|
-
v-on="item.componentListeners"
|
|
46
|
+
v-on="typeof item.componentListeners === 'function' ? item.componentListeners(formData, item) : item.componentListeners || {}"
|
|
47
47
|
:ref="item.componentRef"
|
|
48
48
|
></component>
|
|
49
49
|
</el-form-item>
|
|
@@ -113,7 +113,6 @@ export default {
|
|
|
113
113
|
};
|
|
114
114
|
</script>
|
|
115
115
|
<style lang="less" scoped>
|
|
116
|
-
|
|
117
116
|
::v-deep.el-form::after {
|
|
118
117
|
content: "";
|
|
119
118
|
display: table;
|
|
@@ -126,5 +125,8 @@ export default {
|
|
|
126
125
|
.el-form-item {
|
|
127
126
|
margin-bottom: 12px;
|
|
128
127
|
}
|
|
128
|
+
.el-form-item__label {
|
|
129
|
+
display: inline;
|
|
130
|
+
}
|
|
129
131
|
}
|
|
130
132
|
</style>
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
v-model="inputValue"
|
|
20
20
|
:disabled="inputDisabled"
|
|
21
21
|
placeholder="请输入"
|
|
22
|
+
@input="inputChange"
|
|
22
23
|
style="display: inline-block; margin-top: 10px"
|
|
23
24
|
/>
|
|
24
25
|
<!-- @input="inputChange" -->
|
|
@@ -143,6 +144,9 @@ export default {
|
|
|
143
144
|
this.props.label
|
|
144
145
|
];
|
|
145
146
|
},
|
|
147
|
+
inputChange(val){
|
|
148
|
+
this.$emit("otherInput", val)
|
|
149
|
+
}
|
|
146
150
|
},
|
|
147
151
|
};
|
|
148
152
|
</script>
|
|
@@ -37,7 +37,7 @@
|
|
|
37
37
|
type="index"
|
|
38
38
|
width="50">
|
|
39
39
|
</el-table-column>
|
|
40
|
-
<template v-for="(col, index) in
|
|
40
|
+
<template v-for="(col, index) in filteredColumns">
|
|
41
41
|
<el-table-column
|
|
42
42
|
v-if="!col['type'] && (!col.headerList || col.headerList.length === 0)"
|
|
43
43
|
:label="col.label"
|
|
@@ -50,6 +50,7 @@
|
|
|
50
50
|
:key="col.id"
|
|
51
51
|
:fixed="col.fixed"
|
|
52
52
|
:prop="col.bind"
|
|
53
|
+
|
|
53
54
|
>
|
|
54
55
|
<template
|
|
55
56
|
slot="header"
|
|
@@ -279,6 +280,11 @@ export default {
|
|
|
279
280
|
column: []
|
|
280
281
|
}
|
|
281
282
|
},
|
|
283
|
+
computed: {
|
|
284
|
+
filteredColumns() {
|
|
285
|
+
return this.columns.filter(item => !item.showColumns || item.showColumns(item))
|
|
286
|
+
}
|
|
287
|
+
},
|
|
282
288
|
methods: {
|
|
283
289
|
// 列表选中当前行字体加粗
|
|
284
290
|
selectedRowStyle({ row }) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<div>
|
|
3
|
-
<el-tabs v-model="activeName" v-bind="$attrs" @tab-click="handleClick">
|
|
3
|
+
<el-tabs v-model="activeName" v-bind="$attrs" @tab-click="handleClick" :type="type">
|
|
4
4
|
<el-tab-pane
|
|
5
5
|
v-for="(item, index) in tabList"
|
|
6
6
|
:key="index+item.label"
|
|
@@ -37,6 +37,10 @@ export default {
|
|
|
37
37
|
};
|
|
38
38
|
},
|
|
39
39
|
},
|
|
40
|
+
type: {
|
|
41
|
+
type: String,
|
|
42
|
+
default: ''
|
|
43
|
+
}
|
|
40
44
|
},
|
|
41
45
|
data() {
|
|
42
46
|
return {
|