@bsgoal/common 0.1.0 → 1.0.1

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.
Files changed (42) hide show
  1. package/dist/index.mjs +521 -437
  2. package/dist/index.mjs.map +1 -1
  3. package/dist/index.umd.js +1 -1
  4. package/dist/index.umd.js.map +1 -1
  5. package/dist/style.css +1 -1
  6. package/package.json +5 -3
  7. package/src/App.vue +9 -0
  8. package/src/combines/useComs.js +32 -0
  9. package/src/combines/useFetchs.js +48 -0
  10. package/src/components/bsgoal-base-cascader/demo.vue +317 -0
  11. package/src/components/bsgoal-base-cascader/index.vue +93 -0
  12. package/src/components/bsgoal-base-dialog/demo.vue +50 -0
  13. package/src/components/bsgoal-base-dialog/index.vue +133 -0
  14. package/src/components/bsgoal-base-form/demo.vue +187 -0
  15. package/src/components/bsgoal-base-form/index.vue +499 -0
  16. package/src/components/bsgoal-base-frame/demo.vue +35 -0
  17. package/src/components/bsgoal-base-frame/index.vue +29 -0
  18. package/src/components/bsgoal-base-line/demo.vue +42 -0
  19. package/src/components/bsgoal-base-line/index.vue +54 -0
  20. package/src/components/bsgoal-base-search/demo.vue +217 -0
  21. package/src/components/bsgoal-base-search/index.vue +506 -0
  22. package/src/components/bsgoal-base-search-operation/index.vue +74 -0
  23. package/src/components/bsgoal-base-search-table/demo-table.vue +52 -0
  24. package/src/components/bsgoal-base-search-table/demo.vue +664 -0
  25. package/src/components/bsgoal-base-search-table/index.vue +159 -0
  26. package/src/components/bsgoal-base-table/demo.vue +270 -0
  27. package/src/components/bsgoal-base-table/index.vue +281 -0
  28. package/src/components/bsgoal-base-table-content/index.vue +42 -0
  29. package/src/components/bsgoal-base-table-pagination/index.vue +107 -0
  30. package/src/components/bsgoal-base-tree/demo.vue +113 -0
  31. package/src/components/bsgoal-base-tree/index.vue +213 -0
  32. package/src/components/bsgoal-base-tree-fold/index.vue +65 -0
  33. package/src/components/layout/layout-home.vue +60 -0
  34. package/src/components/layout/layout-left-menu.vue +48 -0
  35. package/src/components/layout/layout-right-container.vue +36 -0
  36. package/src/components/layout/layout-top-header.vue +40 -0
  37. package/src/directives/directiveBase.js +94 -0
  38. package/src/entry.js +35 -0
  39. package/src/enums/enumType.js +32 -0
  40. package/src/main.js +11 -0
  41. package/src/router/index.js +71 -0
  42. package/src/styles/index.css +14 -0
