agilebuilder-ui 1.1.36-tmp4 → 1.1.37

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 (67) hide show
  1. package/lib/{401-c55bdcf2.js → 401-9314ce87.js} +1 -1
  2. package/lib/{404-c1dbd5e1.js → 404-572d631d.js} +1 -1
  3. package/lib/{iframe-page-917912ae.js → iframe-page-87c9c0d0.js} +1 -1
  4. package/lib/{index-6ec53ef7.js → index-79b98485.js} +12729 -12671
  5. package/lib/super-ui.css +1 -1
  6. package/lib/super-ui.js +1 -1
  7. package/lib/super-ui.umd.cjs +99 -99
  8. package/lib/{tab-content-iframe-index-46a76242.js → tab-content-iframe-index-070ce653.js} +1 -1
  9. package/lib/{tab-content-index-132379e6.js → tab-content-index-3b98efb4.js} +1 -1
  10. package/lib/{tache-subprocess-history-384455d6.js → tache-subprocess-history-46442012.js} +1 -1
  11. package/package.json +2 -2
  12. package/packages/department-tree/src/department-tree.vue +130 -123
  13. package/packages/department-tree-inline/src/department-multi-tree-inline.vue +435 -466
  14. package/packages/department-tree-inline/src/department-single-tree-inline.vue +335 -342
  15. package/packages/department-tree-inline/src/department-tree-inline.vue +18 -11
  16. package/packages/department-tree-inline/src/department-tree-service.js +10 -11
  17. package/packages/department-tree-mobile/src/department-tree-app.vue +103 -75
  18. package/packages/department-tree-mobile/src/department-tree-inline-app.vue +256 -225
  19. package/packages/department-tree-mobile/src/department-tree-service.ts +98 -75
  20. package/packages/department-user-tree/src/department-user-multiple-tree.vue +112 -115
  21. package/packages/department-user-tree/src/department-user-single-tree.vue +85 -88
  22. package/packages/department-user-tree/src/department-user-tree.vue +127 -119
  23. package/packages/department-user-tree-inline/src/department-user-multiple-tree-inline.vue +6 -1
  24. package/packages/department-user-tree-inline/src/department-user-single-tree-inline.vue +5 -0
  25. package/packages/department-user-tree-inline/src/department-user-tree-inline.vue +18 -11
  26. package/packages/department-user-tree-inline/src/department-user-tree-multi-service.js +26 -51
  27. package/packages/department-user-tree-inline/src/department-user-tree-single-service.js +25 -45
  28. package/packages/department-user-tree-inline/src/group-user/group-list.vue +97 -90
  29. package/packages/department-user-tree-inline/src/group-user/group-user.vue +28 -32
  30. package/packages/department-user-tree-mobile/src/department-user-tree-app.vue +103 -75
  31. package/packages/department-user-tree-mobile/src/department-user-tree-inline-app.vue +282 -224
  32. package/packages/department-user-tree-mobile/src/department-user-tree-service.ts +58 -51
  33. package/packages/fs-preview/src/fs-preview.vue +20 -2
  34. package/packages/fs-upload-list/src/fs-upload-list.vue +30 -7
  35. package/packages/fs-upload-new/src/file-upload-mobile/file-upload-browser.vue +1 -1
  36. package/packages/fs-upload-new/src/fs-preview-new.vue +27 -15
  37. package/packages/index.js +4 -4
  38. package/packages/organization-input/src/organization-input.vue +34 -12
  39. package/packages/super-grid/src/apis.js +21 -4
  40. package/packages/super-grid/src/dynamic-input.vue +58 -13
  41. package/packages/super-grid/src/normal-column-content.vue +1 -1
  42. package/packages/super-grid/src/row-operation.vue +10 -4
  43. package/packages/super-grid/src/super-grid.vue +51 -42
  44. package/packages/super-grid/src/utils.js +13 -8
  45. package/packages/super-icon/src/index.vue +4 -1
  46. package/packages/workgroup-tree/src/workgroup-tree.vue +117 -110
  47. package/packages/workgroup-tree-inline/src/workgroup-tree-inline.vue +6 -1
  48. package/packages/workgroup-tree-mobile/src/workgroup-tree-app.vue +103 -75
  49. package/packages/workgroup-tree-mobile/src/workgroup-tree-inline-app.vue +229 -208
  50. package/src/api/sso-service.js +6 -5
  51. package/src/directives/permission/index.js +4 -4
  52. package/src/index.js +71 -2
  53. package/src/store/modules/table.js +0 -1
  54. package/src/styles/theme/dark-blue/sidebar.scss +9 -0
  55. package/src/styles/theme/gray/sidebar.scss +9 -8
  56. package/src/styles/theme/green/sidebar.scss +10 -0
  57. package/src/styles/theme/ocean-blue/sidebar.scss +9 -0
  58. package/src/styles/theme/tiffany-blue-mobile/sidebar.scss +9 -0
  59. package/src/utils/insert_css.js +1 -1
  60. package/src/utils/util.js +19 -0
  61. package/src/views/dsc-component/Sidebar/SidebarItem.vue +2 -2
  62. package/src/views/dsc-component/Sidebar/index.vue +36 -18
  63. package/src/views/layout/components/Menubar/Item.vue +0 -9
  64. package/src/views/layout/components/Menubar/SidebarItem.vue +2 -2
  65. package/src/views/layout/components/Sidebar/Item.vue +4 -1
  66. package/src/views/layout/components/Sidebar/SidebarItem.vue +2 -2
  67. package/vite.config.js +1 -1
