gds-plus-design-vue 1.2.6 → 1.2.7

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 (368) hide show
  1. package/lib/approvalModel.a26e8ff6.mjs +340 -0
  2. package/lib/approvalModel.cfd81971.js +1 -0
  3. package/lib/btnFunctionName.9aabfed0.js +1 -0
  4. package/lib/btnFunctionName.d08627cb.mjs +254 -0
  5. package/lib/btnRelation.8e608261.mjs +156 -0
  6. package/lib/btnRelation.cb3dc022.js +1 -0
  7. package/lib/businessRules.754cc398.mjs +539 -0
  8. package/lib/businessRules.f41f7035.js +1 -0
  9. package/lib/buttonRule.4483314f.mjs +396 -0
  10. package/lib/buttonRule.645de1d3.js +1 -0
  11. package/lib/chartDisplayRules.1f4d1f29.mjs +288 -0
  12. package/lib/chartDisplayRules.fedfefe8.js +1 -0
  13. package/lib/components.chartbi.470b96af.mjs +1798 -0
  14. package/lib/components.chartbi.e9459775.js +8 -0
  15. package/lib/components.coloreditor.affa0400.mjs +1505 -0
  16. package/lib/components.coloreditor.dbec8da6.js +6 -0
  17. package/lib/components.dataassign.39281072.mjs +147 -0
  18. package/lib/components.dataassign.b6a1bffb.js +1 -0
  19. package/lib/components.echarts.95ffc3b3.mjs +811 -0
  20. package/lib/components.echarts.d09e9850.js +4 -0
  21. package/lib/components.exception.11315db5.js +1 -0
  22. package/lib/components.exception.facf9df9.mjs +61 -0
  23. package/lib/components.form.56ea8f98.js +41 -0
  24. package/lib/components.form.a7b3ea37.mjs +7813 -0
  25. package/lib/components.globalheader.0a7ce959.js +1 -0
  26. package/lib/components.globalheader.4a5f7225.mjs +54 -0
  27. package/lib/components.iconselector.0c03cfc7.js +1 -0
  28. package/lib/components.iconselector.251c29b9.mjs +1169 -0
  29. package/lib/components.imgpreview.5546e541.mjs +213 -0
  30. package/lib/components.imgpreview.706a89f0.js +1 -0
  31. package/lib/components.lunccalendar.5363cba5.mjs +1137 -0
  32. package/lib/components.lunccalendar.fe7db238.js +1 -0
  33. package/lib/components.middleware.01601349.js +1 -0
  34. package/lib/components.middleware.f5f4ac0f.mjs +148 -0
  35. package/lib/components.modaltitle.5ded43f9.mjs +127 -0
  36. package/lib/components.modaltitle.cc9ba616.js +1 -0
  37. package/lib/components.multitab.0f9da9f3.mjs +140 -0
  38. package/lib/components.multitab.726cff2f.js +1 -0
  39. package/lib/components.selecttree.1a71c963.mjs +170 -0
  40. package/lib/components.selecttree.2fadffca.js +1 -0
  41. package/lib/components.settingdrawer.1af86231.js +1 -0
  42. package/lib/components.settingdrawer.adc262cf.mjs +237 -0
  43. package/lib/components.sidemenu.03442146.mjs +277 -0
  44. package/lib/components.sidemenu.5107c7e3.js +1 -0
  45. package/lib/components.sidenavmenu.3d255147.mjs +1147 -0
  46. package/lib/components.sidenavmenu.ef33de39.js +1 -0
  47. package/lib/components.statuschange.805a751b.mjs +116 -0
  48. package/lib/components.statuschange.83646c5d.js +1 -0
  49. package/lib/components.table.61eb5d81.js +8 -0
  50. package/lib/components.table.c986e58d.mjs +4650 -0
  51. package/lib/components.tableumy.35b465f9.mjs +453 -0
  52. package/lib/components.tableumy.eba43953.js +1 -0
  53. package/lib/components.tablevirtual.14a8dbed.mjs +564 -0
  54. package/lib/components.tablevirtual.6af04c44.js +1 -0
  55. package/lib/components.teamsharing.68865424.js +1 -0
  56. package/lib/components.teamsharing.c4f4f12e.mjs +373 -0
  57. package/lib/components.tooltip.ccb1717d.mjs +86 -0
  58. package/lib/components.tooltip.e2e21e66.js +1 -0
  59. package/lib/components.uploadfile.a0dfedaf.mjs +228 -0
  60. package/lib/components.uploadfile.e93b500d.js +1 -0
  61. package/lib/components.uploadimg.3804913e.js +1 -0
  62. package/lib/components.uploadimg.e49707d9.mjs +192 -0
  63. package/lib/components.verificationcode.5a9c0220.js +1 -0
  64. package/lib/components.verificationcode.ead74922.mjs +71 -0
  65. package/lib/components.viewformdetails.3c1596ad.js +1 -0
  66. package/lib/components.viewformdetails.98be3c0d.mjs +1081 -0
  67. package/lib/components.viewloading.5b178ec5.js +1 -0
  68. package/lib/components.viewloading.cb7917b7.mjs +99 -0
  69. package/lib/components.watermark.849409ca.js +2 -0
  70. package/lib/components.watermark.a2521d0c.mjs +53 -0
  71. package/lib/components.xlsxexport.3405a00b.js +1 -0
  72. package/lib/components.xlsxexport.871f87d1.mjs +263 -0
  73. package/lib/components.xlsximport.85ce77cf.mjs +922 -0
  74. package/lib/components.xlsximport.e3bcb07d.js +1 -0
  75. package/lib/copy.b09a6d38.js +1 -0
  76. package/lib/copy.c0a2f16d.mjs +572 -0
  77. package/lib/dialogLayout.059ee256.mjs +138 -0
  78. package/lib/dialogLayout.cedf2865.js +1 -0
  79. package/lib/drawerContainer.38d7b530.mjs +154 -0
  80. package/lib/drawerContainer.ea7722d7.js +1 -0
  81. package/lib/drawerLayout.454e4921.js +1 -0
  82. package/lib/drawerLayout.fad843ee.mjs +119 -0
  83. package/lib/editForm.c199538f.mjs +434 -0
  84. package/lib/editForm.f9dc93ef.js +1 -0
  85. package/lib/flow.designer.4c83c0d3.js +1 -0
  86. package/lib/flow.designer.9442a995.mjs +7673 -0
  87. package/lib/flow.list.4a31969e.mjs +3032 -0
  88. package/lib/flow.list.f41ee531.js +1 -0
  89. package/lib/form.build.c38bf362.js +1 -0
  90. package/lib/form.build.fb9f905b.mjs +259 -0
  91. package/lib/form.designer.build.3fdf8007.js +1 -0
  92. package/lib/form.designer.build.e1b97dc3.mjs +5135 -0
  93. package/lib/formFiled.624b8dd3.js +1 -0
  94. package/lib/formFiled.94fb1dce.mjs +498 -0
  95. package/lib/gd-initial.js +1 -35
  96. package/lib/gd-initial.mjs +233 -91087
  97. package/lib/http.appmanage.9b22ff82.mjs +50 -0
  98. package/lib/http.appmanage.b998818f.js +1 -0
  99. package/lib/http.codegeneratemanage.b123bab3.mjs +120 -0
  100. package/lib/http.codegeneratemanage.e3db2f09.js +1 -0
  101. package/lib/http.configmanage.6cfb8ae7.js +1 -0
  102. package/lib/http.configmanage.c23c7fa8.mjs +34 -0
  103. package/lib/http.currencymanage.37ab5ced.js +1 -0
  104. package/lib/http.currencymanage.c25bd2e6.mjs +10 -0
  105. package/lib/http.datasource.294b01e2.js +1 -0
  106. package/lib/http.datasource.aa5cd0d1.mjs +58 -0
  107. package/lib/http.dictdatamanage.2583b5ae.mjs +42 -0
  108. package/lib/http.dictdatamanage.70545d8a.js +1 -0
  109. package/lib/http.dictmanage.3dc07b5d.js +1 -0
  110. package/lib/http.dictmanage.d8fe18dc.mjs +50 -0
  111. package/lib/http.duplicatechecking.9b79ce21.mjs +50 -0
  112. package/lib/http.duplicatechecking.ee5c414c.js +1 -0
  113. package/lib/http.emailmanage.1ddaa8b5.js +1 -0
  114. package/lib/http.emailmanage.64fd611f.mjs +18 -0
  115. package/lib/http.filedocument.6fdfc693.js +1 -0
  116. package/lib/http.filedocument.d3a4afd9.mjs +293 -0
  117. package/lib/http.filemanage.7e6e3e1a.js +1 -0
  118. package/lib/http.filemanage.c0de21d6.mjs +71 -0
  119. package/lib/http.languagemanage.2ef16159.mjs +10 -0
  120. package/lib/http.languagemanage.e2c098ec.js +1 -0
  121. package/lib/http.loginmanage.05500c29.mjs +74 -0
  122. package/lib/http.loginmanage.326984c3.js +1 -0
  123. package/lib/http.logmanage.1e12a9bd.js +1 -0
  124. package/lib/http.logmanage.8ba72635.mjs +82 -0
  125. package/lib/http.machinemanage.29d72a65.js +1 -0
  126. package/lib/http.machinemanage.7bbe6c16.mjs +26 -0
  127. package/lib/http.main.1af1e119.mjs +517 -0
  128. package/lib/http.main.2f8a6936.js +1 -0
  129. package/lib/http.menumanage.09fffb7d.mjs +66 -0
  130. package/lib/http.menumanage.6d740f2c.js +1 -0
  131. package/lib/http.message.1d68e914.mjs +178 -0
  132. package/lib/http.message.87f319d7.js +1 -0
  133. package/lib/http.noticemanage.2507d094.js +1 -0
  134. package/lib/http.noticemanage.2cdb23b8.mjs +82 -0
  135. package/lib/http.noticereceivedmanage.50797be1.mjs +10 -0
  136. package/lib/http.noticereceivedmanage.e8ec9c9d.js +1 -0
  137. package/lib/http.onlineusermanage.3893f897.js +1 -0
  138. package/lib/http.onlineusermanage.c8d84337.mjs +18 -0
  139. package/lib/http.orgmanage.0b1df8d5.mjs +58 -0
  140. package/lib/http.orgmanage.5162fd7a.js +1 -0
  141. package/lib/http.pluginmanage.54720675.mjs +82 -0
  142. package/lib/http.pluginmanage.6a876040.js +1 -0
  143. package/lib/http.posmanage.c0f80aec.js +1 -0
  144. package/lib/http.posmanage.ee6a7613.mjs +34 -0
  145. package/lib/http.promptmanagement.d115c4b0.js +1 -0
  146. package/lib/http.promptmanagement.dad4c6a7.mjs +42 -0
  147. package/lib/http.rolemanage.4d1101dd.js +1 -0
  148. package/lib/http.rolemanage.da5c40e9.mjs +146 -0
  149. package/lib/http.solution.b10d9197.mjs +91 -0
  150. package/lib/http.solution.c6b2634f.js +1 -0
  151. package/lib/http.sumberrules.0b68ce6d.js +1 -0
  152. package/lib/http.sumberrules.176d3d06.mjs +34 -0
  153. package/lib/http.sysapps.469d47f7.js +1 -0
  154. package/lib/http.sysapps.932ba43b.mjs +58 -0
  155. package/lib/http.syscodegenerateconfigmanage.6d2e5da0.mjs +42 -0
  156. package/lib/http.syscodegenerateconfigmanage.840f1136.js +1 -0
  157. package/lib/http.tabledevelopment.7adf4910.mjs +362 -0
  158. package/lib/http.tabledevelopment.a880bb76.js +1 -0
  159. package/lib/http.team.a9c609d5.mjs +90 -0
  160. package/lib/http.team.e45400d5.js +1 -0
  161. package/lib/http.timersmanage.6e894942.js +1 -0
  162. package/lib/http.timersmanage.c79afb66.mjs +146 -0
  163. package/lib/http.timezonemanage.b9deffe3.mjs +10 -0
  164. package/lib/http.timezonemanage.e0aa212f.js +1 -0
  165. package/lib/http.translationmanage.1f9dce46.js +1 -0
  166. package/lib/http.translationmanage.f8694b51.mjs +104 -0
  167. package/lib/http.useraffiliation.af2013ad.js +1 -0
  168. package/lib/http.useraffiliation.f2a29f92.mjs +90 -0
  169. package/lib/http.usermanage.6dcbc7de.js +1 -0
  170. package/lib/http.usermanage.f5491144.mjs +219 -0
  171. package/lib/http.webresource.1a1a768f.mjs +50 -0
  172. package/lib/http.webresource.7c01b9cd.js +1 -0
  173. package/lib/index.3fa2dc66.mjs +40154 -0
  174. package/lib/index.fe757a98.js +8 -0
  175. package/lib/layoutBlocks.14c77a02.js +1 -0
  176. package/lib/layoutBlocks.5d71a03b.mjs +401 -0
  177. package/lib/layouts.a662f681.js +2 -0
  178. package/lib/layouts.ec4f20a2.mjs +376 -0
  179. package/lib/main.092a2ac8.js +1 -0
  180. package/lib/{main.f0045877.mjs → main.15237e71.mjs} +12 -10
  181. package/lib/main.29769f01.js +1 -0
  182. package/lib/main.401059c6.mjs +189 -0
  183. package/lib/main.447be615.js +1 -0
  184. package/lib/main.4e507685.mjs +231 -0
  185. package/lib/main.72cafa63.mjs +540 -0
  186. package/lib/{main.c41228a0.mjs → main.73f22d9e.mjs} +9 -8
  187. package/lib/main.7601bd3d.mjs +166 -0
  188. package/lib/main.79199ac2.js +1 -0
  189. package/lib/main.821d081b.js +1 -0
  190. package/lib/main.8627466a.mjs +537 -0
  191. package/lib/{main.b5a3be02.mjs → main.88e9be9d.mjs} +4 -4
  192. package/lib/main.8e6f6cba.mjs +323 -0
  193. package/lib/main.a9a54af9.js +1 -0
  194. package/lib/main.e033a376.js +1 -0
  195. package/lib/main.e2e4ba74.js +1 -0
  196. package/lib/{main.3caa11e1.mjs → main.e79d9e56.mjs} +113 -188
  197. package/lib/main.ea3a04f4.js +1 -0
  198. package/lib/main.f44d8279.js +1 -0
  199. package/lib/messages.5f54a62e.js +9 -0
  200. package/lib/{messages.a739f4fc.mjs → messages.d4354532.mjs} +4321 -5268
  201. package/lib/packages.filedocument.8418d852.mjs +4039 -0
  202. package/lib/packages.filedocument.9b8eda0d.js +1 -0
  203. package/lib/page.build.4d28df9a.js +12 -0
  204. package/lib/page.build.78cc7396.mjs +3020 -0
  205. package/lib/personal.echarts.940f1cc9.mjs +696 -0
  206. package/lib/personal.echarts.b5a7f574.js +1 -0
  207. package/lib/result.0161b0e0.js +1 -0
  208. package/lib/result.5a9330d7.mjs +627 -0
  209. package/lib/router.config.79a98ab8.mjs +3105 -0
  210. package/lib/router.config.7fd04c30.js +1 -0
  211. package/lib/solution.application.3ae7c0c5.js +1 -0
  212. package/lib/solution.application.fdc15ffc.mjs +548 -0
  213. package/lib/solution.applicationmenu.67aba620.js +1 -0
  214. package/lib/solution.applicationmenu.daaacb07.mjs +508 -0
  215. package/lib/solution.approvalflow.81b7cfb7.js +1 -0
  216. package/lib/solution.approvalflow.a541adcc.mjs +436 -0
  217. package/lib/solution.dict.addbce33.mjs +769 -0
  218. package/lib/solution.dict.f1c9bae6.js +1 -0
  219. package/lib/solution.menu.2033fa37.mjs +5834 -0
  220. package/lib/solution.menu.6512047f.js +1 -0
  221. package/lib/solution.plugin.7094dbfd.js +1 -0
  222. package/lib/solution.plugin.d8f057cb.mjs +347 -0
  223. package/lib/solution.processflow.0adf4f55.js +1 -0
  224. package/lib/solution.processflow.a779bd58.mjs +392 -0
  225. package/lib/solution.role.d35cb00d.js +1 -0
  226. package/lib/solution.role.d9a4b25a.mjs +456 -0
  227. package/lib/solution.webresources.e1421655.mjs +379 -0
  228. package/lib/solution.webresources.e817757c.js +1 -0
  229. package/lib/solution.workflow.59552b8c.mjs +395 -0
  230. package/lib/solution.workflow.985e1f4d.js +1 -0
  231. package/lib/store.config.556bd56b.js +1 -0
  232. package/lib/store.config.5e5cb48a.mjs +547 -0
  233. package/lib/style.css +3 -3
  234. package/lib/system.account.1b281679.js +216 -0
  235. package/lib/system.account.96d5bc17.mjs +2093 -0
  236. package/lib/system.config.0ff45e62.js +1 -0
  237. package/lib/{system.config.d2ad8c97.mjs → system.config.35b13003.mjs} +7 -6
  238. package/lib/system.datasource.4243937d.js +1 -0
  239. package/lib/{system.datasource.a77831ab.mjs → system.datasource.7f582bef.mjs} +15 -64
  240. package/lib/{system.dict.cb276470.mjs → system.dict.3697546d.mjs} +269 -344
  241. package/lib/system.dict.8e4fe6b0.js +1 -0
  242. package/lib/system.document.69e534a6.js +1 -0
  243. package/lib/system.document.8e4dbe5e.mjs +667 -0
  244. package/lib/system.duplicatechecking.1083eb1e.js +1 -0
  245. package/lib/system.duplicatechecking.c6a8b2b7.mjs +722 -0
  246. package/lib/system.email.06bb7cc1.mjs +133 -0
  247. package/lib/system.email.41036a31.js +1 -0
  248. package/lib/system.fieldsecurity.3ea880d8.js +1 -0
  249. package/lib/{system.fieldsecurity.9d40595f.mjs → system.fieldsecurity.dd504643.mjs} +486 -938
  250. package/lib/{system.file.8064c8e9.mjs → system.file.8ccc4569.mjs} +84 -151
  251. package/lib/system.file.b8e4e6a1.js +1 -0
  252. package/lib/system.log.14c22a7a.js +1 -0
  253. package/lib/{system.log.2b2fc11a.mjs → system.log.aad4ff54.mjs} +31 -93
  254. package/lib/system.machine.379beacb.js +1 -0
  255. package/lib/{system.machine.0130e762.mjs → system.machine.c47be0cc.mjs} +5 -25
  256. package/lib/{system.notice.5f8cd020.mjs → system.notice.dc1b67cc.mjs} +1075 -1255
  257. package/lib/system.notice.fb151c45.js +1 -0
  258. package/lib/system.noticereceived.3a29d891.js +1 -0
  259. package/lib/{system.noticereceived.51b6353a.mjs → system.noticereceived.e75bf358.mjs} +19 -27
  260. package/lib/{system.onlineuser.c0a69360.mjs → system.onlineuser.ab9c2776.mjs} +36 -38
  261. package/lib/system.onlineuser.fc26aff9.js +1 -0
  262. package/lib/system.org.b6f826e8.js +1 -0
  263. package/lib/{system.org.1169fe47.mjs → system.org.dd710a91.mjs} +3 -3
  264. package/lib/system.permissions.75406743.mjs +972 -0
  265. package/lib/system.permissions.97f68887.js +1 -0
  266. package/lib/system.plugin.3fcf7b0b.js +1 -0
  267. package/lib/{system.plugin.502a69d8.mjs → system.plugin.4b80cd95.mjs} +503 -552
  268. package/lib/system.pos.5a1663d8.js +1 -0
  269. package/lib/{system.pos.8c44c029.mjs → system.pos.a3bafaaa.mjs} +31 -62
  270. package/lib/system.promptmanagement.53c301a3.js +1 -0
  271. package/lib/{system.promptmanagement.d8565db4.mjs → system.promptmanagement.fd651c09.mjs} +318 -449
  272. package/lib/{system.role.19959d7f.mjs → system.role.9edb5922.mjs} +512 -486
  273. package/lib/system.role.e164f059.js +1 -0
  274. package/lib/{system.sumberrules.087015a4.mjs → system.sumberrules.4bb2c95c.mjs} +169 -192
  275. package/lib/system.sumberrules.5e9cd262.js +1 -0
  276. package/lib/system.team.3e605266.js +1 -0
  277. package/lib/system.team.bb1fb40e.mjs +452 -0
  278. package/lib/system.teammembers.a098883b.js +1 -0
  279. package/lib/{system.teammembers.4056d586.mjs → system.teammembers.b8e53d99.mjs} +257 -199
  280. package/lib/system.timers.2f884e41.js +38 -0
  281. package/lib/{system.timers.6f61bfe1.mjs → system.timers.551c4a4b.mjs} +2202 -2278
  282. package/lib/system.translation.6e99c852.js +1 -0
  283. package/lib/{system.translation.9b88fbf2.mjs → system.translation.c2c1f40c.mjs} +437 -431
  284. package/lib/{system.user.bdf2613e.mjs → system.user.b99911de.mjs} +1082 -1025
  285. package/lib/system.user.dffc2543.js +14 -0
  286. package/lib/{system.useraffiliation.63b6bb36.mjs → system.useraffiliation.12cae7ef.mjs} +419 -412
  287. package/lib/system.useraffiliation.f8b33def.js +1 -0
  288. package/lib/system.webresource.1d3ed352.js +1 -0
  289. package/lib/{system.webresource.c36d6792.mjs → system.webresource.8a8d856b.mjs} +177 -219
  290. package/lib/{system.welcome.14785b50.mjs → system.welcome.573a76db.mjs} +10 -3
  291. package/lib/system.welcome.eedf1db2.js +1 -0
  292. package/lib/tableDescriptions.923c4ef1.mjs +80 -0
  293. package/lib/tableDescriptions.b12679b0.js +1 -0
  294. package/lib/tcheckboxs.887d733c.mjs +52 -0
  295. package/lib/tcheckboxs.fe7e574a.js +1 -0
  296. package/lib/tcurrency.10ac9aa7.mjs +85 -0
  297. package/lib/tcurrency.20e959c0.js +1 -0
  298. package/lib/tdatepicker.54036bba.js +1 -0
  299. package/lib/tdatepicker.a08ad382.mjs +52 -0
  300. package/lib/tdictSwitch.274e9f86.js +1 -0
  301. package/lib/tdictSwitch.d40f1b4f.mjs +60 -0
  302. package/lib/tfile.5c897827.js +1 -0
  303. package/lib/tfile.f63b73b9.mjs +62 -0
  304. package/lib/tparticipants.4698962b.mjs +56 -0
  305. package/lib/tparticipants.b6fb4545.js +1 -0
  306. package/lib/translation.mains.5cfc7a2f.js +1 -0
  307. package/lib/translation.mains.e6cb610b.mjs +383 -0
  308. package/lib/utils.datepicker.js.0a5a699e.js +1 -0
  309. package/lib/utils.datepicker.js.5549a741.mjs +70 -0
  310. package/lib/utils.echarts.js.461a74e7.js +54 -0
  311. package/lib/utils.echarts.js.d1bb8ac6.mjs +25711 -0
  312. package/lib/utils.mixins.js.750ca50e.js +1 -0
  313. package/lib/utils.mixins.js.be01e599.mjs +41 -0
  314. package/lib/utils.plug.js.9313aead.mjs +31 -0
  315. package/lib/utils.plug.js.f62510ce.js +1 -0
  316. package/lib/utils.util.js.885de913.mjs +439 -0
  317. package/lib/utils.util.js.c0ba699b.js +1 -0
  318. package/lib/view.build.051553d8.mjs +1578 -0
  319. package/lib/view.build.9af3087b.js +1 -0
  320. package/lib/viewList.209956c3.js +1 -0
  321. package/lib/viewList.c05c92be.mjs +318 -0
  322. package/lib/viewTree.0cd9f1a2.js +1 -0
  323. package/lib/viewTree.c5290360.mjs +409 -0
  324. package/locale/en_US.js +92 -28
  325. package/locale/id_ID.js +76 -12
  326. package/locale/vi_VN.js +2012 -1948
  327. package/locale/zh_CN.js +97 -33
  328. package/package.json +106 -105
  329. package/lib/chartbi.114d32d7.js +0 -60
  330. package/lib/chartbi.eb4dd0af.mjs +0 -27639
  331. package/lib/main.03984fed.js +0 -1
  332. package/lib/main.1050afb3.js +0 -1
  333. package/lib/main.64122541.js +0 -1
  334. package/lib/main.b7d2c6ee.js +0 -1
  335. package/lib/messages.828b6ed8.js +0 -9
  336. package/lib/system.account.3181bcd6.js +0 -216
  337. package/lib/system.account.7c6ea20c.mjs +0 -2552
  338. package/lib/system.config.10f57fa2.js +0 -1
  339. package/lib/system.datasource.d5eea7f2.js +0 -1
  340. package/lib/system.dict.d73658f1.js +0 -1
  341. package/lib/system.duplicatechecking.5c8a3eef.mjs +0 -2142
  342. package/lib/system.duplicatechecking.d24ba6ea.js +0 -1
  343. package/lib/system.email.4bf52f2d.js +0 -41
  344. package/lib/system.email.db5da8d7.mjs +0 -7432
  345. package/lib/system.fieldsecurity.eb217079.js +0 -1
  346. package/lib/system.file.c1884db7.js +0 -1
  347. package/lib/system.log.389af80d.js +0 -1
  348. package/lib/system.machine.49fc6405.js +0 -1
  349. package/lib/system.notice.a89f4826.js +0 -1
  350. package/lib/system.noticereceived.5e0773c3.js +0 -1
  351. package/lib/system.onlineuser.67733846.js +0 -1
  352. package/lib/system.org.ff54d620.js +0 -1
  353. package/lib/system.permissions.cc9a9866.mjs +0 -212
  354. package/lib/system.permissions.e6317c5a.js +0 -9
  355. package/lib/system.plugin.3467d572.js +0 -1
  356. package/lib/system.pos.4aadf86e.js +0 -1
  357. package/lib/system.promptmanagement.9ba710d6.js +0 -1
  358. package/lib/system.role.890c8ca2.js +0 -1
  359. package/lib/system.sumberrules.068ebe4a.js +0 -1
  360. package/lib/system.team.27cd57f7.mjs +0 -1000
  361. package/lib/system.team.2b28502b.js +0 -1
  362. package/lib/system.teammembers.e3baf783.js +0 -1
  363. package/lib/system.timers.cb0a3bd0.js +0 -38
  364. package/lib/system.translation.f3884a0a.js +0 -1
  365. package/lib/system.user.3bd95871.js +0 -14
  366. package/lib/system.useraffiliation.7db6e13c.js +0 -1
  367. package/lib/system.webresource.ede248a8.js +0 -1
  368. package/lib/system.welcome.c9eefa06.js +0 -1
