@bsgoal/common 2.11.1 → 2.11.3

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bsgoal/common",
3
- "version": "2.11.1",
3
+ "version": "2.11.3",
4
4
  "private": false,
5
5
  "files": [
6
6
  "dist",
@@ -2,7 +2,7 @@
2
2
  * @Author: canlong.shen
3
3
  * @Date: 2023-04-13 09:38:19
4
4
  * @LastEditors: canlong.shen
5
- * @LastEditTime: 2023-04-27 17:44:25
5
+ * @LastEditTime: 2023-06-21 14:23:18
6
6
  * @FilePath: \common\src\components\bsgoal-base-search\demo.vue
7
7
  * @Description: 表格查询组件演示
8
8
  *
@@ -24,7 +24,7 @@ const searchModelValue = ref({})
24
24
  let curLocalOptions = ref([
25
25
  {
26
26
  label: 'prop1',
27
- // value: '111',
27
+ value: '111',
28
28
  prop: 'prop1',
29
29
  type: ComponentTypeEnums.INPUT
30
30
  },
@@ -54,7 +54,7 @@ let curLocalOptions = ref([
54
54
  },
55
55
  {
56
56
  label: 'prop3',
57
- // value: '111',
57
+ value: '111',
58
58
  type: ComponentTypeEnums.SLIDER,
59
59
  prop: 'prop3'
60
60
  },
@@ -2,7 +2,7 @@
2
2
  * @Author: canlong.shen
3
3
  * @Date: 2023-04-13 09:38:11
4
4
  * @LastEditors: canlong.shen
5
- * @LastEditTime: 2023-06-20 19:03:02
5
+ * @LastEditTime: 2023-06-21 14:35:58
6
6
  * @FilePath: \common\src\components\bsgoal-base-search\index.vue
7
7
  * @Description: 表格查询 公共组件
8
8
  *
@@ -17,7 +17,6 @@ import baseDirective from '../../directives/directiveBase.js'
17
17
  import BsgoalBaseLine from '../bsgoal-base-line/index.vue'
18
18
  import BsgoalBaseSearchOperation from '../bsgoal-base-search-operation/index.vue'
19
19
  import BsgoalBaseCascader from '../bsgoal-base-cascader/index.vue'
20
-
21
20
  defineOptions({
22
21
  name: 'BsgoalBaseSearch'
23
22
  })
@@ -72,7 +71,7 @@ const EL_FORM_REF = ref(null)
72
71
  const vAlign = baseDirective.align
73
72
 
74
73
  const model = ref({})
75
- const watchPropList = []
74
+ // const watchPropList = []
76
75
 
77
76
  /**
78
77
  * @Author: canlong.shen
@@ -85,11 +84,8 @@ watchEffect(() => {
85
84
  const { configOptions } = props
86
85
  const options = unref(configOptions)
87
86
  options.forEach((fei) => {
88
- const { value, prop = '', type = '' } = fei
89
- if (![ComponentTypeEnums.INPUT, ComponentTypeEnums.INPUT_TEXT_AREA].includes(type)) {
90
- watchPropList.push(prop)
91
- }
92
- model.value[prop] = [0, false].includes(value) ? value : ''
87
+ const { value, prop = '' } = fei
88
+ model.value[prop] = value || [0, false].includes(value) ? value : ''
93
89
  })
94
90
  })
95
91
 
@@ -210,7 +206,12 @@ const triggerOperationSearch = () => {
210
206
  shadowModel[prop] = value
211
207
  }
212
208
 
213
- if (type.endsWith('range') && range && range.length === 2) {
209
+ if (
210
+ Array.isArray(value) &&
211
+ Array.isArray(range) &&
212
+ type.endsWith('range') &&
213
+ range.length === 2
214
+ ) {
214
215
  const { 0: startValue = '', 1: endValue = '' } = value
215
216
  const { 0: startProp = '', 1: endProp = '' } = range
216
217
  shadowModel[startProp] = startValue
@@ -271,7 +272,6 @@ const triggerValueChange = (type, prop) => {
271
272
  emits('on-change', emitValue)
272
273
  }
273
274
 
274
-
275
275
  // ---> S 暴露 <---
276
276
  defineExpose({
277
277
  triggerOperationSearch
@@ -2,7 +2,7 @@
2
2
  * @Author: canlong.shen
3
3
  * @Date: 2023-04-18 17:04:53
4
4
  * @LastEditors: canlong.shen
5
- * @LastEditTime: 2023-06-21 10:22:10
5
+ * @LastEditTime: 2023-06-21 14:26:18
6
6
  * @FilePath: \common\src\components\bsgoal-base-search-table\demo.vue
7
7
  * @Description: 查询 + 表格 组合公共组件
8
8
  *
@@ -25,7 +25,7 @@ const props = defineProps({})
25
25
  const configOptions = ref([
26
26
  {
27
27
  label: 'prop1',
28
- // value: '111',
28
+ value: '111',
29
29
  prop: 'prop1',
30
30
  type: ComponentTypeEnums.INPUT,
31
31
  width: '100px'
@@ -2,7 +2,7 @@
2
2
  * @Author: canlong.shen
3
3
  * @Date: 2023-05-08 15:11:05
4
4
  * @LastEditors: canlong.shen
5
- * @LastEditTime: 2023-05-08 15:11:11
5
+ * @LastEditTime: 2023-06-21 14:07:09
6
6
  * @FilePath: \common\src\utils\common.js
7
7
  * @Description: 常用的工具方法
8
8
  *
@@ -51,3 +51,6 @@ export const isBoolean = (tar) => {
51
51
  export const isUndefind = (tar) => {
52
52
  return getInstanceType(tar) === 'undefind'
53
53
  }
54
+ export const isArray = (tar) => {
55
+ return Array.isArray(tar)
56
+ };
@@ -1,8 +0,0 @@
1
- [0531/113627.873:ERROR:registration_protocol_win.cc(107)] CreateFile: ϵͳ�Ҳ���ָ�����ļ��� (0x2)
2
- [0531/113628.535:ERROR:registration_protocol_win.cc(107)] CreateFile: ϵͳ�Ҳ���ָ�����ļ��� (0x2)
3
- [0531/114349.870:ERROR:registration_protocol_win.cc(107)] CreateFile: ϵͳ�Ҳ���ָ�����ļ��� (0x2)
4
- [0531/134940.513:ERROR:registration_protocol_win.cc(107)] CreateFile: ϵͳ�Ҳ���ָ�����ļ��� (0x2)
5
- [0531/134940.513:ERROR:registration_protocol_win.cc(107)] CreateFile: ϵͳ�Ҳ���ָ�����ļ��� (0x2)
6
- [0531/140033.847:ERROR:registration_protocol_win.cc(107)] CreateFile: ϵͳ�Ҳ���ָ�����ļ��� (0x2)
7
- [0531/140033.869:ERROR:registration_protocol_win.cc(107)] CreateFile: ϵͳ�Ҳ���ָ�����ļ��� (0x2)
8
- [0531/143430.040:ERROR:registration_protocol_win.cc(107)] CreateFile: ϵͳ�Ҳ���ָ�����ļ��� (0x2)