package/src/index.js CHANGED
@@ -1,14 +1,51 @@
1
+ // 依次导入组件库的各个组件
2
+ // import Breadcrumb from '../packages/breadcrumb'
3
+ // import DepartmentTree from '../packages/department-tree'
4
+ // import Hamburger from '../packages/hamburger'
5
+ // import SvgIcon from '../packages/svg-icon'
6
+ // import SuperGrid from '../packages/super-grid'
7
+ // import DepartmentUserTree from '../packages/department-user-tree'
8
+ // import WorkgroupTree from '../packages/workgroup-tree'
9
+ // import WorkgroupUserTree from '../packages/workgroup-user-tree'
10
+ // import InlineDepartmentTree from '../packages/department-tree-inline'
11
+ // import InlineDepartmentUserTree from '../packages/department-user-tree-inline'
12
+ // import InlineWorkgroupTree from '../packages/workgroup-tree-inline'
13
+ // import InlineWorkgroupUserTree from '../packages/workgroup-user-tree-inline'
14
+ // import WorkflowButton from '../packages/workflow-button'
15
+ // import WorkflowHistoryList from '../packages/workflow-history-list'
1
16
  import PreventReclick from '../packages/directives/prevent-reclick'
17
+ // import exportPlugin from '../packages/export-data/index'
18
+ // import ValidCode from '../packages/valid-code'
2
19
  import customPlugin from '../packages/plugins/index'
20
+ // import RemoveUser from '../packages/remove-user'
21
+ // import RemoveDepartment from '../packages/remove-department'
22
+ // import RemoveWorkgroup from '../packages/remove-workgroup'
23
+ // import OrganizationInput from '../packages/organization-input'
24
+ // import SuperNineGrid from '../packages/super-nine-grid'
25
+ // import DynamicSourceSelect from '../packages/dynamic-source-select'
26
+ // import FsUpload from '../packages/fs-upload'
27
+ // import ScanCodeInput from '../packages/scan-code-input'
28
+ // import FsPreview from '../packages/fs-preview'
29
+ // import FsUploadList from '../packages/fs-upload-list'
3
30
  import { openPage } from './utils/jump-page-utils'
31
+ // import YearRangePicker from '../packages/year-range-picker'
32
+ // import MultipartUpload from '../packages/multipart-upload'
33
+ // import RichEditor from '../packages/rich-editor'
34
+ // import SecretInfo from '../packages/secret-info'
35
+ import plugins from '../packages/plugins/index'
4
36
  import permission from './directives/permission'