@@ -0,0 +1,4039 @@
1
+ import { n as d, m as u } from "./components.chartbi.470b96af.mjs";
2
+ import { s as A, a as B, g as f, b as E, c as M, d as K, e as R, f as V, h as P, i as q, j as I, k as H, l as _, m as U, n as $, o as J, p as W, q as Q, r as G, t as X, u as Y, v as Z, w as ee, x as te, y as ie, z as se, A as re } from "./http.filedocument.d3a4afd9.mjs";
3
+ import { U as N } from "./components.uploadfile.a0dfedaf.mjs";
4
+ import { a as ae } from "./http.main.1af1e119.mjs";
5
+ function ne(t, e = !1) {
6
+ let i = "";
7
+ for (let s in t)
8
+ i += Fe(t, s, e);
9
+ return i;
10
+ }
11
+ function le(t) {
12
+ let e = [];
13
+ return (t.padding ? t.padding : []).forEach((s) => {
14
+ e.push(s ? `${s}px` : 0);
15
+ }), e.length === 0 ? "" : `padding:${e.join(" ")};`;
16
+ }
17
+ function oe(t) {
18
+ let e = [];
19
+ return (t.margin ? t.margin : []).forEach((s) => {
20
+ e.push(s ? `${s}px` : 0);
21
+ }), e.length === 0 ? "" : `margin:${e.join(" ")};`;
22
+ }
23
+ function ce(t) {
24
+ const e = t.bjColor ? t.bjColor : "";
25
+ return e === "" ? "" : `background-color:${e};`;
26
+ }
27
+ function de(t) {
28
+ let e = [];
29
+ return (t.radius ? t.radius : []).forEach((s) => {
30
+ e.push(s ? `${s}px` : 0);
31
+ }), e.length === 0 ? "" : `border-radius:${e.join(" ")};`;
32
+ }
33
+ function ue(t) {
34
+ const e = t.align ? t.align : "";
35
+ return e === "" ? "" : `text-align:${e};`;
36
+ }
37
+ function he(t) {
38
+ const e = t.lineHeight ? t.lineHeight : "";
39
+ return e === "" ? "" : `line-height:${e}px;`;
40
+ }
41
+ function pe(t) {
42
+ const e = t.letterSpacing ? t.letterSpacing : "";
43
+ return e === "" ? "" : `letter-spacing:${e}px;`;
44
+ }
45
+ function fe(t) {
46
+ if (t.color === "0")
47
+ return "color:var(--color);";
48
+ const e = t.color ? t.color : "";
49
+ return e === "" ? "" : `color:${e};`;
50
+ }
51
+ function me(t) {
52
+ const e = t.fontSize ? t.fontSize : "";
53
+ return e === "" ? "" : `font-size:${e}px;`;
54
+ }
55
+ function ge(t) {
56
+ const e = t.fontWeight ? t.fontWeight : "";
57
+ return e === "" ? "" : `font-weight:${e};`;
58
+ }
59
+ function ve(t) {
60
+ const e = t.textDecoration ? t.textDecoration : "";
61
+ return e === "" ? "" : `text-decoration:${e};`;
62
+ }
63
+ function ye(t) {
64
+ const e = t.fontStyle ? t.fontStyle : "";
65
+ return e === "" ? "" : `font-style:${e};`;
66
+ }
67
+ function be(t) {
68
+ const e = t.maxLineClamp ? t.maxLineClamp : "";
69
+ return e === "" ? "" : `overflow: hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-line-clamp: ${e};-webkit-box-orient: vertical;`;
70
+ }
71
+ function _e(t, e = !1) {
72
+ const i = t.flexWidth ? t.flexWidth : "100", s = t.flexUnit ? t.flexUnit : "%", r = s === "%" ? i > 100 ? 100 : i : s === "auto" ? "" : i;
73
+ return e && `${r}${s}` == "100%" ? "flex:1;" : `width:${r}${s};`;
74
+ }
75
+ function $e(t) {
76
+ const e = t.flexDirection ? t.flexDirection : "";
77
+ return e === "" ? "" : `flex-direction:${e};`;
78
+ }
79
+ function Ce(t) {
80
+ const e = t.justifyContent ? t.justifyContent : "";
81
+ return e === "" ? "" : `justify-content:${e};`;
82
+ }
83
+ function De(t) {
84
+ const e = t.alignItems ? t.alignItems : "";
85
+ return e === "" ? "" : `align-items:${e};`;
86
+ }
87
+ function we(t) {
88
+ const e = t.flexWrap ? t.flexWrap : "";
89
+ return e === "" ? "" : `flex-wrap:${e};`;
90
+ }
91
+ function ke(t) {
92
+ const e = t.spacing ? t.spacing : "";
93
+ return e === "" ? "" : `gap:${e}px;`;
94
+ }
95
+ function Fe(t, e, i) {
96
+ switch (e) {
97
+ case "padding":
98
+ return le(t);
99
+ case "margin":
100
+ return oe(t);
101
+ case "bjColor":
102
+ return ce(t);
103
+ case "radius":
104
+ return de(t);
105
+ case "align":
106
+ return ue(t);
107
+ case "lineHeight":
108
+ return he(t);
109
+ case "letterSpacing":
110
+ return pe(t);
111
+ case "color":
112
+ return fe(t);
113
+ case "fontSize":
114
+ return me(t);
115
+ case "fontWeight":
116
+ return ge(t);
117
+ case "textDecoration":
118
+ return ve(t);
119
+ case "fontStyle":
120
+ return ye(t);
121
+ case "maxLineClamp":
122
+ return be(t);
123
+ case "flexWidth":
124
+ return _e(t, i);
125
+ case "flexDirection":
126
+ return $e(t);
127
+ case "justifyContent":
128
+ return Ce(t);
129
+ case "alignItems":
130
+ return De(t);
131
+ case "flexWrap":
132
+ return we(t);
133
+ case "spacing":
134
+ return ke(t);
135
+ default:
136
+ return "";
137
+ }
138
+ }
139
+ function x(t, e, i) {
140
+ t && t.forEach((s) => {
141
+ if (s.parentid == i) {
142
+ const r = {
143
+ ...s,
144
+ children: []
145
+ };
146
+ x(t, r.children, s.id), r.children.length <= 0 && delete r.children, e.push(r);
147
+ }
148
+ });
149
+ }
150
+ const h = [
151
+ {
152
+ name: "\u67E5\u770B",
153
+ code: "readmetadata",
154
+ transkey: "gd.btn.view",
155
+ allow: !1,
156
+ refuse: !1,
157
+ field: "readmetadata",
158
+ icon: "gd-icon-xitongrizhi7",
159
+ show: !0,
160
+ type: []
161
+ },
162
+ {
163
+ name: "\u91CD\u547D\u540D",
164
+ code: "rename",
165
+ transkey: "gd.btn.rename",
166
+ allow: !1,
167
+ refuse: !1,
168
+ field: "rename",
169
+ icon: "gd-icon-bianjisekuai",
170
+ show: !0,
171
+ type: [1, 2]
172
+ },
173
+ {
174
+ name: "\u5220\u9664",
175
+ code: "delete",
176
+ transkey: "gd.btn.del",
177
+ allow: !1,
178
+ refuse: !1,
179
+ field: "delete",
180
+ icon: "gd-icon-shanchu3",
181
+ show: !0,
182
+ type: [1, 2]
183
+ },
184
+ {
185
+ name: "\u79FB\u52A8",
186
+ code: "move",
187
+ transkey: "gd.btn.move",
188
+ allow: !1,
189
+ refuse: !1,
190
+ field: "move",
191
+ icon: "el-icon-rank",
192
+ show: !0,
193
+ type: [1, 2]
194
+ },
195
+ {
196
+ name: "\u4E0B\u8F7D",
197
+ code: "download",
198
+ transkey: "gd.btn.download",
199
+ allow: !1,
200
+ refuse: !1,
201
+ field: "download",
202
+ icon: "gd-icon-icon-test14",
203
+ show: !0,
204
+ type: [2]
205
+ },
206
+ {
207
+ name: "\u521B\u5EFA\u6587\u4EF6",
208
+ code: "createfile",
209
+ transkey: "gd.btn.createfile",
210
+ allow: !1,
211
+ refuse: !1,
212
+ field: "createfile",
213
+ icon: "el-icon-document",
214
+ show: !0,
215
+ type: [1]
216
+ },
217
+ {
218
+ name: "\u521B\u5EFA\u6587\u4EF6\u5939",
219
+ code: "createsubfolder",
220
+ transkey: "gd.btn.createSubfolders",
221
+ allow: !1,
222
+ refuse: !1,
223
+ field: "createsubfolder",
224
+ icon: "el-icon-folder-add",
225
+ show: !0,
226
+ type: [1]
227
+ },
228
+ {
229
+ name: "\u7BA1\u7406\u6743\u9650",
230
+ code: "manageprem",
231
+ transkey: "gd.btn.administrativePermissions",
232
+ allow: !1,
233
+ refuse: !1,
234
+ field: "manageprem",
235
+ icon: "gd-icon-12quanxianguanli",
236
+ show: !0,
237
+ type: [1, 2]
238
+ }
239
+ ];
240
+ function F(t) {
241
+ if (!t)
242
+ return [];
243
+ if (typeof t != "object")
244
+ return [];
245
+ let e = [];
246
+ for (let i in t)
247
+ t[i] === 1 && e.push(i);
248
+ return e;
249
+ }
250
+ function xe(t) {
251
+ const e = h.filter((i) => i.code === t)[0];
252
+ return e ? e.field : t;
253
+ }
254
+ function L(t) {
255
+ if (t.type === 1)
256
+ return "gd-icon-wenjianjia-shouqi";
257
+ let e = "gd-icon-GIF1";
258
+ return ["gif", "jpeg", "png", "jpg", "JPG", "PNG", "bmp", "BMP"].includes(t.filetype) ? e = "gd-icon-img" : ["xml"].includes(t.filetype) ? e = "gd-icon-XML" : ["html"].includes(t.filetype) ? e = "gd-icon-Html" : ["txt"].includes(t.filetype) ? e = "gd-icon-txt-full" : ["pptx"].includes(t.filetype) ? e = "gd-icon-office-pptx" : ["pdf"].includes(t.filetype) ? e = "gd-icon-file-pdf" : ["docx", "doc", "dot"].includes(t.filetype) ? e = "gd-icon-DOCX" : ["xlsx", "xls", "excel"].includes(t.filetype) ? e = "gd-icon-xlsx_2x" : (["mp3"].includes(t.filetype) || ["mp4"].includes(t.filetype)) && (e = "gd-icon-mp3"), e;
259
+ }
260
+ function O(t) {
261
+ if (t.type === 1)
262
+ return "";
263
+ let e = t.filesize / 1024;
264
+ return e < 1024 ? `${Math.ceil(e)}K` : `${(t.filesize / 1024 / 1024).toFixed(2)}M`;
265
+ }
266
+ function Le(t, e) {
267
+ const i = new RegExp(e, "gi");
268
+ return t.replace(i, (s) => `<span class="active-color">${s}</span>`);
269
+ }
270
+ function C(t, {
271
+ rulesInput: e,
272
+ rulesSelect: i
273
+ }) {
274
+ let s = [...e];
275
+ return ["fk", "datepicker", "select", "radio", "checkbox"].includes(t.datatype) ? s = [...i] : ["inputnumber", "double"].includes(t.datatype) && (s[0] = Object.assign({}, s[0], {
276
+ type: "number"
277
+ })), s;
278
+ }
279
+ function D(t, e) {
280
+ if (!["datepicker"].includes(t.datatype))
281
+ return "";
282
+ const i = p(t, e);
283
+ let s = "date";
284
+ return i === "yyyy-MM-dd hh:mm:ss" || i === "yyyy-MM-dd HH:mm:ss" ? s = "datetime" : i === "yyyy-MM" ? s = "month" : i === "yyyy" && (s = "year"), s;
285
+ }
286
+ function p(t, e) {
287
+ if (!["datepicker"].includes(t.datatype))
288
+ return "";
289
+ const i = e.filter((s) => String(s.code) === String(t.fieldformat))[0];
290
+ return i ? i.name.replace("DD", "dd") : "yyyy-MM-dd HH:mm:ss";
291
+ }
292
+ function w(t) {
293
+ return ["inputnumber", "double"].includes(t.datatype) ? t.defaultvalue !== "" && t.defaultvalue !== null ? t.defaultvalue : void 0 : ["checkbox"].includes(t.datatype) ? t.defaultvalue ? t.defaultvalue.split(",") : [] : t.defaultvalue;
294
+ }
295
+ function k(t, e) {
296
+ return ["datepicker"].includes(t.datatype) ? !["hh:mm:ss", "hh:mm", "mm:ss", "HH:mm:ss", "HH:mm"].includes(p(t, e)) : !1;
297
+ }
298
+ const Te = {
299
+ props: {
300
+ collapse: {
301
+ type: Boolean,
302
+ default: !1
303
+ }
304
+ },
305
+ data() {
306
+ return {
307
+ propsData: {
308
+ label: "name",
309
+ children: "children",
310
+ isLeaf: "isLeaf"
311
+ },
312
+ defaultExpandedKeys: "",
313
+ id: 0,
314
+ confirmLoading: !1,
315
+ noData: !1,
316
+ treeData: [],
317
+ expandedKeys: [],
318
+ userPermission: [],
319
+ rootData: {}
320
+ };
321
+ },
322
+ computed: {
323
+ createSubfolder() {
324
+ return "createsubfolder";
325
+ }
326
+ },
327
+ methods: {
328
+ getPermissionItem: xe,
329
+ rootAttribute() {
330
+ this.$emit("seeAttribute", this.rootData);
331
+ },
332
+ selPopoverOpen(t) {
333
+ const e = this.expandedKeys.filter((i) => i !== t.id);
334
+ this.expandedKeys = e.concat([t.id]), this.$refs.tree.setCurrentKey(t.id);
335
+ },
336
+ setExpandKey(t) {
337
+ if (this.expandedKeys = t, t.length === 0) {
338
+ this.$refs.tree.setCurrentKey(null), this.id = 0, this.defaultExpandedKeys = "";
339
+ return;
340
+ }
341
+ const e = t[t.length - 1];
342
+ this.id = e, this.defaultExpandedKeys = e, this.$refs.tree.setCurrentKey(e);
343
+ },
344
+ handleExpand(t, e, i) {
345
+ this.expandedKeys = this.expandedKeys.concat([t.id]);
346
+ },
347
+ handleCollapse(t) {
348
+ let e = [t.id];
349
+ const i = (s) => (s = s.filter((r) => (e.push(r.id), r.children && i(r.children), !0)), s);
350
+ i(t.children), this.expandedKeys = this.expandedKeys.filter((s) => !e.includes(s));
351
+ },
352
+ refresh() {
353
+ this.confirmLoading || this.init();
354
+ },
355
+ createFile() {
356
+ this.$emit("createFile", { type: "tree", data: null });
357
+ },
358
+ doClose() {
359
+ this.$emit("doClose");
360
+ },
361
+ handleContextmenu(t, e) {
362
+ this.$emit("nodeContextmenu", t, e);
363
+ },
364
+ handleNodeClick(t) {
365
+ this.id = t.id, this.doClose(), this.$emit("handleNodeClick", t);
366
+ },
367
+ init() {
368
+ this.confirmLoading = !0, Promise.all([this.getAllDoc(), this.getUserDoc(), this.getRootPermission()]).then((t) => {
369
+ this.noData = this.treeData.length === 0, this.confirmLoading = !1;
370
+ });
371
+ },
372
+ getUserDoc() {
373
+ return A({}).then((t) => {
374
+ if (t.code === 200) {
375
+ const e = t.data.filter((r) => r.type === 1), i = t.data.filter((r) => r.id === 0)[0];
376
+ this.rootData = i || { id: 0 }, this.$emit("treeData", e);
377
+ let s = [];
378
+ x(e, s, 0), this.treeData = s, this.$emit("treeMenusData", s);
379
+ } else
380
+ this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + t.message);
381
+ return t;
382
+ });
383
+ },
384
+ getAllDoc() {
385
+ B({ docId: 0 }).then((t) => (t.code === 200 && this.$emit("treeDataAll", t.data), t));
386
+ },
387
+ getRootPermission() {
388
+ f({ docId: 0 }).then((t) => {
389
+ t.code === 200 && (this.userPermission = F(t.data));
390
+ });
391
+ },
392
+ handleContextmenupopover(t) {
393
+ return t.preventDefault(), !1;
394
+ }
395
+ },
396
+ created() {
397
+ this.init();
398
+ }
399
+ };
400
+ var Se = function() {
401
+ var e = this, i = e._self._c;
402
+ return i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }], staticClass: "document-tree", on: { contextmenu: function(s) {
403
+ return s.stopPropagation(), s.preventDefault(), e.handleContextmenupopover(s);
404
+ } } }, [i("div", { directives: [{ name: "show", rawName: "v-show", value: !e.collapse, expression: "!collapse" }], staticClass: "document-tree-menu" }, [e.userPermission.includes(e.getPermissionItem("createsubfolder")) ? i("el-tooltip", { directives: [{ name: "delTabIndex", rawName: "v-delTabIndex" }], staticClass: "item", attrs: { effect: "dark", content: e.$i18nt("gd.btn.createSubfolders", "\u521B\u5EFA\u5B50\u6587\u4EF6\u5939"), placement: "bottom" } }, [i("i", { staticClass: "gd-icons el-icon-plus", on: { click: e.createFile } })]) : e._e(), i("el-tooltip", { directives: [{ name: "delTabIndex", rawName: "v-delTabIndex" }], staticClass: "item", attrs: { effect: "dark", content: e.$i18nt("gd.basics.refresh", "\u5237\u65B0"), placement: "bottom" } }, [i("i", { staticClass: "gd-icons el-icon-refresh", on: { click: e.refresh } })]), i("el-tooltip", { directives: [{ name: "delTabIndex", rawName: "v-delTabIndex" }], staticClass: "item", attrs: { effect: "dark", content: e.$i18nt("gd.form.attribute", "\u5C5E\u6027"), placement: "bottom" } }, [i("i", { staticClass: "gd-icons el-icon-info", on: { click: e.rootAttribute } })])], 1), i("div", { directives: [{ name: "show", rawName: "v-show", value: !e.collapse, expression: "!collapse" }], staticClass: "document-tree-list" }, [i("el-tree", { ref: "tree", attrs: { data: e.treeData, props: e.propsData, "node-key": "id", "current-node-key": e.defaultExpandedKeys, "highlight-current": "", "expand-on-click-node": !1, "default-expanded-keys": e.expandedKeys }, on: { "node-click": e.handleNodeClick, "node-contextmenu": e.handleContextmenu, "node-expand": e.handleExpand, "node-collapse": e.handleCollapse }, scopedSlots: e._u([{ key: "default", fn: function({ node: s, data: r }) {
405
+ return i("div", { staticClass: "document-tree-node" }, [i("div", { staticClass: "tree-node-label line1", attrs: { title: s.label } }, [i("i", { staticClass: "gd-icon-wenjianjia-shouqi gd-icons wenjianjia-shouqi" }), e._v(" " + e._s(s.label) + " ")])]);
406
+ } }]) })], 1), e.noData ? i("div", { staticClass: "document-tree-creat" }, [i("i", { staticClass: "el-icon-receiving" }), i("div", { staticClass: "tip" }, [e._v(e._s(e.$i18nt("gd.fileDocument.noFilesTip", "~\u8FD8\u6CA1\u6709\u6587\u4EF6~")))]), e.userPermission.includes(e.getPermissionItem("createsubfolder")) ? i("div", { staticClass: "handle" }, [i("span", [e._v(e._s(e.$i18nt("gd.fileDocument.fast", "\u5FEB\u901F")))]), i("el-divider", { attrs: { direction: "vertical" } }), i("span", { staticClass: "active-color", staticStyle: { cursor: "pointer" }, on: { click: e.createFile } }, [e._v(" " + e._s(e.$i18nt("gd.btn.createSubfolders", "\u521B\u5EFA\u5B50\u6587\u4EF6\u5939")) + " ")])], 1) : e._e()]) : e._e(), i("div", { staticClass: "collapse-bar", on: { click: function(s) {
407
+ return e.$emit("collapseBar");
408
+ } } }, [i("i", { class: e.collapse ? "el-icon-d-arrow-right" : "el-icon-d-arrow-left" })])]);
409
+ }, Pe = [], Ie = /* @__PURE__ */ d(
410
+ Te,
411
+ Se,
412
+ Pe,
413
+ !1,
414
+ null,
415
+ "b43ff01e",
416
+ null,
417
+ null
418
+ );
419
+ const Ne = Ie.exports;
420
+ const Oe = {
421
+ props: {
422
+ recordData: {
423
+ type: Object,
424
+ default: () => {
425
+ }
426
+ },
427
+ treeData: {
428
+ type: Array,
429
+ default: () => []
430
+ }
431
+ },
432
+ data() {
433
+ return {
434
+ left: 0,
435
+ top: 0,
436
+ contextMenuVisible: !1,
437
+ hasRight: !1,
438
+ hasBottom: !0,
439
+ rightMenus: [],
440
+ rightLoad: !1,
441
+ statu: !1,
442
+ selItem: {}
443
+ };
444
+ },
445
+ computed: {
446
+ getPermissionList() {
447
+ return this.recordData.permissionList !== void 0 ? this.recordData.permissionList : h;
448
+ },
449
+ popperClass() {
450
+ let t = "";
451
+ return this.hasRight && (t += "contextmenu-right "), this.hasBottom && (t += "contextmenu-btom "), t;
452
+ },
453
+ ...u(["screenWidth", "screenHeight"])
454
+ },
455
+ methods: {
456
+ handleContextmenu(t, e) {
457
+ this.statu || (this.contextMenuVisible = !1, this.rightMenus = [], this.statu = !0, this.hasRight = this.screenWidth - t.clientX < 170, this.hasBottom = this.screenHeight - t.clientY < 170, this.selItem = e, this.$emit("doClose"), this.$nextTick(() => {
458
+ this.contextMenuVisible = !0, setTimeout(() => {
459
+ const i = this.$refs.dropdown;
460
+ this.left = t.clientX - 16, this.top = t.clientY - 20, i && i.doShow();
461
+ }, 0), setTimeout(() => {
462
+ this.statu = !1;
463
+ }, 500);
464
+ }), this.getRootPermission(e));
465
+ },
466
+ getRootPermission(t) {
467
+ return this.rightLoad = !0, f({ docId: t.id }).then((e) => {
468
+ if (e.code === 200) {
469
+ const i = F(e.data), s = this.getPermissionList.filter((n) => n.type.includes(t.type)), a = (t.type === 1 ? [] : [
470
+ {
471
+ name: "\u9884\u89C8",
472
+ code: "readmetadata",
473
+ transkey: "gd.btn.preview",
474
+ field: "readmetadata",
475
+ icon: "gd-icon-kejian",
476
+ type: [2],
477
+ transtype: "customize"
478
+ }
479
+ ]).concat(s).filter((n) => i.includes(n.code));
480
+ this.rightMenus = a;
481
+ }
482
+ return this.rightLoad = !1, e;
483
+ });
484
+ },
485
+ seeAttribute(t) {
486
+ this.$emit("seeAttribute", t);
487
+ },
488
+ versionControl(t) {
489
+ this.$emit("versionControl", t);
490
+ },
491
+ doClose() {
492
+ this.selItem.id !== void 0 && this.$nextTick(() => {
493
+ const t = this.$refs.dropdown;
494
+ t && t.doClose();
495
+ });
496
+ },
497
+ selPopover(t, e) {
498
+ this.doClose(), this.$emit("selPopover", t, e);
499
+ },
500
+ selPopoverOpen(t) {
501
+ if (this.doClose(), this.$emit("doClose"), t.type === 1) {
502
+ this.init(t), this.$emit("selPopoverOpen", t);
503
+ return;
504
+ }
505
+ this.$emit("selPopover", t, "readmetadata");
506
+ },
507
+ handleContextmenupopover(t) {
508
+ return t.preventDefault(), !1;
509
+ }
510
+ }
511
+ };
512
+ var je = function() {
513
+ var e = this, i = e._self._c;
514
+ return e.contextMenuVisible ? i("div", { staticClass: "contextmenu contextmenu-fixed", style: { left: e.left + "px", top: e.top + "px" } }, [i("el-popover", { ref: "dropdown", attrs: { placement: "right", trigger: "hover", "popper-class": e.popperClass } }, [i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.rightLoad, expression: "rightLoad" }], staticClass: "selectionl-popover", on: { contextmenu: function(s) {
515
+ return s.stopPropagation(), s.preventDefault(), e.handleContextmenupopover(s);
516
+ } } }, [e._l(e.rightMenus, function(s) {
517
+ return [i("div", { staticClass: "popover-item", on: { click: function(r) {
518
+ return e.selPopover(e.selItem, s.code);
519
+ } } }, [i("i", { staticClass: "gd-icons", class: s.icon }), e._v(" " + e._s(e.$i18nt(s.transkey, s.name)) + " ")])];
520
+ }), !e.rightLoad && e.rightMenus.length === 0 ? i("div", { staticClass: "no-menus" }, [i("i", { staticClass: "el-icon-receiving" }), i("div", { staticClass: "tip" }, [e._v(e._s(e.$i18nt("gd.page.temporarilyAuthority", "\u6682\u65E0\u6743\u9650")))])]) : e._e(), e.rightLoad ? e._e() : [i("div", { staticStyle: { padding: "0 6px" } }, [i("el-divider")], 1), e.selItem.type === 2 ? i("div", { staticClass: "popover-item", on: { click: function(s) {
521
+ return e.versionControl(e.selItem);
522
+ } } }, [i("i", { staticClass: "gd-icons gd-icon-banbenguanli" }), e._v(" " + e._s(e.$i18nt("gd.application.version", "\u7248\u672C")) + " ")]) : e._e(), i("div", { staticClass: "popover-item", on: { click: function(s) {
523
+ return e.seeAttribute(e.selItem);
524
+ } } }, [i("i", { staticClass: "gd-icons el-icon-info" }), e._v(" " + e._s(e.$i18nt("gd.form.attribute", "\u5C5E\u6027")) + " ")])]], 2)])], 1) : e._e();
525
+ }, ze = [], Ae = /* @__PURE__ */ d(
526
+ Oe,
527
+ je,
528
+ ze,
529
+ !1,
530
+ null,
531
+ "4c2b23e4",
532
+ null,
533
+ null
534
+ );
535
+ const j = Ae.exports;
536
+ var v = null, y = null;
537
+ const Be = {
538
+ props: {
539
+ recordData: {
540
+ type: Object,
541
+ default: () => {
542
+ }
543
+ },
544
+ treeData: {
545
+ type: Array,
546
+ default: () => []
547
+ }
548
+ },
549
+ components: { ContextMenu: j },
550
+ data() {
551
+ return {
552
+ moverShow: !1,
553
+ seachPath: "",
554
+ hig: 200,
555
+ record: {},
556
+ total: 100,
557
+ pageSized: 10,
558
+ currentPage: 1,
559
+ mode: "grid",
560
+ selItem: {},
561
+ statu: !1,
562
+ showBtn: !0,
563
+ operationType: "single",
564
+ tableColumns: [
565
+ {
566
+ type: "selection",
567
+ width: "60",
568
+ checked: !1
569
+ },
570
+ {
571
+ transKey: "gd.translation.name",
572
+ prop: "name",
573
+ label: "\u540D\u79F0",
574
+ align: "left",
575
+ checked: !0,
576
+ width: "320",
577
+ sortable: "custom"
578
+ },
579
+ {
580
+ transKey: "gd.file.fileAccept",
581
+ prop: "type",
582
+ label: "\u6587\u4EF6\u7C7B\u578B",
583
+ align: "center",
584
+ type: "slot",
585
+ slotType: "type",
586
+ checked: !0,
587
+ width: "120"
588
+ },
589
+ {
590
+ transKey: "gd.file.fileSize",
591
+ prop: "size",
592
+ label: "\u6587\u4EF6\u5927\u5C0F",
593
+ align: "right",
594
+ checked: !0,
595
+ width: "120"
596
+ },
597
+ {
598
+ transKey: "gd.solution.version",
599
+ prop: "version",
600
+ label: "\u7248\u672C",
601
+ align: "right",
602
+ checked: !0,
603
+ width: "120"
604
+ },
605
+ {
606
+ transKey: "gd.fileDocument.iseffectiveness",
607
+ prop: "iseffectiveness",
608
+ label: "\u6709\u6548",
609
+ align: "center",
610
+ type: "slot",
611
+ slotType: "iseffectiveness",
612
+ checked: !0,
613
+ width: "120"
614
+ },
615
+ {
616
+ transKey: "gd.directory.remark",
617
+ prop: "description",
618
+ label: "\u5907\u6CE8",
619
+ align: "left",
620
+ checked: !0,
621
+ width: "320"
622
+ },
623
+ {
624
+ transKey: "gd.web.creationTime",
625
+ prop: "createdtime",
626
+ label: "\u521B\u5EFA\u65E5\u671F",
627
+ align: "center",
628
+ checked: !0,
629
+ width: "220",
630
+ sortable: "custom"
631
+ },
632
+ {
633
+ transKey: "gd.web.updatedTime",
634
+ prop: "updatedtime",
635
+ label: "\u4FEE\u6539\u65F6\u95F4",
636
+ align: "center",
637
+ checked: !0,
638
+ width: "220"
639
+ }
640
+ ],
641
+ sysViewButtons: [
642
+ {
643
+ displayName: "\u6279\u91CF\u4E0B\u8F7D",
644
+ functionName: "batchDownload",
645
+ show: !0,
646
+ transKey: "gd.btn.batchDownload",
647
+ icon: "el-icon-download",
648
+ operationType: ["batch"]
649
+ },
650
+ {
651
+ displayName: "\u6279\u91CF\u5220\u9664",
652
+ functionName: "batchDel",
653
+ show: !0,
654
+ transKey: "gd.btn.batchDelete",
655
+ icon: "el-icon-delete",
656
+ style: "color:red",
657
+ operationType: ["batch"]
658
+ },
659
+ {
660
+ displayName: "\u64CD\u4F5C",
661
+ functionName: "operation",
662
+ show: !0,
663
+ transKey: "gd.basics.handle",
664
+ icon: "el-icon-s-operation",
665
+ operationType: ["single"],
666
+ type: "children",
667
+ children: [
668
+ {
669
+ displayName: "\u521B\u5EFA\u6587\u4EF6",
670
+ show: !0,
671
+ transKey: "gd.btn.createfile",
672
+ icon: "el-icon-document",
673
+ key: "createfile"
674
+ },
675
+ {
676
+ displayName: "\u521B\u5EFA\u6587\u4EF6\u5939",
677
+ show: !0,
678
+ transKey: "gd.btn.createSubfolders",
679
+ icon: "el-icon-folder-add",
680
+ key: "createsubfolder"
681
+ },
682
+ {
683
+ displayName: "\u6743\u9650\u7BA1\u7406",
684
+ show: !0,
685
+ transKey: "gd.btn.permissionManagement",
686
+ icon: "gd-icon-yewuquanxian",
687
+ btnType: "danger",
688
+ key: "manageprem"
689
+ }
690
+ ]
691
+ },
692
+ {
693
+ displayName: "\u6392\u5E8F",
694
+ functionName: "sortQuery",
695
+ show: !0,
696
+ transKey: "gd.menu.sort",
697
+ icon: "el-icon-sort",
698
+ operationType: ["single"],
699
+ type: "sort",
700
+ sortChildren: [
701
+ { key: "asc", displayName: "\u5347\u5E8F", transKey: "gd.view.asc", icon: "el-icon-sort-up", show: !0 },
702
+ { key: "desc", displayName: "\u964D\u5E8F", transKey: "gd.view.desc", icon: "el-icon-sort-down", show: !0 }
703
+ ],
704
+ fieldChildren: [
705
+ {
706
+ displayName: "\u540D\u79F0",
707
+ show: !0,
708
+ transKey: "gd.translation.name",
709
+ icon: "el-icon-document",
710
+ key: "name"
711
+ },
712
+ {
713
+ displayName: "\u521B\u5EFA\u65F6\u95F4",
714
+ show: !0,
715
+ transKey: "gd.web.creationTime",
716
+ key: "createdtime"
717
+ },
718
+ {
719
+ displayName: "\u4FEE\u6539\u65F6\u95F4",
720
+ show: !0,
721
+ transKey: "gd.web.updatedTime",
722
+ key: "updatedtime"
723
+ },
724
+ {
725
+ displayName: "\u6587\u4EF6\u7C7B\u578B",
726
+ show: !0,
727
+ transKey: "gd.file.fileAccept",
728
+ btnType: "danger",
729
+ key: "filetype"
730
+ }
731
+ ]
732
+ },
733
+ {
734
+ displayName: "\u641C\u7D22",
735
+ functionName: "searchQuery",
736
+ show: !0,
737
+ transKey: "gd.btn.search",
738
+ icon: "el-icon-search",
739
+ operationType: ["single"],
740
+ type: "search"
741
+ },
742
+ {
743
+ displayName: "\u5237\u65B0",
744
+ functionName: "refresh",
745
+ show: !0,
746
+ transKey: "gd.btn.refresh",
747
+ icon: "el-icon-refresh",
748
+ operationType: ["single"]
749
+ },
750
+ {
751
+ displayName: "\u7BA1\u7406",
752
+ functionName: "management",
753
+ show: !0,
754
+ transKey: "gd.btn.management",
755
+ icon: "el-icon-setting",
756
+ operationType: ["single"]
757
+ },
758
+ {
759
+ displayName: "\u9000\u51FA\u7BA1\u7406",
760
+ functionName: "exitManagement",
761
+ icon: "gd-icon-a-goback",
762
+ show: !0,
763
+ transKey: "gd.btn.exitManagement",
764
+ btnType: "info",
765
+ operationType: ["batch"]
766
+ }
767
+ ],
768
+ checkList: [],
769
+ checkedAll: !1,
770
+ confirmLoading: !1,
771
+ list: [],
772
+ id: -1,
773
+ noData: !0,
774
+ rightMenus: [],
775
+ rightLoad: !1,
776
+ folderPermission: [],
777
+ loadData: (t) => (t.sortField !== void 0 ? (this.sortOpen = !0, this.sortParam = [t.sortField === "size" ? "filesize" : t.sortField, t.sortOrder]) : t.sortField == null && this.sortOpen && (this.sortParam[0] = ""), this.getList(this.record).then((e) => ({ pageno: 1, totalrows: this.list.length, rows: this.list }))),
778
+ sortParam: ["createdtime", "asc"],
779
+ sortOpen: !1,
780
+ tableShow: !0
781
+ };
782
+ },
783
+ computed: {
784
+ defaultSort() {
785
+ let t = {};
786
+ if (this.sortParam[0] !== "") {
787
+ const e = this.sortParam[0] === "filesize" ? "size" : this.sortParam[0];
788
+ Object.assign(t, {
789
+ prop: e,
790
+ order: this.sortParam[1] + "ending"
791
+ });
792
+ }
793
+ return t;
794
+ },
795
+ queryParam() {
796
+ let t = {};
797
+ return this.sortParam[0] !== "" && Object.assign(t, {
798
+ orderBy: `${this.sortParam[0]} ${this.sortParam[1]}`
799
+ }), t;
800
+ },
801
+ showMode() {
802
+ return (this.options.switchDemoMode !== void 0 ? this.options.switchDemoMode : 0) === 1;
803
+ },
804
+ options() {
805
+ return this.recordData.options;
806
+ },
807
+ getPermissionList() {
808
+ return this.recordData.permissionList !== void 0 ? this.recordData.permissionList : permissionList;
809
+ },
810
+ popperClass() {
811
+ let t = "";
812
+ return this.hasRight && (t += "contextmenu-right "), this.hasBottom && (t += "contextmenu-btom "), t;
813
+ },
814
+ getTableColumns() {
815
+ return this.tableColumns.map((t) => Object.assign(t, {
816
+ checked: t.type === "selection" ? this.operationType === "batch" : !0
817
+ }));
818
+ },
819
+ getButtons() {
820
+ return this.sysViewButtons.filter((i) => i.operationType.includes(this.operationType)).map((i) => {
821
+ if (i.functionName === "operation") {
822
+ const s = i.children.map((a) => Object.assign(a, {
823
+ show: a.key === "manageprem" && Number(this.id) === 0 ? !1 : this.folderPermission.includes(a.key)
824
+ })), r = s.filter((a) => a.show);
825
+ return Object.assign(i, {
826
+ show: r.length > 0,
827
+ children: s
828
+ });
829
+ } else
830
+ return i;
831
+ });
832
+ },
833
+ pageSizes() {
834
+ return [10, 20, 30, 40, 50, 100, 200, 500];
835
+ },
836
+ show() {
837
+ return this.id !== -1;
838
+ },
839
+ foldersNum() {
840
+ return this.list.filter((e) => e.type === 1).length;
841
+ },
842
+ fileNum() {
843
+ return this.list.filter((e) => e.type !== 1).length;
844
+ },
845
+ filePath() {
846
+ let t = [];
847
+ const e = this.treeData.filter((a) => a.id === this.id)[0];
848
+ if (e === void 0)
849
+ return t;
850
+ const i = e.path.split(".").filter((a) => a != 0);
851
+ let s = [];
852
+ i.reverse().forEach((a) => {
853
+ const n = this.treeData.filter((l) => l.id === Number(a))[0];
854
+ t.length < 5 && n ? t.push({ name: `/${n.name}`, type: "" }) : s.push(`/${n.name}`);
855
+ });
856
+ let r = {};
857
+ return s.length > 0 && Object.assign(r, {
858
+ name: s.reverse().join(""),
859
+ type: "more"
860
+ }), s.length === 0 ? t.reverse() : [r].concat(t.reverse());
861
+ },
862
+ fadeColord() {
863
+ return this.fadeColor(this.primaryColor, 0.1);
864
+ },
865
+ ...u(["tablePageSize", "screenWidth", "screenHeight", "primaryColor"])
866
+ },
867
+ methods: {
868
+ submitSeachPath() {
869
+ this.blurSeachPath(), this.seachPath !== "" && this.$emit("submitSeachPath", this.seachPath);
870
+ },
871
+ blurSeachPath() {
872
+ this.moverShow = !1;
873
+ },
874
+ moverSeachPath() {
875
+ this.moverShow || (this.moverShow = !this.moverShow, this.$nextTick(() => {
876
+ setTimeout(() => {
877
+ this.$refs.seachPath && this.$refs.seachPath.focus();
878
+ }, 0);
879
+ }));
880
+ },
881
+ switchMode() {
882
+ this.sortOpen = !1, this.mode = this.mode === "grid" ? "table" : "grid", this.inputMode();
883
+ },
884
+ seeAttribute(t) {
885
+ this.$emit("seeAttribute", t);
886
+ },
887
+ versionControl(t) {
888
+ this.$emit("versionControl", t);
889
+ },
890
+ inputMode() {
891
+ this.refresh();
892
+ },
893
+ onSelectChange(t) {
894
+ this.checkList = t;
895
+ },
896
+ batchDownload() {
897
+ if (this.checkList.length === 0)
898
+ return;
899
+ const t = this.list.filter((e) => this.checkList.includes(e.id));
900
+ this.$emit("downloadFolder", { data: t }, "batch");
901
+ },
902
+ batchDel() {
903
+ if (this.checkList.length === 0)
904
+ return;
905
+ const t = this.list.filter((e) => this.checkList.includes(e.id));
906
+ this.$emit("deleteFolder", { data: t }, "batch");
907
+ },
908
+ isCheckedAl() {
909
+ const t = this.list.filter((e) => e.type !== 1);
910
+ this.checkedAll = t.length === this.checkList.length;
911
+ },
912
+ changeCheckedAll(t) {
913
+ if (!t) {
914
+ this.checkList = [];
915
+ return;
916
+ }
917
+ let e = [];
918
+ this.list.forEach((i) => {
919
+ i.type !== 1 && e.push(i.id);
920
+ }), this.checkList = e;
921
+ },
922
+ changSelItem(t) {
923
+ if (this.operationType !== "batch")
924
+ return;
925
+ this.checkList.filter((i) => i === t.id)[0] ? this.checkList = this.checkList.filter((i) => i !== t.id) : this.checkList = this.checkList.concat(t.id), this.isCheckedAl();
926
+ },
927
+ operation(t) {
928
+ if (t.key === "manageprem") {
929
+ this.$emit("managepremFolder", { type: "list", data: this.record, hand: t.key });
930
+ return;
931
+ }
932
+ this.$emit(t.key === "createsubfolder" ? "createSubfolders" : "createFile", { type: "list", data: this.record, hand: t.key });
933
+ },
934
+ sortQuery(t) {
935
+ let e = [...this.sortParam];
936
+ ["desc", "asc"].includes(t.key) ? e[1] = t.key : e[0] = t.key, this.sortParam = [...e], this.tableShow = !1, this.$nextTick(() => {
937
+ this.tableShow = !0, this.refresh();
938
+ });
939
+ },
940
+ refresh() {
941
+ this.getFolderPermission(this.id), this.mode === "grid" ? this.getList() : this.$nextTick(() => {
942
+ this.getHeight(), setTimeout(() => {
943
+ this.$refs.table && this.$refs.table.refresh(!1);
944
+ });
945
+ });
946
+ },
947
+ refreshDel(t) {
948
+ !t.includes(this.id) || (this.list = [], this.id = -1, this.noData = !0, this.checkList = [], this.checkedAll = !1);
949
+ },
950
+ initBatch() {
951
+ if (this.operationType !== "batch")
952
+ return;
953
+ let t = [];
954
+ this.list.forEach((e) => {
955
+ this.checkList.includes(e.id) && t.push(e.id);
956
+ }), this.checkList = t, this.isCheckedAl();
957
+ },
958
+ init(t) {
959
+ this.record = t, this.id = t.id, this.refresh();
960
+ },
961
+ initMode() {
962
+ this.$nextTick(() => {
963
+ this.pageSized = this.tablePageSize, this.mode = this.options.listDemoMode ? this.options.listDemoMode : "grid";
964
+ });
965
+ },
966
+ getList() {
967
+ return this.confirmLoading = !0, this.statu = !0, E(Object.assign({ docId: this.id }, this.queryParam)).then((t) => (t.code === 200 ? this.list = t.data.map((e) => Object.assign(
968
+ { ...e },
969
+ {
970
+ icon: L(e),
971
+ size: O(e)
972
+ }
973
+ )) : this.list = [], this.noData = this.list.length === 0, this.initBatch(), this.confirmLoading = !1, this.statu = !1, t));
974
+ },
975
+ exitManagement() {
976
+ this.operationType = "single", this.checkList = [];
977
+ },
978
+ management() {
979
+ this.operationType = "batch";
980
+ },
981
+ searchQuery() {
982
+ this.$emit("searchQuery", "search");
983
+ },
984
+ doClose() {
985
+ this.selItem.id !== void 0 && this.$nextTick(() => {
986
+ const t = this.$refs.contextMenu;
987
+ t && t.doClose();
988
+ });
989
+ },
990
+ handleUp() {
991
+ if (y) {
992
+ clearTimeout(y), y = null;
993
+ return;
994
+ }
995
+ },
996
+ handleDown() {
997
+ y = setTimeout(() => {
998
+ y = null, this.management();
999
+ }, 1500);
1000
+ },
1001
+ rowClick(t) {
1002
+ this.handleSelItem(t);
1003
+ },
1004
+ handleSelItem(t) {
1005
+ if (v) {
1006
+ clearTimeout(v), v = null, this.selPopoverOpen(t);
1007
+ return;
1008
+ }
1009
+ v = setTimeout(() => {
1010
+ v = null, this.selItem = this.operationType === "batch" ? {} : t, this.changSelItem(t);
1011
+ }, 260);
1012
+ },
1013
+ selPopover(t, e) {
1014
+ this.doClose(), this.$emit("selPopover", t, e);
1015
+ },
1016
+ selPopoverOpen(t) {
1017
+ if (this.doClose(), this.$emit("doClose"), t.type === 1) {
1018
+ this.init(t), this.$emit("selPopoverOpen", t);
1019
+ return;
1020
+ }
1021
+ this.$emit("selPopover", t, "readmetadata");
1022
+ },
1023
+ rowContextmenu({ row: t, column: e, event: i }) {
1024
+ i.preventDefault(), this.handleContextmenu(i, t);
1025
+ },
1026
+ handleContextmenu(t, e) {
1027
+ this.selItem = e, this.$refs.contextMenu.handleContextmenu(t, e);
1028
+ },
1029
+ getFolderPermission(t) {
1030
+ return this.folderPermission = [], f({ docId: t }).then((e) => (e.code === 200 && (this.folderPermission = F(e.data)), e));
1031
+ },
1032
+ getHeight() {
1033
+ const t = document.getElementById("document-content-list");
1034
+ this.hig = t ? t.clientHeight - 56 : 200;
1035
+ },
1036
+ handleSizeChange(t) {
1037
+ this.pageSized = t;
1038
+ },
1039
+ handleCurrentChange(t, e) {
1040
+ this.currentPage = t;
1041
+ },
1042
+ getDictionary(t) {
1043
+ return this.$options.filters.dictData(t);
1044
+ },
1045
+ fadeColor(t, e) {
1046
+ let i = parseInt(t.substring(1, 3), 16), s = parseInt(t.substring(3, 5), 16), r = parseInt(t.substring(5, 7), 16);
1047
+ return `rgba(${i},${s},${r},${e})`;
1048
+ },
1049
+ doEvent(t) {
1050
+ let e = t.item.functionName;
1051
+ this[e] && this[e](t);
1052
+ }
1053
+ },
1054
+ mounted() {
1055
+ this.initMode();
1056
+ }
1057
+ };
1058
+ var Ee = function() {
1059
+ var e = this, i = e._self._c;
1060
+ return i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }], staticClass: "document-content" }, [e.show ? i("div", { staticClass: "document-content-title" }, [e.operationType === "single" ? [i("div", { staticClass: "title-path title-path-seach line1", on: { click: function(s) {
1061
+ return s.stopPropagation(), e.moverSeachPath.apply(null, arguments);
1062
+ } } }, [e.moverShow ? i("div", [i("el-input", { ref: "seachPath", attrs: { placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165") }, on: { blur: e.blurSeachPath }, nativeOn: { keyup: function(s) {
1063
+ return !s.type.indexOf("key") && e._k(s.keyCode, "enter", 13, s.key, "Enter") ? null : e.submitSeachPath.apply(null, arguments);
1064
+ } }, model: { value: e.seachPath, callback: function(s) {
1065
+ e.seachPath = s;
1066
+ }, expression: "seachPath" } })], 1) : i("div", [e._l(e.filePath, function(s) {
1067
+ return [s.type === "more" ? i("el-tooltip", { attrs: { placement: "bottom" } }, [i("template", { slot: "content" }, [e._v(" " + e._s(s.name) + " ")]), i("i", { staticClass: "el-icon-more" })], 2) : i("span", [e._v(e._s(s.name) + e._s(s.type))])];
1068
+ })], 2)])] : i("div", { staticClass: "title-path" }, [i("el-checkbox", { attrs: { clearable: "" }, on: { change: e.changeCheckedAll }, model: { value: e.checkedAll, callback: function(s) {
1069
+ e.checkedAll = s;
1070
+ }, expression: "checkedAll" } }, [e._v(e._s(e.$i18nt("gd.btn.selectAll", "\u5168\u9009")))])], 1), e.showMode ? i("div", { staticClass: "title-qie" }, [i("el-radio-group", { attrs: { size: "mini" }, on: { input: e.inputMode }, model: { value: e.mode, callback: function(s) {
1071
+ e.mode = s;
1072
+ }, expression: "mode" } }, [i("el-radio-button", { attrs: { label: "grid" } }, [i("i", { staticClass: "el-icon-menu" })]), i("el-radio-button", { attrs: { label: "table" } }, [i("i", { staticClass: "gd-icons gd-icon-bullet-list--points-bullet-unordered-list-lists-bu", staticStyle: { "line-height": "0.9", "font-size": "16px" } })])], 1)], 1) : e._e(), i("div", { staticClass: "title-btn" }, [i("div", { staticClass: "title-btn-list" }, [e._l(e.getButtons, function(s) {
1073
+ return [s.show ? [i("el-divider", { attrs: { direction: "vertical" } }), s.type === "sort" ? i("el-dropdown", { attrs: { placement: "bottom" }, on: { command: e.doEvent } }, [i("div", { staticClass: "btn-list-item" }, [i("i", { staticClass: "gd-icons", class: s.icon })]), i("el-dropdown-menu", { staticClass: "sort-dropdown", style: { "--dilute": e.fadeColord, minWidth: "140px" }, attrs: { slot: "dropdown" }, slot: "dropdown" }, [e._l(s.fieldChildren, function(r) {
1074
+ return i("el-dropdown-item", { key: r.key, attrs: { command: { item: s, key: r.key } } }, [i("div", { staticClass: "check-flex" }, [i("div", { staticClass: "check-flex-icon" }, [e.sortParam.includes(r.key) ? i("div", { staticClass: "el-icon-check active-color" }) : e._e()]), i("div", [e._v(e._s(e.$i18nt(r.transKey, r.displayName)))])])]);
1075
+ }), i("el-divider"), e._l(s.sortChildren, function(r) {
1076
+ return i("el-dropdown-item", { key: r.key, attrs: { command: { item: s, key: r.key } } }, [i("div", { staticClass: "check-flex" }, [i("div", { staticClass: "check-flex-icon" }, [e.sortParam.includes(r.key) ? i("div", { staticClass: "el-icon-check active-color" }) : e._e()]), i("div", [i("i", { staticClass: "gd-icons", class: r.icon ? r.icon : s.icon }), e._v(" " + e._s(e.$i18nt(r.transKey, r.displayName)) + " ")])])]);
1077
+ })], 2)], 1) : s.type === "children" ? i("el-dropdown", { attrs: { placement: "bottom" }, on: { command: e.doEvent } }, [i("div", { staticClass: "btn-list-item" }, [i("i", { staticClass: "gd-icons", class: s.icon })]), i("el-dropdown-menu", { style: { "--dilute": e.fadeColord, minWidth: "140px" }, attrs: { slot: "dropdown" }, slot: "dropdown" }, [e._l(s.children, function(r) {
1078
+ return [r.show ? i("el-dropdown-item", { key: r.key, attrs: { command: { item: s, key: r.key } } }, [i("i", { staticClass: "gd-icons", class: r.icon ? r.icon : s.icon, staticStyle: { "font-size": "14px" } }), e._v(" " + e._s(e.$i18nt(r.transKey, r.displayName)) + " ")]) : e._e()];
1079
+ })], 2)], 1) : i("el-tooltip", { attrs: { placement: "bottom" } }, [i("template", { slot: "content" }, [e._v(" " + e._s(e.$i18nt(s.transKey, s.displayName)) + " ")]), i("div", { staticClass: "btn-list-item" }, [i("i", { staticClass: "gd-icons", class: s.icon, style: s.style ? s.style : "", on: { click: function(r) {
1080
+ return e.doEvent({ item: s, key: null });
1081
+ } } })])], 2)] : e._e()];
1082
+ })], 2)]), i("div", { staticClass: "title-num" }, [i("span", { staticClass: "gd-icons gd-icon-wenjianjia-shouqi", staticStyle: { color: "#f8d71c", "font-size": "18px" } }), i("span", { staticStyle: { padding: "0 4px" } }, [e._v(e._s(e.foldersNum))]), i("span", { staticClass: "gd-icons el-icon-s-order", staticStyle: { color: "rgb(194, 197, 206)", "font-size": "18px" } }), i("span", { staticStyle: { padding: "0 4px" } }, [e._v(e._s(e.fileNum))])])], 2) : i("div", { staticClass: "document-content-title" }, [i("div", { staticClass: "title-path" }), i("div", { staticClass: "title-num" }, [i("i", { staticClass: "el-icon-info" }), e._v(" " + e._s(e.$i18nt("gd.fileDocument.noFolderSel", "\u672A\u9009\u62E9\u6587\u4EF6\u5939")) + " ")])]), i("div", { staticClass: "document-content-list", class: e.mode === "table" ? "document-content-table" : "", attrs: { id: "document-content-list" } }, [e.mode === "grid" ? i("div", { staticClass: "grid-list" }, [e._l(e.list, function(s) {
1083
+ return [i("div", { staticClass: "list-item", class: [e.selItem.id === s.id ? "list-item-post" : ""], on: { contextmenu: function(r) {
1084
+ return r.preventDefault(), e.handleContextmenu(r, s);
1085
+ }, click: function(r) {
1086
+ return e.handleSelItem(s);
1087
+ }, mousedown: e.handleDown, mouseup: e.handleUp } }, [i("div", { staticClass: "item-icon" }, [i("i", { staticClass: "gd-icons", class: s.icon })]), i("div", { staticClass: "spu line1" }, [e._v(e._s(s.name))]), i("div", { staticClass: "sku" }, [i("div", { staticClass: "time" }, [e._v(e._s(e._f("formatTime")(s.updatedtime)))]), s.type === 1 ? i("div", { staticClass: "tiao" }) : i("div", { staticClass: "size" }, [e._v(e._s(s.size))])]), e.operationType === "batch" ? i("div", { staticClass: "choice" }, [e.checkList.includes(s.id) ? i("i", { staticClass: "gd-icons gd-icon-zhengque active-color" }) : e._e()]) : e._e()])];
1088
+ })], 2) : i("div", [e.tableShow ? i("gd-tables", { ref: "table", attrs: { dataSource: e.loadData, columns: e.getTableColumns, initialLoading: !1, showPagination: !1, selectedRowKeys: e.checkList, height: e.hig, defaultSort: e.defaultSort }, on: { onChange: e.onSelectChange, rowContextmenu: e.rowContextmenu, rowClick: e.rowClick }, scopedSlots: e._u([{ key: "type", fn: function({ column: s, row: r }) {
1089
+ return [i("i", { staticClass: "gd-icons miniimg", class: r.icon })];
1090
+ } }, { key: "iseffectiveness", fn: function({ column: s, row: r }) {
1091
+ return [i("el-tag", { style: e._f("dictColor")("yes_or_no", r.iseffectiveness), attrs: { effect: "dark" } }, [e._v(" " + e._s(e._f("dictType")("yes_or_no", r.iseffectiveness)) + " ")])];
1092
+ } }], null, !1, 2438667704) }) : e._e()], 1), e.noData && e.mode === "grid" ? i("div", { staticClass: "empty" }, [e._m(0), i("div", { staticClass: "empty-title" }, [i("span", [e._v(e._s(e.$i18nt("gd.echarts.noData", "\u6682\u65E0\u6570\u636E\u5C55\u793A")))])])]) : e._e()]), i("ContextMenu", { ref: "contextMenu", attrs: { recordData: e.recordData, treeData: e.treeData }, on: { versionControl: e.versionControl, seeAttribute: e.seeAttribute, selPopover: e.selPopover, selPopoverOpen: e.selPopoverOpen, doClose: e.doClose } })], 1);
1093
+ }, Me = [function() {
1094
+ var t = this, e = t._self._c;
1095
+ return e("div", { staticClass: "empty-icon" }, [e("i", { staticClass: "el-icon-receiving" })]);
1096
+ }], Ke = /* @__PURE__ */ d(
1097
+ Be,
1098
+ Ee,
1099
+ Me,
1100
+ !1,
1101
+ null,
1102
+ "a2e5070e",
1103
+ null,
1104
+ null
1105
+ );
1106
+ const Re = Ke.exports;
1107
+ const Ve = {
1108
+ props: {
1109
+ record: {
1110
+ type: Object,
1111
+ required: !0
1112
+ },
1113
+ develop: {
1114
+ type: [Number, String],
1115
+ default: 1
1116
+ },
1117
+ height: {
1118
+ type: Number,
1119
+ default: 100
1120
+ }
1121
+ },
1122
+ components: {
1123
+ FileTree: Ne,
1124
+ FileList: Re,
1125
+ FileSearch: () => Promise.resolve().then(() => Ye),
1126
+ CreateSubfolders: () => Promise.resolve().then(() => rt),
1127
+ MoveFile: () => Promise.resolve().then(() => dt),
1128
+ CreateFile: () => Promise.resolve().then(() => gt),
1129
+ PermissionManage: () => Promise.resolve().then(() => Ct),
1130
+ Attribute: () => Promise.resolve().then(() => Lt),
1131
+ VersionControl: () => Promise.resolve().then(() => Ot)
1132
+ },
1133
+ data() {
1134
+ return {
1135
+ collapse: !1,
1136
+ contextMenuVisible: !1,
1137
+ left: 0,
1138
+ top: 0,
1139
+ hasBottom: !1,
1140
+ selItem: {},
1141
+ handleData: {},
1142
+ treeData: [],
1143
+ treeDataAll: [],
1144
+ treeMenusData: [],
1145
+ rightMenus: [],
1146
+ rightLoad: !1,
1147
+ showType: "list"
1148
+ };
1149
+ },
1150
+ computed: {
1151
+ multipleLimit() {
1152
+ return this.options.multipleLimit !== void 0 ? this.options.multipleLimit : 12;
1153
+ },
1154
+ getPermissionList() {
1155
+ return (this.record.permissionList !== void 0 ? this.record.permissionList : h).filter((i) => i.type.includes(1));
1156
+ },
1157
+ fadeColord() {
1158
+ return this.fadeColor(this.primaryColor, 0.1);
1159
+ },
1160
+ selColord() {
1161
+ return this.fadeColor(this.primaryColor, 0.2);
1162
+ },
1163
+ options() {
1164
+ return this.record.options;
1165
+ },
1166
+ fileAccept() {
1167
+ return this.options.fileAccept;
1168
+ },
1169
+ limit() {
1170
+ return this.options.limit === void 0 ? 12 : this.options.limit;
1171
+ },
1172
+ gclass() {
1173
+ return this.develop == 1 ? "" : this.record.customClass ? this.record.customClass : "";
1174
+ },
1175
+ getHig() {
1176
+ const t = this.develop == 1 ? this.height - 12 : this.height;
1177
+ return this.options.heightMode === "custom" ? this.options.height === 0 || this.options.height === "" ? t : this.options.height : t;
1178
+ },
1179
+ treewid() {
1180
+ const t = this.options.treeStationWid ? this.options.treeStationWid : 256;
1181
+ return this.collapse ? 6 : t;
1182
+ },
1183
+ style() {
1184
+ const t = this.collapse ? 1 : 6;
1185
+ return `height:${this.getHig}px;--fadecolor: ${this.fadeColord};--treewid:${this.treewid}px;--selcolor:${this.selColord};--marginr:${t}px;`;
1186
+ },
1187
+ wstyle() {
1188
+ const t = this.develop == 1 ? "" : this.record.customCss ? this.record.customCss : "";
1189
+ return `${ne(this.record.css)}${t}`;
1190
+ },
1191
+ ...u(["tableLists", "primaryColor", "screenHeight"])
1192
+ },
1193
+ methods: {
1194
+ submitSeachPath(t) {
1195
+ if (t === "/" || t === "\\") {
1196
+ this.$refs.fileTree.setExpandKey([]), this.$refs.fileList.init({ id: 0 });
1197
+ return;
1198
+ }
1199
+ const e = t.substring(0, 1);
1200
+ if (e !== "/" && e !== "\\") {
1201
+ this.$message.error(this.$i18nt("gd.fileDocument.errorDataTip", "\u6570\u636E\u9519\u8BEF\uFF0C\u8BF7\u91CD\u65B0\u8F93\u5165"));
1202
+ return;
1203
+ }
1204
+ let s = (e === "/" ? t.substring(1).replace("\\", "/").toString() : t.replace("\\", "/").toString()).split("/");
1205
+ t.substring(t.length - 1) === "/" && s.pop();
1206
+ let a = [];
1207
+ if (this.getChildrenId(a, this.treeMenusData, s, 0), a.length < s.length) {
1208
+ this.$message.error(this.$i18nt("gd.fileDocument.specifiedPathTip", "\u672A\u627E\u5230\u6307\u5B9A\u8DEF\u5F84\uFF01"));
1209
+ return;
1210
+ }
1211
+ const n = this.treeData.filter((l) => l.id === a[a.length - 1])[0];
1212
+ this.handleNodeClick(n), this.$refs.fileTree.setExpandKey(a);
1213
+ },
1214
+ getChildrenId(t, e, i, s) {
1215
+ const r = i[s], a = e.filter((n) => n.name === r)[0];
1216
+ !a || !i[s] || (a && t.push(a.id), a && a.children && i[s + 1] && this.getChildrenId(t, a.children, i, s + 1));
1217
+ },
1218
+ collapseBar() {
1219
+ this.collapse = !this.collapse;
1220
+ },
1221
+ searchQuery(t) {
1222
+ this.showType = t, t === "search" && this.$nextTick(() => {
1223
+ this.$refs.fileSearch.init();
1224
+ });
1225
+ },
1226
+ switchMode() {
1227
+ this.$refs.fileList.switchMode();
1228
+ },
1229
+ seeAttribute(t) {
1230
+ this.$refs.attribute.open(t);
1231
+ },
1232
+ versionControl(t) {
1233
+ this.$refs.versionControl.open(t);
1234
+ },
1235
+ selPopoverOpen(t, e = !1) {
1236
+ this.$refs.fileTree.selPopoverOpen(t), e && this.$nextTick(() => {
1237
+ this.$refs.fileList.init(t);
1238
+ });
1239
+ },
1240
+ getTreeMenusData(t) {
1241
+ this.treeMenusData = t;
1242
+ },
1243
+ getTreeDataAll(t) {
1244
+ const e = t.filter((i) => i.type === 1);
1245
+ this.treeData = e, this.treeDataAll = t;
1246
+ },
1247
+ getTreeData(t) {
1248
+ this.treeData = t;
1249
+ },
1250
+ handleNodeClick(t) {
1251
+ this.$refs.fileList.init(t);
1252
+ },
1253
+ init() {
1254
+ this.develop !== 1 && this.$nextTick(() => {
1255
+ this.$refs.fileList.init({ id: 0 });
1256
+ });
1257
+ },
1258
+ refresh(t) {
1259
+ this.$refs.fileTree.refresh(t, this.handleData);
1260
+ const e = this.showType === "list" ? "fileList" : "fileSearch";
1261
+ this.$refs[e].refresh(t, this.handleData);
1262
+ },
1263
+ readmetadataFolder(t) {
1264
+ const e = t.data.name.length, i = t.data.filetype.length, s = t.data.name.slice(e - i - 1, e);
1265
+ this.record.doEvent({
1266
+ key: "GdFilePreview",
1267
+ functionName: "gd-file-preview",
1268
+ data: [{ fileoriginname: s === `.${t.data.filetype}` ? t.data.name : `${t.data.name}.${t.data.filetype}`, id: t.data.file }],
1269
+ source: this.record,
1270
+ callback: !1,
1271
+ callbackComponents: "",
1272
+ callbackFunction: ""
1273
+ });
1274
+ },
1275
+ fileDownload(t) {
1276
+ const e = this.$message({
1277
+ message: this.$i18nt("gd.https.downloading", "\u6B63\u5728\u4E0B\u8F7D\u4E2D......"),
1278
+ duration: 0,
1279
+ iconClass: "el-icon-loading"
1280
+ });
1281
+ M({ docObjId: t.data.id }).then((i) => {
1282
+ if (i.data.type === "application/json") {
1283
+ const s = new FileReader();
1284
+ s.onload = (r) => {
1285
+ const a = JSON.parse(s.result);
1286
+ this.$message.error(a.message), e.close();
1287
+ }, s.readAsText(i.data);
1288
+ return;
1289
+ }
1290
+ if (i) {
1291
+ const s = t.data.name.length, r = t.data.filetype.length, a = t.data.name.slice(s - r - 1, s), n = new Blob([i.data], {
1292
+ type: this.getBlobType(t.data.filetype)
1293
+ }), l = URL.createObjectURL(n);
1294
+ let o = document.createElement("a");
1295
+ o.style.display = "none", o.href = l, o.download = a === `.${t.data.filetype}` ? t.data.name : `${t.data.name}.${t.data.filetype}`, o.click(), setTimeout(() => {
1296
+ e.close(), URL.revokeObjectURL(o.href);
1297
+ }, 1e3);
1298
+ } else
1299
+ e.close(), this.$message.error(i.message);
1300
+ });
1301
+ },
1302
+ fileDownloadBatch(t) {
1303
+ const e = this.$message({
1304
+ message: this.$i18nt("gd.https.downloading", "\u6B63\u5728\u4E0B\u8F7D\u4E2D......"),
1305
+ duration: 0,
1306
+ iconClass: "el-icon-loading"
1307
+ });
1308
+ let i = [];
1309
+ t.data.forEach((s) => {
1310
+ i.push(s.id);
1311
+ }), K({ docList: i }).then((s) => {
1312
+ if (s.data.type === "application/json") {
1313
+ const r = new FileReader();
1314
+ r.onload = (a) => {
1315
+ const n = JSON.parse(r.result);
1316
+ this.$message.error(n.message), e.close();
1317
+ }, r.readAsText(s.data);
1318
+ return;
1319
+ }
1320
+ if (s) {
1321
+ const r = this.treeData.filter((o) => o.id === t.data[0].parentid)[0], a = new Blob([s.data], {
1322
+ type: "application/zip"
1323
+ }), n = URL.createObjectURL(a);
1324
+ let l = document.createElement("a");
1325
+ l.style.display = "none", l.href = n, l.download = `${r.name}_${new Date().getTime()}.zip`, l.click(), setTimeout(() => {
1326
+ e.close(), URL.revokeObjectURL(l.href);
1327
+ }, 1e3);
1328
+ } else
1329
+ e.close(), this.$message.error(s.message);
1330
+ });
1331
+ },
1332
+ getBlobType(t) {
1333
+ let e = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
1334
+ return t === "pdf" ? e = "application/pdf" : t === "docx" && (e = "application/msword"), e;
1335
+ },
1336
+ downloadFolder(t, e = "single") {
1337
+ if ((e === "single" ? [] : t.data.filter((s) => s.type === 1))[0]) {
1338
+ this.$message.error(this.$i18nt("gd.fileDocument.downloadFolderTip", "\u4E0B\u8F7D\u6570\u636E\u5185\u4E0D\u80FD\u5305\u542B\u6587\u4EF6\u5939"));
1339
+ return;
1340
+ }
1341
+ if (e === "single") {
1342
+ this.fileDownload(t);
1343
+ return;
1344
+ }
1345
+ if (t.data.length === 1) {
1346
+ this.fileDownload({ data: t.data[0] });
1347
+ return;
1348
+ }
1349
+ this.fileDownloadBatch(t);
1350
+ },
1351
+ renameFolder(t) {
1352
+ this.$refs.createSubfolders.open(t.data, t.hand);
1353
+ },
1354
+ deleteFolder(t, e = "single") {
1355
+ let i = this, s = [], r = this.$i18nt("gd.https.delContent", "\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?");
1356
+ if (e === "single") {
1357
+ const a = this.treeDataAll.filter((n) => n.parentid === t.data.id);
1358
+ s = s.concat(a);
1359
+ } else
1360
+ t.data.forEach((a) => {
1361
+ const n = this.treeDataAll.filter((l) => l.parentid === a.id);
1362
+ s = s.concat(n);
1363
+ });
1364
+ s.length > 0 && (r = this.$i18nt("gd.fileDocument.delContent", "\u5F53\u524D\u9009\u4E2D\u6570\u636E\u4E2D\u5B58\u5728\u5B50\u6587\u4EF6/\u6587\u4EF6\u5939\uFF0C\u662F\u5426\u786E\u8BA4\u5220\u9664?")), this.$confirm(r, this.$i18nt("gd.https.delTitle", "\u6E29\u99A8\u63D0\u793A"), {
1365
+ confirmButtonText: this.$i18nt("gd.https.delOk", "\u786E\u5B9A\u5220\u9664"),
1366
+ cancelButtonText: this.$i18nt("gd.https.delCancel", "\u53D6\u6D88"),
1367
+ showClose: !1,
1368
+ confirmButtonLoading: !1,
1369
+ cancelButtonLoading: !1,
1370
+ closeOnClickModal: !1,
1371
+ type: "warning",
1372
+ confirmButtonClass: "el-button--danger",
1373
+ customClass: "custom-alert",
1374
+ callback: () => {
1375
+ },
1376
+ beforeClose: (a, n, l) => {
1377
+ if (a !== "confirm") {
1378
+ l();
1379
+ return;
1380
+ }
1381
+ n.confirmButtonLoading = !0, n.cancelButtonLoading = !0, n.showCancelButton = !1;
1382
+ let o = [];
1383
+ e === "single" ? o.push(t.data.id) : t.data.forEach((c) => {
1384
+ o.push(c.id);
1385
+ }), R({
1386
+ ids: o.join(",")
1387
+ }).then((c) => {
1388
+ n.confirmButtonLoading = !1, n.cancelButtonLoading = !1, n.showCancelButton = !0, c.success ? (i.$message.success(i.$i18nt("gd.https.delSucc", "\u5220\u9664\u6210\u529F")), i.$refs.fileList.refreshDel(o), i.refresh(t.data), l()) : i.$message.error(i.$i18nt("gd.https.delFail", "\u5220\u9664\u5931\u8D25") + c.message);
1389
+ });
1390
+ }
1391
+ });
1392
+ },
1393
+ moveFolder(t) {
1394
+ this.$refs.moveFile.open(t.data);
1395
+ },
1396
+ createsubfolderFolder(t) {
1397
+ this.$refs.createSubfolders.open(t.data, t.hand);
1398
+ },
1399
+ createfileFolder(t) {
1400
+ this.$refs.createFile.open(t.data, t.hand);
1401
+ },
1402
+ managepremFolder(t) {
1403
+ this.$refs.permissionManage.open(t.data);
1404
+ },
1405
+ createFile(t) {
1406
+ this.handleData = t, this.$refs.createSubfolders.open(t.data, "createrootdirectory");
1407
+ },
1408
+ doClose() {
1409
+ this.$nextTick(() => {
1410
+ const t = this.$refs.dropdown;
1411
+ t && t.doClose();
1412
+ });
1413
+ },
1414
+ selPopoverList(t, e) {
1415
+ this.selItem = t, this.selPopover(e);
1416
+ },
1417
+ selPopover(t) {
1418
+ this.doClose();
1419
+ const e = `${t}Folder`;
1420
+ this.handleData = { type: "tree", data: this.selItem, hand: t }, this[e] && this[e](this.handleData);
1421
+ },
1422
+ handleContextmenu(t, e) {
1423
+ this.contextMenuVisible = !1, this.rightMenus = [], this.hasBottom = this.screenHeight - t.clientY < 170, this.$nextTick(() => {
1424
+ this.contextMenuVisible = !0, this.$nextTick(() => {
1425
+ this.$refs.fileList.doClose();
1426
+ const i = this.$refs.dropdown;
1427
+ this.left = t.layerX - 10, this.top = t.layerY + 32, this.selItem = e, i.doShow();
1428
+ });
1429
+ }), this.getRootPermission(e.id);
1430
+ },
1431
+ getRootPermission(t) {
1432
+ return this.rightLoad = !0, f({ docId: t }).then((e) => {
1433
+ if (e.code === 200) {
1434
+ const i = F(e.data), s = this.getPermissionList.filter((r) => i.includes(r.code));
1435
+ this.rightMenus = s;
1436
+ }
1437
+ return this.rightLoad = !1, e;
1438
+ });
1439
+ },
1440
+ fadeColor(t, e) {
1441
+ let i = parseInt(t.substring(1, 3), 16), s = parseInt(t.substring(3, 5), 16), r = parseInt(t.substring(5, 7), 16);
1442
+ return `rgba(${i},${s},${r},${e})`;
1443
+ },
1444
+ getFileBlob(t) {
1445
+ return sysFileInfoDownload({
1446
+ id: t
1447
+ }).then((e) => e.data);
1448
+ },
1449
+ executeEvent(t) {
1450
+ const e = t.functionName ? t.functionName : "";
1451
+ e && this[e] !== void 0 ? this[e](t) : console.log("\u6267\u884C\u9519\u8BEF");
1452
+ }
1453
+ },
1454
+ mounted() {
1455
+ this.develop == 2 && (this.record.executeEvent = this.executeEvent), this.init();
1456
+ }
1457
+ };
1458
+ var qe = function() {
1459
+ var e = this, i = e._self._c;
1460
+ return i("div", { staticClass: "gd-file-document", class: e.gclass, style: e.wstyle }, [i("div", { staticClass: "file-document-main", style: e.style }, [i("FileTree", { ref: "fileTree", attrs: { record: e.record, collapse: e.collapse }, on: { nodeContextmenu: e.handleContextmenu, doClose: e.doClose, createFile: e.createFile, handleNodeClick: e.handleNodeClick, treeData: e.getTreeData, treeDataAll: e.getTreeDataAll, seeAttribute: e.seeAttribute, collapseBar: e.collapseBar, treeMenusData: e.getTreeMenusData } }), i("FileList", { directives: [{ name: "show", rawName: "v-show", value: e.showType === "list", expression: "showType === 'list'" }], ref: "fileList", attrs: { treeData: e.treeData, recordData: e.record }, on: { doClose: e.doClose, selPopoverOpen: e.selPopoverOpen, createSubfolders: e.createsubfolderFolder, createFile: e.createfileFolder, selPopover: e.selPopoverList, deleteFolder: e.deleteFolder, downloadFolder: e.downloadFolder, seeAttribute: e.seeAttribute, versionControl: e.versionControl, managepremFolder: e.managepremFolder, searchQuery: e.searchQuery, submitSeachPath: e.submitSeachPath } }), i("FileSearch", { directives: [{ name: "show", rawName: "v-show", value: e.showType === "search", expression: "showType === 'search'" }], ref: "fileSearch", attrs: { treeData: e.treeData, recordData: e.record, showType: e.showType }, on: { searchQuery: e.searchQuery, doClose: e.doClose, seeAttribute: e.seeAttribute, versionControl: e.versionControl, selPopoverOpen: e.selPopoverOpen, selPopover: e.selPopoverList } })], 1), e.contextMenuVisible ? i("div", { staticClass: "contextmenu", style: { left: e.left + "px", top: e.top + "px" } }, [i("el-popover", { ref: "dropdown", attrs: { placement: "right", trigger: "hover", "popper-class": e.hasBottom ? "contextmenu-btom" : "" } }, [i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.rightLoad, expression: "rightLoad" }], staticClass: "selectionl-popover" }, [e._l(e.rightMenus, function(s) {
1461
+ return [i("div", { staticClass: "popover-item", on: { click: function(r) {
1462
+ return e.selPopover(s.code);
1463
+ } } }, [i("i", { staticClass: "gd-icons", class: s.icon }), e._v(" " + e._s(e.$i18nt(s.transkey, s.name)) + " ")])];
1464
+ }), !e.rightLoad && e.rightMenus.length === 0 ? i("div", { staticClass: "no-menus" }, [i("i", { staticClass: "el-icon-receiving" }), i("div", { staticClass: "tip" }, [e._v(e._s(e.$i18nt("gd.page.temporarilyAuthority", "\u6682\u65E0\u6743\u9650")))])]) : e._e(), e.rightLoad ? e._e() : [i("div", { staticStyle: { padding: "0 6px" } }, [i("el-divider")], 1), i("div", { staticClass: "popover-item", on: { click: function(s) {
1465
+ return e.seeAttribute(e.selItem);
1466
+ } } }, [i("i", { staticClass: "gd-icons el-icon-info" }), e._v(" " + e._s(e.$i18nt("gd.form.attribute", "\u5C5E\u6027")) + " ")])]], 2)])], 1) : e._e(), i("CreateSubfolders", { ref: "createSubfolders", on: { ok: e.refresh } }), i("MoveFile", { ref: "moveFile", attrs: { treeData: e.treeData }, on: { ok: e.refresh } }), i("CreateFile", { ref: "createFile", attrs: { fileAccept: e.fileAccept, limit: e.limit }, on: { ok: e.refresh } }), i("Attribute", { ref: "attribute", attrs: { treeData: e.treeData, fileAccept: e.fileAccept }, on: { preview: e.readmetadataFolder } }), i("VersionControl", { ref: "versionControl", attrs: { fileAccept: e.fileAccept }, on: { preview: e.readmetadataFolder } }), i("PermissionManage", { ref: "permissionManage", attrs: { treeData: e.treeData, multipleLimit: e.multipleLimit }, on: { ok: e.refresh } })], 1);
1467
+ }, He = [], Ue = /* @__PURE__ */ d(
1468
+ Ve,
1469
+ qe,
1470
+ He,
1471
+ !1,
1472
+ null,
1473
+ "44b392e7",
1474
+ null,
1475
+ null
1476
+ );
1477
+ const oi = Ue.exports;
1478
+ var b = null;
1479
+ const Je = {
1480
+ props: {
1481
+ recordData: {
1482
+ type: Object,
1483
+ default: () => {
1484
+ }
1485
+ },
1486
+ treeData: {
1487
+ type: Array,
1488
+ default: () => []
1489
+ },
1490
+ showType: {
1491
+ type: String,
1492
+ default: "list"
1493
+ }
1494
+ },
1495
+ components: { ContextMenu: j },
1496
+ data() {
1497
+ return {
1498
+ confirmLoading: !1,
1499
+ ruleFormData: {
1500
+ docName: "",
1501
+ type: "",
1502
+ uploadTime: "",
1503
+ maxSize: void 0,
1504
+ minSize: void 0
1505
+ },
1506
+ sysViewButtons: [
1507
+ {
1508
+ displayName: "\u67E5\u8BE2",
1509
+ functionName: "search",
1510
+ show: !0,
1511
+ transKey: "gd.btn.query",
1512
+ icon: "el-icon-search",
1513
+ operationType: ["single"],
1514
+ type: "search"
1515
+ },
1516
+ {
1517
+ displayName: "\u9000\u51FA",
1518
+ functionName: "exit",
1519
+ icon: "gd-icon-a-goback",
1520
+ show: !0,
1521
+ transKey: "gd.btn.exit",
1522
+ btnType: "info"
1523
+ }
1524
+ ],
1525
+ noData: !0,
1526
+ list: [],
1527
+ selItem: {}
1528
+ };
1529
+ },
1530
+ computed: {
1531
+ pickerOptions() {
1532
+ return {
1533
+ shortcuts: [
1534
+ {
1535
+ text: this.$i18nt("el.view.today", "\u4ECA\u5929"),
1536
+ onClick(t) {
1537
+ t.$emit("pick", new Date());
1538
+ }
1539
+ },
1540
+ {
1541
+ text: this.$i18nt("el.view.yesterday", "\u6628\u5929"),
1542
+ onClick(t) {
1543
+ const e = new Date();
1544
+ e.setTime(e.getTime() - 3600 * 1e3 * 24), t.$emit("pick", e);
1545
+ }
1546
+ },
1547
+ {
1548
+ text: this.$i18nt("el.view.daysAgo3", "3\u5929\u4E4B\u524D"),
1549
+ onClick(t) {
1550
+ const e = new Date();
1551
+ e.setTime(e.getTime() - 3600 * 1e3 * 24 * 3), t.$emit("pick", e);
1552
+ }
1553
+ },
1554
+ {
1555
+ text: this.$i18nt("el.view.daysAgo5", "5\u5929\u4E4B\u524D"),
1556
+ onClick(t) {
1557
+ const e = new Date();
1558
+ e.setTime(e.getTime() - 3600 * 1e3 * 24 * 5), t.$emit("pick", e);
1559
+ }
1560
+ },
1561
+ {
1562
+ text: this.$i18nt("el.view.daysAgo7", "7\u5929\u4E4B\u524D"),
1563
+ onClick(t) {
1564
+ const e = new Date();
1565
+ e.setTime(e.getTime() - 3600 * 1e3 * 24 * 7), t.$emit("pick", e);
1566
+ }
1567
+ }
1568
+ ]
1569
+ };
1570
+ },
1571
+ valueFormat() {
1572
+ return "yyyy-MM-dd";
1573
+ },
1574
+ getQueryParam() {
1575
+ let t = {};
1576
+ return this.ruleFormData.docName && Object.assign(t, { docName: this.ruleFormData.docName }), this.ruleFormData.type.length > 0 && this.ruleFormData.type.length === 1 && Object.assign(t, { type: this.ruleFormData.type[0] }), this.ruleFormData.uploadTime && Object.assign(t, { uploadTime: this.ruleFormData.uploadTime + " 12:00:00" }), this.ruleFormData.minSize !== void 0 && this.ruleFormData.minSize !== "" && (this.ruleFormData.maxSize === void 0 || this.ruleFormData.maxSize === "" ? Object.assign(t, { minSize: 0, maxSize: this.ruleFormData.minSize }) : Object.assign(t, { minSize: this.ruleFormData.minSize })), this.ruleFormData.maxSize !== void 0 && this.ruleFormData.maxSize !== "" && (this.ruleFormData.minSize === void 0 || this.ruleFormData.minSize === "" ? Object.assign(t, { minSize: 0, maxSize: this.ruleFormData.maxSize }) : Object.assign(t, { maxSize: this.ruleFormData.maxSize })), t;
1577
+ }
1578
+ },
1579
+ methods: {
1580
+ init() {
1581
+ this.list.length !== 0 && this.search();
1582
+ },
1583
+ refresh() {
1584
+ this.search();
1585
+ },
1586
+ selPopover(t, e) {
1587
+ this.doClose(), this.$emit("selPopover", t, e);
1588
+ },
1589
+ selPopoverOpen(t) {
1590
+ if (this.doClose(), this.$emit("doClose"), t.type === 1) {
1591
+ this.$emit("selPopoverOpen", t, !0), this.$emit("searchQuery", "list");
1592
+ return;
1593
+ }
1594
+ this.$emit("selPopover", t, "readmetadata");
1595
+ },
1596
+ seeAttribute(t) {
1597
+ this.$emit("seeAttribute", t);
1598
+ },
1599
+ versionControl(t) {
1600
+ this.$emit("versionControl", t);
1601
+ },
1602
+ doClose() {
1603
+ this.selItem.id !== void 0 && this.$nextTick(() => {
1604
+ const t = this.$refs.contextMenu;
1605
+ t && t.doClose();
1606
+ });
1607
+ },
1608
+ handleContextmenu(t, e) {
1609
+ this.selItem = e, this.$refs.contextMenu.handleContextmenu(t, e);
1610
+ },
1611
+ handleSelItem(t) {
1612
+ if (b) {
1613
+ clearTimeout(b), b = null, this.selPopoverOpen(t);
1614
+ return;
1615
+ }
1616
+ b = setTimeout(() => {
1617
+ b = null, this.selItem = t;
1618
+ }, 260);
1619
+ },
1620
+ search() {
1621
+ if (this.confirmLoading)
1622
+ return;
1623
+ if (Object.keys(this.getQueryParam).length === 0 && this.ruleFormData.type.length === 0) {
1624
+ this.$message.info(this.$i18nt("gd.fileDocument.queryCriteria", "\u8BF7\u8F93\u5165\u67E5\u8BE2\u6761\u4EF6"));
1625
+ return;
1626
+ }
1627
+ this.confirmLoading = !0, V(this.getQueryParam).then((e) => {
1628
+ this.confirmLoading = !1, e.code === 200 && (this.list = e.data.map((i) => Object.assign(
1629
+ { ...i },
1630
+ {
1631
+ icon: L(i),
1632
+ size: O(i),
1633
+ highlightedText: Le(i.name, this.ruleFormData.docName),
1634
+ filePath: this.getFilePath(i)
1635
+ }
1636
+ ))), this.noData = this.list.length === 0;
1637
+ });
1638
+ },
1639
+ getFilePath(t) {
1640
+ let e = "";
1641
+ return (t.path ? t.path.split(".").filter((s) => s != 0) : []).forEach((s) => {
1642
+ const r = this.treeData.filter((a) => a.id === Number(s))[0];
1643
+ t.id !== Number(s) && (e += r ? `/${r.name}` : `/${s}`);
1644
+ }), e;
1645
+ },
1646
+ exit() {
1647
+ this.$emit("searchQuery", "list"), this.list = [], this.noData = !0, this.selItem = {}, this.ruleFormData = {
1648
+ docName: "",
1649
+ type: "",
1650
+ uploadTime: "",
1651
+ maxSize: void 0,
1652
+ minSize: void 0
1653
+ };
1654
+ },
1655
+ getDictionary(t) {
1656
+ return this.$options.filters.dictData(t);
1657
+ },
1658
+ doEvent(t) {
1659
+ let e = t.item.functionName;
1660
+ this[e] && this[e](t);
1661
+ }
1662
+ }
1663
+ };
1664
+ var We = function() {
1665
+ var e = this, i = e._self._c;
1666
+ return e.showType === "search" ? i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }], staticClass: "document-content" }, [i("div", { staticClass: "document-content-search" }, [i("div", { staticClass: "search-path" }, [i("el-form", { ref: "ruleForm", attrs: { model: e.ruleFormData }, nativeOn: { submit: function(s) {
1667
+ s.preventDefault();
1668
+ } } }, [i("div", { staticClass: "search-list" }, [i("div", { staticClass: "search-input" }, [i("el-input", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.fileDocument.nameSearch", "\u8BF7\u8F93\u5165\u540D\u79F0\u67E5\u8BE2"), clearable: "", size: "mini", clearable: "" }, model: { value: e.ruleFormData.docName, callback: function(s) {
1669
+ e.$set(e.ruleFormData, "docName", s);
1670
+ }, expression: "ruleFormData.docName" } })], 1), i("div", { staticClass: "search-select" }, [i("el-select", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.fileDocument.typeSearch", "\u8BF7\u9009\u62E9\u6587\u4EF6\u7C7B\u578B"), multiple: "", size: "mini", "collapse-tags": "", clearable: "" }, model: { value: e.ruleFormData.type, callback: function(s) {
1671
+ e.$set(e.ruleFormData, "type", s);
1672
+ }, expression: "ruleFormData.type" } }, e._l(e.getDictionary("sys_doc_objects_type"), function(s) {
1673
+ return i("el-option", { key: s.code, attrs: { label: e.$i18nt(`Dynamics.${s.transkey}`, s.name), value: s.code } });
1674
+ }), 1)], 1), i("div", { staticClass: "search-input" }, [i("el-date-picker", { staticStyle: { width: "100%" }, attrs: { type: "date", placeholder: e.$i18nt("gd.fileDocument.timeSearch", "\u8BF7\u9009\u62E9\u4E0A\u4F20\u65E5\u671F"), "picker-options": e.pickerOptions, size: "mini", clearable: "", "value-format": e.valueFormat, format: e.valueFormat }, model: { value: e.ruleFormData.uploadTime, callback: function(s) {
1675
+ e.$set(e.ruleFormData, "uploadTime", s);
1676
+ }, expression: "ruleFormData.uploadTime" } })], 1), i("div", { staticClass: "search-num" }, [i("el-input-number", { staticStyle: { flex: "1" }, attrs: { min: 0, max: e.ruleFormData.maxSize - 1 || 999999999, placeholder: e.$i18nt("gd.form.minimum", "\u6700\u5C0F\u503C"), "controls-position": "right", size: "mini", controls: !1, clearable: "" }, model: { value: e.ruleFormData.minSize, callback: function(s) {
1677
+ e.$set(e.ruleFormData, "minSize", s);
1678
+ }, expression: "ruleFormData.minSize" } }), i("div", { staticClass: "zhi" }, [e._v("~")]), i("el-input-number", { staticStyle: { flex: "1" }, attrs: { min: e.ruleFormData.minSize + 1 || 0, max: 999999999, placeholder: e.$i18nt("gd.form.maximum", "\u6700\u5927\u503C"), "controls-position": "right", size: "mini", controls: !1, clearable: "" }, model: { value: e.ruleFormData.maxSize, callback: function(s) {
1679
+ e.$set(e.ruleFormData, "maxSize", s);
1680
+ }, expression: "ruleFormData.maxSize" } })], 1)])])], 1), i("div", { staticClass: "title-btn" }, [i("gd-btn-list", { attrs: { sysViewButtons: e.sysViewButtons }, on: { functionName: e.doEvent } })], 1)]), i("div", { staticClass: "document-content-list" }, [i("div", { staticClass: "search-list" }, [e._l(e.list, function(s) {
1681
+ return [i("div", { staticClass: "search-list-item", class: e.selItem.id === s.id ? "active-sel" : "", on: { click: function(r) {
1682
+ return e.handleSelItem(s);
1683
+ }, contextmenu: function(r) {
1684
+ return r.preventDefault(), e.handleContextmenu(r, s);
1685
+ } } }, [i("div", { staticClass: "item-icon" }, [i("i", { staticClass: "gd-icons", class: s.icon })]), i("div", { staticClass: "itemc" }, [i("div", { staticClass: "itemc-name", domProps: { innerHTML: e._s(s.highlightedText) } }), i("div", { staticClass: "itemc-path line1", attrs: { title: s.filePath } }, [e._v(e._s(s.filePath))])]), i("div", { staticClass: "itemr" }, [i("div", { staticClass: "itemr-time" }, [e._v(e._s(s.uploaddate))]), s.size !== 0 ? i("div", { staticClass: "itemr-size" }, [e._v(e._s(s.size))]) : e._e()])])];
1686
+ })], 2), e.noData ? i("div", { staticClass: "empty" }, [e._m(0), i("div", { staticClass: "empty-title" }, [i("span", [e._v(e._s(e.$i18nt("gd.echarts.noData", "\u6682\u65E0\u6570\u636E\u5C55\u793A")))])])]) : e._e()]), i("ContextMenu", { ref: "contextMenu", attrs: { recordData: e.recordData, treeData: e.treeData }, on: { versionControl: e.versionControl, seeAttribute: e.seeAttribute, selPopover: e.selPopover, selPopoverOpen: e.selPopoverOpen, doClose: e.doClose } })], 1) : e._e();
1687
+ }, Qe = [function() {
1688
+ var t = this, e = t._self._c;
1689
+ return e("div", { staticClass: "empty-icon" }, [e("i", { staticClass: "el-icon-receiving" })]);
1690
+ }], Ge = /* @__PURE__ */ d(
1691
+ Je,
1692
+ We,
1693
+ Qe,
1694
+ !1,
1695
+ null,
1696
+ "58886402",
1697
+ null,
1698
+ null
1699
+ );
1700
+ const Xe = Ge.exports, Ye = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1701
+ __proto__: null,
1702
+ default: Xe
1703
+ }, Symbol.toStringTag, { value: "Module" }));
1704
+ const Ze = {
1705
+ data() {
1706
+ return {
1707
+ type: "",
1708
+ record: null,
1709
+ width: "700px",
1710
+ confirmLoading: !1,
1711
+ visible: !1,
1712
+ fullscreen: !1,
1713
+ parentId: 0,
1714
+ parentList: [],
1715
+ buttons: [
1716
+ {
1717
+ displayName: "\u786E\u5B9A",
1718
+ functionName: "handleSubmit",
1719
+ show: !0,
1720
+ transKey: "gd.btn.confirm",
1721
+ icon: "el-icon-document-checked"
1722
+ }
1723
+ ],
1724
+ ruleForm: {},
1725
+ rules: {
1726
+ name: [
1727
+ { required: !0, message: this.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), trigger: ["change", "blur"] },
1728
+ {
1729
+ pattern: /^((?!\\|\/|:|\*|\?|<|>|\||'|%|\!|"|').){1,50}$/,
1730
+ message: this.$i18nt("gd.fileDocument.addNameTip", '\u540D\u79F0\u4E0D\u80FD\u5305\u542B\u4EE5\u4E0B\u5B57\u7B26\uFF1A<>:"/|?*%!')
1731
+ },
1732
+ { validator: this.validateName, trigger: ["change", "blur"] }
1733
+ ]
1734
+ }
1735
+ };
1736
+ },
1737
+ computed: {
1738
+ disabled() {
1739
+ return !0;
1740
+ },
1741
+ title() {
1742
+ return this.type === "rename" ? this.$i18nt("gd.btn.rename", "\u91CD\u547D\u540D") : this.$i18nt("gd.btn.createSubfolders", "\u521B\u5EFA\u6587\u4EF6\u5939");
1743
+ },
1744
+ fileName() {
1745
+ return this.type === "rename" ? this.$i18nt("gd.fileDocument.newFileName", "\u65B0\u540D\u79F0") : this.$i18nt("gd.translation.name", "\u540D\u79F0");
1746
+ },
1747
+ ...u(["primaryColor"])
1748
+ },
1749
+ methods: {
1750
+ validateName(t, e, i) {
1751
+ if (e) {
1752
+ if (this.type === "rename" && e === this.ruleForm.oname)
1753
+ return i(new Error(this.$i18nt("gd.fileDocument.renameTip", "\u65B0\u540D\u79F0\u4E0D\u80FD\u4E0E\u5F53\u524D\u540D\u79F0\u91CD\u590D")));
1754
+ i();
1755
+ } else
1756
+ return i(new Error(this.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165")));
1757
+ },
1758
+ inputName(t) {
1759
+ this.ruleForm.name = t.replace(/\s+/g, "");
1760
+ },
1761
+ add() {
1762
+ let t = {
1763
+ name: this.ruleForm.name,
1764
+ parentid: this.ruleForm.parentid,
1765
+ type: this.ruleForm.type,
1766
+ inheritpermissions: this.ruleForm.inheritpermissions
1767
+ };
1768
+ this.confirmLoading = !0, P(t).then((e) => {
1769
+ e.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok", t), this.closed()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + e.message), this.confirmLoading = !1;
1770
+ });
1771
+ },
1772
+ edit() {
1773
+ this.confirmLoading = !0;
1774
+ const t = this.type === "rename" ? { docId: this.record.id, newName: this.ruleForm.name } : Object.assign({}, this.record, this.ruleForm);
1775
+ (this.type === "rename" ? q : I)(t).then((i) => {
1776
+ i.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok", t), this.closed()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + i.message), this.confirmLoading = !1;
1777
+ });
1778
+ },
1779
+ handleSubmit() {
1780
+ this.$refs.ruleForm.validate((t) => {
1781
+ if (t) {
1782
+ if (["createsubfolder", "createrootdirectory"].includes(this.type)) {
1783
+ this.add();
1784
+ return;
1785
+ }
1786
+ this.edit();
1787
+ }
1788
+ });
1789
+ },
1790
+ open(t, e) {
1791
+ this.type = e, this.record = t, this.visible = !0;
1792
+ let i = {}, s = "", r = {
1793
+ parentid: t && t.parentid ? t.parentid : 0,
1794
+ name: "",
1795
+ type: t && t.type ? String(t.type) : "1",
1796
+ inheritpermissions: t ? t.inheritpermissions : 1
1797
+ };
1798
+ e === "createsubfolder" ? (this.parentId = t ? t.id : 0, this.parentList = [{ name: t.name, id: t.id }], i = { parentid: this.parentId }, s = "ruleFormName") : e === "rename" ? (i = { oname: t.name, name: "" }, s = "ruleFormName") : e === "createrootdirectory" && (s = "ruleFormName"), this.ruleForm = Object.assign(r, i), this.$nextTick(() => {
1799
+ setTimeout(() => {
1800
+ this.$refs.ruleForm && this.$refs.ruleForm.clearValidate(), s && this.$refs[s].focus();
1801
+ }, 0);
1802
+ });
1803
+ },
1804
+ closed() {
1805
+ this.ruleForm = {}, this.fullscreen = !1, this.visible = !1;
1806
+ },
1807
+ getDictionary(t) {
1808
+ return this.$options.filters.dictData(t);
1809
+ },
1810
+ toggleFullscreen() {
1811
+ this.fullscreen = !this.fullscreen;
1812
+ },
1813
+ doEvent(t) {
1814
+ let e = t.item.functionName;
1815
+ this[e] && this[e]();
1816
+ }
1817
+ }
1818
+ };
1819
+ var et = function() {
1820
+ var e = this, i = e._self._c;
1821
+ return i("div", [i("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "append-to-body": !0, "modal-append-to-body": !1, top: "80px", "show-close": !1 }, on: { "update:visible": function(s) {
1822
+ e.visible = s;
1823
+ }, closed: e.closed } }, [i("gd-modal-title", { attrs: { slot: "title", title: e.title, fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen }, slot: "title" }), i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }] }, [e.visible ? i("el-form", { ref: "ruleForm", staticClass: "gd-form", staticStyle: { width: "90%", margin: "0 auto" }, attrs: { model: e.ruleForm, "label-width": "140px", rules: e.rules }, nativeOn: { submit: function(s) {
1824
+ s.preventDefault();
1825
+ } } }, [["createsubfolder"].includes(e.type) ? i("el-form-item", { attrs: { label: e.$i18nt("gd.fileDocument.parentDirectory", "\u4E0A\u7EA7\u76EE\u5F55") } }, [i("el-select", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.btn.select", "\u8BF7\u9009\u62E9"), disabled: e.disabled }, model: { value: e.ruleForm.parentid, callback: function(s) {
1826
+ e.$set(e.ruleForm, "parentid", s);
1827
+ }, expression: "ruleForm.parentid" } }, e._l(e.parentList, function(s) {
1828
+ return i("el-option", { key: s.id, attrs: { label: s.name, value: s.id } });
1829
+ }), 1)], 1) : e._e(), ["rename"].includes(e.type) ? i("el-form-item", { attrs: { label: e.$i18nt("gd.fileDocument.currentFileName", "\u5F53\u524D\u540D\u79F0") } }, [i("el-input", { attrs: { placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), disabled: "" }, model: { value: e.ruleForm.oname, callback: function(s) {
1830
+ e.$set(e.ruleForm, "oname", s);
1831
+ }, expression: "ruleForm.oname" } })], 1) : e._e(), i("el-form-item", { attrs: { label: e.fileName, prop: "name" } }, [i("el-input", { ref: "ruleFormName", attrs: { placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), maxlength: 50 }, on: { input: e.inputName }, model: { value: e.ruleForm.name, callback: function(s) {
1832
+ e.$set(e.ruleForm, "name", s);
1833
+ }, expression: "ruleForm.name" } })], 1), ["createsubfolder", "createrootdirectory"].includes(e.type) ? i("el-form-item", { attrs: { label: e.$i18nt("gd.file.fileAccept", "\u6587\u4EF6\u7C7B\u578B"), prop: "type" } }, [i("el-select", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.btn.select", "\u8BF7\u9009\u62E9"), disabled: "" }, model: { value: e.ruleForm.type, callback: function(s) {
1834
+ e.$set(e.ruleForm, "type", s);
1835
+ }, expression: "ruleForm.type" } }, e._l(e.getDictionary("sys_doc_objects_type"), function(s) {
1836
+ return i("el-option", { key: s.code, attrs: { label: e.$i18nt(`Dynamics.${s.transkey}`, s.name), value: s.code } });
1837
+ }), 1)], 1) : e._e(), ["createsubfolder"].includes(e.type) ? i("el-form-item", { attrs: { label: e.$i18nt("gd.fileDocument.inheritedPermissions", "\u7EE7\u627F\u6743\u9650") } }, [i("el-switch", { attrs: { "active-value": 1, "inactive-value": 0, "active-color": e.primaryColor }, model: { value: e.ruleForm.inheritpermissions, callback: function(s) {
1838
+ e.$set(e.ruleForm, "inheritpermissions", s);
1839
+ }, expression: "ruleForm.inheritpermissions" } })], 1) : e._e()], 1) : e._e()], 1)], 1)], 1);
1840
+ }, tt = [], it = /* @__PURE__ */ d(
1841
+ Ze,
1842
+ et,
1843
+ tt,
1844
+ !1,
1845
+ null,
1846
+ "a9a3fa42",
1847
+ null,
1848
+ null
1849
+ );
1850
+ const st = it.exports, rt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1851
+ __proto__: null,
1852
+ default: st
1853
+ }, Symbol.toStringTag, { value: "Module" }));
1854
+ const at = {
1855
+ props: {
1856
+ treeData: {
1857
+ type: Array,
1858
+ default: () => []
1859
+ }
1860
+ },
1861
+ data() {
1862
+ return {
1863
+ privName: ["createfile", "createsubfolder"],
1864
+ record: null,
1865
+ width: "700px",
1866
+ confirmLoading: !1,
1867
+ visible: !1,
1868
+ orgTreeShow: !1,
1869
+ fullscreen: !1,
1870
+ buttons: [
1871
+ {
1872
+ displayName: "\u786E\u5B9A",
1873
+ functionName: "handleSubmit",
1874
+ show: !0,
1875
+ transKey: "gd.btn.confirm",
1876
+ icon: "el-icon-document-checked"
1877
+ }
1878
+ ],
1879
+ ruleForm: {
1880
+ oparentid: "",
1881
+ parentid: "",
1882
+ name: ""
1883
+ },
1884
+ rules: {
1885
+ parentid: [
1886
+ { required: !0, message: this.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), trigger: ["change", "blur"] },
1887
+ { validator: this.validateParentid, trigger: ["change", "blur"] }
1888
+ ]
1889
+ },
1890
+ orgTree: [],
1891
+ propsData: {
1892
+ label: "name",
1893
+ children: "children",
1894
+ value: "id"
1895
+ },
1896
+ hasPermission: []
1897
+ };
1898
+ },
1899
+ computed: {},
1900
+ methods: {
1901
+ save() {
1902
+ this.confirmLoading = !0;
1903
+ const t = {
1904
+ docId: this.record.id,
1905
+ destinationObjId: this.ruleForm.parentid
1906
+ };
1907
+ H(t).then((e) => {
1908
+ e.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok", t), this.closed()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + e.message), this.confirmLoading = !1;
1909
+ });
1910
+ },
1911
+ handleSubmit() {
1912
+ this.$refs.ruleForm.validate((t) => {
1913
+ t && this.save();
1914
+ });
1915
+ },
1916
+ validateParentid(t, e, i) {
1917
+ e === this.ruleForm.oparentid ? i(new Error(this.$i18nt("gd.fileDocument.folderTip", "\u4E0D\u80FD\u4E3A\u540C\u4E00\u6587\u4EF6\u5939"))) : i();
1918
+ },
1919
+ open(t) {
1920
+ this.record = t, this.confirmLoading = !0, this.visible = !0, Promise.all([this.getDetail(), this.allDocListPriv()]).then(() => {
1921
+ let e = this.treeData.filter((s) => s.id !== this.record.id).map((s) => Object.assign(s, {
1922
+ disabled: !this.hasPermission.includes(s.id)
1923
+ })), i = [];
1924
+ x(e, i, 0), this.orgTree = [{ name: "Root", id: 0, parentid: -1, children: i, disabled: !this.hasPermission.includes(0) }], this.ruleForm = {
1925
+ oparentid: this.record.parentid,
1926
+ parentid: "",
1927
+ name: this.record.name
1928
+ }, this.orgTreeShow = !0, this.$nextTick(() => {
1929
+ setTimeout(() => {
1930
+ this.$refs.ruleForm && this.$refs.ruleForm.clearValidate(), this.confirmLoading = !1;
1931
+ }, 100);
1932
+ });
1933
+ });
1934
+ },
1935
+ getDetail() {
1936
+ return _({ id: this.record.id }).then((t) => (t.code === 200 && (this.record = t.data), t.data));
1937
+ },
1938
+ allDocListPriv() {
1939
+ const t = this.record.type === 1 ? 1 : 0;
1940
+ return U({ privName: this.privName[t] }).then((e) => {
1941
+ if (e.code === 200) {
1942
+ let i = [];
1943
+ e.data.forEach((s) => {
1944
+ i.push(s.id);
1945
+ }), this.hasPermission = i;
1946
+ }
1947
+ return e.data;
1948
+ });
1949
+ },
1950
+ closed() {
1951
+ this.ruleForm = {
1952
+ oparentid: "",
1953
+ parentid: "",
1954
+ name: ""
1955
+ }, this.fullscreen = !1, this.visible = !1, this.orgTreeShow = !1;
1956
+ },
1957
+ getDictionary(t) {
1958
+ return this.$options.filters.dictData(t);
1959
+ },
1960
+ doEvent(t) {
1961
+ let e = t.item.functionName;
1962
+ this[e] && this[e]();
1963
+ }
1964
+ }
1965
+ };
1966
+ var nt = function() {
1967
+ var e = this, i = e._self._c;
1968
+ return i("div", [i("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "append-to-body": !0, "modal-append-to-body": !1, top: "80px", "show-close": !1 }, on: { "update:visible": function(s) {
1969
+ e.visible = s;
1970
+ }, closed: e.closed } }, [i("gd-modal-title", { attrs: { slot: "title", title: e.$i18nt("gd.btn.move", "\u79FB\u52A8"), fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent }, slot: "title" }), i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }] }, [e.visible ? i("el-form", { ref: "ruleForm", staticClass: "gd-form", staticStyle: { width: "90%", margin: "0 auto" }, attrs: { model: e.ruleForm, "label-width": "140px", rules: e.rules }, nativeOn: { submit: function(s) {
1971
+ s.preventDefault();
1972
+ } } }, [i("el-form-item", { attrs: { label: e.$i18nt("gd.translation.name", "\u540D\u79F0"), prop: "name" } }, [i("el-input", { attrs: { placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), disabled: "" }, model: { value: e.ruleForm.name, callback: function(s) {
1973
+ e.$set(e.ruleForm, "name", s);
1974
+ }, expression: "ruleForm.name" } })], 1), i("el-form-item", { attrs: { label: e.$i18nt("gd.fileDocument.originalParentDirectory", "\u539F\u4E0A\u7EA7\u76EE\u5F55"), prop: "oparentid" } }, [e.orgTreeShow ? i("gd-select-tree", { attrs: { filterable: !0, "tree-options": e.orgTree, "default-value": e.ruleForm.oparentid, placeholder: e.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), disabled: "", defaultProps: e.propsData }, model: { value: e.ruleForm.oparentid, callback: function(s) {
1975
+ e.$set(e.ruleForm, "oparentid", s);
1976
+ }, expression: "ruleForm.oparentid" } }) : e._e()], 1), i("el-form-item", { attrs: { label: e.$i18nt("gd.fileDocument.parentDirectory", "\u4E0A\u7EA7\u76EE\u5F55"), prop: "parentid" } }, [i("gd-select-tree", { attrs: { filterable: !0, "tree-options": e.orgTree, placeholder: e.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), defaultProps: e.propsData }, model: { value: e.ruleForm.parentid, callback: function(s) {
1977
+ e.$set(e.ruleForm, "parentid", s);
1978
+ }, expression: "ruleForm.parentid" } })], 1)], 1) : e._e()], 1)], 1)], 1);
1979
+ }, lt = [], ot = /* @__PURE__ */ d(
1980
+ at,
1981
+ nt,
1982
+ lt,
1983
+ !1,
1984
+ null,
1985
+ "55b5c379",
1986
+ null,
1987
+ null
1988
+ );
1989
+ const ct = ot.exports, dt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
1990
+ __proto__: null,
1991
+ default: ct
1992
+ }, Symbol.toStringTag, { value: "Module" }));
1993
+ const ut = {
1994
+ props: {
1995
+ limit: {
1996
+ type: Number,
1997
+ default: 12
1998
+ },
1999
+ fileAccept: {
2000
+ type: String,
2001
+ default: ""
2002
+ },
2003
+ fileSize: {
2004
+ type: Number,
2005
+ default: 1024
2006
+ }
2007
+ },
2008
+ data() {
2009
+ return {
2010
+ ruleFormRecord: {
2011
+ options: {
2012
+ fileName: "file",
2013
+ drag: !0
2014
+ }
2015
+ },
2016
+ record: null,
2017
+ width: "80%",
2018
+ confirmLoading: !1,
2019
+ visible: !1,
2020
+ fullscreen: !1,
2021
+ parentId: 0,
2022
+ parentList: [],
2023
+ docTypeList: [],
2024
+ buttons: [
2025
+ {
2026
+ displayName: "\u786E\u5B9A",
2027
+ functionName: "handleSubmit",
2028
+ show: !0,
2029
+ transKey: "gd.btn.confirm",
2030
+ icon: "el-icon-document-checked"
2031
+ }
2032
+ ],
2033
+ ruleForm: {
2034
+ file: "",
2035
+ fileList: []
2036
+ },
2037
+ rules: {
2038
+ name: [
2039
+ { required: !0, message: this.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), trigger: ["change", "blur"] },
2040
+ {
2041
+ pattern: /^((?!\\|\/|:|\*|\?|<|>|\||'|%|\!|"|').){1,50}$/,
2042
+ message: this.$i18nt("gd.fileDocument.addNameTip", '\u540D\u79F0\u4E0D\u80FD\u5305\u542B\u4EE5\u4E0B\u5B57\u7B26\uFF1A<>:"/|?*%!')
2043
+ }
2044
+ ],
2045
+ file: [{ required: !0, message: this.$i18nt("gd.web.selectFileTip", "\u8BF7\u9009\u62E9\u6587\u4EF6!"), trigger: ["change", "blur"] }]
2046
+ },
2047
+ rulesName: [
2048
+ { required: !0, message: this.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), trigger: ["change", "blur"] },
2049
+ {
2050
+ pattern: /^((?!\\|\/|:|\*|\?|<|>|\||'|%|\!|"|').){1,50}$/,
2051
+ message: this.$i18nt("gd.fileDocument.addNameTip", '\u540D\u79F0\u4E0D\u80FD\u5305\u542B\u4EE5\u4E0B\u5B57\u7B26\uFF1A<>:"/|?*%!')
2052
+ }
2053
+ ],
2054
+ fileList: [],
2055
+ fileData: []
2056
+ };
2057
+ },
2058
+ components: { UploadFile: N, LayoutItemColumn: () => Promise.resolve().then(() => T) },
2059
+ computed: {
2060
+ rulesInput() {
2061
+ return [{ required: !0, message: this.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), trigger: ["change", "blur"] }];
2062
+ },
2063
+ rulesSelect() {
2064
+ return [{ required: !0, message: this.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), trigger: ["change", "blur"] }];
2065
+ },
2066
+ timeLongshort() {
2067
+ return this.getDictionary("time_longshort");
2068
+ },
2069
+ title() {
2070
+ const t = this.$i18nt("gd.btn.createfile", "\u521B\u5EFA\u6587\u4EF6"), e = this.parentList.filter((s) => s.id === this.parentId)[0], i = e ? ` (${e.name})` : "";
2071
+ return `${t}${i}`;
2072
+ },
2073
+ ...u(["primaryColor"])
2074
+ },
2075
+ methods: {
2076
+ saveFail(t) {
2077
+ t.forEach((e) => {
2078
+ e.res.success && this.delItem(e.data);
2079
+ }), this.$nextTick(() => {
2080
+ setTimeout(() => {
2081
+ this.ruleForm.fileList = this.ruleForm.fileList.map((e) => {
2082
+ const i = t.filter((s) => s.data.fileId === e.fileId)[0];
2083
+ return Object.assign(
2084
+ { ...e },
2085
+ {
2086
+ tip: i ? i.res.message : ""
2087
+ }
2088
+ );
2089
+ });
2090
+ }, 0);
2091
+ });
2092
+ },
2093
+ changeDocType(t, e) {
2094
+ const i = this.docTypeList.filter((l) => l.code === t)[0];
2095
+ if (!i) {
2096
+ Object.assign(e, {
2097
+ attributes: []
2098
+ });
2099
+ return;
2100
+ }
2101
+ this.confirmLoading = !0;
2102
+ let s = [], r = /* @__PURE__ */ new Map();
2103
+ i.sysdoctypeattributes.forEach((l) => {
2104
+ if (l.ishidden !== 1) {
2105
+ const o = JSON.parse(l.reserve1);
2106
+ s.push({
2107
+ label: l.name,
2108
+ transKey: l.transkey ? `Dynamics.${l.transkey}` : null,
2109
+ prop: l.attrcode,
2110
+ dictTypeCode: l.dicttypecode,
2111
+ effectType: l.datatype,
2112
+ rules: l.statecodes !== 1 ? [] : l.isrequired === 1 ? C(l, {
2113
+ rulesInput: this.rulesInput,
2114
+ rulesSelect: this.rulesSelect
2115
+ }) : [],
2116
+ pickerType: D(l, this.timeLongshort),
2117
+ fieldFormat: p(l, this.timeLongshort),
2118
+ fkEntityName: l.fkentity,
2119
+ fieldsize: l.datatype === "inputnumber" ? 0 : l.fieldsize,
2120
+ isDatePicker: k(l, this.timeLongshort),
2121
+ viewId: o.viewId ? o.viewId : "",
2122
+ disabled: l.statecodes !== 1
2123
+ }), r.set(l.attrcode, w(l));
2124
+ }
2125
+ });
2126
+ const a = this.ruleForm.fileList.map((l) => l.fileId === e.fileId ? Object.assign(
2127
+ l,
2128
+ Object.assign({}, l, Object.fromEntries(r), {
2129
+ attributes: s
2130
+ })
2131
+ ) : Object.assign({}, l)), n = Object.assign({}, this.ruleForm, {
2132
+ fileList: [...a]
2133
+ });
2134
+ this.ruleForm = JSON.parse(JSON.stringify(n)), setTimeout(() => {
2135
+ this.confirmLoading = !1;
2136
+ }, 300);
2137
+ },
2138
+ inputName(t, e) {
2139
+ e.name = t.replace(/\s+/g, "");
2140
+ },
2141
+ save() {
2142
+ this.confirmLoading = !0;
2143
+ let t = [];
2144
+ this.ruleForm.fileList.forEach((e, i) => {
2145
+ let s = this.add(e, i).then((r) => ({ data: e, res: r }));
2146
+ t.push(s);
2147
+ }), Promise.all(t).then((e) => {
2148
+ this.confirmLoading = !1;
2149
+ const i = e.filter((r) => !r.res.success);
2150
+ if (i.length === 0) {
2151
+ this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.closed(), this.$emit("ok");
2152
+ return;
2153
+ }
2154
+ i.length < e.length && this.$emit("ok");
2155
+ let s = "";
2156
+ i.forEach((r) => {
2157
+ s += `<p>${r.data.name} ${r.res.message}</p>`;
2158
+ }), this.saveFail(e), this.$message({
2159
+ message: `${this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25")}${s}`,
2160
+ type: "error",
2161
+ dangerouslyUseHTMLString: !0
2162
+ });
2163
+ });
2164
+ },
2165
+ add(t) {
2166
+ let e = [];
2167
+ t.attributes.forEach((r) => {
2168
+ e.push({ attrCode: r.prop, attrValue: ["checkbox"].includes(r.effectType) ? t[r.prop].join(",") : t[r.prop] });
2169
+ });
2170
+ const i = this.docTypeList.filter((r) => r.code === t.sysdoctypeid)[0], s = {
2171
+ name: t.name,
2172
+ parentid: this.ruleForm.parentid,
2173
+ type: 2,
2174
+ inheritpermissions: t.inheritpermissions,
2175
+ filetype: t.filetype,
2176
+ filesize: t.filesize,
2177
+ file: t.fileId,
2178
+ version: t.version,
2179
+ description: t.description,
2180
+ sysdoctypeid: i.id,
2181
+ attributes: e
2182
+ };
2183
+ return P(s).then((r) => r);
2184
+ },
2185
+ handleSubmit() {
2186
+ if ((this.ruleFormRecord.uidUploading ? this.ruleFormRecord.uidUploading : []).length > 0) {
2187
+ this.$message.error(`${this.$i18nt("gd.https.uidUploading", "\u6587\u4EF6\u6B63\u5728\u4E0A\u4F20\u4E2D,\u8BF7\u7B49\u5F85..")}`);
2188
+ return;
2189
+ }
2190
+ this.$refs.ruleForm.validate((e) => {
2191
+ e && this.save();
2192
+ });
2193
+ },
2194
+ delItem(t) {
2195
+ this.ruleForm.fileList = this.ruleForm.fileList.filter((e) => e.fileId !== t.fileId), this.$refs.uploadFile.removeFileManual(t.fileId);
2196
+ },
2197
+ handleChange(t) {
2198
+ this.confirmLoading = !0;
2199
+ const e = JSON.parse(t.sourceData);
2200
+ let i = [];
2201
+ e.forEach((s) => {
2202
+ const r = s.name.substr(s.name.lastIndexOf(".") + 1), a = this.fileData.filter((l) => l.uid === s.ouid)[0], n = this.ruleForm.fileList.filter((l) => l.fileId === s.fileId)[0];
2203
+ i.push({
2204
+ fileoriginname: s.fileoriginname,
2205
+ name: s.name,
2206
+ filetype: r,
2207
+ filesize: a ? a.size : 0,
2208
+ inheritpermissions: 1,
2209
+ fileId: s.fileId,
2210
+ ouid: s.ouid,
2211
+ tip: "",
2212
+ version: "",
2213
+ description: "",
2214
+ sysdoctypeid: "",
2215
+ attributes: n ? n.attributes : []
2216
+ });
2217
+ }), this.ruleForm.fileList = i, setTimeout(() => {
2218
+ this.confirmLoading = !1;
2219
+ }, 100);
2220
+ },
2221
+ uploadFile(t) {
2222
+ const e = this.fileData.filter((i) => i.uid !== t.file.uid);
2223
+ this.fileData = e.concat([t.file]);
2224
+ },
2225
+ getDocTypePage() {
2226
+ this.confirmLoading = !0, $({ pageno: this.pageno, pagesize: this.pagesize }).then((t) => {
2227
+ t.code === 200 && (this.docTypeList = t.data.rows.filter((e) => e.statecodes === 1)), this.confirmLoading = !1;
2228
+ });
2229
+ },
2230
+ open(t) {
2231
+ this.parentId = t ? t.id : "0", this.parentList = [{ name: t.name ? t.name : "root", id: t.id }], this.record = t, this.ruleForm = {
2232
+ parentid: t.id,
2233
+ file: "",
2234
+ fileList: []
2235
+ }, this.visible = !0, this.getDocTypePage(), this.$nextTick(() => {
2236
+ setTimeout(() => {
2237
+ this.$refs.ruleForm && this.$refs.ruleForm.clearValidate();
2238
+ }, 100);
2239
+ });
2240
+ },
2241
+ closed() {
2242
+ this.fileData = [], this.ruleForm = { fileList: [] }, this.fullscreen = !1, this.visible = !1;
2243
+ },
2244
+ getDictionary(t) {
2245
+ return this.$options.filters.dictData(t);
2246
+ },
2247
+ toggleFullscreen() {
2248
+ this.fullscreen = !this.fullscreen;
2249
+ },
2250
+ doEvent(t) {
2251
+ let e = t.item.functionName;
2252
+ this[e] && this[e]();
2253
+ }
2254
+ }
2255
+ };
2256
+ var ht = function() {
2257
+ var e = this, i = e._self._c;
2258
+ return i("div", [i("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "append-to-body": !0, "modal-append-to-body": !1, top: "80px", "show-close": !1 }, on: { "update:visible": function(s) {
2259
+ e.visible = s;
2260
+ }, closed: e.closed } }, [i("gd-modal-title", { attrs: { slot: "title", title: e.title, fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen }, slot: "title" }), i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }] }, [e.visible ? i("el-form", { ref: "ruleForm", staticClass: "gd-form", staticStyle: { width: "100%", margin: "0 auto" }, attrs: { model: e.ruleForm, "label-width": "160px", rules: e.rules }, nativeOn: { submit: function(s) {
2261
+ s.preventDefault();
2262
+ } } }, [i("el-form-item", { staticStyle: { width: "90%" }, attrs: { label: e.$i18nt("gd.page.uploadFile", "\u4E0A\u4F20\u6587\u4EF6"), prop: "file" } }, [i("UploadFile", { ref: "uploadFile", attrs: { record: e.ruleFormRecord, model: e.ruleForm, limit: e.limit, prop: "file", accept: e.fileAccept, size: e.fileSize }, on: { change: e.handleChange, uploadFile: e.uploadFile } })], 1), e._l(e.ruleForm.fileList, function(s, r) {
2263
+ return [i("div", { staticClass: "list" }, [i("el-alert", { staticStyle: { "margin-bottom": "12px" }, attrs: { title: s.fileoriginname, type: "info", closable: !1 } }), i("el-row", { attrs: { gutter: 24 } }, [i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { key: `${s.fileId}_name`, attrs: { label: e.$i18nt("gd.translation.name", "\u540D\u79F0"), prop: "fileList." + r + ".name", rules: e.rulesName } }, [i("el-input", { attrs: { clearable: "", placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), maxlength: 50 }, on: { input: (a) => e.inputName(a, s) }, model: { value: s.name, callback: function(a) {
2264
+ e.$set(s, "name", a);
2265
+ }, expression: "item.name" } })], 1)], 1), i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { attrs: { label: e.$i18nt("gd.fileDocument.inheritedPermissions", "\u7EE7\u627F\u6743\u9650"), title: e.$i18nt("gd.fileDocument.inheritedPermissions", "\u7EE7\u627F\u6743\u9650") } }, [i("el-switch", { attrs: { "active-value": 1, "inactive-value": 0, "active-color": e.primaryColor }, model: { value: s.inheritpermissions, callback: function(a) {
2266
+ e.$set(s, "inheritpermissions", a);
2267
+ }, expression: "item.inheritpermissions" } })], 1)], 1), i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { key: `${s.fileId}_sysdoctypeid`, attrs: { label: e.$i18nt("gd.fileDocument.classification", "\u6587\u6863\u5206\u7C7B"), rules: e.rulesSelect, prop: "fileList." + r + ".sysdoctypeid", title: e.$i18nt("gd.fileDocument.classification", "\u6587\u6863\u5206\u7C7B") } }, [i("el-select", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), clearable: "", remote: "", filterable: "" }, on: { change: (a) => e.changeDocType(a, s) }, model: { value: s.sysdoctypeid, callback: function(a) {
2268
+ e.$set(s, "sysdoctypeid", a);
2269
+ }, expression: "item.sysdoctypeid" } }, e._l(e.docTypeList, function(a) {
2270
+ return i("el-option", { key: a.code, attrs: { label: e.$i18nt(`Dynamics.${a.transkey}`, a.name), value: a.code } });
2271
+ }), 1)], 1)], 1), i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { attrs: { label: e.$i18nt("gd.solution.version", "\u7248\u672C"), title: e.$i18nt("gd.solution.version", "\u7248\u672C") } }, [i("el-input", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165") }, model: { value: s.version, callback: function(a) {
2272
+ e.$set(s, "version", a);
2273
+ }, expression: "item.version" } })], 1)], 1), i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { attrs: { label: e.$i18nt("gd.directory.remark", "\u5907\u6CE8"), title: e.$i18nt("gd.directory.remark", "\u5907\u6CE8") } }, [i("el-input", { attrs: { clearable: "", placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), type: "textarea", rows: 1 }, model: { value: s.description, callback: function(a) {
2274
+ e.$set(s, "description", a);
2275
+ }, expression: "item.description" } })], 1)], 1), e._l(s.attributes, function(a) {
2276
+ return [i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { key: `${a.fileId}_${a.prop}`, attrs: { label: e.$i18nt(a.transKey, a.label), prop: `fileList.${r}.${a.prop}`, rules: a.rules, title: e.$i18nt(a.transKey, a.label) } }, [i("LayoutItemColumn", { attrs: { record: a, ruleFormData: s } })], 1)], 1)];
2277
+ })], 2), i("div", { staticClass: "item-del" }, [i("i", { staticClass: "el-icon-close", on: { click: function(a) {
2278
+ return e.delItem(s);
2279
+ } } })]), s.tip ? i("el-tooltip", { staticClass: "item-tooltip", attrs: { effect: "dark", placement: "top-start" } }, [i("i", { staticClass: "el-icon-warning", staticStyle: { color: "red" } }), i("div", { staticClass: "list-tip", attrs: { slot: "content" }, slot: "content" }, [e._v(e._s(s.tip))])]) : e._e()], 1)];
2280
+ })], 2) : e._e()], 1)], 1)], 1);
2281
+ }, pt = [], ft = /* @__PURE__ */ d(
2282
+ ut,
2283
+ ht,
2284
+ pt,
2285
+ !1,
2286
+ null,
2287
+ "3f9cc7b9",
2288
+ null,
2289
+ null
2290
+ );
2291
+ const mt = ft.exports, gt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2292
+ __proto__: null,
2293
+ default: mt
2294
+ }, Symbol.toStringTag, { value: "Module" }));
2295
+ const vt = {
2296
+ props: {
2297
+ treeData: {
2298
+ type: Array,
2299
+ default: () => []
2300
+ },
2301
+ multipleLimit: {
2302
+ type: Number,
2303
+ default: 12
2304
+ }
2305
+ },
2306
+ components: { AddPermission: () => Promise.resolve().then(() => Ht) },
2307
+ data() {
2308
+ return {
2309
+ tableColumns: [
2310
+ {
2311
+ type: "selection",
2312
+ width: "60",
2313
+ fixed: !0
2314
+ },
2315
+ {
2316
+ transKey: "gd.directory.name",
2317
+ prop: "name",
2318
+ label: "\u540D\u79F0",
2319
+ align: "left",
2320
+ width: "210",
2321
+ fixed: !0,
2322
+ type: "slot",
2323
+ slotType: "name"
2324
+ },
2325
+ {
2326
+ transKey: "gd.application.inherit",
2327
+ prop: "inherit",
2328
+ label: "\u7EE7\u627F",
2329
+ width: "120",
2330
+ align: "center",
2331
+ type: "slot",
2332
+ slotType: "inherit"
2333
+ },
2334
+ {
2335
+ transKey: "gd.fileDocument.allow",
2336
+ prop: "allow",
2337
+ label: "\u5141\u8BB8",
2338
+ align: "left",
2339
+ width: "420",
2340
+ type: "slot",
2341
+ slotType: "allow"
2342
+ },
2343
+ {
2344
+ transKey: "gd.fileDocument.refuse",
2345
+ prop: "refuse",
2346
+ label: "\u62D2\u7EDD",
2347
+ align: "left",
2348
+ width: "420",
2349
+ type: "slot",
2350
+ slotType: "refuse"
2351
+ }
2352
+ ],
2353
+ tableButtons: [
2354
+ {
2355
+ displayName: "\u65B0\u589E",
2356
+ functionName: "add",
2357
+ show: !0,
2358
+ transKey: "gd.btn.add",
2359
+ icon: "el-icon-plus"
2360
+ },
2361
+ {
2362
+ displayName: "\u7F16\u8F91",
2363
+ functionName: "edit",
2364
+ show: !0,
2365
+ transKey: "gd.btn.edit",
2366
+ icon: "el-icon-edit"
2367
+ },
2368
+ {
2369
+ displayName: "\u5220\u9664",
2370
+ functionName: "del",
2371
+ show: !0,
2372
+ transKey: "gd.btn.del",
2373
+ icon: "el-icon-delete",
2374
+ btnType: "danger"
2375
+ }
2376
+ ],
2377
+ record: null,
2378
+ isInherit: 1,
2379
+ width: "90%",
2380
+ confirmLoading: !1,
2381
+ visible: !1,
2382
+ fullscreen: !1,
2383
+ selectedRowKeys: [],
2384
+ selectedRows: [],
2385
+ allIds: [],
2386
+ disabledRowId: [],
2387
+ loadData: (t) => J({ docId: this.record.id }).then((e) => {
2388
+ if (e.code === 200) {
2389
+ let i = [], s = [];
2390
+ const r = e.data.map((a) => (i.push(a.principalid_aboutid), a.isinherit && s.push(a.id), Object.assign(a, this.getAllowRefuse(a))));
2391
+ return this.allIds = i, this.disabledRowId = s, { pageno: 1, totalrows: e.data.length, rows: r };
2392
+ }
2393
+ })
2394
+ };
2395
+ },
2396
+ computed: {
2397
+ hig() {
2398
+ return this.screenHeight - (this.fullscreen ? 80 : 264);
2399
+ },
2400
+ title() {
2401
+ const t = this.$i18nt("gd.btn.administrativePermissions", "\u7BA1\u7406\u6743\u9650");
2402
+ if (!this.record)
2403
+ return t;
2404
+ this.treeData.filter((s) => s.id === this.record.id)[0];
2405
+ let e = "";
2406
+ return (this.record.path ? this.record.path.split(".") : []).forEach((s) => {
2407
+ const r = this.treeData.filter((a) => a.id === Number(s))[0];
2408
+ e += r === void 0 ? "" : `/${r.name}`;
2409
+ }), this.record.type !== 1 && (e += `/${this.record.name}`), `${t} (${e})`;
2410
+ },
2411
+ ...u(["screenHeight", "primaryColor"])
2412
+ },
2413
+ methods: {
2414
+ saveConvertPermission({ data: t, action: e, instance: i, done: s }) {
2415
+ i.confirmButtonLoading = !0, i.cancelButtonLoading = !0, i.showCancelButton = !0;
2416
+ const r = {
2417
+ docId: this.record.id,
2418
+ inheritPermissions: t,
2419
+ isConvert: e === "confirm" ? 1 : 0
2420
+ };
2421
+ W(r).then((a) => {
2422
+ i.confirmButtonLoading = !1, i.cancelButtonLoading = !1, i.showCancelButton = !0, this.confirmLoading = !1, a.code === 200 ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.refresh(), s()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + a.message);
2423
+ });
2424
+ },
2425
+ inheritPermission(t) {
2426
+ let e = this;
2427
+ this.confirmLoading = !0, this.$confirm(this.$i18nt("gd.fileDocument.inheritParentPermissionsTip", "\u662F\u5426\u4ECE\u7236\u9879\u7EE7\u627F\u6743\u9650?"), this.$i18nt("gd.https.delTitle", "\u6E29\u99A8\u63D0\u793A"), {
2428
+ confirmButtonText: this.$i18nt("gd.btn.confirm", "\u786E\u8BA4"),
2429
+ cancelButtonText: this.$i18nt("gd.https.delCancel", "\u53D6\u6D88"),
2430
+ showClose: !1,
2431
+ confirmButtonLoading: !1,
2432
+ cancelButtonLoading: !1,
2433
+ closeOnClickModal: !1,
2434
+ type: "warning",
2435
+ confirmButtonClass: "el-button--danger",
2436
+ customClass: "custom-alert",
2437
+ callback: () => {
2438
+ },
2439
+ beforeClose: (i, s, r) => {
2440
+ if (i !== "confirm") {
2441
+ r(), e.confirmLoading = !1, e.isInherit = 0;
2442
+ return;
2443
+ }
2444
+ this.saveConvertPermission({ data: t, action: i, instance: s, done: r });
2445
+ }
2446
+ });
2447
+ },
2448
+ convertPermission(t) {
2449
+ this.$confirm(this.$i18nt("gd.fileDocument.closeParentPermissionsTip", "\u662F\u5426\u5173\u95ED\u4ECE\u7236\u9879\u7EE7\u627F\u6743\u9650?"), this.$i18nt("gd.https.delTitle", "\u6E29\u99A8\u63D0\u793A"), {
2450
+ confirmButtonText: this.$i18nt("gd.fileDocument.convertInheritedTip", "\u8F6C\u6362\u5DF2\u7EE7\u627F\u7684\u6743\u9650"),
2451
+ cancelButtonText: this.$i18nt("gd.fileDocument.deleteInherited", "\u5220\u9664\u5DF2\u7EE7\u627F\u7684\u6743\u9650"),
2452
+ confirmButtonLoading: !1,
2453
+ cancelButtonLoading: !1,
2454
+ closeOnClickModal: !1,
2455
+ type: "warning",
2456
+ confirmButtonClass: "el-button--danger",
2457
+ customClass: "custom-alert",
2458
+ distinguishCancelAndClose: !0,
2459
+ callback: () => {
2460
+ },
2461
+ beforeClose: (e, i, s) => {
2462
+ if (e === "close") {
2463
+ this.isInherit = 1, s();
2464
+ return;
2465
+ }
2466
+ this.saveConvertPermission({ data: t, action: e, instance: i, done: s }), i.confirmButtonLoading = !0, i.cancelButtonLoading = !0, i.showCancelButton = !1;
2467
+ }
2468
+ });
2469
+ },
2470
+ changeInherit(t) {
2471
+ t === 1 ? this.inheritPermission(t) : this.convertPermission(t);
2472
+ },
2473
+ editForm(t) {
2474
+ this.$refs.addPermission.open(t);
2475
+ },
2476
+ edit() {
2477
+ if (this.selectedRowKeys.length === 0) {
2478
+ this.$message.warning(this.$i18nt("gd.https.editTip", "\u8BF7\u9009\u62E9\u9700\u8981\u7F16\u8F91\u7684\u6570\u636E!"));
2479
+ return;
2480
+ }
2481
+ if (this.selectedRowKeys.length > 1) {
2482
+ this.$message.warning(this.$i18nt("gd.https.editTipOne", "\u53EA\u80FD\u9009\u62E9\u4E00\u6761\u6570\u636E\u7F16\u8F91!"));
2483
+ return;
2484
+ }
2485
+ this.editForm(this.selectedRows[0]);
2486
+ },
2487
+ del() {
2488
+ let t = this;
2489
+ this.$confirm(this.$i18nt("gd.https.delContent", "\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"), this.$i18nt("gd.https.delTitle", "\u6E29\u99A8\u63D0\u793A"), {
2490
+ confirmButtonText: this.$i18nt("gd.https.delOk", "\u786E\u5B9A\u5220\u9664"),
2491
+ cancelButtonText: this.$i18nt("gd.https.delCancel", "\u53D6\u6D88"),
2492
+ showClose: !1,
2493
+ confirmButtonLoading: !1,
2494
+ cancelButtonLoading: !1,
2495
+ closeOnClickModal: !1,
2496
+ type: "warning",
2497
+ confirmButtonClass: "el-button--danger",
2498
+ customClass: "custom-alert",
2499
+ callback: () => {
2500
+ },
2501
+ beforeClose: (e, i, s) => {
2502
+ if (e !== "confirm") {
2503
+ s();
2504
+ return;
2505
+ }
2506
+ i.confirmButtonLoading = !0, i.cancelButtonLoading = !0, i.showCancelButton = !1, Q({
2507
+ ids: this.selectedRowKeys.join(",")
2508
+ }).then((r) => {
2509
+ i.confirmButtonLoading = !1, i.cancelButtonLoading = !1, i.showCancelButton = !0, r.success ? (t.$message.success(t.$i18nt("gd.https.delSucc", "\u5220\u9664\u6210\u529F")), t.refresh(), s()) : t.$message.error(t.$i18nt("gd.https.delFail", "\u5220\u9664\u5931\u8D25") + r.message);
2510
+ });
2511
+ }
2512
+ });
2513
+ },
2514
+ getAllowRefuse(t) {
2515
+ let e = [], i = [];
2516
+ return h.forEach((s) => {
2517
+ const r = t[s.code];
2518
+ r !== "" && r !== null && r !== 0 && (r === 2 && i.push(s), r === 1 && e.push(s));
2519
+ }), { allow: e, refuse: i };
2520
+ },
2521
+ getDetail() {
2522
+ _({ id: this.record.id }).then((t) => {
2523
+ t.code === 200 && (this.record = t.data, this.isInherit = t.data.inheritpermissions);
2524
+ });
2525
+ },
2526
+ add() {
2527
+ this.$refs.addPermission.open(null);
2528
+ },
2529
+ refresh() {
2530
+ this.getDetail(), this.$refs.table && this.$refs.table.refresh();
2531
+ },
2532
+ triggerRefresh(t) {
2533
+ this.selectedRowKeys = [], this.selectedRows = [];
2534
+ },
2535
+ open(t) {
2536
+ this.isInherit = t.inheritpermissions, this.record = t, this.visible = !0, this.getDetail(), this.$nextTick(() => {
2537
+ setTimeout(() => {
2538
+ this.refresh();
2539
+ }, 0);
2540
+ });
2541
+ },
2542
+ closed() {
2543
+ this.ruleForm = {}, this.fullscreen = !1, this.visible = !1;
2544
+ },
2545
+ onSelectChange(t, e) {
2546
+ this.selectedRowKeys = t, this.selectedRows = e;
2547
+ },
2548
+ getDictionary(t) {
2549
+ return this.$options.filters.dictData(t);
2550
+ },
2551
+ toggleFullscreen() {
2552
+ this.fullscreen = !this.fullscreen;
2553
+ },
2554
+ doEvent(t) {
2555
+ let e = t.item.functionName;
2556
+ this[e] && this[e]();
2557
+ }
2558
+ }
2559
+ };
2560
+ var yt = function() {
2561
+ var e = this, i = e._self._c;
2562
+ return i("div", [i("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "append-to-body": !0, "modal-append-to-body": !1, top: "80px", "show-close": !1 }, on: { "update:visible": function(s) {
2563
+ e.visible = s;
2564
+ }, closed: e.closed } }, [i("gd-modal-title", { attrs: { slot: "title", title: e.title, fullscreen: e.fullscreen, buttons: e.tableButtons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen }, slot: "title" }), i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }], staticClass: "document-manage", staticStyle: { "margin-top": "-6px" } }, [i("gd-tables", { ref: "table", attrs: { dataSource: e.loadData, columns: e.tableColumns, initialLoading: !1, showPagination: !1, selectedRowKeys: e.selectedRowKeys, height: e.hig, disabledRowId: e.disabledRowId }, on: { onChange: e.onSelectChange, triggerRefresh: e.triggerRefresh }, scopedSlots: e._u([{ key: "operator", fn: function() {
2565
+ return [i("div", { staticClass: "operator" }, [i("el-switch", { attrs: { "active-color": e.primaryColor, "active-value": 1, "inactive-value": 0 }, on: { change: e.changeInherit }, model: { value: e.isInherit, callback: function(s) {
2566
+ e.isInherit = s;
2567
+ }, expression: "isInherit" } }), i("span", { class: e.isInherit === 1 ? "active-color" : "" }, [e._v(" " + e._s(e.$i18nt("gd.fileDocument.inheritParentPermissions", "\u4ECE\u7236\u6587\u4EF6\u5939\u7EE7\u627F\u6743\u9650")) + " ")])], 1)];
2568
+ }, proxy: !0 }, { key: "name", fn: function({ column: s, row: r }) {
2569
+ return [i("div", { on: { click: function(a) {
2570
+ return e.editForm(r);
2571
+ } } }, [i("span", { staticClass: "active-color", staticStyle: { cursor: "pointer", "padding-right": "4px" } }, [e._v(e._s(r.principalname))]), r.principalid_abouttable === "sys_user" ? i("span", [e._v("(" + e._s(e.$i18nt("gd.fieldSecurity.user", "\u7528\u6237")) + ")")]) : r.principalid_abouttable === "sys_team" ? i("span", [e._v("(" + e._s(e.$i18nt("gd.fieldSecurity.team", "\u56E2\u961F")) + ")")]) : e._e()])];
2572
+ } }, { key: "allow", fn: function({ column: s, row: r }) {
2573
+ return [i("div", { staticClass: "allow-item" }, e._l(r.allow, function(a) {
2574
+ return i("el-tag", { key: a.code, attrs: { type: "success", effect: "dark", size: "mini" } }, [e._v(" " + e._s(e.$i18nt(a.transkey, a.name)) + " ")]);
2575
+ }), 1)];
2576
+ } }, { key: "refuse", fn: function({ column: s, row: r }) {
2577
+ return [i("div", { staticClass: "allow-item" }, e._l(r.refuse, function(a) {
2578
+ return i("el-tag", { key: a.code, attrs: { type: "danger", effect: "dark", size: "mini" } }, [e._v(" " + e._s(e.$i18nt(a.transkey, a.name)) + " ")]);
2579
+ }), 1)];
2580
+ } }, { key: "inherit", fn: function({ column: s, row: r }) {
2581
+ return [r.isinherit ? i("i", { staticClass: "gd-icons gd-icon-xuanzhong active-color", staticStyle: { "font-size": "18px" } }) : i("i", { staticClass: "gd-icons gd-icon-jinyong1", staticStyle: { "font-size": "18px", color: "#999" } })];
2582
+ } }, { key: "handle", fn: function({ column: s, row: r }) {
2583
+ return [i("span", { staticClass: "active-color", staticStyle: { cursor: "pointer" } }, [e._v(e._s(e.$i18nt("gd.btn.edit", "\u7F16\u8F91")))]), i("el-divider", { attrs: { direction: "vertical" } }), i("span", { staticStyle: { color: "red", cursor: "pointer" } }, [e._v(e._s(e.$i18nt("gd.btn.del", "\u5220\u9664")))])];
2584
+ } }]) })], 1)], 1), i("AddPermission", { ref: "addPermission", attrs: { recordData: e.record, allIds: e.allIds, multipleLimit: e.multipleLimit }, on: { ok: e.refresh } })], 1);
2585
+ }, bt = [], _t = /* @__PURE__ */ d(
2586
+ vt,
2587
+ yt,
2588
+ bt,
2589
+ !1,
2590
+ null,
2591
+ "19358cd5",
2592
+ null,
2593
+ null
2594
+ );
2595
+ const $t = _t.exports, Ct = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2596
+ __proto__: null,
2597
+ default: $t
2598
+ }, Symbol.toStringTag, { value: "Module" }));
2599
+ const Dt = {
2600
+ props: {
2601
+ treeData: {
2602
+ type: Array,
2603
+ default: () => []
2604
+ },
2605
+ fileAccept: {
2606
+ type: String,
2607
+ default: ""
2608
+ },
2609
+ fileSize: {
2610
+ type: Number,
2611
+ default: 1024
2612
+ }
2613
+ },
2614
+ data() {
2615
+ return {
2616
+ maxLeg: 5,
2617
+ type: 2,
2618
+ record: {},
2619
+ statu: !1,
2620
+ confirmLoading: !1,
2621
+ visible: !1,
2622
+ fullscreen: !1,
2623
+ buttons: [
2624
+ {
2625
+ displayName: "\u5237\u65B0",
2626
+ functionName: "init",
2627
+ show: !0,
2628
+ transKey: "gd.basics.refresh",
2629
+ icon: "el-icon-refresh"
2630
+ }
2631
+ ],
2632
+ permissionMenus: [],
2633
+ attributesList: [],
2634
+ permissionData: {},
2635
+ docTypeList: [],
2636
+ docTypeData: {},
2637
+ activeName: "attribute"
2638
+ };
2639
+ },
2640
+ components: {
2641
+ ExtendedAttributes: () => Promise.resolve().then(() => Xt)
2642
+ },
2643
+ computed: {
2644
+ hasRename() {
2645
+ return this.permissionData.rename === 1;
2646
+ },
2647
+ docTypeName() {
2648
+ const t = this.record.sysdoctypeid ? this.record.sysdoctypeid : "", e = this.docTypeList.filter((i) => i.id === t)[0];
2649
+ return e ? this.$i18nt(`Dynamics.${e.transkey}`, e.name) : "";
2650
+ },
2651
+ title() {
2652
+ return this.record.name;
2653
+ },
2654
+ getHeight() {
2655
+ const t = this.fullscreen ? 206 : 380;
2656
+ return this.screenHeight - t;
2657
+ },
2658
+ pathAddress() {
2659
+ let t = "";
2660
+ return this.record.path === void 0 || (this.record.path.split(".").forEach((i) => {
2661
+ const s = this.treeData.filter((r) => r.id === Number(i))[0];
2662
+ t += s && i !== "0" ? `/${s.name}` : "";
2663
+ }), this.record.type !== 1 && (t += `/${this.record.name}`)), t;
2664
+ },
2665
+ fileIcon() {
2666
+ return L(this.record);
2667
+ },
2668
+ fileType() {
2669
+ const e = this.getDictionary("sys_doc_objects_type").filter((i) => i.code == this.record.type)[0];
2670
+ return e ? this.$i18nt(`Dynamics.${e.transkey}`, e.name) : this.record.type;
2671
+ },
2672
+ recordFileSize() {
2673
+ if (this.record.type === 1)
2674
+ return 0;
2675
+ const t = this.record.filesize ? this.record.filesize : 0;
2676
+ return this.getFilSize(t);
2677
+ },
2678
+ timeLongshort() {
2679
+ return this.getDictionary("time_longshort");
2680
+ },
2681
+ ...u(["primaryColor", "tablePageSize", "tableSize", "screenHeight", "tableLists"])
2682
+ },
2683
+ methods: {
2684
+ editExtendedAttributes() {
2685
+ this.$refs.extendedAttributes.open(this.record);
2686
+ },
2687
+ seeFkItem(t) {
2688
+ const e = this.tableLists.filter((r) => r.tablename === t.fkentity)[0];
2689
+ this.statu = !0;
2690
+ let i = {
2691
+ tableId: e.id,
2692
+ data: [
2693
+ {
2694
+ id: t.fkId
2695
+ }
2696
+ ]
2697
+ };
2698
+ const s = this.$message({
2699
+ message: this.$i18nt("gd.https.Loading", "\u52A0\u8F7D\u4E2D..."),
2700
+ duration: 0,
2701
+ iconClass: "el-icon-loading"
2702
+ });
2703
+ this.$refs.middleware.init(i).then((r) => {
2704
+ setTimeout(() => {
2705
+ this.statu = !1;
2706
+ }, 1e3), s.close();
2707
+ });
2708
+ },
2709
+ getFilSize(t) {
2710
+ let e = t / 1024;
2711
+ return e < 1024 ? `${Math.ceil(e)}K` : `${(t / 1024 / 1024).toFixed(2)}M`;
2712
+ },
2713
+ getFieldFormat(t) {
2714
+ if (!["datepicker"].includes(t.datatype))
2715
+ return "";
2716
+ const e = this.timeLongshort.filter((i) => String(i.code) === String(t.fieldformat))[0];
2717
+ return e ? e.name.replace("DD", "dd") : "yyyy-MM-dd HH:mm:ss";
2718
+ },
2719
+ init() {
2720
+ this.confirmLoading = !0, Promise.all([this.getDetail(), this.getRootPermission(), this.getDocTypePage()]).then((t) => {
2721
+ let e = [];
2722
+ const i = this.record.attributes ? this.record.attributes : [], s = this.docTypeList.filter((a) => a.id === this.record.sysdoctypeid)[0];
2723
+ this.docTypeData = s || {}, (s ? s.sysdoctypeattributes : []).forEach((a) => {
2724
+ if (a.ishidden !== 1) {
2725
+ const n = i.filter((o) => o.attrcode === a.attrcode)[0];
2726
+ let l = {
2727
+ name: a.name,
2728
+ code: a.attrcode,
2729
+ fkName: "",
2730
+ effectType: a.datatype,
2731
+ dictTypeCode: a.dicttypecode,
2732
+ fieldFormat: this.getFieldFormat(a),
2733
+ transkey: a.transkey ? `Dynamics.${a.transkey}` : null,
2734
+ value: "",
2735
+ fieldsize: a.fieldsize,
2736
+ fkentity: a.fkentity,
2737
+ statecodes: a.statecodes
2738
+ };
2739
+ n && Object.assign(l, {
2740
+ fkName: n.attrname ? n.attrname : n.attrvalue,
2741
+ fkId: ["fk"].includes(a.datatype) ? n.attrvalue : "",
2742
+ value: this.getDefaultvalue(a, n.attrvalue)
2743
+ }), e.push(l);
2744
+ }
2745
+ }), this.attributesList = [...e], this.activeName === "version" && this.refresh(), this.confirmLoading = !1;
2746
+ });
2747
+ },
2748
+ getDefaultvalue(t, e) {
2749
+ return ["checkbox"].includes(t.datatype) ? e.split(",") : ["double", "currency"].includes(t.datatype) ? e && Number(e).toFixed(t.fieldsize) : e;
2750
+ },
2751
+ open(t) {
2752
+ this.type = t.type, this.activeName = "attribute", this.record = t, this.visible = !0, this.init();
2753
+ },
2754
+ getDocTypePage() {
2755
+ $({ pageno: 1, pagesize: 1e3 }).then((t) => {
2756
+ t.code === 200 && (this.docTypeList = t.data.rows);
2757
+ });
2758
+ },
2759
+ getDetail() {
2760
+ return _({ id: this.record.id }).then((t) => (t.code !== 200 || (this.record = t.data), t));
2761
+ },
2762
+ getRootPermission() {
2763
+ return f({ docId: this.record.id }).then((t) => {
2764
+ let e = {};
2765
+ t.code === 200 ? e = t.data : this.$message.error(t.message), this.permissionData = e;
2766
+ const i = h.filter((s) => s.type.includes(this.record.type));
2767
+ return this.permissionMenus = i.map((s) => {
2768
+ const r = e[s.code];
2769
+ return Object.assign(
2770
+ { ...s },
2771
+ {
2772
+ allow: r !== void 0 ? r === 1 : !1,
2773
+ refuse: r !== void 0 ? r === 2 : !1
2774
+ }
2775
+ );
2776
+ }), t;
2777
+ });
2778
+ },
2779
+ getBlobType(t) {
2780
+ let e = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
2781
+ return t === "pdf" ? e = "application/pdf" : t === "docx" && (e = "application/msword"), e;
2782
+ },
2783
+ closed() {
2784
+ this.fullscreen = !1, this.visible = !1;
2785
+ },
2786
+ toggleFullscreen() {
2787
+ this.fullscreen = !this.fullscreen;
2788
+ },
2789
+ getDictionary(t) {
2790
+ return this.$options.filters.dictData(t);
2791
+ },
2792
+ doEvent(t) {
2793
+ let e = t.item.functionName;
2794
+ this[e] && this[e]();
2795
+ }
2796
+ }
2797
+ };
2798
+ var wt = function() {
2799
+ var e = this, i = e._self._c;
2800
+ return i("div", [i("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: "700px", center: !0, "close-on-click-modal": !1, "append-to-body": !0, "modal-append-to-body": !1, top: "80px", "show-close": !1, "destroy-on-close": !0 }, on: { "update:visible": function(s) {
2801
+ e.visible = s;
2802
+ }, closed: e.closed } }, [i("gd-modal-title", { attrs: { slot: "title", title: e.title, fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen }, slot: "title" }), i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }], staticClass: "gd-doc-attribute" }, [e.visible ? i("el-tabs", { attrs: { type: "card" }, model: { value: e.activeName, callback: function(s) {
2803
+ e.activeName = s;
2804
+ }, expression: "activeName" } }, [i("el-tab-pane", { attrs: { label: e.$i18nt("gd.fileDocument.properties", "\u6587\u6863\u5C5E\u6027"), name: "attribute" } }, [i("div", { staticClass: "attribute", staticStyle: { "margin-top": "10px" } }, [i("div", { staticClass: "attribute-item" }, [i("div", { staticClass: "list" }, [i("div", { staticClass: "list-item list-label" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.form.attribute", "\u5C5E\u6027")))]), i("div", { staticClass: "item-val" }, [e._v(e._s(e.$i18nt("gd.form.value", "\u503C")))])]), i("div", { staticClass: "list-kuang" }, [i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.translation.name", "\u540D\u79F0")))]), i("div", { staticClass: "item-val line1", attrs: { title: e.record.name } }, [e._v(e._s(e.record.name))])]), i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.fileDocument.pathAddress", "\u8DEF\u5F84\u5730\u5740")))]), i("div", { staticClass: "item-val line1", attrs: { title: e.pathAddress } }, [e._v(e._s(e.pathAddress))])]), i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.file.fileAccept", "\u6587\u4EF6\u7C7B\u578B")))]), i("div", { staticClass: "item-val" }, [i("i", { staticClass: "gd-icons", class: e.fileIcon })])]), e.record.filesize ? [i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.file.fileSize", "\u6587\u4EF6\u5927\u5C0F")))]), i("div", { staticClass: "item-val", attrs: { title: e.recordFileSize } }, [e._v(e._s(e.recordFileSize))])]), e.record.version !== void 0 ? i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.fileDocument.currentVersion", "\u5F53\u524D\u7248\u672C")))]), i("div", { staticClass: "item-val", attrs: { title: e.record.version } }, [e._v(e._s(e.record.version))])]) : e._e(), e.record.iseffectiveness !== void 0 ? i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.fileDocument.iseffectiveness", "\u6709\u6548")))]), i("div", { staticClass: "item-val" }, [i("el-tag", { style: e._f("dictColor")("yes_or_no", e.record.iseffectiveness), attrs: { effect: "dark" } }, [e._v(" " + e._s(e._f("dictType")("yes_or_no", e.record.iseffectiveness)) + " ")])], 1)]) : e._e(), i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.fileDocument.classification", "\u6587\u6863\u5206\u7C7B")))]), i("div", { staticClass: "item-val", attrs: { title: e.docTypeName } }, [e._v(e._s(e.docTypeName))])])] : e._e(), i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.fileDocument.inheritedPermissions", "\u7EE7\u627F\u6743\u9650")))]), i("div", { staticClass: "item-val", attrs: { title: e._f("dictType")("yes_or_no", e.record.inheritpermissions) } }, [i("el-tag", { style: e._f("dictColor")("yes_or_no", e.record.inheritpermissions), attrs: { effect: "dark" } }, [e._v(" " + e._s(e._f("dictType")("yes_or_no", e.record.inheritpermissions)) + " ")])], 1)]), i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.fileDocument.uploadTime", "\u6700\u540E\u4E0A\u4F20\u65F6\u95F4")))]), i("div", { staticClass: "item-val", attrs: { title: e.record.uploaddate } }, [e._v(e._s(e.record.uploaddate))])]), i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.fileDocument.mdifyUser", "\u4FEE\u6539\u7528\u6237")))]), i("div", { staticClass: "item-val", attrs: { title: e.record.updatedbyname } }, [e._v(e._s(e.record.updatedbyname ? e.record.updatedbyname : ""))])]), i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.web.updatedTime", "\u4FEE\u6539\u65F6\u95F4")))]), i("div", { staticClass: "item-val", attrs: { title: e.record.updatedtime } }, [e._v(e._s(e.record.updatedtime))])]), i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.fileDocument.createUser", "\u521B\u5EFA\u7528\u6237")))]), i("div", { staticClass: "item-val", attrs: { title: e.record.createdbyname } }, [e._v(e._s(e.record.createdbyname ? e.record.createdbyname : ""))])]), i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.web.creationTime", "\u521B\u5EFA\u65F6\u95F4")))]), i("div", { staticClass: "item-val", attrs: { title: e.record.createdtime } }, [e._v(e._s(e.record.createdtime))])])], 2)])])])]), e.type === 2 ? i("el-tab-pane", { attrs: { label: e.$i18nt("gd.fileDocument.extendedAttributes", "\u6269\u5C55\u5C5E\u6027"), name: "extendedAttributes" } }, [i("div", { staticClass: "attribute" }, [e.type === 2 ? i("div", { staticClass: "attribute-item" }, [i("div", { staticClass: "list-title list-title-flex" }, [i("div", { staticClass: "list-title-name" }), e.hasRename && e.docTypeData.statecodes === 1 && e.attributesList.length > 0 ? i("div", { staticClass: "list-title-edit active-color", on: { click: e.editExtendedAttributes } }, [i("i", { staticClass: "el-icon-edit-outline active-color" }), e._v(" " + e._s(e.$i18nt("gd.btn.edit", "\u7F16\u8F91")) + " ")]) : e._e()]), i("div", { staticClass: "list" }, [i("div", { staticClass: "list-item list-label" }, [i("div", { staticClass: "item-name item-names" }, [e._v(e._s(e.$i18nt("gd.form.attribute", "\u5C5E\u6027")))]), i("div", { staticClass: "item-val" }, [e._v(" " + e._s(e.$i18nt("gd.form.value", "\u503C")) + " ")])]), e.attributesList.length > 0 ? i("div", { staticClass: "list-kuang" }, e._l(e.attributesList, function(s) {
2805
+ return i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name item-names" }, [e._v(" " + e._s(e.$i18nt(s.transkey, s.name)) + " ")]), ["radio", "select", "switch"].includes(s.effectType) ? i("div", { staticClass: "item-val line1", attrs: { title: e._f("dictType")(s.dictTypeCode, s.value) } }, [i("el-tag", { style: e._f("dictColor")(s.dictTypeCode, s.value), attrs: { effect: "dark" } }, [e._v(" " + e._s(e._f("dictType")(s.dictTypeCode, s.value)) + " ")])], 1) : ["datepicker"].includes(s.effectType) ? i("div", { staticClass: "item-val line1", attrs: { title: e._f("formatTime")(s.value, s.fieldFormat) } }, [e._v(" " + e._s(e._f("formatTime")(s.value, s.fieldFormat)) + " ")]) : ["checkbox"].includes(s.effectType) ? i("div", { staticClass: "item-val line1" }, [e._l(s.value, function(r, a) {
2806
+ return [a < e.maxLeg ? i("el-tag", { style: e._f("dictColor")(s.dictTypeCode, r), attrs: { effect: "dark" } }, [e._v(" " + e._s(e._f("dictType")(s.dictTypeCode, r)) + " ")]) : e._e(), a === e.maxLeg ? i("el-tooltip", { directives: [{ name: "delTabIndex", rawName: "v-delTabIndex" }], attrs: { effect: "dark", placement: "top" } }, [i("div", { attrs: { slot: "content" }, slot: "content" }, [e._l(s.value, function(n, l) {
2807
+ return [l >= e.maxLeg ? i("span", { staticStyle: { "padding-right": "4px" } }, [e._v(e._s(e._f("dictType")(s.dictTypeCode, n)))]) : e._e()];
2808
+ })], 2), i("el-tag", { staticStyle: { "background-color": "#fff", "border-color": "#dcdfe2", color: "rgba(0, 0, 0, 0.65)" }, attrs: { effect: "dark" } }, [e._v(" ... ")])], 1) : e._e()];
2809
+ })], 2) : ["fk"].includes(s.effectType) ? i("div", { staticClass: "item-val line1", attrs: { title: s.fkName } }, [s.fkId ? i("span", { staticClass: "active-color", on: { click: function(r) {
2810
+ return e.seeFkItem(s);
2811
+ } } }, [e._v(e._s(s.fkName))]) : e._e()]) : i("div", { staticClass: "item-val line1", attrs: { title: s.value } }, [e._v(e._s(s.value))])]);
2812
+ }), 0) : i("div", { staticClass: "empty" }, [i("div", { staticClass: "empty-icon" }, [i("i", { staticClass: "el-icon-receiving" })]), i("div", { staticClass: "empty-title" }, [i("span", [e._v(e._s(e.$i18nt("gd.echarts.noData", "\u6682\u65E0\u6570\u636E\u5C55\u793A")))])])])])]) : e._e()])]) : e._e(), i("el-tab-pane", { attrs: { label: e.$i18nt("gd.page.limitsAuthority", "\u6743\u9650"), name: "permission" } }, [i("div", { staticClass: "list", staticStyle: { "margin-top": "12px" } }, [i("div", { staticClass: "list-item list-label" }, [i("div", { staticClass: "item-name" }, [e._v(e._s(e.$i18nt("gd.page.limitsAuthority", "\u6743\u9650")))]), i("div", { staticClass: "item-hand" }, [e._v(e._s(e.$i18nt("gd.fileDocument.allow", "\u5141\u8BB8")))]), i("div", { staticClass: "item-hand" }, [e._v(e._s(e.$i18nt("gd.fileDocument.refuse", "\u62D2\u7EDD")))])]), i("div", { staticClass: "list-kuang" }, [e._l(e.permissionMenus, function(s) {
2813
+ return [s.show ? i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name" }, [e._v(" " + e._s(e.$i18nt(s.transkey, s.name)) + " (" + e._s(s.code) + ") ")]), i("div", { staticClass: "item-hand" }, [s.allow ? i("i", { staticClass: "el-icon-check", staticStyle: { color: "#52c41a" } }) : e._e()]), i("div", { staticClass: "item-hand" }, [s.refuse ? i("i", { staticClass: "el-icon-close", staticStyle: { color: "red" } }) : e._e()])]) : e._e()];
2814
+ })], 2)])])], 1) : e._e()], 1)], 1), i("ExtendedAttributes", { ref: "extendedAttributes", on: { ok: e.init } }), i("gd-middleware", { ref: "middleware", on: { ok: e.init } })], 1);
2815
+ }, kt = [], Ft = /* @__PURE__ */ d(
2816
+ Dt,
2817
+ wt,
2818
+ kt,
2819
+ !1,
2820
+ null,
2821
+ "c4a2af33",
2822
+ null,
2823
+ null
2824
+ );
2825
+ const xt = Ft.exports, Lt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2826
+ __proto__: null,
2827
+ default: xt
2828
+ }, Symbol.toStringTag, { value: "Module" }));
2829
+ const Tt = {
2830
+ props: {
2831
+ fileAccept: {
2832
+ type: String,
2833
+ default: ""
2834
+ },
2835
+ fileSize: {
2836
+ type: Number,
2837
+ default: 1024
2838
+ }
2839
+ },
2840
+ data() {
2841
+ return {
2842
+ record: {},
2843
+ statu: !1,
2844
+ confirmLoading: !1,
2845
+ visible: !1,
2846
+ fullscreen: !1,
2847
+ queryParam: {},
2848
+ loadData: (t) => G(
2849
+ Object.assign(t, this.queryParam, {
2850
+ sysDocObjectId: this.record.id
2851
+ })
2852
+ ).then((e) => {
2853
+ let i = [];
2854
+ return e.code === 200 && (i = e.data.rows.map((s) => Object.assign(s, {
2855
+ filesized: this.getFilSize(s.filesize),
2856
+ currentversion: s.id === this.record.currentversion ? "1" : "0"
2857
+ }))), Object.assign(e.data, {
2858
+ rows: i
2859
+ });
2860
+ }),
2861
+ permissionMenus: [],
2862
+ selectedRowKeys: [],
2863
+ permissionData: {},
2864
+ docTypeList: [],
2865
+ docTypeData: {}
2866
+ };
2867
+ },
2868
+ components: {
2869
+ VersionEdit: () => Promise.resolve().then(() => si)
2870
+ },
2871
+ computed: {
2872
+ hasRename() {
2873
+ return this.permissionData.rename === 1;
2874
+ },
2875
+ getTableButtons() {
2876
+ return this.hasRename ? [{ displayName: "\u521B\u5EFA\u65B0\u7248\u672C", functionName: "createVersion", show: !0, transKey: "gd.fileDocument.createNewVersion", icon: "el-icon-plus" }] : [];
2877
+ },
2878
+ tableColumns() {
2879
+ return [
2880
+ {
2881
+ transKey: "gd.solution.version",
2882
+ prop: "version",
2883
+ label: "\u7248\u672C",
2884
+ align: "left",
2885
+ width: "150"
2886
+ },
2887
+ {
2888
+ transKey: "gd.fileDocument.currentVersion",
2889
+ prop: "currentversion",
2890
+ label: "\u5F53\u524D\u7248\u672C",
2891
+ align: "center",
2892
+ type: "slot",
2893
+ slotType: "currentversion",
2894
+ width: "140"
2895
+ },
2896
+ {
2897
+ transKey: "gd.fileDocument.effectiveness",
2898
+ prop: "iseffectiveness",
2899
+ label: "\u6709\u6548\u6027",
2900
+ align: "center",
2901
+ type: "slot",
2902
+ slotType: "iseffectiveness",
2903
+ width: "140"
2904
+ },
2905
+ {
2906
+ transKey: "gd.file.fileSize",
2907
+ prop: "filesized",
2908
+ label: "\u6587\u4EF6\u5927\u5C0F",
2909
+ align: "right",
2910
+ width: "100"
2911
+ },
2912
+ {
2913
+ transKey: "gd.web.creationTime",
2914
+ prop: "createdtime",
2915
+ label: "\u521B\u5EFA\u65F6\u95F4",
2916
+ align: "right",
2917
+ width: "200"
2918
+ },
2919
+ {
2920
+ transKey: "gd.fileDocument.createUser",
2921
+ prop: "createdusername",
2922
+ label: "\u521B\u5EFA\u7528\u6237",
2923
+ align: "right",
2924
+ width: "170"
2925
+ },
2926
+ {
2927
+ transKey: "gd.btn.handle",
2928
+ prop: "handle",
2929
+ label: "\u64CD\u4F5C",
2930
+ align: "left",
2931
+ type: "slot",
2932
+ slotType: "handle",
2933
+ width: "210",
2934
+ fixed: "right",
2935
+ showTooltip: !1
2936
+ }
2937
+ ];
2938
+ },
2939
+ getHeight() {
2940
+ const t = this.fullscreen ? 158 : 320;
2941
+ return this.screenHeight - t;
2942
+ },
2943
+ timeLongshort() {
2944
+ return this.getDictionary("time_longshort");
2945
+ },
2946
+ ...u(["primaryColor", "tablePageSize", "tableSize", "screenHeight", "tableLists"])
2947
+ },
2948
+ methods: {
2949
+ editExtendedAttributes() {
2950
+ this.$refs.extendedAttributes.open(this.record);
2951
+ },
2952
+ seeFkItem(t) {
2953
+ const e = this.tableLists.filter((r) => r.tablename === t.fkentity)[0];
2954
+ this.statu = !0;
2955
+ let i = {
2956
+ tableId: e.id,
2957
+ data: [
2958
+ {
2959
+ id: t.fkId
2960
+ }
2961
+ ]
2962
+ };
2963
+ const s = this.$message({
2964
+ message: this.$i18nt("gd.https.Loading", "\u52A0\u8F7D\u4E2D..."),
2965
+ duration: 0,
2966
+ iconClass: "el-icon-loading"
2967
+ });
2968
+ this.$refs.middleware.init(i).then((r) => {
2969
+ setTimeout(() => {
2970
+ this.statu = !1;
2971
+ }, 1e3), s.close();
2972
+ });
2973
+ },
2974
+ copyItem(t) {
2975
+ this.$refs.addVersion.open(t, "copy");
2976
+ },
2977
+ editItem(t) {
2978
+ this.$refs.addVersion.open(t, "edit");
2979
+ },
2980
+ previewItem(t) {
2981
+ const e = t.name ? t.name : new Date().getTime() + "." + t.filetype;
2982
+ this.$emit("preview", { type: "attribute", data: { name: e, fileoriginname: e, filetype: t.filetype, file: t.file } });
2983
+ },
2984
+ createVersion() {
2985
+ this.$refs.addVersion.open(null);
2986
+ },
2987
+ downloadItem(t) {
2988
+ const e = this.$message({
2989
+ message: this.$i18nt("gd.https.downloading", "\u6B63\u5728\u4E0B\u8F7D\u4E2D......"),
2990
+ duration: 0,
2991
+ iconClass: "el-icon-loading"
2992
+ });
2993
+ X({ docVersionId: t.id }).then((i) => {
2994
+ if (i.data.type === "application/json") {
2995
+ const s = new FileReader();
2996
+ s.onload = (r) => {
2997
+ const a = JSON.parse(s.result);
2998
+ this.$message.error(a.message), e.close();
2999
+ }, s.readAsText(i.data);
3000
+ return;
3001
+ }
3002
+ if (i) {
3003
+ const s = t.name ? t.name : new Date().getTime() + "." + t.filetype, r = s.length, a = t.filetype.length, n = s.slice(r - a - 1, r), l = new Blob([i.data], {
3004
+ type: this.getBlobType(t.filetype)
3005
+ }), o = URL.createObjectURL(l);
3006
+ let c = document.createElement("a");
3007
+ c.style.display = "none", c.href = o, c.download = n === `.${t.filetype}` ? s : `${s}.${t.filetype}`, c.click(), setTimeout(() => {
3008
+ e.close(), URL.revokeObjectURL(c.href);
3009
+ }, 1e3);
3010
+ } else
3011
+ e.close(), this.$message.error(i.message);
3012
+ });
3013
+ },
3014
+ changeStatu(t) {
3015
+ let e = this;
3016
+ const i = t.iseffectiveness === 1 ? this.$i18nt("gd.fileDocument.cancelValidityTip", "\u662F\u5426\u53D6\u6D88\u6709\u6548\u6027?") : this.$i18nt("gd.fileDocument.setValidityTip", "\u662F\u5426\u8BBE\u7F6E\u6709\u6548\u6027?");
3017
+ this.$confirm(i, this.$i18nt("gd.https.delTitle", "\u6E29\u99A8\u63D0\u793A"), {
3018
+ confirmButtonText: this.$i18nt("gd.btn.confirm", "\u786E\u8BA4"),
3019
+ cancelButtonText: this.$i18nt("gd.https.delCancel", "\u53D6\u6D88"),
3020
+ showClose: !1,
3021
+ confirmButtonLoading: !1,
3022
+ cancelButtonLoading: !1,
3023
+ closeOnClickModal: !1,
3024
+ type: "warning",
3025
+ confirmButtonClass: "el-button--danger",
3026
+ customClass: "custom-alert",
3027
+ callback: () => {
3028
+ },
3029
+ beforeClose: (s, r, a) => {
3030
+ if (s !== "confirm") {
3031
+ a();
3032
+ return;
3033
+ }
3034
+ r.confirmButtonLoading = !0, r.cancelButtonLoading = !0, r.showCancelButton = !1, Y({
3035
+ docVersionId: t.id,
3036
+ newState: t.iseffectiveness === 1 ? 0 : 1
3037
+ }).then((n) => {
3038
+ if (r.confirmButtonLoading = !1, r.cancelButtonLoading = !1, r.showCancelButton = !0, !n.success) {
3039
+ e.$message.error(e.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + n.message);
3040
+ return;
3041
+ }
3042
+ e.init(), e.$message.success(e.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), a();
3043
+ });
3044
+ }
3045
+ });
3046
+ },
3047
+ delItem(t) {
3048
+ let e = this;
3049
+ this.$confirm(this.$i18nt("gd.https.delContent", "\u662F\u5426\u5220\u9664\u9009\u4E2D\u6570\u636E?"), this.$i18nt("gd.https.delTitle", "\u6E29\u99A8\u63D0\u793A"), {
3050
+ confirmButtonText: this.$i18nt("gd.https.delOk", "\u786E\u5B9A\u5220\u9664"),
3051
+ cancelButtonText: this.$i18nt("gd.https.delCancel", "\u53D6\u6D88"),
3052
+ showClose: !1,
3053
+ confirmButtonLoading: !1,
3054
+ cancelButtonLoading: !1,
3055
+ closeOnClickModal: !1,
3056
+ type: "warning",
3057
+ confirmButtonClass: "el-button--danger",
3058
+ customClass: "custom-alert",
3059
+ callback: () => {
3060
+ },
3061
+ beforeClose: (i, s, r) => {
3062
+ if (i !== "confirm") {
3063
+ r();
3064
+ return;
3065
+ }
3066
+ s.confirmButtonLoading = !0, s.cancelButtonLoading = !0, s.showCancelButton = !1, Z({
3067
+ ids: t.id
3068
+ }).then((a) => {
3069
+ if (s.confirmButtonLoading = !1, s.cancelButtonLoading = !1, s.showCancelButton = !0, !a.success) {
3070
+ e.$message.error(e.$i18nt("gd.https.delFail", "\u5220\u9664\u5931\u8D25") + a.message);
3071
+ return;
3072
+ }
3073
+ e.init(), e.$message.success(e.$i18nt("gd.https.delSucc", "\u5220\u9664\u6210\u529F")), r();
3074
+ });
3075
+ }
3076
+ });
3077
+ },
3078
+ getFilSize(t) {
3079
+ let e = t / 1024;
3080
+ return e < 1024 ? `${Math.ceil(e)}K` : `${(t / 1024 / 1024).toFixed(2)}M`;
3081
+ },
3082
+ refresh() {
3083
+ this.$nextTick(() => {
3084
+ setTimeout(() => {
3085
+ this.$refs.table.refresh();
3086
+ }, 0);
3087
+ });
3088
+ },
3089
+ init() {
3090
+ this.confirmLoading = !0, Promise.all([this.getDetail(), this.getRootPermission(), this.getDocTypePage()]).then((t) => {
3091
+ this.refresh(), this.confirmLoading = !1;
3092
+ });
3093
+ },
3094
+ open(t) {
3095
+ this.record = t, this.visible = !0, this.init();
3096
+ },
3097
+ getDocTypePage() {
3098
+ $({ pageno: 1, pagesize: 1e3 }).then((t) => {
3099
+ t.code === 200 && (this.docTypeList = t.data.rows);
3100
+ });
3101
+ },
3102
+ getDetail() {
3103
+ return _({ id: this.record.id }).then((t) => (t.code !== 200 || (this.record = t.data), t));
3104
+ },
3105
+ getRootPermission() {
3106
+ return f({ docId: this.record.id }).then((t) => {
3107
+ let e = {};
3108
+ t.code === 200 ? e = t.data : this.$message.error(t.message), this.permissionData = e;
3109
+ const i = h.filter((s) => s.type.includes(this.record.type));
3110
+ return this.permissionMenus = i.map((s) => {
3111
+ const r = e[s.code];
3112
+ return Object.assign(
3113
+ { ...s },
3114
+ {
3115
+ allow: r !== void 0 ? r === 1 : !1,
3116
+ refuse: r !== void 0 ? r === 2 : !1
3117
+ }
3118
+ );
3119
+ }), t;
3120
+ });
3121
+ },
3122
+ getBlobType(t) {
3123
+ let e = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
3124
+ return t === "pdf" ? e = "application/pdf" : t === "docx" && (e = "application/msword"), e;
3125
+ },
3126
+ closed() {
3127
+ this.fullscreen = !1, this.visible = !1;
3128
+ },
3129
+ toggleFullscreen() {
3130
+ this.fullscreen = !this.fullscreen;
3131
+ },
3132
+ getDictionary(t) {
3133
+ return this.$options.filters.dictData(t);
3134
+ },
3135
+ doEvent(t) {
3136
+ let e = t.item.functionName;
3137
+ this[e] && this[e]();
3138
+ }
3139
+ }
3140
+ };
3141
+ var St = function() {
3142
+ var e = this, i = e._self._c;
3143
+ return i("div", [i("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: "86%", center: !0, "close-on-click-modal": !1, "append-to-body": !0, "modal-append-to-body": !1, top: "80px", "show-close": !1, "destroy-on-close": !0 }, on: { "update:visible": function(s) {
3144
+ e.visible = s;
3145
+ }, closed: e.closed } }, [i("gd-modal-title", { attrs: { slot: "title", title: e.$i18nt("gd.fileDocument.versionControl", "\u7248\u672C\u7BA1\u7406"), fullscreen: e.fullscreen, buttons: [], confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen }, slot: "title" }), i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }] }, [i("gd-tables", { ref: "table", attrs: { dataSource: e.loadData, size: e.tableSize, pageSize: e.tablePageSize, columns: e.tableColumns, selectedRowKeys: e.selectedRowKeys, height: e.getHeight, initialLoading: !1 }, scopedSlots: e._u([{ key: "currentversion", fn: function({ column: s, row: r }) {
3146
+ return [i("el-tag", { style: e._f("dictColor")("yes_or_no", r.currentversion), attrs: { effect: "dark" } }, [e._v(e._s(e._f("dictType")("yes_or_no", r.currentversion)))])];
3147
+ } }, { key: "iseffectiveness", fn: function({ column: s, row: r }) {
3148
+ return [i("el-tag", { style: e._f("dictColor")("yes_or_no", r.iseffectiveness), attrs: { effect: "dark" } }, [e._v(e._s(e._f("dictType")("yes_or_no", r.iseffectiveness)))])];
3149
+ } }, { key: "operator", fn: function() {
3150
+ return [i("div", { staticClass: "gd-table-operator" }, [i("div", { staticClass: "gd-table-operatorr" }, [i("gd-btn-list", { attrs: { sysViewButtons: e.getTableButtons }, on: { functionName: e.doEvent } })], 1)])];
3151
+ }, proxy: !0 }, { key: "handle", fn: function({ column: s, row: r }) {
3152
+ return [i("div", { staticClass: "handle-btn" }, [r.iseffectiveness === 1 ? [e.permissionData.readmetadata === 1 ? [i("el-tooltip", { staticClass: "item", attrs: { effect: "dark", content: e.$i18nt("gd.btn.preview", "\u9884\u89C8"), placement: "top" } }, [i("i", { staticClass: "gd-icons gd-icon-kejian", on: { click: function(a) {
3153
+ return e.previewItem(r);
3154
+ } } })]), i("el-divider", { attrs: { direction: "vertical" } })] : e._e(), e.permissionData.download === 1 ? [i("el-tooltip", { staticClass: "item", attrs: { effect: "dark", content: e.$i18nt("gd.btn.download", "\u4E0B\u8F7D"), placement: "top" } }, [i("i", { staticClass: "gd-icons gd-icon-icon-test14", on: { click: function(a) {
3155
+ return e.downloadItem(r);
3156
+ } } })]), i("el-divider", { attrs: { direction: "vertical" } })] : e._e(), e.permissionData.rename === 1 ? [i("el-tooltip", { staticClass: "item", attrs: { effect: "dark", content: e.$i18nt("gd.btn.edit", "\u7F16\u8F91"), placement: "top" } }, [i("i", { staticClass: "gd-icons el-icon-edit-outline active-color", on: { click: function(a) {
3157
+ return e.editItem(r);
3158
+ } } })]), i("el-divider", { attrs: { direction: "vertical" } })] : e._e(), e.permissionData.rename === 1 ? [i("el-tooltip", { staticClass: "item", attrs: { effect: "dark", content: e.$i18nt("gd.fileDocument.recoveryVersion", "\u6062\u590D\u7248\u672C"), placement: "top" } }, [i("i", { staticClass: "gd-icons el-icon-refresh-right", staticStyle: { color: "red" }, on: { click: function(a) {
3159
+ return e.copyItem(r);
3160
+ } } })]), i("el-divider", { attrs: { direction: "vertical" } })] : e._e(), e.permissionData.delete === 1 ? [i("el-tooltip", { staticClass: "item", attrs: { effect: "dark", content: e.$i18nt("gd.btn.del", "\u5220\u9664"), placement: "top" } }, [i("i", { staticClass: "gd-icons el-icon-delete", staticStyle: { color: "red" }, on: { click: function(a) {
3161
+ return e.delItem(r);
3162
+ } } })]), i("el-divider", { attrs: { direction: "vertical" } })] : e._e()] : e._e(), e.permissionData.rename === 1 ? i("el-tooltip", { staticClass: "item", attrs: { effect: "dark", content: e.$i18nt("gd.fileDocument.setEffective", "\u8BBE\u4E3A\u6709\u6548"), placement: "top" } }, [i("i", { staticClass: "gd-icons el-icon-setting", on: { click: function(a) {
3163
+ return e.changeStatu(r);
3164
+ } } })]) : e._e()], 2)];
3165
+ } }]) })], 1)], 1), i("VersionEdit", { ref: "addVersion", attrs: { recordData: e.record, fileAccept: e.fileAccept, fileSize: e.fileSize }, on: { ok: e.init } })], 1);
3166
+ }, Pt = [], It = /* @__PURE__ */ d(
3167
+ Tt,
3168
+ St,
3169
+ Pt,
3170
+ !1,
3171
+ null,
3172
+ "30c626a7",
3173
+ null,
3174
+ null
3175
+ );
3176
+ const Nt = It.exports, Ot = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3177
+ __proto__: null,
3178
+ default: Nt
3179
+ }, Symbol.toStringTag, { value: "Module" }));
3180
+ const jt = {
3181
+ props: {
3182
+ record: {
3183
+ type: Object,
3184
+ default: () => ({})
3185
+ },
3186
+ ruleFormData: {
3187
+ type: Object,
3188
+ required: !0
3189
+ }
3190
+ },
3191
+ data() {
3192
+ return {};
3193
+ },
3194
+ computed: {
3195
+ disabled() {
3196
+ return this.record.disabled !== void 0 ? this.record.disabled : !1;
3197
+ },
3198
+ ...u(["primaryColor"])
3199
+ },
3200
+ components: { SelectFkMultiple: () => import("./components.form.a7b3ea37.mjs").then((t) => t.s) },
3201
+ methods: {
3202
+ getDictionary(t) {
3203
+ return this.$options.filters.dictData(t);
3204
+ }
3205
+ }
3206
+ };
3207
+ var zt = function() {
3208
+ var e = this, i = e._self._c;
3209
+ return i("div", [["inputnumber", "double"].includes(e.record.effectType) ? i("el-input-number", { staticStyle: { width: "100%" }, attrs: { type: "number", precision: e.record.fieldsize, placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), "controls-position": "right", clearable: "", disabled: e.disabled }, model: { value: e.ruleFormData[e.record.prop], callback: function(s) {
3210
+ e.$set(e.ruleFormData, e.record.prop, s);
3211
+ }, expression: "ruleFormData[record.prop]" } }) : ["textarea"].includes(e.record.effectType) ? i("el-input", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), clearable: "", type: "textarea", rows: 1, disabled: e.disabled }, model: { value: e.ruleFormData[e.record.prop], callback: function(s) {
3212
+ e.$set(e.ruleFormData, e.record.prop, s);
3213
+ }, expression: "ruleFormData[record.prop]" } }) : ["switch"].includes(e.record.effectType) ? i("el-switch", { attrs: { "active-color": e.primaryColor, "active-value": "1", "inactive-value": "0", disabled: e.disabled }, model: { value: e.ruleFormData[e.record.prop], callback: function(s) {
3214
+ e.$set(e.ruleFormData, e.record.prop, s);
3215
+ }, expression: "ruleFormData[record.prop]" } }) : ["radio"].includes(e.record.effectType) ? i("el-radio-group", { attrs: { disabled: e.disabled }, model: { value: e.ruleFormData[e.record.prop], callback: function(s) {
3216
+ e.$set(e.ruleFormData, e.record.prop, s);
3217
+ }, expression: "ruleFormData[record.prop]" } }, [e._l(e.getDictionary(e.record.dictTypeCode), function(s) {
3218
+ return [i("el-radio", { attrs: { label: s.code } }, [e._v(" " + e._s(e.$i18nt(`Dynamics.${s.transkey}`, s.name)) + " ")])];
3219
+ })], 2) : ["checkbox"].includes(e.record.effectType) ? i("el-checkbox-group", { attrs: { disabled: e.disabled }, model: { value: e.ruleFormData[e.record.prop], callback: function(s) {
3220
+ e.$set(e.ruleFormData, e.record.prop, s);
3221
+ }, expression: "ruleFormData[record.prop]" } }, [e._l(e.getDictionary(e.record.dictTypeCode), function(s) {
3222
+ return [i("el-checkbox", { attrs: { label: s.code } }, [e._v(e._s(e.$i18nt(`Dynamics.${s.transkey}`, s.name)))])];
3223
+ })], 2) : ["select"].includes(e.record.effectType) ? i("el-select", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), disabled: e.disabled }, model: { value: e.ruleFormData[e.record.prop], callback: function(s) {
3224
+ e.$set(e.ruleFormData, e.record.prop, s);
3225
+ }, expression: "ruleFormData[record.prop]" } }, [e._l(e.getDictionary(e.record.dictTypeCode), function(s) {
3226
+ return [i("el-option", { attrs: { label: e.$i18nt(`Dynamics.${s.transkey}`, s.name), value: s.code } }, [e._v(" " + e._s(e.$i18nt(`Dynamics.${s.transkey}`, s.name)) + " ")])];
3227
+ })], 2) : ["datepicker"].includes(e.record.effectType) ? [e.record.isDatePicker ? i("el-date-picker", { staticStyle: { width: "100%" }, attrs: { type: e.record.pickerType, "value-format": e.record.fieldFormat, format: e.record.fieldFormat, placeholder: e.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), clearable: "", disabled: e.disabled }, model: { value: e.ruleFormData[e.record.prop], callback: function(s) {
3228
+ e.$set(e.ruleFormData, e.record.prop, s);
3229
+ }, expression: "ruleFormData[record.prop]" } }) : i("el-time-picker", { staticStyle: { width: "100%" }, attrs: { "value-format": e.record.fieldFormat, format: e.record.fieldFormat, placeholder: e.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), clearable: "", disabled: e.disabled }, model: { value: e.ruleFormData[e.record.prop], callback: function(s) {
3230
+ e.$set(e.ruleFormData, e.record.prop, s);
3231
+ }, expression: "ruleFormData[record.prop]" } })] : ["fk"].includes(e.record.effectType) ? i("SelectFkMultiple", { attrs: { column: e.record, ruleFormData: e.ruleFormData } }) : i("el-input", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), clearable: "", disabled: e.disabled }, model: { value: e.ruleFormData[e.record.prop], callback: function(s) {
3232
+ e.$set(e.ruleFormData, e.record.prop, s);
3233
+ }, expression: "ruleFormData[record.prop]" } })], 2);
3234
+ }, At = [], Bt = /* @__PURE__ */ d(
3235
+ jt,
3236
+ zt,
3237
+ At,
3238
+ !1,
3239
+ null,
3240
+ "bf42592b",
3241
+ null,
3242
+ null
3243
+ );
3244
+ const Et = Bt.exports, T = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3245
+ __proto__: null,
3246
+ default: Et
3247
+ }, Symbol.toStringTag, { value: "Module" }));
3248
+ const Mt = {
3249
+ props: {
3250
+ recordData: {
3251
+ type: Object,
3252
+ defalt: () => {
3253
+ }
3254
+ },
3255
+ allIds: {
3256
+ type: Array,
3257
+ defalt: () => []
3258
+ },
3259
+ multipleLimit: {
3260
+ type: Number,
3261
+ default: 12
3262
+ }
3263
+ },
3264
+ data() {
3265
+ return {
3266
+ ruleForm: {
3267
+ principalidAboutId: "",
3268
+ principalidAboutTable: "",
3269
+ principalidAboutIdBatch: [],
3270
+ isInherit: !1
3271
+ },
3272
+ rules: {
3273
+ principalidAboutId: [
3274
+ {
3275
+ required: !0,
3276
+ message: this.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"),
3277
+ trigger: ["change", "blur"]
3278
+ }
3279
+ ],
3280
+ principalidAboutIdBatch: [
3281
+ {
3282
+ required: !0,
3283
+ message: this.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"),
3284
+ trigger: ["change", "blur"]
3285
+ }
3286
+ ]
3287
+ },
3288
+ record: null,
3289
+ width: "800px",
3290
+ confirmLoading: !1,
3291
+ visible: !1,
3292
+ fullscreen: !1,
3293
+ loading: !1,
3294
+ hasRefresh: !1,
3295
+ fkData: [],
3296
+ fkEntityName: "sys_user,sys_team",
3297
+ list: [],
3298
+ batchPrincipalid: [],
3299
+ permissionList: h
3300
+ };
3301
+ },
3302
+ computed: {
3303
+ maxTip() {
3304
+ return `${this.$i18nt("gd.https.exceedMaxiNumber", "\u8D85\u8FC7\u6279\u91CF\u63D0\u4EA4\u6700\u5927\u6570")} :${this.multipleLimit}`;
3305
+ },
3306
+ docacltemList() {
3307
+ const t = this.getDictionary("docacltem");
3308
+ return (t || []).map((i) => Object.assign(i, {
3309
+ bjcolor: i.colour ? `background:${i.colour};color:#fff;` : ""
3310
+ }));
3311
+ },
3312
+ title() {
3313
+ return this.record ? this.$i18nt("gd.btn.edit", "\u7F16\u8F91") : this.$i18nt("gd.btn.add", "\u65B0\u589E");
3314
+ },
3315
+ fadeColord() {
3316
+ return this.fadeColor(this.primaryColor, 0.1);
3317
+ },
3318
+ disabledRowId() {
3319
+ return this.record ? this.allIds.filter((t) => t !== this.record.principalid_aboutid) : this.allIds;
3320
+ },
3321
+ disabled() {
3322
+ return !!(this.record && this.record.isinherit);
3323
+ },
3324
+ buttons() {
3325
+ return this.disabled ? [] : [
3326
+ {
3327
+ displayName: "\u786E\u5B9A",
3328
+ functionName: "handleSubmit",
3329
+ show: !0,
3330
+ transKey: "gd.btn.confirm",
3331
+ icon: "el-icon-document-checked"
3332
+ }
3333
+ ];
3334
+ },
3335
+ ...u(["primaryColor", "tableLists"])
3336
+ },
3337
+ methods: {
3338
+ selDocacltem(t) {
3339
+ const e = t.remark ? t.remark.split(",") : [];
3340
+ this.list = this.list.map((i) => {
3341
+ const s = e.filter((r) => r.toUpperCase() === i.code.toUpperCase())[0];
3342
+ return Object.assign(
3343
+ { ...i },
3344
+ {
3345
+ refuse: 0,
3346
+ allow: !!s
3347
+ }
3348
+ );
3349
+ });
3350
+ },
3351
+ edit(t) {
3352
+ this.confirmLoading = !0;
3353
+ const e = this.fkData.filter((s) => s.id === this.ruleForm.principalidAboutId)[0], i = Object.assign(t, {
3354
+ sysDocObjectId: this.recordData.id,
3355
+ principalId_AboutId: this.ruleForm.principalidAboutId,
3356
+ principalId_AboutTable: e.tableName,
3357
+ id: this.record.id
3358
+ });
3359
+ ee(i).then((s) => {
3360
+ s.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok", i), this.closed()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + s.message), this.confirmLoading = !1;
3361
+ });
3362
+ },
3363
+ add(t) {
3364
+ if (this.batchPrincipalid.length > this.multipleLimit) {
3365
+ this.$message.error(this.maxTip);
3366
+ return;
3367
+ }
3368
+ this.confirmLoading = !0;
3369
+ let e = [];
3370
+ this.batchPrincipalid.forEach((i, s) => {
3371
+ let r = Object.assign({}, t, {
3372
+ sysDocObjectId: this.recordData.id,
3373
+ principalId_AboutId: i.id,
3374
+ principalId_AboutTable: i.tableName
3375
+ });
3376
+ const a = this.sysDocPermissionAdd(r, s * 100).then((n) => ({ res: n, item: i }));
3377
+ e.push(a);
3378
+ }), Promise.all(e).then((i) => {
3379
+ this.hasRefresh = !0, this.confirmLoading = !1;
3380
+ const s = i.filter((l) => !l.res.success);
3381
+ if (s.length === 0) {
3382
+ this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.closed();
3383
+ return;
3384
+ }
3385
+ let r = [], a = `<p>${this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25")}</<p>`, n = [];
3386
+ this.batchPrincipalid.forEach((l) => {
3387
+ const o = s.filter((c) => c.item.id === l.id)[0];
3388
+ o && (r.push(
3389
+ Object.assign({}, l, {
3390
+ errTip: o.res.message
3391
+ })
3392
+ ), a += `<p>${l.name} (${o.res.message});</p>`, n.push(l.id));
3393
+ }), this.batchPrincipalid = r, this.ruleForm.principalidAboutIdBatch = n, this.$message({
3394
+ dangerouslyUseHTMLString: !0,
3395
+ message: a,
3396
+ type: "error"
3397
+ });
3398
+ });
3399
+ },
3400
+ sysDocPermissionAdd(t, e) {
3401
+ return new Promise((i) => {
3402
+ setTimeout(() => {
3403
+ te(t).then((s) => {
3404
+ i(s);
3405
+ });
3406
+ }, e);
3407
+ });
3408
+ },
3409
+ handleSubmit() {
3410
+ this.$refs.ruleForm.validate((t) => {
3411
+ if (t) {
3412
+ let e = /* @__PURE__ */ new Map();
3413
+ this.list.forEach((i) => {
3414
+ e.set(i.code, i.allow ? 1 : i.refuse ? 2 : 0);
3415
+ }), this.record ? this.edit(Object.fromEntries(e)) : this.add(Object.fromEntries(e));
3416
+ }
3417
+ });
3418
+ },
3419
+ changeAllow(t, e) {
3420
+ t && (e.refuse = !1);
3421
+ },
3422
+ changeRefuse(t, e) {
3423
+ t && (e.allow = !1);
3424
+ },
3425
+ delPrincipalid(t) {
3426
+ this.ruleForm.principalidAboutIdBatch = this.ruleForm.principalidAboutIdBatch.filter((e) => e !== t.id), this.getBatchPrincipalid();
3427
+ },
3428
+ getBatchPrincipalid() {
3429
+ let t = [];
3430
+ this.fkData.forEach((e) => {
3431
+ if (this.ruleForm.principalidAboutIdBatch.includes(e.id)) {
3432
+ const i = this.tableLists.filter((s) => s.tablename === e.tableName)[0];
3433
+ t.push(
3434
+ Object.assign({}, e, {
3435
+ tableBusName: i ? i.busname : "--",
3436
+ tableTransKey: i ? i.transkey : null,
3437
+ errTip: ""
3438
+ })
3439
+ );
3440
+ }
3441
+ }), this.batchPrincipalid = t;
3442
+ },
3443
+ lookup() {
3444
+ const t = this.record ? this.ruleForm.principalidAboutId : this.ruleForm.principalidAboutIdBatch;
3445
+ this.$refs.viewSearch.open({
3446
+ fkEntityName: this.fkEntityName,
3447
+ effectType: this.record ? "about" : "participants",
3448
+ val: t
3449
+ });
3450
+ },
3451
+ lookupSeled(t) {
3452
+ this.fkData = [...t.fkData], Object.assign(this.ruleForm, {
3453
+ principalidAboutId: this.record ? t.data[0] : "",
3454
+ principalidAboutIdBatch: this.record ? [] : t.data
3455
+ }), this.getBatchPrincipalid();
3456
+ },
3457
+ searchData(t) {
3458
+ const e = this.fkEntityName.split(",")[0], i = { name: t, fkEntityName: e }, s = this.fkData.filter((r) => r.id === this.ruleForm.principalidAboutId);
3459
+ this.loading = !0, ae(i).then((r) => {
3460
+ if (this.loading = !1, r.code === 200) {
3461
+ r.data.map((n) => (n.tableName = e, n));
3462
+ const a = r.data.filter((n) => n.id !== this.ruleForm.principalidAboutId).filter((n) => !this.disabledRowId.includes(n.id));
3463
+ this.fkData = s.concat(a);
3464
+ }
3465
+ });
3466
+ },
3467
+ open(t) {
3468
+ this.record = t, this.visible = !0;
3469
+ let e = JSON.parse(JSON.stringify(this.permissionList)).map((i) => Object.assign(i, {
3470
+ show: ["createfile", "createsubfolder"].includes(i.code) ? this.recordData.type === 1 : !0
3471
+ }));
3472
+ if (!t) {
3473
+ this.list = e, this.searchData("");
3474
+ return;
3475
+ }
3476
+ this.ruleForm = {
3477
+ principalidAboutId: t.principalid_aboutid,
3478
+ principalidAboutTable: t.principalid_abouttable,
3479
+ principalidAboutIdBatch: []
3480
+ }, this.list = e.map((i) => {
3481
+ const s = t[i.code];
3482
+ return Object.assign(i, { allow: s === 1, refuse: s === 2 });
3483
+ }), this.fkData = [{ tableName: t.principalid_abouttable, id: t.principalid_aboutid, name: t.principalname }];
3484
+ },
3485
+ closed() {
3486
+ this.hasRefresh && (this.$emit("ok"), this.hasRefresh = !1), this.ruleForm = {
3487
+ principalidAboutIdBatch: [],
3488
+ principalidAboutId: "",
3489
+ principalidAboutTable: ""
3490
+ }, this.batchPrincipalid = [], this.fullscreen = !1, this.visible = !1;
3491
+ },
3492
+ onSelectChange(t, e) {
3493
+ this.selectedRowKeys = t, this.selectedRows = e;
3494
+ },
3495
+ getDictionary(t) {
3496
+ return this.$options.filters.dictData(t);
3497
+ },
3498
+ fadeColor(t, e) {
3499
+ let i = parseInt(t.substring(1, 3), 16), s = parseInt(t.substring(3, 5), 16), r = parseInt(t.substring(5, 7), 16);
3500
+ return `rgba(${i},${s},${r},${e})`;
3501
+ },
3502
+ toggleFullscreen() {
3503
+ this.fullscreen = !this.fullscreen;
3504
+ },
3505
+ doEvent(t) {
3506
+ let e = t.item.functionName;
3507
+ this[e] && this[e]();
3508
+ }
3509
+ }
3510
+ };
3511
+ var Kt = function() {
3512
+ var e = this, i = e._self._c;
3513
+ return i("div", [i("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "append-to-body": !0, "modal-append-to-body": !1, top: "80px", "show-close": !1 }, on: { "update:visible": function(s) {
3514
+ e.visible = s;
3515
+ }, closed: e.closed } }, [i("gd-modal-title", { attrs: { slot: "title", title: e.title, fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen }, slot: "title" }), i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }], style: { "--fadecolor": e.fadeColord } }, [e.visible ? i("el-form", { ref: "ruleForm", staticClass: "gd-form", attrs: { model: e.ruleForm, "label-width": "120px", rules: e.rules }, nativeOn: { submit: function(s) {
3516
+ s.preventDefault();
3517
+ } } }, [i("el-row", { attrs: { gutter: 24 } }, [i("el-col", { attrs: { span: 12 } }, [e.record ? i("el-form-item", { attrs: { label: e.$i18nt("gd.fileDocument.userGroup", "\u7528\u6237/\u7528\u6237\u7EC4"), prop: "principalidAboutId" } }, [i("div", { staticClass: "cao_about" }, [i("el-select", { staticClass: "cao_input", attrs: { placeholder: e.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), loading: e.loading, "reserve-keyword": "", filterable: "", remote: "", clearable: "", "remote-method": e.searchData, disabled: e.disabled }, model: { value: e.ruleForm.principalidAboutId, callback: function(s) {
3518
+ e.$set(e.ruleForm, "principalidAboutId", s);
3519
+ }, expression: "ruleForm.principalidAboutId" } }, e._l(e.fkData, function(s) {
3520
+ return i("el-option", { key: s.id, attrs: { label: s.name, value: s.id } });
3521
+ }), 1), i("div", { staticClass: "cao_setting" }, [i("i", { staticClass: "el-input__icon el-icon-search", on: { click: e.lookup } })])], 1)]) : i("el-form-item", { attrs: { label: e.$i18nt("gd.fileDocument.userGroup", "\u7528\u6237/\u7528\u6237\u7EC4"), prop: "principalidAboutIdBatch" } }, [i("div", { staticClass: "cao_about" }, [i("el-select", { staticClass: "cao_input", attrs: { multiple: "", placeholder: e.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), loading: e.loading, "reserve-keyword": "", filterable: "", remote: "", clearable: "", "remote-method": e.searchData, "collapse-tags": "", "multiple-limit": e.multipleLimit }, on: { change: e.getBatchPrincipalid }, model: { value: e.ruleForm.principalidAboutIdBatch, callback: function(s) {
3522
+ e.$set(e.ruleForm, "principalidAboutIdBatch", s);
3523
+ }, expression: "ruleForm.principalidAboutIdBatch" } }, e._l(e.fkData, function(s) {
3524
+ return i("el-option", { key: s.id, attrs: { label: s.name, value: s.id } });
3525
+ }), 1), i("div", { staticClass: "cao_setting" }, [i("i", { staticClass: "el-input__icon el-icon-search", on: { click: e.lookup } })])], 1)])], 1)], 1)], 1) : e._e(), [e.batchPrincipalid.length > 0 ? i("div", { staticClass: "batch-principalid" }, [e._l(e.batchPrincipalid, function(s) {
3526
+ return [i("div", { staticClass: "item" }, [s.errTip ? i("el-tooltip", { attrs: { placement: "top", effect: "dark", content: s.errTip } }, [i("i", { staticClass: "el-icon-warning" })]) : e._e(), i("el-tooltip", { staticClass: "name-tooltip", attrs: { effect: "dark", content: `${s.name} (${e.$i18nt(`Dynamics.${s.tableTransKey}`, s.tableBusName)})`, placement: "top" } }, [i("div", { staticClass: "line1" }, [e._v(" " + e._s(s.name) + " ")])]), i("i", { staticClass: "el-icon-error", on: { click: function(r) {
3527
+ return e.delPrincipalid(s);
3528
+ } } })], 1)];
3529
+ })], 2) : e._e(), e.batchPrincipalid.length > e.multipleLimit ? i("div", { staticClass: "max-tip" }, [e._v(e._s(e.maxTip))]) : e._e()], i("el-divider"), i("div", { staticClass: "list" }, [i("div", { staticClass: "list-item list-label" }, [i("div", { staticClass: "item-name" }, [e._v(e._s(e.$i18nt("gd.page.limitsAuthority", "\u6743\u9650")))]), i("div", { staticClass: "item-hand", staticStyle: { color: "#52c41a" } }, [e._v(e._s(e.$i18nt("gd.page.allow", "\u5141\u8BB8")))]), i("div", { staticClass: "item-hand", staticStyle: { color: "red" } }, [e._v(e._s(e.$i18nt("gd.page.refuse", "\u62D2\u7EDD")))])]), i("div", { staticClass: "list-kuang" }, [e._l(e.list, function(s) {
3530
+ return [s.show ? i("div", { staticClass: "list-item" }, [i("div", { staticClass: "item-name" }, [e._v(" " + e._s(e.$i18nt(s.transkey, s.name)) + " ( "), i("span", { staticClass: "active-color" }, [e._v(e._s(s.code))]), e._v(" ) ")]), i("div", { staticClass: "item-hand" }, [i("el-checkbox", { attrs: { disabled: e.disabled }, on: { change: (r) => e.changeAllow(r, s) }, model: { value: s.allow, callback: function(r) {
3531
+ e.$set(s, "allow", r);
3532
+ }, expression: "item.allow" } })], 1), i("div", { staticClass: "item-hand" }, [i("el-checkbox", { attrs: { disabled: e.disabled }, on: { change: (r) => e.changeRefuse(r, s) }, model: { value: s.refuse, callback: function(r) {
3533
+ e.$set(s, "refuse", r);
3534
+ }, expression: "item.refuse" } })], 1)]) : e._e()];
3535
+ })], 2)]), e.docacltemList.length > 0 ? i("div", { staticClass: "list" }, [i("el-alert", { staticStyle: { "border-radius": "6px 6px 0 0" }, attrs: { "show-icon": "", title: e.$i18nt("gd.fileDocument.quicklyPermission", "\u5FEB\u901F\u9009\u62E9\u6743\u9650\u6A21\u5757"), type: "info", effect: "dark", closable: !1 } }), i("div", { staticClass: "list-kuang" }, [i("div", { staticClass: "list-dict" }, [e._l(e.docacltemList, function(s) {
3536
+ return [i("div", { staticClass: "dict-item" }, [i("div", { staticClass: "item-name gdhvr-float-shadow", style: s.bjcolor, on: { click: function(r) {
3537
+ return e.selDocacltem(s);
3538
+ } } }, [e._v(" " + e._s(e.$i18nt(`Dynamics.${s.transkey}`, s.name)) + " ")])])];
3539
+ })], 2)])], 1) : e._e()], 2)], 1), i("gd-search", { ref: "viewSearch", attrs: { appendToBody: !0, disabledRowId: e.disabledRowId }, on: { lookupSeled: e.lookupSeled } })], 1);
3540
+ }, Rt = [], Vt = /* @__PURE__ */ d(
3541
+ Mt,
3542
+ Kt,
3543
+ Rt,
3544
+ !1,
3545
+ null,
3546
+ "66c78ea8",
3547
+ null,
3548
+ null
3549
+ );
3550
+ const qt = Vt.exports, Ht = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3551
+ __proto__: null,
3552
+ default: qt
3553
+ }, Symbol.toStringTag, { value: "Module" }));
3554
+ const Ut = {
3555
+ data() {
3556
+ return {
3557
+ record: null,
3558
+ width: "600px",
3559
+ confirmLoading: !1,
3560
+ visible: !1,
3561
+ fullscreen: !1,
3562
+ buttons: [
3563
+ {
3564
+ displayName: "\u786E\u5B9A",
3565
+ functionName: "handleSubmit",
3566
+ show: !0,
3567
+ transKey: "gd.btn.confirm",
3568
+ icon: "el-icon-document-checked"
3569
+ }
3570
+ ],
3571
+ ruleForm: {},
3572
+ docTypeList: [],
3573
+ attributesList: []
3574
+ };
3575
+ },
3576
+ components: {
3577
+ LayoutItemColumn: () => Promise.resolve().then(() => T)
3578
+ },
3579
+ computed: {
3580
+ title() {
3581
+ return this.$i18nt("gd.btn.edit", "\u7F16\u8F91");
3582
+ },
3583
+ rulesInput() {
3584
+ return [{ required: !0, message: this.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), trigger: ["change", "blur"] }];
3585
+ },
3586
+ rulesSelect() {
3587
+ return [{ required: !0, message: this.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), trigger: ["change", "blur"] }];
3588
+ },
3589
+ timeLongshort() {
3590
+ return this.getDictionary("time_longshort");
3591
+ }
3592
+ },
3593
+ methods: {
3594
+ edit() {
3595
+ let t = [];
3596
+ this.attributesList.forEach((e) => {
3597
+ t.push({ attrCode: e.prop, attrValue: ["checkbox"].includes(e.effectType) ? this.ruleForm[e.prop].join(",") : this.ruleForm[e.prop] });
3598
+ }), I(
3599
+ Object.assign({}, this.record, {
3600
+ attributes: t
3601
+ })
3602
+ ).then((e) => {
3603
+ this.confirmLoading = !1, e.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok"), this.closed()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + e.message);
3604
+ });
3605
+ },
3606
+ handleSubmit() {
3607
+ this.confirmLoading = !0, this.$refs.ruleForm.validate((t) => {
3608
+ if (!t) {
3609
+ this.confirmLoading = !1;
3610
+ return;
3611
+ }
3612
+ this.edit();
3613
+ });
3614
+ },
3615
+ getAttrData(t, e) {
3616
+ const i = w(t), s = e.filter((a) => a.attrcode === t.attrcode)[0], r = s ? s.attrvalue : i;
3617
+ return ["inputnumber", "double"].includes(t.datatype) ? r !== "" && r !== null ? r : void 0 : ["checkbox"].includes(t.datatype) ? r ? s ? r.split(",") : r : [] : ["fk"].includes(t.datatype) ? r ? Number(r) : "" : r;
3618
+ },
3619
+ init() {
3620
+ this.confirmLoading = !0, Promise.all([this.getDetail(), this.getDocTypePage()]).then((t) => {
3621
+ const e = this.docTypeList.filter((n) => n.id === this.record.sysdoctypeid)[0], i = e ? e.sysdoctypeattributes : [];
3622
+ let s = /* @__PURE__ */ new Map(), r = [];
3623
+ const a = this.record.attributes ? this.record.attributes : [];
3624
+ i.forEach((n) => {
3625
+ if (n.ishidden !== 1) {
3626
+ const l = JSON.parse(n.reserve1);
3627
+ let o = {
3628
+ label: n.name,
3629
+ transKey: n.transkey ? `Dynamics.${n.transkey}` : null,
3630
+ prop: n.attrcode,
3631
+ dictTypeCode: n.dicttypecode,
3632
+ effectType: n.datatype,
3633
+ rules: n.statecodes !== 1 ? [] : n.isrequired === 1 ? C(n, {
3634
+ rulesInput: this.rulesInput,
3635
+ rulesSelect: this.rulesSelect
3636
+ }) : [],
3637
+ pickerType: D(n, this.timeLongshort),
3638
+ fieldFormat: p(n, this.timeLongshort),
3639
+ fkEntityName: n.fkentity,
3640
+ fieldsize: n.datatype === "inputnumber" ? 0 : n.fieldsize,
3641
+ isDatePicker: k(n, this.timeLongshort),
3642
+ viewId: l.viewId ? l.viewId : "",
3643
+ disabled: n.statecodes !== 1
3644
+ };
3645
+ const c = this.getAttrData(n, a);
3646
+ if (["fk"].includes(n.datatype) && c) {
3647
+ const m = a.filter((g) => g.attrcode === n.attrcode)[0];
3648
+ Object.assign(o, {
3649
+ fkData: [{ id: Number(c), name: m ? m.attrname : "" }]
3650
+ });
3651
+ }
3652
+ r.push(o), s.set(n.attrcode, c);
3653
+ }
3654
+ }), this.ruleForm = Object.fromEntries(s), this.attributesList = r, this.confirmLoading = !1, this.$nextTick(() => {
3655
+ setTimeout(() => {
3656
+ this.$refs.ruleForm && this.$refs.ruleForm.clearValidate();
3657
+ }, 100);
3658
+ });
3659
+ });
3660
+ },
3661
+ open(t) {
3662
+ this.record = t, this.visible = !0, this.init();
3663
+ },
3664
+ getDocTypePage() {
3665
+ $({ pageno: 1, pagesize: 1e3 }).then((t) => {
3666
+ t.code === 200 && (this.docTypeList = t.data.rows);
3667
+ });
3668
+ },
3669
+ getDetail() {
3670
+ return _({ id: this.record.id }).then((t) => (t.code !== 200 || (this.record = t.data), t));
3671
+ },
3672
+ closed() {
3673
+ this.ruleForm = {}, this.attributesList = [], this.fullscreen = !1, this.visible = !1;
3674
+ },
3675
+ getDictionary(t) {
3676
+ return this.$options.filters.dictData(t);
3677
+ },
3678
+ toggleFullscreen() {
3679
+ this.fullscreen = !this.fullscreen;
3680
+ },
3681
+ doEvent(t) {
3682
+ let e = t.item.functionName;
3683
+ this[e] && this[e]();
3684
+ }
3685
+ }
3686
+ };
3687
+ var Jt = function() {
3688
+ var e = this, i = e._self._c;
3689
+ return i("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "append-to-body": !0, "modal-append-to-body": !1, top: "80px", "show-close": !1, "destroy-on-close": !0 }, on: { "update:visible": function(s) {
3690
+ e.visible = s;
3691
+ }, closed: e.closed } }, [i("gd-modal-title", { attrs: { slot: "title", title: e.title, fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen }, slot: "title" }), i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }], staticStyle: { "min-height": "300px" } }, [e.visible ? i("el-form", { ref: "ruleForm", staticClass: "gd-form", attrs: { model: e.ruleForm, "label-width": "140px" }, nativeOn: { submit: function(s) {
3692
+ s.preventDefault();
3693
+ } } }, [e._l(e.attributesList, function(s) {
3694
+ return [i("el-form-item", { attrs: { label: e.$i18nt(s.transKey, s.label), prop: s.prop, rules: s.rules, title: e.$i18nt(s.transKey, s.label) } }, [i("LayoutItemColumn", { attrs: { record: s, ruleFormData: e.ruleForm } })], 1)];
3695
+ })], 2) : e._e()], 1)], 1);
3696
+ }, Wt = [], Qt = /* @__PURE__ */ d(
3697
+ Ut,
3698
+ Jt,
3699
+ Wt,
3700
+ !1,
3701
+ null,
3702
+ "19ee5b98",
3703
+ null,
3704
+ null
3705
+ );
3706
+ const Gt = Qt.exports, Xt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
3707
+ __proto__: null,
3708
+ default: Gt
3709
+ }, Symbol.toStringTag, { value: "Module" }));
3710
+ const Yt = {
3711
+ props: {
3712
+ recordData: {
3713
+ type: Object,
3714
+ default: () => {
3715
+ }
3716
+ },
3717
+ fileAccept: {
3718
+ type: String,
3719
+ default: ""
3720
+ },
3721
+ fileSize: {
3722
+ type: Number,
3723
+ default: 1024
3724
+ }
3725
+ },
3726
+ data() {
3727
+ return {
3728
+ type: "add",
3729
+ ruleFormRecord: {
3730
+ options: {
3731
+ fileName: "file",
3732
+ drag: !0
3733
+ }
3734
+ },
3735
+ attributeData: {},
3736
+ record: null,
3737
+ width: "80%",
3738
+ confirmLoading: !1,
3739
+ visible: !1,
3740
+ fullscreen: !1,
3741
+ buttons: [
3742
+ {
3743
+ displayName: "\u786E\u5B9A",
3744
+ functionName: "handleSubmit",
3745
+ show: !0,
3746
+ transKey: "gd.btn.confirm",
3747
+ icon: "el-icon-document-checked"
3748
+ }
3749
+ ],
3750
+ ruleForm: {
3751
+ fileId: "",
3752
+ name: "",
3753
+ filetype: "",
3754
+ filesize: "",
3755
+ version: "",
3756
+ sysdoctypeid: ""
3757
+ },
3758
+ rules: {
3759
+ name: [
3760
+ { required: !0, message: this.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), trigger: ["change", "blur"] },
3761
+ {
3762
+ pattern: /^((?!\\|\/|:|\*|\?|<|>|\||'|%|\!|"|').){1,50}$/,
3763
+ message: this.$i18nt("gd.fileDocument.addNameTip", '\u540D\u79F0\u4E0D\u80FD\u5305\u542B\u4EE5\u4E0B\u5B57\u7B26\uFF1A<>:"/|?*%!')
3764
+ }
3765
+ ],
3766
+ fileId: [{ required: !0, message: this.$i18nt("gd.web.selectFileTip", "\u8BF7\u9009\u62E9\u6587\u4EF6!"), trigger: ["change", "blur"] }],
3767
+ version: [{ required: !0, message: this.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165!"), trigger: ["change", "blur"] }],
3768
+ sysdoctypeid: [{ required: !0, message: this.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), trigger: ["change", "blur"] }]
3769
+ },
3770
+ fileData: [],
3771
+ docTypeList: [],
3772
+ attributesList: []
3773
+ };
3774
+ },
3775
+ components: { UploadFile: N, LayoutItemColumn: () => Promise.resolve().then(() => T) },
3776
+ computed: {
3777
+ rulesInput() {
3778
+ return [{ required: !0, message: this.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), trigger: ["change", "blur"] }];
3779
+ },
3780
+ rulesSelect() {
3781
+ return [{ required: !0, message: this.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), trigger: ["change", "blur"] }];
3782
+ },
3783
+ title() {
3784
+ return this.type === "copy" ? this.$i18nt("gd.fileDocument.recoveryVersion", "\u6062\u590D\u7248\u672C") : this.type === "edit" ? this.$i18nt("gd.btn.edit", "\u7F16\u8F91") : this.$i18nt("gd.fileDocument.createNewVersion", "\u521B\u5EFA\u65B0\u7248\u672C");
3785
+ },
3786
+ timeLongshort() {
3787
+ return this.getDictionary("time_longshort");
3788
+ }
3789
+ },
3790
+ methods: {
3791
+ edit() {
3792
+ let t = {
3793
+ name: this.ruleForm.name,
3794
+ filetype: this.ruleForm.filetype,
3795
+ filesize: this.ruleForm.filesize,
3796
+ version: this.ruleForm.version,
3797
+ file: this.ruleForm.fileId,
3798
+ sysdoctypeid: this.ruleForm.sysdoctypeid
3799
+ }, e = [];
3800
+ const i = this.record.attributes ? this.record.attributes : [];
3801
+ this.attributesList.forEach((s) => {
3802
+ let r = { attrcode: s.prop, attrvalue: ["checkbox"].includes(s.effectType) ? this.ruleForm[s.prop].join(",") : this.ruleForm[s.prop] };
3803
+ const a = i.filter((n) => s.prop === n.attrcode)[0];
3804
+ a && (r = Object.assign({}, a, r)), e.push(r);
3805
+ }), ie(Object.assign(this.record, t, { attributes: e })).then((s) => {
3806
+ this.confirmLoading = !1, s.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok"), this.closed()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + s.message);
3807
+ });
3808
+ },
3809
+ add() {
3810
+ let t = {
3811
+ name: this.ruleForm.name,
3812
+ filetype: this.ruleForm.filetype,
3813
+ filesize: this.ruleForm.filesize,
3814
+ version: this.ruleForm.version,
3815
+ file: this.ruleForm.fileId,
3816
+ sysDocObjectId: this.recordData.id,
3817
+ sysdoctypeid: this.ruleForm.sysdoctypeid
3818
+ }, e = [];
3819
+ this.attributesList.forEach((i) => {
3820
+ e.push({ attrcode: i.prop, attrvalue: ["checkbox"].includes(i.effectType) ? this.ruleForm[i.prop].join(",") : this.ruleForm[i.prop] });
3821
+ }), se(
3822
+ Object.assign(t, {
3823
+ attributes: e
3824
+ })
3825
+ ).then((i) => {
3826
+ this.confirmLoading = !1, i.success ? (this.$message.success(this.$i18nt("gd.https.operateSucc", "\u64CD\u4F5C\u6210\u529F")), this.$emit("ok"), this.closed()) : this.$message.error(this.$i18nt("gd.https.operateFail", "\u64CD\u4F5C\u5931\u8D25") + i.message);
3827
+ });
3828
+ },
3829
+ handleSubmit() {
3830
+ this.confirmLoading = !0, this.$refs.ruleForm.validate((t) => {
3831
+ if (!t) {
3832
+ this.confirmLoading = !1;
3833
+ return;
3834
+ }
3835
+ this.type === "edit" ? this.edit() : this.add();
3836
+ });
3837
+ },
3838
+ changeDocType(t) {
3839
+ const e = this.docTypeList.filter((a) => a.id === t)[0];
3840
+ if (!e)
3841
+ return;
3842
+ this.confirmLoading = !0;
3843
+ let i = [], s = /* @__PURE__ */ new Map();
3844
+ e.sysdoctypeattributes.forEach((a) => {
3845
+ if (a.ishidden !== 1) {
3846
+ const n = JSON.parse(a.reserve1);
3847
+ i.push({
3848
+ label: a.name,
3849
+ transKey: a.transkey ? `Dynamics.${a.transkey}` : null,
3850
+ prop: a.attrcode,
3851
+ dictTypeCode: a.dicttypecode,
3852
+ effectType: a.datatype,
3853
+ rules: a.statecodes !== 1 ? [] : a.isrequired === 1 ? C(a, {
3854
+ rulesInput: this.rulesInput,
3855
+ rulesSelect: this.rulesSelect
3856
+ }) : [],
3857
+ pickerType: D(a, this.timeLongshort),
3858
+ fieldFormat: p(a, this.timeLongshort),
3859
+ fkEntityName: a.fkentity,
3860
+ fieldsize: a.datatype === "inputnumber" ? 0 : a.fieldsize,
3861
+ isDatePicker: k(a, this.timeLongshort),
3862
+ viewId: n.viewId ? n.viewId : "",
3863
+ disabled: a.statecodes !== 1
3864
+ }), s.set(a.attrcode, w(a));
3865
+ }
3866
+ }), this.attributesList = i;
3867
+ const r = Object.assign({}, this.ruleForm, Object.fromEntries(s));
3868
+ this.ruleForm = JSON.parse(JSON.stringify(r)), setTimeout(() => {
3869
+ this.confirmLoading = !1;
3870
+ }, 300);
3871
+ },
3872
+ handleChange(t) {
3873
+ this.confirmLoading = !0;
3874
+ const e = JSON.parse(t.sourceData)[0];
3875
+ let i = { filetype: "", filesize: 0, fileId: "" };
3876
+ if (e) {
3877
+ const s = e.name.substr(e.name.lastIndexOf(".") + 1), r = this.fileData.filter((a) => a.uid === e.ouid)[0];
3878
+ Object.assign(i, {
3879
+ filetype: s,
3880
+ filesize: r ? r.size : 0,
3881
+ fileId: e.fileId
3882
+ });
3883
+ }
3884
+ Object.assign(this.ruleForm, i), setTimeout(() => {
3885
+ this.$refs.ruleForm.clearValidate(), this.confirmLoading = !1;
3886
+ }, 100);
3887
+ },
3888
+ uploadFile(t) {
3889
+ const e = this.fileData.filter((i) => i.uid !== t.file.uid);
3890
+ this.fileData = e.concat([t.file]);
3891
+ },
3892
+ inputName(t, e) {
3893
+ e.name = t.replace(/\s+/g, "");
3894
+ },
3895
+ getAttrData(t, e) {
3896
+ const i = w(t), s = e.filter((a) => a.attrcode === t.attrcode)[0], r = s ? s.attrvalue : i;
3897
+ return ["inputnumber", "double"].includes(t.datatype) ? r !== "" && r !== null ? r : void 0 : ["checkbox"].includes(t.datatype) ? r ? s ? r.split(",") : r : [] : ["fk"].includes(t.datatype) ? r ? Number(r) : "" : r;
3898
+ },
3899
+ init() {
3900
+ this.confirmLoading = !0, Promise.all([this.getVersionDetails(), this.getDocTypePage()]).then((t) => {
3901
+ this.confirmLoading = !1;
3902
+ let e = {
3903
+ name: this.recordData.name,
3904
+ version: "",
3905
+ fileId: "",
3906
+ filetype: "",
3907
+ filesize: "",
3908
+ sysdoctypeid: this.recordData.sysdoctypeid
3909
+ }, i = [];
3910
+ this.record && (Object.assign(e, {
3911
+ version: this.record.version,
3912
+ fileId: this.record.file,
3913
+ filetype: this.record.filetype,
3914
+ filesize: this.record.filesize
3915
+ }), i = this.record.attributes ? this.record.attributes : []);
3916
+ const s = this.docTypeList.filter((o) => o.id === this.recordData.sysdoctypeid)[0], r = s.sysdoctypeattributes ? s.sysdoctypeattributes : [];
3917
+ let a = /* @__PURE__ */ new Map(), n = [];
3918
+ r.forEach((o) => {
3919
+ if (o.ishidden !== 1) {
3920
+ const c = JSON.parse(o.reserve1);
3921
+ let m = {
3922
+ label: o.name,
3923
+ transKey: null,
3924
+ prop: o.attrcode,
3925
+ dictTypeCode: o.dicttypecode,
3926
+ effectType: o.datatype,
3927
+ rules: o.statecodes !== 1 ? [] : o.isrequired === 1 ? C(o, {
3928
+ rulesInput: this.rulesInput,
3929
+ rulesSelect: this.rulesSelect
3930
+ }) : [],
3931
+ pickerType: D(o, this.timeLongshort),
3932
+ fieldFormat: p(o, this.timeLongshort),
3933
+ fkEntityName: o.fkentity,
3934
+ fieldsize: o.datatype === "inputnumber" ? 0 : o.fieldsize,
3935
+ isDatePicker: k(o, this.timeLongshort),
3936
+ viewId: c.viewId ? c.viewId : "",
3937
+ disabled: o.statecodes !== 1
3938
+ };
3939
+ const g = this.getAttrData(o, i);
3940
+ if (["fk"].includes(o.datatype) && g) {
3941
+ const S = i.filter((z) => z.attrcode === o.attrcode)[0];
3942
+ Object.assign(m, {
3943
+ fkData: [{ id: Number(g), name: S ? S.attrname : "" }]
3944
+ });
3945
+ }
3946
+ n.push(m), a.set(o.attrcode, g);
3947
+ }
3948
+ });
3949
+ const l = Object.assign({}, this.ruleForm, e, Object.fromEntries(a));
3950
+ this.ruleForm = JSON.parse(JSON.stringify(l)), this.attributesList = n, this.ruleForm.fileId && this.$nextTick(() => {
3951
+ setTimeout(() => {
3952
+ this.$refs.uploadFile.setData(JSON.stringify([{ name: this.ruleForm.name, id: this.ruleForm.fileId }]));
3953
+ }, 100);
3954
+ }), this.$nextTick(() => {
3955
+ setTimeout(() => {
3956
+ this.$refs.ruleForm && this.$refs.ruleForm.clearValidate();
3957
+ }, 0);
3958
+ });
3959
+ });
3960
+ },
3961
+ getVersionDetails() {
3962
+ return this.record ? re({ id: this.record.id }).then((t) => (t.code === 200 && (this.record = Object.assign({}, this.record, t.data)), t)) : new Promise((t) => {
3963
+ t();
3964
+ });
3965
+ },
3966
+ getDocTypePage() {
3967
+ return $({ pageno: this.pageno, pagesize: this.pagesize }).then((t) => (t.code === 200 && (this.docTypeList = t.data.rows.filter((e) => e.statecodes === 1)), t));
3968
+ },
3969
+ open(t, e = "add") {
3970
+ this.type = e, this.record = t, this.visible = !0, this.init();
3971
+ },
3972
+ closed() {
3973
+ this.fileData = [], this.ruleForm = {
3974
+ fileId: "",
3975
+ name: "",
3976
+ filetype: "",
3977
+ filesize: "",
3978
+ version: "",
3979
+ sysdoctypeid: ""
3980
+ }, this.attributesList = [], this.fullscreen = !1, this.visible = !1;
3981
+ },
3982
+ getDictionary(t) {
3983
+ return this.$options.filters.dictData(t);
3984
+ },
3985
+ toggleFullscreen() {
3986
+ this.fullscreen = !this.fullscreen;
3987
+ },
3988
+ doEvent(t) {
3989
+ let e = t.item.functionName;
3990
+ this[e] && this[e]();
3991
+ }
3992
+ }
3993
+ };
3994
+ var Zt = function() {
3995
+ var e = this, i = e._self._c;
3996
+ return i("el-dialog", { directives: [{ name: "drag", rawName: "v-drag" }], ref: "dialog", class: e.fullscreen ? "gd-dialog gd-dialog-fangda" : "gd-dialog", attrs: { fullscreen: e.fullscreen, visible: e.visible, width: e.width, center: !0, "close-on-click-modal": !1, "append-to-body": !0, "modal-append-to-body": !1, top: "80px", "show-close": !1, "destroy-on-close": !0 }, on: { "update:visible": function(s) {
3997
+ e.visible = s;
3998
+ }, closed: e.closed } }, [i("gd-modal-title", { attrs: { slot: "title", title: e.title, fullscreen: e.fullscreen, buttons: e.buttons, confirmLoading: e.confirmLoading, showClose: !0 }, on: { changeEvent: e.doEvent, toggleFullscreen: e.toggleFullscreen }, slot: "title" }), i("div", { directives: [{ name: "loading", rawName: "v-loading", value: e.confirmLoading, expression: "confirmLoading" }] }, [e.visible ? i("el-form", { ref: "ruleForm", staticClass: "gd-form", attrs: { model: e.ruleForm, "label-width": "160px", rules: e.rules }, nativeOn: { submit: function(s) {
3999
+ s.preventDefault();
4000
+ } } }, [i("el-form-item", { staticStyle: { width: "100%" }, attrs: { label: e.$i18nt("gd.page.uploadFile", "\u4E0A\u4F20\u6587\u4EF6"), prop: "fileId" } }, [i("UploadFile", { ref: "uploadFile", attrs: { record: e.ruleFormRecord, model: e.ruleForm, limit: 1, prop: "file", accept: e.fileAccept, size: e.fileSize }, on: { change: e.handleChange, uploadFile: e.uploadFile } })], 1), i("el-row", { attrs: { gutter: 24 } }, [i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { attrs: { label: e.$i18nt("gd.translation.name", "\u540D\u79F0"), prop: "name" } }, [i("el-input", { attrs: { clearable: "", placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), maxlength: 50, disabled: "" }, on: { input: (s) => e.inputName(s, e.ruleForm) }, model: { value: e.ruleForm.name, callback: function(s) {
4001
+ e.$set(e.ruleForm, "name", s);
4002
+ }, expression: "ruleForm.name" } })], 1)], 1), i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { attrs: { label: e.$i18nt("gd.fileDocument.classification", "\u6587\u6863\u5206\u7C7B"), prop: "sysdoctypeid", title: e.$i18nt("gd.fileDocument.classification", "\u6587\u6863\u5206\u7C7B") } }, [i("el-select", { staticStyle: { width: "100%" }, attrs: { placeholder: e.$i18nt("gd.placeholder.select", "\u8BF7\u9009\u62E9"), clearable: "", remote: "", filterable: "", disabled: !!e.recordData.sysdoctypeid }, on: { change: e.changeDocType }, model: { value: e.ruleForm.sysdoctypeid, callback: function(s) {
4003
+ e.$set(e.ruleForm, "sysdoctypeid", s);
4004
+ }, expression: "ruleForm.sysdoctypeid" } }, e._l(e.docTypeList, function(s) {
4005
+ return i("el-option", { key: s.id, attrs: { label: e.$i18nt(`Dynamics.${s.transkey}`, s.name), value: s.id } });
4006
+ }), 1)], 1)], 1), i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { attrs: { label: e.$i18nt("gd.solution.version", "\u7248\u672C"), prop: "version", title: e.$i18nt("gd.solution.version", "\u7248\u672C") } }, [i("el-input", { attrs: { clearable: "", placeholder: e.$i18nt("gd.placeholder.input", "\u8BF7\u8F93\u5165"), maxlength: 50 }, model: { value: e.ruleForm.version, callback: function(s) {
4007
+ e.$set(e.ruleForm, "version", s);
4008
+ }, expression: "ruleForm.version" } })], 1)], 1), e._l(e.attributesList, function(s) {
4009
+ return [i("el-col", { attrs: { span: 12 } }, [i("el-form-item", { attrs: { label: e.$i18nt(s.transKey, s.label), prop: s.prop, rules: s.rules, title: e.$i18nt(s.transKey, s.label) } }, [i("LayoutItemColumn", { attrs: { record: s, ruleFormData: e.ruleForm } })], 1)], 1)];
4010
+ })], 2)], 1) : e._e()], 1)], 1);
4011
+ }, ei = [], ti = /* @__PURE__ */ d(
4012
+ Yt,
4013
+ Zt,
4014
+ ei,
4015
+ !1,
4016
+ null,
4017
+ "ebc90cc9",
4018
+ null,
4019
+ null
4020
+ );
4021
+ const ii = ti.exports, si = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
4022
+ __proto__: null,
4023
+ default: ii
4024
+ }, Symbol.toStringTag, { value: "Module" }));
4025
+ export {
4026
+ be as a,
4027
+ ce as b,
4028
+ fe as c,
4029
+ ge as d,
4030
+ oi as e,
4031
+ me as f,
4032
+ ne as g,
4033
+ Ce as j,
4034
+ he as l,
4035
+ oe as m,
4036
+ le as p,
4037
+ de as r,
4038
+ _e as w
4039
+ };