ylyx-cli 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (402) hide show
  1. package/README.md +184 -0
  2. package/bin/ylyx.js +95 -0
  3. package/lib/generator.js +192 -0
  4. package/lib/index.js +113 -0
  5. package/lib/interactive.js +87 -0
  6. package/lib/remote.js +179 -0
  7. package/lib/template.js +174 -0
  8. package/lib/utils.js +134 -0
  9. package/package.json +56 -0
  10. package/templates/react-app/files/README.md +23 -0
  11. package/templates/react-app/files/package.json +29 -0
  12. package/templates/react-app/files/public/index.html +11 -0
  13. package/templates/react-app/files/src/App.css +15 -0
  14. package/templates/react-app/files/src/App.js +15 -0
  15. package/templates/react-app/files/src/index.css +10 -0
  16. package/templates/react-app/files/src/index.js +11 -0
  17. package/templates/react-app/template.json +12 -0
  18. package/templates/react-component/files/Component.module.css +5 -0
  19. package/templates/react-component/files/Component.tsx +31 -0
  20. package/templates/react-component/files/index.ts +2 -0
  21. package/templates/react-component/template.json +49 -0
  22. package/templates/vue-app/files/.editorconfig +14 -0
  23. package/templates/vue-app/files/.env.development +21 -0
  24. package/templates/vue-app/files/.env.production +18 -0
  25. package/templates/vue-app/files/.eslintignore +5 -0
  26. package/templates/vue-app/files/.eslintrc.js +267 -0
  27. package/templates/vue-app/files/.prettierignore +12 -0
  28. package/templates/vue-app/files/.travis.yml +5 -0
  29. package/templates/vue-app/files/.vscode/extensions.json +7 -0
  30. package/templates/vue-app/files/.vscode/settings.json +39 -0
  31. package/templates/vue-app/files/LICENSE +191 -0
  32. package/templates/vue-app/files/README.md +87 -0
  33. package/templates/vue-app/files/babel.config.js +11 -0
  34. package/templates/vue-app/files/jest.config.js +24 -0
  35. package/templates/vue-app/files/package.json +136 -0
  36. package/templates/vue-app/files/plopfile.js +7 -0
  37. package/templates/vue-app/files/postcss.config.js +5 -0
  38. package/templates/vue-app/files/prettier.config.js +36 -0
  39. package/templates/vue-app/files/public/default.js +26 -0
  40. package/templates/vue-app/files/public/favicon.ico +0 -0
  41. package/templates/vue-app/files/public/index.html +26 -0
  42. package/templates/vue-app/files/src/App.vue +54 -0
  43. package/templates/vue-app/files/src/api/bigDataV/index.js +198 -0
  44. package/templates/vue-app/files/src/api/data.js +42 -0
  45. package/templates/vue-app/files/src/api/dataArchive/index.js +186 -0
  46. package/templates/vue-app/files/src/api/generator/genConfig.js +16 -0
  47. package/templates/vue-app/files/src/api/generator/generator.js +32 -0
  48. package/templates/vue-app/files/src/api/indexManagement/index.js +39 -0
  49. package/templates/vue-app/files/src/api/institutionMonitor/index.js +396 -0
  50. package/templates/vue-app/files/src/api/institutionSet/index.js +120 -0
  51. package/templates/vue-app/files/src/api/login.js +44 -0
  52. package/templates/vue-app/files/src/api/selfStatistics/index.js +50 -0
  53. package/templates/vue-app/files/src/api/system/code.js +15 -0
  54. package/templates/vue-app/files/src/api/system/dict.js +34 -0
  55. package/templates/vue-app/files/src/api/system/dictDetail.js +52 -0
  56. package/templates/vue-app/files/src/api/system/equipment.js +35 -0
  57. package/templates/vue-app/files/src/api/system/examManage.js +49 -0
  58. package/templates/vue-app/files/src/api/system/examProject.js +48 -0
  59. package/templates/vue-app/files/src/api/system/hosModel.js +35 -0
  60. package/templates/vue-app/files/src/api/system/hospital.js +88 -0
  61. package/templates/vue-app/files/src/api/system/job.js +40 -0
  62. package/templates/vue-app/files/src/api/system/menu.js +67 -0
  63. package/templates/vue-app/files/src/api/system/model.js +42 -0
  64. package/templates/vue-app/files/src/api/system/risConfig.js +9 -0
  65. package/templates/vue-app/files/src/api/system/role.js +64 -0
  66. package/templates/vue-app/files/src/api/system/sysSet.js +19 -0
  67. package/templates/vue-app/files/src/api/system/timing.js +41 -0
  68. package/templates/vue-app/files/src/api/system/user.js +121 -0
  69. package/templates/vue-app/files/src/api/tools/alipay.js +25 -0
  70. package/templates/vue-app/files/src/api/tools/email.js +24 -0
  71. package/templates/vue-app/files/src/api/tools/localStorage.js +27 -0
  72. package/templates/vue-app/files/src/api/tools/qiniu.js +40 -0
  73. package/templates/vue-app/files/src/assets/401_images/401.gif +0 -0
  74. package/templates/vue-app/files/src/assets/404_images/404.png +0 -0
  75. package/templates/vue-app/files/src/assets/404_images/404_cloud.png +0 -0
  76. package/templates/vue-app/files/src/assets/css/font-awesome.css +2342 -0
  77. package/templates/vue-app/files/src/assets/css/font-awesome.min.css +2336 -0
  78. package/templates/vue-app/files/src/assets/fonts/FontAwesome.otf +0 -0
  79. package/templates/vue-app/files/src/assets/fonts/fontawesome-webfont.eot +0 -0
  80. package/templates/vue-app/files/src/assets/fonts/fontawesome-webfont.svg +2671 -0
  81. package/templates/vue-app/files/src/assets/fonts/fontawesome-webfont.ttf +0 -0
  82. package/templates/vue-app/files/src/assets/fonts/fontawesome-webfont.woff +0 -0
  83. package/templates/vue-app/files/src/assets/fonts/fontawesome-webfont.woff2 +0 -0
  84. package/templates/vue-app/files/src/assets/icons/index.js +9 -0
  85. package/templates/vue-app/files/src/assets/icons/svg/Steve-Jobs.svg +1 -0
  86. package/templates/vue-app/files/src/assets/icons/svg/achive.svg +1 -0
  87. package/templates/vue-app/files/src/assets/icons/svg/alipay.svg +1 -0
  88. package/templates/vue-app/files/src/assets/icons/svg/anq.svg +1 -0
  89. package/templates/vue-app/files/src/assets/icons/svg/app.svg +1 -0
  90. package/templates/vue-app/files/src/assets/icons/svg/archive.svg +1 -0
  91. package/templates/vue-app/files/src/assets/icons/svg/backup.svg +1 -0
  92. package/templates/vue-app/files/src/assets/icons/svg/chain.svg +1 -0
  93. package/templates/vue-app/files/src/assets/icons/svg/chart.svg +1 -0
  94. package/templates/vue-app/files/src/assets/icons/svg/codeConsole.svg +1 -0
  95. package/templates/vue-app/files/src/assets/icons/svg/dashboard.svg +1 -0
  96. package/templates/vue-app/files/src/assets/icons/svg/database.svg +1 -0
  97. package/templates/vue-app/files/src/assets/icons/svg/date.svg +1 -0
  98. package/templates/vue-app/files/src/assets/icons/svg/deploy.svg +1 -0
  99. package/templates/vue-app/files/src/assets/icons/svg/dept.svg +1 -0
  100. package/templates/vue-app/files/src/assets/icons/svg/dev.svg +1 -0
  101. package/templates/vue-app/files/src/assets/icons/svg/develop.svg +1 -0
  102. package/templates/vue-app/files/src/assets/icons/svg/dictionary.svg +1 -0
  103. package/templates/vue-app/files/src/assets/icons/svg/doc.svg +1 -0
  104. package/templates/vue-app/files/src/assets/icons/svg/download.svg +1 -0
  105. package/templates/vue-app/files/src/assets/icons/svg/edit.svg +1 -0
  106. package/templates/vue-app/files/src/assets/icons/svg/education.svg +1 -0
  107. package/templates/vue-app/files/src/assets/icons/svg/email.svg +1 -0
  108. package/templates/vue-app/files/src/assets/icons/svg/equSet.svg +1 -0
  109. package/templates/vue-app/files/src/assets/icons/svg/error.svg +1 -0
  110. package/templates/vue-app/files/src/assets/icons/svg/exit-fullscreen.svg +1 -0
  111. package/templates/vue-app/files/src/assets/icons/svg/fullscreen.svg +1 -0
  112. package/templates/vue-app/files/src/assets/icons/svg/fwb.svg +1 -0
  113. package/templates/vue-app/files/src/assets/icons/svg/github.svg +1 -0
  114. package/templates/vue-app/files/src/assets/icons/svg/goBack.svg +1 -0
  115. package/templates/vue-app/files/src/assets/icons/svg/gonggao.svg +1 -0
  116. package/templates/vue-app/files/src/assets/icons/svg/hospital.svg +2 -0
  117. package/templates/vue-app/files/src/assets/icons/svg/hospital1.svg +2 -0
  118. package/templates/vue-app/files/src/assets/icons/svg/hospitalTotal.svg +1 -0
  119. package/templates/vue-app/files/src/assets/icons/svg/icon.svg +1 -0
  120. package/templates/vue-app/files/src/assets/icons/svg/image.svg +1 -0
  121. package/templates/vue-app/files/src/assets/icons/svg/index.svg +1 -0
  122. package/templates/vue-app/files/src/assets/icons/svg/international.svg +1 -0
  123. package/templates/vue-app/files/src/assets/icons/svg/ipvisits.svg +1 -0
  124. package/templates/vue-app/files/src/assets/icons/svg/java.svg +1 -0
  125. package/templates/vue-app/files/src/assets/icons/svg/link.svg +1 -0
  126. package/templates/vue-app/files/src/assets/icons/svg/list.svg +1 -0
  127. package/templates/vue-app/files/src/assets/icons/svg/lock.svg +1 -0
  128. package/templates/vue-app/files/src/assets/icons/svg/log.svg +1 -0
  129. package/templates/vue-app/files/src/assets/icons/svg/login.svg +1 -0
  130. package/templates/vue-app/files/src/assets/icons/svg/loginOne.svg +35 -0
  131. package/templates/vue-app/files/src/assets/icons/svg/loginOneWhite.svg +19 -0
  132. package/templates/vue-app/files/src/assets/icons/svg/loginOr.svg +93 -0
  133. package/templates/vue-app/files/src/assets/icons/svg/loginUp.svg +96 -0
  134. package/templates/vue-app/files/src/assets/icons/svg/markdown.svg +1 -0
  135. package/templates/vue-app/files/src/assets/icons/svg/menu.svg +1 -0
  136. package/templates/vue-app/files/src/assets/icons/svg/message.svg +1 -0
  137. package/templates/vue-app/files/src/assets/icons/svg/mnt.svg +1 -0
  138. package/templates/vue-app/files/src/assets/icons/svg/money.svg +1 -0
  139. package/templates/vue-app/files/src/assets/icons/svg/monitor.svg +1 -0
  140. package/templates/vue-app/files/src/assets/icons/svg/nested.svg +1 -0
  141. package/templates/vue-app/files/src/assets/icons/svg/network.svg +1 -0
  142. package/templates/vue-app/files/src/assets/icons/svg/offline.svg +1 -0
  143. package/templates/vue-app/files/src/assets/icons/svg/online.svg +1 -0
  144. package/templates/vue-app/files/src/assets/icons/svg/password.svg +1 -0
  145. package/templates/vue-app/files/src/assets/icons/svg/people.svg +1 -0
  146. package/templates/vue-app/files/src/assets/icons/svg/peoples.svg +1 -0
  147. package/templates/vue-app/files/src/assets/icons/svg/perSet.svg +1 -0
  148. package/templates/vue-app/files/src/assets/icons/svg/permission.svg +1 -0
  149. package/templates/vue-app/files/src/assets/icons/svg/phone.svg +1 -0
  150. package/templates/vue-app/files/src/assets/icons/svg/piechart.svg +1 -0
  151. package/templates/vue-app/files/src/assets/icons/svg/qiniu.svg +1 -0
  152. package/templates/vue-app/files/src/assets/icons/svg/redis.svg +1 -0
  153. package/templates/vue-app/files/src/assets/icons/svg/resetpassword.svg +1 -0
  154. package/templates/vue-app/files/src/assets/icons/svg/resetpassword1.svg +1 -0
  155. package/templates/vue-app/files/src/assets/icons/svg/role.svg +1 -0
  156. package/templates/vue-app/files/src/assets/icons/svg/search.svg +1 -0
  157. package/templates/vue-app/files/src/assets/icons/svg/server.svg +1 -0
  158. package/templates/vue-app/files/src/assets/icons/svg/shopping.svg +1 -0
  159. package/templates/vue-app/files/src/assets/icons/svg/size.svg +1 -0
  160. package/templates/vue-app/files/src/assets/icons/svg/skill.svg +1 -0
  161. package/templates/vue-app/files/src/assets/icons/svg/source.svg +1 -0
  162. package/templates/vue-app/files/src/assets/icons/svg/sqlMonitor.svg +1 -0
  163. package/templates/vue-app/files/src/assets/icons/svg/statistical.svg +1 -0
  164. package/templates/vue-app/files/src/assets/icons/svg/swagger.svg +1 -0
  165. package/templates/vue-app/files/src/assets/icons/svg/sys-tools.svg +1 -0
  166. package/templates/vue-app/files/src/assets/icons/svg/system.svg +1 -0
  167. package/templates/vue-app/files/src/assets/icons/svg/system1.svg +1 -0
  168. package/templates/vue-app/files/src/assets/icons/svg/tab.svg +1 -0
  169. package/templates/vue-app/files/src/assets/icons/svg/teams.svg +1 -0
  170. package/templates/vue-app/files/src/assets/icons/svg/theme.svg +1 -0
  171. package/templates/vue-app/files/src/assets/icons/svg/timing.svg +1 -0
  172. package/templates/vue-app/files/src/assets/icons/svg/tools.svg +1 -0
  173. package/templates/vue-app/files/src/assets/icons/svg/tree-table.svg +1 -0
  174. package/templates/vue-app/files/src/assets/icons/svg/tree.svg +1 -0
  175. package/templates/vue-app/files/src/assets/icons/svg/unlock.svg +1 -0
  176. package/templates/vue-app/files/src/assets/icons/svg/user.svg +1 -0
  177. package/templates/vue-app/files/src/assets/icons/svg/user1.svg +1 -0
  178. package/templates/vue-app/files/src/assets/icons/svg/validCode.svg +1 -0
  179. package/templates/vue-app/files/src/assets/icons/svg/visits.svg +1 -0
  180. package/templates/vue-app/files/src/assets/icons/svg/web.svg +1 -0
  181. package/templates/vue-app/files/src/assets/icons/svg/wechat.svg +1 -0
  182. package/templates/vue-app/files/src/assets/icons/svg/weixin.svg +1 -0
  183. package/templates/vue-app/files/src/assets/icons/svg/zujian.svg +1 -0
  184. package/templates/vue-app/files/src/assets/icons/svgo.yml +21 -0
  185. package/templates/vue-app/files/src/assets/images/archive.png +0 -0
  186. package/templates/vue-app/files/src/assets/images/archive_icon.png +0 -0
  187. package/templates/vue-app/files/src/assets/images/avatar.png +0 -0
  188. package/templates/vue-app/files/src/assets/images/background.jpg +0 -0
  189. package/templates/vue-app/files/src/assets/images/bg.png +0 -0
  190. package/templates/vue-app/files/src/assets/images/gongan.png +0 -0
  191. package/templates/vue-app/files/src/assets/images/hospital_icon.png +0 -0
  192. package/templates/vue-app/files/src/assets/images/location.png +0 -0
  193. package/templates/vue-app/files/src/assets/images/logintitle.jpg +0 -0
  194. package/templates/vue-app/files/src/assets/images/logo-copy1.png +0 -0
  195. package/templates/vue-app/files/src/assets/images/logo.png +0 -0
  196. package/templates/vue-app/files/src/assets/images/logoBg.png +0 -0
  197. package/templates/vue-app/files/src/assets/images/offline-bg.png +0 -0
  198. package/templates/vue-app/files/src/assets/images/position.png +0 -0
  199. package/templates/vue-app/files/src/assets/images/qualityBg.jpg +0 -0
  200. package/templates/vue-app/files/src/assets/images/self-bg.png +0 -0
  201. package/templates/vue-app/files/src/assets/images/self-bg2.png +0 -0
  202. package/templates/vue-app/files/src/assets/images/triAngel.png +0 -0
  203. package/templates/vue-app/files/src/assets/images/triAngelNormal.png +0 -0
  204. package/templates/vue-app/files/src/assets/styles/btn.scss +103 -0
  205. package/templates/vue-app/files/src/assets/styles/eladmin.scss +124 -0
  206. package/templates/vue-app/files/src/assets/styles/element-ui.scss +217 -0
  207. package/templates/vue-app/files/src/assets/styles/element-variables.scss +31 -0
  208. package/templates/vue-app/files/src/assets/styles/global.scss +73 -0
  209. package/templates/vue-app/files/src/assets/styles/index.scss +220 -0
  210. package/templates/vue-app/files/src/assets/styles/mixin.scss +60 -0
  211. package/templates/vue-app/files/src/assets/styles/publicStyle.scss +224 -0
  212. package/templates/vue-app/files/src/assets/styles/sidebar.scss +239 -0
  213. package/templates/vue-app/files/src/assets/styles/transition.scss +48 -0
  214. package/templates/vue-app/files/src/assets/styles/variables.scss +44 -0
  215. package/templates/vue-app/files/src/common/flexible.js +145 -0
  216. package/templates/vue-app/files/src/components/Breadcrumb/index.vue +87 -0
  217. package/templates/vue-app/files/src/components/Crud/CRUD.operation.vue +248 -0
  218. package/templates/vue-app/files/src/components/Crud/Pagination.vue +20 -0
  219. package/templates/vue-app/files/src/components/Crud/RR.operation.vue +39 -0
  220. package/templates/vue-app/files/src/components/Crud/UD.operation.vue +106 -0
  221. package/templates/vue-app/files/src/components/Crud/crud.js +907 -0
  222. package/templates/vue-app/files/src/components/Crud/user/UR.operation.vue +154 -0
  223. package/templates/vue-app/files/src/components/DateRangePicker/index.vue +42 -0
  224. package/templates/vue-app/files/src/components/DateRangePickerProhibitNext/index.vue +42 -0
  225. package/templates/vue-app/files/src/components/DateRangePickerProhibitTodayNext/index.vue +48 -0
  226. package/templates/vue-app/files/src/components/Dict/Dict.js +31 -0
  227. package/templates/vue-app/files/src/components/Dict/index.js +29 -0
  228. package/templates/vue-app/files/src/components/Doc/index.vue +16 -0
  229. package/templates/vue-app/files/src/components/Echarts/BarChart.vue +115 -0
  230. package/templates/vue-app/files/src/components/Echarts/Category.vue +768 -0
  231. package/templates/vue-app/files/src/components/Echarts/Funnel.vue +120 -0
  232. package/templates/vue-app/files/src/components/Echarts/Gauge.vue +74 -0
  233. package/templates/vue-app/files/src/components/Echarts/Graph.vue +101 -0
  234. package/templates/vue-app/files/src/components/Echarts/HeatMap.vue +301 -0
  235. package/templates/vue-app/files/src/components/Echarts/Line3D.vue +110 -0
  236. package/templates/vue-app/files/src/components/Echarts/PieChart.vue +84 -0
  237. package/templates/vue-app/files/src/components/Echarts/Point.vue +161 -0
  238. package/templates/vue-app/files/src/components/Echarts/RadarChart.vue +123 -0
  239. package/templates/vue-app/files/src/components/Echarts/Rich.vue +160 -0
  240. package/templates/vue-app/files/src/components/Echarts/Sankey.vue +114 -0
  241. package/templates/vue-app/files/src/components/Echarts/Scatter.vue +192 -0
  242. package/templates/vue-app/files/src/components/Echarts/Sunburst.vue +127 -0
  243. package/templates/vue-app/files/src/components/Echarts/ThemeRiver.vue +233 -0
  244. package/templates/vue-app/files/src/components/Echarts/WordCloud.vue +201 -0
  245. package/templates/vue-app/files/src/components/GithubCorner/index.vue +55 -0
  246. package/templates/vue-app/files/src/components/Hamburger/index.vue +44 -0
  247. package/templates/vue-app/files/src/components/HeaderSearch/index.vue +196 -0
  248. package/templates/vue-app/files/src/components/IconSelect/index.vue +74 -0
  249. package/templates/vue-app/files/src/components/IconSelect/requireIcons.js +10 -0
  250. package/templates/vue-app/files/src/components/Iframe/index.vue +30 -0
  251. package/templates/vue-app/files/src/components/JavaEdit/index.vue +78 -0
  252. package/templates/vue-app/files/src/components/Pagination/index.vue +100 -0
  253. package/templates/vue-app/files/src/components/PanThumb/index.vue +149 -0
  254. package/templates/vue-app/files/src/components/ParentView/index.vue +3 -0
  255. package/templates/vue-app/files/src/components/Permission/index.js +13 -0
  256. package/templates/vue-app/files/src/components/Permission/permission.js +21 -0
  257. package/templates/vue-app/files/src/components/RightPanel/index.vue +149 -0
  258. package/templates/vue-app/files/src/components/Screenfull/index.vue +60 -0
  259. package/templates/vue-app/files/src/components/SizeSelect/index.vue +60 -0
  260. package/templates/vue-app/files/src/components/SvgIcon/index.vue +66 -0
  261. package/templates/vue-app/files/src/components/ThemePicker/index.vue +177 -0
  262. package/templates/vue-app/files/src/components/UploadExcel/index.vue +149 -0
  263. package/templates/vue-app/files/src/components/WaterMark/setWaterMark.js +68 -0
  264. package/templates/vue-app/files/src/components/WaterMark/waterMark.vue +69 -0
  265. package/templates/vue-app/files/src/components/Xgplayer/index.vue +49 -0
  266. package/templates/vue-app/files/src/components/YamlEdit/index.vue +81 -0
  267. package/templates/vue-app/files/src/layout/components/AppMain.vue +67 -0
  268. package/templates/vue-app/files/src/layout/components/Navbar.vue +209 -0
  269. package/templates/vue-app/files/src/layout/components/Settings/index.vue +125 -0
  270. package/templates/vue-app/files/src/layout/components/Sidebar/FixiOSBug.js +26 -0
  271. package/templates/vue-app/files/src/layout/components/Sidebar/Item.vue +29 -0
  272. package/templates/vue-app/files/src/layout/components/Sidebar/Link.vue +35 -0
  273. package/templates/vue-app/files/src/layout/components/Sidebar/Logo.vue +93 -0
  274. package/templates/vue-app/files/src/layout/components/Sidebar/SidebarItem.vue +104 -0
  275. package/templates/vue-app/files/src/layout/components/Sidebar/index.vue +79 -0
  276. package/templates/vue-app/files/src/layout/components/TagsView/ScrollPane.vue +90 -0
  277. package/templates/vue-app/files/src/layout/components/TagsView/index.vue +299 -0
  278. package/templates/vue-app/files/src/layout/components/index.js +5 -0
  279. package/templates/vue-app/files/src/layout/index.vue +119 -0
  280. package/templates/vue-app/files/src/layout/mixin/ResizeHandler.js +45 -0
  281. package/templates/vue-app/files/src/main.js +89 -0
  282. package/templates/vue-app/files/src/mixins/crud.js +348 -0
  283. package/templates/vue-app/files/src/router/index.js +156 -0
  284. package/templates/vue-app/files/src/router/routers.js +203 -0
  285. package/templates/vue-app/files/src/settings.js +57 -0
  286. package/templates/vue-app/files/src/store/getters.js +29 -0
  287. package/templates/vue-app/files/src/store/index.js +25 -0
  288. package/templates/vue-app/files/src/store/modules/api.js +33 -0
  289. package/templates/vue-app/files/src/store/modules/app.js +55 -0
  290. package/templates/vue-app/files/src/store/modules/permission.js +79 -0
  291. package/templates/vue-app/files/src/store/modules/register.js +17 -0
  292. package/templates/vue-app/files/src/store/modules/settings.js +46 -0
  293. package/templates/vue-app/files/src/store/modules/tagsView.js +168 -0
  294. package/templates/vue-app/files/src/store/modules/user.js +119 -0
  295. package/templates/vue-app/files/src/utils/auth.js +18 -0
  296. package/templates/vue-app/files/src/utils/base64ToFile.js +27 -0
  297. package/templates/vue-app/files/src/utils/clipboard.js +36 -0
  298. package/templates/vue-app/files/src/utils/datetime.js +289 -0
  299. package/templates/vue-app/files/src/utils/getBlobFile.js +10 -0
  300. package/templates/vue-app/files/src/utils/getTime.js +29 -0
  301. package/templates/vue-app/files/src/utils/index.js +520 -0
  302. package/templates/vue-app/files/src/utils/permission.js +29 -0
  303. package/templates/vue-app/files/src/utils/pinyin.js +450 -0
  304. package/templates/vue-app/files/src/utils/request.js +139 -0
  305. package/templates/vue-app/files/src/utils/rsaEncrypt.js +37 -0
  306. package/templates/vue-app/files/src/utils/shortcuts.js +210 -0
  307. package/templates/vue-app/files/src/utils/upload.js +12 -0
  308. package/templates/vue-app/files/src/utils/validate.js +262 -0
  309. package/templates/vue-app/files/src/views/components/Echarts.vue +124 -0
  310. package/templates/vue-app/files/src/views/components/Editor.vue +75 -0
  311. package/templates/vue-app/files/src/views/components/MarkDown.vue +44 -0
  312. package/templates/vue-app/files/src/views/components/UVideo.vue +37 -0
  313. package/templates/vue-app/files/src/views/components/YamlEdit.vue +206 -0
  314. package/templates/vue-app/files/src/views/components/camera/camera.vue +115 -0
  315. package/templates/vue-app/files/src/views/components/camera/cameraTest.vue +158 -0
  316. package/templates/vue-app/files/src/views/components/excel/upload-excel.vue +41 -0
  317. package/templates/vue-app/files/src/views/components/icons/element-icons.js +74 -0
  318. package/templates/vue-app/files/src/views/components/icons/index.vue +106 -0
  319. package/templates/vue-app/files/src/views/components/icons/svg-icons.js +10 -0
  320. package/templates/vue-app/files/src/views/components/scroll/index.vue +107 -0
  321. package/templates/vue-app/files/src/views/components/scrollFull/index.vue +99 -0
  322. package/templates/vue-app/files/src/views/dashboard/LineChart.vue +138 -0
  323. package/templates/vue-app/files/src/views/dashboard/PanelGroup.vue +173 -0
  324. package/templates/vue-app/files/src/views/dashboard/mixins/resize.js +57 -0
  325. package/templates/vue-app/files/src/views/dataArchive/delTable.vue +354 -0
  326. package/templates/vue-app/files/src/views/dataArchive/exportDetail.vue +121 -0
  327. package/templates/vue-app/files/src/views/dataArchive/exportList.vue +160 -0
  328. package/templates/vue-app/files/src/views/dataArchive/index.vue +2104 -0
  329. package/templates/vue-app/files/src/views/features/401.vue +83 -0
  330. package/templates/vue-app/files/src/views/features/404.vue +226 -0
  331. package/templates/vue-app/files/src/views/features/redirect.vue +12 -0
  332. package/templates/vue-app/files/src/views/generator/config.vue +348 -0
  333. package/templates/vue-app/files/src/views/generator/index.vue +143 -0
  334. package/templates/vue-app/files/src/views/generator/preview.vue +39 -0
  335. package/templates/vue-app/files/src/views/home.vue +80 -0
  336. package/templates/vue-app/files/src/views/indexManagement/index.vue +422 -0
  337. package/templates/vue-app/files/src/views/indexManagement/other.vue +286 -0
  338. package/templates/vue-app/files/src/views/institutionMonitor/components/LineChart.vue +191 -0
  339. package/templates/vue-app/files/src/views/institutionMonitor/index.scss +339 -0
  340. package/templates/vue-app/files/src/views/institutionMonitor/index.vue +1385 -0
  341. package/templates/vue-app/files/src/views/institutionMonitor/mixins/resize.js +57 -0
  342. package/templates/vue-app/files/src/views/institutionMonitor/monitorDetail/checkProjectCode.vue +267 -0
  343. package/templates/vue-app/files/src/views/institutionMonitor/monitorDetail/imageAbnormalMonitor.vue +361 -0
  344. package/templates/vue-app/files/src/views/institutionMonitor/monitorDetail/index.vue +686 -0
  345. package/templates/vue-app/files/src/views/institutionMonitor/monitorDetail/leakageAnomaly.vue +270 -0
  346. package/templates/vue-app/files/src/views/institutionMonitor/monitorDetail/moveMonitore.vue +114 -0
  347. package/templates/vue-app/files/src/views/institutionMonitor/monitorDetail/qualityMonitore.vue +338 -0
  348. package/templates/vue-app/files/src/views/institutionSet/cloudSet.vue +534 -0
  349. package/templates/vue-app/files/src/views/institutionSet/index.vue +2550 -0
  350. package/templates/vue-app/files/src/views/login.vue +243 -0
  351. package/templates/vue-app/files/src/views/qualityLogin.vue +280 -0
  352. package/templates/vue-app/files/src/views/selfStatistics/components/LineChart.vue +296 -0
  353. package/templates/vue-app/files/src/views/selfStatistics/hospitalDetail/index.vue +533 -0
  354. package/templates/vue-app/files/src/views/selfStatistics/index.scss +447 -0
  355. package/templates/vue-app/files/src/views/selfStatistics/index.vue +903 -0
  356. package/templates/vue-app/files/src/views/selfStatistics/mixins/resize.js +57 -0
  357. package/templates/vue-app/files/src/views/selfStatistics/monitorDetail/index.vue +285 -0
  358. package/templates/vue-app/files/src/views/selfStatistics/offlineDetail/index.vue +104 -0
  359. package/templates/vue-app/files/src/views/selfStatistics/selfActiveDetail/index.vue +104 -0
  360. package/templates/vue-app/files/src/views/selfStatistics/selfMonitorDetail/index.vue +420 -0
  361. package/templates/vue-app/files/src/views/selfStatistics/setWaterMark/setWaterMark.js +68 -0
  362. package/templates/vue-app/files/src/views/selfStatistics/setWaterMark/waterMark.vue +69 -0
  363. package/templates/vue-app/files/src/views/system/dept/index.vue +144 -0
  364. package/templates/vue-app/files/src/views/system/dict/dictDetail.vue +146 -0
  365. package/templates/vue-app/files/src/views/system/dict/index.vue +159 -0
  366. package/templates/vue-app/files/src/views/system/examModality/index.vue +174 -0
  367. package/templates/vue-app/files/src/views/system/examPart/index.vue +184 -0
  368. package/templates/vue-app/files/src/views/system/examProject/index.vue +321 -0
  369. package/templates/vue-app/files/src/views/system/examine/index.vue +66 -0
  370. package/templates/vue-app/files/src/views/system/job/index.vue +119 -0
  371. package/templates/vue-app/files/src/views/system/job/module/form.vue +72 -0
  372. package/templates/vue-app/files/src/views/system/job/module/header.vue +48 -0
  373. package/templates/vue-app/files/src/views/system/menu/index.vue +327 -0
  374. package/templates/vue-app/files/src/views/system/model/index.vue +285 -0
  375. package/templates/vue-app/files/src/views/system/role/index.vue +434 -0
  376. package/templates/vue-app/files/src/views/system/sysSet/index.vue +84 -0
  377. package/templates/vue-app/files/src/views/system/timing/index.vue +289 -0
  378. package/templates/vue-app/files/src/views/system/timing/log.vue +143 -0
  379. package/templates/vue-app/files/src/views/system/user/admin.vue +414 -0
  380. package/templates/vue-app/files/src/views/system/user/center/updateEmail.vue +146 -0
  381. package/templates/vue-app/files/src/views/system/user/center/updatePass.vue +168 -0
  382. package/templates/vue-app/files/src/views/system/user/center.vue +140 -0
  383. package/templates/vue-app/files/src/views/system/user/index.vue +972 -0
  384. package/templates/vue-app/files/src/views/systemSet/role/index.vue +314 -0
  385. package/templates/vue-app/files/src/views/systemSet/user/admin.vue +414 -0
  386. package/templates/vue-app/files/src/views/systemSet/user/center/updateEmail.vue +146 -0
  387. package/templates/vue-app/files/src/views/systemSet/user/center/updatePass.vue +115 -0
  388. package/templates/vue-app/files/src/views/systemSet/user/center.vue +351 -0
  389. package/templates/vue-app/files/src/views/systemSet/user/index.vue +928 -0
  390. package/templates/vue-app/files/src/views/tools/aliPay/config.vue +102 -0
  391. package/templates/vue-app/files/src/views/tools/aliPay/index.vue +48 -0
  392. package/templates/vue-app/files/src/views/tools/aliPay/toPay.vue +91 -0
  393. package/templates/vue-app/files/src/views/tools/email/config.vue +91 -0
  394. package/templates/vue-app/files/src/views/tools/email/index.vue +42 -0
  395. package/templates/vue-app/files/src/views/tools/email/send.vue +159 -0
  396. package/templates/vue-app/files/src/views/tools/storage/index.vue +35 -0
  397. package/templates/vue-app/files/src/views/tools/storage/local/index.vue +207 -0
  398. package/templates/vue-app/files/src/views/tools/storage/qiniu/form.vue +108 -0
  399. package/templates/vue-app/files/src/views/tools/storage/qiniu/index.vue +241 -0
  400. package/templates/vue-app/files/src/views/tools/swagger/index.vue +14 -0
  401. package/templates/vue-app/files/vue.config.js +173 -0
  402. package/templates/vue-app/template.json +30 -0