5
37
 
6
38
  // 定义 install 方法,接收 Vue 作为参数。如果使用 use 注册插件,则所有的组件都将被注册
7
39
  const install = function (Vue) {
8
- Vue.directive('prevent-reclick', PreventReclick)
40
+ window.$vueApp.directive('prevent-reclick', PreventReclick)
9
41
  permission.install(Vue)
10
- Vue.use(customPlugin)
42
+ window.$vueApp.use(customPlugin)
43
+ window.$vueApp.use(plugins)
11
44
  if (install.installed) return
45
+ // components.map(component => Vue.component(component.name, component))
46
+ // components.forEach(component => {
47
+ // Vue.component(component.name, component)
48
+ // })
12
49
  // 将弹出页面方法注册到window对象上
13
50
  window['$plateform_openPage'] = openPage
14
51
  }
@@ -17,6 +54,38 @@ const install = function (Vue) {
17
54
  if (typeof window !== 'undefined' && window.Vue) {
18
55
  install(window.Vue)
19
56
  }
57
+ // 按需引入
58
+ // export {
59
+ // Breadcrumb,
60
+ // DepartmentTree,
61
+ // Hamburger,
62
+ // SvgIcon,
63
+ // SuperGrid,
64
+ // DepartmentUserTree,
65
+ // WorkgroupTree,
66
+ // WorkgroupUserTree,
67
+ // InlineDepartmentTree,
68
+ // InlineDepartmentUserTree,
69
+ // InlineWorkgroupTree,
70
+ // InlineWorkgroupUserTree,
71
+ // WorkflowButton,
72
+ // WorkflowHistoryList,
73
+ // ValidCode,
74
+ // RemoveUser,
75
+ // RemoveDepartment,
76
+ // RemoveWorkgroup,
77
+ // OrganizationInput,
78
+ // SuperNineGrid,
79
+ // DynamicSourceSelect,
80
+ // FsUpload,
81
+ // ScanCodeInput,
82
+ // FsPreview,
83
+ // FsUploadList,
84
+ // YearRangePicker,
85
+ // MultipartUpload,
86
+ // RichEditor,
87
+ // SecretInfo
88
+ // }
20
89
 
21
90
  export default {
22
91
  // 导出的对象必须具有 install,才能被 Vue.use() 方法安装
@@ -68,7 +68,6 @@ const app = {
68
68
  * @param {Object} context - 上下文对象
69
69
  */
70
70
  clearAllEditing({ commit }) {
71
- debugger
72
71
  commit('clearAllEditing');
73
72
  }
74
73
  },
@@ -220,6 +220,15 @@
220
220
  }
221
221
  }
222
222
 
223
+ // 注释的原因:会导致孙子菜单显示的位置不正确
224
+ // .sidebar-container-popper .el-menu{
225
+ // // height: 100vh;
226
+ // height: auto;
227
+ // max-height: 100vh;
228
+ // overflow-y: auto;
229
+ // overflow-x: hidden;
230
+ // scroll-behavior: smooth;
231
+ // }
223
232
  .sidebar-container-popper .el-submenu__title:not(.is-disabled):hover {
224
233
  background: #F7F7F8;
225
234
  color: rgba(0, 13, 31, 0.85);
@@ -189,14 +189,15 @@
189
189
  }
190
190
  }
191
191
 
192
- .sidebar-container-popper .el-menu{
193
- // height: 100vh;
194
- height: auto;
195
- max-height: 100vh;
196
- overflow-y: auto;
197
- overflow-x: hidden;
198
- scroll-behavior: smooth;
199
- }
192
+ // 注释的原因:会导致孙子菜单显示的位置不正确
193
+ // .sidebar-container-popper .el-menu{
194
+ // // height: 100vh;
195
+ // height: auto;
196
+ // max-height: 100vh;
197
+ // overflow-y: auto;
198
+ // overflow-x: hidden;
199
+ // scroll-behavior: smooth;
200
+ // }
200
201
 
