bri-components 1.2.91 → 1.2.92

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": "bri-components",
3
- "version": "1.2.91",
3
+ "version": "1.2.92",
4
4
  "author": "dengshanghui",
5
5
  "description": "a component lib for vue project",
6
6
  "main": "src/index.js",
@@ -30,7 +30,7 @@
30
30
  :formList="canSearchFormList"
31
31
  :useChainField="useChainField"
32
32
  :dynamicFormList="dynamicFormList"
33
- @change="change('loopControl', conditionItem, ...arguments)"
33
+ @change="change('loopSearch', conditionItem, ...arguments)"
34
34
  >
35
35
  <slot
36
36
  slot-scope="{ conditionItem }"
@@ -72,6 +72,7 @@
72
72
  <template v-else-if="['subSearch', 'subTableSearch'].includes(conditionItem.fieldOperator)">
73
73
  <dsh-adv-search
74
74
  v-if="conditionItem.finished === true"
75
+ style="padding: 0px 0px 0px 8px;"
75
76
  :mode="mode"
76
77
  :isInner="true"
77
78
  :value="conditionItem.fieldSearch"
@@ -324,7 +325,7 @@
324
325
  }
325
326
 
326
327
  &-logic {
327
- margin: 5px 0px 10px;
328
+ margin: 0px 0px 10px;
328
329
  .dsh-flex-row-start-center();
329
330
 
330
331
  &-title {
@@ -369,7 +370,7 @@
369
370
 
370
371
  &-item {
371
372
  padding: 0!important;
372
- margin-bottom: 10px!important;
373
+ margin-bottom: 8px!important;
373
374
  cursor: pointer;
374
375
 
375
376
  &-loading {
@@ -148,7 +148,13 @@ export default {
148
148
  }
149
149
  },
150
150
  // 发生改动
151
- change (operationType, conditionItem) {
151
+ change (operationType, conditionItem, subAdvSearchObj) {
152
+ if (operationType === "loopSearch") {
153
+ Object.assign(conditionItem, subAdvSearchObj);
154
+ } else if (operationType === "subSearch") {
155
+ Object.assign(conditionItem.fieldSearch, subAdvSearchObj);
156
+ }
157
+
152
158
  const advSearchObj = {
153
159
  ...this.advSearchObj,
154
160
  conditions: this.transformConditions(this.advSearchObj.conditions)
@@ -213,6 +219,7 @@ export default {
213
219
  };
214
220
  } else {
215
221
  return {
222
+ _id: this.$ObjectID().str,
216
223
  ...initContion,
217
224
  __isDelete__: true, // 前端用它标识对应字段已被删除的筛选项
218
225
  formItem: {
@@ -222,24 +229,30 @@ export default {
222
229
  }
223
230
  } else if (["and", "or"].includes(initContion.logic)) {
224
231
  return {
232
+ _id: this.$ObjectID().str,
225
233
  logic: "and",
226
234
  conditions: [],
227
235
  ...initContion
228
236
  };
229
237
  } else if (["text"].includes(initContion.logic)) {
230
238
  return {
239
+ _id: this.$ObjectID().str,
231
240
  logic: "text",
232
241
  textSearch: "",
233
242
  ...initContion
234
243
  };
235
244
  } else if (["native"].includes(initContion.logic)) {
236
245
  return {
246
+ _id: this.$ObjectID().str,
237
247
  logic: "native",
238
248
  nativeSearch: {},
239
249
  ...initContion
240
250
  };
241
251
  } else {
242
- return initContion;
252
+ return {
253
+ _id: this.$ObjectID().str,
254
+ ...initContion
255
+ };
243
256
  }
244
257
  },
245
258
  // 获取表单配置