@@ -0,0 +1,217 @@
1
+ <!--
2
+ * @Author: canlong.shen
3
+ * @Date: 2023-04-13 09:38:19
4
+ * @LastEditors: canlong.shen
5
+ * @LastEditTime: 2023-04-25 16:31:56
6
+ * @FilePath: \common\src\components\bsgoal-base-search\demo.vue
7
+ * @Description: 表格查询组件演示
8
+ *
9
+ -->
10
+
11
+ <script>
12
+ export default {
13
+ name: 'BsgoalBaseSearchDemo'
14
+ }
15
+ </script>
16
+ <script setup>
17
+ /* setup模板
18
+ ---------------------------------------------------------------- */
19
+ import { ref } from 'vue'
20
+ import BsgoalBaseSearch from './index.vue'
21
+ import EnumType from '../../enums/enumType.js'
22
+
23
+ const searchModelValue = ref({})
24
+
25
+ // props
26
+ const props = defineProps({})
27
+ let curLocalOptions = ref([
28
+ {
29
+ label: 'prop1',
30
+ // value: '111',
31
+ prop: 'prop1',
32
+ type: EnumType.INPUT
33
+ },
34
+ {
35
+ label: 'prop2',
36
+ value: 'select2',
37
+ type: EnumType.SELECT,
38
+ prop: 'prop2',
39
+ range: [
40
+ {
41
+ label: 'select1',
42
+ value: 'select1'
43
+ },
44
+ {
45
+ label: 'select2',
46
+ value: 'select2'
47
+ },
48
+ {
49
+ label: 'select3',
50
+ value: 'select3'
51
+ },
52
+ {
53
+ label: 'select4',
54
+ value: 'select5'
55
+ }
56
+ ]
57
+ },
58
+ {
59
+ label: 'prop3',
60
+ // value: '111',
61
+ type: EnumType.SLIDER,
62
+ prop: 'prop3'
63
+ },
64
+ {
65
+ label: 'prop4',
66
+ // value: '111',
67
+ type: EnumType.SWITCH,
68
+ prop: 'prop4'
69
+ },
70
+ {
71
+ label: 'prop5',
72
+ // value: '111',
73
+ type: EnumType.RADIO,
74
+ prop: 'prop5',
75
+ range: [
76
+ {
77
+ label: 'radio1',
78
+ value: 'radio1'
79
+ },
80
+ {
81
+ label: 'radio2',
82
+ value: 'radio2'
83
+ }
84
+ ]
85
+ },
86
+ {
87
+ label: 'prop6',
88
+ value: [],
89
+ type: EnumType.CHECKBOX,
90
+ prop: 'prop6',
91
+ range: [
92
+ {
93
+ label: 'checkbox1',
94
+ value: 'checkbox1'
95
+ },
96
+ {
97
+ label: 'checkbox2',
98
+ value: 'checkbox2'
99
+ }
100
+ ]
101
+ },
102
+ {
103
+ label: 'prop7',
104
+ // value: '111',
105
+ type: EnumType.DATE,
106
+ prop: 'prop7',
107
+ format: 'YYYY-MM-DD'
108
+ },
109
+ // {
110
+ // label: 'prop8',
111
+ // // value: '111',
112
+ // type: EnumType.WEEK,
113
+ // prop: 'prop8'
114
+
115
+ // },
116
+ {
117
+ label: 'prop9',
118
+ // value: '111',
119
+ type: EnumType.MONTH,
120
+ prop: 'prop9'
121
+ },
122
+ {
123
+ label: 'prop10',
124
+ // value: '111',
125
+ type: EnumType.YEAR,
126
+ prop: 'prop10'
127
+ },
128
+ {
129
+ label: 'prop11',
130
+ // value: '111',
131
+ type: EnumType.DATE_RANGE,
132
+ prop: 'prop11',
133
+ range: ['startDate', 'endDate']
134
+ },
135
+ {
136
+ label: 'prop12',
137
+ // value: '111',
138
+ type: EnumType.MONTH_RANGE,
139
+ prop: 'prop12'
140
+ },
141
+ {
142
+ label: 'prop13',
143
+ // value: '111',
144
+ type: EnumType.TIME,
145
+ prop: 'prop13'
146
+ },
147
+ {
148
+ label: 'prop14',
149
+ // value: '111',
150
+ type: EnumType.TIME_RANGE,
151
+ prop: 'prop14'
152
+ },
153
+ {
154
+ label: 'prop15',
155
+ // value: '111',
156
+ type: EnumType.DATE_TIME,
157
+ prop: 'prop15'
158
+ },
159
+ {
160
+ label: 'prop16',
161
+ // value: '111',
162
+ type: EnumType.DATE_TIME_RANGE,
163
+ prop: 'prop16'
164
+ },
165
+ {
166
+ label: 'prop17',
167
+ type: EnumType.CASCADER,
168
+ prop: 'prop17',
169
+ range: [
170
+ {
171
+ label: 'value1',
172
+ value: 'value1',
173
+ children: [
174
+ {
175
+ label: 'value1-1',
176
+ value: 'value1-1'
177
+ },
178
+ {
179
+ label: 'value1-2',
180
+ value: 'value1-2'
181
+ },
182
+ {
183
+ label: 'value1-3',
184
+ value: 'value1-3'
185
+ },
186
+ {
187
+ label: 'value1-4',
188
+ value: 'value1-5'
189
+ },
190
+ ]
191
+ }
192
+ ]
193
+ }
194
+ ])
195
+ const test = () => {
196
+ curLocalOptions.value = [111]
197
+ }
198
+
199
+ const curInputModel = ref({
200
+ prop: '1'
201
+ })
202
+ </script>
203
+ <template>
204
+ <div class="bsgoal-base-search_demo">
205
+ {{ searchModelValue }}
206
+ <BsgoalBaseSearch :config-options="curLocalOptions" v-model="searchModelValue" />
207
+ <el-button @click="test">点击按钮</el-button>
208
+ </div>
209
+ </template>
210
+ <style lang="scss" scoped>
211
+ /* 自定义样式
212
+ ---------------------------------------------------------------- */
213
+ </style>
214
+ <style lang="scss">
215
+ /* 覆盖样式
216
+ ---------------------------------------------------------------- */
217
+ </style>