@@ -0,0 +1,903 @@
1
+ <template>
2
+ <div class="app-container digitalImage">
3
+ <!-- 工具栏-->
4
+ <el-form :inline="true" :model="query" ref="topForm" class="form-inline-hospital" size="small">
5
+ <el-form-item>
6
+ <!-- 区域 -->
7
+ <el-cascader
8
+ v-model="query.address"
9
+ placeholder="医院地区"
10
+ :options="provinceList"
11
+ :props="props"
12
+ style="width: 220px"
13
+ @active-item-change="handleItemChange"
14
+ @change="addressChange"
15
+ @blur="forceUpdate">
16
+ </el-cascader>
17
+ </el-form-item>
18
+ <el-form-item>
19
+ <el-select
20
+ v-model="query.hospitalType"
21
+ clearable
22
+ placeholder="医院类别"
23
+ class="filter-item"
24
+ style="width: 160px"
25
+ @change="changeHospital"
26
+ @clear="changeHospital">
27
+ <el-option
28
+ v-for="item in dict.hos_category"
29
+ :key="item.value"
30
+ :label="item.label"
31
+ :value="item.value" />
32
+ </el-select>
33
+ </el-form-item>
34
+ <!-- 医院等级 -->
35
+ <el-form-item>
36
+ <el-select
37
+ v-model="query.level"
38
+ clearable
39
+ @change="changeHospital"
40
+ @clear="changeHospital"
41
+ placeholder="医院等级(级)"
42
+ class="filter-item"
43
+ style="width: 160px">
44
+ <el-option
45
+ v-for="item in dict.hos_rank"
46
+ :key="item.value"
47
+ :label="item.label"
48
+ :value="item.value" />
49
+ </el-select>
50
+ </el-form-item>
51
+ <el-form-item prop="hospitalTypeList">
52
+ <el-select
53
+ v-model="query.hospitalIdList"
54
+ clearable
55
+ filterable
56
+ multiple
57
+ @change="changeHospital"
58
+ @clear="changeHospital"
59
+ placeholder="医院名称"
60
+ class="filter-item"
61
+ style="width: 160px">
62
+ <el-option
63
+ v-for="item in hospitalNames"
64
+ :key="item.scenceId"
65
+ :label="item.hospitalName"
66
+ :value="item.scenceId" />
67
+ </el-select>
68
+ </el-form-item>
69
+ <el-form-item prop="softwareType">
70
+ <el-select
71
+ v-model="query.softwareType"
72
+ clearable
73
+ @change="changeHospital"
74
+ @clear="changeHospital"
75
+ placeholder="软件类型"
76
+ class="filter-item"
77
+ style="width: 160px">
78
+ <el-option v-for="item in softData" :key="item" :label="item" :value="item" />
79
+ </el-select>
80
+ </el-form-item>
81
+ <el-form-item>
82
+ <!-- <date-range-picker
83
+ v-model="query.consultationTimeList"
84
+ :picker-options="pickerOptions"
85
+ popper-class="isDisabledDate"
86
+ valueFormat="yyyy-MM-dd"
87
+ style="width: 250px"
88
+ class="date-item"
89
+ @change="dateChange"
90
+ @blur="forceUpdate"
91
+ :clearable="false"
92
+ /> -->
93
+ <date-range-picker
94
+ @blur="forceUpdate"
95
+ @change="dateChange"
96
+ v-model="query.consultationTimeList"
97
+ :picker-options="pickerOptions"
98
+ popper-class="isDisabledDate"
99
+ valueFormat="yyyy-MM-dd"
100
+ style="width: 250px"
101
+ class="date-item"
102
+ :clearable="false" />
103
+ </el-form-item>
104
+
105
+ <el-button @click="toQuery" class="filter-item" size="small">查询 </el-button>
106
+ <el-button @click="resetQueryClick" class="filter-item" size="small">重置 </el-button>
107
+ </el-form>
108
+ <!-- 统计模块 -->
109
+ <div class="self-statiscs">
110
+ <div class="other" @click="offlineClick(1, 'hospitalDetail', '医院数量详情')">
111
+ <p class="top">
112
+ <span>医院数量</span>
113
+ <el-tooltip
114
+ class="item"
115
+ effect="dark"
116
+ content="是【医院管理】模块内录入自助机信息的医院数量及自助机总量,不随检索时间及软件类型变化"
117
+ placement="top-start">
118
+ <span class="el-icon-question"></span>
119
+ </el-tooltip>
120
+ <span class="bold">{{ (cloudCount.myHospitalTotal || 0) | NumFormat }}</span>
121
+ </p>
122
+ <p class="bottom">
123
+ <span><i></i>配备自助机</span>
124
+ <span class="bold">{{ (cloudCount.myMachineQuantity || 0) | NumFormat }}</span>
125
+ </p>
126
+ </div>
127
+ <div class="other" @click="offlineClick(2, 'hospitalDetail', '监测自助机详情')">
128
+ <p class="top">
129
+ <span>监测自助机系统</span>
130
+ <el-tooltip
131
+ class="item"
132
+ effect="dark"
133
+ content="是系统实际监测到的系统数量,不随检索时间变化"
134
+ placement="top-start">
135
+ <span class="el-icon-question"></span>
136
+ </el-tooltip>
137
+ <span class="bold">{{ (cloudCount.machineTotal || 0) | NumFormat }}</span>
138
+ </p>
139
+ <div class="bottom special-bottom">
140
+ <!-- <img src="~@/assets/images/hospital_icon.png" alt="" /> -->
141
+ <p>
142
+ <i></i>影联系统<span class="bold">{{
143
+ (cloudCount.ylyxMachineTotal || 0) | NumFormat
144
+ }}</span>
145
+ </p>
146
+ <p>
147
+ <i></i>真实自助机<span class="bold">{{
148
+ (cloudCount.realMachine || 0) | NumFormat
149
+ }}</span>
150
+ </p>
151
+ <p :style="{ visibility: query.softwareType == '影联' ? 'hidden' : 'visible' }">
152
+ <i class="first"></i>非影联系统<span class="bold">{{
153
+ (cloudCount.otherMachineTotal || 0) | NumFormat
154
+ }}</span>
155
+ </p>
156
+ <p>
157
+ <i class="first"></i>非真实自助机<span class="bold">{{
158
+ (cloudCount.virtualMachine || 0) | NumFormat
159
+ }}</span>
160
+ </p>
161
+ </div>
162
+ </div>
163
+ <div class="other" @click="offlineClick(3, 'hospitalDetail', '自助机活跃度详情')">
164
+ <p class="top">
165
+ <span>自助机活跃度</span>
166
+ <el-tooltip
167
+ class="item"
168
+ effect="dark"
169
+ content="是实际监测到的真实自助机的活跃度"
170
+ placement="top-start">
171
+ <span class="el-icon-question"></span>
172
+ </el-tooltip>
173
+ <span class="bold">{{ dealData(cloudCount.activityRate) }}</span>
174
+ </p>
175
+ <div class="bottom">
176
+ <!-- <img src="~@/assets/images/hospital_icon.png" alt="" /> -->
177
+ <p>
178
+ <i></i>影联系统<span class="bold">{{
179
+ dealData(cloudCount.ylyxMachineActivityRate)
180
+ }}</span>
181
+ </p>
182
+ <p v-show="query.softwareType !== '影联'">
183
+ <i class="first"></i>非影联系统<span class="bold">{{
184
+ dealData(cloudCount.qtMachineActivityRate)
185
+ }}</span>
186
+ </p>
187
+ </div>
188
+ </div>
189
+ <div class="other">
190
+ <p class="top">
191
+ <!-- <img src="~@/assets/images/hospital_icon.png" alt="" /> -->
192
+ <span>打印报告</span>
193
+ <span class="bold">{{ (cloudCount.cumulativePrintTimes || 0) | NumFormat }}</span>
194
+ </p>
195
+ <div class="bottom">
196
+ <!-- <img src="~@/assets/images/hospital_icon.png" alt="" /> -->
197
+ <p>
198
+ <i></i>影联系统<span class="bold">{{
199
+ (cloudCount.ylyxCumulativePrintTimes || 0) | NumFormat
200
+ }}</span>
201
+ </p>
202
+ <p :style="{ visibility: query.softwareType == '影联' ? 'hidden' : 'visible' }">
203
+ <i class="first"></i>非影联系统<span class="bold">{{
204
+ (cloudCount.qtCumulativePrintTimes || 0) | NumFormat
205
+ }}</span>
206
+ </p>
207
+ </div>
208
+ </div>
209
+ <div class="other bg2" @click="offlineClick(5, 'offlineDetail', '客户端状态详情')">
210
+ <p class="top">
211
+ <span>客户端状态</span>
212
+ <el-tooltip
213
+ class="item"
214
+ effect="dark"
215
+ content="影联客户端在线状态,不随检索的时间区间及软件类型变化"
216
+ placement="top-start">
217
+ <span class="el-icon-question"></span>
218
+ </el-tooltip>
219
+ </p>
220
+ <p class="bottom">
221
+ <span>
222
+ <svg-icon class-name="online" icon-class="online" />在线<span class="bold">{{
223
+ (cloudCount.online || 0) | NumFormat
224
+ }}</span></span
225
+ >
226
+ <span>
227
+ <svg-icon class-name="offline" icon-class="offline" />离线<span class="bold">{{
228
+ (cloudCount.offline || 0) | NumFormat
229
+ }}</span></span
230
+ >
231
+ </p>
232
+ <div class="offline-detail">离线详情</div>
233
+ </div>
234
+ </div>
235
+ <div class="changeBtns">
236
+ <div class="frequency">
237
+ <ul>
238
+ <li
239
+ v-for="(item, index) in frequencyArr"
240
+ :key="index"
241
+ :class="[activeIndex == item.active ? 'frequencyActive' : '']"
242
+ @click="clickFrequency(item.active)">
243
+ {{ item.name }}
244
+ </li>
245
+ </ul>
246
+ </div>
247
+ <div class="radioBtn">
248
+ <el-radio-group v-model="radio1" size="small" @change="changeRadio">
249
+ <el-radio-button label="day">按天</el-radio-button>
250
+ <el-radio-button label="week">按周</el-radio-button>
251
+ <el-radio-button label="month">按月</el-radio-button>
252
+ <el-radio-button label="year">按年</el-radio-button>
253
+ </el-radio-group>
254
+ </div>
255
+ </div>
256
+
257
+ <line-chart :className="'lineChart'" :chart-data="lineChartData" />
258
+ <div class="export">
259
+ <el-button type="primary" @click="explore" :loading="downloadLoading" plain size="mini"
260
+ >导出</el-button
261
+ >
262
+ </div>
263
+ <div class="table-Data">
264
+ <!-- 表格 -->
265
+ <el-table :data="crud.data" v-loading="crud.loading" @sort-change="sortChange">
266
+ <el-table-column label="序号" width="60px">
267
+ <template slot-scope="scope">
268
+ <span>{{ (crud.page.page - 1) * crud.page.size + scope.$index + 1 }}</span>
269
+ </template>
270
+ </el-table-column>
271
+ <el-table-column
272
+ v-for="(item, index) in checkTable"
273
+ :key="index.key"
274
+ :label="item.label"
275
+ :prop="item.prop"
276
+ :show-overflow-tooltip="true"
277
+ :min-width="item.width"
278
+ :sortable="item.sort"
279
+ :render-header="renderPrice"
280
+ :sort-method="
281
+ (a, b) => {
282
+ return a[item.prop] - b[item.prop];
283
+ }
284
+ ">
285
+ <template slot-scope="scope">
286
+ <div v-if="item.prop == 'hospitalType'">
287
+ {{ hosCategory(scope.row.hospitalType) || omitData }}
288
+ </div>
289
+ <div v-else-if="item.prop == 'level'">
290
+ {{ hosRank(scope.row.level) || omitData }}
291
+ </div>
292
+ <div v-else-if="item.prop == 'printTimes'">
293
+ {{ scope.row.printTimes || 0 }}
294
+ </div>
295
+ <div v-else-if="item.prop == 'printTimeOfDailyAverage'">
296
+ {{ scope.row.printTimeOfDailyAverage || 0 }}
297
+ </div>
298
+ <div v-else-if="item.prop == 'activityMachineTotalRate'">
299
+ {{ dealData(scope.row.activityMachineTotalRate) }}
300
+ </div>
301
+ <div v-else-if="item.prop == 'reportConversionRate'">
302
+ {{ dealData(scope.row.reportConversionRate) }}
303
+ </div>
304
+ <div v-else>
305
+ {{ scope.row[item.prop] || omitData }}
306
+ </div>
307
+ </template>
308
+ </el-table-column>
309
+ <el-table-column label="操作" width="80" fixed="right">
310
+ <template slot-scope="scope">
311
+ <el-button size="mini" type="text" @click="goCloudDetail(scope.row)">详情 </el-button>
312
+ </template>
313
+ </el-table-column>
314
+ </el-table>
315
+ <!--分页组件-->
316
+ <pagination />
317
+ </div>
318
+
319
+ <!-- 维护记录弹窗 -->
320
+ <el-dialog
321
+ :title="currentDetail.hospitalName"
322
+ top="5vh"
323
+ :visible.sync="cloudDetailVisiable"
324
+ :close-on-click-modal="false"
325
+ width="75%"
326
+ @close="dialogClosse">
327
+ <span slot="title" class="dialog-footer"
328
+ >{{ currentDetail.hospitalName }} {{ currentDetail.startTime }}至{{
329
+ currentDetail.endTime
330
+ }}</span
331
+ >
332
+ <cloudListDetail ref="cloudListDetail" :cloudDetail="currentDetail" />
333
+ </el-dialog>
334
+ <!-- 维护记录弹窗 -->
335
+ <el-dialog
336
+ :title="dialogText"
337
+ top="5vh"
338
+ :visible.sync="offlineDetailVisiable"
339
+ :close-on-click-modal="false"
340
+ width="85%">
341
+ <span slot="title" class="dialog-footer"
342
+ >{{ dialogText }}
343
+ <el-tooltip class="item" effect="dark" placement="top-start">
344
+ <div slot="content" v-html="content"></div>
345
+ <span class="el-icon-question" v-if="clickIndex !== 5"></span> </el-tooltip
346
+ ></span>
347
+ <hospital-detail ref="hospitalDetail" v-if="clickIndex !== 5"></hospital-detail>
348
+ <!-- <self-monitor-detail
349
+ ref="selfMonitorDetail"
350
+ v-if="clickIndex == 2"
351
+ ></self-monitor-detail>
352
+ <self-active-detail
353
+ ref="selfActiveDetail"
354
+ v-if="clickIndex == 3"
355
+ ></self-active-detail> -->
356
+ <offline-detail ref="offlineDetail" v-if="clickIndex == 5" :data="query" />
357
+ </el-dialog>
358
+ <!-- <WaterMark :waterMarkProp="waterMarkProp" /> -->
359
+ </div>
360
+ </template>
361
+
362
+ <script>
363
+ import LineChart from './components/LineChart.vue';
364
+ import { mapGetters } from 'vuex';
365
+ import pagination from '@crud/Pagination';
366
+ import cloudListDetail from './monitorDetail/index.vue';
367
+ import offlineDetail from './offlineDetail/index.vue';
368
+ import hospitalDetail from './hospitalDetail/index.vue';
369
+ import selfMonitorDetail from './selfMonitorDetail/index.vue';
370
+ import selfActiveDetail from './selfActiveDetail/index.vue';
371
+ import CRUD, { presenter, header, crud } from '@crud/crud';
372
+ import { getTotalData, getLineData, queryHospital } from '@/api/selfStatistics/index.js';
373
+ import DateRangePicker from '@/components/DateRangePicker';
374
+ import institutionMonitor from '@/api/institutionMonitor/index';
375
+ import { getDay } from '@/utils/getTime';
376
+ import WaterMark from './setWaterMark/waterMark.vue';
377
+ import { downloadFile } from '@/utils/index';
378
+ import { downloadPost } from '@/api/data';
379
+ const end = getDay(-1);
380
+ const start = getDay(-7);
381
+ export default {
382
+ name: 'cloudStatistics',
383
+ components: {
384
+ pagination,
385
+ cloudListDetail,
386
+ DateRangePicker,
387
+ LineChart,
388
+ offlineDetail,
389
+ WaterMark,
390
+ hospitalDetail,
391
+ selfMonitorDetail,
392
+ selfActiveDetail,
393
+ },
394
+ dicts: ['cloud_code', 'hos_category', 'hos_rank'],
395
+ data() {
396
+ return {
397
+ waterMarkProp: {
398
+ zIndex: 1,
399
+ devicePixelRatio: 2,
400
+ text: '',
401
+ showTime: true,
402
+ },
403
+ omitData: '-',
404
+ provinceList: [],
405
+ // 区域
406
+ props: {
407
+ value: 'value',
408
+ children: 'cities',
409
+ label: 'label',
410
+ checkStrictly: true,
411
+ },
412
+ hospitalNames: [],
413
+ radio1: 'day',
414
+ checkTable: [
415
+ { label: '医院名称', prop: 'hospitalName', width: '180px' },
416
+ { label: '医院类别', prop: 'hospitalType', width: '120px' },
417
+ { label: '医院等级(级)', prop: 'level', width: '120px' },
418
+ { label: '配备自助机', prop: 'myMachineTotal', width: '120px', sort: true },
419
+ { label: '监测自助机', prop: 'machineTotal', width: '120px', sort: true },
420
+ {
421
+ label: '该时间段活跃自助机',
422
+ prop: 'activityMachineTotal',
423
+ width: '190px',
424
+ sort: true,
425
+ },
426
+ {
427
+ label: '该时间段自助机活跃度',
428
+ prop: 'activityMachineTotalRate',
429
+ width: '190px',
430
+ sort: true,
431
+ },
432
+
433
+ { label: '审核报告量', prop: 'auditedDataTotal', width: '120px', sort: true },
434
+ { label: '打印报告量', prop: 'printTimes', width: '120px', sort: true },
435
+ { label: '报告转化率', prop: 'reportConversionRate', width: '120px', sort: true },
436
+ {
437
+ label: '日均打印报告量',
438
+ prop: 'printTimeOfDailyAverage',
439
+ width: '160px',
440
+ sort: true,
441
+ },
442
+ ],
443
+ // 获取统计数量
444
+ cloudCount: {},
445
+ // 详情弹窗控制
446
+ cloudDetailVisiable: false,
447
+ // 当前点击的详情信息
448
+ currentDetail: {},
449
+ // 导出
450
+ downloadLoading: false,
451
+ // 离线详情
452
+ offlineDetailVisiable: false,
453
+ // 判断是否第一次
454
+ crudShow: false,
455
+ lineChartData: {
456
+ times: [],
457
+ datas: [],
458
+ },
459
+ activeIndex: 1,
460
+ clickIndex: 1,
461
+ dialogText: '',
462
+ frequencyArr: [
463
+ {
464
+ name: '数据趋势',
465
+ active: '1',
466
+ },
467
+ ],
468
+ softData: ['影联'],
469
+ sortString: {
470
+ myMachineTotal: 1,
471
+ machineTotal: 2,
472
+ activityMachineTotal: 6,
473
+ auditedDataTotal: 7,
474
+ printTimes: 8,
475
+ printTimeOfDailyAverage: 9,
476
+ activityMachineTotalRate: 11,
477
+ reportConversionRate: 12,
478
+ },
479
+ downloadLoading: false,
480
+ pickerOptions: {
481
+ disabledDate(time) {
482
+ return time.getTime() > Date.now();
483
+ },
484
+ shortcuts: [
485
+ {
486
+ text: '近一周',
487
+ onClick(picker) {
488
+ const end = new Date();
489
+ const start = new Date();
490
+ end.setTime(end.getTime() - 3600 * 1000 * 24);
491
+ start.setTime(start.getTime() - 3600 * 1000 * 24 * 7);
492
+ picker.$emit('pick', [start, end]);
493
+ },
494
+ },
495
+ {
496
+ text: '近一个月',
497
+ onClick(picker) {
498
+ const end = new Date();
499
+ const start = new Date();
500
+ end.setTime(end.getTime() - 3600 * 1000 * 24);
501
+ start.setTime(start.getTime() - 3600 * 1000 * 24 * 30);
502
+ picker.$emit('pick', [start, end]);
503
+ },
504
+ },
505
+ {
506
+ text: '近三个月',
507
+ onClick(picker) {
508
+ const end = new Date();
509
+ const start = new Date();
510
+ end.setTime(end.getTime() - 3600 * 1000 * 24);
511
+ start.setTime(start.getTime() - 3600 * 1000 * 24 * 90);
512
+ picker.$emit('pick', [start, end]);
513
+ },
514
+ },
515
+ {
516
+ text: '最近一年',
517
+ onClick: picker => {
518
+ const end = new Date(); // 当前日期
519
+ const start = new Date(); // 开始日期
520
+
521
+ end.setDate(end.getDate() - 1); // 设置结束日期为昨天
522
+ start.setFullYear(start.getFullYear() - 1); // 设置开始日期为一年前
523
+
524
+ picker.$emit('pick', [start, end]);
525
+ },
526
+ },
527
+ {
528
+ text: '本年度',
529
+ onClick: picker => {
530
+ const end = new Date(); // 当前日期
531
+ const start = new Date(); // 开始日期
532
+ start.setDate(1);
533
+ end.setDate(end.getDate() - 1); // 设置结束日期为昨天
534
+ start.setMonth(0); // 设置开始日期为今年的1月份
535
+ picker.$emit('pick', [start, end]);
536
+ },
537
+ },
538
+ ],
539
+ },
540
+ };
541
+ },
542
+ mounted() {
543
+ this.waterMarkProp.text = this.user.name;
544
+ },
545
+ cruds() {
546
+ return CRUD({
547
+ title: '医院',
548
+ url: 'machine/getHospitalTableData',
549
+ crudMethod: {},
550
+ sort: [],
551
+ query: {},
552
+ });
553
+ },
554
+ computed: {
555
+ ...mapGetters(['user']),
556
+ content() {
557
+ return ` 配备自助机数量:是公司在医疗机构实际安装的自助机数量;<br/>
558
+ 监测自助机数量:是系统实际监测到的医疗机构的自助机数量(自助机信息上传成功);<br/>
559
+ 影联系统:是监测到的自助机中,有几台安装的是影联自研的打印系统;<br/>
560
+ 非影联系统:是监测到的自助机中,有几台安装的不是影联自研的打印系统;<br/>
561
+ 近7天是否活跃:是近7天该医疗机构监测到的自助机是否有过打印记录;</br>
562
+ 近7天活跃度:是该医疗机构监测到的自助机的活跃度,近7天有过打印记录的自助机数量÷监测到的自助机总数量;<br/>
563
+ `;
564
+ },
565
+ },
566
+ mixins: [presenter(), header(), crud()],
567
+
568
+ filters: {
569
+ NumFormat(value) {
570
+ if (value == '-') return '-';
571
+ if (!value) return '0';
572
+ /*原来用的是Number(value).toFixed(0),这样取整时有问题,例如0.51取整之后为1,感谢Nils指正*/
573
+ /*后来改成了 Number(value)|0,但是输入超过十一位就为负数了,具体见评论 */
574
+ var intPart = Number(value) - (Number(value) % 1); //获取整数部分(这里是windy93的方法)
575
+ var intPartFormat = intPart.toString().replace(/(\d)(?=(?:\d{3})+$)/g, '$1,'); //将整数部分逢三一断
576
+
577
+ var floatPart = ''; //预定义小数部分
578
+ var value2Array = value.toString().split('.');
579
+
580
+ //=2表示数据有小数位
581
+ if (value2Array.length == 2) {
582
+ floatPart = value2Array[1].toString(); //拿到小数部分
583
+
584
+ if (floatPart.length == 1) {
585
+ //补0,实际上用不着
586
+ return intPartFormat + '.' + floatPart + '0';
587
+ } else {
588
+ return intPartFormat + '.' + floatPart;
589
+ }
590
+ } else {
591
+ return intPartFormat + floatPart;
592
+ }
593
+ },
594
+ },
595
+
596
+ methods: {
597
+ dealData(value) {
598
+ if (value == -1 || value === undefined) {
599
+ return '-';
600
+ } else if (value === 0) {
601
+ return value;
602
+ } else {
603
+ return value + '%';
604
+ }
605
+ },
606
+ sortChange(column) {
607
+ if (column.order == 'ascending') {
608
+ this.query = {
609
+ ...this.query,
610
+ sortType: this.sortString[column.prop],
611
+ sort: 1,
612
+ };
613
+ this.crud.toQuery();
614
+ } else if (column.order == 'descending') {
615
+ this.query = {
616
+ ...this.query,
617
+ sortType: this.sortString[column.prop],
618
+ sort: 2,
619
+ };
620
+ this.crud.toQuery();
621
+ }
622
+ },
623
+ renderPrice(h, { column, $index }) {
624
+ if (column.property == 'activityMachineTotal') {
625
+ return [
626
+ column.label,
627
+ h(
628
+ 'el-tooltip',
629
+ {
630
+ props: {
631
+ content: '在上方选择的时间区间内,有过打印记录的被监测到的自助机数量',
632
+ placement: 'top', // 悬停内容展示的位置
633
+ },
634
+ },
635
+ [h('span', { class: { 'el-icon-question': true } })] // 图标
636
+ ),
637
+ ];
638
+ } else {
639
+ return column.label;
640
+ }
641
+ },
642
+ // 导出
643
+ explore() {
644
+ this.downloadLoading = true;
645
+ // let hospitalId=this.currentDetail.hospitalId
646
+ // let hospitalName=this.currentDetail.hospitalName,
647
+ let data = {
648
+ ...this.query,
649
+ };
650
+ downloadPost('machine/downloadHospitalTableData', data)
651
+ .then(result => {
652
+ this.downloadLoading = false;
653
+ })
654
+ .catch(e => {
655
+ let text = `医院列表 ${this.query.startTime}至${this.query.endTime}`;
656
+ downloadFile(e, text, 'xlsx');
657
+ this.downloadLoading = false;
658
+ });
659
+ },
660
+ // 返回医院类别对应的名称
661
+ hosCategory(category) {
662
+ return this.dict.label.hos_category[category];
663
+ },
664
+ // 返回医院等级(级)对应的名称
665
+ hosRank(rank) {
666
+ return this.dict.label.hos_rank[rank];
667
+ },
668
+ // 地区联动获取数据
669
+ getPosition(val, cb) {
670
+ let vm = this; //查询省市县
671
+ let params = { parent: 1 };
672
+ if (!val) {
673
+ //初始化加载 获取所有省份数据
674
+ params = { parent: 1 };
675
+ } else if (val.length === 1) {
676
+ //加载二级 获取市级数据
677
+ params = { parent: val[0] };
678
+ } else {
679
+ //加载3级 获取县级数据
680
+ params = { parent: val[1] };
681
+ }
682
+ institutionMonitor
683
+ .queryNation(params)
684
+ .then(res => {
685
+ if (!val) {
686
+ //初始化加载 查询省份数据
687
+ vm.provinceList = res.content.map(e => {
688
+ return {
689
+ value: e.saleid,
690
+ label: e.province,
691
+ cities: [],
692
+ };
693
+ });
694
+ } else if (val.length === 1) {
695
+ //加载二级 查询该省下市级数据
696
+ vm.provinceList.map(item => {
697
+ if (item.value === val[0]) {
698
+ item.cities = res.content.map(e => {
699
+ return {
700
+ value: e.saleid,
701
+ label: e.city || e.county,
702
+ cities: [],
703
+ };
704
+ });
705
+ }
706
+ });
707
+ } else {
708
+ //加载3级 查询该省市下县级数据
709
+ vm.provinceList.map(item => {
710
+ if (item.value === val[0]) {
711
+ item.cities.map(value => {
712
+ if (value.value === val[1]) {
713
+ value.cities = res.content.map(e => {
714
+ return { value: e.saleid, label: e.county };
715
+ });
716
+ }
717
+ });
718
+ }
719
+ });
720
+ }
721
+ cb && cb(res);
722
+ })
723
+ .catch(err => {
724
+ console.log(err);
725
+ });
726
+ },
727
+ // 一级二级改变的时候调取下一级数据
728
+ handleItemChange(val) {
729
+ this.getPosition(val);
730
+ },
731
+ // 查询医院名称
732
+ queryHospital() {
733
+ let params = JSON.parse(JSON.stringify(this.query));
734
+ params.county = params.district;
735
+
736
+ // 删除时间 医院名称
737
+ delete params.consultationTimeList;
738
+ delete params.address;
739
+ delete params.startTime;
740
+ delete params.endTime;
741
+ delete params.hospitalIdList;
742
+ params.deleted = 0;
743
+ queryHospital(params).then(res => {
744
+ this.hospitalNames = [];
745
+ res.forEach(k => {
746
+ let obj = {
747
+ scenceId: k.scenceId,
748
+ hospitalName: k.hospitalName,
749
+ };
750
+ this.hospitalNames.push(obj);
751
+ });
752
+ });
753
+ },
754
+ addressChange(status) {
755
+ if (this.query.address.length > 0) {
756
+ this.query.province = this.query.address[0];
757
+ this.query.city = this.query.address[1];
758
+ this.query.district = this.query.address[2];
759
+ }
760
+ this.queryHospital();
761
+ this.forceUpdate();
762
+ this.getCloudCount();
763
+ this.getLineData();
764
+ if (status != 1) {
765
+ this.crud.toQuery();
766
+ }
767
+ },
768
+ // 选择逐日-逐年
769
+ changeRadio() {
770
+ this.getLineData();
771
+ },
772
+ dateChange() {
773
+ this.forceUpdate();
774
+ if (this.query.consultationTimeList) {
775
+ this.query.startTime = this.query.consultationTimeList[0];
776
+ this.query.endTime = this.query.consultationTimeList[1];
777
+ } else {
778
+ this.query.startTime = '';
779
+ this.query.endTime = '';
780
+ }
781
+ },
782
+ //获取统计参数
783
+ getCloudCount() {
784
+ let data = {
785
+ ...this.query,
786
+ };
787
+ delete data.consultationTimeList;
788
+ delete data.address;
789
+ getTotalData(data).then(res => {
790
+ console.log(res);
791
+ this.cloudCount = res || {};
792
+ });
793
+ },
794
+ getLineData() {
795
+ let data = {
796
+ ...this.query,
797
+ statisticsType: this.radio1,
798
+ };
799
+ delete data.consultationTimeList;
800
+ delete data.address;
801
+ getLineData(data).then(res => {
802
+ this.lineChartData = res;
803
+ });
804
+ },
805
+ forceUpdate() {
806
+ this.$forceUpdate(); // 强制刷新
807
+ },
808
+ //重置
809
+ resetQueryClick() {
810
+ Object.keys(this.query).map(key => {
811
+ this.query[key] = '';
812
+ });
813
+ this.getPosition(null, () => {});
814
+
815
+ this.query.address = ['1114'];
816
+ this.query.consultationTimeList = [start, end];
817
+ this.toQuery();
818
+ },
819
+
820
+ //弹出框关闭
821
+ dialogClosse() {
822
+ this.currentDetail = {};
823
+ },
824
+ offlineClick(status, prop, title) {
825
+ this.offlineDetailVisiable = true;
826
+ this.clickIndex = status;
827
+ this.dialogText = title;
828
+ // this.
829
+ this.$nextTick(() => {
830
+ this.$refs[prop].toQuery(this.query, status, title);
831
+ });
832
+ },
833
+ //详情
834
+ goCloudDetail(row) {
835
+ // debugger;
836
+ this.cloudDetailVisiable = true;
837
+ this.currentDetail = {
838
+ ...row,
839
+ startTime: this.query.startTime,
840
+ endTime: this.query.endTime,
841
+ softwareType: this.query.softwareType,
842
+ };
843
+ this.$nextTick(() => {
844
+ if (this.currentDetail.hospitalId) {
845
+ this.$refs.cloudListDetail.getCloudDetail(this.currentDetail);
846
+ }
847
+ });
848
+ },
849
+ //改变选择的医院
850
+ changeHospital() {
851
+ this.forceUpdate();
852
+ this.queryHospital();
853
+ this.toQuery();
854
+ },
855
+ toQuery() {
856
+ this.dateChange();
857
+ this.addressChange();
858
+ this.crud.toQuery();
859
+ this.getLineData();
860
+ this.getCloudCount();
861
+ },
862
+
863
+ [CRUD.HOOK.beforeRefresh](crud) {
864
+ Object.keys(this.query).map(key => {
865
+ if (typeof this.query[key] == 'string') {
866
+ this.query[key] = this.query[key].trim();
867
+ }
868
+ });
869
+ if (!this.query.consultationTimeList && !this.crudShow) {
870
+ this.getPosition(null, () => {});
871
+ this.query.consultationTimeList = [start, end];
872
+ this.query.address = ['1114'];
873
+ this.dateChange();
874
+ this.addressChange(1);
875
+ // this.getLineData();
876
+ // this.getCloudCount();
877
+ this.crudShow = true;
878
+ }
879
+ crud.query = {
880
+ ...this.query,
881
+ };
882
+ },
883
+ [CRUD.HOOK.afterRefresh](crud) {
884
+ console.log(crud, 111111);
885
+ },
886
+ },
887
+
888
+ destroyed() {},
889
+
890
+ activated() {
891
+ // this.getCloudCount()
892
+ },
893
+ };
894
+ </script>
895
+ <style lang="scss"></style>
896
+ <style rel="stylesheet/scss" lang="scss" scoped>
897
+ @import './index.scss';
898
+
899
+ .exploreFlex {
900
+ padding: 8px;
901
+ text-align: right;
902
+ }
903
+ </style>