cnhis-design-vue 3.2.14-release.0 → 3.2.15-beta.2

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 (337) hide show
  1. package/README.md +87 -87
  2. package/es/components/ai-chat/index.d.ts +1 -0
  3. package/es/components/ai-chat/src/Index.vue.d.ts +1 -0
  4. package/es/components/ai-chat/src/components/ChatCard.js +1 -1
  5. package/es/components/ai-chat/src/components/ChatFooter.vue.d.ts +1 -0
  6. package/es/components/ai-chat/src/components/ChatFooter.vue2.js +1 -1
  7. package/es/components/ai-chat/src/components/ChatMain.js +1 -1
  8. package/es/components/ai-chat/src/components/ChatPatient.vue2.js +1 -1
  9. package/es/components/ai-chat/src/components/ChatPrompt.vue2.js +1 -1
  10. package/es/components/ai-chat/style/index.css +1 -1
  11. package/es/components/audio-sdk/src/components/recording.vue2.js +1 -1
  12. package/es/components/base-search/index.d.ts +8 -3
  13. package/es/components/base-search/src/index.vue.d.ts +8 -3
  14. package/es/components/base-search/src/index.vue2.js +1 -1
  15. package/es/components/big-table/src/BigTable.vue2.js +1 -1
  16. package/es/components/big-table/src/components/NoData.vue2.js +1 -1
  17. package/es/components/big-table/src/components/edit-form/edit-date.js +1 -1
  18. package/es/components/big-table/src/components/edit-form/edit-input.js +1 -1
  19. package/es/components/big-table/src/components/edit-form/edit-select.js +1 -1
  20. package/es/components/big-table/src/components/edit-form/edit-time.js +1 -1
  21. package/es/components/big-table/src/components/input-button.vue2.js +1 -1
  22. package/es/components/big-table/src/hooks/useNestTable.js +1 -1
  23. package/es/components/big-table/src/hooks/useTableParse.js +1 -1
  24. package/es/components/body-select/src/index.vue2.js +1 -1
  25. package/es/components/bpmn-workflow/src/BpmnWorkflow.d.ts +0 -0
  26. package/es/components/bpmn-workflow/types/BpmnViewer.d.ts +1 -0
  27. package/es/components/bpmn-workflow/types/ModelingModule.d.ts +1 -0
  28. package/es/components/bpmn-workflow/types/MoveCanvasModule.d.ts +1 -0
  29. package/es/components/branch-notice/index.d.ts +63 -0
  30. package/es/components/branch-notice/index.js +1 -0
  31. package/es/components/branch-notice/src/BranchNotice.vue.d.ts +64 -0
  32. package/es/components/branch-notice/src/BranchNotice.vue.js +1 -0
  33. package/es/components/branch-notice/src/BranchNotice.vue2.js +1 -0
  34. package/es/components/branch-notice/src/canstants.d.ts +7 -0
  35. package/es/components/branch-notice/src/canstants.js +1 -0
  36. package/es/components/branch-notice/src/components/NoticeItem.vue.d.ts +151 -0
  37. package/es/components/branch-notice/src/components/NoticeItemAside.vue.d.ts +35 -0
  38. package/es/components/branch-notice/src/components/NoticeOperationList.vue.d.ts +49 -0
  39. package/es/components/branch-notice/src/drawLine.d.ts +2 -0
  40. package/es/components/branch-notice/src/drawLine.js +1 -0
  41. package/es/components/branch-notice/src/types.d.ts +14 -0
  42. package/es/components/branch-notice/src/types.js +1 -0
  43. package/es/components/branch-notice/style/index.css +1 -0
  44. package/es/components/button-print/index.d.ts +4 -0
  45. package/es/components/button-print/src/ButtonPrint.vue.d.ts +4 -0
  46. package/es/components/button-print/src/ButtonPrint.vue2.js +1 -1
  47. package/es/components/button-print/src/components/EditFormat.vue2.js +1 -1
  48. package/es/components/button-print/src/components/IdentityVerification.vue2.js +1 -1
  49. package/es/components/button-print/src/components/NewPrintComponent.vue.d.ts +4 -0
  50. package/es/components/button-print/src/components/NewPrintComponent.vue2.js +1 -1
  51. package/es/components/button-print/src/components/OldPrintComponent.vue2.js +1 -1
  52. package/es/components/button-print/src/components/Preview.vue2.js +1 -1
  53. package/es/components/button-print/src/utils/dialog.js +1 -1
  54. package/es/components/button-print/src/utils/print.js +1 -1
  55. package/es/components/calendar/index.d.ts +4 -4
  56. package/es/components/calendar/src/Calendar.vue.d.ts +4 -4
  57. package/es/components/card-reader-sdk/src/components/readCardDialog.vue2.js +1 -1
  58. package/es/components/card-reader-sdk/src/utils/readHealthCard.js +1 -1
  59. package/es/components/classification/index.d.ts +1 -0
  60. package/es/components/classification/src/components/search-filter/index.vue2.js +1 -1
  61. package/es/components/classification/src/components/set-classification/index.vue2.js +1 -1
  62. package/es/components/classification/src/components/table-modal/index.vue.d.ts +0 -3
  63. package/es/components/classification/src/components/table-modal/index.vue2.js +1 -1
  64. package/es/components/classification/src/index.vue.d.ts +1 -0
  65. package/es/components/classification/src/index.vue2.js +1 -1
  66. package/es/components/classification/style/index.css +1 -1
  67. package/es/components/default-page/src/constants/index.js +1 -1
  68. package/es/components/default-page/src/index.vue2.js +1 -1
  69. package/es/components/expand-field/src/components/FormBatchOptionsModal.vue2.js +1 -1
  70. package/es/components/expand-field/src/components/FormItemPerson.vue2.js +1 -1
  71. package/es/components/expand-field/src/components/PersonModal.vue2.js +1 -1
  72. package/es/components/expand-field/src/components/form.vue2.js +1 -1
  73. package/es/components/expand-field/src/index.vue2.js +1 -1
  74. package/es/components/expand-field/src/utils/constant.js +1 -1
  75. package/es/components/fabric-chart/index.d.ts +23 -4
  76. package/es/components/fabric-chart/src/FabricChart.vue.d.ts +23 -4
  77. package/es/components/fabric-chart/src/FabricChart.vue2.js +1 -1
  78. package/es/components/fabric-chart/src/components/PopupMenu.js +1 -1
  79. package/es/components/fabric-chart/src/components/PopupTip.vue.d.ts +13 -0
  80. package/es/components/fabric-chart/src/components/PopupTip.vue2.js +1 -1
  81. package/es/components/fabric-chart/src/components/useStyle.js +1 -1
  82. package/es/components/fabric-chart/src/constants/index.d.ts +1 -1
  83. package/es/components/fabric-chart/src/constants/index.js +1 -1
  84. package/es/components/fabric-chart/src/hooks/birthProcess/useBirthProcess.js +1 -1
  85. package/es/components/fabric-chart/src/hooks/birthProcess/useBirthProcessChart.d.ts +1 -0
  86. package/es/components/fabric-chart/src/hooks/birthProcess/useBirthProcessChart.js +1 -1
  87. package/es/components/fabric-chart/src/hooks/electrocardiogram/hooks/useDetailEvent.js +1 -1
  88. package/es/components/fabric-chart/src/hooks/electrocardiogram/useElectrocardiogram.js +1 -1
  89. package/es/components/fabric-chart/src/hooks/electrocardiogram/useElectrocardiogramChart.d.ts +1 -0
  90. package/es/components/fabric-chart/src/hooks/electrocardiogram/useElectrocardiogramChart.js +1 -1
  91. package/es/components/fabric-chart/src/hooks/electrocardiogram/useMeasureInstrument.js +1 -1
  92. package/es/components/fabric-chart/src/hooks/newBirthProcess/useNewBirthProcess.js +1 -1
  93. package/es/components/fabric-chart/src/hooks/newBirthProcess/useNewBirthProcessChart.js +1 -1
  94. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useCenter.d.ts +1 -1
  95. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useCenter.js +1 -1
  96. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useLeft.js +1 -1
  97. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useOther.js +1 -1
  98. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useSurgicalAnesthesiaChart.d.ts +1 -0
  99. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useSurgicalAnesthesiaChart.js +1 -1
  100. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useTop.d.ts +7 -1
  101. package/es/components/fabric-chart/src/hooks/surgicalAnesthesia/useTop.js +1 -1
  102. package/es/components/fabric-chart/src/hooks/temperature/useBottom.js +1 -1
  103. package/es/components/fabric-chart/src/hooks/temperature/useCenter.js +1 -1
  104. package/es/components/fabric-chart/src/hooks/temperature/useLeft.js +1 -1
  105. package/es/components/fabric-chart/src/hooks/temperature/useOther.js +1 -1
  106. package/es/components/fabric-chart/src/hooks/temperature/useTemperatureChart.d.ts +1 -0
  107. package/es/components/fabric-chart/src/hooks/temperature/useTemperatureChart.js +1 -1
  108. package/es/components/fabric-chart/src/hooks/temperature/useTop.js +1 -1
  109. package/es/components/fabric-chart/src/hooks/useCommon.js +1 -1
  110. package/es/components/fabric-chart/src/interface.d.ts +3 -0
  111. package/es/components/fabric-chart/src/utils/index.d.ts +1 -1
  112. package/es/components/fabric-chart/src/utils/index.js +1 -1
  113. package/es/components/field-set/src/FieldColor.vue.d.ts +4 -4
  114. package/es/components/field-set/src/FieldColor.vue2.js +1 -1
  115. package/es/components/field-set/src/FieldFilter.vue.d.ts +6 -5
  116. package/es/components/field-set/src/FieldFilter.vue2.js +1 -1
  117. package/es/components/field-set/src/FieldSet.vue.d.ts +3 -3
  118. package/es/components/field-set/src/FieldSet.vue2.js +1 -1
  119. package/es/components/field-set/src/Index.vue2.js +1 -1
  120. package/es/components/field-set/src/TableStyle.vue2.js +1 -1
  121. package/es/components/field-set/src/components/condition.vue2.js +1 -1
  122. package/es/components/field-set/src/components/edit-dialog.vue.d.ts +1 -1
  123. package/es/components/field-set/src/components/edit-dialog.vue2.js +1 -1
  124. package/es/components/field-set/src/components/edit-filter.vue2.js +1 -1
  125. package/es/components/field-set/src/components/table-row.vue.d.ts +3 -3
  126. package/es/components/field-set/src/components/table-row.vue2.js +1 -1
  127. package/es/components/field-set/src/constants/filter.d.ts +21 -12
  128. package/es/components/field-set/src/constants/filter.js +1 -1
  129. package/es/components/field-set/src/constants/index.js +1 -1
  130. package/es/components/field-set/src/types/index.d.ts +1 -1
  131. package/es/components/form-config/index.d.ts +108 -3
  132. package/es/components/form-config/src/FormConfig.vue.d.ts +108 -3
  133. package/es/components/form-config/src/FormConfig.vue2.js +1 -1
  134. package/es/components/form-config/src/components/FormConfigEventSetting.vue.js +1 -0
  135. package/es/components/form-config/src/components/FormConfigEventSetting.vue2.js +1 -0
  136. package/es/components/form-config/src/constants/index.js +1 -1
  137. package/es/components/form-config/src/hooks/useLocale.js +1 -1
  138. package/es/components/form-render/index.js +1 -1
  139. package/es/components/form-render/src/components/renderer/combination/hooks/useCombination.js +1 -1
  140. package/es/components/form-render/src/components/renderer/combination/jsonCombination.js +1 -1
  141. package/es/components/form-render/src/components/renderer/combination/tableCombination.js +1 -1
  142. package/es/components/form-render/src/components/renderer/radio_checkbox.js +1 -1
  143. package/es/components/form-render/src/components/renderer/remoteSearch.js +1 -1
  144. package/es/components/form-render/src/components/renderer/switch.js +1 -1
  145. package/es/components/form-render/src/hooks/useComplexOptions.js +1 -1
  146. package/es/components/form-render/src/hooks/useFieldListAdaptor.js +1 -1
  147. package/es/components/form-render/src/hooks/useFormEvent.js +1 -1
  148. package/es/components/form-render/src/hooks/usePresetScope.d.ts +1 -1
  149. package/es/components/form-render/src/hooks/usePresetScope.js +1 -1
  150. package/es/components/form-render/src/utils/index.d.ts +1 -0
  151. package/es/components/form-render/src/utils/index.js +1 -1
  152. package/es/components/iho-chat/index.d.ts +635 -54
  153. package/es/components/iho-chat/src/Index.vue.d.ts +638 -61
  154. package/es/components/iho-chat/src/Index.vue2.js +1 -1
  155. package/es/components/iho-chat/src/api/index.d.ts +1 -0
  156. package/es/components/iho-chat/src/api/index.js +1 -1
  157. package/es/components/iho-chat/src/components/ChatAdd.vue.d.ts +32 -1
  158. package/es/components/iho-chat/src/components/ChatAdd.vue2.js +1 -1
  159. package/es/components/iho-chat/src/components/ChatFile.vue.d.ts +52 -3
  160. package/es/components/iho-chat/src/components/ChatFile.vue2.js +1 -1
  161. package/es/components/iho-chat/src/components/ChatFooter.vue.d.ts +52 -2
  162. package/es/components/iho-chat/src/components/ChatFooter.vue2.js +1 -1
  163. package/es/components/iho-chat/src/components/ChatHeader.vue.d.ts +221 -11
  164. package/es/components/iho-chat/src/components/ChatHeader.vue2.js +1 -1
  165. package/es/components/iho-chat/src/components/ChatMain.vue.d.ts +82 -6
  166. package/es/components/iho-chat/src/components/ChatMain.vue2.js +1 -1
  167. package/es/components/iho-chat/src/components/ChatRecord.vue.d.ts +19 -1
  168. package/es/components/iho-chat/src/components/ChatRecord.vue2.js +1 -1
  169. package/es/components/iho-chat/src/components/ChatSearch.vue.d.ts +49 -10
  170. package/es/components/iho-chat/src/components/ChatSearch.vue2.js +1 -1
  171. package/es/components/iho-chat/src/components/ChatSet.vue.d.ts +71 -4
  172. package/es/components/iho-chat/src/components/ChatSet.vue2.js +1 -1
  173. package/es/components/iho-chat/src/components/ContextMenu.d.ts +11 -2
  174. package/es/components/iho-chat/src/components/ContextMenu.js +1 -1
  175. package/es/components/iho-chat/src/components/MessageTemplate.vue.d.ts +1 -1
  176. package/es/components/iho-chat/src/components/MessageTemplate.vue2.js +1 -1
  177. package/es/components/iho-chat/src/components/MultipleVideo.vue.d.ts +51 -2
  178. package/es/components/iho-chat/src/components/MultipleVideo.vue2.js +1 -1
  179. package/es/components/iho-chat/src/components/PersonProfile.vue.d.ts +19 -1
  180. package/es/components/iho-chat/src/components/PersonProfile.vue2.js +1 -1
  181. package/es/components/iho-chat/src/components/SiderList.vue.d.ts +69 -1
  182. package/es/components/iho-chat/src/components/SiderList.vue2.js +1 -1
  183. package/es/components/iho-chat/src/components/Video.vue.d.ts +19 -1
  184. package/es/components/iho-chat/src/components/Video.vue2.js +1 -1
  185. package/es/components/iho-chat/src/constants/index.d.ts +12 -3
  186. package/es/components/iho-chat/src/constants/index.js +1 -1
  187. package/es/components/iho-chat/src/hooks/index.d.ts +2 -2
  188. package/es/components/iho-chat/src/hooks/index.js +1 -1
  189. package/es/components/iho-chat/src/hooks/useData.d.ts +94 -0
  190. package/es/components/iho-chat/src/hooks/useData.js +1 -0
  191. package/es/components/iho-chat/src/hooks/useSearchUserList.js +1 -1
  192. package/es/components/iho-chat/src/hooks/useVideo.d.ts +19 -1
  193. package/es/components/iho-chat/src/hooks/useVideo.js +1 -1
  194. package/es/components/iho-chat/src/hooks/useWebSocket.d.ts +3 -0
  195. package/es/components/iho-chat/src/hooks/useWebSocket.js +1 -0
  196. package/es/components/iho-chat/src/types/index.d.ts +0 -6
  197. package/es/components/iho-chat/src/types/index.js +1 -1
  198. package/es/components/iho-chat/src/utils/chatSock.js +1 -1
  199. package/es/components/iho-chat/src/utils/index.d.ts +2 -0
  200. package/es/components/iho-chat/src/utils/index.js +1 -1
  201. package/es/components/iho-chat/style/index.css +1 -1
  202. package/es/components/iho-table/src/hooks/useColumnConfigAdaptor.js +1 -1
  203. package/es/components/iho-table/src/plugins/dynamicFilterRenderPlugin/dynamicFilter.vue2.js +1 -1
  204. package/es/components/iho-table/src/plugins/filterRenderPlugin/filter.vue2.js +1 -1
  205. package/es/components/iho-table/src/plugins/filterRenderPlugin/index.js +1 -1
  206. package/es/components/iho-table/src/plugins/filterTextPlugin/filter.vue2.js +1 -1
  207. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/numberRendererPlugin.js +1 -1
  208. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/selectRendererPlugin/editSelect.js +1 -1
  209. package/es/components/iho-table/src/plugins/rendererPlugins/editableWidgets/timeRendererPlugin/editTime.vue2.js +1 -1
  210. package/es/components/iho-table/src/utils/index.js +1 -1
  211. package/es/components/index.css +1 -1
  212. package/es/components/index.d.ts +2 -1
  213. package/es/components/index.js +1 -1
  214. package/es/components/info-header/src/components/patientInfo/index.vue2.js +1 -1
  215. package/es/components/keyboard/src/Keyboard.vue2.js +1 -1
  216. package/es/components/keyboard/src/components/NumberPanel.vue2.js +1 -1
  217. package/es/components/map/src/Map.vue2.js +1 -1
  218. package/es/components/picture-clipper/src/PictureClipper.vue2.js +1 -1
  219. package/es/components/quick-search/index.d.ts +3 -1
  220. package/es/components/quick-search/src/index.vue.d.ts +3 -1
  221. package/es/components/quick-search/src/index.vue2.js +1 -1
  222. package/es/components/quick-search/style/index.css +1 -1
  223. package/es/components/recommend-search/src/components/BaseSearch.js +1 -1
  224. package/es/components/recommend-search/src/components/RecommendInput.vue2.js +1 -1
  225. package/es/components/recommend-search/src/components/RecommendSelect.vue2.js +1 -1
  226. package/es/components/scale-view/index.d.ts +31 -0
  227. package/es/components/scale-view/src/ScaleView.vue.d.ts +13 -0
  228. package/es/components/scale-view/src/ScaleView.vue2.js +1 -1
  229. package/es/components/scale-view/src/components/NoData.vue2.js +1 -1
  230. package/es/components/scale-view/src/components/composables/choose-common.js +1 -1
  231. package/es/components/scale-view/src/components/formitem/r-cascader.js +1 -1
  232. package/es/components/scale-view/src/components/formitem/r-checkbox.d.ts +9 -0
  233. package/es/components/scale-view/src/components/formitem/r-checkbox.js +1 -1
  234. package/es/components/scale-view/src/components/formitem/r-input.d.ts +9 -0
  235. package/es/components/scale-view/src/components/formitem/r-input.js +1 -1
  236. package/es/components/scale-view/src/components/formitem/r-map.js +1 -1
  237. package/es/components/scale-view/src/components/formitem/r-radio.d.ts +9 -0
  238. package/es/components/scale-view/src/components/formitem/r-radio.js +1 -1
  239. package/es/components/scale-view/src/components/formitem/r-select.js +1 -1
  240. package/es/components/scale-view/src/components/formitem/r-sign.js +1 -1
  241. package/es/components/scale-view/src/components/formitem/standard-modal.js +1 -1
  242. package/es/components/scale-view/src/hooks/scaleview-computed.js +1 -1
  243. package/es/components/scale-view/src/hooks/scaleview-methods.js +1 -1
  244. package/es/components/scale-view/src/hooks/scaleview-props.d.ts +4 -0
  245. package/es/components/scale-view/src/hooks/scaleview-props.js +1 -1
  246. package/es/components/scale-view/src/hooks/scaleview-submit.js +1 -1
  247. package/es/components/scale-view/src/hooks/scaleview-validate.js +1 -1
  248. package/es/components/scale-view/src/hooks/use-component.d.ts +72 -0
  249. package/es/components/scale-view/style/index.css +1 -1
  250. package/es/components/search-cascader/src/SearchCascader.vue2.js +1 -1
  251. package/es/components/select-label/src/LabelFormContent.vue2.js +1 -1
  252. package/es/components/select-label/src/SelectLabel.vue2.js +1 -1
  253. package/es/components/select-label/src/components/label-classify.vue2.js +1 -1
  254. package/es/components/select-label/src/ihoLabel/IhoLabelFormContent.vue2.js +1 -1
  255. package/es/components/select-label/src/ihoLabel/IhoSelectLabel.vue2.js +1 -1
  256. package/es/components/select-label/src/ihoLabel/iho-label-classify.vue2.js +1 -1
  257. package/es/components/select-person/src/SelectPerson.vue2.js +1 -1
  258. package/es/components/select-person/src/SelectPersonType.vue2.js +1 -1
  259. package/es/components/select-person/src/components/SearchOrgAndStaff.vue2.js +1 -1
  260. package/es/components/select-person/src/index.vue2.js +1 -1
  261. package/es/components/slider-tree/src/index.vue2.js +1 -1
  262. package/es/components/table-export-field/src/components/ExportModal.vue2.js +1 -1
  263. package/es/components/table-export-field/src/components/SaveProjectModal.vue2.js +1 -1
  264. package/es/components/table-export-field/src/index.vue2.js +1 -1
  265. package/es/components/table-filter/src/components/bi-filter/ValueCfg.vue2.js +1 -1
  266. package/es/components/table-filter/src/components/bi-filter/helpers/options.js +1 -1
  267. package/es/components/table-filter/src/components/bi-filter/index.vue2.js +1 -1
  268. package/es/components/table-filter/src/components/classify-filter/ValueCfg.vue2.js +1 -1
  269. package/es/components/table-filter/src/components/classify-filter/components/Date.vue2.js +1 -1
  270. package/es/components/table-filter/src/components/classify-filter/components/DateRange.vue2.js +1 -1
  271. package/es/components/table-filter/src/components/classify-filter/components/InputFilter.vue2.js +1 -1
  272. package/es/components/table-filter/src/components/classify-filter/components/InputNumberGroup.vue2.js +1 -1
  273. package/es/components/table-filter/src/components/classify-filter/helpers/options.js +1 -1
  274. package/es/components/table-filter/src/components/classify-filter/hooks/useDisplayCategory.js +1 -1
  275. package/es/components/table-filter/src/components/classify-filter/index.vue2.js +1 -1
  276. package/es/components/table-filter/src/components/render-widget/components/DateInner.vue2.js +1 -1
  277. package/es/components/table-filter/src/components/render-widget/components/DateOut.vue2.js +1 -1
  278. package/es/components/table-filter/src/components/render-widget/components/DateRangeInner.vue2.js +1 -1
  279. package/es/components/table-filter/src/components/render-widget/components/DateRangeOut.vue2.js +1 -1
  280. package/es/components/table-filter/src/components/render-widget/components/InputCustom.vue2.js +1 -1
  281. package/es/components/table-filter/src/components/render-widget/components/InputNumberGroup.vue2.js +1 -1
  282. package/es/components/table-filter/src/components/render-widget/components/LabelInner.vue2.js +1 -1
  283. package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue.d.ts +4 -7
  284. package/es/components/table-filter/src/components/render-widget/components/SelectDynamic.vue2.js +1 -1
  285. package/es/components/table-filter/src/components/render-widget/components/SelectDynamicOption/index.vue2.js +1 -1
  286. package/es/components/table-filter/src/components/render-widget/components/index.d.ts +4 -7
  287. package/es/components/table-filter/src/components/render-widget/helpers/dateExtraMap.js +1 -1
  288. package/es/components/table-filter/src/components/render-widget/helpers/selectExtraMap.js +1 -1
  289. package/es/components/table-filter/src/components/render-widget/index.vue.d.ts +3 -1
  290. package/es/components/table-filter/src/components/render-widget/index.vue.js +1 -1
  291. package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.d.ts +4 -7
  292. package/es/components/table-filter/src/components/render-widget/widgetCfgMaps.js +1 -1
  293. package/es/components/table-filter/src/tool/baseOptions.js +1 -1
  294. package/es/components/template-render/src/components/index.d.ts +23 -23
  295. package/es/components/tooth-bitmap/src/ToothBitmap.vue2.js +1 -1
  296. package/es/components/vod-chunk-upload/src/hooks/upload-computed.js +1 -1
  297. package/es/components/vod-chunk-upload/src/vod-chunk-upload/vod-chunk-upload.vue2.js +1 -1
  298. package/es/components/vod-chunk-upload/src/vod-upload-modal.js +1 -1
  299. package/es/env.d.ts +25 -25
  300. package/es/shared/assets/img/ai__avatar.png.js +1 -1
  301. package/es/shared/assets/img/defaultCover/10review_successful.png.js +1 -1
  302. package/es/shared/assets/img/defaultCover/11review_fail.png.js +1 -1
  303. package/es/shared/assets/img/defaultCover/12no_setting.png.js +1 -1
  304. package/es/shared/assets/img/defaultCover/13no_menu_setting.png.js +1 -1
  305. package/es/shared/assets/img/defaultCover/14no_call_setting.png.js +1 -1
  306. package/es/shared/assets/img/defaultCover/15no_use_tag.png.js +1 -1
  307. package/es/shared/assets/img/defaultCover/16no_table_data.png.js +1 -1
  308. package/es/shared/assets/img/defaultCover/1location.png.js +1 -1
  309. package/es/shared/assets/img/defaultCover/2notfound.png.js +1 -1
  310. package/es/shared/assets/img/defaultCover/3loading.png.js +1 -1
  311. package/es/shared/assets/img/defaultCover/4no_permission.png.js +1 -1
  312. package/es/shared/assets/img/defaultCover/5no_data.png.js +1 -1
  313. package/es/shared/assets/img/defaultCover/6no_network.png.js +1 -1
  314. package/es/shared/assets/img/defaultCover/7no_doctor.png.js +1 -1
  315. package/es/shared/assets/img/defaultCover/8system_error.png.js +1 -1
  316. package/es/shared/assets/img/defaultCover/9system_upgrade.png.js +1 -1
  317. package/es/shared/assets/img/failure.png.js +1 -1
  318. package/es/shared/assets/img/logo.png.js +1 -1
  319. package/es/shared/assets/img/no-permission.png.js +1 -1
  320. package/es/shared/assets/img/nodata.png.js +1 -1
  321. package/es/shared/assets/img/notfound.png.js +1 -1
  322. package/es/shared/assets/img/qr.png.js +1 -1
  323. package/es/shared/assets/img/success.png.js +1 -1
  324. package/es/shared/assets/img/table_style_2.png.js +1 -1
  325. package/es/shared/assets/img/video.png.js +1 -1
  326. package/es/shared/assets/img/video_default_cover.png.js +1 -1
  327. package/es/shared/assets/img/xb_big.png.js +1 -1
  328. package/es/shared/assets/img/xb_small.png.js +1 -1
  329. package/es/shared/components/VueDraggable/src/vuedraggable.d.ts +86 -0
  330. package/es/shared/package.json.js +1 -1
  331. package/es/shared/utils/fabricjs/index.d.ts +6823 -0
  332. package/es/shared/utils/tapable/index.d.ts +139 -0
  333. package/package.json +2 -2
  334. package/es/components/iho-chat/src/hooks/useSession.d.ts +0 -12
  335. package/es/components/iho-chat/src/hooks/useSession.js +0 -1
  336. package/es/components/iho-chat/src/hooks/useState.d.ts +0 -18
  337. package/es/components/iho-chat/src/hooks/useState.js +0 -1
