You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2508 lines
81 KiB

2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
11 months ago
2 years ago
11 months ago
11 months ago
11 months ago
11 months ago
2 years ago
1 year ago
11 months ago
1 year ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
11 months ago
2 years ago
11 months ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
11 months ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
1 year ago
1 year ago
1 year ago
1 year ago
11 months ago
11 months ago
11 months ago
1 year ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
11 months ago
11 months ago
1 year ago
2 years ago
11 months ago
2 years ago
11 months ago
1 year ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
1 year ago
11 months ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
1 year ago
2 years ago
11 months ago
2 years ago
1 year ago
11 months ago
1 year ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
1 year ago
11 months ago
1 year ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
1 year ago
1 year ago
2 years ago
1 year ago
11 months ago
2 years ago
2 years ago
2 years ago
1 year ago
2 years ago
2 years ago
1 year ago
1 year ago
11 months ago
11 months ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
1 year ago
2 years ago
11 months ago
1 year ago
11 months ago
2 years ago
11 months ago
1 year ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
11 months ago
2 years ago
2 years ago
2 years ago
1 year ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
11 months ago
2 years ago
2 years ago
2 years ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
1 year ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
1 year ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
1 year ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
2 years ago
1 year ago
1 year ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
12 months ago
1 year ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
11 months ago
11 months ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
2 years ago
2 years ago
1 year ago
11 months ago
1 year ago
2 years ago
2 years ago
1 year ago
11 months ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
2 years ago
12 months ago
11 months ago
12 months ago
11 months ago
1 year ago
11 months ago
1 year ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
2 years ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
2 years ago
1 year ago
2 years ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
2 years ago
1 year ago
2 years ago
11 months ago
1 year ago
2 years ago
1 year ago
1 year ago
2 years ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
2 years ago
1 year ago
2 years ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
2 years ago
2 years ago
2 years ago
1 year ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
1 year ago
2 years ago
1 year ago
1 year ago
1 year ago
11 months ago
2 years ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
2 years ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
1 year ago
1 year ago
11 months ago
2 years ago
1 year ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
11 months ago
1 year ago
2 years ago
2 years ago
2 years ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
11 months ago
2 years ago
11 months ago
11 months ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
11 months ago
2 years ago
11 months ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
  1. <template>
  2. <div>
  3. <!--组件主体-->
  4. <div style="display: flex">
  5. <div
  6. :style="'width:' + (window.pageWidth - 200 - 145) + 'px;'"
  7. @contextmenu.prevent="onContextmenu"
  8. >
  9. <div>
  10. <u-table
  11. :data="tableData"
  12. border
  13. :height="
  14. window.pageHeight < 600
  15. ? 248
  16. : Math.floor(((window.pageHeight - 250) * 2) / 3)
  17. "
  18. highlight-current-row
  19. @row-click="rowClick"
  20. size="small"
  21. row-key="id"
  22. @selection-change="handleSelectionChange"
  23. @row-contextmenu="onCellRightClick"
  24. ref="info"
  25. id="info"
  26. :row-class-name="handleRowClassName"
  27. use-virtual
  28. :row-height="30"
  29. @table-body-scroll="scrollFull"
  30. big-data-checkbox
  31. :data-changes-scroll-top="false"
  32. >
  33. <u-table-column
  34. type="selection"
  35. width="40"
  36. align="center"
  37. ></u-table-column>
  38. <u-table-column
  39. v-for="(item, index) in dragCol"
  40. :key="index"
  41. :type="dragCol[index].type"
  42. :min-width="dragCol[index].minWidth"
  43. :align="dragCol[index].align"
  44. :label="item.label"
  45. :prop="dragCol[index].prop"
  46. :sortable="
  47. dragCol[index].type || dragCol[index].prop == 'sn'
  48. ? false
  49. : true
  50. "
  51. >
  52. <template slot-scope="scope" v-if="!dragCol[index].type">
  53. <div v-if="!dragCol[index].type">
  54. <div v-if="dragCol[index].prop == 'sn'">
  55. {{ scope.$index + 1 }}
  56. </div>
  57. <div
  58. v-else-if="dragCol[index].prop == 'completeFlag'"
  59. :style="`color: ${setPrStatusColor(
  60. scope.row.isAudit,
  61. scope.row.completeFlag
  62. )}`"
  63. >
  64. {{
  65. scope.row.isAudit == "Y"
  66. ? "已审核"
  67. : dddw(
  68. dict.completeFlag,
  69. "id",
  70. scope.row.completeFlag,
  71. "displayName"
  72. )
  73. }}
  74. </div>
  75. <div v-else-if="dragCol[index].prop == 'qztlType'">
  76. {{
  77. dddw(
  78. dict.qztlType,
  79. "id",
  80. scope.row.qztlType,
  81. "displayName"
  82. )
  83. }}
  84. </div>
  85. <div v-else-if="dragCol[index].prop == 'guidePrintTimes'">
  86. <i
  87. class="el-icon-printer"
  88. v-if="scope.row.guidePrintTimes > 0"
  89. style="font-size: 20px; color: green"
  90. />
  91. </div>
  92. <div v-else-if="dragCol[index].prop == 'isLock'">
  93. <i
  94. class="el-icon-lock"
  95. v-if="scope.row.isLock == 'Y'"
  96. style="font-size: 20px; color: red"
  97. />
  98. </div>
  99. <div
  100. v-else-if="
  101. dragCol[index].prop == 'isVip' ||
  102. dragCol[index].prop == 'isUpload' ||
  103. dragCol[index].prop == 'qztlIsMain' ||
  104. dragCol[index].prop == 'qztlIsCy' ||
  105. dragCol[index].prop == 'qztlIsCw' ||
  106. dragCol[index].prop == 'qztlIsGt' ||
  107. dragCol[index].prop == 'qztlIsWh' ||
  108. dragCol[index].prop == 'qztlIsFj'
  109. "
  110. >
  111. {{ scope.row[dragCol[index].prop] == "Y" ? "是" : "否" }}
  112. </div>
  113. <div
  114. v-else-if="dragCol[index].prop == 'customerOrgParentName'"
  115. >
  116. {{
  117. scope.row.customerOrgParentName
  118. ? scope.row.customerOrgParentName
  119. : scope.row.customerOrgName
  120. }}
  121. </div>
  122. <div v-else-if="dragCol[index].prop == 'sexId'">
  123. {{
  124. dddw(
  125. dict.sex,
  126. "id",
  127. scope.row[dragCol[index].prop],
  128. "displayName"
  129. )
  130. }}
  131. </div>
  132. <div v-else-if="dragCol[index].prop == 'groupPack'">
  133. <div
  134. v-if="
  135. scope.row.medicalPackageId !== dict.personOrgId &&
  136. scope.row.customerOrgId === dict.personOrgId
  137. "
  138. >
  139. {{
  140. dddw(
  141. dict.medicalPackage,
  142. "id",
  143. scope.row.medicalPackageId,
  144. "displayName"
  145. )
  146. }}
  147. </div>
  148. <div
  149. v-if="
  150. scope.row.medicalPackageId !== dict.personOrgId &&
  151. scope.row.customerOrgId !== dict.personOrgId
  152. "
  153. >
  154. {{
  155. dddw(
  156. dict.customerOrgGroupAll,
  157. "id",
  158. scope.row.customerOrgGroupId,
  159. "displayName"
  160. )
  161. }}
  162. </div>
  163. </div>
  164. <div v-else-if="dragCol[index].prop == 'nationId'">
  165. {{
  166. dddw(
  167. dict.nation,
  168. "id",
  169. scope.row[dragCol[index].prop],
  170. "displayName"
  171. )
  172. }}
  173. </div>
  174. <div v-else-if="dragCol[index].prop == 'birthDate'">
  175. {{
  176. scope.row[dragCol[index].prop]
  177. ? moment(scope.row[dragCol[index].prop]).format(
  178. "yyyy-MM-DD"
  179. )
  180. : ""
  181. }}
  182. </div>
  183. <div v-else-if="dragCol[index].prop == 'maritalStatusId'">
  184. {{
  185. dddw(
  186. dict.maritalStatus,
  187. "id",
  188. scope.row[dragCol[index].prop],
  189. "displayName"
  190. )
  191. }}
  192. </div>
  193. <div v-else-if="dragCol[index].prop == 'medicalTypeId'">
  194. {{
  195. dddw(
  196. dict.medicalType,
  197. "id",
  198. scope.row[dragCol[index].prop],
  199. "displayName"
  200. )
  201. }}
  202. </div>
  203. <div v-else-if="dragCol[index].prop == 'personnelTypeId'">
  204. {{
  205. dddw(
  206. dict.personnelType,
  207. "id",
  208. scope.row[dragCol[index].prop],
  209. "displayName"
  210. )
  211. }}
  212. </div>
  213. <div v-else-if="dragCol[index].prop == 'idNo'">
  214. {{ scope.row[dragCol[index].prop] }}&#031;
  215. </div>
  216. <div v-else-if="dragCol[index].prop == 'customerOrgName'">
  217. {{
  218. scope.row[dragCol[index].prop] ==
  219. scope.row["customerOrgParentName"]
  220. ? ""
  221. : scope.row[dragCol[index].prop]
  222. }}
  223. </div>
  224. <div v-else>
  225. {{ scope.row[dragCol[index].prop] }}
  226. </div>
  227. </div>
  228. </template>
  229. </u-table-column>
  230. <!--
  231. "sexHormoneTermId": "00000000-0000-0000-0000-000000000000",
  232. "interposeMeasure": null,
  233. "medicalConclusionId": "00000000-0000-0000-0000-000000000000",
  234. "reportPrintTimes": 0,
  235. "isMedicalStart": "N",
  236. "medicalStartDate": "6/28/2023",
  237. "isRecoverGuide": "N",
  238. "summaryDate": "",
  239. "summaryDoctor": null,
  240. "isAudit": "N",
  241. "auditDoctor": null,
  242. "auditDate": "",
  243. "isNameHide": "N",
  244. "isPhoneFollow": "N",
  245. "thirdInfo": null,
  246. "guidePrintTimes": null,
  247. "remark": null,
  248. "medicalCenterId": "00000000-0000-0000-0000-000000000000",
  249. "customerOrgRegisterId": "00000000-0000-0000-0000-000000000000",
  250. "lastModifierName": "",
  251. "lastModificationTime": null,
  252. "lastModifierId": null,
  253. "creatorId": null,
  254. "id": "3a0c196d-a6d0-37fe-5c32-4806bdc4530f"
  255. -->
  256. </u-table>
  257. <div style="display: flex; justify-content: space-between">
  258. <div></div>
  259. <div>
  260. <span style="font-size: 12px"
  261. >{{ loadOpts.totalCount }} 条记录当前显示{{
  262. tableData.length
  263. }}
  264. </span
  265. >
  266. </div>
  267. </div>
  268. </div>
  269. <!-- 组合项目 基本信息 -->
  270. <el-tabs v-model="tabChoosed" style="margin-top: -22px">
  271. <!-- 组合项目 -->
  272. <el-tab-pane label="已选组合项目" name="1">
  273. <PatientRegisterAsbItem />
  274. </el-tab-pane>
  275. </el-tabs>
  276. </div>
  277. <div style="margin-left: 10px">
  278. <div
  279. v-show="checkPagePriv(pagePriv.privs, '导入青藏数据')"
  280. class="listBtn"
  281. >
  282. <el-button
  283. type="success"
  284. class="commonbutton"
  285. @click="btnImportOrgData"
  286. >导入青藏数据</el-button
  287. >
  288. </div>
  289. <div v-show="checkPagePriv(pagePriv.privs, '人员登记')" class="listBtn">
  290. <el-button type="success" class="commonbutton" @click="btnAdd"
  291. >人员登记</el-button
  292. >
  293. </div>
  294. <div
  295. v-show="checkPagePriv(pagePriv.privs, '批量正式登记')"
  296. class="listBtn"
  297. >
  298. <el-button
  299. type="success"
  300. class="commonbutton"
  301. @click="btnAddBatch('1')"
  302. >批量正式登记</el-button
  303. >
  304. </div>
  305. <div
  306. v-show="checkPagePriv(pagePriv.privs, '批量转预登记')"
  307. class="listBtn"
  308. >
  309. <el-button
  310. type="success"
  311. class="commonbutton"
  312. @click="btnAddBatch('0')"
  313. >批量转预登记</el-button
  314. >
  315. </div>
  316. <div v-show="checkPagePriv(pagePriv.privs, '编辑')" class="listBtn">
  317. <el-button type="primary" class="commonbutton" @click="btnEdit"
  318. >编辑</el-button
  319. >
  320. </div>
  321. <div v-show="checkPagePriv(pagePriv.privs, '删除')" class="listBtn">
  322. <el-button type="danger" class="deleteButton" @click="btnDel"
  323. >删除</el-button
  324. >
  325. </div>
  326. <!--
  327. <div class="listBtn">
  328. <el-button
  329. type=""
  330. class="btnClass"
  331. @click="openCamera"
  332. icon="el-icon-camera"
  333. >拍照</el-button
  334. >
  335. </div>
  336. <div class="listBtn">
  337. <el-button type="" class="btnClass commonbutton">健康档案</el-button>
  338. </div>
  339. -->
  340. <div
  341. v-show="checkPagePriv(pagePriv.privs, '批量调整分组')"
  342. class="listBtn"
  343. >
  344. <el-button type="" class="commonbutton" @click="btnGroupBatch"
  345. >批量调整分组</el-button
  346. >
  347. </div>
  348. <div
  349. v-show="checkPagePriv(pagePriv.privs, '批量调整项目')"
  350. class="listBtn"
  351. >
  352. <el-button type="" class="commonbutton" @click="btnAsbBatch"
  353. >批量调整项目</el-button
  354. >
  355. </div>
  356. <div
  357. v-show="checkPagePriv(pagePriv.privs, '指引单打印')"
  358. class="listBtn"
  359. >
  360. <el-button
  361. type=""
  362. class="commonbutton"
  363. @click="guidePrint('0001', false)"
  364. >指引单打印</el-button
  365. >
  366. </div>
  367. <div
  368. v-show="checkPagePriv(pagePriv.privs, '指引单预览')"
  369. class="listBtn"
  370. >
  371. <el-button
  372. type=""
  373. class="commonbutton"
  374. @click="guidePrint('0001', true)"
  375. >指引单预览</el-button
  376. >
  377. </div>
  378. <div
  379. v-show="checkPagePriv(pagePriv.privs, '人员检验检查条码')"
  380. class="listBtn"
  381. >
  382. <el-button
  383. type=""
  384. class="commonbutton"
  385. @click="printPromise()"
  386. style="font-size: 12px"
  387. >人员检验检查条码</el-button
  388. >
  389. </div>
  390. <div
  391. v-show="checkPagePriv(pagePriv.privs, '人员信息导出')"
  392. class="listBtn"
  393. >
  394. <download-excel
  395. :fields="jsonFields"
  396. :fetch="btnExport"
  397. type="xls"
  398. :name="tableName"
  399. >
  400. <el-button type="" style="width:100%">人员信息导出</el-button>
  401. </download-excel>
  402. <!-- <el-button type="" class="commonbutton" @click="btnExport('info')">人员信息导出</el-button> -->
  403. </div>
  404. <div class="listBtn">
  405. <el-button type="" class="commonbutton" @click="btnDragColDesign"
  406. >设计列排序</el-button
  407. >
  408. </div>
  409. <!-- elProgress.display dialogWin.LocalConfig
  410. <div class="listBtn">
  411. <el-button type="" class="commonbutton" @click="dialogWin.LocalConfig = true">本地设置</el-button>
  412. </div>
  413. -->
  414. <!--
  415. <div class="listBtn">
  416. <el-button type="" class="btnClass commonbutton" @click="rowSelected(tableData)">选中</el-button>
  417. </div>
  418. --></div>
  419. </div>
  420. <!--组件弹窗-->
  421. <div>
  422. <!-- 体检人员登记 :title="patientRegister.patientRegisterRd.id ? '体检人员--编辑' : '体检人员--新增'" -->
  423. <el-dialog
  424. :title="
  425. dataTransOpts.tableS.patient_register.id
  426. ? '体检人员--编辑'
  427. : '体检人员--新增'
  428. "
  429. :visible.sync="dialogWin.PatientRegisterEdit"
  430. :close-on-click-modal="false"
  431. fullscreen
  432. @close="close_dialogWin_PatientRegisterEdit"
  433. >
  434. <!-- :formInitData="patientRegister.patientRegisterRd" -->
  435. <PatientRegisterEdit
  436. :isDoctor="'1'"
  437. :patientRegisterId="patientRegister.patientRegisterRd.id"
  438. :editTimes="editTimes"
  439. :refFuncSetData="refFuncSetData"
  440. />
  441. </el-dialog>
  442. <!-- 修改信息 -->
  443. <el-dialog
  444. :title="`修改信息--${upBaseInfo.label}`"
  445. :visible.sync="upBaseInfo.visble"
  446. width="400"
  447. :show-close="false"
  448. :append-to-body="true"
  449. :close-on-click-modal="false"
  450. >
  451. <div>
  452. <div style="display: flex; margin-bottom: 20px">
  453. <span style="padding: 5px 0 0 10px; width: 100px">{{
  454. upBaseInfo.label
  455. }}</span>
  456. <el-input v-model="upBaseInfo.value" size="small"></el-input>
  457. </div>
  458. <div style="display: flex; justify-content: space-between">
  459. <div></div>
  460. <div>
  461. <el-button class="commonbutton" @click="btnUpBaseInfo"
  462. >提交</el-button
  463. >
  464. <el-button
  465. class="commonbutton"
  466. @click="close_dialogWin_upBaseInfo"
  467. >关闭</el-button
  468. >
  469. </div>
  470. </div>
  471. </div>
  472. </el-dialog>
  473. <el-dialog
  474. title="修改信息--体检日期"
  475. :visible.sync="dialogEditMedicalStartDate"
  476. width="400"
  477. :show-close="false"
  478. :append-to-body="true"
  479. :close-on-click-modal="false"
  480. >
  481. <div>
  482. <div style="display: flex; margin-bottom: 20px">
  483. <span style="padding: 5px 0 0 10px; width: 100px">体检日期</span>
  484. <el-date-picker
  485. v-model="upBaseInfo.medicalStartDate"
  486. type="date"
  487. placeholder="体检日期"
  488. size="small"
  489. value-format="yyyy-MM-dd"
  490. :picker-options="pickerOptions"
  491. />
  492. </div>
  493. <div style="display: flex; justify-content: space-between">
  494. <div></div>
  495. <div>
  496. <el-button class="commonbutton" @click="btnEditMedicalStartDate"
  497. >提交</el-button
  498. >
  499. <el-button
  500. class="commonbutton"
  501. @click="dialogEditMedicalStartDate = false"
  502. >关闭</el-button
  503. >
  504. </div>
  505. </div>
  506. </div>
  507. </el-dialog>
  508. <!-- 分诊排队 -->
  509. <el-dialog
  510. title="分诊排队"
  511. :visible.sync="dialogWin.queue"
  512. width="800px"
  513. :append-to-body="true"
  514. :close-on-click-modal="false"
  515. >
  516. <Queue :refParams="queueParams" />
  517. </el-dialog>
  518. <!-- 拍照 -->
  519. <el-dialog
  520. title="拍照"
  521. :visible.sync="patientRegister.cameraVisble"
  522. width="400"
  523. height="800"
  524. :show-close="false"
  525. :append-to-body="true"
  526. :close-on-click-modal="false"
  527. >
  528. <Camera :id="patientRegister.patientRegisterId" />
  529. </el-dialog>
  530. <!-- 导入企业数据 -->
  531. <el-dialog
  532. title="导入企业数据"
  533. :visible.sync="dialogWin.ImportOrgData"
  534. width="800px"
  535. :append-to-body="true"
  536. :close-on-click-modal="false"
  537. >
  538. <ImportOrgData />
  539. </el-dialog>
  540. <!-- 列排序 -->
  541. <el-dialog
  542. title="列排序"
  543. :visible.sync="dialogColSort"
  544. width="300px"
  545. :append-to-body="true"
  546. :close-on-click-modal="false"
  547. >
  548. <el-table
  549. id="elTable_dragCol"
  550. :data="dragColDesign"
  551. row-key="prop"
  552. border
  553. height="600"
  554. >
  555. <el-table-column type="index" label="序号" width="40" align="center">
  556. </el-table-column>
  557. <el-table-column
  558. label="列名"
  559. prop="label"
  560. min-width="120"
  561. align="center"
  562. ></el-table-column>
  563. </el-table>
  564. <span slot="footer" class="dialog-footer">
  565. <el-button class="commonbutton" @click="dialogColSort = false"
  566. >取消</el-button
  567. >
  568. <el-button class="commonbutton" @click="btnDragColDesignOk"
  569. >确定</el-button
  570. >
  571. </span>
  572. </el-dialog>
  573. <!-- 批量调整分组 -->
  574. <el-dialog
  575. title="批量调整分组"
  576. :visible.sync="dialogWin.PatientRegisterEditGroupBatch"
  577. width="600px"
  578. height="800px"
  579. :append-to-body="true"
  580. :close-on-click-modal="false"
  581. >
  582. <PatientRegisterEditGroupBatch :multipleSelection="multipleSelection" />
  583. </el-dialog>
  584. <!-- 批量调整项目 -->
  585. <el-dialog
  586. title="批量调整项目"
  587. :visible.sync="dialogWin.PatientRegisterEditItemBatch"
  588. width="610px"
  589. height="800px"
  590. :append-to-body="true"
  591. :close-on-click-modal="false"
  592. >
  593. <PatientRegisterEditItemBatch :multipleSelection="multipleSelection" />
  594. </el-dialog>
  595. <!-- 批量调整检查项目医生 -->
  596. <el-dialog
  597. title="批量调整检查项目医生"
  598. :visible.sync="dialogWin.PatientRegisterEditDoctorBatch"
  599. width="610px"
  600. :append-to-body="true"
  601. :close-on-click-modal="false"
  602. >
  603. <PatientRegisterEditDoctorBatch
  604. :multipleSelection="multipleSelection"
  605. />
  606. </el-dialog>
  607. <!-- 通用进度条 -->
  608. <el-dialog
  609. title="数据处理中……"
  610. :visible.sync="elProgress.display"
  611. width="600px"
  612. height="400"
  613. :show-close="false"
  614. :close-on-click-modal="false"
  615. :append-to-body="true"
  616. >
  617. <ElProgressOCX />
  618. </el-dialog>
  619. <!--通用本地参数设置-->
  620. <el-dialog
  621. title="本地参数设置"
  622. :visible.sync="dialogWin.LocalConfig"
  623. :close-on-click-modal="false"
  624. :append-to-body="true"
  625. width="800px"
  626. height="600px"
  627. >
  628. <LocalConfig />
  629. </el-dialog>
  630. </div>
  631. </div>
  632. </template>
  633. <script>
  634. import moment from "moment";
  635. import { mapState, mapActions } from "vuex";
  636. import { getapi, postapi, putapi, deletapi } from "@/api/api";
  637. import Sortable from "sortablejs";
  638. import FileSaver from "file-saver";
  639. import html2canvas from "html2canvas";
  640. import JsonExcel from "vue-json-excel";
  641. import {
  642. getPagePriv,
  643. checkPagePriv,
  644. dddw,
  645. objCopy,
  646. arrayReduce,
  647. arrayExistObj,
  648. deepCopy,
  649. setPrStatusColor,
  650. } from "../../utlis/proFunc";
  651. import { savePeoplePhoto } from "../../utlis/proApi";
  652. import PatientRegisterEdit from "../../components/patientRegister/PatientRegisterEdit.vue";
  653. import Camera from "../../components/patientRegister/Camera.vue";
  654. import PatientRegisterAsbItem from "../../components/patientRegister/patientRegisterAsbItem.vue";
  655. import ElProgressOCX from "../../components/report/ElProgressOCX.vue";
  656. import PatientRegisterEditGroupBatch from "./PatientRegisterEditGroupBatch.vue";
  657. import PatientRegisterEditItemBatch from "./PatientRegisterEditItemBatch.vue";
  658. import PatientRegisterEditDoctorBatch from "./PatientRegisterEditDoctorBatch.vue";
  659. import ImportOrgData from "./ImportOrgData.vue";
  660. import LocalConfig from "../../components/common/LocalConfig.vue";
  661. import Queue from "../../components/queue/Queue.vue";
  662. import { UTable, UTableColumn } from 'umy-ui';
  663. export default {
  664. components: {
  665. PatientRegisterEdit,
  666. Camera,
  667. PatientRegisterAsbItem,
  668. PatientRegisterEditGroupBatch, // 批量调整分组
  669. PatientRegisterEditItemBatch, // 批量调整项目
  670. PatientRegisterEditDoctorBatch, // 批量调整检查项目医生
  671. ElProgressOCX,
  672. LocalConfig,
  673. ImportOrgData,
  674. Queue,
  675. DownloadExcel: JsonExcel,
  676. UTable,
  677. UTableColumn
  678. },
  679. data() {
  680. return {
  681. pagePriv: {
  682. routeUrlorPageName: "patientRegister", //当前页面归属路由或归属页面权限名称
  683. privs: [], // 页面权限
  684. },
  685. peisid: null,
  686. startPoint: -1, // 多选起点 -1 表示选择
  687. endPoint: -1, // 多选终点 -1 表示未选择
  688. tableData: [], //表格数据
  689. tableDataCurrentRow: {}, // 当前被选中的行
  690. multipleSelection: [], //选中的数据列表
  691. dialogCamera: false,
  692. tabChoosed: "1",
  693. formInitData: {}, //体检登记初始表单数据
  694. editTimes: 0,
  695. rClickRow: null, //右击的行
  696. rClickColumn: null, //右击的列(预留)
  697. dragColDesign: [], // 待调整的排序的序
  698. //拖动列
  699. dragCol: [
  700. { label: "序号", prop: "sn", minWidth: 40, align: "center" },
  701. {
  702. label: "体检进度",
  703. prop: "completeFlag",
  704. minWidth: 80,
  705. align: "center",
  706. },
  707. {
  708. label: "打印",
  709. prop: "guidePrintTimes",
  710. minWidth: 55,
  711. align: "center",
  712. },
  713. { label: "锁住", prop: "isLock", minWidth: 55, align: "center" },
  714. {
  715. label: "单位",
  716. prop: "customerOrgParentName",
  717. minWidth: 180,
  718. align: "center",
  719. },
  720. {
  721. label: "部门",
  722. prop: "customerOrgName",
  723. minWidth: 120,
  724. align: "center",
  725. },
  726. { label: "姓名", prop: "patientName", minWidth: 80, align: "center" },
  727. { label: "性别", prop: "sexId", minWidth: 55, align: "center" },
  728. { label: "年龄", prop: "age", minWidth: 55, align: "center" },
  729. {
  730. label: "条码号",
  731. prop: "patientRegisterNo",
  732. minWidth: 150,
  733. align: "center",
  734. },
  735. { label: "档案号", prop: "patientNo", minWidth: 100, align: "center" },
  736. {
  737. label: "体检次数",
  738. prop: "medicalTimes",
  739. minWidth: 80,
  740. align: "center",
  741. },
  742. {
  743. label: "分组/套餐",
  744. prop: "groupPack",
  745. minWidth: 150,
  746. align: "center",
  747. },
  748. { label: "民族", prop: "nationId", minWidth: 55, align: "center" },
  749. { label: "身份证", prop: "idNo", minWidth: 160, align: "center" },
  750. { label: "出生日期", prop: "birthDate", minWidth: 80, align: "center" },
  751. { label: "邮箱", prop: "email", minWidth: 150, align: "center" },
  752. {
  753. label: "手机",
  754. prop: "mobileTelephone",
  755. minWidth: 130,
  756. align: "center",
  757. },
  758. { label: "电话", prop: "telephone", minWidth: 130, align: "center" },
  759. { label: "地址", prop: "address", minWidth: 400, align: "" },
  760. {
  761. label: "体检卡号",
  762. prop: "medicalCardNo",
  763. minWidth: 80,
  764. align: "center",
  765. },
  766. { label: "工卡号", prop: "jobCardNo", minWidth: 80, align: "center" },
  767. {
  768. label: "婚姻状况",
  769. prop: "maritalStatusId",
  770. minWidth: 80,
  771. align: "center",
  772. },
  773. {
  774. label: "体检类别",
  775. prop: "medicalTypeId",
  776. minWidth: 80,
  777. align: "center",
  778. },
  779. {
  780. label: "人员类别",
  781. prop: "personnelTypeId",
  782. minWidth: 80,
  783. align: "center",
  784. },
  785. { label: "职务", prop: "jobPost", minWidth: 200, align: "center" },
  786. { label: "职称", prop: "jobTitle", minWidth: 80, align: "center" },
  787. { label: "介绍人", prop: "salesman", minWidth: 80, align: "center" },
  788. { label: "是否VIP", prop: "isVip", minWidth: 80, align: "center" },
  789. { label: "登记人", prop: "creatorName", minWidth: 80, align: "center" },
  790. {
  791. label: "登记日期",
  792. prop: "creationTime",
  793. minWidth: 140,
  794. align: "center",
  795. },
  796. {
  797. label: "体检日期",
  798. prop: "medicalStartDate",
  799. minWidth: 140,
  800. align: "center",
  801. },
  802. { label: "是否上传", prop: "isUpload", minWidth: 80, align: "center" },
  803. { label: "高原/健康", prop: "qztlType", minWidth: 90, align: "center" },
  804. { label: "行车", prop: "qztlIsMain", minWidth: 50, align: "center" },
  805. { label: "从业", prop: "qztlIsCy", minWidth: 50, align: "center" },
  806. { label: "普速", prop: "qztlIsCw", minWidth: 50, align: "center" },
  807. { label: "高铁", prop: "qztlIsGt", minWidth: 50, align: "center" },
  808. { label: "职害", prop: "qztlIsWh", minWidth: 50, align: "center" },
  809. { label: "复检", prop: "qztlIsFj", minWidth: 50, align: "center" },
  810. ],
  811. dialogColSort: false,
  812. jsonFields: {},
  813. dom: null, //用于滚动加载数据
  814. // lazyLoading: false, //是否懒加载中
  815. loadOpts: {
  816. totalCount: 0,
  817. skipCount: 0,
  818. maxResultCount: 100,
  819. },
  820. loadOptsInit: {},
  821. upBaseInfo: {
  822. visble: false,
  823. label: "姓名",
  824. value: "",
  825. colName: "patientName",
  826. patientRegisterId: "",
  827. medicalStartDate: "", // 体检日期
  828. },
  829. dialogEditMedicalStartDate: false, // 修改体检日期
  830. queueParams: {}, // 分诊排队参数
  831. LocalConfig: {
  832. normal: {
  833. maxResultCount: 100, //分页时单页记录数
  834. },
  835. },
  836. LocalConfigInit: {},
  837. tableName:""//导出人员列表表名
  838. };
  839. },
  840. created() {
  841. //获取用户当前页面的权限
  842. let userPriv = window.sessionStorage.getItem("userPriv");
  843. if (userPriv)
  844. this.pagePriv.privs = deepCopy(
  845. getPagePriv(this.pagePriv.routeUrlorPageName)
  846. );
  847. this.LocalConfigInit = deepCopy(this.LocalConfig);
  848. let LocalConfig = window.localStorage.getItem("LocalConfig") || null;
  849. // console.log('LocalConfig',LocalConfig)
  850. try {
  851. this.LocalConfig = Object.assign(
  852. {},
  853. deepCopy(this.LocalConfigInit),
  854. JSON.parse(LocalConfig) || {}
  855. );
  856. } catch (error) {
  857. console.log('window.localStorage.getItem("LocalConfig")', error);
  858. }
  859. // console.log('this.LocalConfig',this.LocalConfig)
  860. this.loadOpts.maxResultCount = Number(
  861. this.LocalConfig.normal.maxResultCount || 100
  862. );
  863. this.loadOptsInit = Object.assign({}, this.loadOpts);
  864. },
  865. //挂载完成
  866. mounted() {
  867. this.quickAsb = this.dict.asbItemAll;
  868. this.peisid = window.sessionStorage.getItem("peisid");
  869. // if(this.$refs.info){
  870. // this.$nextTick(() => {
  871. // this.scrollFull()
  872. // })
  873. // }
  874. },
  875. computed: {
  876. ...mapState([
  877. "pickerOptions",
  878. "window",
  879. "dataTransOpts",
  880. "dialogWin",
  881. "dict",
  882. "elProgress",
  883. "patientRegister",
  884. "customerOrg",
  885. ]),
  886. },
  887. methods: {
  888. ...mapActions(["getCustomerOrgGroup", "getPatientRegisterAbs"]),
  889. moment,
  890. dddw,
  891. deepCopy,
  892. checkPagePriv,
  893. setPrStatusColor,
  894. // 扩展定义表格行样式
  895. handleRowClassName({ row, rowIndex }) {
  896. // highLightBg 为 'selected'的高亮
  897. //// console.log(rowIndex, row)
  898. //return row.highLightBg == 'selected' ? 'high-light-bg' : '';
  899. if (row.choosed) {
  900. return "current-row";
  901. } else {
  902. return "";
  903. }
  904. },
  905. // 行选择
  906. rowSelected(rows) {
  907. rows.forEach((e) => {
  908. this.$refs["info"].toggleRowSelection(e, true);
  909. });
  910. },
  911. refFuncSetData(item, v) {
  912. setData(this, item, v);
  913. },
  914. // 打印指引单(isPreview)
  915. async guidePrint(ReportCode, isPreview) {
  916. if (!this.$peisAPI) {
  917. this.$message.info({
  918. showClose: true,
  919. message: "此功能,需要在壳客户端才可运行!",
  920. });
  921. return;
  922. }
  923. let token = window.sessionStorage.getItem("token");
  924. let user = window.sessionStorage.getItem("user");
  925. let toOutShell = {
  926. ReportCode,
  927. token,
  928. isBuildImage: "N",
  929. IsUploadPdf: "N",
  930. preViewCanPrint: "N",
  931. Parameters: [
  932. { Name: "printer", Value: user },
  933. { Name: "hisLog", Value: "pic/hisLog.jpg" },
  934. { Name: "pageFooter", Value: "pic/peisQrCode.jpg" },
  935. ],
  936. };
  937. let lfind = -1;
  938. //选中(取消勾选)start -------------------------
  939. // this.multipleSelection = []
  940. // this.tableData.forEach(e => {
  941. // if (e.choosed) {
  942. // this.multipleSelection.push(deepCopy(e))
  943. // }
  944. // })
  945. //选中(取消勾选) end  -------------------------
  946. if (this.multipleSelection.length < 1) {
  947. this.$message.info({
  948. showClose: true,
  949. message: "请勾选要打印指引单的人员记录!",
  950. });
  951. return;
  952. }
  953. if (isPreview) {
  954. /*
  955. //this.multipleSelection.forEach((item,index) =>{
  956. postapi(
  957. `/api/app/printreport/getpatientregisterguidereport?PatientRegisterId=${this.multipleSelection[0].id}`
  958. )
  959. .then((res) => {
  960. if (res.code != -1) {
  961. toOutShell.ReportTable = res.data;
  962. // console.log(
  963. "JSON.stringify(toOutShell)",
  964. JSON.stringify(toOutShell)
  965. );
  966. return this.$peisAPI.printPre(JSON.stringify(toOutShell));
  967. }
  968. })
  969. .then(res => {
  970. // console.log('this.$peisAPI.printPre', res)
  971. if (JSON.parse(res).code < 0) {
  972. this.$message.warning(JSON.parse(res).message);
  973. }
  974. })
  975. .catch((err) => {
  976. // console.log('打印指引单', err)
  977. this.$message.warning({ showClose: true, message: err });
  978. });
  979. */
  980. toOutShell.BusinessCode = this.multipleSelection[0].id;
  981. if (this.multipleSelection[0].completeFlag == "0") {
  982. this.$message.warning({
  983. showClose: true,
  984. message: "预登记人员,不可执行此操作!",
  985. });
  986. return;
  987. }
  988. this.$peisAPI
  989. .printPre(JSON.stringify(toOutShell))
  990. .then((res) => {
  991. if (JSON.parse(res).code < 0) {
  992. this.$message.warning({
  993. showClose: true,
  994. message: JSON.parse(res).message,
  995. });
  996. }
  997. })
  998. .catch((err) => {
  999. // console.log('打印指引单', err)
  1000. this.$message.warning({ showClose: true, message: `${err}` });
  1001. });
  1002. } else {
  1003. this.elProgress.display = true;
  1004. this.elProgress.percentage = 0;
  1005. for (let i = 0; i < this.multipleSelection.length; i++) {
  1006. try {
  1007. let patientregisterId = this.multipleSelection[i].id;
  1008. if (this.multipleSelection[i].completeFlag == "0") {
  1009. this.$message.warning({
  1010. showClose: true,
  1011. message: `${this.multipleSelection[i].patientName} 为预登记人员,不可打印指引单`,
  1012. });
  1013. continue;
  1014. }
  1015. toOutShell.BusinessCode = patientregisterId;
  1016. let resPeisAPI = await this.$peisAPI.print(
  1017. JSON.stringify(toOutShell)
  1018. );
  1019. if (JSON.parse(resPeisAPI).code < 0) continue;
  1020. let resPrintTimes = await postapi(
  1021. "/api/app/patientregister/updatepatientregisterguideprinttimesmany",
  1022. [patientregisterId]
  1023. );
  1024. if (resPrintTimes.code == -1) continue;
  1025. lfind = arrayExistObj(this.tableData, "id", patientregisterId);
  1026. if (lfind > -1) {
  1027. if (this.tableData[lfind].guidePrintTimes) {
  1028. this.tableData[lfind].guidePrintTimes =
  1029. Number(this.tableData[lfind].guidePrintTimes) + 1;
  1030. } else {
  1031. this.tableData[lfind].guidePrintTimes = 1;
  1032. }
  1033. }
  1034. } catch (error) {
  1035. // console.log('打印指引单', error)
  1036. this.$message.warning({ showClose: true, message: `${error}` });
  1037. }
  1038. this.elProgress.percentage = Math.floor(
  1039. ((i + 1) * 100) / this.multipleSelection.length
  1040. );
  1041. }
  1042. this.elProgress.display = false;
  1043. }
  1044. },
  1045. // 指引单新打印方式,promise
  1046. guidePrintPromise(ReportCode, isPreview, row) {
  1047. return new Promise((resolve, reject) => {
  1048. if (!this.$peisAPI) reject("此功能,需要在壳客户端才可运行!");
  1049. let token = window.sessionStorage.getItem("token");
  1050. let user = window.sessionStorage.getItem("user");
  1051. let toOutShell = {
  1052. ReportCode,
  1053. token,
  1054. isBuildImage: "N",
  1055. IsUploadPdf: "N",
  1056. preViewCanPrint: "N",
  1057. Parameters: [
  1058. { Name: "printer", Value: user },
  1059. { Name: "hisLog", Value: "pic/hisLog.jpg" },
  1060. { Name: "pageFooter", Value: "pic/peisQrCode.jpg" },
  1061. ],
  1062. };
  1063. if (!row.completeFlag || row.completeFlag == "0")
  1064. reject("预登记人员,不可执行此操作!");
  1065. toOutShell.BusinessCode = row.id;
  1066. console.log(JSON.stringify(toOutShell));
  1067. if (isPreview) {
  1068. this.$peisAPI
  1069. .printPre(JSON.stringify(toOutShell))
  1070. .then((res) => {
  1071. let lres = JSON.parse(res);
  1072. if (lres.code > -1) {
  1073. resolve(lres);
  1074. } else {
  1075. reject(lres.message);
  1076. }
  1077. })
  1078. .catch((err) => {
  1079. reject(err);
  1080. });
  1081. } else {
  1082. this.$peisAPI
  1083. .print(JSON.stringify(toOutShell))
  1084. .then((res) => {
  1085. let lres = JSON.parse(res);
  1086. if (lres.code > -1) {
  1087. return postapi(
  1088. "/api/app/patientregister/updatepatientregisterguideprinttimesmany",
  1089. [row.id]
  1090. );
  1091. } else {
  1092. reject(lres.message);
  1093. }
  1094. })
  1095. .then((res) => {
  1096. if (res && res.code > -1) {
  1097. let lfind = arrayExistObj(this.tableData, "id", row.id);
  1098. if (lfind > -1) {
  1099. if (this.tableData[lfind].guidePrintTimes) {
  1100. this.tableData[lfind].guidePrintTimes =
  1101. Number(this.tableData[lfind].guidePrintTimes) + 1;
  1102. } else {
  1103. this.tableData[lfind].guidePrintTimes = 1;
  1104. }
  1105. }
  1106. }
  1107. resolve(res);
  1108. })
  1109. .catch((err) => {
  1110. reject(err);
  1111. });
  1112. }
  1113. });
  1114. },
  1115. printGuideLisPacs(row) {
  1116. return new Promise((resolve, reject) => {
  1117. this.guidePrintPromise("0008", false, row)
  1118. .then((res) => {
  1119. return this.lisPrint(row, "0002", false);
  1120. })
  1121. .then((res) => {
  1122. return this.pacsPrint(row, "0004", false);
  1123. })
  1124. .then((res) => {
  1125. resolve(res);
  1126. })
  1127. .catch((err) => {
  1128. reject(err);
  1129. });
  1130. });
  1131. },
  1132. async printPromise() {
  1133. if (this.multipleSelection.length < 1) {
  1134. this.$message.info({
  1135. showClose: true,
  1136. message: "请勾选要打印人员检验检查条码的记录!",
  1137. });
  1138. return;
  1139. }
  1140. this.elProgress.display = true;
  1141. this.elProgress.percentage = 0;
  1142. for (let i = 0; i < this.multipleSelection.length; i++) {
  1143. let row = this.multipleSelection[i];
  1144. try {
  1145. await this.printGuideLisPacs(row);
  1146. } catch (error) {
  1147. console.log("printPromise", error);
  1148. }
  1149. this.elProgress.percentage = Math.floor(
  1150. ((i + 1) * 100) / this.multipleSelection.length
  1151. );
  1152. }
  1153. this.elProgress.display = false;
  1154. },
  1155. handleSelectionChange(rows) {
  1156. //this.multipleSelection = rows;
  1157. //// console.log('this.multipleSelection',this.multipleSelection)
  1158. // rows.forEach((item) => {
  1159. // item.highLightBg = "selected";
  1160. // });
  1161. // // 取消全选
  1162. // if (!rows.length) {
  1163. // this.tableData.forEach((item) => {
  1164. // item.highLightBg = "";
  1165. // });
  1166. // }
  1167. this.multipleSelection = rows;
  1168. },
  1169. //设置新增/编辑的form数据
  1170. setForm(formData) {
  1171. this.patientRegister.patientRegisterRd = deepCopy(formData);
  1172. if (!this.patientRegister.patientRegisterRd.id) {
  1173. this.patientRegister.patientRegisterRd.customerOrgId =
  1174. this.patientRegister.query.customerOrgId;
  1175. }
  1176. },
  1177. //点击体检次数行
  1178. rowClick(row) {
  1179. // 按住了shift键
  1180. // if (this.window.shift) {
  1181. // //清除所有选择
  1182. // this.tableData.forEach((e, index) => {
  1183. // e.choosed = false;
  1184. // e.index = index;
  1185. // });
  1186. // if (this.startPoint == -1) {
  1187. // this.tableData[row.index].choosed = true;
  1188. // this.startPoint = row.index;
  1189. // } else {
  1190. // if (this.startPoint > row.index) {
  1191. // for (let i = row.index; i <= this.startPoint; i++) {
  1192. // this.tableData[i].choosed = true;
  1193. // }
  1194. // } else if (this.startPoint <= row.index) {
  1195. // for (let i = this.startPoint; i <= row.index; i++) {
  1196. // this.tableData[i].choosed = true;
  1197. // }
  1198. // }
  1199. // }
  1200. // } else if (this.window.ctrl) { // 按住了ctrl 键
  1201. // this.tableData[row.index].choosed = true;
  1202. // if (this.startPoint == -1) {
  1203. // this.startPoint = row.index;
  1204. // }
  1205. // } else {
  1206. // // 未按住了ctrl 、shift 键
  1207. // //清除所有选择
  1208. // // console.log("清除所有选择");
  1209. // this.tableData.forEach((e, index) => {
  1210. // e.choosed = false;
  1211. // e.index = index;
  1212. // });
  1213. // // console.log(this.tableData, row.index);
  1214. // // console.log(this.tableData[row.index].choosed);
  1215. // this.tableData[row.index].choosed = true;
  1216. // this.startPoint = row.index;
  1217. // }
  1218. //选中了多个点编辑时,排序最前的作为当前选中的
  1219. // console.log('row.index <= this.startPoint', row.index, this.startPoint)
  1220. // let lfind = -1
  1221. // for (let i = 0; i < this.tableData.length; i++) {
  1222. // if (this.tableData[i].choosed) {
  1223. // lfind = i
  1224. // break
  1225. // }
  1226. // }
  1227. // if (lfind > -1) {
  1228. // 弹出编辑框,只有在编辑框显示时,才去触发获取数据
  1229. this.dataTransOpts.tableS.patient_register = deepCopy(row);
  1230. this.tableDataCurrentRow = deepCopy(row);
  1231. this.dataTransOpts.refresh.register_check_asbitem.M++; //触发所选组合项目刷新
  1232. // }
  1233. },
  1234. // 导入企业(青藏公司)数据
  1235. btnImportOrgData() {
  1236. //
  1237. this.dataTransOpts.plus.ImportOrgData++;
  1238. this.dialogWin.ImportOrgData = true;
  1239. },
  1240. //体检次数 相关操作
  1241. btnAdd() {
  1242. if (!this.peisid || this.peisid == "null") {
  1243. this.$message.warning({
  1244. showClose: true,
  1245. message: "该用户未选归属体检中心,不能执行此操作!",
  1246. });
  1247. return;
  1248. }
  1249. let customerOrgId = this.patientRegister.query.customerOrgId;
  1250. if (!customerOrgId) {
  1251. this.$message.warning({ showClose: true, message: "请选择单位或个人" });
  1252. return;
  1253. }
  1254. // this.patientRegister.patientRegisterRdInit.customerOrgId = customerOrgId
  1255. // this.setForm(this.patientRegister.patientRegisterRdInit)
  1256. // this.patientRegister.patientRegisterAbs = [];
  1257. // this.patientRegister.patientRegisterRd.id = ''
  1258. // this.dialogWin.PatientRegisterEdit = true;
  1259. // this.editTimes++; //触发表单窗口,数据更新
  1260. // this.getPatientRegisterAbs();
  1261. this.dataTransOpts.tableS.patient_register.id = "";
  1262. this.dialogWin.PatientRegisterEdit = true;
  1263. this.dataTransOpts.plus.clearPatientRegisterQuery++; //触发清空人员登记界面的查询条件
  1264. setTimeout(() => {
  1265. this.dataTransOpts.refresh.patient_register.S++; //触发人员信息刷新
  1266. }, 10);
  1267. },
  1268. //批量正式登记
  1269. btnAddBatch(completeFlag) {
  1270. let patientRegisterIds = [];
  1271. //取消勾选,换成选择的方式 start
  1272. // this.multipleSelection = [];
  1273. // this.tableData.forEach((e) => {
  1274. // if (e.choosed && e.completeFlag == '0') {
  1275. // this.multipleSelection.push(e);
  1276. // patientRegisterIds.push(e.id)
  1277. // }
  1278. // });
  1279. //取消勾选,换成选择的方式 end
  1280. if (this.multipleSelection.length < 1) {
  1281. this.$message.info({
  1282. showClose: true,
  1283. message: "请勾选要操作的记录!",
  1284. });
  1285. return;
  1286. }
  1287. this.multipleSelection.forEach((e) => {
  1288. switch (completeFlag) {
  1289. case "0":
  1290. if (e.completeFlag == "1") patientRegisterIds.push(e.id);
  1291. break;
  1292. case "1":
  1293. if (e.completeFlag == "0") patientRegisterIds.push(e.id);
  1294. break;
  1295. }
  1296. });
  1297. if (patientRegisterIds.length == 0) {
  1298. this.$message.info({ showClose: true, message: "没有可操作的数据!" });
  1299. return;
  1300. }
  1301. let body = { completeFlag, patientRegisterIds };
  1302. postapi(
  1303. "/api/app/patientregister/updatepatientregistercompleteflagormedicalstartdate",
  1304. body
  1305. )
  1306. .then((res) => {
  1307. if (res.code != -1) {
  1308. // console.log('操作成功!')
  1309. patientRegisterIds.forEach((e) => {
  1310. let lfind = arrayExistObj(this.tableData, "id", e);
  1311. if (lfind > -1) this.tableData[lfind].completeFlag = completeFlag;
  1312. });
  1313. }
  1314. })
  1315. .catch((err) => {
  1316. this.$message.error({ showClose: true, message: `操作失败 ${err}` });
  1317. });
  1318. },
  1319. // 单个编辑
  1320. btnEdit() {
  1321. // if (!this.patientRegister.patientRegisterRd.id) {
  1322. if (!this.dataTransOpts.tableS.patient_register.id) {
  1323. this.$message.warning({
  1324. showClose: true,
  1325. message: "请选择要操作的记录",
  1326. });
  1327. return;
  1328. }
  1329. //// console.log(this.patientRegister.patientRegisterRd,this.tableData)
  1330. // 触发数据刷新
  1331. this.dataTransOpts.refresh.patient_register.S++; //触发人员信息刷新(会同时刷新组合项目)
  1332. this.dataTransOpts.plus.clearPatientRegisterQuery++; //触发清空人员登记界面的查询条件
  1333. this.dialogWin.PatientRegisterEdit = true;
  1334. },
  1335. //新增或编辑后选中记录
  1336. async close_dialogWin_PatientRegisterEdit() {
  1337. // 如果 dataTransOpts.tableS.patient_register.id 为空(未增加),则不做处理
  1338. let id = this.dataTransOpts.tableS.patient_register.id;
  1339. if (!id) {
  1340. id = this.tableDataCurrentRow.id;
  1341. }
  1342. if (!id) return;
  1343. this.dataTransOpts.tableS.patient_register.id = id;
  1344. let res = await postapi("/api/app/patientregister/getlistinfilter", {
  1345. patientRegisterNo:
  1346. this.dataTransOpts.tableS.patient_register.patientRegisterNo,
  1347. });
  1348. if (res.code != 1) return;
  1349. let currentRow = res.data.items[0];
  1350. // this.tableData.forEach(e => {
  1351. // e.choosed = false
  1352. // });
  1353. let lfind = arrayExistObj(
  1354. this.tableData,
  1355. "id",
  1356. this.dataTransOpts.tableS.patient_register.id
  1357. );
  1358. if (lfind > -1) {
  1359. objCopy(currentRow, this.tableData[lfind]);
  1360. } else {
  1361. lfind = this.tableData.length;
  1362. currentRow.index = lfind;
  1363. currentRow.choosed = true;
  1364. this.tableData.push(currentRow);
  1365. }
  1366. // 刷新 register_check_asbitem 表记录
  1367. if (lfind > -1) {
  1368. this.dataTransOpts.refresh.register_check_asbitem.M++;
  1369. }
  1370. },
  1371. //拍照
  1372. openCamera() {
  1373. if (!this.patientRegister.patientRegisterId) {
  1374. this.$message.warning({
  1375. showClose: true,
  1376. message: "请选择要操作的记录",
  1377. });
  1378. return;
  1379. }
  1380. this.patientRegister.cameraVisble = true;
  1381. },
  1382. //删除(可批量删除)
  1383. // /api/app/patient-register/many?PatientRegisterIds=3a0c2cac-f44c-f407-9504-c1fc5e80a159&PatientRegisterIds=3a0c2cb3-d10c-ed70-db6a-b835e75ce641
  1384. btnDel() {
  1385. //选中(取消勾选)start -------------------------
  1386. // this.multipleSelection = []
  1387. // this.tableData.forEach(e => {
  1388. // if (e.choosed) {
  1389. // this.multipleSelection.push(deepCopy(e))
  1390. // }
  1391. // })
  1392. //选中(取消勾选) end -------------------------
  1393. if (this.multipleSelection.length < 1) {
  1394. this.$message.warning({
  1395. showClose: true,
  1396. message: "请先勾选要操作的记录",
  1397. });
  1398. return;
  1399. }
  1400. let patientRegisterIds = [];
  1401. for (let i = 0; i < this.multipleSelection.length; i++) {
  1402. patientRegisterIds.push(this.multipleSelection[i]["id"]);
  1403. }
  1404. this.$confirm("此操作将永久删除该记录, 是否继续?", "提示", {
  1405. confirmButtonText: "是",
  1406. cancelButtonText: "否",
  1407. type: "warning",
  1408. })
  1409. .then(() => {
  1410. //// console.log('{patientRegisterIds}',{patientRegisterIds})
  1411. return postapi("/api/app/patient-register/delete-many", {
  1412. patientRegisterIds,
  1413. });
  1414. })
  1415. .then((res) => {
  1416. if (res.code != -1) {
  1417. // console.log("操作成功");
  1418. this.dataTransOpts.tableS.patient_register.id = "";
  1419. setTimeout(() => {
  1420. this.dataTransOpts.refresh.register_check_asbitem.M++;
  1421. }, 10);
  1422. arrayReduce(this.tableData, this.multipleSelection, "id=id"); //清除列表记录
  1423. // this.setForm(this.patientRegister.patientRegisterRdInit)
  1424. // this.getPatientRegisterAbs();
  1425. }
  1426. })
  1427. .catch((err) => {
  1428. if (err == "cancel") {
  1429. this.$message.info({ showClose: true, message: "已取消操作" });
  1430. }
  1431. });
  1432. },
  1433. //查询
  1434. async Query() {
  1435. // 查询时,清掉明细数据 (滚动时不清)
  1436. this.dataTransOpts.tableS.patient_register.id = "";
  1437. this.tableDataCurrentRow = {}; // 清除选择
  1438. if (
  1439. !(
  1440. this.patientRegister.query.isSeries == "Y" &&
  1441. this.patientRegister.query.patientRegisterNo
  1442. )
  1443. ) {
  1444. this.tableData = [];
  1445. }
  1446. setTimeout(() => {
  1447. this.dataTransOpts.refresh.register_check_asbitem.M++; //触发所选组合项目刷新
  1448. }, 10);
  1449. this.loadOpts = Object.assign(this.loadOpts, this.loadOptsInit);
  1450. await this.getPrList();
  1451. },
  1452. //数据量多时,滚动加载
  1453. async load() {
  1454. this.loadOpts.skipCount++;
  1455. await this.getPrList();
  1456. },
  1457. // 获取列表数据
  1458. async getPrList() {
  1459. if (
  1460. this.loadOpts.skipCount != 0 &&
  1461. this.loadOpts.skipCount * this.loadOpts.maxResultCount >=
  1462. this.loadOpts.totalCount
  1463. )
  1464. return;
  1465. // console.log('getPrList', this.loadOpts)
  1466. let body = {
  1467. skipCount: this.loadOpts.skipCount,
  1468. maxResultCount: this.loadOpts.maxResultCount,
  1469. };
  1470. // console.log(`this.patientRegister.query`, this.patientRegister.query);
  1471. if (this.patientRegister.query.customerOrgFlag) {
  1472. // if (this.patientRegister.query.CustomerOrgParentId) {
  1473. // body.customerOrgId = this.patientRegister.query.CustomerOrgParentId;
  1474. // } else {
  1475. // if (this.patientRegister.query.customerOrgId)
  1476. // body.customerOrgId = this.patientRegister.query.customerOrgId;
  1477. // }
  1478. if (this.patientRegister.query.customerOrgId)
  1479. body.customerOrgId = this.patientRegister.query.customerOrgId;
  1480. if (
  1481. this.patientRegister.query.customerOrgId &&
  1482. this.patientRegister.query.customerOrgId != this.dict.personOrgId &&
  1483. this.patientRegister.query.customerOrgRegister.id
  1484. ) {
  1485. body.customerOrgRegisterId =
  1486. this.patientRegister.query.customerOrgRegister.id;
  1487. body.customerOrgGroupIds =
  1488. this.patientRegister.query.customerOrgGroupIds;
  1489. }
  1490. }
  1491. if (this.patientRegister.query.sex)
  1492. body.sexId = this.patientRegister.query.sex;
  1493. if (this.patientRegister.query.patientName)
  1494. body.patientName = this.patientRegister.query.patientName;
  1495. if (
  1496. this.patientRegister.query.medicalTypeIds &&
  1497. this.patientRegister.query.medicalTypeIds.length > 0
  1498. )
  1499. body.medicalTypeIds = this.patientRegister.query.medicalTypeIds;
  1500. if (
  1501. this.patientRegister.query.completeFlags &&
  1502. this.patientRegister.query.completeFlags.length > 0
  1503. )
  1504. body.completeFlags = this.patientRegister.query.completeFlags;
  1505. //StartDate EndDate
  1506. if (
  1507. this.patientRegister.query.startDate &&
  1508. this.patientRegister.query.endDate
  1509. ) {
  1510. body.dateType = this.patientRegister.query.dateType;
  1511. body.startDate = moment(this.patientRegister.query.startDate).format(
  1512. "yyyy-MM-DD"
  1513. );
  1514. body.endDate = moment(this.patientRegister.query.endDate).format(
  1515. "yyyy-MM-DD"
  1516. );
  1517. if (body.startDate > body.endDate) {
  1518. this.$message.warning({
  1519. showClose: true,
  1520. message: "起始日期不能大于截止日期,数据校验不通过!",
  1521. });
  1522. return;
  1523. }
  1524. }
  1525. if (this.patientRegister.query.phone)
  1526. body.phone = this.patientRegister.query.phone;
  1527. if (this.patientRegister.query.idCardNo) {
  1528. body.idNo = this.patientRegister.query.idCardNo;
  1529. try {
  1530. let sysParmId = "patient_register_query_idno";
  1531. let sysParam = await postapi(
  1532. "/api/app/SysParmValue/GetSysParmValueBySysParmId",
  1533. { sysParmId }
  1534. );
  1535. // console.log('sysParam', sysParam)
  1536. if (sysParam.data != "N") {
  1537. body = {
  1538. idNo: this.patientRegister.query.idCardNo,
  1539. skipCount: this.loadOpts.skipCount,
  1540. maxResultCount: this.loadOpts.maxResultCount,
  1541. };
  1542. }
  1543. } catch (error) {
  1544. console.log(error);
  1545. }
  1546. }
  1547. if (this.patientRegister.query.patientNo)
  1548. body = {
  1549. patientNo: this.patientRegister.query.patientNo,
  1550. skipCount: this.loadOpts.skipCount,
  1551. maxResultCount: this.loadOpts.maxResultCount,
  1552. };
  1553. if (this.patientRegister.query.patientRegisterNo)
  1554. body = {
  1555. patientRegisterNo: this.patientRegister.query.patientRegisterNo,
  1556. skipCount: this.loadOpts.skipCount,
  1557. maxResultCount: this.loadOpts.maxResultCount,
  1558. };
  1559. // console.log("/api/app/patientregister/getlistinfilter", body);
  1560. let upPhoto = "patient_register_read_idno_upPhoto"; // 是否读身份证查询更新照片
  1561. let upPhotoParam = await postapi(
  1562. "/api/app/SysParmValue/GetSysParmValueBySysParmId",
  1563. { sysParmId: upPhoto }
  1564. );
  1565. let photo = this.patientRegister.photo;
  1566. this.patientRegister.photo = "";
  1567. postapi("/api/app/patientregister/getlistinfilter", body).then(
  1568. async (res) => {
  1569. if (res.code > -1) {
  1570. // 刷新最大记录数
  1571. this.loadOpts.totalCount = res.data.totalCount;
  1572. let curLoad = res.data.items;
  1573. // let oldCount = 0
  1574. // 处理:
  1575. // 1、分组/套餐 排序混乱的问题
  1576. // 2、扫身份证查询时,无照片自动更新照片(参数控制)
  1577. curLoad.forEach((e) => {
  1578. // 1、分组/套餐 排序混乱的问题
  1579. if (e.customerOrgId == this.dict.personOrgId) {
  1580. e.groupPack = e.medicalPackageId;
  1581. } else {
  1582. e.groupPack = e.customerOrgGroupId;
  1583. }
  1584. // 2、扫身份证查询时,无照片自动更新照片(参数控制)
  1585. if (upPhotoParam != "N" && photo) {
  1586. if (!e.photo) {
  1587. savePeoplePhoto(e.id, photo);
  1588. }
  1589. }
  1590. });
  1591. // 不是连续扫码时,需要判断是否分页查询(连续扫码不清原来的数据)
  1592. console.log(
  1593. "this.patientRegister.query",
  1594. this.patientRegister.query.isSeries,
  1595. this.patientRegister.query.patientRegisterNo
  1596. );
  1597. if (
  1598. !(
  1599. this.patientRegister.query.isSeries == "Y" &&
  1600. this.patientRegister.query.patientRegisterNo
  1601. )
  1602. ) {
  1603. if (body.skipCount == 0) {
  1604. //查询
  1605. this.tableData = [];
  1606. }
  1607. }
  1608. this.tableData = this.tableData.concat(curLoad);
  1609. // else {
  1610. // // 懒加载 ,原数据集不用清空
  1611. // oldCount = this.tableData.length
  1612. // }
  1613. // curLoad.forEach((e, index) => {
  1614. // this.tableData.push(Object.assign({ index: Number(oldCount) + Number(index), choosed: false }, e))
  1615. // })
  1616. //如果 有选中 记录,则刷新其对应的组合项目
  1617. if (this.dataTransOpts.tableS.patient_register.id) {
  1618. this.dataTransOpts.refresh.register_check_asbitem.M++;
  1619. }
  1620. }
  1621. }
  1622. );
  1623. },
  1624. //滚动加载数据
  1625. async scrollFull(scroll, event) {
  1626. if (scroll.judgeFlse) {
  1627. if (
  1628. (Number(this.loadOpts.skipCount) + 1) *
  1629. Number(this.loadOpts.maxResultCount) >=
  1630. Number(this.loadOpts.totalCount)
  1631. ) {
  1632. return;
  1633. } else {
  1634. await this.load();
  1635. }
  1636. }
  1637. // this.dom = this.$refs.info.bodyWrapper
  1638. // console.log('this.dom', this.dom)
  1639. // this.dom.addEventListener('scroll', async () => {
  1640. // // // console.log('scrollTop',this.dom.scrollTop,'clientHeight',this.dom.clientHeight,'scrollHeight',this.dom.scrollHeight);
  1641. // if (this.dom.scrollTop + this.dom.clientHeight + 20 > this.dom.scrollHeight && !this.lazyLoading) {
  1642. // // 获取到的不是全部数据 当滚动到底部
  1643. // // console.log('scrollTop', this.dom.scrollTop, 'clientHeight', this.dom.clientHeight, 'scrollHeight', this.dom.scrollHeight);
  1644. // if ((Number(this.loadOpts.skipCount) + 1) * Number(this.loadOpts.maxResultCount) >= Number(this.loadOpts.totalCount)) {
  1645. // this.lazyLoading = false
  1646. // } else {
  1647. // this.lazyLoading = true
  1648. // await this.load()
  1649. // this.lazyLoading = false
  1650. // // this.dom.scrollTop = this.dom.scrollTop - 100
  1651. // }
  1652. // }
  1653. // })
  1654. },
  1655. close_dialogWin_upBaseInfo() {
  1656. this.upBaseInfo.visble = false;
  1657. this.close_dialogWin_PatientRegisterEdit();
  1658. },
  1659. btnUpBaseInfo() {
  1660. let body = {
  1661. patientRegisterId: this.upBaseInfo.patientRegisterId,
  1662. // "patientName": "string",
  1663. // "mobileTelephone": "string",
  1664. // "idNo": "string"
  1665. };
  1666. body[this.upBaseInfo.colName] = this.upBaseInfo.value;
  1667. postapi(
  1668. "/api/app/PatientRegister/UpdatePatientRegisterBaseInfoByPatientRegisterId",
  1669. body
  1670. ).then((res) => {
  1671. if (res.code > -1) {
  1672. this.close_dialogWin_upBaseInfo();
  1673. }
  1674. });
  1675. },
  1676. // 修改基本信息
  1677. fnUpBaseInfo(row, baseInfoType) {
  1678. this.dataTransOpts.tableS.patient_register.id = row.id;
  1679. this.upBaseInfo.visble = true;
  1680. this.upBaseInfo.patientRegisterId = row.id;
  1681. this.upBaseInfo.colName = baseInfoType;
  1682. switch (baseInfoType) {
  1683. case "idNo":
  1684. this.upBaseInfo.label = "新身份证号";
  1685. break;
  1686. case "mobileTelephone":
  1687. this.upBaseInfo.label = "新手机号";
  1688. break;
  1689. default:
  1690. this.upBaseInfo.label = "新姓名";
  1691. break;
  1692. }
  1693. this.upBaseInfo.value = row[baseInfoType];
  1694. },
  1695. editMedicalStartDate() {
  1696. if (this.multipleSelection.length < 1) {
  1697. this.$message.warning({
  1698. showClose: true,
  1699. message: "请勾选要操作的人员记录!",
  1700. });
  1701. return;
  1702. }
  1703. this.upBaseInfo.medicalStartDate = moment(
  1704. this.multipleSelection[0].medicalStartDate
  1705. ).format("yyyy-MM-DD");
  1706. this.dialogEditMedicalStartDate = true;
  1707. },
  1708. // 批量修改体检日期
  1709. btnEditMedicalStartDate() {
  1710. let body = {
  1711. //"completeFlag": "string",
  1712. medicalStartDate: this.upBaseInfo.medicalStartDate,
  1713. patientRegisterIds: [],
  1714. };
  1715. this.multipleSelection.forEach((e) => {
  1716. body.patientRegisterIds.push(e.id);
  1717. });
  1718. postapi(
  1719. "/api/app/PatientRegister/UpdatePatientRegisterMedicalStartDate",
  1720. body
  1721. ).then((res) => {
  1722. if (res.code > -1) {
  1723. let lfind = 0;
  1724. this.multipleSelection.forEach((e) => {
  1725. e.medicalStartDate = body.medicalStartDate;
  1726. lfind = arrayExistObj(this.tableData, "id", e.id);
  1727. if (lfind > -1)
  1728. this.tableData.medicalStartDate = body.medicalStartDate;
  1729. });
  1730. this.dialogEditMedicalStartDate = false;
  1731. }
  1732. });
  1733. },
  1734. // 分诊排队
  1735. fnQueue(row) {
  1736. this.queueParams = {
  1737. patientRegisterId: row.id,
  1738. };
  1739. this.dialogWin.queue = true;
  1740. this.dataTransOpts.plus.queue++;
  1741. },
  1742. //右击菜单
  1743. onCellRightClick(row, column) {
  1744. // console.log(row)
  1745. this.rClickRow = { ...row }; //右击的行记录
  1746. this.rClickColumn = { ...column }; //右击的列(预留)
  1747. // console.log(row, column.property);
  1748. // this.onContextmenu()
  1749. },
  1750. onContextmenu(event) {
  1751. // console.log('onContextmenu',event);
  1752. if (!this.rClickRow) return false;
  1753. let row = { ...this.rClickRow };
  1754. let items = []; //菜单项
  1755. // items.push({
  1756. // label: "一级菜单",
  1757. // children: [
  1758. // { label: "修改姓名", onClick: () => { this.fnUpBaseInfo(row, 'patientName'); } }
  1759. // ]
  1760. // })
  1761. let subMenumedical = [];
  1762. if (checkPagePriv(this.pagePriv.privs, "修改体检日期"))
  1763. subMenumedical.push({
  1764. label: "修改体检日期",
  1765. onClick: () => {
  1766. this.editMedicalStartDate();
  1767. },
  1768. });
  1769. if (
  1770. checkPagePriv(this.pagePriv.privs, "修改姓名") &&
  1771. row.completeFlag != "0"
  1772. )
  1773. subMenumedical.push({
  1774. label: "修改姓名",
  1775. onClick: () => {
  1776. this.fnUpBaseInfo(row, "patientName");
  1777. },
  1778. });
  1779. if (
  1780. checkPagePriv(this.pagePriv.privs, "修改手机号") &&
  1781. row.completeFlag != "0"
  1782. )
  1783. subMenumedical.push({
  1784. label: "修改手机号",
  1785. onClick: () => {
  1786. this.fnUpBaseInfo(row, "mobileTelephone");
  1787. },
  1788. });
  1789. if (
  1790. checkPagePriv(this.pagePriv.privs, "修改身份证号") &&
  1791. row.completeFlag != "0"
  1792. )
  1793. subMenumedical.push({
  1794. label: "修改身份证号",
  1795. onClick: () => {
  1796. this.fnUpBaseInfo(row, "idNo");
  1797. },
  1798. });
  1799. if (subMenumedical.length > 0)
  1800. items.push({ label: "修改体检信息", children: subMenumedical });
  1801. if (
  1802. checkPagePriv(this.pagePriv.privs, "分诊排队") &&
  1803. row.completeFlag != "0"
  1804. )
  1805. items.push({
  1806. label: "分诊排队",
  1807. onClick: () => {
  1808. this.fnQueue(row);
  1809. },
  1810. });
  1811. if (
  1812. checkPagePriv(this.pagePriv.privs, "发送检验申请") &&
  1813. row.completeFlag != "0"
  1814. )
  1815. items.push({
  1816. label: "发送检验申请",
  1817. onClick: () => {
  1818. this.lisRequest(row);
  1819. },
  1820. });
  1821. // 预览条码
  1822. let subMenuPre = [];
  1823. if (
  1824. checkPagePriv(this.pagePriv.privs, "预览人员条码") &&
  1825. row.completeFlag != "0"
  1826. )
  1827. subMenuPre.push({
  1828. label: "预览人员条码",
  1829. onClick: () => {
  1830. this.guidePrintPromise("0008", true, row);
  1831. },
  1832. });
  1833. if (
  1834. checkPagePriv(this.pagePriv.privs, "预览检验条码") &&
  1835. row.completeFlag != "0"
  1836. )
  1837. subMenuPre.push({
  1838. label: "预览检验条码",
  1839. onClick: () => {
  1840. this.lisPrint(row, "0002", true);
  1841. },
  1842. });
  1843. if (
  1844. checkPagePriv(this.pagePriv.privs, "预览Pacs条码") &&
  1845. row.completeFlag != "0"
  1846. )
  1847. subMenuPre.push({
  1848. label: "预览Pacs条码",
  1849. onClick: () => {
  1850. // console.log('预览Pacs条码 row',row)
  1851. this.pacsPrint(row, "0004", true);
  1852. },
  1853. });
  1854. if (subMenuPre.length > 0)
  1855. items.push({ label: "预览条码", children: subMenuPre });
  1856. let subMenuPrint = [];
  1857. if (
  1858. checkPagePriv(this.pagePriv.privs, "打印人员条码") &&
  1859. row.completeFlag != "0"
  1860. )
  1861. subMenuPrint.push({
  1862. label: "打印人员条码",
  1863. onClick: () => {
  1864. this.guidePrintPromise("0008", false, row);
  1865. },
  1866. });
  1867. if (
  1868. checkPagePriv(this.pagePriv.privs, "打印检验条码") &&
  1869. row.completeFlag != "0"
  1870. )
  1871. subMenuPrint.push({
  1872. label: "打印检验条码",
  1873. onClick: () => {
  1874. this.lisPrint(row, "0002", false);
  1875. },
  1876. });
  1877. if (
  1878. checkPagePriv(this.pagePriv.privs, "打印Pacs条码") &&
  1879. row.completeFlag != "0"
  1880. )
  1881. subMenuPrint.push({
  1882. label: "打印Pacs条码",
  1883. onClick: () => {
  1884. this.pacsPrint(row, "0004", false);
  1885. },
  1886. });
  1887. if (subMenuPrint.length > 0)
  1888. items.push({ label: "打印条码", children: subMenuPrint });
  1889. let subMenuImp = [];
  1890. if (
  1891. checkPagePriv(this.pagePriv.privs, "导入检查结果") &&
  1892. row.completeFlag != "0"
  1893. )
  1894. subMenuImp.push({
  1895. label: "导入检查结果",
  1896. onClick: () => {
  1897. this.importResult("pacs", row);
  1898. },
  1899. });
  1900. if (
  1901. checkPagePriv(this.pagePriv.privs, "导入检验结果") &&
  1902. row.completeFlag != "0"
  1903. )
  1904. subMenuImp.push({
  1905. label: "导入检验结果",
  1906. onClick: () => {
  1907. this.importResult("lis", row);
  1908. },
  1909. });
  1910. if (subMenuImp.length > 0)
  1911. items.push({ label: "导入结果", children: subMenuImp });
  1912. if (
  1913. checkPagePriv(this.pagePriv.privs, "批量更新组合项目明细") &&
  1914. this.multipleSelection.length > 0
  1915. )
  1916. items.push({
  1917. label: "批量更新组合项目明细",
  1918. onClick: () => {
  1919. this.btnItemBatch();
  1920. },
  1921. });
  1922. if (
  1923. checkPagePriv(this.pagePriv.privs, "调整检查项目医生") &&
  1924. this.multipleSelection.length > 0
  1925. )
  1926. items.push({
  1927. label: "调整检查项目医生",
  1928. onClick: () => {
  1929. this.dataTransOpts.plus.PatientRegisterEditDoctorBatch++; //如果放在弹窗显示后面,在首次加载子组件时,会触发两次数据处理
  1930. this.dialogWin.PatientRegisterEditDoctorBatch = true;
  1931. },
  1932. });
  1933. items.push({ label: "----------------" });
  1934. this.$contextmenu({
  1935. items,
  1936. event,
  1937. x: event.clientX,
  1938. y: event.clientY,
  1939. customClass: "custom-class",
  1940. zIndex: 3,
  1941. minWidth: 80,
  1942. });
  1943. this.rClickRow = null;
  1944. return false;
  1945. },
  1946. //批量更新分组按钮
  1947. btnGroupBatch() {
  1948. let customerOrgId = this.patientRegister.query.customerOrgId;
  1949. if (!customerOrgId) {
  1950. this.$message.warning({ showClose: true, message: "请选择单位" });
  1951. return;
  1952. }
  1953. //取消勾选,换成选择的方式 start
  1954. // this.multipleSelection = [];
  1955. // this.tableData.forEach((e) => {
  1956. // if (e.choosed) this.multipleSelection.push(e);
  1957. // });
  1958. //取消勾选,换成选择的方式 end
  1959. if (this.multipleSelection.length < 1) {
  1960. this.$message.info({
  1961. showClose: true,
  1962. message: "请选择要操作的记录!",
  1963. });
  1964. return;
  1965. }
  1966. this.dataTransOpts.plus.PatientRegisterEditGroupBatch++;
  1967. this.dialogWin.PatientRegisterEditGroupBatch = true;
  1968. },
  1969. //批量更新组合项目
  1970. btnAsbBatch() {
  1971. let customerOrgId = this.patientRegister.query.customerOrgId;
  1972. if (!customerOrgId) {
  1973. this.$message.warning({ showClose: true, message: "请选择单位" });
  1974. return;
  1975. }
  1976. //取消勾选,换成选择的方式 start
  1977. // this.multipleSelection = [];
  1978. // this.tableData.forEach((e) => {
  1979. // if (e.choosed) this.multipleSelection.push(e);
  1980. // });
  1981. //取消勾选,换成选择的方式 end
  1982. if (this.multipleSelection.length < 1) {
  1983. this.$message.warning({
  1984. showClose: true,
  1985. message: "请选择要操作的记录",
  1986. });
  1987. return;
  1988. }
  1989. this.dataTransOpts.plus.PatientRegisterEditItemBatch++; //如果放在弹窗显示后面,在首次加载子组件时,会触发两次数据处理
  1990. this.dialogWin.PatientRegisterEditItemBatch = true;
  1991. },
  1992. //批量更新组合项目
  1993. async btnItemBatch() {
  1994. if (this.multipleSelection.length < 1) {
  1995. this.$message.warning({
  1996. showClose: true,
  1997. message: "请选择要操作的记录",
  1998. });
  1999. return;
  2000. }
  2001. this.elProgress.display = true;
  2002. this.elProgress.percentage = 0;
  2003. for (let i = 0; i < this.multipleSelection.length; i++) {
  2004. let patientRegisterId = this.multipleSelection[i].id;
  2005. try {
  2006. await postapi("/api/app/RegisterCheckItem/SyncRegisterCheckItem", {
  2007. patientRegisterId,
  2008. });
  2009. } catch (error) {
  2010. console.log("printPromise", error);
  2011. }
  2012. this.elProgress.percentage = Math.floor(
  2013. ((i + 1) * 100) / this.multipleSelection.length
  2014. );
  2015. }
  2016. this.elProgress.display = false;
  2017. },
  2018. //检验申请
  2019. async lisRequest(row) {
  2020. let isPrintLisRequest = false;
  2021. let res = null;
  2022. if (row.completeFlag == "0") {
  2023. this.$message.info({
  2024. showClose: true,
  2025. message: "预登记人员,不可执行此操作!",
  2026. });
  2027. return;
  2028. }
  2029. try {
  2030. res = await postapi(
  2031. `/api/app/lisrequest/setlisrequest?PatientRegisterId=${row.id}`
  2032. );
  2033. // console.log(`/ api / app / lisrequest / setlisrequest ? PatientRegisterId = ${ prId }`,res);
  2034. } catch (error) {
  2035. return;
  2036. }
  2037. if (res.code > -1) {
  2038. isPrintLisRequest = true;
  2039. }
  2040. //重复申请,重打
  2041. if (res.code == -1 && res.message.indexOf("已申请") > -1) {
  2042. isPrintLisRequest = true;
  2043. }
  2044. if (!isPrintLisRequest) return;
  2045. try {
  2046. await this.$confirm("是否打印检验申请单?", "提示", {
  2047. confirmButtonText: "是",
  2048. cancelButtonText: "否",
  2049. type: "info",
  2050. showClose: false,
  2051. closeOnClickModal: false,
  2052. closeOnPressEscape: false,
  2053. });
  2054. } catch (error) {
  2055. return;
  2056. }
  2057. //打印检验申请单
  2058. this.lisPrint(row, "0003", false);
  2059. },
  2060. //检验条码打印 改造成 promise
  2061. lisPrint(row, ReportCode, isPreview) {
  2062. return new Promise((resolve, reject) => {
  2063. if (!this.$peisAPI) reject("此功能,需要在壳客户端才可运行!");
  2064. if (!row.completeFlag || row.completeFlag == "0")
  2065. reject("预登记人员,不可执行此操作!");
  2066. let token = window.sessionStorage.getItem("token");
  2067. let user = window.sessionStorage.getItem("user");
  2068. let toOutShell = {
  2069. ReportCode,
  2070. token,
  2071. IsMoreLabel: "Y",
  2072. isBuildImage: "N",
  2073. IsUploadPdf: "N",
  2074. preViewCanPrint: "N",
  2075. Parameters: [
  2076. { Name: "printer", Value: user },
  2077. { Name: "hisLog", Value: "pic/hisLog.jpg" },
  2078. ],
  2079. BusinessCode: row.id,
  2080. };
  2081. console.log("this.$peisAPI.toOutShell", toOutShell);
  2082. if (isPreview) {
  2083. this.$peisAPI
  2084. .printPre(JSON.stringify(toOutShell))
  2085. .then((res) => {
  2086. console.log("this.$peisAPI.printPre", res);
  2087. let lres = JSON.parse(res);
  2088. if (lres.code > -1) {
  2089. resolve(lres);
  2090. } else {
  2091. reject(lres.message);
  2092. }
  2093. })
  2094. .catch((err) => {
  2095. reject(err);
  2096. });
  2097. } else {
  2098. this.$peisAPI
  2099. .print(JSON.stringify(toOutShell))
  2100. .then((res) => {
  2101. console.log("this.$peisAPI.print", res);
  2102. let lres = JSON.parse(res);
  2103. if (lres.code < 0) {
  2104. reject(lres.message);
  2105. } else {
  2106. return postapi("/api/app/lisrequest/updatelisrequestisprint", {
  2107. operateType: 1,
  2108. patientRegisterId: row.id,
  2109. });
  2110. }
  2111. })
  2112. .then((res) => {
  2113. if (res && res.code < 0) {
  2114. reject(res.message);
  2115. } else {
  2116. resolve(res);
  2117. }
  2118. })
  2119. .catch((err) => {
  2120. reject(err);
  2121. });
  2122. }
  2123. });
  2124. },
  2125. //pacs条码打印
  2126. pacsPrint(row, ReportCode, isPreview) {
  2127. return new Promise((resolve, reject) => {
  2128. if (!this.$peisAPI) reject("此功能,需要在壳客户端才可运行!");
  2129. if (!row.completeFlag || row.completeFlag == "0")
  2130. reject("预登记人员,不可执行此操作!");
  2131. let token = window.sessionStorage.getItem("token");
  2132. let user = window.sessionStorage.getItem("user");
  2133. let toOutShell = {
  2134. ReportCode,
  2135. token,
  2136. IsMoreLabel: "Y",
  2137. isBuildImage: "N",
  2138. IsUploadPdf: "N",
  2139. preViewCanPrint: "N",
  2140. Parameters: [
  2141. { Name: "printer", Value: user },
  2142. { Name: "hisLog", Value: "pic/hisLog.jpg" },
  2143. ],
  2144. BusinessCode: row.id,
  2145. };
  2146. console.log("this.$peisAPI.print", toOutShell);
  2147. if (isPreview) {
  2148. this.$peisAPI
  2149. .printPre(JSON.stringify(toOutShell))
  2150. .then((res) => {
  2151. console.log("this.$peisAPI.printPre", res);
  2152. let lres = JSON.parse(res);
  2153. if (lres.code > -1) {
  2154. resolve(lres);
  2155. } else {
  2156. reject(lres.message);
  2157. }
  2158. })
  2159. .catch((err) => {
  2160. reject(err);
  2161. });
  2162. } else {
  2163. this.$peisAPI
  2164. .print(JSON.stringify(toOutShell))
  2165. .then((res) => {
  2166. console.log("this.$peisAPI.print", res);
  2167. let lres = JSON.parse(res);
  2168. if (lres.code > -1) {
  2169. resolve(lres);
  2170. } else {
  2171. reject(lres.message);
  2172. }
  2173. })
  2174. .catch((err) => {
  2175. reject(err);
  2176. });
  2177. }
  2178. });
  2179. },
  2180. // 导入检查检验结果
  2181. importResult(checkType, row) {
  2182. let url = "/api/app/ImportLisResult/ImportResultByPatientRegisterId";
  2183. switch (checkType) {
  2184. case "pacs":
  2185. url = "/api/app/ImportPacsResult/ImportResultByPatientRegisterId";
  2186. postapi(url, { patientRegisterId: row.id })
  2187. .then((res) => {
  2188. if (res.code > -1) {
  2189. return postapi(
  2190. "/api/app/ImportElectrocardiogramResult/ImportElectrocardiogramResultByPatientRegisterId",
  2191. { patientRegisterId: row.id }
  2192. );
  2193. }
  2194. })
  2195. .then((res) => {
  2196. if (res && res.code > -1) {
  2197. this.$message.success({
  2198. showClose: true,
  2199. message: "导入成功!",
  2200. });
  2201. this.rowClick(row);
  2202. }
  2203. });
  2204. break;
  2205. default:
  2206. postapi(url, { patientRegisterId: row.id }).then((res) => {
  2207. if (res.code > -1) {
  2208. this.$message.success({ showClose: true, message: "导入成功!" });
  2209. this.rowClick(row);
  2210. }
  2211. });
  2212. break;
  2213. }
  2214. },
  2215. //通用导出
  2216. btnExport(elId) {
  2217. this.dragCol.forEach((e) => {
  2218. this.jsonFields[e.label] = e.prop;
  2219. });
  2220. let tableDatas=deepCopy(this.tableData)
  2221. tableDatas.forEach((e,index)=>{
  2222. if(index)e.sn=index+1
  2223. if(e.completeFlag)e.completeFlag=e.isAudit == "Y"? "已审核": dddw(this.dict.completeFlag,"id",e.completeFlag,"displayName")
  2224. if(e.guidePrintTimes)e.guidePrintTimes=e.guidePrintTimes > 0?'打印':''
  2225. if(e.isLock)e.isLock=e.isLock=='Y'?'锁住':''
  2226. if(e.sexId)e.sexId=dddw(this.dict.sex,"id",e.sexId,"displayName")
  2227. if(e.medicalPackageId !== this.dict.personOrgId &&e.customerOrgId === this.dict.personOrgId){
  2228. e.groupPack=dddw(this.dict.medicalPackage,"id",e.medicalPackageId,"displayName")
  2229. }else if(e.medicalPackageId !== this.dict.personOrgId &&e.customerOrgId !== this.dict.personOrgId){
  2230. e.groupPack=dddw(this.dict.customerOrgGroupAll,"id",e.customerOrgGroupId,"displayName")
  2231. }
  2232. if(e.nationId)e.nationId=dddw(this.dict.nation,"id",e.nationId,"displayName")
  2233. if(e.idNo)e.idNo=e.idNo+'&'
  2234. if(e.birthDate)e.birthDate=moment(e.birthDate).format("yyyy-MM-DD")
  2235. if(e.maritalStatusId)e.maritalStatusId=dddw(this.dict.maritalStatus,"id",e.maritalStatusId,"displayName")
  2236. if(e.medicalTypeId)e.medicalTypeId=dddw(this.dict.medicalType,"id",e.medicalTypeId,"displayName")
  2237. if(e.personnelTypeId)e.personnelTypeId=dddw(this.dict.personnelType,"id",e.personnelTypeId,"displayName")
  2238. if(e.isVip)e.isVip=e.isVip == "Y" ? "是" : "否"
  2239. if(e.isUpload)e.isUpload=e.isUpload == "Y" ? "是" : "否"
  2240. if(e.qztlType)e.qztlType=dddw(this.dict.qztlType,"id",e.qztlType,"displayName")
  2241. if(e.qztlIsMain)e.qztlIsMain=e.qztlIsMain == "Y" ? "是" : "否"
  2242. if(e.qztlIsCy)e.qztlIsCy=e.qztlIsCy == "Y" ? "是" : "否"
  2243. if(e.qztlIsCw)e.qztlIsCw=e.qztlIsCw == "Y" ? "是" : "否"
  2244. if(e.qztlIsGt)e.qztlIsGt=e.qztlIsGt == "Y" ? "是" : "否"
  2245. if(e.qztlIsWh)e.qztlIsWh=e.qztlIsWh == "Y" ? "是" : "否"
  2246. if(e.qztlIsFj)e.qztlIsFj=e.qztlIsFj == "Y" ? "是" : "否"
  2247. })
  2248. this.tableName='人员登记列表'+moment(new Date()).format('yyyyMMDDHHmmss')+'.xls'
  2249. return tableDatas;
  2250. // const columns = this.$refs.info.getColumns(); // 获取列信息
  2251. // const data = this.$refs.info.getData(); // 获取数据
  2252. // console.log(columns)
  2253. // console.log(columns)
  2254. // const exportConf = { columns, data }; // 构建导出配置对象
  2255. // const filename = 'my_data.xlsx'; // 设置文件名
  2256. // const blob = exportTable(exportConf); // 导出数据为 Blob 对象
  2257. // saveAs(blob, filename); // 使用 file-saver 保存文件
  2258. // // 获取HTML元素(表格)
  2259. // // let table = document.getElementById(elId); //.cloneNode(true)
  2260. // this.$nextTick(() => {
  2261. // // let refsTable = this.$refs[elId] //.cloneNode(true) true
  2262. // let table = document.getElementById(elId)
  2263. // // console.log('table,refsTable', table, refsTable)
  2264. // let tableData = table.innerHTML
  2265. // let fileName = moment(new Date()).format('yyyyMMDDHHmmss')
  2266. // let blob = new Blob([tableData], { type: "text/plain;charset=utf-8" });
  2267. // FileSaver.saveAs(blob, fileName + '.xls');
  2268. // // 导出图片
  2269. // // 使用html2canvas将HTML元素转换为画布
  2270. // // let cloneTable = table.cloneNode(true) //[elId]
  2271. // /*
  2272. // html2canvas(table).then(canvas => {
  2273. // // 创建一个a元素用于下载
  2274. // const link = document.createElement('a');
  2275. // link.href = canvas.toDataURL('image/jpeg');
  2276. // link.download = fileName + '.jpg';
  2277. // document.body.appendChild(link);
  2278. // link.click();
  2279. // //document.body.removeChild(link);
  2280. // // // 创建一个PDF对象
  2281. // // var pdf = new jsPDF();
  2282. // // // 设置PDF的尺寸
  2283. // // pdf.addImage(canvas.toDataURL('image/png'), 'PNG', 0, 0, canvas.width, canvas.height);
  2284. // // // 导出PDF
  2285. // // pdf.save('员工信息表.pdf');
  2286. // });
  2287. // */
  2288. // })
  2289. },
  2290. btnDragColDesign() {
  2291. this.dragColDesign = deepCopy(this.dragCol);
  2292. this.dialogColSort = true;
  2293. this.rowDrag();
  2294. },
  2295. btnDragColDesignOk() {
  2296. this.dragCol = deepCopy(this.dragColDesign);
  2297. this.dialogColSort = false;
  2298. },
  2299. //拖拽
  2300. rowDrag() {
  2301. this.$nextTick(() => {
  2302. const el = document.querySelector("#elTable_dragCol tbody");
  2303. // console.log('el0', el)
  2304. const that = this;
  2305. Sortable.create(el, {
  2306. animation: 150, // ms, number 单位:ms,定义排序动画的时间
  2307. //拖拽结束
  2308. onEnd({ newIndex, oldIndex }) {
  2309. that.isshow = false;
  2310. const currRow = that.dragColDesign.splice(oldIndex, 1)[0];
  2311. that.dragColDesign.splice(newIndex, 0, currRow);
  2312. // console.log('el', el)
  2313. },
  2314. });
  2315. });
  2316. },
  2317. },
  2318. //监听事件
  2319. watch: {
  2320. "patientRegister.query.customerOrgId": {
  2321. // immediate: true, // 立即执行
  2322. // deep: true, // 深度监听复杂类型内变化
  2323. handler(newVal, oldVal) {
  2324. //// console.log('watch:patientRegister.query.customerOrgId:',newVal,oldVal)
  2325. // 单位变化时,清除当前列表信息
  2326. if (newVal && newVal != oldVal) {
  2327. this.tableData = [];
  2328. this.dataTransOpts.tableM.register_check_asbitem = [];
  2329. }
  2330. },
  2331. },
  2332. //触发查询事件
  2333. "patientRegister.query.times"(newVal, oldVal) {
  2334. if (newVal != oldVal) {
  2335. //alert('触发查询事件')
  2336. this.Query();
  2337. }
  2338. },
  2339. //新增后,触发赋值
  2340. // "patientRegister.patientRegisterRd.id"(newVal, oldVal) {
  2341. // if (newVal != oldVal) {
  2342. // //// console.log('patientRegister.patientRegisterRd.customerOrgId',this.patientRegister.patientRegisterRd.customerOrgId)
  2343. // objCopy(this.patientRegister.patientRegisterRd, this.form);
  2344. // }
  2345. // },
  2346. },
  2347. };
  2348. </script>
  2349. <style scoped>
  2350. @import "../../assets/css/global_input.css";
  2351. @import "../../assets/css/global_table.css";
  2352. @import "../../assets/css/global.css";
  2353. .box {
  2354. display: flex;
  2355. }
  2356. .listBtn {
  2357. margin-top: 5px;
  2358. text-align: center;
  2359. }
  2360. .btnClass {
  2361. width: 100px;
  2362. }
  2363. </style>