agilebuilder-ui 1.0.0

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 (392) hide show
  1. package/README.md +7 -0
  2. package/index.html +13 -0
  3. package/package.json +36 -0
  4. package/packages/IntervalSelection/index.js +6 -0
  5. package/packages/IntervalSelection/src/quarterScope.vue +405 -0
  6. package/packages/IntervalSelection/src/sectionDate.vue +475 -0
  7. package/packages/breadcrumb/index.js +6 -0
  8. package/packages/breadcrumb/src/breadcrumb.vue +81 -0
  9. package/packages/department-tree/index.js +6 -0
  10. package/packages/department-tree/src/department-tree.vue +114 -0
  11. package/packages/department-tree-inline/index.js +6 -0
  12. package/packages/department-tree-inline/src/department-multi-tree-inline.vue +494 -0
  13. package/packages/department-tree-inline/src/department-single-tree-inline.vue +367 -0
  14. package/packages/department-tree-inline/src/department-tree-inline.vue +86 -0
  15. package/packages/department-tree-inline/src/department-tree-service.js +344 -0
  16. package/packages/department-tree-inline/src/search-result.vue +238 -0
  17. package/packages/department-user-tree/index.js +6 -0
  18. package/packages/department-user-tree/src/department-user-multiple-tree.vue +133 -0
  19. package/packages/department-user-tree/src/department-user-single-tree.vue +96 -0
  20. package/packages/department-user-tree/src/department-user-tree.vue +115 -0
  21. package/packages/department-user-tree-inline/index.js +9 -0
  22. package/packages/department-user-tree-inline/src/department-user-multiple-tree-inline.vue +758 -0
  23. package/packages/department-user-tree-inline/src/department-user-single-tree-inline.vue +358 -0
  24. package/packages/department-user-tree-inline/src/department-user-tree-inline.vue +87 -0
  25. package/packages/department-user-tree-inline/src/department-user-tree-multi-service.js +309 -0
  26. package/packages/department-user-tree-inline/src/department-user-tree-single-service.js +180 -0
  27. package/packages/department-user-tree-inline/src/search-result.vue +286 -0
  28. package/packages/directives/prevent-reclick.js +22 -0
  29. package/packages/dynamic-source-select/index.js +6 -0
  30. package/packages/dynamic-source-select/src/dynamic-source-select-service.js +124 -0
  31. package/packages/dynamic-source-select/src/dynamic-source-select.vue +857 -0
  32. package/packages/dynamic-source-select/src/events.js +77 -0
  33. package/packages/fs-preview/index.js +6 -0
  34. package/packages/fs-preview/src/fs-preview.vue +303 -0
  35. package/packages/fs-upload/index.js +6 -0
  36. package/packages/fs-upload/src/fs-upload-multi.vue +458 -0
  37. package/packages/fs-upload/src/fs-upload-single.vue +365 -0
  38. package/packages/fs-upload/src/fs-upload.vue +191 -0
  39. package/packages/fs-upload/src/see-big-picture.vue +67 -0
  40. package/packages/fs-upload-list/index.js +6 -0
  41. package/packages/fs-upload-list/src/fs-upload-list.vue +387 -0
  42. package/packages/hamburger/index.js +6 -0
  43. package/packages/hamburger/src/hamburger.vue +50 -0
  44. package/packages/index.js +124 -0
  45. package/packages/multipart-upload/index.js +6 -0
  46. package/packages/multipart-upload/src/index.vue +66 -0
  47. package/packages/multipart-upload/src/multipart-upload-form.vue +395 -0
  48. package/packages/multipart-upload/src/multipart-upload-list.vue +539 -0
  49. package/packages/organization-input/index.js +6 -0
  50. package/packages/organization-input/src/organization-input.vue +579 -0
  51. package/packages/plugins/export-data-new.js +630 -0
  52. package/packages/plugins/export-data.js +431 -0
  53. package/packages/plugins/index.js +15 -0
  54. package/packages/plugins/public-method.js +47 -0
  55. package/packages/remove-department/index.js +6 -0
  56. package/packages/remove-department/src/remove-department.vue +201 -0
  57. package/packages/remove-department/src/remove-dept-service.js +31 -0
  58. package/packages/remove-user/index.js +6 -0
  59. package/packages/remove-user/src/remove-user-service.js +31 -0
  60. package/packages/remove-user/src/remove-user.vue +227 -0
  61. package/packages/remove-workgroup/index.js +6 -0
  62. package/packages/remove-workgroup/src/remove-workgroup-service.js +31 -0
  63. package/packages/remove-workgroup/src/remove-workgroup.vue +184 -0
  64. package/packages/rich-editor/index.js +7 -0
  65. package/packages/rich-editor/index.vue +314 -0
  66. package/packages/rich-editor/tinymce/icons/default/icons.min.js +1 -0
  67. package/packages/rich-editor/tinymce/langs/README.md +3 -0
  68. package/packages/rich-editor/tinymce/langs/zh-Hans.js +1 -0
  69. package/packages/rich-editor/tinymce/license.txt +21 -0
  70. package/packages/rich-editor/tinymce/models/dom/model.min.js +4 -0
  71. package/packages/rich-editor/tinymce/plugins/accordion/plugin.min.js +4 -0
  72. package/packages/rich-editor/tinymce/plugins/advlist/plugin.min.js +4 -0
  73. package/packages/rich-editor/tinymce/plugins/anchor/plugin.min.js +4 -0
  74. package/packages/rich-editor/tinymce/plugins/autolink/plugin.min.js +4 -0
  75. package/packages/rich-editor/tinymce/plugins/autoresize/plugin.min.js +4 -0
  76. package/packages/rich-editor/tinymce/plugins/autosave/plugin.min.js +4 -0
  77. package/packages/rich-editor/tinymce/plugins/charmap/plugin.min.js +4 -0
  78. package/packages/rich-editor/tinymce/plugins/code/plugin.min.js +4 -0
  79. package/packages/rich-editor/tinymce/plugins/codesample/plugin.min.js +4 -0
  80. package/packages/rich-editor/tinymce/plugins/directionality/plugin.min.js +4 -0
  81. package/packages/rich-editor/tinymce/plugins/emoticons/js/emojiimages.js +1 -0
  82. package/packages/rich-editor/tinymce/plugins/emoticons/js/emojiimages.min.js +3 -0
  83. package/packages/rich-editor/tinymce/plugins/emoticons/js/emojis.js +1 -0
  84. package/packages/rich-editor/tinymce/plugins/emoticons/js/emojis.min.js +2 -0
  85. package/packages/rich-editor/tinymce/plugins/emoticons/plugin.min.js +4 -0
  86. package/packages/rich-editor/tinymce/plugins/fullscreen/plugin.min.js +4 -0
  87. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/ar.js +90 -0
  88. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/bg_BG.js +90 -0
  89. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/ca.js +90 -0
  90. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/cs.js +90 -0
  91. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/da.js +90 -0
  92. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/de.js +90 -0
  93. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/el.js +90 -0
  94. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/en.js +90 -0
  95. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/es.js +90 -0
  96. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/eu.js +90 -0
  97. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/fa.js +90 -0
  98. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/fi.js +90 -0
  99. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/fr_FR.js +90 -0
  100. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/he_IL.js +90 -0
  101. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/hi.js +90 -0
  102. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/hr.js +90 -0
  103. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/hu_HU.js +90 -0
  104. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/id.js +90 -0
  105. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/it.js +90 -0
  106. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/ja.js +90 -0
  107. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/kk.js +90 -0
  108. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/ko_KR.js +90 -0
  109. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/ms.js +90 -0
  110. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/nb_NO.js +90 -0
  111. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/nl.js +90 -0
  112. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/pl.js +90 -0
  113. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/pt_BR.js +90 -0
  114. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/pt_PT.js +90 -0
  115. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/ro.js +90 -0
  116. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/ru.js +90 -0
  117. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/sk.js +90 -0
  118. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/sl_SI.js +90 -0
  119. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/sv_SE.js +90 -0
  120. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/th_TH.js +90 -0
  121. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/tr.js +90 -0
  122. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/uk.js +90 -0
  123. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/vi.js +90 -0
  124. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/zh_CN.js +84 -0
  125. package/packages/rich-editor/tinymce/plugins/help/js/i18n/keynav/zh_TW.js +90 -0
  126. package/packages/rich-editor/tinymce/plugins/help/plugin.min.js +4 -0
  127. package/packages/rich-editor/tinymce/plugins/image/plugin.min.js +4 -0
  128. package/packages/rich-editor/tinymce/plugins/importcss/plugin.min.js +4 -0
  129. package/packages/rich-editor/tinymce/plugins/insertdatetime/plugin.min.js +4 -0
  130. package/packages/rich-editor/tinymce/plugins/link/plugin.min.js +4 -0
  131. package/packages/rich-editor/tinymce/plugins/lists/plugin.min.js +4 -0
  132. package/packages/rich-editor/tinymce/plugins/media/plugin.min.js +4 -0
  133. package/packages/rich-editor/tinymce/plugins/nonbreaking/plugin.min.js +4 -0
  134. package/packages/rich-editor/tinymce/plugins/pagebreak/plugin.min.js +4 -0
  135. package/packages/rich-editor/tinymce/plugins/preview/plugin.min.js +4 -0
  136. package/packages/rich-editor/tinymce/plugins/quickbars/plugin.min.js +4 -0
  137. package/packages/rich-editor/tinymce/plugins/save/plugin.min.js +4 -0
  138. package/packages/rich-editor/tinymce/plugins/searchreplace/plugin.min.js +4 -0
  139. package/packages/rich-editor/tinymce/plugins/table/plugin.min.js +4 -0
  140. package/packages/rich-editor/tinymce/plugins/template/plugin.min.js +4 -0
  141. package/packages/rich-editor/tinymce/plugins/visualblocks/plugin.min.js +4 -0
  142. package/packages/rich-editor/tinymce/plugins/visualchars/plugin.min.js +4 -0
  143. package/packages/rich-editor/tinymce/plugins/wordcount/plugin.min.js +4 -0
  144. package/packages/rich-editor/tinymce/skins/content/dark/content.js +2 -0
  145. package/packages/rich-editor/tinymce/skins/content/dark/content.min.css +1 -0
  146. package/packages/rich-editor/tinymce/skins/content/default/content.js +2 -0
  147. package/packages/rich-editor/tinymce/skins/content/default/content.min.css +1 -0
  148. package/packages/rich-editor/tinymce/skins/content/document/content.js +2 -0
  149. package/packages/rich-editor/tinymce/skins/content/document/content.min.css +1 -0
  150. package/packages/rich-editor/tinymce/skins/content/tinymce-5/content.js +2 -0
  151. package/packages/rich-editor/tinymce/skins/content/tinymce-5/content.min.css +1 -0
  152. package/packages/rich-editor/tinymce/skins/content/tinymce-5-dark/content.js +2 -0
  153. package/packages/rich-editor/tinymce/skins/content/tinymce-5-dark/content.min.css +1 -0
  154. package/packages/rich-editor/tinymce/skins/content/writer/content.js +2 -0
  155. package/packages/rich-editor/tinymce/skins/content/writer/content.min.css +1 -0
  156. package/packages/rich-editor/tinymce/skins/ui/oxide/content.inline.js +2 -0
  157. package/packages/rich-editor/tinymce/skins/ui/oxide/content.inline.min.css +1 -0
  158. package/packages/rich-editor/tinymce/skins/ui/oxide/content.js +2 -0
  159. package/packages/rich-editor/tinymce/skins/ui/oxide/content.min.css +1 -0
  160. package/packages/rich-editor/tinymce/skins/ui/oxide/skin.js +2 -0
  161. package/packages/rich-editor/tinymce/skins/ui/oxide/skin.min.css +1 -0
  162. package/packages/rich-editor/tinymce/skins/ui/oxide/skin.shadowdom.js +2 -0
  163. package/packages/rich-editor/tinymce/skins/ui/oxide/skin.shadowdom.min.css +1 -0
  164. package/packages/rich-editor/tinymce/skins/ui/oxide-dark/content.inline.js +2 -0
  165. package/packages/rich-editor/tinymce/skins/ui/oxide-dark/content.inline.min.css +1 -0
  166. package/packages/rich-editor/tinymce/skins/ui/oxide-dark/content.js +2 -0
  167. package/packages/rich-editor/tinymce/skins/ui/oxide-dark/content.min.css +1 -0
  168. package/packages/rich-editor/tinymce/skins/ui/oxide-dark/skin.js +2 -0
  169. package/packages/rich-editor/tinymce/skins/ui/oxide-dark/skin.min.css +1 -0
  170. package/packages/rich-editor/tinymce/skins/ui/oxide-dark/skin.shadowdom.js +2 -0
  171. package/packages/rich-editor/tinymce/skins/ui/oxide-dark/skin.shadowdom.min.css +1 -0
  172. package/packages/rich-editor/tinymce/skins/ui/tinymce-5/content.inline.js +2 -0
  173. package/packages/rich-editor/tinymce/skins/ui/tinymce-5/content.inline.min.css +1 -0
  174. package/packages/rich-editor/tinymce/skins/ui/tinymce-5/content.js +2 -0
  175. package/packages/rich-editor/tinymce/skins/ui/tinymce-5/content.min.css +1 -0
  176. package/packages/rich-editor/tinymce/skins/ui/tinymce-5/skin.js +2 -0
  177. package/packages/rich-editor/tinymce/skins/ui/tinymce-5/skin.min.css +1 -0
  178. package/packages/rich-editor/tinymce/skins/ui/tinymce-5/skin.shadowdom.js +2 -0
  179. package/packages/rich-editor/tinymce/skins/ui/tinymce-5/skin.shadowdom.min.css +1 -0
  180. package/packages/rich-editor/tinymce/skins/ui/tinymce-5-dark/content.inline.js +2 -0
  181. package/packages/rich-editor/tinymce/skins/ui/tinymce-5-dark/content.inline.min.css +1 -0
  182. package/packages/rich-editor/tinymce/skins/ui/tinymce-5-dark/content.js +2 -0
  183. package/packages/rich-editor/tinymce/skins/ui/tinymce-5-dark/content.min.css +1 -0
  184. package/packages/rich-editor/tinymce/skins/ui/tinymce-5-dark/skin.js +2 -0
  185. package/packages/rich-editor/tinymce/skins/ui/tinymce-5-dark/skin.min.css +1 -0
  186. package/packages/rich-editor/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.js +2 -0
  187. package/packages/rich-editor/tinymce/skins/ui/tinymce-5-dark/skin.shadowdom.min.css +1 -0
  188. package/packages/rich-editor/tinymce/themes/silver/theme.min.js +4 -0
  189. package/packages/rich-editor/tinymce/tinymce.d.ts +3238 -0
  190. package/packages/rich-editor/tinymce/tinymce.min.js +4 -0
  191. package/packages/rich-editor/tinymce/zh_CN.js +418 -0
  192. package/packages/rich-editor/viewer.vue +105 -0
  193. package/packages/scan-code-input/index.js +6 -0
  194. package/packages/scan-code-input/src/events.js +34 -0
  195. package/packages/scan-code-input/src/scan-code-input-colse.vue +140 -0
  196. package/packages/scan-code-input/src/scan-code-input.vue +132 -0
  197. package/packages/secret-info/index.js +7 -0
  198. package/packages/secret-info/index.vue +100 -0
  199. package/packages/super-grid/index.js +7 -0
  200. package/packages/super-grid/src/apis.js +1193 -0
  201. package/packages/super-grid/src/columns-config.vue +429 -0
  202. package/packages/super-grid/src/components/grid-icon.vue +162 -0
  203. package/packages/super-grid/src/components/hyperlinks.vue +114 -0
  204. package/packages/super-grid/src/custom-formatter.js +430 -0
  205. package/packages/super-grid/src/dynamic-input.vue +1473 -0
  206. package/packages/super-grid/src/eventBus.js +10 -0
  207. package/packages/super-grid/src/events.js +56 -0
  208. package/packages/super-grid/src/formValidatorUtil.js +300 -0
  209. package/packages/super-grid/src/formatter.js +196 -0
  210. package/packages/super-grid/src/group-column.vue +99 -0
  211. package/packages/super-grid/src/header-context-menu.vue +82 -0
  212. package/packages/super-grid/src/index-column.vue +69 -0
  213. package/packages/super-grid/src/normal-column.vue +1239 -0
  214. package/packages/super-grid/src/public-methods.js +30 -0
  215. package/packages/super-grid/src/row-operation.vue +193 -0
  216. package/packages/super-grid/src/search-button.vue +79 -0
  217. package/packages/super-grid/src/search-condition-input.vue +74 -0
  218. package/packages/super-grid/src/search-condition-list.vue +70 -0
  219. package/packages/super-grid/src/search-form-advancedQuery.vue +833 -0
  220. package/packages/super-grid/src/search-form-dialog.vue +77 -0
  221. package/packages/super-grid/src/search-form-item.vue +496 -0
  222. package/packages/super-grid/src/search-form-number.vue +111 -0
  223. package/packages/super-grid/src/search-form-open.vue +178 -0
  224. package/packages/super-grid/src/search-form-ordinarySearch.vue +248 -0
  225. package/packages/super-grid/src/search-form.vue +767 -0
  226. package/packages/super-grid/src/search-methods.js +591 -0
  227. package/packages/super-grid/src/selection-column.vue +46 -0
  228. package/packages/super-grid/src/store.js +3 -0
  229. package/packages/super-grid/src/super-grid-service.js +729 -0
  230. package/packages/super-grid/src/super-grid.vue +3025 -0
  231. package/packages/super-grid/src/utils.js +880 -0
  232. package/packages/super-grid/src/view-image-dialog.vue +190 -0
  233. package/packages/super-nine-grid/index.js +7 -0
  234. package/packages/super-nine-grid/src/apis.js +108 -0
  235. package/packages/super-nine-grid/src/custom-formatter.js +73 -0
  236. package/packages/super-nine-grid/src/formatter.js +134 -0
  237. package/packages/super-nine-grid/src/search-form-number.vue +35 -0
  238. package/packages/super-nine-grid/src/search-form.vue +704 -0
  239. package/packages/super-nine-grid/src/search-methods.js +151 -0
  240. package/packages/super-nine-grid/src/store.js +3 -0
  241. package/packages/super-nine-grid/src/super-grid-service.js +108 -0
  242. package/packages/super-nine-grid/src/super-nine-grid.vue +1211 -0
  243. package/packages/super-nine-grid/src/utils.js +264 -0
  244. package/packages/svg-icon/index.js +6 -0
  245. package/packages/svg-icon/src/svg-icon.vue +43 -0
  246. package/packages/utils/date-util.js +292 -0
  247. package/packages/utils/dom.js +227 -0
  248. package/packages/utils/gogocodeTransfer.js +59 -0
  249. package/packages/utils/memory-cache-utils.js +117 -0
  250. package/packages/utils/utils.js +180 -0
  251. package/packages/utils/value-set.js +97 -0
  252. package/packages/valid-code/index.js +7 -0
  253. package/packages/valid-code/src/valid-code.vue +104 -0
  254. package/packages/workflow-button/index.js +6 -0
  255. package/packages/workflow-button/src/workflow-button.vue +569 -0
  256. package/packages/workflow-history-list/index.js +6 -0
  257. package/packages/workflow-history-list/src/api.js +7 -0
  258. package/packages/workflow-history-list/src/workflow-history-list.vue +302 -0
  259. package/packages/workgroup-tree/index.js +6 -0
  260. package/packages/workgroup-tree/src/workgroup-tree.vue +87 -0
  261. package/packages/workgroup-tree-inline/index.js +6 -0
  262. package/packages/workgroup-tree-inline/src/search-result.vue +226 -0
  263. package/packages/workgroup-tree-inline/src/workgroup-tree-inline.vue +539 -0
  264. package/packages/workgroup-tree-inline/src/workgroup-tree-service.js +93 -0
  265. package/packages/workgroup-user-tree/index.js +6 -0
  266. package/packages/workgroup-user-tree/src/workgroup-user-tree.vue +104 -0
  267. package/packages/workgroup-user-tree-inline/index.js +9 -0
  268. package/packages/workgroup-user-tree-inline/src/search-result.vue +270 -0
  269. package/packages/workgroup-user-tree-inline/src/workgroup-tree-inline-service.js +239 -0
  270. package/packages/workgroup-user-tree-inline/src/workgroup-user-tree-inline.vue +681 -0
  271. package/packages/year-range-picker/index.js +6 -0
  272. package/packages/year-range-picker/src/year-range-picker.vue +53 -0
  273. package/public/vite.svg +1 -0
  274. package/src/api/sso-service.js +193 -0
  275. package/src/api/tab.js +36 -0
  276. package/src/api/user-service.js +11 -0
  277. package/src/assets/401/401.gif +0 -0
  278. package/src/assets/404/404-cloud.png +0 -0
  279. package/src/assets/404/404.png +0 -0
  280. package/src/assets/cloud.png +0 -0
  281. package/src/assets/nonemessage.png +0 -0
  282. package/src/directives/permission/index.js +13 -0
  283. package/src/directives/permission/permission.js +20 -0
  284. package/src/i18n/i18n.js +16 -0
  285. package/src/i18n/langs/cn.js +266 -0
  286. package/src/i18n/langs/en.js +276 -0
  287. package/src/index.js +93 -0
  288. package/src/permission.js +242 -0
  289. package/src/plugins.js +18 -0
  290. package/src/router/index.js +92 -0
  291. package/src/store/getters.js +15 -0
  292. package/src/store/index.js +19 -0
  293. package/src/store/modules/app.js +54 -0
  294. package/src/store/modules/permission.js +143 -0
  295. package/src/store/modules/tab-content.js +36 -0
  296. package/src/store/modules/user.js +365 -0
  297. package/src/styles/display-layout.scss +34 -0
  298. package/src/styles/element-ui.scss +29 -0
  299. package/src/styles/index.scss +157 -0
  300. package/src/styles/mixin.scss +27 -0
  301. package/src/styles/theme/black/font-style.scss +70 -0
  302. package/src/styles/theme/black/index.scss +306 -0
  303. package/src/styles/theme/black/sidebar.scss +189 -0
  304. package/src/styles/theme/blue/font-style.scss +46 -0
  305. package/src/styles/theme/blue/index.scss +172 -0
  306. package/src/styles/theme/blue/sidebar.scss +171 -0
  307. package/src/styles/theme/blue2/font-style.scss +70 -0
  308. package/src/styles/theme/blue2/index.scss +188 -0
  309. package/src/styles/theme/blue2/sidebar.scss +201 -0
  310. package/src/styles/theme/dark-blue/button.scss +78 -0
  311. package/src/styles/theme/dark-blue/card.scss +63 -0
  312. package/src/styles/theme/dark-blue/checkbox.scss +10 -0
  313. package/src/styles/theme/dark-blue/dark-blue-var.scss +9 -0
  314. package/src/styles/theme/dark-blue/dialog.scss +17 -0
  315. package/src/styles/theme/dark-blue/element-variables.scss +7 -0
  316. package/src/styles/theme/dark-blue/font.scss +71 -0
  317. package/src/styles/theme/dark-blue/form.scss +51 -0
  318. package/src/styles/theme/dark-blue/index.scss +277 -0
  319. package/src/styles/theme/dark-blue/input.scss +15 -0
  320. package/src/styles/theme/dark-blue/message.scss +8 -0
  321. package/src/styles/theme/dark-blue/pagination.scss +18 -0
  322. package/src/styles/theme/dark-blue/radio.scss +13 -0
  323. package/src/styles/theme/dark-blue/scrollbar-style.scss +32 -0
  324. package/src/styles/theme/dark-blue/sidebar.scss +268 -0
  325. package/src/styles/theme/dark-blue/tab.scss +83 -0
  326. package/src/styles/theme/dark-blue/table.scss +60 -0
  327. package/src/styles/theme/dark-blue/tree.scss +57 -0
  328. package/src/styles/theme/dark-blue/var.scss +1028 -0
  329. package/src/styles/theme/gray/card-style.scss +54 -0
  330. package/src/styles/theme/gray/font-style.scss +70 -0
  331. package/src/styles/theme/gray/index.scss +172 -0
  332. package/src/styles/theme/gray/input-style.scss +19 -0
  333. package/src/styles/theme/gray/scrollbar-style.scss +32 -0
  334. package/src/styles/theme/gray/sidebar.scss +243 -0
  335. package/src/styles/theme/gray/tab-style.scss +81 -0
  336. package/src/styles/transition.scss +47 -0
  337. package/src/utils/auth-api.js +259 -0
  338. package/src/utils/auth.js +98 -0
  339. package/src/utils/calculator/calculator-factory-wf.js +558 -0
  340. package/src/utils/calculator/calculator-factory.js +145 -0
  341. package/src/utils/calculator/calculator-util.js +166 -0
  342. package/src/utils/common-util.js +474 -0
  343. package/src/utils/eventBus.js +10 -0
  344. package/src/utils/iconUtils.js +37 -0
  345. package/src/utils/index.js +102 -0
  346. package/src/utils/jump-page-utils.js +824 -0
  347. package/src/utils/local-storage.js +33 -0
  348. package/src/utils/menu.js +19 -0
  349. package/src/utils/permission.js +31 -0
  350. package/src/utils/permissionAuth.js +121 -0
  351. package/src/utils/range-selector.js +204 -0
  352. package/src/utils/request.js +280 -0
  353. package/src/utils/restful-interface-utils.js +57 -0
  354. package/src/utils/util.js +910 -0
  355. package/src/utils/validate.js +34 -0
  356. package/src/utils/watermark.js +108 -0
  357. package/src/utils/workflow-util.js +104 -0
  358. package/src/views/404.vue +248 -0
  359. package/src/views/dsc-component/Sidebar/Item.vue +81 -0
  360. package/src/views/dsc-component/Sidebar/Link.vue +38 -0
  361. package/src/views/dsc-component/Sidebar/SidebarItem.vue +197 -0
  362. package/src/views/dsc-component/Sidebar/index.vue +229 -0
  363. package/src/views/dsc-component/tabs/tab-content.vue +215 -0
  364. package/src/views/error-page/401.vue +106 -0
  365. package/src/views/error-page/404.vue +248 -0
  366. package/src/views/layout/EmptyLayout.vue +3 -0
  367. package/src/views/layout/Layout.vue +81 -0
  368. package/src/views/layout/NewLayout.vue +18 -0
  369. package/src/views/layout/components/AppMain.vue +39 -0
  370. package/src/views/layout/components/Breadcrumb/index.vue +158 -0
  371. package/src/views/layout/components/Menubar/Item.vue +79 -0
  372. package/src/views/layout/components/Menubar/Link.vue +38 -0
  373. package/src/views/layout/components/Menubar/SidebarItem.vue +261 -0
  374. package/src/views/layout/components/Menubar/index.vue +210 -0
  375. package/src/views/layout/components/Sidebar/Item.vue +53 -0
  376. package/src/views/layout/components/Sidebar/Link.vue +38 -0
  377. package/src/views/layout/components/Sidebar/SidebarItem.vue +135 -0
  378. package/src/views/layout/components/Sidebar/index.vue +141 -0
  379. package/src/views/layout/components/iframe-page.vue +38 -0
  380. package/src/views/layout/components/index.js +4 -0
  381. package/src/views/layout/components/tabs/tab-content.vue +214 -0
  382. package/src/views/layout/mixin/ResizeHandler.js +41 -0
  383. package/src/views/layout/tab-content-iframe-index.vue +38 -0
  384. package/src/views/layout/tab-content-index.vue +92 -0
  385. package/src/views/login/authredirect.vue +10 -0
  386. package/src/views/login/index.vue +296 -0
  387. package/src/views/login/update-password.vue +243 -0
  388. package/src/views/redirect/index.vue +14 -0
  389. package/src/views/svg-icon/index.js +6 -0
  390. package/src/views/svg-icon/src/svg-icon.vue +46 -0
  391. package/src/views/wf-history/tache-subprocess-history.vue +45 -0
  392. package/vite.config.js +37 -0