201
202
  .sidebar-container-popper .el-submenu__title:not(.is-disabled):hover {
202
203
  background: #F7F7F8;
@@ -223,6 +223,16 @@
223
223
  }
224
224
  }
225
225
 
226
+ // 注释的原因:会导致孙子菜单显示的位置不正确
227
+ // .sidebar-container-popper .el-menu{
228
+ // // height: 100vh;
229
+ // height: auto;
230
+ // max-height: 100vh;
231
+ // overflow-y: auto;
232
+ // overflow-x: hidden;
233
+ // scroll-behavior: smooth;
234
+ // }
235
+
226
236
  .sidebar-container-popper .el-submenu__title:not(.is-disabled):hover {
227
237
  background: #F7F7F8;
228
238
  color: rgba(0, 13, 31, 0.85);
@@ -217,6 +217,15 @@
217
217
  }
218
218
  }
219
219
 
220
+ // 注释的原因:会导致孙子菜单显示的位置不正确
221
+ // .sidebar-container-popper .el-menu{
222
+ // // height: 100vh;
223
+ // height: auto;
224
+ // max-height: 100vh;
225
+ // overflow-y: auto;
226
+ // overflow-x: hidden;
227
+ // scroll-behavior: smooth;
228
+ // }
220
229
  .sidebar-container-popper .el-submenu__title:not(.is-disabled):hover {
221
230
  background: #F7F7F8;
222
231
  color: rgba(0, 13, 31, 0.85);
@@ -219,6 +219,15 @@
219
219
  }
220
220
  }
221
221
 
