byt-ui 0.0.17 → 0.0.19
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 +172 -172
- package/lib/byt-ui.common.js +46 -15
- package/lib/byt-ui.css +1 -1
- package/lib/byt-ui.umd.js +46 -15
- package/lib/byt-ui.umd.min.js +1 -1
- package/package.json +1 -1
- package/packages/common/modules/cookie.js +6 -2
- package/packages/components/basic-view/index.vue +9 -5
- package/packages/components/form-view/index.vue +20 -3
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* @Description:
|
|
3
3
|
* @Author: 王国火
|
|
4
4
|
* @Date: 2022-10-18 12:37:03
|
|
5
|
-
* @LastEditTime:
|
|
5
|
+
* @LastEditTime: 2023-07-11 14:28:17
|
|
6
6
|
* @LastEditors: 王国火
|
|
7
7
|
*/
|
|
8
8
|
import Cookie from 'js-cookie'
|
|
@@ -29,5 +29,9 @@ export const setCookie = (key, value, expires = 7, path = '/') => {
|
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
export const removeCookie = (key, path = '/') => {
|
|
32
|
-
|
|
32
|
+
console.log(`${website.key}-${key}`)
|
|
33
|
+
return Cookie.remove(`${website.key}-${key}`, {
|
|
34
|
+
path,
|
|
35
|
+
domain:window.location.hostname
|
|
36
|
+
})
|
|
33
37
|
}
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
* @Description:
|
|
3
3
|
* @Author: 王国火
|
|
4
4
|
* @Date: 2022-07-12 17:47:20
|
|
5
|
-
* @LastEditTime: 2023-
|
|
6
|
-
* @LastEditors:
|
|
5
|
+
* @LastEditTime: 2023-09-13 09:50:53
|
|
6
|
+
* @LastEditors: hcm
|
|
7
7
|
-->
|
|
8
8
|
|
|
9
9
|
<template>
|
|
@@ -19,7 +19,11 @@
|
|
|
19
19
|
@reset="onReset"
|
|
20
20
|
@init="init"
|
|
21
21
|
v-model="searchForm"
|
|
22
|
-
|
|
22
|
+
>
|
|
23
|
+
<template #filters>
|
|
24
|
+
<slot name="filters"></slot>
|
|
25
|
+
</template>
|
|
26
|
+
</FormView>
|
|
23
27
|
</div>
|
|
24
28
|
|
|
25
29
|
<div class="action-view">
|
|
@@ -59,7 +63,7 @@
|
|
|
59
63
|
<vxe-column
|
|
60
64
|
:fixed="column.fixed"
|
|
61
65
|
v-else-if="column.slot"
|
|
62
|
-
:width="column.width
|
|
66
|
+
:width="column.width"
|
|
63
67
|
:title="column.label"
|
|
64
68
|
:align="column.align||'center'"
|
|
65
69
|
:key="index"
|
|
@@ -86,7 +90,7 @@
|
|
|
86
90
|
:type="column.type"
|
|
87
91
|
v-else
|
|
88
92
|
:field="column.key"
|
|
89
|
-
:width="column.width
|
|
93
|
+
:width="column.width"
|
|
90
94
|
:title="column.label"
|
|
91
95
|
:align="column.align||'center'"
|
|
92
96
|
:key="index"
|
|
@@ -2,15 +2,16 @@
|
|
|
2
2
|
* @Description:
|
|
3
3
|
* @Author: 王国火
|
|
4
4
|
* @Date: 2022-07-13 08:46:34
|
|
5
|
-
* @LastEditTime: 2023-
|
|
6
|
-
* @LastEditors:
|
|
5
|
+
* @LastEditTime: 2023-09-13 09:54:09
|
|
6
|
+
* @LastEditors: hcm
|
|
7
7
|
-->
|
|
8
8
|
<!-- -->
|
|
9
9
|
<template>
|
|
10
10
|
<el-form ref="form" :model="form" :inline="inline" :label-width="`${labelWidth}px`">
|
|
11
11
|
<el-form-item :label="item.label" :key="index" v-for="(item,index) in searchList">
|
|
12
12
|
<template v-if="item.type=='input' || !item.type">
|
|
13
|
-
|
|
13
|
+
<!-- update by hcm 回车触发过滤 -->
|
|
14
|
+
<el-input v-model="form[item.key]" clearable :placeholder="`请输入${item.label}`" @keyup.enter.native="onSearch"></el-input>
|
|
14
15
|
</template>
|
|
15
16
|
|
|
16
17
|
<template v-if="item.type=='cascader'">
|
|
@@ -59,6 +60,22 @@
|
|
|
59
60
|
>
|
|
60
61
|
</el-date-picker>
|
|
61
62
|
</template>
|
|
63
|
+
|
|
64
|
+
<!-- add by hcm 加时间区间类型-->
|
|
65
|
+
<template v-if="item.type=='datetimerange'">
|
|
66
|
+
<el-date-picker
|
|
67
|
+
v-model="form[item.key]"
|
|
68
|
+
type="datetimerange"
|
|
69
|
+
range-separator="至"
|
|
70
|
+
start-placeholder="开始时间"
|
|
71
|
+
end-placeholder="结束时间"
|
|
72
|
+
value-format="yyyy-MM-dd"
|
|
73
|
+
:picker-options="pickerOptions"
|
|
74
|
+
>
|
|
75
|
+
</el-date-picker>
|
|
76
|
+
</template>
|
|
77
|
+
<!-- add by hcm 加插槽 增加灵活性 -->
|
|
78
|
+
<slot name="filters"></slot>
|
|
62
79
|
</el-form-item>
|
|
63
80
|
|
|
64
81
|
<el-form-item>
|