@@ -0,0 +1,1239 @@
1
+ <template>
2
+ <el-table-column
3
+ :align="align"
4
+ :class-name="column.prop"
5
+ :filter-method="filterMethod"
6
+ :filters="filters"
7
+ :fixed="fixed"
8
+ :header-align="headerAlign"
9
+ :prop="column.prop"
10
+ :sortable="sortable"
11
+ :width="getColumnWidth()"
12
+ >
13
+ <template v-slot:header>
14
+ <span :class="{ is_req: isFieldRequired() }"
15
+ ><span
16
+ :title="$escapeHtml(label)"
17
+ class="cell--span required__label"
18
+ v-html="$escapeHtml(label)"
19
+ /></span>
20
+ <el-icon v-if="isShowAdd" style="font-size: 20px; color: #409eff" @click="createFormSubTableRow">
21
+ <CirclePlus/>
22
+ </el-icon>
23
+ </template>
24
+ <template v-slot="scope">
25
+ <!--添加:key="column.prop+'_'+scope.$index"是为了解决多行是行编辑状态时新建的记录的文本框内有值的问题-->
26
+ <dynamic-input
27
+ v-if="lineEdit.editable && isEditable && scope.row.$editing"
28
+ v-model:value="scope.row[column.prop]"
29
+ :class="isRequired(scope.row.$editing) ? 'm-requried' : ''"
30
+ :column="column"
31
+ :is-sql="isSql"
32
+ :line-edit="lineEdit"
33
+ :list-code="listCode"
34
+ :list-toolbar-form-data="listToolbarFormData"
35
+ :options="column.valueSet"
36
+ :position="{
37
+ row: scope.$index,
38
+ prop: column.prop,
39
+ }"
40
+ :row="scope.row"
41
+ :row-index="scope.$index"
42
+ :type="column.componentType"
43
+ @findIndex="findIndex(scope.$index)"
44
+ @focus="onFocus(scope.$index)"
45
+ @prohibitToEdit="prohibitToEdit"
46
+ @refresData="refresData"
47
+ @refresMainTableFields="refresMainTableFields"
48
+ @refresPortData="refresPortData"
49
+ @refresPortsData="refresPortsData"
50
+ />
51
+ <span v-else>
52
+ <span v-if="column.operations" class="grid-operation-buttons">
53
+ <span
54
+ v-for="(operation, operationIndex) in column.operations"
55
+ :key="operationIndex"
56
+ class="cell--span"
57
+ >
58
+ <el-dropdown
59
+ v-if="operation.isGroup"
60
+ :size="
61
+ operation.buttons && operation.buttons.length > 0
62
+ ? operation.buttons[0].props.size
63
+ : 'small'
64
+ "
65
+ split-button
66
+ style="padding-left: 10px"
67
+ @command="handleCommand"
68
+ >
69
+ {{ $escapeHtml(operation.label) }}
70
+ <template v-slot:dropdown>
71
+ <el-dropdown-menu>
72
+ <span
73
+ v-for="(buttonChild, buttonChildIndex) in operation.buttons"
74
+ :key="buttonChild.props.code + buttonChildIndex"
75
+ >
76
+ <el-dropdown-item
77
+ v-permission="buttonChild.props.permission"
78
+ :command="
79
+ beforeHandleCommand(
80
+ buttonChild.props.code,
81
+ scope.row,
82
+ scope.$index
83
+ )
84
+ "
85
+ :disabled="preventReclick"
86
+ >
87
+ {{
88
+ $escapeHtml(
89
+ buttonChild.props.label
90
+ ? buttonChild.props.label
91
+ : buttonChild.props.code === 'search'
92
+ ? $t('superPageMessage.searchButtonLabel')
93
+ : ''
94
+ )
95
+ }}
96
+ </el-dropdown-item>
97
+ </span>
98
+ </el-dropdown-menu>
99
+ </template>
100
+ </el-dropdown>
101
+ <row-operation
102
+ v-else
103
+ :column="column"
104
+ :editing="scope.row.$editing"
105
+ :entity="scope.row"
106
+ :is-show="operation.isShow"
107
+ :label="
108
+ operation.props.label
109
+ ? operation.props.label
110
+ : scope.row[column.prop]
111
+ "
112
+ :on-click="operation.onClick"
113
+ :operation-index="operationIndex"
114
+ :operation-setting="operation.props"
115
+ :row-index="scope.$index"
116
+ />
117
+ </span>
118
+ </span>
119
+ <span
120
+ v-else-if="
121
+ customFormatValue(
122
+ scope.row,
123
+ column.prop,
124
+ customFormat,
125
+ scope.$index
126
+ )
127
+ "
128
+ class="cell--span"
129
+ >
130
+ <component
131
+ :is="column.prop + scope.$index"
132
+ :entity="scope.row"
133
+ :parent="parentFormData"
134
+ :prop="column.prop"
135
+ :row="scope.row"
136
+ :row-index="scope.$index"
137
+ :select-options="column.valueSet"
138
+ :show-value="$escapeHtml(getLabel(scope.row, scope.$index))"
139
+ :value="getCellValue(scope.row)"
140
+ :additional-param-map="additionalParamMap"
141
+ />
142
+ </span>
143
+ <!-- 自定义格式的时候 -->
144
+ <span
145
+ v-else-if="
146
+ columnFormatter !== undefined &&
147
+ columnFormatter.type !== undefined &&
148
+ columnFormatter.type === 'customControl' &&
149
+ columnFormatter.options &&
150
+ columnFormatter.options.format &&
151
+ columnFormatter.options.format !== ''
152
+ "
153
+ class="cell--span"
154
+ >
155
+ <!--:key="column.prop+'_'+scope.$index+'_'+currentPage" 为了解决子表分页时,新增自动跳转到下一页,第一条记录的自定义控件被复用,导致业务逻辑没执行 -->
156
+ <component
157
+ :is="columnFormatter.options.format"
158
+ :key="column.prop + '_' + scope.$index + '_' + currentPage"
159
+ :current-page="currentPage"
160
+ :disabled="true"
161
+ :entity="pageGridData[scope.$index]"
162
+ :get-form-data="getFormData"
163
+ :get-grid-data="getTableGridData"
164
+ :grid-data="gridData"
165
+ :page-grid-data="pageGridData"
166
+ :parent="parentFormData"
167
+ :prop="column.prop"
168
+ :row="pageGridData[scope.$index]"
169
+ :row-index="scope.$index"
170
+ :select-options="column.valueSet"
171
+ :show-value="
172
+ $escapeHtml(getLabel(pageGridData[scope.$index], scope.$index))
173
+ "
174
+ :value="getCellValue(pageGridData[scope.$index])"
175
+ :additional-param-map="additionalParamMap"
176
+ /></span>
177
+ <span
178
+ v-else-if="
179
+ columnFormatter !== undefined &&
180
+ columnFormatter.type !== undefined &&
181
+ columnFormatter.type === 'secretInfo'
182
+ "
183
+ :id="column.prop + 'DomData' + scope.$index"
184
+ class="cell--span"
185
+ >
186
+ <secret-info
187
+ :entity="scope.row"
188
+ :field-label="$escapeHtml(label)"
189
+ :list-code="listCode"
190
+ :list-name="listName"
191
+ :page-code="pageCode"
192
+ :prop="column.prop"
193
+ :table-name="tableName"
194
+ :value="getCellValue(scope.row)"
195
+ />
196
+ </span>
197
+ <span v-else-if="isObjectProp(column.prop)">
198
+ <span v-if="column.componentType === 'annex'" type="primary">
199
+ <span
200
+ v-if="isShowOverflowTooltip"
201
+ :id="column.prop + 'DomData' + scope.$index"
202
+ :style="{ width: cellWidth + 'px' }"
203
+ :title="$escapeHtml(getLabel(scope.row))"
204
+ class="ellipsis cell--span"
205
+ >
206
+ <span v-if="$escapeHtml(getLabel(scope.row, scope.$index))">
207
+ <el-icon class="annex-cell" @click="previewImg(scope.row)"><el-icon-zoom-in/></el-icon>
208
+ </span>
209
+ {{ $escapeHtml(getLabel(scope.row, scope.$index)) }}
210
+ </span>
211
+ <span
212
+ v-else
213
+ :id="column.prop + 'DomData' + scope.$index"
214
+ class="cell--span"
215
+ >
216
+ <span v-if="$escapeHtml(getLabel(scope.row, scope.$index))">
217
+ <el-icon class="annex-cell" @click="previewImg(scope.row)"><el-icon-zoom-in/></el-icon>
218
+ </span>
219
+ {{ $escapeHtml(getLabel(scope.row, scope.$index)) }}
220
+ </span>
221
+ </span>
222
+ <span
223
+ v-else-if="column.formatter && column.formatter.type === 'files'"
224
+ type="primary"
225
+ >
226
+ <span
227
+ v-if="isShowOverflowTooltip"
228
+ :id="column.prop + 'DomData' + scope.$index"
229
+ :style="{ width: cellWidth + 'px' }"
230
+ :title="$escapeHtml(getLabel(scope.row))"
231
+ class="ellipsis cell--span"
232
+ >
233
+ <span v-if="$escapeHtml(getLabel(scope.row, scope.$index))">
234
+ <el-icon class="annex-cell" @click="previewImg(scope.row)"><el-icon-zoom-in/></el-icon>
235
+ </span>
236
+ {{ $escapeHtml(getLabel(scope.row, scope.$index)) }}
237
+ </span>
238
+ <span
239
+ v-else
240
+ :id="column.prop + 'DomData' + scope.$index"
241
+ class="cell--span"
242
+ >
243
+ <span v-if="$escapeHtml(getLabel(scope.row, scope.$index))">
244
+ <el-icon class="annex-cell" @click="previewImg(scope.row)"><el-icon-zoom-in/></el-icon>
245
+ </span>
246
+ {{ $escapeHtml(getLabel(scope.row, scope.$index)) }}
247
+ </span>
248
+ </span>
249
+ <!-- <el-link
250
+ v-else-if="
251
+ columnFormatter !== undefined &&
252
+ columnFormatter.type !== undefined &&
253
+ columnFormatter.type === 'hyperlinks' &&
254
+ getMyHyperLinkSetting(scope.row).visible === true
255
+ "
256
+ type="primary"
257
+ @click="clickHyperLink(column, scope.row, listCode, scope.$index)"
258
+ > -->
259
+ <el-link v-else-if="
260
+ columnFormatter !== undefined &&
261
+ columnFormatter.type !== undefined &&
262
+ columnFormatter.type === 'hyperlinks'
263
+ && getMyHyperLinkSetting(scope.row).visible === true"
264
+ :type="getLinkType(scope.row)"
265
+ @click="clickHyperLink(column, scope.row, listCode,scope.$index)">
266
+ <span
267
+ v-if="isShowOverflowTooltip"
268
+ :id="column.prop + 'DomData' + scope.$index"
269
+ :style="{ width: cellWidth + 'px' }"
270
+ :title="getMyHyperLinkSetting(scope.row).title"
271
+ class="ellipsis cell--span"
272
+ >{{ getMyHyperLinkSetting(scope.row).label
273
+ }}<i
274
+ v-if="getMyHyperLinkSetting(scope.row).icon"
275
+ :class="getMyHyperLinkSetting(scope.row).icon"
276
+ /></span>
277
+ <span
278
+ v-else
279
+ :id="column.prop + 'DomData' + scope.$index"
280
+ class="cell--span"
281
+ >{{ getMyHyperLinkSetting(scope.row).label
282
+ }}<i
283
+ v-if="getMyHyperLinkSetting(scope.row).icon"
284
+ :class="getMyHyperLinkSetting(scope.row).icon"
285
+ /></span>
286
+ </el-link>
287
+ <span
288
+ v-else-if="isShowOverflowTooltip"
289
+ :id="column.prop + 'DomData' + scope.$index"
290
+ :style="{ width: cellWidth + 'px' }"
291
+ :title="$escapeHtml(getLabel(scope.row))"
292
+ class="ellipsis cell--span"
293
+ >{{ $escapeHtml(getLabel(scope.row, scope.$index)) }}</span
294
+ >
295
+ <span
296
+ v-else
297
+ :id="column.prop + 'DomData' + scope.$index"
298
+ class="cell--span"
299
+ >{{ $escapeHtml(getLabel(scope.row, scope.$index)) }}</span
300
+ >
301
+ </span>
302
+ <span v-else>
303
+ <span
304
+ v-if="
305
+ column.componentType === 'annex' ||
306
+ column.componentType === 'multipartUpload'
307
+ "
308
+ type="primary"
309
+ >
310
+ <span
311
+ v-if="isShowOverflowTooltip"
312
+ :id="column.prop + 'DomData' + scope.$index"
313
+ :style="{ width: cellWidth + 'px' }"
314
+ :title="$escapeHtml(getLabel(scope.row))"
315
+ class="ellipsis cell--span"
316
+ >
317
+ <FsPreview
318
+ :entity="scope.row"
319
+ :file-set-obj="getFileObj(column.fileSet)"
320
+ :is-sql="isSql"
321
+ :label="$escapeHtml(getLabel(scope.row, scope.$index))"
322
+ />
323
+ </span>
324
+ <span
325
+ v-else
326
+ :id="column.prop + 'DomData' + scope.$index"
327
+ class="cell--span"
328
+ >
329
+ <FsPreview
330
+ :entity="scope.row"
331
+ :file-set-obj="getFileObj(column.fileSet)"
332
+ :is-sql="isSql"
333
+ :label="$escapeHtml(getLabel(scope.row, scope.$index))"
334
+ />
335
+ </span>
336
+ </span>
337
+ <span
338
+ v-else-if="column.formatter && column.formatter.type === 'files'"
339
+ >
340
+ <span
341
+ v-if="isShowOverflowTooltip"
342
+ :id="column.prop + 'DomData' + scope.$index"
343
+ :style="{ width: cellWidth + 'px' }"
344
+ :title="$escapeHtml(getLabel(scope.row))"
345
+ class="ellipsis cell--span"
346
+ >
347
+ <span v-if="$escapeHtml(getLabel(scope.row, scope.$index))">
348
+ <el-icon class="annex-cell" @click="previewImg(scope.row)"><el-icon-zoom-in/></el-icon>
349
+ </span>
350
+ {{ $escapeHtml(getLabel(scope.row, scope.$index)) }}
351
+ </span>
352
+ <span
353
+ v-else
354
+ :id="column.prop + 'DomData' + scope.$index"
355
+ class="cell--span"
356
+ >
357
+ <span v-if="$escapeHtml(getLabel(scope.row, scope.$index))">
358
+ <el-icon class="annex-cell" @click="previewImg(scope.row)"><el-icon-zoom-in/></el-icon>
359
+ </span>
360
+ {{ $escapeHtml(getLabel(scope.row, scope.$index)) }}
361
+ </span>
362
+ </span>
363
+ <!-- 超链接 -->
364
+ <el-link
365
+ v-else-if="
366
+ columnFormatter !== undefined &&
367
+ columnFormatter.type !== undefined &&
368
+ columnFormatter.type === 'hyperlinks' &&
369
+ getMyHyperLinkSetting(scope.row).visible === true
370
+ "
371
+ type="primary"
372
+ @click="clickHyperLink(column, scope.row, listCode, scope.$index)"
373
+ >
374
+ <span
375
+ v-if="isShowOverflowTooltip"
376
+ :id="column.prop + 'DomData' + scope.$index"
377
+ :style="{ width: cellWidth + 'px' }"
378
+ :title="$escapeHtml(getMyHyperLinkSetting(scope.row).title)"
379
+ class="ellipsis cell--span"
380
+ >{{ $escapeHtml(getMyHyperLinkSetting(scope.row).label)
381
+ }}<i
382
+ v-if="getMyHyperLinkSetting(scope.row).icon"
383
+ :class="getMyHyperLinkSetting(scope.row).icon"
384
+ /></span>
385
+ <span
386
+ v-else
387
+ :id="column.prop + 'DomData' + scope.$index"
388
+ class="cell--span"
389
+ >{{ $escapeHtml(getMyHyperLinkSetting(scope.row).label)
390
+ }}<i
391
+ v-if="getMyHyperLinkSetting(scope.row).icon"
392
+ :class="getMyHyperLinkSetting(scope.row).icon"
393
+ /></span>
394
+ </el-link>
395
+ <!-- 富文本 -->
396
+ <span
397
+ v-else-if="
398
+ column.formatter && column.formatter.type === 'richEditor'
399
+ "
400
+ >
401
+ <el-tooltip
402
+ :content="$t('superGrid.show')"
403
+ class="item"
404
+ effect="dark"
405
+ placement="top"
406
+ >
407
+ <em
408
+ class="fa fa-info-circle annex-cell"
409
+ @click="showRichEditorContent(scope.row, column, getHeader())"
410
+ />
411
+ </el-tooltip>
412
+ </span>
413
+ <GridIcon
414
+ v-else-if="column.formatter && column.formatter.type === 'icon'"
415
+ :id="column.prop+'DomData'+scope.$index"
416
+ :column="column"
417
+ :row="scope.row"
418
+ :row-index="scope.$index"
419
+ :is-sql="isSql"
420
+ :list-code="listCode"
421
+ />
422
+ <span
423
+ v-else-if="isShowOverflowTooltip"
424
+ :id="column.prop + 'DomData' + scope.$index"
425
+ :style="{ width: cellWidth + 'px' }"
426
+ :title="getLabel(scope.row)"
427
+ class="ellipsis cell--span"
428
+ style="white-space: pre"
429
+ v-html="$escapeHtml(getLabel(scope.row, scope.$index))"
430
+ />
431
+ <span
432
+ v-else
433
+ :id="column.prop + 'DomData' + scope.$index"
434
+ class="cell--span"
435
+ >{{ $escapeHtml(getLabel(scope.row, scope.$index)) }}</span
436
+ >
437
+ </span>
438
+ </span>
439
+ <view-image-dialog
440
+ v-if="showSingleImgFlag"
441
+ :file-list="fileList"
442
+ @close="showSingleImgFlag = false"
443
+ />
444
+ <rich-editor-viewer
445
+ v-if="showRichEditorViewer"
446
+ ref="richEditorViewerRef"
447
+ @closeRichEditorContent="closeRichEditorContent"
448
+ />
449
+ </template>
450
+ </el-table-column>
451
+ </template>
452
+
453
+ <script>
454
+ import {CirclePlus, ZoomIn as ElIconZoomIn} from '@element-plus/icons-vue'
455
+ import {$emit, $off, $on} from '../../utils/gogocodeTransfer'
456
+ import {
457
+ ArrowKeyAction,
458
+ getColumnValues,
459
+ getFileList,
460
+ isDynamicDataSourceSource,
461
+ isHasEditOption,
462
+ isRequiredEdit,
463
+ getAdditionalParamMap
464
+ } from './utils'
465
+ import DynamicInput from './dynamic-input.vue'
466
+ import store from './store'
467
+ import {doFormatWithValueSet} from './formatter'
468
+ import customFormatter from './custom-formatter'
469
+ import RowOperation from './row-operation.vue'
470
+ import apis from './apis'
471
+ import {mapGetters} from 'vuex'
472
+ import {getEntityFieldValue, getParentObjectUtil,} from '../../../src/utils/util'
473
+ import ViewImageDialog from './view-image-dialog.vue'
474
+ import eventBus from './eventBus'
475
+ import FsPreview from '../../fs-preview'
476
+ import RichEditorViewer from '../../rich-editor/viewer.vue'
477
+ import GridIcon from './components/grid-icon'
478
+ export default {
479
+ components: {
480
+ DynamicInput,
481
+ RowOperation,
482
+ ViewImageDialog,
483
+ FsPreview,
484
+ RichEditorViewer,
485
+ CirclePlus,
486
+ ElIconZoomIn,
487
+ GridIcon
488
+ },
489
+ name: 'NormalColumn',
490
+ props: {
491
+ column: {
492
+ type: Object,
493
+ default: null,
494
+ },
495
+ customFormat: {
496
+ type: Function,
497
+ default: null,
498
+ },
499
+ listCode: {
500
+ type: String,
501
+ default: null,
502
+ },
503
+ isSql: {
504
+ type: Boolean,
505
+ default: false,
506
+ },
507
+ newWidth: {
508
+ type: Number,
509
+ default: null,
510
+ },
511
+ dragColumnProp: {
512
+ type: String,
513
+ default: null,
514
+ },
515
+ tableName: {
516
+ type: String,
517
+ default: null,
518
+ },
519
+ pageCode: {
520
+ type: String,
521
+ default: null,
522
+ },
523
+ listName: {
524
+ type: String,
525
+ default: null,
526
+ },
527
+ currentPage: {
528
+ type: Number,
529
+ default: 1,
530
+ },
531
+ gridData: {
532
+ type: Array,
533
+ default: null,
534
+ },
535
+ pageGridData: {
536
+ type: Array,
537
+ default: null,
538
+ },
539
+ listToolbarFormData: {
540
+ type: Object,
541
+ default: null,
542
+ },
543
+ },
544
+ data() {
545
+ let parentFormData
546
+ const gridParams = store.get(this.listCode)
547
+ if (
548
+ gridParams.options.extraParam &&
549
+ gridParams.options.extraParam.entityMap
550
+ ) {
551
+ parentFormData = gridParams.options.extraParam.entityMap
552
+ }
553
+ const additionalParamMap = getAdditionalParamMap(gridParams)
554
+ return {
555
+ selectRow: null,
556
+ that: this,
557
+ align: 'left', // 文本内容对齐
558
+ headerAlign: 'left', // 表头对齐方式
559
+ columnFormatter: this.column.formatter,
560
+ hyperLinks: {},
561
+ fileDownType: '',
562
+ isFormSubTable: false, // 是否是表单子表
563
+ subTableCanAdd: true, // 表单子表时是否有新增权限
564
+ isShowAdd: false, // 是否显示表头的新增按钮
565
+ cellWidth: null,
566
+ parentFormData,
567
+ fileMultiple: false, // 附件上传是否多选
568
+ showSingleImgFlag: false,
569
+ singleImgSrc: '',
570
+ fileList: [],
571
+ index: null,
572
+ isEditable: this.column.editable,
573
+ showRichEditorViewer: false,
574
+ getFormData: gridParams.options.getFormData,
575
+ getTableGridData: gridParams.options.getGridData,
576
+ additionalParamMap
577
+ }
578
+ },
579
+ computed: {
580
+ filters() {
581
+ if (this.column.filterable) {
582
+ const gridParams = store.get(this.listCode)
583
+ const values = getColumnValues(gridParams.gridData, this.column.prop)
584
+ const filters = []
585
+ for (const value of values) {
586
+ filters.push({
587
+ text: value,
588
+ value,
589
+ })
590
+ }
591
+ return filters
592
+ } else {
593
+ return null
594
+ }
595
+ },
596
+ filterMethod() {
597
+ if (this.column.filterable) {
598
+ return this.filterHandler
599
+ } else {
600
+ return null
601
+ }
602
+ },
603
+ fixed() {
604
+ if (
605
+ (this.column.fixed && this.column.fixed === 'false') ||
606
+ this.column.fixed === undefined ||
607
+ this.column.fixed === ''
608
+ ) {
609
+ return false
610
+ }
611
+ if (
612
+ this.column.prop === 'operation' &&
613
+ this.column.fixed &&
614
+ this.column.fixed === 'left'
615
+ ) {
616
+ // 操作列居右固定
617
+ return 'right'
618
+ }
619
+ return this.column.fixed
620
+ },
621
+ sortable() {
622
+ const gridParams = store.get(this.listCode)
623
+ if (
624
+ gridParams &&
625
+ gridParams.options &&
626
+ gridParams.options.isFormSubTable &&
627
+ gridParams.options.showOperationButton
628
+ ) {
629
+ return false
630
+ }
631
+ if (
632
+ this.column.sortable === 'false' ||
633
+ this.column.sortable === false ||
634
+ this.column.sortable === ''
635
+ ) {
636
+ return false
637
+ } else if (
638
+ this.column.sortable === 'true' ||
639
+ this.column.sortable === true
640
+ ) {
641
+ return 'custom'
642
+ }
643
+ if (this.column.sortable) {
644
+ return 'custom'
645
+ } else {
646
+ return false
647
+ }
648
+ },
649
+ lineEdit() {
650
+ let isLineEdit = false
651
+ if (this.listCode) {
652
+ const gridParams = store.get(this.listCode)
653
+ if (gridParams.lineEdit !== null && gridParams.lineEdit !== undefined) {
654
+ isLineEdit = gridParams.lineEdit
655
+ } else {
656
+ isLineEdit = false
657
+ }
658
+ }
659
+ return isLineEdit
660
+ },
661
+
662
+ ...mapGetters(['preventReclick']),
663
+ },
664
+ watch: {
665
+ isSql: {
666
+ deep: true,
667
+
668
+ handler(newValue, oldValue) {
669
+ this.isSql = newValue
670
+ },
671
+ },
672
+ newWidth: {
673
+ deep: true,
674
+
675
+ handler(newValue, oldValue) {
676
+ if (
677
+ newValue !== undefined &&
678
+ newValue !== null &&
679
+ this.dragColumnProp &&
680
+ this.dragColumnProp === this.column.prop
681
+ ) {
682
+ this.cellWidth = newValue
683
+ }
684
+ },
685
+ },
686
+ },
687
+ created() {
688
+ if (this.column.width) {
689
+ this.cellWidth = this.column.width - 10
690
+ }
691
+ const gridParams = store.get(this.listCode)
692
+ if (gridParams && gridParams.options && gridParams.options.isFormSubTable) {
693
+ this.isFormSubTable = gridParams.options.isFormSubTable
694
+ }
695
+ if (
696
+ gridParams &&
697
+ gridParams.options &&
698
+ gridParams.options.subTableCanAdd !== undefined &&
699
+ gridParams.options.subTableCanAdd !== null
700
+ ) {
701
+ this.subTableCanAdd = gridParams.options.subTableCanAdd
702
+ }
703
+ if (this.column.prop && this.column.prop === 'operation') {
704
+ // 如果是操作列按钮则不显示省略号
705
+ this.isShowOverflowTooltip = false
706
+ } else {
707
+ if (
708
+ typeof gridParams.options.showOverflowTooltip !== 'undefined' &&
709
+ gridParams.options.showOverflowTooltip === false
710
+ ) {
711
+ this.isShowOverflowTooltip = false
712
+ } else {
713
+ this.isShowOverflowTooltip = true
714
+ }
715
+ }
716
+ if (typeof gridParams.options.align !== 'undefined') {
717
+ this.align = gridParams.options.align
718
+ } else if (this.column.contAlign && this.column.contAlign !== '') {
719
+ this.align = this.column.contAlign
720
+ }
721
+ if (typeof gridParams.options.headerAlign !== 'undefined') {
722
+ this.headerAlign = gridParams.options.headerAlign
723
+ } else if (this.column.titleAlign && this.column.titleAlign !== '') {
724
+ this.headerAlign = this.column.titleAlign
725
+ } else {
726
+ // 如果没有配置表头对齐方式,默认使用内容对齐方式
727
+ this.headerAlign = 'left'
728
+ }
729
+ if (
730
+ gridParams.isHasDynamic === undefined &&
731
+ this.column.dynamic !== undefined &&
732
+ this.column.dynamic === true
733
+ ) {
734
+ // 当前列表中有动态列
735
+ gridParams.isHasDynamic = true
736
+ }
737
+ this.label = this.getHeader()
738
+ if (this.column.operations) {
739
+ // console.log('this.column.operations', this.column.operations)
740
+ }
741
+ // console.log('gridParams.options.subTableCanAdd=', gridParams.options.subTableCanAdd, 'this.subTableCanAdd=', this.subTableCanAdd)
742
+ this.isShowAdd =
743
+ this.isFormSubTable &&
744
+ this.column.prop === 'operation' &&
745
+ this.subTableCanAdd &&
746
+ gridParams.options &&
747
+ gridParams.options.showOperationButton
748
+ if (
749
+ this.column.fileSet &&
750
+ this.column.fileSet !== '' &&
751
+ this.column.componentType === 'annex'
752
+ ) {
753
+ const fileSetObj = JSON.parse(this.column.fileSet)
754
+ if (fileSetObj && fileSetObj.multiple) {
755
+ this.fileMultiple = true
756
+ }
757
+ }
758
+ },
759
+ mounted() {
760
+ // 监听保存时点击按钮事件线触发
761
+ $on(eventBus, 'un-edit', (param) => {
762
+ // 处理多选选项组问题保存问题
763
+ if (
764
+ this.column.componentType &&
765
+ (this.column.componentType === 'multiselect' ||
766
+ this.column.componentType === 'select')
767
+ ) {
768
+ const isDynamic = isDynamicDataSourceSource(this.column)
769
+ if (!isDynamic) {
770
+ // 选项组保存时将数组处理为字符串
771
+ const beforeColumnValue = param.row[this.column.prop]
772
+ if (
773
+ beforeColumnValue &&
774
+ Object.prototype.toString.apply(beforeColumnValue) ===
775
+ '[object Array]'
776
+ ) {
777
+ // 如果是数组才需要转换
778
+ param.row[this.column.prop] = beforeColumnValue.join(',')
779
+ }
780
+ } else {
781
+ // 动态数据源多选保存时,获取已选择的字段,由于多选选项组的值是数组,保存时要拼接成“ ,” 分隔的字符串
782
+ if ('_dynamic-source-data-' + this.column.prop in this.column) {
783
+ const temp = this.column['_dynamic-source-data-' + this.column.prop]
784
+ const valueSetOptions = temp.valueSetOptions
785
+ // 获取当前字段对应在映射关系中对应的是动态数据源中的哪一个字段key
786
+ let selectDataKey
787
+ for (let i = 0; i < valueSetOptions.length; i++) {
788
+ const valueSetOption = valueSetOptions[i]
789
+ if (
790
+ this.column.prop === valueSetOption.valueColumn.dbColumnName
791
+ ) {
792
+ selectDataKey = valueSetOption.columnName
793
+ break
794
+ }
795
+ }
796
+ if (selectDataKey) {
797
+ // beforeColumnValue是数组值,如果是单选则是字符串
798
+ let beforeColumnValue = param.row[this.column.prop]
799
+ if (this.column.componentType === 'select') {
800
+ if (selectDataKey !== temp.valueAttribute) {
801
+ // 解决当前字段不是动态数据源选项值所映射的字段的问题 例如当前字段是工厂名称, 动态数据源选项值是工厂编码
802
+ beforeColumnValue = temp.optionItems.find(
803
+ (item) =>
804
+ // 当前字段映射的是工厂名称,
805
+ // 筛选动态数据源选项值字段对应的当前字段所映射的字段, 例如 根据工厂编码找工厂编码对应的工厂名称
806
+ // 找出名称后赋值给当前字段
807
+ item[temp.valueAttribute] === beforeColumnValue
808
+ )[selectDataKey]
809
+ }
810
+ // 如果是单选
811
+ // 现在选择时已经赋值,不再需要这里进行赋值
812
+ // temp.optionItems.forEach(optionItem => {
813
+ // if (optionItem[temp.valueAttribute] === beforeColumnValue) {
814
+ // this.$set(param.row, this.column.prop, optionItem[selectDataKey])
815
+ // }
816
+ // })
817
+ param.row[this.column.prop] = beforeColumnValue
818
+ } else {
819
+ // 如果是多选,join “ ,” , 并给row赋值
820
+ // 现在选择时已经赋值,不再需要这里进行赋值
821
+ // const afterColumnValue = []
822
+ // temp.optionItems.forEach(optionItem => {
823
+ // beforeColumnValue.forEach(value => {
824
+ // if (optionItem[temp.valueAttribute] === value) {
825
+ // afterColumnValue.push(optionItem[selectDataKey])
826
+ // }
827
+ // })
828
+ // })
829
+ if (
830
+ beforeColumnValue &&
831
+ selectDataKey !== temp.valueAttribute
832
+ ) {
833
+ // 解决当前字段不是动态数据源选项值所映射的字段的问题 例如当前字段是工厂名称, 动态数据源选项值是工厂编码
834
+ const t = []
835
+ beforeColumnValue.forEach((selectItem) => {
836
+ if (selectDataKey !== temp.valueAttribute) {
837
+ t.push(
838
+ temp.optionItems.find(
839
+ (option) => option[temp.valueAttribute] === selectItem
840
+ )[selectDataKey]
841
+ )
842
+ }
843
+ })
844
+ beforeColumnValue = t
845
+ }
846
+ param.row[this.column.prop] = beforeColumnValue.join(',')
847
+ }
848
+ }
849
+ } else {
850
+ const beforeColumnValue = param.row[this.column.prop]
851
+ if (
852
+ beforeColumnValue &&
853
+ Object.prototype.toString.apply(beforeColumnValue) ===
854
+ '[object Array]'
855
+ ) {
856
+ // 如果是数组才需要转换
857
+ param.row[this.column.prop] = beforeColumnValue.join(',')
858
+ }
859
+ }
860
+ }
861
+ }
862
+ })
863
+ },
864
+ unmounted() {
865
+ $off(eventBus, 'un-edit')
866
+ },
867
+ methods: {
868
+ ...customFormatter,
869
+ ...apis,
870
+ getFileObj(fileSet) {
871
+ if (fileSet) {
872
+ return JSON.parse(fileSet)
873
+ }
874
+ },
875
+ getHeader() {
876
+ if (!this.column.titleValueSet) {
877
+ return this.column.label.replace(/\\n/g, '</br>')
878
+ } else {
879
+ return this.formatHeader()
880
+ }
881
+ },
882
+ formatHeader() {
883
+ return doFormatWithValueSet(
884
+ this.column.titleValueSetValue,
885
+ this.column.label
886
+ )
887
+ },
888
+ filterHandler(value, row, column) {
889
+ const property = column['property']
890
+ return row[property] === value
891
+ },
892
+ onFocus(index) {
893
+ const gridParams = store.get(this.listCode)
894
+ if (gridParams.lineEdit.editingCell) {
895
+ gridParams.lineEdit.editingCell.row = index
896
+ gridParams.lineEdit.editingCell.prop = this.column.prop
897
+ }
898
+ },
899
+ findIndex(index) {
900
+ this.index = index
901
+ const gridParams = store.get(this.listCode)
902
+ if (gridParams.lineEdit.editingCell) {
903
+ gridParams.lineEdit.editingCell.row = index
904
+ gridParams.lineEdit.editingCell.prop = this.column.prop
905
+ }
906
+ },
907
+ refresData(data) {
908
+ $emit(this, 'refresData', data)
909
+ },
910
+ refresPortData(port, value) {
911
+ const gridParams = store.get(this.listCode)
912
+ console.log('gridParams', gridParams)
913
+ console.log('this.index', this.index)
914
+ if (
915
+ gridParams &&
916
+ gridParams.lineEdit &&
917
+ gridParams.lineEdit.editingCell
918
+ ) {
919
+ $emit(
920
+ this,
921
+ 'refresPortData',
922
+ port,
923
+ value,
924
+ gridParams.lineEdit.editingCell.row
925
+ )
926
+ } else {
927
+ $emit(this, 'refresPortData', port, value, this.index)
928
+ }
929
+ },
930
+ refresPortsData(map) {
931
+ const gridParams = store.get(this.listCode)
932
+ console.log('gridParams', gridParams)
933
+ console.log('this.index', this.index)
934
+ if (
935
+ gridParams &&
936
+ gridParams.lineEdit &&
937
+ gridParams.lineEdit.editingCell
938
+ ) {
939
+ $emit(this, 'refresPortsData', map, gridParams.lineEdit.editingCell.row)
940
+ } else {
941
+ $emit(this, 'refresPortsData', map, this.index)
942
+ }
943
+ },
944
+ refresMainTableFields(map) {
945
+ $emit(this, 'refresMainTableFields', map)
946
+ },
947
+ // @keyup.native.left="move('left')"
948
+ // @keyup.native.right="move('right')"
949
+ // @keyup.native.up="move('up')"
950
+ // @keyup.native.down="move('down')"
951
+ move(direction) {
952
+ if (direction === 'left') {
953
+ const prop = ArrowKeyAction.getLeftColumn(this.column.prop)
954
+ const gridParams = store.get(this.listCode)
955
+ gridParams.lineEdit.editingCell.prop = prop
956
+ }
957
+ },
958
+ // filterHandler(value, row, column) {
959
+ // const property = column['property']
960
+ // return row[property] === value
961
+ // },
962
+ isSaveByEnter() {
963
+ const gridParams = store.get(this.listCode)
964
+ return (
965
+ typeof gridParams.options.lineEditOptions.isSaveByEnter ===
966
+ 'undefined' ||
967
+ (isHasEditOption('isSaveByEnter', this.listCode) &&
968
+ gridParams.options.lineEditOptions.isSaveByEnter === true)
969
+ )
970
+ },
971
+ isRestoreByEsc() {
972
+ const gridParams = store.get(this.listCode)
973
+ return (
974
+ typeof gridParams.options.lineEditOptions.isRestoreByEsc ===
975
+ 'undefined' ||
976
+ (isHasEditOption('isRestoreByEsc', this.listCode) &&
977
+ gridParams.options.lineEditOptions.isRestoreByEsc === true)
978
+ )
979
+ },
980
+ canFocus(index) {
981
+ const gridParams = store.get(this.listCode)
982
+ if (
983
+ index === gridParams.lineEdit.editingCell.row &&
984
+ this.column.prop === gridParams.lineEdit.editingCell.prop
985
+ ) {
986
+ return true
987
+ } else {
988
+ return false
989
+ }
990
+ },
991
+ getLabel(row, index) {
992
+ this.transferColumnDataToUpperCase(row)
993
+ const obj = this.objectPropValueTwo(row, this.column)
994
+ // // 存储执行时间
995
+ // const get2 = new Date().getTime()
996
+ // const get3 = Number(get2) - Number(get1)
997
+ // if (!window.sessionStorage.getItem('getLabel')) {
998
+ // window.sessionStorage.setItem('getLabel', get3)
999
+ // } else {
1000
+ // const get4 = window.sessionStorage.getItem('getLabel')
1001
+ // const get5 = Number(get4) + Number(get3)
1002
+ // window.sessionStorage.setItem('getLabel', get5)
1003
+ // }
1004
+ return obj
1005
+ // const returnValue = this.objectPropValueTwo(row, this.column)
1006
+ // if (returnValue) {
1007
+ // // 解决当文本中有多个空格时候, vue自动将多个空格合并为一个空格,
1008
+ // // 或者修改vue的配置 https://cn.vuejs.org/api/application.html#app-config-compileroptions app.config.compilerOptions.whitespace
1009
+ // return returnValue.replaceAll(' ', '\u00A0')
1010
+ // }
1011
+ // return returnValue
1012
+ },
1013
+ getCellValue(row) {
1014
+ let cellValue = getEntityFieldValue(row, this.column.prop, false)
1015
+ if (cellValue === undefined || cellValue === null) {
1016
+ this.transferColumnDataToUpperCase(row)
1017
+ cellValue = getEntityFieldValue(row, this.column.prop, false)
1018
+ }
1019
+ return cellValue
1020
+ },
1021
+ // 兼容oracle和mysql数据库,oracle是字段名是大写的,mysql是小写的,将小写转为大写
1022
+ transferColumnDataToUpperCase(row) {
1023
+ const reg1 = /[A-Z]+/ // 大写字母
1024
+ if (this.isSql && reg1.test(this.column.prop)) {
1025
+ this.transferColumnDataToUpperCaseWithProp(
1026
+ row,
1027
+ this.column.prop.toLowerCase(),
1028
+ this.column.prop
1029
+ )
1030
+ }
1031
+ },
1032
+ transferColumnDataToUpperCaseWithProp(row, propLowerCase, columnProp) {
1033
+ let dataModel
1034
+ if (propLowerCase && propLowerCase.indexOf('.') > 0) {
1035
+ const parentObj = getParentObjectUtil(propLowerCase, row)
1036
+ const prop = propLowerCase.substring(propLowerCase.lastIndexOf('.') + 1)
1037
+ dataModel = parentObj[prop]
1038
+ if (dataModel !== undefined) {
1039
+ // sql字段名小写转大写,兼容mysql、oracle数据库
1040
+ parentObj[columnProp] = dataModel
1041
+ delete parentObj[prop]
1042
+ }
1043
+ } else {
1044
+ dataModel = row[propLowerCase]
1045
+ if (dataModel !== undefined) {
1046
+ // sql字段名小写转大写,兼容mysql、oracle数据库
1047
+ row[columnProp] = dataModel
1048
+ delete row[propLowerCase]
1049
+ }
1050
+ }
1051
+ return dataModel
1052
+ },
1053
+ getMyHyperLinkSetting(row) {
1054
+ this.transferColumnDataToUpperCase(row)
1055
+ const gridParams = store.get(this.listCode)
1056
+ let tableName
1057
+ if (
1058
+ gridParams &&
1059
+ gridParams.basicInfo &&
1060
+ gridParams.basicInfo.tableName
1061
+ ) {
1062
+ tableName = gridParams.basicInfo.tableName
1063
+ }
1064
+ const hyperLinkResult = this.getHyperLinkSetting(
1065
+ this.column,
1066
+ row,
1067
+ this.isSql,
1068
+ this.additionalParamMap,
1069
+ gridParams.contextParameter,
1070
+ tableName,
1071
+ this.listCode
1072
+ )
1073
+ hyperLinkResult.icon = this.getHyperIconClass(hyperLinkResult)
1074
+ return hyperLinkResult
1075
+ },
1076
+ getHyperIconClass(hyperLinkResult) {
1077
+ let iconName
1078
+ if (
1079
+ hyperLinkResult &&
1080
+ hyperLinkResult !== null &&
1081
+ hyperLinkResult.icon &&
1082
+ hyperLinkResult.icon !== ''
1083
+ ) {
1084
+ iconName = hyperLinkResult.icon
1085
+ }
1086
+ if (iconName && iconName.indexOf('fa-') === 0) {
1087
+ // 表示以“fa-”开头,使用font-awesome中的图标
1088
+ iconName = 'fa ' + iconName
1089
+ }
1090
+ return iconName
1091
+ },
1092
+ createFormSubTableRow() {
1093
+ console.log('触发了行新建')
1094
+ this.createRow(this.listCode)
1095
+ },
1096
+ handleCommand(comman) {
1097
+ let prop = null
1098
+ this.column.operations.forEach((item) => {
1099
+ if (item.isGroup) {
1100
+ item.buttons.forEach((button) => {
1101
+ if (button.props.code === comman.comman) {
1102
+ prop = button
1103
+ }
1104
+ })
1105
+ }
1106
+ })
1107
+ if (prop) {
1108
+ customFormatter.onClickFun(
1109
+ comman.row,
1110
+ this.column,
1111
+ prop.onClick,
1112
+ comman.rowIndex
1113
+ )
1114
+ }
1115
+ },
1116
+ beforeHandleCommand(comman, row, rowIndex) {
1117
+ return {
1118
+ comman: comman,
1119
+ row: row,
1120
+ rowIndex: rowIndex,
1121
+ }
1122
+ },
1123
+ previewImg(row) {
1124
+ this.fileList = getFileList(row, this.column, this.isSql)
1125
+ this.showSingleImgFlag = true
1126
+ },
1127
+ getFileList(row) {
1128
+ return getFileList(row, this.column, this.isSql)
1129
+ },
1130
+ getColumnWidth() {
1131
+ if (
1132
+ this.column &&
1133
+ this.column.prop === 'operation' &&
1134
+ !this.column.width
1135
+ ) {
1136
+ // 表示操作列,宽度固定
1137
+ return '210'
1138
+ }
1139
+ return this.column.width ? this.column.width + '' : '130'
1140
+ },
1141
+ // 设置字段禁止编辑
1142
+ fnProhibitToEdit(isEditable) {
1143
+ this.isEditable = isEditable
1144
+ },
1145
+ // 设置字段禁止编辑
1146
+ prohibitToEdit(entity) {
1147
+ $emit(this, 'prohibitToEdit', entity)
1148
+ },
1149
+ isFieldRequired() {
1150
+ return isRequiredEdit(this.column, this.listCode)
1151
+ // return true
1152
+ },
1153
+ // 展示富文本内容
1154
+ showRichEditorContent(row, column, header) {
1155
+ this.showRichEditorViewer = true
1156
+ this.$nextTick(() => {
1157
+ this.$refs.richEditorViewerRef.showContent(row[column.prop], header)
1158
+ })
1159
+ },
1160
+ closeRichEditorContent() {
1161
+ this.showRichEditorViewer = false
1162
+ },
1163
+ isRequired(editing) {
1164
+ if (
1165
+ !this.isFormSubTable &&
1166
+ this.lineEdit.editable &&
1167
+ this.isEditable &&
1168
+ editing &&
1169
+ this.column.validations
1170
+ ) {
1171
+ if (this.column.validations.indexOf('"required":true') > 0) {
1172
+ return true
1173
+ }
1174
+ }
1175
+ return false
1176
+ },
1177
+ getFormatIconSetting(row) {
1178
+ this.transferColumnDataToUpperCase(row)
1179
+ const gridParams = store.get(this.listCode)
1180
+ const result = this.getIconSetting(
1181
+ this.column,
1182
+ row,
1183
+ this.isSql,
1184
+ gridParams,
1185
+ this.listCode
1186
+ )
1187
+ result.icon = this.getHyperIconClass(result)
1188
+ if (
1189
+ this.column.formatter.options &&
1190
+ this.column.formatter.options.format
1191
+ ) {
1192
+ result.position = JSON.parse(
1193
+ this.column.formatter.options.format
1194
+ ).position
1195
+ }
1196
+ return result
1197
+ },
1198
+ getLinkType(row) {
1199
+ if (this.column.events && this.column.events['cellStyle']) {
1200
+ const params = {
1201
+ value: row[this.column.property],
1202
+ row: row,
1203
+ column: this.column,
1204
+ prop: this.column.property
1205
+ }
1206
+ const gridParams = store.get(this.listCode)
1207
+ return gridParams.options['eventCallBack'][this.column.events['cellStyle']].call(this, params)
1208
+ }
1209
+ return 'primary'
1210
+ },
1211
+ },
1212
+ emits: [
1213
+ 'refresData',
1214
+ 'refresPortData',
1215
+ 'refresPortsData',
1216
+ 'refresMainTableFields',
1217
+ 'prohibitToEdit',
1218
+ ,
1219
+ ],
1220
+ }
1221
+ </script>
1222
+
1223
+ <style lang="scss" scoped>
1224
+ .annex-cell {
1225
+ padding-right: 5px;
1226
+ cursor: pointer;
1227
+ color: #409eff;
1228
+ }
1229
+
1230
+ .m-requried {
1231
+ float: left;
1232
+ white-space: nowrap;
1233
+ }
1234
+
1235
+ .m-requried::after {
1236
+ content: '*';
1237
+ color: #f56c6c;
1238
+ }
1239
+ </style>