@@ -107,6 +107,10 @@ declare const _default: import("vue").DefineComponent<{
107
107
  type: BooleanConstructor;
108
108
  default: boolean;
109
109
  };
110
+ isGeneratePrintPdf: {
111
+ type: BooleanConstructor;
112
+ default: boolean;
113
+ };
110
114
  }, {
111
115
  ScaleViewState: {
112
116
  other: string;
@@ -250,6 +254,10 @@ declare const _default: import("vue").DefineComponent<{
250
254
  type: BooleanConstructor;
251
255
  default: boolean;
252
256
  };
257
+ isGeneratePrintPdf: {
258
+ type: BooleanConstructor;
259
+ default: boolean;
260
+ };
253
261
  }>> & {
254
262
  onOnCloseSetting?: ((...args: any[]) => any) | undefined;
255
263
  onSubmitNoRequest?: ((...args: any[]) => any) | undefined;
@@ -864,6 +872,10 @@ declare const _default: import("vue").DefineComponent<{
864
872
  type: BooleanConstructor;
865
873
  default: boolean;
866
874
  };
875
+ isGeneratePrintPdf: {
876
+ type: BooleanConstructor;
877
+ default: boolean;
878
+ };
867
879
  }>> & {
868
880
  onOnCloseSetting?: ((...args: any[]) => any) | undefined;
869
881
  onSubmitNoRequest?: ((...args: any[]) => any) | undefined;
@@ -894,5 +906,6 @@ declare const _default: import("vue").DefineComponent<{
894
906
  fontSizeObj: Record<string, any>;
895
907
  hasExtendBtn: boolean;
896
908
  printingHideBtn: boolean;
909
+ isGeneratePrintPdf: boolean;
897
910
  }>;
898
911
  export default _default;
@@ -1 +1 @@
1
- import{defineComponent as e,reactive as o,ref as t,watch as a,nextTick as n,openBlock as s,createElementBlock as i,normalizeClass as l,unref as r,createCommentVNode as m,Fragment as c,createBlock as u,mergeProps as d,createElementVNode as p,normalizeStyle as f,createVNode as v,withCtx as g,renderList as h,toDisplayString as k,createTextVNode as y,resolveDynamicComponent as w,renderSlot as S}from"vue";import b from"./hooks/use-noData.js";import{ScaleViewProps as C}from"./hooks/scaleview-props.js";import{getScaleViewState as D}from"./hooks/scaleview-state.js";import{ScaleViewComputed as E}from"./hooks/scaleview-computed.js";import{ScaleViewInit as j}from"./hooks/scaleview-init.js";import{ScaleViewSubmit as _}from"./hooks/scaleview-submit.js";import{ScaleViewMethods as x}from"./hooks/scaleview-methods.js";import{handleQueryParams as F,isCollection as P}from"./utils/judge-types.js";import{useEvent as q}from"./hooks/use-event.js";import"xe-utils";import"moment";import L from"../../../shared/utils/vexutilsExpand.js";import N from"./components/NoData.vue.js";import R from"./components/EvaluateCountdown.vue.js";import A from"./components/EvaluatePage.vue.js";import M from"./components/AnswerParse.vue.js";import O from"./components/ScaleScore.js";import T from"./components/DescribeContent.vue.js";import{NForm as V,NFormItem as I,NButton as B}from"naive-ui";const J=["innerHTML"],G={key:0,class:"required-text"},W={key:1,class:"evalute-label"},H=["onClick"],Q=p("i",{class:"scale-view-iconfont icon-scale-view-dengpao"},null,-1),$={key:1,class:"footer"};var z=e({__name:"ScaleView",props:C,emits:["onCloseSetting","submitNoRequest","onSubmit","startWriteScale"],setup(e,{expose:C,emit:z}){const K=e,{ScaleViewState:U}=D(),X=o(U),Y=t(null),Z=t(null),ee=t(null),{noDataState:oe,setNoData:te,resetNodata:ae}=b(),ne=F(),{showEvatip:se,isFormBoldOpen:ie,scaleStyle:le,handlePageClass:re,isShowItem:me,handleShowQuestionNumber:ce,hasScore:ue,isPreviewScale:de,showEvaluateEntry:pe,showEvaluateCoundownPage:fe,showScaleFooter:ve,isCancelBtn:ge,isSaveBtn:he,showEvaluateLabel:ke,showAnswerParse:ye,propsConfig:we,evaluatePageProps:Se,evaluateCountdownProps:be,isEvaluetaResSituation:Ce,disableEdit:De,desStart:Ee,desEnd:je,desContent:_e}=E(K,X,{query:ne,scaleViewDom:Y}),{initForm:xe}=j(K,X,z,{query:ne}),{submitMethod:Fe,onSubmitData:Pe,onSubmitForm:qe,handleScoreJson:Le}=_(K,X,z,{query:ne,formRef:ee,countdownDom:Z}),{nextLogicEvent:Ne,handleDynamicDataRelation:Re}=q(K,X),{scaleChange:Ae,labelChange:Me,vodFileList:Oe,writeGuage:Te,closeEvaluateCountdown:Ve,showEvaTipModal:Ie}=x(K,X,z,{nextLogicEvent:Ne,handleDynamicDataRelation:Re,isPreviewScale:de,submitMethod:Fe,isEvaluetaResSituation:Ce,handleScoreJson:Le,disableEdit:De});(()=>{let{id:e}=ne;e&&(X.shareId=e)})();const Be=e=>{try{ae(),xe(e)}catch(e){console.log(e,"--error"),X.spinning=!1,X.hasFrontAddress=!1,te(!0,null==e?void 0:e.resultMsg,null==e?void 0:e.result)}};a((()=>K.ids),((e,o)=>{o?e.guage_id&&e.guage_id!=o.guage_id&&Be(e):e.guage_id&&Be(e)}),{immediate:!0}),a((()=>K.guageData),(e=>{if(!e||!Object.keys(e||{}).length)return;X.form={},X.formArray=[];const o=JSON.parse(JSON.stringify(e));n((()=>{xe(o)}))}),{immediate:!0});const Je=L.debounce(Pe,300),Ge=()=>{z("onCloseSetting")};return C({getScaleData:()=>({...X}),onSubmitForm:qe,cancel:Ge}),(e,o)=>(s(),i("div",{class:l(["c-scale-view-block",{"c-scale-view-block-hasfooter":r(ve)}]),ref_key:"scaleViewDom",ref:Y},[m(' <template v-if="state.spinning">\r\n <n-spin :show="state.spinning" description="加载中"></n-spin>\r\n </template> '),X.spinning||X.hasFrontAddress?m("v-if",!0):(s(),i(c,{key:0},[r(oe).noData?(s(),u(N,{key:0,noDataImg:r(oe).noDataImg,noDataTip:r(oe).noDataTip},null,8,["noDataImg","noDataTip"])):(s(),i(c,{key:1},[r(pe)?(s(),u(A,d({key:0},r(Se),{onWriteGuage:r(Te)}),null,16,["onWriteGuage"])):(s(),i(c,{key:1},[r(fe)?(s(),u(R,d({key:0,ref_key:"countdownDom",ref:Z},r(be),{onCloseEvaluateCountdown:r(Ve)}),null,16,["onCloseEvaluateCountdown"])):m("v-if",!0),p("div",{class:l(["scale-container",{"scale-container-nopadding":r(re),"scale-container-hasfooter":r(ve)}]),style:f(r(le))},[r(ue)?(s(),u(r(O),{key:0,config:X.config,maxScore:X.maxScore},null,8,["config","maxScore"])):m("v-if",!0),r(Ee)?(s(),u(T,{key:1,content:r(_e)},null,8,["content"])):m("v-if",!0),v(r(V),{ref_key:"formRef",ref:ee,model:X.form,rules:X.rules,"require-mark-placement":"left",class:"main"},{default:g((()=>[(s(!0),i(c,null,h(X.formArray,((e,o)=>(s(),i(c,{key:(e.id||e.seq)+o},[r(me)(e)?(s(),u(r(I),{key:0,path:e.val_key,"show-label":!r(P)(e.type),class:"c-scle-form-item"},{label:g((()=>[p("span",{class:l({"scale-label-required":r(ie)(e)}),innerHTML:r(ce)(e)},null,10,J),r(ie)(e)?(s(),i("span",G,"(必填)")):m("v-if",!0),r(ke)(e)?(s(),i("span",W,k(r(ke)(e)),1)):m("v-if",!0),r(se)(e)?(s(),i("span",{key:2,class:"evalute-tip",onClick:o=>r(Ie)(e)},[Q,y(" 查看提示 ")],8,H)):m("v-if",!0)])),default:g((()=>[(s(),u(w(e.renderCom),d(r(we)(e,o),{key:(e.id||e.seq)+o,onScaleChange:r(Ae),onOnChange:o=>r(Me)(o,e),onVodFileList:r(Oe)}),null,16,["onScaleChange","onOnChange","onVodFileList"])),r(ye)(e)?(s(),u(M,{key:0,item:e},null,8,["item"])):m("v-if",!0)])),_:2},1032,["path","show-label"])):m("v-if",!0)],64)))),128))])),_:1},8,["model","rules"]),r(je)?(s(),u(T,{key:2,content:r(_e)},null,8,["content"])):m("v-if",!0)],6),r(ve)?(s(),i("div",$,[m(" 分享的链接 隐藏取消按钮 "),r(ge)?(s(),u(r(B),{key:0,onClick:Ge},{default:g((()=>[y("取消")])),_:1})):m("v-if",!0),r(he)?(s(),u(r(B),{key:1,onClick:r(Je),disabled:X.banSubmit,type:"primary"},{default:g((()=>[y(" 保存 ")])),_:1},8,["onClick","disabled"])):m("v-if",!0),S(e.$slots,"extendBtn")])):m("v-if",!0)],64))],64))],64))],2))}});export{z as default};
1
+ import{defineComponent as e,reactive as o,ref as a,watch as t,nextTick as n,openBlock as s,createElementBlock as i,normalizeClass as l,unref as r,createCommentVNode as m,Fragment as u,createBlock as c,mergeProps as d,createElementVNode as p,normalizeStyle as v,createVNode as f,withCtx as g,renderList as w,toDisplayString as h,createTextVNode as y,resolveDynamicComponent as k,renderSlot as S}from"vue";import C from"./hooks/use-noData.js";import{ScaleViewProps as b}from"./hooks/scaleview-props.js";import{getScaleViewState as D}from"./hooks/scaleview-state.js";import{ScaleViewComputed as E}from"./hooks/scaleview-computed.js";import{ScaleViewInit as j}from"./hooks/scaleview-init.js";import{ScaleViewSubmit as _}from"./hooks/scaleview-submit.js";import{ScaleViewMethods as x}from"./hooks/scaleview-methods.js";import{handleQueryParams as F,isCollection as L}from"./utils/judge-types.js";import{useEvent as P}from"./hooks/use-event.js";import"xe-utils";import"moment";import q from"../../../shared/utils/vexutilsExpand.js";import N from"./components/NoData.vue.js";import R from"./components/EvaluateCountdown.vue.js";import A from"./components/EvaluatePage.vue.js";import B from"./components/AnswerParse.vue.js";import M from"./components/ScaleScore.js";import O from"./components/DescribeContent.vue.js";import{NForm as T,NFormItem as V,NButton as I}from"naive-ui";const J=["innerHTML"],G={key:0,class:"required-text"},W={key:1,class:"evalute-label"},H=["onClick"],Q=p("i",{class:"scale-view-iconfont icon-scale-view-dengpao"},null,-1),$={key:1,class:"footer"};var z=e({__name:"ScaleView",props:b,emits:["onCloseSetting","submitNoRequest","onSubmit","startWriteScale"],setup(e,{expose:b,emit:z}){const K=e,{ScaleViewState:U}=D(),X=o(U),Y=a(null),Z=a(null),ee=a(null),{noDataState:oe,setNoData:ae,resetNodata:te}=C(),ne=F(),{showEvatip:se,isFormBoldOpen:ie,scaleStyle:le,handlePageClass:re,isShowItem:me,handleShowQuestionNumber:ue,hasScore:ce,isPreviewScale:de,showEvaluateEntry:pe,showEvaluateCoundownPage:ve,showScaleFooter:fe,isCancelBtn:ge,isSaveBtn:we,showEvaluateLabel:he,showAnswerParse:ye,propsConfig:ke,evaluatePageProps:Se,evaluateCountdownProps:Ce,isEvaluetaResSituation:be,disableEdit:De,desStart:Ee,desEnd:je,desContent:_e}=E(K,X,{query:ne,scaleViewDom:Y}),{initForm:xe}=j(K,X,z,{query:ne}),{submitMethod:Fe,onSubmitData:Le,onSubmitForm:Pe,handleScoreJson:qe}=_(K,X,z,{query:ne,formRef:ee,countdownDom:Z}),{nextLogicEvent:Ne,handleDynamicDataRelation:Re}=P(K,X),{scaleChange:Ae,labelChange:Be,vodFileList:Me,writeGuage:Oe,closeEvaluateCountdown:Te,showEvaTipModal:Ve}=x(K,X,z,{nextLogicEvent:Ne,handleDynamicDataRelation:Re,isPreviewScale:de,submitMethod:Fe,isEvaluetaResSituation:be,handleScoreJson:qe,disableEdit:De});(()=>{let{id:e}=ne;e&&(X.shareId=e)})();const Ie=e=>{try{te(),xe(e)}catch(e){console.log(e,"--error"),X.spinning=!1,X.hasFrontAddress=!1,ae(!0,null==e?void 0:e.resultMsg,null==e?void 0:e.result)}};t((()=>K.ids),((e,o)=>{o?e.guage_id&&e.guage_id!=o.guage_id&&Ie(e):e.guage_id&&Ie(e)}),{immediate:!0}),t((()=>K.guageData),(e=>{if(!e||!Object.keys(e||{}).length)return;X.form={},X.formArray=[];const o=JSON.parse(JSON.stringify(e));n((()=>{xe(o)}))}),{immediate:!0});const Je=q.debounce(Le,300),Ge=()=>{z("onCloseSetting")};return b({getScaleData:()=>({...X}),onSubmitForm:Pe,cancel:Ge}),(e,o)=>(s(),i("div",{class:l(["c-scale-view-block",{"c-scale-view-block-hasfooter":r(fe)}]),ref_key:"scaleViewDom",ref:Y},[m(' <template v-if="state.spinning">\n <n-spin :show="state.spinning" description="加载中"></n-spin>\n </template> '),X.spinning||X.hasFrontAddress?m("v-if",!0):(s(),i(u,{key:0},[r(oe).noData?(s(),c(N,{key:0,noDataImg:r(oe).noDataImg,noDataTip:r(oe).noDataTip},null,8,["noDataImg","noDataTip"])):(s(),i(u,{key:1},[r(pe)?(s(),c(A,d({key:0},r(Se),{onWriteGuage:r(Oe)}),null,16,["onWriteGuage"])):(s(),i(u,{key:1},[r(ve)?(s(),c(R,d({key:0,ref_key:"countdownDom",ref:Z},r(Ce),{onCloseEvaluateCountdown:r(Te)}),null,16,["onCloseEvaluateCountdown"])):m("v-if",!0),p("div",{class:l(["scale-container",{"scale-container-nopadding":r(re),"scale-container-hasfooter":r(fe)}]),style:v(r(le))},[r(ce)?(s(),c(r(M),{key:0,config:X.config,maxScore:X.maxScore},null,8,["config","maxScore"])):m("v-if",!0),r(Ee)?(s(),c(O,{key:1,content:r(_e)},null,8,["content"])):m("v-if",!0),f(r(T),{ref_key:"formRef",ref:ee,model:X.form,rules:X.rules,"require-mark-placement":"left",class:"main"},{default:g((()=>[(s(!0),i(u,null,w(X.formArray,((e,o)=>(s(),i(u,{key:(e.id||e.seq)+o},[r(me)(e)?(s(),c(r(V),{key:0,path:e.val_key,"show-label":!r(L)(e.type),class:"c-scle-form-item"},{label:g((()=>[p("span",{class:l({"scale-label-required":r(ie)(e)}),innerHTML:r(ue)(e)},null,10,J),r(ie)(e)?(s(),i("span",G,"(必填)")):m("v-if",!0),r(he)(e)?(s(),i("span",W,h(r(he)(e)),1)):m("v-if",!0),r(se)(e)?(s(),i("span",{key:2,class:"evalute-tip",onClick:o=>r(Ve)(e)},[Q,y(" 查看提示 ")],8,H)):m("v-if",!0)])),default:g((()=>[(s(),c(k(e.renderCom),d(r(ke)(e,o),{key:(e.id||e.seq)+o,onScaleChange:r(Ae),onOnChange:o=>r(Be)(o,e),onVodFileList:r(Me)}),null,16,["onScaleChange","onOnChange","onVodFileList"])),r(ye)(e)?(s(),c(B,{key:0,item:e},null,8,["item"])):m("v-if",!0)])),_:2},1032,["path","show-label"])):m("v-if",!0)],64)))),128))])),_:1},8,["model","rules"]),r(je)?(s(),c(O,{key:2,content:r(_e)},null,8,["content"])):m("v-if",!0)],6),r(fe)?(s(),i("div",$,[m(" 分享的链接 隐藏取消按钮 "),r(ge)?(s(),c(r(I),{key:0,onClick:Ge},{default:g((()=>{var e;return[y((null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.32"))||"取消")]})),_:1})):m("v-if",!0),r(we)?(s(),c(r(I),{key:1,onClick:r(Je),disabled:X.banSubmit,type:"primary"},{default:g((()=>{var e;return[y((null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.244"))||"保存")]})),_:1},8,["onClick","disabled"])):m("v-if",!0),S(e.$slots,"extendBtn")])):m("v-if",!0)],64))],64))],64))],2))}});export{z as default};
@@ -1 +1 @@
1
- import{defineComponent as a,computed as s,openBlock as e,createElementBlock as t,unref as o,createCommentVNode as r,createElementVNode as n,toDisplayString as i}from"vue";import p from"../../../../shared/assets/img/nodata.png.js";import m from"../../../../shared/assets/img/no-permission.png.js";import l from"../../../../shared/assets/img/failure.png.js";import g from"../../../../shared/assets/img/notfound.png.js";const u={class:"no-data-tip NoData-page"},f=["src"],d={key:1};var c=a({__name:"NoData",props:{noDataTip:{type:String,default:"暂无数据"},noDataImg:{type:String,default:"nodata"},showImg:{type:Boolean,default:!0}},setup(a){const c=a,h=s((()=>{let a=null;switch(c.noDataImg){case"no-permission":a=m;break;case"failure":a=l;break;case"nodata":a=p;break;default:a=g}return a})),D=s((()=>{let a="";switch(c.noDataImg){case"no-permission":a="请联系管理员";break;case"failure":a="请稍后再试"}return a}));return(s,p)=>(e(),t("div",u,[a.showImg?(e(),t("img",{key:0,src:o(h),alt:""},null,8,f)):r("v-if",!0),n("p",null,i(a.noDataTip),1),o(D)?(e(),t("span",d,i(o(D)),1)):r("v-if",!0)]))}});export{c as default};
1
+ import{defineComponent as a,computed as e,openBlock as t,createElementBlock as o,unref as s,createCommentVNode as n,createElementVNode as r,toDisplayString as i}from"vue";import l from"../../../../shared/assets/img/nodata.png.js";import p from"../../../../shared/assets/img/no-permission.png.js";import m from"../../../../shared/assets/img/failure.png.js";import d from"../../../../shared/assets/img/notfound.png.js";var g;const u={class:"no-data-tip NoData-page"},f=["src"],c={key:1};var w=a({__name:"NoData",props:{noDataTip:{type:String,default:(null==(g=window.getLanguageByCode)?void 0:g.call(window,"10010.1.445"))||"暂无数据"},noDataImg:{type:String,default:"nodata"},showImg:{type:Boolean,default:!0}},setup(a){const g=a,w=e((()=>{let a=null;switch(g.noDataImg){case"no-permission":a=p;break;case"failure":a=m;break;case"nodata":a=l;break;default:a=d}return a})),v=e((()=>{var a;let e="";switch(g.noDataImg){case"no-permission":e="请联系管理员";break;case"failure":e=(null==(a=window.getLanguageByCode)?void 0:a.call(window,"10010.1.449"))||"请稍后再试"}return e}));return(e,l)=>(t(),o("div",u,[a.showImg?(t(),o("img",{key:0,src:s(w),alt:""},null,8,f)):n("v-if",!0),r("p",null,i(a.noDataTip),1),s(v)?(t(),o("span",c,i(s(v)),1)):n("v-if",!0)]))}});export{w as default};
@@ -1 +1 @@
1
- import{computed as e}from"vue";function i(i,f){return{choiceUseKey:e((()=>"RADIO_BLOCK"===i.item.type||"CHECKBOX_BLOCK"===i.item.type?"key":"value")),choiceColor:e((()=>e=>`${e.color||"rgba(0, 0, 0, 0.65)"}`)),showImgWrap:e((()=>e=>!e.prefix&&!e.suffix&&e.imageUrl)),isRadioItem:e((()=>"RADIO_BLOCK"===i.item.type)),isCheckboxItem:e((()=>"CHECKBOX_BLOCK"===i.item.type)),showPreSuffix:e((()=>e=>e.prefix||e.suffix)),handleDefPreSuffix:(e,i,t,r,o)=>{if(e.prefix||e.suffix){if(e.value===t)return!1;if(e.prefix&&0===t.indexOf(e.prefix)){const i=t.substring(e.prefix.length);return f.optionsPreSuffixObj[e.key]=i,e.key}if(e.suffix){const i=t.lastIndexOf(e.suffix);if(e.suffix.length,t.length===i+e.suffix.length){const i=t.lastIndexOf(e.suffix),r=t.substring(0,i);return f.optionsPreSuffixObj[e.key]=r,e.key}}}return t===e.value?e.key:r&&o?(f.othersText=t,"other"):void 0},handleOptions:e=>e.map(((e,i)=>e.prefix||e.suffix?(f.optionsPreSuffixObj[e.key]=void 0,e):e.label?e:null)).filter(Boolean)||[],stopClick:e=>{e.preventDefault(),e.stopPropagation()}}}export{i as default};
1
+ import{computed as e}from"vue";function i(i,f){return{choiceUseKey:e((()=>"RADIO_BLOCK"===i.item.type||"CHECKBOX_BLOCK"===i.item.type?"key":"value")),choiceColor:e((()=>e=>`${e.color||"rgba(0, 0, 0, 0.65)"}`)),showImgWrap:e((()=>e=>!e.prefix&&!e.suffix&&e.imageUrl)),isRadioItem:e((()=>"RADIO_BLOCK"===i.item.type)),isCheckboxItem:e((()=>"CHECKBOX_BLOCK"===i.item.type)),showPreSuffix:e((()=>e=>e.prefix||e.suffix)),handleDefPreSuffix:(e,i,t,r,o)=>{var n;if(e.prefix||e.suffix){if(e.value===t)return!1;if(e.prefix&&0===(null==(n=null==t?void 0:t.indexOf)?void 0:n.call(t,e.prefix))){const i=t.substring(e.prefix.length);return f.optionsPreSuffixObj[e.key]=i,e.key}if(e.suffix){const i=t.lastIndexOf(e.suffix);if(e.suffix.length,t.length===i+e.suffix.length){const i=t.lastIndexOf(e.suffix),r=t.substring(0,i);return f.optionsPreSuffixObj[e.key]=r,e.key}}}return t===e.value?e.key:r&&o?(f.othersText=t,"other"):void 0},handleOptions:e=>e.map(((e,i)=>e.prefix||e.suffix?(f.optionsPreSuffixObj[e.key]=void 0,e):e.label?e:null)).filter(Boolean)||[],stopClick:e=>{e.preventDefault(),e.stopPropagation()}}}export{i as default};
@@ -1 +1 @@
1
- import{defineComponent as e,reactive as t,createVNode as a,resolveComponent as n}from"vue";import{NCascader as r,NEmpty as l}from"naive-ui";import i from"../LoadingCom.vue.js";var c=e({name:"RCascader",components:{NCascader:r,NEmpty:l,LoadingCom:i},props:{form:{type:Object,default:()=>{}},item:{type:Object,default:()=>{}},isLock:{type:Boolean,default:!1},getCascadeOptions:{type:Function,default:()=>Promise.resolve([])}},emits:["scaleChange"],setup(e,r){let c=t({cascaderValue:void 0,curOptions:[],fetching:!1});const u=(e,t)=>{if(!e.length||!t||!t.length)return;let a=0,n=t.length;t[0];let r,l=e;for(;a<n;a++){let e=t[a];if(!l.length)return!1;if(r=l.find((t=>t.value===e)),0===a&&!r)return!1;if(a===n-1&&!r)return!1;if(a===n-1&&r)break;l=r.children||[]}r&&(c.cascaderValue=r.theUniqueKey)},o=(e,t)=>e.map(((e,a)=>{var n;e.curIndex=a+1;let r=e.level||0;return e.path=`${e.curIndex}`,r&&t&&(e.path=`${t.path}-${e.curIndex}`),e.theUniqueKey=e.path,e.hasOwnProperty("children")&&!e.children.length&&delete e.children,(null==(n=e.children)?void 0:n.length)&&o(e.children,e),e}));(async t=>{var a;if(!t||!Object.keys(t).length)return;let n=JSON.parse(JSON.stringify(t)),r=e.form[e.item.val_key],l=[];if(!(null==(a=n.targetSource)?void 0:a.target_id))return l=o(n.options||[]),c.curOptions=l,void u(l,r);try{c.fetching=!0,l=await e.getCascadeOptions(n),c.curOptions=l,u(l,r),c.fetching=!1}catch(e){c.fetching=!1}})(e.item);const s=(t,a,n)=>{let l=n.map((e=>e.value));c.cascaderValue=t,r.emit("scaleChange",l,e.item)};return()=>a(n("n-cascader"),{value:c.cascaderValue,"onUpdate:value":e=>c.cascaderValue=e,filterable:!0,clearable:!0,placeholder:"请选择","check-strategy":"parent","value-field":"theUniqueKey",disabled:e.isLock,options:c.curOptions,"show-path":!0,cascade:!1,"on-update:value":s},{empty:()=>c.fetching?a(i,null,null):a(l,null,null)})}});export{c as default};
1
+ import{defineComponent as e,reactive as t,createVNode as a,resolveComponent as n}from"vue";import{NCascader as r,NEmpty as l}from"naive-ui";import i from"../LoadingCom.vue.js";var c=e({name:"RCascader",components:{NCascader:r,NEmpty:l,LoadingCom:i},props:{form:{type:Object,default:()=>{}},item:{type:Object,default:()=>{}},isLock:{type:Boolean,default:!1},getCascadeOptions:{type:Function,default:()=>Promise.resolve([])}},emits:["scaleChange"],setup(e,r){let c=t({cascaderValue:void 0,curOptions:[],fetching:!1});const o=(e,t)=>{if(!e.length||!t||!t.length)return;let a=0,n=t.length;t[0];let r,l=e;for(;a<n;a++){let e=t[a];if(!l.length)return!1;if(r=l.find((t=>t.value===e)),0===a&&!r)return!1;if(a===n-1&&!r)return!1;if(a===n-1&&r)break;l=r.children||[]}r&&(c.cascaderValue=r.theUniqueKey)},u=(e,t)=>e.map(((e,a)=>{var n;e.curIndex=a+1;let r=e.level||0;return e.path=`${e.curIndex}`,r&&t&&(e.path=`${t.path}-${e.curIndex}`),e.theUniqueKey=e.path,e.hasOwnProperty("children")&&!e.children.length&&delete e.children,(null==(n=e.children)?void 0:n.length)&&u(e.children,e),e}));(async t=>{var a;if(!t||!Object.keys(t).length)return;let n=JSON.parse(JSON.stringify(t)),r=e.form[e.item.val_key],l=[];if(!(null==(a=n.targetSource)?void 0:a.target_id))return l=u(n.options||[]),c.curOptions=l,void o(l,r);try{c.fetching=!0,l=await e.getCascadeOptions(n),c.curOptions=l,o(l,r),c.fetching=!1}catch(e){c.fetching=!1}})(e.item);const d=(t,a,n)=>{let l=n.map((e=>e.value));c.cascaderValue=t,r.emit("scaleChange",l,e.item)};return()=>{var t;return a(n("n-cascader"),{value:c.cascaderValue,"onUpdate:value":e=>c.cascaderValue=e,filterable:!0,clearable:!0,placeholder:(null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.147"))||"请选择","check-strategy":"parent","value-field":"theUniqueKey",disabled:e.isLock,options:c.curOptions,"show-path":!0,cascade:!1,"on-update:value":d},{empty:()=>c.fetching?a(i,null,null):a(l,null,null)})}}});export{c as default};
@@ -15,6 +15,10 @@ declare const _default: import("vue").DefineComponent<{
15
15
  type: BooleanConstructor;
16
16
  default: boolean;
17
17
  };
18
+ isGeneratePrintPdf: {
19
+ type: (BooleanConstructor | ObjectConstructor)[];
20
+ default: boolean;
21
+ };
18
22
  }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "scaleChange"[], "scaleChange", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
19
23
  form: {
20
24
  type: ObjectConstructor;
@@ -32,11 +36,16 @@ declare const _default: import("vue").DefineComponent<{
32
36
  type: BooleanConstructor;
33
37
  default: boolean;
34
38
  };
39
+ isGeneratePrintPdf: {
40
+ type: (BooleanConstructor | ObjectConstructor)[];
41
+ default: boolean;
42
+ };
35
43
  }>> & {
36
44
  onScaleChange?: ((...args: any[]) => any) | undefined;
37
45
  }, {
38
46
  item: Record<string, any>;
39
47
  isLock: boolean;
48
+ isGeneratePrintPdf: boolean | Record<string, any>;
40
49
  form: Record<string, any>;
41
50
  inputLock: boolean;
42
51
  }>;
@@ -1 +1 @@
1
- import{defineComponent as e,reactive as o,watch as t,createVNode as i,resolveComponent as l,isVNode as s}from"vue";import{NCheckboxGroup as c,NCheckbox as n,NInput as r,NIcon as u}from"naive-ui";import{api as a}from"v-viewer";import{SearchOutline as p}from"@vicons/ionicons5";import"xe-utils";import"moment";import h from"../../../../../shared/utils/vexutilsExpand.js";import f from"../composables/choose-common.js";var d=e({name:"RCheckbox",components:{NCheckboxGroup:c,NCheckbox:n,NInput:r,NIcon:u},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1},inputLock:{type:Boolean,default:!1}},emits:["scaleChange"],setup(e,n){var r,d;const x=o({curCheckboxValue:[],othersText:"",curOptions:[],optionsPreSuffixObj:{}}),{choiceColor:b,showImgWrap:m,handleDefPreSuffix:v,choiceUseKey:k,isCheckboxItem:C,showPreSuffix:O,handleOptions:y,stopClick:g}=f(e,x),S=(null==(d=null==(r=e.item)?void 0:r.setting)?void 0:d.chooseStyleSetting)||1,V=o=>{const t={othersText:x.othersText,optionsPreSuffixObj:x.optionsPreSuffixObj};o&&!x.curCheckboxValue.includes("other")&&x.curCheckboxValue.push("other");const i=JSON.parse(JSON.stringify(x.curCheckboxValue));n.emit("scaleChange",i,e.item,{choiceObj:t,isSetObj:C.value})},j=o=>{var t,i;let l=o.options||[];const s=e.form[e.item.val_key],c=null==(t=null==o?void 0:o.setting)?void 0:t.defaultValue;"EVALUATE_CHECKBOX_BLOCK"===e.item.type&&(l=(null==(i=o.scoreConfigs)?void 0:i.scoreRules)||[]);let n=[];n=c&&h.isJSON(c)?JSON.parse(c):s,e.inputLock?((e,o,t)=>{var i;if(x.curOptions=y(t),!t.length||!o||!o.length)return;const l=[];let s,c=0;const n=o.length;for(;c<n;c++){if(s=o[c],"其他"===s){x.othersText=s,x.curCheckboxValue=["other"],!l.includes("other")&&l.push("other");continue}const e=t.findIndex((e=>e.value===s));if(e<0){x.othersText=s,!l.includes("other")&&l.push("other");continue}const n=null==(i=t[e])?void 0:i.key;l.indexOf(n)<0&&l.push(n)}x.curCheckboxValue=l,V()})(0,o.dbValue||n,l):((e,o,t)=>{var i;if(x.curOptions=y(t),!t.length||!o||!o.length)return;if("EVALUATE_CHECKBOX_BLOCK"===e.type)return x.curCheckboxValue=o,void V();const l=[],s=o.length;let c,n=0;const r=t.some((e=>e.importability||"other"===e.key));for(;n<s;n++){if(c=o[n],"其他"===c){x.othersText=c,x.curCheckboxValue=["other"],!l.includes("other")&&l.push("other");continue}const e=t.findIndex((e=>e.value===c));if(e>0){const o=null==(i=t[e])?void 0:i.key;!l.includes(o)&&l.push(o)}else t.map((e=>{const o=v(e,n,c,!0,r);o&&!l.includes(o)&&l.push(o)}))}x.curCheckboxValue=l,V()})(o,o.dbValue||n,l)};t((()=>e.item),(e=>{e&&Object.keys(e).length&&j(e)}),{immediate:!0});const L=h.debounce(V,300),T=h.debounce((o=>{const t={othersText:x.othersText,optionsPreSuffixObj:x.optionsPreSuffixObj};x.curCheckboxValue.includes(o.key)||x.curCheckboxValue.push(o.key);const i=JSON.parse(JSON.stringify(x.curCheckboxValue));n.emit("scaleChange",i,e.item,{choiceObj:t,isSetObj:C.value})}),300),w=e=>i("span",{class:"scale-choice-img-wrap"},[i("img",{class:"show-picture",src:e.imageUrl},null),i("div",{class:"scale-preview-wrap"},[i(u,{size:"24",color:"#fff",component:p,onClick:o=>((e,o)=>{e.preventDefault(),e.stopPropagation();const t=x.curOptions.map((e=>e.imageUrl)).filter(Boolean);if(!t.length)return;const i=t.findIndex((e=>e===o));a({images:t,options:{toolbar:!0,initialViewIndex:i<0?0:i}})})(o,e.imageUrl)},null)])]),N=o=>i("div",{class:"presuffix-wrap"},[o.prefix&&i("span",{class:"prefix-span",style:{color:b.value(o)}},[o.prefix]),i(l("n-input"),{value:x.optionsPreSuffixObj[o.key],"onUpdate:value":e=>x.optionsPreSuffixObj[o.key]=e,disabled:e.isLock||e.inputLock,style:{color:b.value(o)},placeholder:"请输入",bordered:!1,onInput:()=>T(o),onClick:g},null),o.suffix&&i("span",{class:"suffix-span",style:{color:b.value(o)}},[o.suffix])]),P=e=>i("span",{style:{color:b.value(e)},class:"other-span"},[e.label]),I=o=>i("div",{class:"choose-other",onClick:g},[i(l("n-input"),{value:x.othersText,"onUpdate:value":[e=>x.othersText=e,()=>L(!0)],disabled:e.isLock||e.inputLock,style:{color:b.value(o)},placeholder:"请输入",bordered:!1},null)]),U=e=>C.value&&O.value(e),B=k.value;return()=>{let o;return i(c,{value:x.curCheckboxValue,"onUpdate:value":[e=>x.curCheckboxValue=e,()=>V(!1)],class:["c-choice-wrap","choice-wrap-"+S],disabled:e.isLock},"function"==typeof(t=o=x.curOptions.map((e=>i("div",{class:"c-choice-radio-div"},[i(l("n-checkbox"),{key:e.value,value:e[B]},{default:()=>[m.value(e)&&w(e),U(e)&&N(e),!U(e)&&P(e),e.importability&&I(e)]})]))))||"[object Object]"===Object.prototype.toString.call(t)&&!s(t)?o:{default:()=>[o]});var t}}});export{d as default};
1
+ import{defineComponent as e,reactive as o,toRefs as t,computed as i,watch as l,createVNode as s,resolveComponent as n,isVNode as r}from"vue";import{NCheckboxGroup as a,NCheckbox as u,NInput as c,NIcon as p}from"naive-ui";import{api as h}from"v-viewer";import{SearchOutline as d}from"@vicons/ionicons5";import"xe-utils";import"moment";import f from"../../../../../shared/utils/vexutilsExpand.js";import x from"../composables/choose-common.js";var v=e({name:"RCheckbox",components:{NCheckboxGroup:a,NCheckbox:u,NInput:c,NIcon:p},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1},inputLock:{type:Boolean,default:!1},isGeneratePrintPdf:{type:[Boolean,Object],default:!1}},emits:["scaleChange"],setup(e,u){var c,v;const b=o({curCheckboxValue:[],othersText:"",curOptions:[],optionsPreSuffixObj:{}}),{isGeneratePrintPdf:m}=t(e),k=i((()=>e.isLock||e.inputLock)),{choiceColor:y,showImgWrap:C,handleDefPreSuffix:O,choiceUseKey:g,isCheckboxItem:w,showPreSuffix:j,handleOptions:S,stopClick:V}=x(e,b),P=(null==(v=null==(c=e.item)?void 0:c.setting)?void 0:v.chooseStyleSetting)||1,T=o=>{const t={othersText:b.othersText,optionsPreSuffixObj:b.optionsPreSuffixObj};o&&!b.curCheckboxValue.includes("other")&&b.curCheckboxValue.push("other");const i=JSON.parse(JSON.stringify(b.curCheckboxValue));u.emit("scaleChange",i,e.item,{choiceObj:t,isSetObj:w.value})},L=o=>{var t,i;let l=o.options||[];const s=e.form[e.item.val_key],n=null==(t=null==o?void 0:o.setting)?void 0:t.defaultValue;"EVALUATE_CHECKBOX_BLOCK"===e.item.type&&(l=(null==(i=o.scoreConfigs)?void 0:i.scoreRules)||[]);let r=[];r=n&&f.isJSON(n)?JSON.parse(n):s,e.inputLock?((e,o,t)=>{var i;if(b.curOptions=S(t),!t.length||!o||!o.length)return;const l=[];let s,n=0;const r=o.length;for(;n<r;n++){if(s=o[n],"其他"===s){b.othersText=s,b.curCheckboxValue=["other"],!l.includes("other")&&l.push("other");continue}const e=t.findIndex((e=>e.value===s));if(e<0){b.othersText=s,!l.includes("other")&&l.push("other");continue}const r=null==(i=t[e])?void 0:i.key;l.indexOf(r)<0&&l.push(r)}b.curCheckboxValue=l,T()})(0,o.dbValue||r,l):((e,o,t)=>{var i;if(b.curOptions=S(t),!t.length||!o||!o.length)return;if("EVALUATE_CHECKBOX_BLOCK"===e.type)return b.curCheckboxValue=o,void T();const l=[],s=o.length;let n,r=0;const a=t.some((e=>e.importability||"other"===e.key));for(;r<s;r++){if(n=o[r],"其他"===n){b.othersText=n,b.curCheckboxValue=["other"],!l.includes("other")&&l.push("other");continue}const e=t.findIndex((e=>e.value===n));if(e>0){const o=null==(i=t[e])?void 0:i.key;!l.includes(o)&&l.push(o)}else t.map((e=>{const o=O(e,r,n,!0,a);o&&!l.includes(o)&&l.push(o)}))}b.curCheckboxValue=l,T()})(o,o.dbValue||r,l)};l((()=>e.item),(e=>{e&&Object.keys(e).length&&L(e)}),{immediate:!0});const B=f.debounce(T,200),N=f.debounce((o=>{const t={othersText:b.othersText,optionsPreSuffixObj:b.optionsPreSuffixObj};b.curCheckboxValue.includes(o.key)||b.curCheckboxValue.push(o.key);const i=JSON.parse(JSON.stringify(b.curCheckboxValue));u.emit("scaleChange",i,e.item,{choiceObj:t,isSetObj:w.value})}),200),I=e=>{b.othersText=e,B(!0)},U=e=>s("span",{class:"scale-choice-img-wrap"},[s("img",{class:"show-picture",src:e.imageUrl},null),s("div",{class:"scale-preview-wrap"},[s(p,{size:"24",color:"#fff",component:d,onClick:o=>((e,o)=>{e.preventDefault(),e.stopPropagation();const t=b.curOptions.map((e=>e.imageUrl)).filter(Boolean);if(!t.length)return;const i=t.findIndex((e=>e===o));h({images:t,options:{toolbar:!0,initialViewIndex:i<0?0:i}})})(o,e.imageUrl)},null)])]),E=e=>{var o;const t=e?b.optionsPreSuffixObj[e.key]:b.othersText,i=t||((null==(o=window.getLanguageByCode)?void 0:o.call(window,"10010.1.383"))||"请输入");return s("span",{class:["print-span",{"print-span-disabled":k.value,"print-span-empty":!t}]},[i])},J=e=>{var o;return s("div",{class:"presuffix-wrap"},[e.prefix&&s("span",{class:"prefix-span",style:{color:y.value(e)}},[e.prefix]),m.value?E(e):s(n("n-input"),{value:b.optionsPreSuffixObj[e.key],"onUpdate:value":o=>b.optionsPreSuffixObj[e.key]=o,disabled:k.value,style:{color:y.value(e)},placeholder:(null==(o=window.getLanguageByCode)?void 0:o.call(window,"10010.1.383"))||"请输入",bordered:!1,onInput:o=>((e,o)=>{b.optionsPreSuffixObj[o.key]=e,N(o)})(o,e),onClick:V,type:"textarea",autosize:!0,rows:1},null),e.suffix&&s("span",{class:"suffix-span",style:{color:y.value(e)}},[e.suffix])])},K=e=>s("span",{style:{color:y.value(e)},class:"other-span"},[e.label]),_=e=>{var o;return s("div",{class:"choose-other",onClick:V},[s(n("n-input"),{value:b.othersText,"onUpdate:value":[e=>b.othersText=e,I],disabled:k.value,style:{color:y.value(e)},placeholder:(null==(o=window.getLanguageByCode)?void 0:o.call(window,"10010.1.383"))||"请输入",bordered:!1,type:"textarea",autosize:!0,rows:1},null)])},A=e=>w.value&&j.value(e),z=g.value;return()=>{let o;return s(a,{value:b.curCheckboxValue,"onUpdate:value":[e=>b.curCheckboxValue=e,()=>T(!1)],class:["c-choice-wrap","choice-wrap-"+P],disabled:e.isLock},"function"==typeof(t=o=b.curOptions.map((e=>s("div",{class:"c-choice-radio-div"},[s(n("n-checkbox"),{key:e.value,value:e[z],class:{"c-radio-textarea":e.importability||A(e)}},{default:()=>[C.value(e)&&U(e),A(e)&&J(e),!A(e)&&K(e),e.importability&&(m.value?E():_(e))]})]))))||"[object Object]"===Object.prototype.toString.call(t)&&!r(t)?o:{default:()=>[o]});var t}}});export{v as default};
@@ -11,6 +11,10 @@ declare const _default: import("vue").DefineComponent<{
11
11
  type: BooleanConstructor;
12
12
  default: boolean;
13
13
  };
14
+ isGeneratePrintPdf: {
15
+ type: (BooleanConstructor | ObjectConstructor)[];
16
+ default: boolean;
17
+ };
14
18
  }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "scaleChange"[], "scaleChange", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
15
19
  form: {
16
20
  type: ObjectConstructor;
@@ -24,11 +28,16 @@ declare const _default: import("vue").DefineComponent<{
24
28
  type: BooleanConstructor;
25
29
  default: boolean;
26
30
  };
31
+ isGeneratePrintPdf: {
32
+ type: (BooleanConstructor | ObjectConstructor)[];
33
+ default: boolean;
34
+ };
27
35
  }>> & {
28
36
  onScaleChange?: ((...args: any[]) => any) | undefined;
29
37
  }, {
30
38
  item: Record<string, any>;
31
39
  isLock: boolean;
40
+ isGeneratePrintPdf: boolean | Record<string, any>;
32
41
  form: Record<string, any>;
33
42
  }>;
34
43
  export default _default;
@@ -1 +1 @@
1
- import{defineComponent as e,computed as t,ref as l,watch as a,createVNode as o}from"vue";import{NInput as u}from"naive-ui";var i=e({name:"RInput",components:{NInput:u},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1}},emits:["scaleChange"],setup(e,{emit:i}){var n,m,r,s,v,d;const p=null==(n=e.item)?void 0:n.valueType,c=(null==(m=e.item)?void 0:m.type)||"INPUT",f="INPUT"==c||"EVALUATE_INPUT"==c,y=(null==(s=null==(r=e.item)?void 0:r.setting)?void 0:s.inputRow)||1,b=null==(d=null==(v=e.item)?void 0:v.setting)?void 0:d.defaultPlaceHolder,g=t((()=>y&&"auto"!=y?{minRows:y||1,maxRows:y||1}:{minRows:1})),k=e=>{if(!f)return;const t=e.key;e.returnValue="e"!==t&&"E"!==t&&"+"!==t&&"-"!==t},w=l(e.form[e.item.val_key]);a((()=>e.form[e.item.val_key]),(e=>{w.value=e}),{immediate:!0});const I=t=>{w.value=f&&t&&"number"===p?t.replace(/[^\d.]/gi,""):t,i("scaleChange",w.value,e.item)};return()=>(()=>{const t=f?"textarea":p||"text";return o(u,{value:w.value,clearable:!0,type:t,autosize:g.value,placeholder:b,disabled:e.isLock,onKeydown:k,"onUpdate:value":I},null)})()}});export{i as default};
1
+ import{defineComponent as e,toRefs as t,computed as a,ref as n,watch as l,createVNode as i}from"vue";import{NInput as o}from"naive-ui";var u=e({name:"RInput",components:{NInput:o},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1},isGeneratePrintPdf:{type:[Boolean,Object],default:!1}},emits:["scaleChange"],setup(e,{emit:u}){var r,p,s,d,m,v;const c=null==(r=e.item)?void 0:r.valueType,f=(null==(p=e.item)?void 0:p.type)||"INPUT",y="INPUT"==f||"EVALUATE_INPUT"==f,w=(null==(d=null==(s=e.item)?void 0:s.setting)?void 0:d.inputRow)||1,g=null==(v=null==(m=e.item)?void 0:m.setting)?void 0:v.defaultPlaceHolder,{isGeneratePrintPdf:P}=t(e),b=a((()=>w&&"auto"!=w?{minRows:w||1,maxRows:w||1}:{minRows:1})),k=e=>{if(!y)return;const t=e.key;e.returnValue="e"!==t&&"E"!==t&&"+"!==t&&"-"!==t},I=n(e.form[e.item.val_key]);l((()=>e.form[e.item.val_key]),(e=>{I.value=e}),{immediate:!0});const L=t=>{I.value=y&&t&&"number"===c?t.replace(/[^\d.]/gi,""):t,u("scaleChange",I.value,e.item)},R=()=>{const t=y?"textarea":c||"text";return P.value?(()=>{var t;const a=I.value,n=a||(null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.383"))||"请输入";return i("div",{class:["input-print-span",{"input-print-span-disabled":e.isLock,"input-print-span-empty":!a}]},[n])})():i(o,{value:I.value,clearable:!0,type:t,autosize:b.value,placeholder:g,disabled:e.isLock,onKeydown:k,"onUpdate:value":L},null)};return()=>R()}});export{u as default};
@@ -1 +1 @@
1
- import{defineComponent as o,reactive as e,createVNode as t,resolveComponent as a}from"vue";import{NModal as i,NInput as n,NIcon as p}from"naive-ui";import"xe-utils";import"moment";import s from"../../../../../shared/utils/vexutilsExpand.js";import{AlertCircleOutline as l}from"@vicons/ionicons5";import m from"../../../../map/index.js";var c=o({name:"RMap",components:{NModal:i,NInput:n,NIcon:p,CMap:m},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1},locationProp:{type:String,default:""},ak:{type:String,default:"KP3BZ-OAC3W-PY6RY-OJ6DV-JYKN3-H6F72"}},emits:["scaleChange"],setup(o,i){const n=o.form[o.item.val_key],p=e({mapVisible:!1,mapLocation:""}),c=o=>{if(s.isJSON(o)){const e=JSON.parse(o);return e.address||e.name}return""};p.mapLocation=c(n);const r=e=>{const{locationProp:t,isInit:a}=e;p.mapLocation=c(t),i.emit("scaleChange",t,o.item),p.mapVisible=!1},u=()=>{o.isLock||(p.mapVisible=!0)};return()=>t("div",{class:{"c-map-container":!o.isLock}},[t(a("n-input"),{value:p.mapLocation,readonly:!0,class:"map-input","on-click":u,placeholder:"请选择"},{prefix:()=>t(a("n-icon"),{size:"18",component:l},null)}),t(a("n-modal"),{class:"c-scale-map-modal",show:p.mapVisible,"onUpdate:show":o=>p.mapVisible=o,preset:"card",style:{width:"800px",height:"80vh"}},{default:()=>[t(m,{locationProp:o.locationProp,ak:o.ak,onSelectLocation:r},null)]})])}});export{c as default};
1
+ import{defineComponent as o,reactive as e,createVNode as a,resolveComponent as t}from"vue";import{NModal as i,NInput as n,NIcon as p}from"naive-ui";import"xe-utils";import"moment";import l from"../../../../../shared/utils/vexutilsExpand.js";import{AlertCircleOutline as s}from"@vicons/ionicons5";import r from"../../../../map/index.js";var m=o({name:"RMap",components:{NModal:i,NInput:n,NIcon:p,CMap:r},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1},locationProp:{type:String,default:""},ak:{type:String,default:"KP3BZ-OAC3W-PY6RY-OJ6DV-JYKN3-H6F72"}},emits:["scaleChange"],setup(o,i){const n=o.form[o.item.val_key],p=e({mapVisible:!1,mapLocation:""}),m=o=>{if(l.isJSON(o)){const e=JSON.parse(o);return e.address||e.name}return""};p.mapLocation=m(n);const c=e=>{const{locationProp:a,isInit:t}=e;p.mapLocation=m(a),i.emit("scaleChange",a,o.item),p.mapVisible=!1},d=()=>{o.isLock||(p.mapVisible=!0)};return()=>{return a("div",{class:{"c-map-container":!o.isLock}},[a(t("n-input"),{value:p.mapLocation,readonly:!0,class:"map-input","on-click":d,placeholder:(null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.147"))||"请选择"},{prefix:()=>a(t("n-icon"),{size:"18",component:s},null)}),a(t("n-modal"),{class:"c-scale-map-modal",show:p.mapVisible,"onUpdate:show":o=>p.mapVisible=o,preset:"card",style:{width:"800px",height:"80vh"}},{default:()=>[a(r,{locationProp:o.locationProp,ak:o.ak,onSelectLocation:c},null)]})]);var e}}});export{m as default};
@@ -15,6 +15,10 @@ declare const _default: import("vue").DefineComponent<{
15
15
  type: BooleanConstructor;
16
16
  default: boolean;
17
17
  };
18
+ isGeneratePrintPdf: {
19
+ type: (BooleanConstructor | ObjectConstructor)[];
20
+ default: boolean;
21
+ };
18
22
  }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "scaleChange"[], "scaleChange", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
19
23
  form: {
20
24
  type: ObjectConstructor;
@@ -32,11 +36,16 @@ declare const _default: import("vue").DefineComponent<{
32
36
  type: BooleanConstructor;
33
37
  default: boolean;
34
38
  };
39
+ isGeneratePrintPdf: {
40
+ type: (BooleanConstructor | ObjectConstructor)[];
41
+ default: boolean;
42
+ };
35
43
  }>> & {
36
44
  onScaleChange?: ((...args: any[]) => any) | undefined;
37
45
  }, {
38
46
  item: Record<string, any>;
39
47
  isLock: boolean;
48
+ isGeneratePrintPdf: boolean | Record<string, any>;
40
49
  form: Record<string, any>;
41
50
  inputLock: boolean;
42
51
  }>;
@@ -1 +1 @@
1
- import{defineComponent as e,reactive as o,watch as t,createVNode as i,resolveComponent as l,isVNode as s}from"vue";import{NRadioGroup as r,NRadio as a,NInput as u,NIcon as n}from"naive-ui";import{api as c}from"v-viewer";import{SearchOutline as p}from"@vicons/ionicons5";import f from"../composables/choose-common.js";import"xe-utils";import"moment";import v from"../../../../../shared/utils/vexutilsExpand.js";var d=e({name:"RRadio",components:{NRadioGroup:r,NRadio:a,NInput:u,NIcon:n},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1},inputLock:{type:Boolean,default:!1}},emits:["scaleChange"],setup(e,a){var u,d;const m=o({curvalue:"",othersText:"",curOptions:[],optionsPreSuffixObj:{}}),{choiceColor:h,showImgWrap:x,handleDefPreSuffix:b,choiceUseKey:O,isRadioItem:j,showPreSuffix:y,handleOptions:g,stopClick:k}=f(e,m),S=(null==(d=null==(u=e.item)?void 0:u.setting)?void 0:d.chooseStyleSetting)||1,P=o=>{var t;let i=o.options||[];const l=e.form[e.item.val_key];"EVALUATE_RADIO_BLOCK"===e.item.type&&(i=(null==(t=o.scoreConfigs)?void 0:t.scoreRules)||[]);((e,o,t)=>{if(m.curOptions=g(t),!t.length||!o)return;if("EVALUATE_RADIO_BLOCK"===e.type)return m.curvalue=o,void C();const i=t.find((e=>e.value===o));if(i)return m.curvalue=i.key,void C();t.find(((e,t)=>{const i=b(e,t,o);return i&&(m.curvalue=i),!!i||!1}))||(m.othersText=o,m.curvalue="other"),C()})(o,o.dbValue||o.setting.defaultValue||l,i)},C=()=>{const o={othersText:m.othersText,optionsPreSuffixObj:m.optionsPreSuffixObj};a.emit("scaleChange",m.curvalue,e.item,{choiceObj:o,isSetObj:j.value})};t((()=>e.item),(e=>{e&&Object.keys(e).length&&P(e)}),{immediate:!0});const L=v.debounce(((o,t)=>{m.optionsPreSuffixObj[t.key]=o,m.curvalue=t.key;const i={othersText:m.othersText,optionsPreSuffixObj:m.optionsPreSuffixObj};console.log(m.optionsPreSuffixObj),a.emit("scaleChange",m.curvalue,e.item,{choiceObj:i,isSetObj:j.value})}),300),T=v.debounce((()=>{const o={othersText:m.othersText,optionsPreSuffixObj:m.optionsPreSuffixObj};m.curvalue="other",a.emit("scaleChange","other",e.item,{choiceObj:o,isSetObj:j.value})}),300),w=e=>i("span",{class:"scale-choice-img-wrap"},[i("img",{class:"show-picture",src:e.imageUrl},null),i("div",{class:"scale-preview-wrap"},[i(n,{size:"24",color:"#fff",component:p,onClick:o=>((e,o)=>{e.preventDefault(),e.stopPropagation();const t=m.curOptions.map((e=>e.imageUrl)).filter(Boolean);if(!t.length)return;const i=t.findIndex((e=>e===o));c({images:t,options:{toolbar:!0,initialViewIndex:i<0?0:i}})})(o,e.imageUrl)},null)])]),U=o=>i("div",{class:"presuffix-wrap"},[o.prefix&&i("span",{class:"prefix-span",style:{color:h.value(o)}},[o.prefix]),i(l("n-input"),{value:m.optionsPreSuffixObj[o.key],"onUpdate:value":e=>m.optionsPreSuffixObj[o.key]=e,disabled:e.isLock||e.inputLock,style:{color:h.value(o)},placeholder:"请输入",bordered:!1,"on-update:value":e=>L(e,o),onClick:k},null),o.suffix&&i("span",{class:"suffix-span",style:{color:h.value(o)}},[o.suffix])]),I=e=>i("span",{style:{color:h.value(e)},class:"other-span"},[e.label]),R=o=>i("div",{class:"choose-other",onClick:k},[i(l("n-input"),{value:m.othersText,"onUpdate:value":[e=>m.othersText=e,T],disabled:e.isLock||e.inputLock,style:{color:h.value(o)},placeholder:"请输入",bordered:!1},null)]),A=e=>j.value&&y.value(e),B=O.value;return()=>{let o;return i(r,{value:m.curvalue,"onUpdate:value":[e=>m.curvalue=e,C],class:["c-choice-wrap","choice-wrap-"+S],disabled:e.isLock},"function"==typeof(t=o=m.curOptions.map((o=>i("div",{class:"c-choice-radio-div"},[i(l("n-radio"),{key:o.value,value:o[B],onClick:t=>((o,t)=>{if(e.isLock)return;o.preventDefault(),o.stopPropagation();const i=t[B];m.curvalue=m.curvalue===i?"":i,C()})(t,o)},{default:()=>[x.value(o)&&w(o),A(o)&&U(o),!A(o)&&I(o),o.importability&&R(o)]})]))))||"[object Object]"===Object.prototype.toString.call(t)&&!s(t)?o:{default:()=>[o]});var t}}});export{d as default};
1
+ import{defineComponent as e,reactive as o,toRefs as t,computed as i,watch as a,createVNode as r,resolveComponent as l,isVNode as s}from"vue";import{NRadioGroup as n,NRadio as u,NInput as c,NIcon as p}from"naive-ui";import{api as f}from"v-viewer";import{SearchOutline as d}from"@vicons/ionicons5";import v from"../composables/choose-common.js";import"xe-utils";import"moment";import m from"../../../../../shared/utils/vexutilsExpand.js";var h=e({name:"RRadio",components:{NRadioGroup:n,NRadio:u,NInput:c,NIcon:p},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1},inputLock:{type:Boolean,default:!1},isGeneratePrintPdf:{type:[Boolean,Object],default:!1}},emits:["scaleChange"],setup(e,u){var c,h;const x=o({curvalue:"",othersText:"",curOptions:[],optionsPreSuffixObj:{}}),{isGeneratePrintPdf:b}=t(e),y=i((()=>e.isLock||e.inputLock)),{choiceColor:O,showImgWrap:g,handleDefPreSuffix:j,choiceUseKey:w,isRadioItem:k,showPreSuffix:P,handleOptions:S,stopClick:C}=v(e,x),T=(null==(h=null==(c=e.item)?void 0:c.setting)?void 0:h.chooseStyleSetting)||1,L=o=>{var t;let i=o.options||[];const a=e.form[e.item.val_key];"EVALUATE_RADIO_BLOCK"===e.item.type&&(i=(null==(t=o.scoreConfigs)?void 0:t.scoreRules)||[]);((e,o,t)=>{if(x.curOptions=S(t),!t.length||!o)return;if("EVALUATE_RADIO_BLOCK"===e.type)return x.curvalue=o,void B();const i=t.find((e=>e.value===o));if(i)return x.curvalue=i.key,void B();t.find(((e,t)=>{const i=j(e,t,o);return i&&(x.curvalue=i),!!i||!1}))||(x.othersText=o,x.curvalue="other"),B()})(o,o.dbValue||o.setting.defaultValue||a,i)},B=()=>{const o={othersText:x.othersText,optionsPreSuffixObj:x.optionsPreSuffixObj};u.emit("scaleChange",x.curvalue,e.item,{choiceObj:o,isSetObj:k.value})};a((()=>e.item),(e=>{e&&Object.keys(e).length&&L(e)}),{immediate:!0});const U=m.debounce(((o,t)=>{x.curvalue=t.key;const i={othersText:x.othersText,optionsPreSuffixObj:x.optionsPreSuffixObj};u.emit("scaleChange",x.curvalue,e.item,{choiceObj:i,isSetObj:k.value})}),200),I=m.debounce((()=>{const o={othersText:x.othersText,optionsPreSuffixObj:x.optionsPreSuffixObj};x.curvalue="other",u.emit("scaleChange","other",e.item,{choiceObj:o,isSetObj:k.value})}),200),R=e=>{x.othersText=e,I()},A=e=>r("span",{class:"scale-choice-img-wrap"},[r("img",{class:"show-picture",src:e.imageUrl},null),r("div",{class:"scale-preview-wrap"},[r(p,{size:"24",color:"#fff",component:d,onClick:o=>((e,o)=>{e.preventDefault(),e.stopPropagation();const t=x.curOptions.map((e=>e.imageUrl)).filter(Boolean);if(!t.length)return;const i=t.findIndex((e=>e===o));f({images:t,options:{toolbar:!0,initialViewIndex:i<0?0:i}})})(o,e.imageUrl)},null)])]),D=e=>{var o;const t=e?x.optionsPreSuffixObj[e.key]:x.othersText,i=t||((null==(o=window.getLanguageByCode)?void 0:o.call(window,"10010.1.383"))||"请输入");return r("span",{class:["print-span",{"print-span-disabled":y.value,"print-span-empty":!t}]},[i])},E=e=>{var o;return r("div",{class:"presuffix-wrap"},[e.prefix&&r("span",{class:"prefix-span",style:{color:O.value(e)}},[e.prefix]),b.value?D(e):r(l("n-input"),{value:x.optionsPreSuffixObj[e.key],"onUpdate:value":o=>x.optionsPreSuffixObj[e.key]=o,disabled:y.value,style:{color:O.value(e)},placeholder:(null==(o=window.getLanguageByCode)?void 0:o.call(window,"10010.1.383"))||"请输入",bordered:!1,"on-update:value":o=>((e,o)=>{x.optionsPreSuffixObj[o.key]=e,U(e,o)})(o,e),onClick:C,type:"textarea",autosize:!0,rows:1},null),e.suffix&&r("span",{class:"suffix-span",style:{color:O.value(e)}},[e.suffix])])},V=e=>r("span",{style:{color:O.value(e)},class:"other-span"},[e.label]),_=e=>{var o;return r("div",{class:"choose-other",onClick:C},[r(l("n-input"),{value:x.othersText,"onUpdate:value":[e=>x.othersText=e,R],disabled:y.value,style:{color:O.value(e)},placeholder:(null==(o=window.getLanguageByCode)?void 0:o.call(window,"10010.1.383"))||"请输入",bordered:!1,type:"textarea",autosize:!0,rows:1},null)])},N=e=>k.value&&P.value(e),z=w.value;return()=>{let o;return r(n,{value:x.curvalue,"onUpdate:value":[e=>x.curvalue=e,B],class:["c-choice-wrap","choice-wrap-"+T],disabled:e.isLock},"function"==typeof(t=o=x.curOptions.map((o=>r("div",{class:"c-choice-radio-div"},[r(l("n-radio"),{key:o.value,value:o[z],onClick:t=>((o,t)=>{if(e.isLock)return;o.preventDefault(),o.stopPropagation();const i=t[z];x.curvalue=x.curvalue===i?"":i,B()})(t,o),class:{"c-radio-textarea":o.importability||N(o)}},{default:()=>[g.value(o)&&A(o),N(o)&&E(o),!N(o)&&V(o),o.importability&&(b.value?D():_(o))]})]))))||"[object Object]"===Object.prototype.toString.call(t)&&!s(t)?o:{default:()=>[o]});var t}}});export{h as default};
@@ -1 +1 @@
1
- import{defineComponent as e,reactive as t,computed as l,watch as a,createVNode as i,resolveComponent as o}from"vue";import{NSelect as n,NEmpty as u}from"naive-ui";import r from"../LoadingCom.vue.js";var s=e({name:"RSelect",components:{NSelect:n,NEmpty:u,LoadingCom:r},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1},getSelectOptions:{type:Function,default:()=>Promise.resolve([])},getSearchOptions:{type:Function,default:()=>Promise.resolve([])},openType:{type:String,default:""}},emits:["scaleChange"],setup(e,n){const s=t({choiceValue:[],selectParams:{tableType:"TABLE_LIST",pageSize:20,page:1},cloneItem:{},columnName:"",showField:"",curOptions:[],fieldList:[],buttonList:[],fetching:!1,searchKeyword:""});e.openType;const c=l((()=>e.form[e.item.val_key])),v=l((()=>{var t,l;return!!(null==(l=null==(t=e.item)?void 0:t.setting)?void 0:l.isMultiple)})),p=l((()=>{const{targetSource:t={},options:l=[],optionType:a}=e.item||{};return!(!t.target_id||!l.length&&3!=a)})),m=l((()=>{const{targetSource:t={}}=e.item||{};return!!t.target_id&&!p.value})),d=l((()=>{var t;const{target_id:l,values:a}=(null==(t=e.item)?void 0:t.targetSource)||{};return l&&a?p.value?a||"value":a:"value"})),g=l((()=>{var t;const{target_id:l,showField:a}=(null==(t=e.item)?void 0:t.targetSource)||{};return l&&a?p.value?a||"label":a:"label"})),h=async()=>{const{targetSource:t,type:l,options:a=[],optionType:i=1}=s.cloneItem;if(s.showField="label",null==t?void 0:t.target_id)if(p.value)s.curOptions=(e=>e&&e.length?e.map((e=>("cascadeData"in e&&Object.assign(e,{...e.cascadeData}),d.value in e||(e[d.value]=e.value||e.label),g.value in e||(e[g.value]=e.label),e))):[])(a);else try{s.fetching=!0,s.curOptions=await e.getSelectOptions(s.cloneItem),s.fetching=!1,s.columnName=null==t?void 0:t.values,s.showField=(null==t?void 0:t.showField)||(null==t?void 0:t.values)}catch(e){s.fetching=!1}},f=async t=>{if(m.value){s.searchKeyword=t;try{s.curOptions=await e.getSearchOptions({values:s.columnName,showField:s.showField,keyword:t},s.cloneItem)}catch(e){console.log(e)}}},y=async e=>{var t;if(!e||!m.value)return;if(!c.value&&s.searchKeyword)return void f();if(!c.value||!(null==(t=s.curOptions)?void 0:t.length))return;s.curOptions.find((e=>e[d.value]===c.value))||f(c.value)},O=t=>{const l={value:"",list:[]};let a;return t&&Array.isArray(t)?(l.value=t,t.length?(t.forEach((e=>{a=S(e),a&&l.list.push(a)})),void n.emit("scaleChange",l,e.item,l)):(l.list=[],void n.emit("scaleChange",l,e.item,l))):(l.value=t,a=S(t),a&&l.list.push(a),void n.emit("scaleChange",l,e.item,l))},S=e=>s.curOptions.find((t=>t.value===e));return a((()=>e.item),(e=>{e&&Object.keys(e).length&&(e=>{var t;s.cloneItem=JSON.parse(JSON.stringify(e));let l=s.cloneItem.options||[];"EVALUATE_SELECT"===e.type&&(l=(null==(t=s.cloneItem.scoreConfigs)?void 0:t.scoreRules)||[]),s.curOptions=l,h()})(e)}),{immediate:!0}),()=>i(o("n-select"),{value:e.form[e.item.val_key],"onUpdate:value":[t=>e.form[e.item.val_key]=t,O],filterable:!0,clearable:!0,placeholder:"请选择","value-field":d.value,"label-field":g.value,multiple:v.value,disabled:e.isLock,loading:s.fetching,options:s.curOptions,remote:m.value,onSearch:f,"onUpdate:show":y},{empty:()=>s.fetching?i(r,null,null):i(u,null,null)})}});export{s as default};
1
+ import{defineComponent as e,reactive as t,computed as l,watch as a,createVNode as i,resolveComponent as o}from"vue";import{NSelect as n,NEmpty as u}from"naive-ui";import r from"../LoadingCom.vue.js";var s=e({name:"RSelect",components:{NSelect:n,NEmpty:u,LoadingCom:r},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1},getSelectOptions:{type:Function,default:()=>Promise.resolve([])},getSearchOptions:{type:Function,default:()=>Promise.resolve([])},openType:{type:String,default:""}},emits:["scaleChange"],setup(e,n){const s=t({choiceValue:[],selectParams:{tableType:"TABLE_LIST",pageSize:20,page:1},cloneItem:{},columnName:"",showField:"",curOptions:[],fieldList:[],buttonList:[],fetching:!1,searchKeyword:""});e.openType;const c=l((()=>e.form[e.item.val_key])),v=l((()=>{var t,l;return!!(null==(l=null==(t=e.item)?void 0:t.setting)?void 0:l.isMultiple)})),d=l((()=>{const{targetSource:t={},options:l=[],optionType:a}=e.item||{};return!(!t.target_id||!l.length&&3!=a)})),p=l((()=>{const{targetSource:t={}}=e.item||{};return!!t.target_id&&!d.value})),m=l((()=>{var t;const{target_id:l,values:a}=(null==(t=e.item)?void 0:t.targetSource)||{};return l&&a?d.value?a||"value":a:"value"})),g=l((()=>{var t;const{target_id:l,showField:a}=(null==(t=e.item)?void 0:t.targetSource)||{};return l&&a?d.value?a||"label":a:"label"})),h=async()=>{const{targetSource:t,type:l,options:a=[],optionType:i=1}=s.cloneItem;if(s.showField="label",null==t?void 0:t.target_id)if(d.value)s.curOptions=(e=>e&&e.length?e.map((e=>("cascadeData"in e&&Object.assign(e,{...e.cascadeData}),m.value in e||(e[m.value]=e.value||e.label),g.value in e||(e[g.value]=e.label),e))):[])(a);else try{s.fetching=!0,s.curOptions=await e.getSelectOptions(s.cloneItem),s.fetching=!1,s.columnName=null==t?void 0:t.values,s.showField=(null==t?void 0:t.showField)||(null==t?void 0:t.values)}catch(e){s.fetching=!1}},f=async t=>{if(p.value){s.searchKeyword=t;try{s.curOptions=await e.getSearchOptions({values:s.columnName,showField:s.showField,keyword:t},s.cloneItem)}catch(e){console.log(e)}}},y=async e=>{var t;if(!e||!p.value)return;if(!c.value&&s.searchKeyword)return void f();if(!c.value||!(null==(t=s.curOptions)?void 0:t.length))return;s.curOptions.find((e=>e[m.value]===c.value))||f(c.value)},O=t=>{const l={value:"",list:[]};let a;return t&&Array.isArray(t)?(l.value=t,t.length?(t.forEach((e=>{a=w(e),a&&l.list.push(a)})),void n.emit("scaleChange",l,e.item,l)):(l.list=[],void n.emit("scaleChange",l,e.item,l))):(l.value=t,a=w(t),a&&l.list.push(a),void n.emit("scaleChange",l,e.item,l))},w=e=>s.curOptions.find((t=>t.value===e));return a((()=>e.item),(e=>{e&&Object.keys(e).length&&(e=>{var t;s.cloneItem=JSON.parse(JSON.stringify(e));let l=s.cloneItem.options||[];"EVALUATE_SELECT"===e.type&&(l=(null==(t=s.cloneItem.scoreConfigs)?void 0:t.scoreRules)||[]),s.curOptions=l,h()})(e)}),{immediate:!0}),()=>{var t;return i(o("n-select"),{value:e.form[e.item.val_key],"onUpdate:value":[t=>e.form[e.item.val_key]=t,O],filterable:!0,clearable:!0,placeholder:(null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.147"))||"请选择","value-field":m.value,"label-field":g.value,multiple:v.value,disabled:e.isLock,loading:s.fetching,options:s.curOptions,remote:p.value,onSearch:f,"onUpdate:show":y},{empty:()=>s.fetching?i(r,null,null):i(u,null,null)})}}});export{s as default};
@@ -1 +1 @@
1
- import{defineComponent as e,ref as l,computed as i,createVNode as t,createTextVNode as a,resolveComponent as n,Fragment as o}from"vue";import{NButton as s,NIcon as c,NSpace as r,useDialog as m}from"naive-ui";import u from"./standard-modal.js";import p from"./sign-com.js";import{EyeOutline as v,TrashOutline as d}from"@vicons/ionicons5";import{api as g}from"v-viewer";var f=e({name:"RSign",components:{NButton:s,NIcon:c,NSpace:r,StandardModal:u,SignCom:p},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1}},emits:["scaleChange"],setup(e,s){const r=l(null),u=l(!1),p=l([]),f=m(),k=i((()=>{var l,i;return(null==(i=null==(l=e.item)?void 0:l.setting)?void 0:i.limitPic)||1})),C=i((()=>p.value.length<k.value&&!e.isLock));(()=>{const l=e.form[e.item.val_key];l&&Array.isArray(l)&&l.length&&(p.value=l)})();const h=()=>{u.value=!1},y=()=>{r.value.reset()},b=()=>{r.value.generate().then((l=>{console.log(l),p.value.push(l),s.emit("scaleChange",p.value,e.item),h()})).catch((e=>{console.log(e)}))},w=()=>{e.isLock||(u.value=!0)},x=()=>t("div",{class:"sigan-content-wrap"},[p.value.map(((l,i)=>t("div",{class:"sign-item"},[t("img",{src:l.url},null),t("div",null,[t(c,{component:v,onClick:()=>(e=>{const l=p.value.map((e=>e.url)).filter(Boolean);l.length&&g({images:l,options:{toolbar:!0,initialViewIndex:e}})})(i)},null),!e.isLock&&t(c,{component:d,onClick:()=>(l=>{e.isLock||f.warning({title:"提示",content:"确认要删除签名吗?",positiveText:"确定",negativeText:"取消",maskClosable:!1,closable:!1,positiveButtonProps:{type:"primary"},onPositiveClick:()=>{p.value.splice(l,1),s.emit("scaleChange",p.value,e.item)},onNegativeClick(){}})})(i)},null)])]))),C.value&&t("div",{class:"add-sign-wrap",onClick:w},[t("i",{class:"scale-view-iconfont icon-scale-view-qianming"},null),t("span",null,[a("添加签名")])])]),L=()=>t(n("standard-modal"),{class:"r-sign-modal",visible:u.value,title:e.item.title,modalWidth:"652px",modalHeight:"476px",handleOk:b,cancel:h},{default:()=>t(n("sign-com"),{ref:r,isCrop:!0},null),action:()=>t(o,null,[t(n("n-space"),null,{default:()=>[t(n("n-button"),{size:"small",onClick:h},{default:()=>[a("取消")]}),t(n("n-button"),{size:"small",onClick:y,type:"primary"},{default:()=>[a("重签")]}),t(n("n-button"),{size:"small",onClick:b,type:"primary"},{default:()=>[a("确认")]})]})])});return()=>t("div",{class:"c-sign-wrap"},[x(),L()])}});export{f as default};
1
+ import{defineComponent as e,ref as l,computed as n,createVNode as i,createTextVNode as a,resolveComponent as o,Fragment as t}from"vue";import{NButton as s,NIcon as c,NSpace as u,useDialog as r}from"naive-ui";import d from"./standard-modal.js";import m from"./sign-com.js";import{EyeOutline as v,TrashOutline as p}from"@vicons/ionicons5";import{api as g}from"v-viewer";var w=e({name:"RSign",components:{NButton:s,NIcon:c,NSpace:u,StandardModal:d,SignCom:m},props:{form:{type:Object,default:()=>({})},item:{type:Object,default:()=>({})},isLock:{type:Boolean,default:!1}},emits:["scaleChange"],setup(e,s){const u=l(null),d=l(!1),m=l([]),w=r(),f=n((()=>{var l,n;return(null==(n=null==(l=e.item)?void 0:l.setting)?void 0:n.limitPic)||1})),C=n((()=>m.value.length<f.value&&!e.isLock));(()=>{const l=e.form[e.item.val_key];l&&Array.isArray(l)&&l.length&&(m.value=l)})();const k=()=>{d.value=!1},y=()=>{u.value.reset()},h=()=>{u.value.generate().then((l=>{console.log(l),m.value.push(l),s.emit("scaleChange",m.value,e.item),k()})).catch((e=>{console.log(e)}))},b=()=>{e.isLock||(d.value=!0)},L=()=>i("div",{class:"sigan-content-wrap"},[m.value.map(((l,n)=>i("div",{class:"sign-item"},[i("img",{src:l.url},null),i("div",null,[i(c,{component:v,onClick:()=>(e=>{const l=m.value.map((e=>e.url)).filter(Boolean);l.length&&g({images:l,options:{toolbar:!0,initialViewIndex:e}})})(n)},null),!e.isLock&&i(c,{component:p,onClick:()=>(l=>{var n,i;e.isLock||w.warning({title:"提示",content:"确认要删除签名吗?",positiveText:(null==(n=window.getLanguageByCode)?void 0:n.call(window,"10010.1.33"))||"确定",negativeText:(null==(i=window.getLanguageByCode)?void 0:i.call(window,"10010.1.32"))||"取消",maskClosable:!1,closable:!1,positiveButtonProps:{type:"primary"},onPositiveClick:()=>{m.value.splice(l,1),s.emit("scaleChange",m.value,e.item)},onNegativeClick(){}})})(n)},null)])]))),C.value&&i("div",{class:"add-sign-wrap",onClick:b},[i("i",{class:"scale-view-iconfont icon-scale-view-qianming"},null),i("span",null,[a("添加签名")])])]),B=()=>i(o("standard-modal"),{class:"r-sign-modal",visible:d.value,title:e.item.title,modalWidth:"652px",modalHeight:"476px",handleOk:h,cancel:k},{default:()=>i(o("sign-com"),{ref:u,isCrop:!0},null),action:()=>i(t,null,[i(o("n-space"),null,{default:()=>[i(o("n-button"),{size:"small",onClick:k},{default:()=>{var e;return[a((null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.32"))||"取消")]}}),i(o("n-button"),{size:"small",onClick:y,type:"primary"},{default:()=>[a("重签")]}),i(o("n-button"),{size:"small",onClick:h,type:"primary"},{default:()=>{var e;return[a((null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.428"))||"确认")]}})]})])});return()=>i("div",{class:"c-sign-wrap"},[L(),B()])}});export{w as default};
@@ -1 +1 @@
1
- import{defineComponent as e,computed as i,reactive as t,ref as l,createVNode as a,resolveComponent as n}from"vue";import{NModal as o,NButton as s,NTooltip as d}from"naive-ui";var c=e({name:"StandardModal",components:{NModal:o,NButton:s,NTooltip:d},props:{title:{type:[Function,String],default:""},changeSize:{type:Boolean,default:!1},closable:{type:Boolean,default:!0},modalWidth:{type:String,default:""},modalHeight:{type:String,default:""},handleOk:{type:Function,default:()=>({})},cancel:{type:Function,default:()=>({})},visible:{type:Boolean,default:!1}},emits:["update:visible","onClose"],setup(e,o){const s=i((()=>e.modalWidth||"50vw")),d=i((()=>e.modalHeight||"50vh")),c=t({modalWidth:s.value,modalHeight:d.value,maxHeight:"620px",isChangeWindow:!1}),u=l(!1),h=()=>{e.handleOk()},v=()=>{e.cancel(),o.emit("update:visible",!1)},g=()=>{const i=null==e?void 0:e.title,t=typeof i;return a("div",{class:"n-dialog__title-content"},["string"===t?a("div",null,[i]):null,"function"===t?a("div",null,[i()]):null,a("div",{class:"svg-wrap"},[e.changeSize?a("i",{onClick:()=>(document.body.clientHeight,void Object.assign(c,{isChangeWindow:!c.isChangeWindow,modalWidth:c.modalWidth===s.value?"100vw":s.value,modalHeight:c.modalHeight===d.value?"100vh":d.value})),class:u.value?"scale-view-iconfont icon-scale-view-menzhenyishengzhanxitongtubiaozuixiaohua2":"scale-view-iconfont icon-scale-view-menzhenyishengzhanxitongtubiaozuidahua"},null):null,e.closable?a("i",{class:"scale-view-iconfont icon-scale-view-menzhenyishengzhanxitongtubiaoguanbi",onClick:()=>v()},null):null])])};return()=>(()=>{const i={...o.slots};return i.header||(i.header=g),a(n("n-modal"),{class:"c-scale-modal-container",show:e.visible,"mask-closable":!1,"show-icon":!1,closable:!1,style:{width:c.modalWidth,height:c.modalHeight},preset:"dialog","positive-text":"确认","negative-text":"取消","on-positive-click":h,"on-negative-click":v,positiveButtonProps:{type:"primary"}},{...i})})()}});export{c as default};
1
+ import{defineComponent as e,computed as i,reactive as l,ref as n,createVNode as t,resolveComponent as a}from"vue";import{NModal as o,NButton as d,NTooltip as s}from"naive-ui";var u=e({name:"StandardModal",components:{NModal:o,NButton:d,NTooltip:s},props:{title:{type:[Function,String],default:""},changeSize:{type:Boolean,default:!1},closable:{type:Boolean,default:!0},modalWidth:{type:String,default:""},modalHeight:{type:String,default:""},handleOk:{type:Function,default:()=>({})},cancel:{type:Function,default:()=>({})},visible:{type:Boolean,default:!1}},emits:["update:visible","onClose"],setup(e,o){const d=i((()=>e.modalWidth||"50vw")),s=i((()=>e.modalHeight||"50vh")),u=l({modalWidth:d.value,modalHeight:s.value,maxHeight:"620px",isChangeWindow:!1}),c=n(!1),h=()=>{e.handleOk()},v=()=>{e.cancel(),o.emit("update:visible",!1)},g=()=>{const i=null==e?void 0:e.title,l=typeof i;return t("div",{class:"n-dialog__title-content"},["string"===l?t("div",null,[i]):null,"function"===l?t("div",null,[i()]):null,t("div",{class:"svg-wrap"},[e.changeSize?t("i",{onClick:()=>(document.body.clientHeight,void Object.assign(u,{isChangeWindow:!u.isChangeWindow,modalWidth:u.modalWidth===d.value?"100vw":d.value,modalHeight:u.modalHeight===s.value?"100vh":s.value})),class:c.value?"scale-view-iconfont icon-scale-view-menzhenyishengzhanxitongtubiaozuixiaohua2":"scale-view-iconfont icon-scale-view-menzhenyishengzhanxitongtubiaozuidahua"},null):null,e.closable?t("i",{class:"scale-view-iconfont icon-scale-view-menzhenyishengzhanxitongtubiaoguanbi",onClick:()=>v()},null):null])])};return()=>(()=>{var i,l;const n={...o.slots};return n.header||(n.header=g),t(a("n-modal"),{class:"c-scale-modal-container",show:e.visible,"mask-closable":!1,"show-icon":!1,closable:!1,style:{width:u.modalWidth,height:u.modalHeight},preset:"dialog","positive-text":(null==(i=window.getLanguageByCode)?void 0:i.call(window,"10010.1.428"))||"确认","negative-text":(null==(l=window.getLanguageByCode)?void 0:l.call(window,"10010.1.32"))||"取消","on-positive-click":h,"on-negative-click":v,positiveButtonProps:{type:"primary"}},{...n})})()}});export{u as default};
@@ -1 +1 @@
1
- import{computed as e}from"vue";import{isEvaluation as t}from"../utils/judge-types.js";import"xe-utils";import a from"moment";import i from"../../../../shared/utils/vexutilsExpand.js";import{componentMapStr as n}from"./use-component.js";const o=(o,l,r)=>{const{query:s,scaleViewDom:u}=r,v=(new Date).getTime(),c=e((()=>{var e,t;return null==(t=null==(e=l.originConfig)?void 0:e.otherSetting)?void 0:t.desLocation})),d=e((()=>{var e,t;return null==(t=null==(e=l.originConfig)?void 0:e.otherSetting)?void 0:t.desContent})),m=e((()=>"start"===c.value&&!!d.value)),p=e((()=>"end"===c.value&&!!d.value)),g=e((()=>{var e;return s.importId||(null==(e=o.params)?void 0:e.importId)})),f=e((()=>1==(null==s?void 0:s.formBoldOpen))),h=e((()=>e=>{var a;return!g.value&&(!!t(e.type)&&(1==(null==s?void 0:s.evatip)||1==(null==(a=o.params)?void 0:a.evatip)))})),S=e((()=>{var e;return(null==(e=l.config)?void 0:e.evaluateResultSetting)||{}})),C=e((()=>{const{evaluateTime:e}=S.value;return+e})),E=e((()=>{var e;return null==(e=S.value)?void 0:e.evaluateStartTime})),O=e((()=>{const e=new Date(E.value);return!!i.isValidDate(e)&&e})),w=e((()=>{const{evaluetaResSituation:e}=S.value||{};return e})),L=e((()=>{const{evaluateZeroTip:e}=S.value||{};return e})),y=e((()=>{if(!E.value||!C.value)return!1;if(!O.value)return!1;const e=a(E.value).add(C.value,"minutes").valueOf();return v>=e})),b=e((()=>{const e=O.value;if(!e)return!1;const t=a(e).valueOf();return v<t})),B=e((()=>e=>{const t=e.required;return o.styleSetting&&Object.keys(o.styleSetting).length&&"formBoldOpen"in o.styleSetting?t&&o.styleSetting.formBoldOpen:t&&f.value})),R=e((()=>{let e=l.fontSize;if(!e||"S"===e)return;e={L:"large",M:"medium",XS:"extrasmall"}[e];const t=e&&(null==o?void 0:o.fontSizeObj[e])||1,a=Math.floor(100/t*1e4)/1e4;return{width:`${a}%`,height:`${a}%`,transform:`scale(${t})`}})),T=e((()=>!("customList"==o.type&&!o.noBtn)&&!(!o.noBtn&&!o.hideBtn))),k=e((()=>e=>ne(e))),A=e((()=>e=>{var a;const{type:i}=e||{},n=!1===(null==(a=l.config)?void 0:a.autoQuestionNumber)?e.showTitle:`${e.softcode}、${e.showTitle}`;if(!t(i))return n;const o=le(e);return o||L.value?`${n}&nbsp;<span style="color:#2d7aff;" class="score-i">${o}</span>`:n})),j=e((()=>{const{config:e}=l;return!g.value&&(!(!e||!Object.keys(e).length)&&"totalScore"in e)})),_=e((()=>{var e;return(null==(e=o.ids)?void 0:e.guage_id)&&o.noBtn})),U=e((()=>{const e=o.params||{};if(!("skipCover"in e))return!1;return e.skipCover&&!b.value&&!y.value})),F=e((()=>_.value||l.isFinished&&!g.value||o.noBtn||o.hideBtn)),D=e((()=>l.showEvaluatePage&&l.showEvaluateSettingWrap&&!F.value&&!U.value)),P=e((()=>!j.value&&!D.value&&l.showEvaluateCountdownWrap&&!F.value)),V=e((()=>{const{evaluateResultSetting:e={}}=l.config;return(Object.values(e).filter((e=>{if(e)return!0}))||[]).length})),x=e((()=>l.paramsEvaluate&&Object.keys(l.paramsEvaluate).length)),$=e((()=>{const e=window.location.search||window.location.hash;if(!e)return;const t=["evaname","evadesc","evast","evadur","evaan","evasit","evaztip"].find((t=>e.includes(t)));return l.paramsEvaluate||t})),I=e((()=>{var e;return 1==s.isEdit||1==(null==(e=o.params)?void 0:e.isEdit)||g.value})),N=e((()=>1==l.isFinished&&I.value)),K=e((()=>V.value||$.value?!o.noBtn&&!o.hideBtn&&(!l.isFinished||I.value):!o.noBtn&&!o.hideBtn)),M=e((()=>K.value&&"guage"!==o.sourceType)),q=e((()=>K.value&&!o.isLock)),J=e((()=>o.hasExtendBtn?!o.printingHideBtn:M.value||q.value)),z=e((()=>V.value||$.value?!!o.hideBtn||!!o.isLock||l.isFinished&&!I.value:!!o.hideBtn||!!o.isLock)),H=e((()=>e=>({EVALUATE_RADIO_BLOCK:"单选",EVALUATE_CHECKBOX_BLOCK:"多选"}[e.type]))),X=e((()=>e=>{var t;if(N.value)return!1;const{evaluateAnswer:n,checkAnswerMode:o,evaluateStartTime:r,evaluateTime:s}=(null==(t=l.config)?void 0:t.evaluateResultSetting)||{},u=(null==e?void 0:e.scoreConfigs)||0,v=n&&l.isFinished&&["EVALUATE_RADIO_BLOCK","EVALUATE_CHECKBOX_BLOCK","EVALUATE_SELECT","EVALUATE_INPUT"].includes(e.type)&&u;if(!r||!s||o&&1==o)return v;if(!i.isValidDate(new Date(r)))return v;const c=a(r).add(s,"minutes").diff(a(),"seconds",!0);return v&&c<=0})),Q=e((()=>"customList"===o.type?"保存":"提交")),W=e((()=>({getSelectOptions:o.getSelectOptions,getSearchOptions:o.getSearchOptions,openType:o.openType}))),Z=e((()=>({getCascadeOptions:o.getCascadeOptions}))),G=e((()=>({uploadPictureUrl:o.uploadPictureUrl,uploadFileUrl:o.uploadFileUrl}))),Y=e((()=>({ak:o.ak}))),ee=e((()=>({source:"guage",getChunkUploadConfig:o.getChunkUploadConfig}))),te=e((()=>({selectedList:l.labelSelectedList,selectedListObj:l.labelSelectedListObj,getLabelList:o.getLabelList,deleteLabel:o.deleteLabel,saveLabelItem:o.saveLabelItem,sourceType:o.sourceType}))),ae={RSelectCom:W.value,RCascaderCom:Z.value,RUploadCom:G.value,RMapCom:Y.value,RVodChunkUploadCom:ee.value},ie=e((()=>(e,t)=>{var a;const i=n[e.type],o=ae[i]||{},r={form:l.form,item:e,index:t,isLock:z.value,...o};return"RVodChunkUploadCom"===i&&Object.assign(r,{formData:e,limitNum:(null==(a=e.setting)?void 0:a.limitPic)||1,defFileList:l.form[e.val_key]}),"RMapCom"===i&&Object.assign(r,{locationProp:l.form[e.val_key]}),"CSelectLabelCom"===i&&(Object.assign(r,{...te.value}),delete r.form,delete r.index),r})),ne=(e,t)=>{if(e.hide)return!1;const{form:a={},formArray:n=[]}=l;let o={};if(t){let t=e.setting;if(e.setting&&i.isJSON(e.setting)&&(t=JSON.parse(e.setting)),o=i.isString(t.callbackCondition)?JSON.parse(t.callbackCondition):t.callbackCondition,!o||!o.condition||!o.condition.length)return!0}else o=i.isString(e.relationLogic)?JSON.parse(e.relationLogic):e.relationLogic;if(!o||!Object.keys(o).length)return!0;const{relation_logic_is:r,condition:s,relation_logic:u}=o;if(r){const t=s.map((e=>{const t=n.filter((t=>t.seq==e.subject_seq))[0],o=oe(t);return i.isArray(a[o])?a[o].some((t=>e.value.includes(t))):e.value.includes(a[o])}));e.isShow="OR"==u?t.some((e=>e)):"AND"==u?t.every((e=>e)):t[0]}return e.isShow},oe=e=>e.databaseTitle||e.title,le=e=>{const{maxScore:t=0,minScore:a=0,scoreType:i}=e.scoreConfigs||{};return"eachOptionScore"===i&&a<0?`(${a}-${t}分)`:t||L.value?`(${t}分)`:void 0},re=e((()=>{var e;return{formArray:l.formArray,evaluateResultConfig:(null==(e=l.config)?void 0:e.evaluateResultConfig)||{},evaluateResultSetting:S.value,isFinished:l.isFinished,maxScore:l.maxScore,skipCover:U.value}})),se=e((()=>{var e;return{formArray:l.formArray,evaluateResultConfig:(null==(e=l.config)?void 0:e.evaluateResultConfig)||{},evaluateResultSetting:S.value,form:l.form,isFinished:l.isFinished,currentTime:l.currentTime,showEvaluateCountdown:l.showEvaluateCountdown,isEvaluetaResSituation:w.value,evaResultObj:l.evaResultObj,scaleViewDom:u.value}}));return{showEvatip:h,isFormBoldOpen:B,scaleStyle:R,handlePageClass:T,isShowItem:k,handleShowQuestionNumber:A,hasScore:j,isPreviewScale:_,showEvaluateEntry:D,showEvaluateCoundownPage:P,hasEvaluateResultSetting:V,hasparamsEvaluate:x,hasDefault:$,showScaleFooter:J,isCancelBtn:M,isSaveBtn:q,componentDisable:z,showEvaluateLabel:H,showAnswerParse:X,tipMsg:Q,propsConfig:ie,showEvent:ne,formKey:oe,evaluatePageProps:re,evaluateCountdownProps:se,skipCover:U,scaleEdit:N,isEvaluetaResSituation:w,disableEdit:F,isImportScale:g,desStart:m,desEnd:p,desContent:d}};export{o as ScaleViewComputed};
1
+ import{computed as e,toRef as t}from"vue";import{isEvaluation as a}from"../utils/judge-types.js";import"xe-utils";import n from"moment";import i from"../../../../shared/utils/vexutilsExpand.js";import{componentMapStr as o}from"./use-component.js";const l=(l,r,s)=>{const{query:u,scaleViewDom:v}=s,d=(new Date).getTime(),c=e((()=>{var e,t;return null==(t=null==(e=r.originConfig)?void 0:e.otherSetting)?void 0:t.desLocation})),m=e((()=>{var e,t;return null==(t=null==(e=r.originConfig)?void 0:e.otherSetting)?void 0:t.desContent})),g=e((()=>"start"===c.value&&!!m.value)),p=e((()=>"end"===c.value&&!!m.value)),f=e((()=>{var e;return u.importId||(null==(e=l.params)?void 0:e.importId)})),h=e((()=>1==(null==u?void 0:u.formBoldOpen))),C=e((()=>e=>{var t;return!f.value&&(!!a(e.type)&&(1==(null==u?void 0:u.evatip)||1==(null==(t=l.params)?void 0:t.evatip)))})),S=e((()=>{var e;return(null==(e=r.config)?void 0:e.evaluateResultSetting)||{}})),w=e((()=>{const{evaluateTime:e}=S.value;return+e})),E=e((()=>{var e;return null==(e=S.value)?void 0:e.evaluateStartTime})),L=e((()=>{const e=new Date(E.value);return!!i.isValidDate(e)&&e})),y=e((()=>{const{evaluetaResSituation:e}=S.value||{};return e})),O=e((()=>{const{evaluateZeroTip:e}=S.value||{};return e})),b=e((()=>{if(!E.value||!w.value)return!1;if(!L.value)return!1;const e=n(E.value).add(w.value,"minutes").valueOf();return d>=e})),B=e((()=>{const e=L.value;if(!e)return!1;const t=n(e).valueOf();return d<t})),R=e((()=>e=>{const t=e.required;return l.styleSetting&&Object.keys(l.styleSetting).length&&"formBoldOpen"in l.styleSetting?t&&l.styleSetting.formBoldOpen:t&&h.value})),k=e((()=>{let e=r.fontSize;if(!e||"S"===e)return;e={L:"large",M:"medium",XS:"extrasmall"}[e];const t=e&&(null==l?void 0:l.fontSizeObj[e])||1,a=Math.floor(100/t*1e4)/1e4;return{width:`${a}%`,height:`${a}%`,transform:`scale(${t})`}})),T=e((()=>!("customList"==l.type&&!l.noBtn)&&!(!l.noBtn&&!l.hideBtn))),A=e((()=>e=>re(e))),P=e((()=>e=>{var t;const{type:n}=e||{},i=!1===(null==(t=r.config)?void 0:t.autoQuestionNumber)?e.showTitle:`${e.softcode}、${e.showTitle}`;if(!a(n))return i;const o=ue(e);return o||O.value?`${i}&nbsp;<span style="color:#2d7aff;" class="score-i">${o}</span>`:i})),j=e((()=>{const{config:e}=r;return!f.value&&(!(!e||!Object.keys(e).length)&&"totalScore"in e)})),_=e((()=>{var e;return(null==(e=l.ids)?void 0:e.guage_id)&&l.noBtn})),U=e((()=>{const e=l.params||{};if(!("skipCover"in e))return!1;return e.skipCover&&!B.value&&!b.value})),F=e((()=>_.value||r.isFinished&&!f.value||l.noBtn||l.hideBtn)),D=e((()=>r.showEvaluatePage&&r.showEvaluateSettingWrap&&!F.value&&!U.value)),x=e((()=>!j.value&&!D.value&&r.showEvaluateCountdownWrap&&!F.value)),V=e((()=>{const{evaluateResultSetting:e={}}=r.config;return(Object.values(e).filter((e=>{if(e)return!0}))||[]).length})),I=e((()=>r.paramsEvaluate&&Object.keys(r.paramsEvaluate).length)),$=e((()=>{const e=window.location.search||window.location.hash;if(!e)return;const t=["evaname","evadesc","evast","evadur","evaan","evasit","evaztip"].find((t=>e.includes(t)));return r.paramsEvaluate||t})),N=e((()=>{var e;return 1==u.isEdit||1==(null==(e=l.params)?void 0:e.isEdit)||f.value})),K=e((()=>1==r.isFinished&&N.value)),M=e((()=>V.value||$.value?!l.noBtn&&!l.hideBtn&&(!r.isFinished||N.value):!l.noBtn&&!l.hideBtn)),q=e((()=>M.value&&"guage"!==l.sourceType)),G=e((()=>M.value&&!l.isLock)),J=e((()=>l.hasExtendBtn?!l.printingHideBtn:q.value||G.value)),z=e((()=>V.value||$.value?!!l.hideBtn||!!l.isLock||r.isFinished&&!N.value:!!l.hideBtn||!!l.isLock)),H=e((()=>e=>{var t,a;return{EVALUATE_RADIO_BLOCK:(null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.298"))||"单选",EVALUATE_CHECKBOX_BLOCK:(null==(a=window.getLanguageByCode)?void 0:a.call(window,"10010.1.100"))||"多选"}[e.type]})),X=e((()=>e=>{var t;if(K.value)return!1;const{evaluateAnswer:a,checkAnswerMode:o,evaluateStartTime:l,evaluateTime:s}=(null==(t=r.config)?void 0:t.evaluateResultSetting)||{},u=(null==e?void 0:e.scoreConfigs)||0,v=a&&r.isFinished&&["EVALUATE_RADIO_BLOCK","EVALUATE_CHECKBOX_BLOCK","EVALUATE_SELECT","EVALUATE_INPUT"].includes(e.type)&&u;if(!l||!s||o&&1==o)return v;if(!i.isValidDate(new Date(l)))return v;const d=n(l).add(s,"minutes").diff(n(),"seconds",!0);return v&&d<=0})),Q=e((()=>{var e;return"customList"===l.type?(null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.244"))||"保存":"提交"})),W=e((()=>({getSelectOptions:l.getSelectOptions,getSearchOptions:l.getSearchOptions,openType:l.openType}))),Z=e((()=>({getCascadeOptions:l.getCascadeOptions}))),Y=e((()=>({uploadPictureUrl:l.uploadPictureUrl,uploadFileUrl:l.uploadFileUrl}))),ee=e((()=>({ak:l.ak}))),te=e((()=>({source:"guage",getChunkUploadConfig:l.getChunkUploadConfig}))),ae=e((()=>({selectedList:r.labelSelectedList,selectedListObj:r.labelSelectedListObj,getLabelList:l.getLabelList,deleteLabel:l.deleteLabel,saveLabelItem:l.saveLabelItem,sourceType:l.sourceType}))),ne=e((()=>({isGeneratePrintPdf:t(l,"isGeneratePrintPdf")}))),ie=e((()=>({isGeneratePrintPdf:t(l,"isGeneratePrintPdf")}))),oe={RSelectCom:W.value,RCascaderCom:Z.value,RUploadCom:Y.value,RMapCom:ee.value,RVodChunkUploadCom:te.value,RInputCom:ne.value,RRadioCom:ie.value,RCheckboxCom:ie.value},le=e((()=>(e,t)=>{var a;const n=o[e.type],i=oe[n]||{},l={form:r.form,item:e,index:t,isLock:z.value,...i};return"RVodChunkUploadCom"===n&&Object.assign(l,{formData:e,limitNum:(null==(a=e.setting)?void 0:a.limitPic)||1,defFileList:r.form[e.val_key]}),"RMapCom"===n&&Object.assign(l,{locationProp:r.form[e.val_key]}),"CSelectLabelCom"===n&&(Object.assign(l,{...ae.value}),delete l.form,delete l.index),l})),re=(e,t)=>{if(e.hide)return!1;const{form:a={},formArray:n=[]}=r;let o={};if(t){let t=e.setting;if(e.setting&&i.isJSON(e.setting)&&(t=JSON.parse(e.setting)),o=i.isString(t.callbackCondition)?JSON.parse(t.callbackCondition):t.callbackCondition,!o||!o.condition||!o.condition.length)return!0}else o=i.isString(e.relationLogic)?JSON.parse(e.relationLogic):e.relationLogic;if(!o||!Object.keys(o).length)return!0;const{relation_logic_is:l,condition:s,relation_logic:u}=o;if(l){const t=s.map((e=>{const t=n.filter((t=>t.seq==e.subject_seq))[0],o=se(t);return i.isArray(a[o])?a[o].some((t=>e.value.includes(t))):e.value.includes(a[o])}));e.isShow="OR"==u?t.some((e=>e)):"AND"==u?t.every((e=>e)):t[0]}return e.isShow},se=e=>e.databaseTitle||e.title,ue=e=>{const{maxScore:t=0,minScore:a=0,scoreType:n}=e.scoreConfigs||{};return"eachOptionScore"===n&&a<0?`(${a}-${t}分)`:t||O.value?`(${t}分)`:void 0},ve=e((()=>{var e;return{formArray:r.formArray,evaluateResultConfig:(null==(e=r.config)?void 0:e.evaluateResultConfig)||{},evaluateResultSetting:S.value,isFinished:r.isFinished,maxScore:r.maxScore,skipCover:U.value}})),de=e((()=>{var e;return{formArray:r.formArray,evaluateResultConfig:(null==(e=r.config)?void 0:e.evaluateResultConfig)||{},evaluateResultSetting:S.value,form:r.form,isFinished:r.isFinished,currentTime:r.currentTime,showEvaluateCountdown:r.showEvaluateCountdown,isEvaluetaResSituation:y.value,evaResultObj:r.evaResultObj,scaleViewDom:v.value}}));return{showEvatip:C,isFormBoldOpen:R,scaleStyle:k,handlePageClass:T,isShowItem:A,handleShowQuestionNumber:P,hasScore:j,isPreviewScale:_,showEvaluateEntry:D,showEvaluateCoundownPage:x,hasEvaluateResultSetting:V,hasparamsEvaluate:I,hasDefault:$,showScaleFooter:J,isCancelBtn:q,isSaveBtn:G,componentDisable:z,showEvaluateLabel:H,showAnswerParse:X,tipMsg:Q,propsConfig:le,showEvent:re,formKey:se,evaluatePageProps:ve,evaluateCountdownProps:de,skipCover:U,scaleEdit:K,isEvaluetaResSituation:y,disableEdit:F,isImportScale:f,desStart:g,desEnd:p,desContent:m}};export{l as ScaleViewComputed};
@@ -1 +1 @@
1
- import{h as e}from"vue";import{useDialog as a,useMessage as t}from"naive-ui";const i=(i,o,n,l)=>{const s=a(),r=t(),{nextLogicEvent:c,handleDynamicDataRelation:u,isPreviewScale:v,submitMethod:E,isEvaluetaResSituation:d,handleScoreJson:p,disableEdit:f}=l,C=a=>{s.warning({title:"提示",content:()=>e("div",{class:"evatip-container"},[e("span","答案解析:"),e("p",a)]),class:"c-evatip-dialog-wrap",showIcon:!1,positiveText:"确定",negativeText:"关闭",maskClosable:!1,onPositiveClick(){},onNegativeClick(){}})};return{scaleChange:(e,a,t)=>{const{choiceObj:n,isSetObj:l}=t||{};switch(a.type.includes("SELECT")||(o.form[a.val_key]=e),a.type){case"SELECT":case"EVALUATE_SELECT":{const{value:t,list:i=[]}=e;o.form[a.val_key]=t,c(e,a,o.formArray),u(i,a,o.formArray)}break;case"RADIO_BLOCK":case"CHECKBOX_BLOCK":l&&(o.choiceComObj[a.val_key]=n),c(e,a,o.formArray);break;case"EVALUATE_RADIO_BLOCK":case"EVALUATE_CHECKBOX_BLOCK":c(e,a,o.formArray);break;case"DATE":case"TIME":case"DATETIME":case"SEARCH_CASCADE":o.submitForm[a.val_key]=e}!f.value&&d.value&&a.type.includes("EVALUATE_")&&(async()=>{var e;const a=null==(e=i.scaleApiConfig)?void 0:e.getEvaluateResult;if(!a||"function"!=typeof a)return void r.error("getEvaluateResult Is not a function");const{guageId:t}=o.config;if(!t)return;const n=p(),l={gaugeId:t,scoreJson:JSON.stringify(n)},s=await a(l);if(!s)return;const c={...s};delete c.itemScoreMap,o.evaResultObj=c})()},labelChange:(e,a)=>{o.form[a.val_key]=((e,a)=>{const t=a.val_key;if(!e||!e.length)return t&&(o.labelSelectedListObj[t]=[]),{labelStr:"",labels:[]};const i=e||[],n=[],l=[];return i.forEach((e=>{l.push(e),n.push(e.labelName)})),o.labelSelectedList=i,t&&(o.labelSelectedListObj[t]=i),{labelStr:n.join(","),labels:l}})(e,a)},vodFileList:(e,a)=>{o.form[a.val_key]=e},writeGuage:e=>{o.showEvaluateSettingWrap=!1,o.showEvaluateCountdown=!!e,n("startWriteScale")},closeEvaluateCountdown:()=>{o.showEvaluateCountdown=!1,v.value||(o.banSubmit=!0,E(),s.warning({title:"温馨提示",content:"测评时间到了,结束测评!",maskClosable:!1,positiveText:"确定",onPositiveClick:()=>({})}))},showEvaTipModal:async e=>{var a;if(o.evatipMap[e.id])return void C(o.evatipMap[e.id]);const t="getSubjectAnswer",n=(null==(a=i.scaleApiConfig)?void 0:a[t])||null;if(!n||"function"!=typeof n)return void r.error(`${t} Is not a function`);const l=await n(e.id);l&&(o.evatipMap[e.id]||(o.evatipMap[e.id]=l,C(l)))}}};export{i as ScaleViewMethods};
1
+ import{h as e}from"vue";import{useDialog as a,useMessage as t}from"naive-ui";const i=(i,o,n,l)=>{const s=a(),r=t(),{nextLogicEvent:c,handleDynamicDataRelation:u,isPreviewScale:v,submitMethod:d,isEvaluetaResSituation:E,handleScoreJson:p,disableEdit:C}=l,g=a=>{var t;s.warning({title:"提示",content:()=>e("div",{class:"evatip-container"},[e("span","答案解析:"),e("p",a)]),class:"c-evatip-dialog-wrap",showIcon:!1,positiveText:(null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.33"))||"确定",negativeText:"关闭",maskClosable:!1,onPositiveClick(){},onNegativeClick(){}})};return{scaleChange:(e,a,t)=>{const{choiceObj:n,isSetObj:l}=t||{};switch(a.type.includes("SELECT")||(o.form[a.val_key]=e),a.type){case"SELECT":case"EVALUATE_SELECT":{const{value:t,list:i=[]}=e;o.form[a.val_key]=t,c(e,a,o.formArray),u(i,a,o.formArray)}break;case"RADIO_BLOCK":case"CHECKBOX_BLOCK":l&&(o.choiceComObj[a.val_key]=n),c(e,a,o.formArray);break;case"EVALUATE_RADIO_BLOCK":case"EVALUATE_CHECKBOX_BLOCK":c(e,a,o.formArray);break;case"DATE":case"TIME":case"DATETIME":case"SEARCH_CASCADE":o.submitForm[a.val_key]=e}!C.value&&E.value&&a.type.includes("EVALUATE_")&&(async()=>{var e;const a=null==(e=i.scaleApiConfig)?void 0:e.getEvaluateResult;if(!a||"function"!=typeof a)return void r.error("getEvaluateResult Is not a function");const{guageId:t}=o.config;if(!t)return;const n=p(),l={gaugeId:t,scoreJson:JSON.stringify(n)},s=await a(l);if(!s)return;const c={...s};delete c.itemScoreMap,o.evaResultObj=c})()},labelChange:(e,a)=>{o.form[a.val_key]=((e,a)=>{const t=a.val_key;if(!e||!e.length)return t&&(o.labelSelectedListObj[t]=[]),{labelStr:"",labels:[]};const i=e||[],n=[],l=[];return i.forEach((e=>{l.push(e),n.push(e.labelName)})),o.labelSelectedList=i,t&&(o.labelSelectedListObj[t]=i),{labelStr:n.join(","),labels:l}})(e,a)},vodFileList:(e,a)=>{o.form[a.val_key]=e},writeGuage:e=>{o.showEvaluateSettingWrap=!1,o.showEvaluateCountdown=!!e,n("startWriteScale")},closeEvaluateCountdown:()=>{var e;o.showEvaluateCountdown=!1,v.value||(o.banSubmit=!0,d(),s.warning({title:"温馨提示",content:"测评时间到了,结束测评!",maskClosable:!1,positiveText:(null==(e=window.getLanguageByCode)?void 0:e.call(window,"10010.1.33"))||"确定",onPositiveClick:()=>({})}))},showEvaTipModal:async e=>{var a;if(o.evatipMap[e.id])return void g(o.evatipMap[e.id]);const t="getSubjectAnswer",n=(null==(a=i.scaleApiConfig)?void 0:a[t])||null;if(!n||"function"!=typeof n)return void r.error(`${t} Is not a function`);const l=await n(e.id);l&&(o.evatipMap[e.id]||(o.evatipMap[e.id]=l,g(l)))}}};export{i as ScaleViewMethods};
@@ -107,4 +107,8 @@ export declare const ScaleViewProps: {
107
107
  type: BooleanConstructor;
108
108
  default: boolean;
109
109
  };
110
+ isGeneratePrintPdf: {
111
+ type: BooleanConstructor;
112
+ default: boolean;
113
+ };
110
114
  };
@@ -1 +1 @@
1
- const e={guageData:{type:Object,default:()=>({})},styleSetting:{type:Object,default:()=>({})},ids:{type:Object,default:()=>({guage_id:"",db_id:void 0})},params:{default:()=>({}),type:Object},noBtn:{type:[Boolean,String,Number],default:!1},hideBtn:{type:[Boolean,String,Number],default:!1},isLock:{type:[Boolean,String,Number],default:!1},type:{type:String,default:""},openType:{type:String,default:""},scaleApiConfig:{type:Object,default:()=>({})},getSelectOptions:{type:Function,default:()=>Promise.resolve([])},getSearchOptions:{type:Function,default:()=>Promise.resolve([])},getCascadeOptions:{type:Function,default:()=>Promise.resolve([])},getLabelList:{type:Function,default:()=>Promise.resolve([])},deleteLabel:{type:Function,default:()=>Promise.resolve({status:!0})},saveLabelItem:{type:Function,default:()=>Promise.resolve({status:!0})},uploadPictureUrl:{type:String,default:""},uploadFileUrl:{type:String,default:""},ak:{type:String,default:"KP3BZ-OAC3W-PY6RY-OJ6DV-JYKN3-H6F72"},sourceType:{type:String,default:""},getChunkUploadConfig:{type:Function,default:()=>Promise.resolve({})},fontSizeObj:{type:Object,default:()=>({large:1.25,medium:1.1,small:1,extrasmall:.9})},hasExtendBtn:{type:Boolean,default:!1},printingHideBtn:{type:Boolean,default:!1}};export{e as ScaleViewProps};
1
+ const e={guageData:{type:Object,default:()=>({})},styleSetting:{type:Object,default:()=>({})},ids:{type:Object,default:()=>({guage_id:"",db_id:void 0})},params:{default:()=>({}),type:Object},noBtn:{type:[Boolean,String,Number],default:!1},hideBtn:{type:[Boolean,String,Number],default:!1},isLock:{type:[Boolean,String,Number],default:!1},type:{type:String,default:""},openType:{type:String,default:""},scaleApiConfig:{type:Object,default:()=>({})},getSelectOptions:{type:Function,default:()=>Promise.resolve([])},getSearchOptions:{type:Function,default:()=>Promise.resolve([])},getCascadeOptions:{type:Function,default:()=>Promise.resolve([])},getLabelList:{type:Function,default:()=>Promise.resolve([])},deleteLabel:{type:Function,default:()=>Promise.resolve({status:!0})},saveLabelItem:{type:Function,default:()=>Promise.resolve({status:!0})},uploadPictureUrl:{type:String,default:""},uploadFileUrl:{type:String,default:""},ak:{type:String,default:"KP3BZ-OAC3W-PY6RY-OJ6DV-JYKN3-H6F72"},sourceType:{type:String,default:""},getChunkUploadConfig:{type:Function,default:()=>Promise.resolve({})},fontSizeObj:{type:Object,default:()=>({large:1.25,medium:1.1,small:1,extrasmall:.9})},hasExtendBtn:{type:Boolean,default:!1},printingHideBtn:{type:Boolean,default:!1},isGeneratePrintPdf:{type:Boolean,default:!1}};export{e as ScaleViewProps};
@@ -1 +1 @@
1
- import{h as t}from"vue";import{isSortItem as e,isOnlyOptions as i,isEvaluation as o,getQueryVariable as n}from"../utils/judge-types.js";import"xe-utils";import s from"moment";import r from"../../../../shared/utils/vexutilsExpand.js";import{ScaleViewComputed as a}from"./scaleview-computed.js";import{useDialog as l,useMessage as u}from"naive-ui";const f=(f,d,m,p)=>{const c=l(),g=u(),{formRef:v,countdownDom:y}=p,{showEvent:C,formKey:h,showEvaluateEntry:b,scaleEdit:O,showEvaluateCoundownPage:A,skipCover:S,hasScore:T}=a(f,d,p),E=()=>{const t=d.defaultFormArray.find((t=>"SPREAD_PARAMS"===t.type));if(t){r.isJSON(t.setting)&&(t.setting=JSON.parse(t.setting));const e=h(t);d.submitForm[e]=t.setting.spreadParams.domains.map((t=>{const e={};return"1"==t.valueType?e[t.name]=t.value:"2"==t.valueType&&(e[t.name]=n(t.value,d,f.params)),e}))}const e=d.defaultFormArray.find((t=>"CHECKBOX_BLOCK"==t.type));e&&Array.isArray(d.form[e.title])&&"customList"===f.type&&(d.form[e.title]=d.form[e.title].join(","));const i=I();let o;if("customList"===f.type)o={definedListId:f.ids.guage_id,dbId:f.ids.db_id,scoreJson:JSON.stringify(i)};else{const{guageId:t,randomId:e}=d.config;o=Object.assign(f.params,{guageId:t,scoreJson:JSON.stringify(i),randomId:e})}d.shareId&&(o.shareId=d.shareId);const s=d.defaultFormArray.find((t=>"SUCCESS_TIP"===t.type));if(s){const t=r.isJSON(s.setting)?JSON.parse(s.setting):s.setting;o.tipSetting=JSON.stringify({tipMode:t.tipMode,tipType:t.tipType,tipText:t.tipText,tipApi:t.tipApi})}const a=d.defaultFormArray.find((t=>"CALLBACK_INTERFACE"===t.type));let l=!1;a&&(l=C(a,!0));return{params:o,hasCallbackItem:a,isCallback:l}},x=(t,e)=>{if(!e.length)return e;const{type:o,options:n,scoreConfigs:s}=t;let r=n;if("EVALUATE_CHECKBOX_BLOCK"===o&&(r=(null==s?void 0:s.scoreRules)||[]),!r.length)return e;const a=i(o)?"key":"value",l=[];return r.forEach((t=>{const i=t[a];e.includes(i)&&l.push(i)})),l},I=()=>{const t=Object.assign({},d.form,d.submitForm),o={};if(!Object.keys(t).length)return{};for(const n in t){const r=d.formArray.find((t=>h(t)==n));if(n&&r){let a=n,l=t[n]?t[n]:null;if(r&&r.databaseTitle&&(a=r.databaseTitle),"customList"==f.type&&r&&r.setting&&1!=r.setting.startToStop&&t[n]&&"DATETIME"==r.type&&(r.setting&&"time"==r.setting.dateType&&t[n]&&(t[n]=s().format("YYYY-MM-DD ")+t[n]),r.setting&&"date"==r.setting.dateType&&t[n]&&(t[n]=s(t[n]).format("YYYY-MM-DD ")+s().format("HH:mm:ss"))),e(r)&&l&&(l=x(r,l),l=(null==l?void 0:l.length)?l:null),i(r.type)&&l){const{options:t}=r,e=r.val_key,i=d.choiceComObj[e];if("RADIO_BLOCK"===r.type&&l&&(l=j(l,t,i)),"CHECKBOX_BLOCK"===r.type&&(null==l?void 0:l.length)){l=w(l,t,i)}}o[a]=l}else o[n]=t[n]}return o},w=(t,e,i)=>{const o=[];let n,s=0;for(;s<t.length;s++){n=t[s];const r=e.find(((t,e)=>e+1===n));if(r&&!r.prefix&&!r.suffix){o.push(r.value);continue}const a=j(n,e,i);o.push(a)}return o},j=(t,e,i)=>{const{othersText:o,optionsPreSuffixObj:n={}}=i||{};if("other"===t)return o||"其他";const s=e.find(((e,i)=>i+1===t));if(!s)return;if(!s.prefix&&!s.suffix)return s.value;let r=n[t]||"";return s.prefix?r=s.prefix+r:r+=s.suffix,r},L=()=>new Promise((t=>{var e;null==(e=v.value)||e.validate((e=>{var i;if(e){console.log(e);const o=(null==(i=e[0])?void 0:i[0])||{};let n=o.field;const s=o.message,r=d.formArray.find((t=>t.databaseTitle===n));return r&&(n=r.title),g.error(n+s),t(!1),!1}{const e=E();t(e)}}))})),_=e=>{c.warning({title:"温馨提示",content:()=>t("div",{style:{paddingLeft:"30px"}},e),positiveText:"确定",negativeText:"取消",maskClosable:!1,closable:!1,positiveButtonProps:{type:"primary"},onPositiveClick:async()=>{const t=await L();m("onSubmit",t)},onNegativeClick(){}})};return{submitMethod:E,confirmSubmit:_,onSubmitForm:L,onSubmitData:()=>{var t;if(!d.formArray.find((t=>o(t.type))))return void _("确认要提交吗?");const{evaluateResultSetting:e}=d.config;if(!e||!Object.keys(e).length&&!b.value||O.value)return void _("确认要结束测评吗?");if("formIframe"==f.openType&&b.value)return void m("submitNoRequest");let i="确定要提前结束测评吗?";if(A.value&&(null==(t=y.value)?void 0:t.getCountdownObj)){const t=y.value.getCountdownObj(),{setAnswered:e,totalLen:o}=t;if(e<o)i="存在未作答的题目,确定要提前结束测评吗?";else{!(d.showEvaluateCountdown&&!S.value)&&(i="确认要结束测评吗?")}}S.value&&T.value&&(i="确认要结束测评吗?"),_(i)},handleScoreJson:I}};export{f as ScaleViewSubmit};
1
+ import{h as t}from"vue";import{isSortItem as e,isOnlyOptions as i,isEvaluation as o,getQueryVariable as n}from"../utils/judge-types.js";import"xe-utils";import s from"moment";import r from"../../../../shared/utils/vexutilsExpand.js";import{ScaleViewComputed as a}from"./scaleview-computed.js";import{useDialog as l,useMessage as u}from"naive-ui";const f=(f,d,m,p)=>{const c=l(),g=u(),{formRef:v,countdownDom:y}=p,{showEvent:C,formKey:h,showEvaluateEntry:b,scaleEdit:O,showEvaluateCoundownPage:w,skipCover:A,hasScore:S}=a(f,d,p),T=()=>{const t=d.defaultFormArray.find((t=>"SPREAD_PARAMS"===t.type));if(t){r.isJSON(t.setting)&&(t.setting=JSON.parse(t.setting));const e=h(t);d.submitForm[e]=t.setting.spreadParams.domains.map((t=>{const e={};return"1"==t.valueType?e[t.name]=t.value:"2"==t.valueType&&(e[t.name]=n(t.value,d,f.params)),e}))}const e=d.defaultFormArray.find((t=>"CHECKBOX_BLOCK"==t.type));e&&Array.isArray(d.form[e.title])&&"customList"===f.type&&(d.form[e.title]=d.form[e.title].join(","));const i=x();let o;if("customList"===f.type)o={definedListId:f.ids.guage_id,dbId:f.ids.db_id,scoreJson:JSON.stringify(i)};else{const{guageId:t,randomId:e}=d.config;o=Object.assign(f.params,{guageId:t,scoreJson:JSON.stringify(i),randomId:e})}d.shareId&&(o.shareId=d.shareId);const s=d.defaultFormArray.find((t=>"SUCCESS_TIP"===t.type));if(s){const t=r.isJSON(s.setting)?JSON.parse(s.setting):s.setting;o.tipSetting=JSON.stringify({tipMode:t.tipMode,tipType:t.tipType,tipText:t.tipText,tipApi:t.tipApi})}const a=d.defaultFormArray.find((t=>"CALLBACK_INTERFACE"===t.type));let l=!1;a&&(l=C(a,!0));return{params:o,hasCallbackItem:a,isCallback:l}},E=(t,e)=>{if(!e.length)return e;const{type:o,options:n,scoreConfigs:s}=t;let r=n;if("EVALUATE_CHECKBOX_BLOCK"===o&&(r=(null==s?void 0:s.scoreRules)||[]),!r.length)return e;const a=i(o)?"key":"value",l=[];return r.forEach((t=>{const i=t[a];e.includes(i)&&l.push(i)})),l},x=()=>{const t=Object.assign({},d.form,d.submitForm),o={};if(!Object.keys(t).length)return{};for(const n in t){const r=d.formArray.find((t=>h(t)==n));if(n&&r){let a=n,l=t[n]?t[n]:null;if(r&&r.databaseTitle&&(a=r.databaseTitle),"customList"==f.type&&r&&r.setting&&1!=r.setting.startToStop&&t[n]&&"DATETIME"==r.type&&(r.setting&&"time"==r.setting.dateType&&t[n]&&(t[n]=s().format("YYYY-MM-DD ")+t[n]),r.setting&&"date"==r.setting.dateType&&t[n]&&(t[n]=s(t[n]).format("YYYY-MM-DD ")+s().format("HH:mm:ss"))),e(r)&&l&&(l=E(r,l),l=(null==l?void 0:l.length)?l:null),i(r.type)&&l){const{options:t}=r,e=r.val_key,i=d.choiceComObj[e];if("RADIO_BLOCK"===r.type&&l&&(l=L(l,t,i)),"CHECKBOX_BLOCK"===r.type&&(null==l?void 0:l.length)){l=I(l,t,i)}}o[a]=l}else o[n]=t[n]}return o},I=(t,e,i)=>{const o=[];let n,s=0;for(;s<t.length;s++){n=t[s];const r=e.find(((t,e)=>e+1===n));if(r&&!r.prefix&&!r.suffix){o.push(r.value);continue}const a=L(n,e,i);o.push(a)}return o},L=(t,e,i)=>{const{othersText:o,optionsPreSuffixObj:n={}}=i||{};if("other"===t)return o||"其他";const s=e.find(((e,i)=>i+1===t));if(!s)return;if(!s.prefix&&!s.suffix)return s.value;let r=n[t]||"";return s.prefix?r=s.prefix+r:r+=s.suffix,r},j=()=>new Promise((t=>{var e;null==(e=v.value)||e.validate((e=>{var i;if(e){console.log(e);const o=(null==(i=e[0])?void 0:i[0])||{};let n=o.field;const s=o.message,r=d.formArray.find((t=>t.databaseTitle===n));return r&&(n=r.title),g.error(n+s),t(!1),!1}{const e=T();t(e)}}))})),B=e=>{var i,o;c.warning({title:"温馨提示",content:()=>t("div",{style:{paddingLeft:"30px"}},e),positiveText:(null==(i=window.getLanguageByCode)?void 0:i.call(window,"10010.1.33"))||"确定",negativeText:(null==(o=window.getLanguageByCode)?void 0:o.call(window,"10010.1.32"))||"取消",maskClosable:!1,closable:!1,positiveButtonProps:{type:"primary"},onPositiveClick:async()=>{const t=await j();m("onSubmit",t)},onNegativeClick(){}})};return{submitMethod:T,confirmSubmit:B,onSubmitForm:j,onSubmitData:()=>{var t;if(!d.formArray.find((t=>o(t.type))))return void B("确认要提交吗?");const{evaluateResultSetting:e}=d.config;if(!e||!Object.keys(e).length&&!b.value||O.value)return void B("确认要结束测评吗?");if("formIframe"==f.openType&&b.value)return void m("submitNoRequest");let i="确定要提前结束测评吗?";if(w.value&&(null==(t=y.value)?void 0:t.getCountdownObj)){const t=y.value.getCountdownObj(),{setAnswered:e,totalLen:o}=t;if(e<o)i="存在未作答的题目,确定要提前结束测评吗?";else{!(d.showEvaluateCountdown&&!A.value)&&(i="确认要结束测评吗?")}}A.value&&S.value&&(i="确认要结束测评吗?"),B(i)},handleScoreJson:x}};export{f as ScaleViewSubmit};
@@ -1 +1 @@
1
- import"xe-utils";import"moment";import e from"../../../../shared/utils/vexutilsExpand.js";import{ScaleViewComputed as r}from"./scaleview-computed.js";const t=(t,i,n)=>{const{formKey:s}=r(t,i,n),o=(e,r)=>{let{address:t}=r||{};return!!t||new Error("必填")},l=(e,r)=>{if(!r||!Object.keys(r).length)return new Error("必填");let{labelStr:t,labels:i=[]}=r;return!(!t||!i.length)||new Error("必填")},a=(e,r)=>{let t=(i=r,Object.prototype.toString.call(i));var i;if("[object Object]"==t){if(r&&Object.keys(r).length)return!0}else if("[object Array]"==t){if(r&&r.length)return!0}else if("[object Number]"==t){if(r||0===r)return!0}else if(r)return!0;return new Error("必填")},u=["LABEL","ADDRESS"];return{formatRules:r=>{const n={};return r.forEach((r=>{let c=r.val_key;if(n[c]=[],r.required&&!u.includes(r.type)&&n[c].push({required:r.required,message:"必填",trigger:"change",validator:a}),"MOBILE"==r.type&&r.validation)n[c].push({pattern:/^1[3456789]\d{9}$/,message:"格式错误",trigger:"blur"});else if("ID_CARD"==r.type&&r.validation)n[c].push({pattern:/^\d{6}(((19|20)\d{2}(0[1-9]|1[0-2])(0[1-9]|[1-2][0-9]|3[0-1])\d{3}([0-9]|x|X))|(\d{2}(0[1-9]|1[0-2])(0[1-9]|[1-2][0-9]|3[0-1])\d{3}))$/,message:"格式错误",trigger:"blur"});else if("ADDRESS"==r.type&&r.required)(r=>{let t={addressType:"province-city-district-address"};return t=e.isJSON(r.setting)?JSON.parse(r.setting):r.setting,t.addressType.includes("address")})(r)&&n[c].push({validator:o,trigger:"change"});else if("LABEL"==r.type&&r.required)n[c].push({validator:l,trigger:"change"});else if("DATETIME"==r.type&&"customList"==t.type){let t=(r=>{let t=r.setting;return e.isJSON(t)&&(t=JSON.parse(t)),t.dateMaxType})(r);if(!t)return;let i={1:"checkDateMaxCur",2:"checkDateMaxSet",3:"checkDateMaxOther"};n[c].push({validator:(e,n)=>i[t](e,n,r),trigger:"change"})}else"RADIO_BLOCK"===r.type?(i.choiceComObj[s(r)]={},n[c].push({validator:(e,t)=>((e,r,t)=>{if(!r)return!0;let{options:n}=t;if(!n.length||"other"===r)return!0;const o=s(t);let{optionsPreSuffixObj:l={}}=i.choiceComObj[o]||{},a=n.find(((e,t)=>t+1===r));if(!a||a.importability)return!0;if((a.prefix||a.suffix)&&!l[r])return new Error("请完善选项");return!0})(0,t,r),trigger:["change","blur"]})):"CHECKBOX_BLOCK"===r.type&&(i.choiceComObj[s(r)]={},n[c].push({validator:(e,t)=>((e,r,t)=>{if(!r||!r.length)return!0;let{options:n}=t;if(!n.length)return!0;let o,l=0,a=r.length;const u=s(t);let{optionsPreSuffixObj:c={}}=i.choiceComObj[u]||{};for(;l<a;l++){if(o=r[l],"other"===o)continue;let e=n.find(((e,r)=>r+1===o));if(e&&!e.importability&&(e.prefix||e.suffix)&&!c[o])return new Error("请完善选项")}return!0})(0,t,r),trigger:["change","blur"]}))})),n}}};export{t as ScaleViewValidate};
1
+ import"xe-utils";import"moment";import e from"../../../../shared/utils/vexutilsExpand.js";import{ScaleViewComputed as r}from"./scaleview-computed.js";const t=(t,i,n)=>{const{formKey:o}=r(t,i,n),l=(e,r)=>{var t;let{address:i}=r||{};return!!i||new Error((null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.248"))||"必填")},a=(e,r)=>{var t,i;if(!r||!Object.keys(r).length)return new Error((null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.248"))||"必填");let{labelStr:n,labels:o=[]}=r;return!(!n||!o.length)||new Error((null==(i=window.getLanguageByCode)?void 0:i.call(window,"10010.1.248"))||"必填")},s=(e,r)=>{var t;let i=(n=r,Object.prototype.toString.call(n));var n;if("[object Object]"==i){if(r&&Object.keys(r).length)return!0}else if("[object Array]"==i){if(r&&r.length)return!0}else if("[object Number]"==i){if(r||0===r)return!0}else if(r)return!0;return new Error((null==(t=window.getLanguageByCode)?void 0:t.call(window,"10010.1.248"))||"必填")},u=["LABEL","ADDRESS"];return{formatRules:r=>{const n={};return r.forEach((r=>{var d;let g=r.val_key;if(n[g]=[],r.required&&!u.includes(r.type)&&n[g].push({required:r.required,message:(null==(d=window.getLanguageByCode)?void 0:d.call(window,"10010.1.248"))||"必填",trigger:"change",validator:s}),"MOBILE"==r.type&&r.validation)n[g].push({pattern:/^1[3456789]\d{9}$/,message:"格式错误",trigger:"blur"});else if("ID_CARD"==r.type&&r.validation)n[g].push({pattern:/^\d{6}(((19|20)\d{2}(0[1-9]|1[0-2])(0[1-9]|[1-2][0-9]|3[0-1])\d{3}([0-9]|x|X))|(\d{2}(0[1-9]|1[0-2])(0[1-9]|[1-2][0-9]|3[0-1])\d{3}))$/,message:"格式错误",trigger:"blur"});else if("ADDRESS"==r.type&&r.required)(r=>{let t={addressType:"province-city-district-address"};return t=e.isJSON(r.setting)?JSON.parse(r.setting):r.setting,t.addressType.includes("address")})(r)&&n[g].push({validator:l,trigger:"change"});else if("LABEL"==r.type&&r.required)n[g].push({validator:a,trigger:"change"});else if("DATETIME"==r.type&&"customList"==t.type){let t=(r=>{let t=r.setting;return e.isJSON(t)&&(t=JSON.parse(t)),t.dateMaxType})(r);if(!t)return;let i={1:"checkDateMaxCur",2:"checkDateMaxSet",3:"checkDateMaxOther"};n[g].push({validator:(e,n)=>i[t](e,n,r),trigger:"change"})}else"RADIO_BLOCK"===r.type?(i.choiceComObj[o(r)]={},n[g].push({validator:(e,t)=>((e,r,t)=>{if(!r)return!0;let{options:n}=t;if(!n.length||"other"===r)return!0;const l=o(t);let{optionsPreSuffixObj:a={}}=i.choiceComObj[l]||{},s=n.find(((e,t)=>t+1===r));if(!s||s.importability)return!0;if((s.prefix||s.suffix)&&!a[r])return new Error("请完善选项");return!0})(0,t,r),trigger:["change","blur"]})):"CHECKBOX_BLOCK"===r.type&&(i.choiceComObj[o(r)]={},n[g].push({validator:(e,t)=>((e,r,t)=>{if(!r||!r.length)return!0;let{options:n}=t;if(!n.length)return!0;let l,a=0,s=r.length;const u=o(t);let{optionsPreSuffixObj:d={}}=i.choiceComObj[u]||{};for(;a<s;a++){if(l=r[a],"other"===l)continue;let e=n.find(((e,r)=>r+1===l));if(e&&!e.importability&&(e.prefix||e.suffix)&&!d[l])return new Error("请完善选项")}return!0})(0,t,r),trigger:["change","blur"]}))})),n}}};export{t as ScaleViewValidate};