222
+ // 注释的原因:会导致孙子菜单显示的位置不正确
223
+ // .sidebar-container-popper .el-menu{
224
+ // // height: 100vh;
225
+ // height: auto;
226
+ // max-height: 100vh;
227
+ // overflow-y: auto;
228
+ // overflow-x: hidden;
229
+ // scroll-behavior: smooth;
230
+ // }
222
231
  .sidebar-container-popper .el-submenu__title:not(.is-disabled):hover {
223
232
  background: #F7F7F8;
224
233
  color: rgba(0, 13, 31, 0.85);
@@ -18,7 +18,7 @@ if (!window.insertCssFile) {
18
18
  const timestamp = new Date().getTime();
19
19
  const link = document.createElement('link');
20
20
  link.rel = 'stylesheet';
21
- link.href = cssUrl + `?_v=${timestamp}`;
21
+ link.href = cssUrl;
22
22
  link.onload = function () {
23
23
  window.insertedCssFiles.add(cssUrl);
24
24
  };
package/src/utils/util.js CHANGED
@@ -624,6 +624,7 @@ export function getPropValueNew(propValue, pageContext, row) {
624
624
  let value = null
625
625
  if (propValue && propValue !== null && propValue !== '') {
626
626
  const entity = pageContext && pageContext.entity ? pageContext.entity.data : null
627
+ const pageVar = pageContext && pageContext.entity ? pageContext.entity.page : null
627
628
  const additionalParamMap = getAdditionalParamMap(pageContext)
628
629
  const contextParameterMap = pageContext && pageContext.entity ? pageContext.entity.context : null
629
630
  const parentEntity =
@@ -643,6 +644,9 @@ export function getPropValueNew(propValue, pageContext, row) {
643
644
  const propName = propValue.replace('${row.', '').replace('}', '')
644
645
  value = getEntityFieldValue(row, propName)
645
646
  }
647
+ } else if (propValue.indexOf('${page.') === 0) {
648
+ const variable = propValue.replace('${page.', '').replace('}', '')
649
+ value = pageVar ? pageVar[variable] : null
646
650
  } else if (
647
651
  propValue.includes('${context.') ||
648
652
  propValue.includes('${request.') ||
@@ -930,3 +934,18 @@ export function isImage(fileName) {
930
934
  return false
931
935
  }
932
936
  }
937
+
938
+ export function watchPageContextDynamicVariable(that, pageContext, variable, callback) {
939
+ const match = variable.match(/\${(.*?)}/)
940
+ if (!match) return
941
+ const path = match ? match[1].split('.') : []
942
+ if (path && path.length > 0) {
943
+ // 监听 pageContext.entity[type][field][xxx]... 的变化
944
+ that.$watch(
945
+ () => path.reduce((obj, key) => obj[key], pageContext.entity),
946
+ (newVal, oldVal) => {
947
+ callback(newVal, oldVal)
948
+ }
949
+ )
950
+ }
951
+ }
@@ -192,8 +192,8 @@ export default {
192
192
  <style lang="scss" scoped>
193
193
  .smb-sidebar-menu-item {
194
194
  position: relative;
195
- --el-menu-item-height: 36px;
196
- --el-menu-sub-item-height: 36px;
195
+ --el-menu-item-height: 45px;
196
+ --el-menu-sub-item-height: 45px;
197
197
  &.el-menu-item, &.el-sub-menu {
198
198
  padding: 0 !important;
199
199
  &:not(:has(> .el-tooltip__trigger)) {
@@ -46,8 +46,10 @@ export default {
46
46
  },
47
47
  data() {
48
48
  const menus = getMenus()
49
+ const isSelectFirst = window.$vueApp.config.globalProperties.showFirstMenu === undefined || window.$vueApp.config.globalProperties.showFirstMenu === null? true : window.$vueApp.config.globalProperties.showFirstMenu
49
50
  return {
50
51
  menus: Object.freeze(menus),
52
+ isSelectFirst
51
53
  }
52
54
  },
53
55
  computed: {
@@ -138,38 +140,54 @@ export default {
138
140
  const b = new Date().getTime()
139
141
  console.log('菜单组件==>getMyFirstMenu==>b-a', b - a)
140
142
  // 默认不展示第一个有权限的菜单了,可以去掉下面的代码
141
- // if (!shouldSelectMenu) {
142
- // shouldSelectMenu = this.getSelectMenuWithFirstMenu(menus[0])
143
- // }
143
+ if (!shouldSelectMenu) {
144
+ shouldSelectMenu = this.getSelectMenuWithFirstMenu(menus[0])
145
+ }
144
146
  return shouldSelectMenu
145
147
  }
146
148
  },
147
149
  getFirstMenu(menus) {
148
- if (menus && menus.length > 0) {
149
- let shouldSelectMenu
150
+ const currentMenuCode = this.$route.query
151
+ ? this.$route.query._menuCode
152
+ : null
153
+ let shouldSelectMenu
154
+ if(currentMenuCode){
155
+ // 表示需要选中指定的菜单
156
+ this.isSelectFirst = true
157
+ } else {
158
+ shouldSelectMenu = this.getFirstMenuWithCookie(menus)
159
+ }
160
+ console.log('getFirstMenu=====shouldSelectMenu111=', shouldSelectMenu)
161
+ if (this.isSelectFirst && !shouldSelectMenu && menus && menus.length > 0) {
150
162
  for (let i = 0; i < menus.length; i++) {
151
163
  const menu = menus[i]
152
- shouldSelectMenu = this.getShouldSelectMenu(menu)
164
+ shouldSelectMenu = this.getShouldSelectMenu(menu, currentMenuCode)
153
165
  if (shouldSelectMenu) {
154
166
  // 表示获得到了应该选中的菜单
155
167
  break
156
168
  }
157
169
  }
158
- return shouldSelectMenu
159
170
  }
171
+ console.log('getFirstMenu=====shouldSelectMenu222=', shouldSelectMenu)
172
+ return shouldSelectMenu
160
173
  },
161
- getShouldSelectMenu(menu) {
162
- // console.log('dsc--getShouldSelectMenu--this.$route=', this.$route)
163
- const currentMenuCode = this.$route.query
164
- ? this.$route.query._menuCode
165
- : null
166
- if (menu && currentMenuCode) {
174
+ getShouldSelectMenu(menu, currentMenuCode) {
175
+ if (menu) {
167
176
  let shouldSelectMenu
168
- const children = menu.children
169
- if (children && children.length > 0) {
170
- shouldSelectMenu = this.getFirstMenu(children)
171
- } else if (menu.code && menu.code === currentMenuCode) {
172
- shouldSelectMenu = menu
177
+ if(currentMenuCode){
178
+ const children = menu.children
179
+ if (children && children.length > 0) {
180
+ shouldSelectMenu = this.getFirstMenu(children)
181
+ } else if (menu.code && menu.code === currentMenuCode) {
182
+ shouldSelectMenu = menu
183
+ }
184
+ } else {
185
+ const children = menu.children
186
+ if (children && children.length > 0) {
187
+ shouldSelectMenu = this.getFirstMenu(children)
188
+ } else {
189
+ shouldSelectMenu = menu
190
+ }
173
191
  }
174
192
  return shouldSelectMenu
175
193
  }
@@ -40,15 +40,6 @@ export default defineComponent({
40
40
  let iconsData = [h('i', { class: 'amb-iconfont amb-icon-meun_post' })]
41
41
  if (icon) {
42
42
  iconsData = [h(SuperIcon, { iconValue: icon })]
43
- // if (icon.indexOf('amb-icon') === 0) {
44
- // iconsData = [h('i',{class: 'amb-iconfont ' + icon})]
45
- // } else if (icon.indexOf('fa-') === 0) {
46
- // iconsData = [h('i',{class: 'fa ' + icon})]
47
- // } else if (icon.indexOf('svg-') === 0) {
48
- // iconsData = [h(SvgIcon,{'icon-class': icon.substring(icon.indexOf('svg-') + 4)})]
49
- // } else {
50
- // iconsData = [h('i',{class: icon + ' svg-icon'})]
51
- // }
52
43
  }
53
44
  vnodes.push(h('div', { class: ['smb-sidebar-menu-item-icon'] }, iconsData))
54
45
  if (title) {
@@ -254,8 +254,8 @@ export default {
254
254
  <style lang="scss" scoped>
255
255
  .smb-sidebar-menu-item {
256
256
  position: relative;
257
- --el-menu-item-height: 36px;
258
- --el-menu-sub-item-height: 36px;
257
+ --el-menu-item-height: 45px;
258
+ --el-menu-sub-item-height: 45px;
259
259
  &.el-menu-item, &.el-sub-menu {
260
260
  padding: 0 !important;
261
261
  &:not(:has(> .el-tooltip__trigger)) {
@@ -9,7 +9,10 @@ export default function render(_props, _context) {
9
9
  }
10
10
  const { icon, title, hasChildren } = context.props
11
11
  const vnodes = []
12
- let iconsData = <svg-icon icon-class={ icon || 'meun_post'} />
12
+ let iconsData = [h('i', { class: 'amb-iconfont amb-icon-meun_post' })]
13
+ if (icon) {
14
+ iconsData = [h(SuperIcon, { iconValue: icon })]
15
+ }
13
16
 
14
17
  vnodes.push(<div class="smb-sidebar-menu-item-icon">{ iconsData }</div>)
15
18
 
@@ -140,8 +140,8 @@ export default {
140
140
  <style lang="scss" scoped>
141
141
  .smb-sidebar-menu-item {
142
142
  position: relative;
143
- --el-menu-item-height: 36px;
144
- --el-menu-sub-item-height: 36px;
143
+ --el-menu-item-height: 45px;
144
+ --el-menu-sub-item-height: 45px;
145
145
  &.el-menu-item, &.el-sub-menu {
146
146
  padding: 0 !important;
147
147
  &:not(:has(> .el-tooltip__trigger)) {
package/vite.config.js CHANGED
@@ -30,7 +30,7 @@ export default defineConfig(({ mode }) => ({
30
30
  }, //库编译模式配置
31
31
  rollupOptions: {
32
32
  // 确保外部化处理那些你不想打包进库的依赖
33
- external: ["vue"],
33
+ external: ["vue", "jsx"],
34
34
  output: {
35
35
  // 在 UMD 构建模式下为这些外部化的依赖提供一个全局变量
36
36
  globals: {