agilebuilder-ui 1.1.42 → 1.1.43-sit1

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.
@@ -1,5 +1,5 @@
1
1
  import { openBlock as r, createElementBlock as t, createCommentVNode as o } from "vue";
2
- import { _ as s } from "./index-50fdf8ae.js";
2
+ import { _ as s } from "./index-619c9fa7.js";
3
3
  const u = ["src"], f = s({ data: () => ({ src: null }), watch: { $route(n, c) {
4
4
  this.src = this.$route.query.src;
5
5
  } }, mounted() {
@@ -1,4 +1,4 @@
1
- import { _ as f, c as _, g as x, b as P, s as h, m as M, M as O, i as I } from "./index-50fdf8ae.js";
1
+ import { _ as f, c as _, g as x, b as P, s as h, m as M, M as O, i as I } from "./index-619c9fa7.js";
2
2
  import { resolveComponent as u, openBlock as l, createBlock as b, withCtx as g, createVNode as v, TransitionGroup as L, createElementBlock as p, Fragment as C, renderList as T, createElementVNode as m, toDisplayString as w, normalizeClass as S, createCommentVNode as y } from "vue";
3
3
  const k = { class: "no-redirect" }, A = f({ name: "Breadcrumb", data: () => ({ levelList: null }), computed: { levelListWithTitle() {
4
4
  return this.levelList.filter((e) => e.meta.title !== void 0 && e.meta.title !== null);
@@ -1,5 +1,5 @@
1
1
  import { resolveComponent as t, openBlock as a, createElementBlock as s, createElementVNode as y, createVNode as l, withCtx as r, createTextVNode as n, toDisplayString as p, createCommentVNode as c, createBlock as h } from "vue";
2
- import { _ as I } from "./index-50fdf8ae.js";
2
+ import { _ as I } from "./index-619c9fa7.js";
3
3
  const g = { style: { "padding-bottom": "10px" } }, k = { key: 0, class: "graphDiv" }, N = I({ name: "TacheSubprocessHistory", data: () => ({ type: "graph", workflowId: null }), created() {
4
4
  const o = this.$route.query.workflowId;
5
5
  o && (this.workflowId = parseInt(o));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "agilebuilder-ui",
3
- "version": "1.1.42",
3
+ "version": "1.1.43-sit1",
4
4
  "type": "module",
5
5
  "private": false,
6
6
  "main": "./lib/super-ui.js",
@@ -281,7 +281,7 @@ const customFormatter = {
281
281
  if (gridParams.options.extraParam && gridParams.options.extraParam.entityMap) {
282
282
  parentFormData = gridParams.options.extraParam.entityMap
283
283
  }
284
- if (gridParams.isSubTableShowPage && jumpPageSetting.jumpPageAdditional?.length > 0) {
284
+ if (gridParams.options.isFormSubTable && jumpPageSetting.jumpPageAdditional?.length > 0) {
285
285
  // 如果是子表,则需要把配置的 ${data.字段} 改成 ${parent.字段}
286
286
  jumpPageSetting.jumpPageAdditional.forEach((item, index) => {
287
287
  if (item && item.paramValue) {
@@ -487,7 +487,7 @@
487
487
  :multiple="isMultiTree"
488
488
  :table-name="tableName"
489
489
  :tree-type="
490
- deptManTree ? 'DeptUserTree' : deptTree ? 'DeptTree' : wgManTree ? 'WgTree' : wgTree ? 'WgUserTree' : null
490
+ deptManTree ? 'DeptUserTree' : deptTree ? 'DeptTree' : wgManTree ? 'WgUserTree' : wgTree ? 'WgTree' : null
491
491
  "
492
492
  :value="innerValue"
493
493
  @append="appendOrganizationInputEvent"
@@ -107,6 +107,7 @@
107
107
  :is-show="operation.isShow"
108
108
  :label="operation.props.label ? operation.props.label : row[column.prop]"
109
109
  :on-click="operation.onClick"
110
+ :operation="operation"
110
111
  :operation-index="operationIndex"
111
112
  :operation-setting="operation.props"
112
113
  :event-name="operation.eventName"
@@ -1,10 +1,10 @@
1
1
  <template>
2
2
  <!--将@click改为@mousedown.native是因为操作列保存按钮时事件和input等组件的@blur冲突,导致保存需要保存两次,因为
3
3
  @blur先于@click执行的,所以只会执行@blur,@click就失效了,@mousedown是先于@blur执行的-->
4
- <span :style="myStyle">
4
+ <span class="table-operation-row-btn" :style="myStyle">
5
5
  <template v-if="isShowButton()">
6
6
  <el-tooltip :disabled="tooltipDisabled" :content="label" placement="top">
7
- <template v-if="operationSettingData.permission">
7
+ <template v-if="operationSettingData?.permission">
8
8
  <component
9
9
  v-bind="operationSettingData"
10
10
  :is="isElementType"
@@ -77,9 +77,13 @@ export default {
77
77
  type: String,
78
78
  default: null,
79
79
  },
80
+ operation: {
81
+ type: Object,
82
+ default: () => ({}),
83
+ },
80
84
  operationSetting: {
81
85
  type: Object,
82
- default: null,
86
+ default: () => ({}),
83
87
  },
84
88
  operationIndex: {
85
89
  type: Number,
@@ -148,16 +152,16 @@ export default {
148
152
  },
149
153
  // 后置图标
150
154
  suffixIcon() {
151
- if(['right'].includes(this.operationSettingData.iconPosition)) return this.operationSetting.iconValue
155
+ if(['right'].includes(this.operationSetting.iconPosition)) return this.operationSetting.iconValue
152
156
  return undefined
153
157
  },
154
158
  // 是否显示文字按钮 > 图标模式
155
159
  isTextIcon() {
156
160
  if (this.isTableBtnLinkShow) {
157
- if (this.operationSettingData.isTextIcon === undefined) {
161
+ if (this.operationSetting.isTextIcon === undefined) {
158
162
  return this.isSaveRow || this.isDeleteRow || this.isEditRow || this.isRestoreRow
159
163
  }
160
- return this.operationSettingData.isTextIcon
164
+ return this.operationSetting.isTextIcon
161
165
  } else {
162
166
  return false
163
167
  }
@@ -172,14 +176,14 @@ export default {
172
176
  },
173
177
  // 是否自动开启表格 按钮 转 文字按钮
174
178
  isTableBtnLinkShow() {
175
- if (this.operationSetting.text) return true
179
+ if (this.operationSetting?.text) return true
176
180
  if (this.isTableBtnLink && this.elementType === 'el-button') {
177
- return [this.operationSetting.text, this.operationSetting.plain, this.operationSetting.round].every(v => v === undefined)
181
+ return [this.operationSetting?.text, this.operationSetting?.plain, this.operationSetting?.round].every(v => v === undefined)
178
182
  }
179
183
  return false
180
184
  },
181
185
  operationSettingData() {
182
- const dataList = { ...this.operationSetting }
186
+ const dataList = { ...(this.operationSetting ?? {}) }
183
187
  if (this.isTableBtnLinkShow) {
184
188
  dataList.underline = false
185
189
  delete dataList.text
@@ -460,7 +460,7 @@ export default {
460
460
  // 限制高度最低值
461
461
  hasMaxHeight() {
462
462
  if (this.maxHeight) {
463
- return this.maxHeight <= 100 ? 100 : this.maxHeight + this.heightOffset
463
+ return this.maxHeight <= 100 ? 100 : this.maxHeight + (this.heightOffset!==0?this.heightOffset:30)
464
464
  }
465
465
  return undefined
466
466
  },
@@ -468,7 +468,7 @@ export default {
468
468
  // 是指固定高度最低值
469
469
  hasTableHeight() {
470
470
  if (this.tableHeight) {
471
- return this.tableHeight <= 100 ? 100 : this.tableHeight + this.heightOffset
471
+ return this.tableHeight <= 100 ? 100 : this.tableHeight + (this.heightOffset!==0?this.heightOffset:30)
472
472
  }
473
473
  return undefined
474
474
  },
@@ -523,6 +523,8 @@ export default {
523
523
  // 表示不显示“序号”列
524
524
  return false
525
525
  }
526
+ // 存储有默认值的字段集合
527
+ this.storeHasDefaultValueColumns(column, gridParams)
526
528
  let isVisible
527
529
  if (column.show === undefined || column.show) {
528
530
  isVisible = true
@@ -547,8 +549,6 @@ export default {
547
549
  } else {
548
550
  isVisible = false
549
551
  }
550
- // 存储有默认值的字段集合
551
- this.storeHasDefaultValueColumns(column, gridParams)
552
552
  return isVisible
553
553
  })
554
554
  )
@@ -1288,7 +1288,11 @@ export default {
1288
1288
  if (gridParams.defaultValueColumns === undefined || gridParams.defaultValueColumns === null) {
1289
1289
  gridParams.defaultValueColumns = []
1290
1290
  }
1291
- gridParams.defaultValueColumns.push(column)
1291
+ // 放到defaultValueColumns前要根据column.prop判断是否已经存在
1292
+ const hasColumn = gridParams.defaultValueColumns.find((item) => item.prop === column.prop)
1293
+ if (!hasColumn) {
1294
+ gridParams.defaultValueColumns.push(column)
1295
+ }
1292
1296
  }
1293
1297
  },
1294
1298
  // 判断是不是表单子表的使用
@@ -3402,11 +3406,17 @@ export default {
3402
3406
  this.$refs.superGrid.setCurrentRow(this.tableDatas[rowIndex])
3403
3407
  },
3404
3408
  getSuperGridRef() {
3409
+ return this
3410
+ },
3411
+ getSuperGridTableRef() {
3405
3412
  return this.$refs.superGrid
3406
3413
  },
3407
3414
  getColumns() {
3408
3415
  return this.columns
3409
3416
  },
3417
+ getTableData() {
3418
+ return this.tableDatas
3419
+ },
3410
3420
  handRowKeyToUpperCase(row) {
3411
3421
  // 把row对象的所有key都转成大写
3412
3422
  if (row) {
@@ -14,12 +14,16 @@
14
14
  v-for="n of getColumnNumPerRow(r, searchableColumns.length)"
15
15
  :key="n"
16
16
  :span="6"
17
- style="margin-bottom: 5px"
17
+ style="margin-bottom: 10px"
18
18
  >
19
19
  <el-form-item
20
20
  :prop="searchableColumns[fieldNum * (r - 1) + (n - 1)].prop"
21
- style="margin-left: 10px"
22
- label-width="100px"
21
+ :label-width="
22
+ searchableColumns[fieldNum * (r - 1) + (n - 1)].label.replace(/\\n/g, '</br>')?.length > 4
23
+ ? '100px'
24
+ : '80px'
25
+ "
26
+ style="width: 90%"
23
27
  >
24
28
  <template v-slot:label>
25
29
  <span
@@ -311,7 +311,7 @@ export default {
311
311
  slotBefore: 'before',
312
312
  titleWidth,
313
313
  slotState: 'bottom',
314
- isShowBottom: true
314
+ isShowBottom: true
315
315
  }
316
316
  },
317
317
  computed: {},
@@ -227,6 +227,23 @@ body .el-table colgroup.gutter {
227
227
  flex-direction: column
228
228
  }
229
229
 
230
+ .amb-chart-container {
231
+ display: flex;
232
+ flex-direction: column;
233
+ height: 100%;
234
+ }
235
+
236
+ .amb-chart-header {
237
+ flex-shrink: 0;
238
+ }
239
+
240
+ .amb-chart-content {
241
+ /* 图表区域占据剩余空间 */
242
+ flex: 1;
243
+ /* 允许内容缩小 */
244
+ min-height: 0;
245
+ }
246
+
230
247
  .amb-widget-chart-header {
231
248
  border-bottom: 1px solid var(--el-card-border-color);
232
249
  padding: 6px 10px;
package/src/utils/util.js CHANGED
@@ -259,15 +259,30 @@ function parseCondition(
259
259
  // 再获取属于那张表
260
260
  const propDbNameArr = propDbName.split('_+_')
261
261
  propDbName = propDbNameArr[1]
262
- leftValue = getValue(parentFormData, propDbName, isSql)
262
+ if (pageContext && propDbName && propDbName.indexOf('${')>=0) {
263
+ leftValue = getPropValueNew(propDbName, pageContext, entity)
264
+ } else {
265
+ leftValue = getValue(parentFormData, propDbName, isSql)
266
+ }
267
+ // leftValue = getValue(parentFormData, propDbName, isSql)
263
268
  } else {
264
- leftValue = getValue(entity, propDbName, isSql)
269
+ if (pageContext && propDbName && propDbName.indexOf('${')>=0) {
270
+ leftValue = getPropValueNew(propDbName, pageContext, entity)
271
+ } else {
272
+ leftValue = getValue(entity, propDbName, isSql)
273
+ }
274
+ // leftValue = getValue(entity, propDbName, isSql)
265
275
  }
266
276
  if (leftValue === undefined || leftValue === null) {
267
277
  if (tableName && propDbName.toLowerCase().startsWith(tableName.toLowerCase() + '.')) {
268
278
  // 表示是当前表的字段
269
279
  const myProp = propDbName.substring(propDbName.indexOf('.'))
270
- leftValue = getValue(entity, myProp, isSql)
280
+ if (pageContext && myProp && myProp.indexOf('${')>=0) {
281
+ leftValue = getPropValueNew(myProp, pageContext, entity)
282
+ } else {
283
+ leftValue = getValue(entity, myProp, isSql)
284
+ }
285
+ // leftValue = getValue(entity, myProp, isSql)
271
286
  }
272
287
  }
273
288
  } else {
@@ -275,12 +290,27 @@ function parseCondition(
275
290
  propName = propName.replace('parent_+_', '')
276
291
  const propNameArr = propName.split('_+_')
277
292
  propName = propNameArr[1]
278
- leftValue = getValue(parentFormData, propName, isSql)
293
+ if (pageContext && propName && propName.indexOf('${')>=0) {
294
+ leftValue = getPropValueNew(propName, pageContext, entity)
295
+ } else {
296
+ leftValue =getValue(parentFormData, propName, isSql)
297
+ }
298
+ // leftValue = getValue(parentFormData, propName, isSql)
279
299
  } else {
280
- leftValue = getValue(entity, propName, isSql)
300
+ if (pageContext && propName && propName.indexOf('${')>=0) {
301
+ leftValue = getPropValueNew(propName, pageContext, entity)
302
+ } else {
303
+ leftValue = getValue(entity, propName, isSql)
304
+ }
305
+ // leftValue = getValue(entity, propName, isSql)
281
306
  }
282
307
  if (propDbName && (leftValue === undefined || leftValue === null)) {
283
- leftValue = getValue(entity, propDbName, isSql)
308
+ if (pageContext && propDbName && propDbName.indexOf('${')>=0) {
309
+ leftValue = getPropValueNew(propDbName, pageContext, entity)
310
+ } else {
311
+ leftValue = getValue(entity, propDbName, isSql)
312
+ }
313
+ // leftValue = getValue(entity, propDbName, isSql)
284
314
  }
285
315
  }
286
316
  const operator = condition.operator
@@ -291,7 +321,7 @@ function parseCondition(
291
321
  // 判断value类型
292
322
  let value
293
323
  if (pageContext) {
294
- value = getPropValueNew(propValue, pageContext)
324
+ value = getPropValueNew(propValue, pageContext, entity)
295
325
  } else {
296
326
  value = getPropValue(propValue, entity, additionalParamMap, contextParameterMap)
297
327
  }
@@ -83,7 +83,7 @@ export default defineComponent({
83
83
  } else {
84
84
  // 有子菜单时
85
85
  vnodes.push(
86
- h('div', { class: ['smb-sidebar-menu-item-title'] }, [
86
+ h('div', { class: titleClass }, [
87
87
  h(
88
88
  'div',
89
89
  {