PatientDetail.vue 80KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302
  1. <template>
  2. <div class="app-container">
  3. <el-dialog
  4. title="查看传染病检查结果"
  5. :visible.sync="dialogFormVisible"
  6. width="1000px"
  7. id="user-inspection-form"
  8. >
  9. <el-form :model="form" ref="form" label-position="top">
  10. <el-row>
  11. <el-col :span="1">&nbsp;</el-col>
  12. <template v-for="(item, index) in form.formItem">
  13. <el-col :span="7" >
  14. <el-form-item
  15. :label="item.item_name"
  16. v-if="item.range_type == 1"
  17. :key="item.item_id"
  18. :prop="'formItem.' + index + '.value'"
  19. >
  20. <el-input
  21. placeholder="请填入"
  22. v-model="item.value"
  23. style="width: 95%"
  24. type="number"
  25. disabled
  26. >
  27. <template slot="append">{{ item.unit }}</template>
  28. </el-input>
  29. </el-form-item>
  30. <el-form-item
  31. :label="item.item_name"
  32. v-else
  33. :key="item.item_id"
  34. :prop="'formItem.' + index + '.value'"
  35. >
  36. <!-- :key="item.item_id" -->
  37. <el-select
  38. v-model="item.value"
  39. placeholder="请选择"
  40. style="width: 95%"
  41. disabled
  42. >
  43. <el-option
  44. v-for="(optionItem, oidex) in item.select_options"
  45. :key="oidex"
  46. :label="optionItem"
  47. :value="optionItem"
  48. >
  49. </el-option>
  50. </el-select>
  51. </el-form-item>
  52. </el-col>
  53. <el-col :span="1" :key="'form-col' + index">&nbsp;</el-col>
  54. </template>
  55. </el-row>
  56. </el-form>
  57. <div slot="footer" class="dialog-footer">
  58. <el-button @click="dialogFormVisible = false">关闭</el-button>
  59. </div>
  60. </el-dialog>
  61. <el-form
  62. ref="form"
  63. :rules="rules"
  64. :model="form"
  65. label-width="134px"
  66. class="clearfix"
  67. id="patient-info"
  68. >
  69. <div style="float: right; z-index: 8; position: absolute; right: 16px">
  70. <el-button
  71. size="small"
  72. type="primary"
  73. @click="printCard()"
  74. style="margin: 0 6px 6px 0; z-index: 1"
  75. >打印签到卡</el-button
  76. >
  77. <el-button
  78. size="small"
  79. :disabled="$store.getters.xt_user.subscibe.state == 3 ? true : false"
  80. type="primary"
  81. @click="$router.push('/patients/patient/' + patientID + '/edit')"
  82. style="margin: 0 0 6px 0; z-index: 1"
  83. >修改</el-button
  84. >
  85. <el-button
  86. size="small"
  87. type="primary"
  88. @click="printThisInfo()"
  89. style="margin: 0 6px 6px 0; z-index: 1"
  90. >打印</el-button
  91. >
  92. </div>
  93. <div class="dataTitle">一般资料</div>
  94. <el-row>
  95. <el-col :span="20">
  96. <el-row :gutter="10">
  97. <el-col :span="8">
  98. <el-form-item label="姓名 : " class="is-required" prop="name">
  99. <el-input v-model="form.name" disabled></el-input>
  100. </el-form-item>
  101. </el-col>
  102. <el-col :span="8" style="height: 59px">
  103. <el-form-item label="性别 : " class="is-required" prop="gender">
  104. <el-radio-group v-model="form.gender">
  105. <el-radio
  106. v-for="item in sexOptions"
  107. :key="item.value"
  108. :label="item.value"
  109. :value="item.value"
  110. disabled
  111. >{{ item.label }}</el-radio
  112. >
  113. </el-radio-group>
  114. </el-form-item>
  115. </el-col>
  116. <el-col :span="8">
  117. <el-form-item
  118. label="身份证号 : "
  119. class="is-required"
  120. prop="idCardNo"
  121. >
  122. <el-input v-model="form.idCardNo" disabled></el-input>
  123. </el-form-item>
  124. </el-col>
  125. <el-col :span="8" style="height: 59px">
  126. <el-form-item label="年龄 : " class="is-required" prop="age">
  127. <el-input v-model="form.age" disabled></el-input>
  128. </el-form-item>
  129. </el-col>
  130. <el-col :span="8">
  131. <el-form-item label="透析号 : " class="is-required">
  132. <el-input
  133. disabled
  134. v-model="form.dialysisNo"
  135. placeholder="填写或自动生成"
  136. style="width: 110px; float: left; margin-right: 1%"
  137. ></el-input>
  138. <el-button disabled type="primary">自动生成</el-button>
  139. </el-form-item>
  140. </el-col>
  141. <el-col :span="8">
  142. <el-form-item
  143. label="出生日期 : "
  144. class="is-required"
  145. prop="birth"
  146. >
  147. <el-date-picker
  148. v-model="form.birth"
  149. type="date"
  150. disabled
  151. placeholder="选择日期"
  152. :suffix-icon="'el-icon-menu'"
  153. format="yyyy-MM-dd"
  154. value-format="yyyy-MM-dd"
  155. ></el-date-picker>
  156. </el-form-item>
  157. </el-col>
  158. <el-col :span="8" v-if="org_id!=0 && org_id!=10138 && org_id!=10278">
  159. <el-form-item
  160. label="首次肾脏治疗时间 : "
  161. label-width="150px"
  162. class="is-required"
  163. prop="birth"
  164. >
  165. <el-date-picker
  166. v-model="form.firstDialysisDate"
  167. type="date"
  168. disabled
  169. placeholder="选择日期"
  170. :suffix-icon="'el-icon-menu'"
  171. format="yyyy-MM-dd"
  172. value-format="yyyy-MM-dd"
  173. ></el-date-picker>
  174. </el-form-item>
  175. </el-col>
  176. <el-col :span="6" :style="isEdit ? 'width:380px' : ''" v-if="org_id==0||org_id == 10138 || org_id == 10278">
  177. <el-form-item
  178. label="首次进入本院时间:"
  179. prop="firstDialysisDate"
  180. label-width="150px"
  181. >
  182. <el-date-picker
  183. v-model="form.firstDialysisDate"
  184. type="date"
  185. format="yyyy-MM-dd"
  186. value-format="yyyy-MM-dd"
  187. ></el-date-picker>
  188. </el-form-item>
  189. </el-col>
  190. <el-col :span="8">
  191. <el-form-item label="本人电话: " class="is-required" prop="phone">
  192. <el-input
  193. v-model="form.phone"
  194. maxlength="20"
  195. disabled
  196. ></el-input>
  197. </el-form-item>
  198. </el-col>
  199. <el-col :span="8">
  200. <el-form-item label="家属姓名: ">
  201. <el-input
  202. v-model="form.contact_name"
  203. maxlength="20"
  204. disabled
  205. ></el-input>
  206. </el-form-item>
  207. </el-col>
  208. <el-col :span="8">
  209. <el-form-item label="家属电话: " prop="homeTelephone">
  210. <el-input
  211. v-model="form.homeTelephone"
  212. maxlength="20"
  213. disabled
  214. ></el-input>
  215. </el-form-item>
  216. </el-col>
  217. <el-col :span="6">
  218. <el-form-item
  219. label="本院首次透析 : "
  220. prop="is_hospital_first_dialysis"
  221. >
  222. <el-radio-group v-model="form.is_hospital_first_dialysis">
  223. <el-radio
  224. v-for="item in isHospitalFirstDialysisOptions"
  225. :key="item.value"
  226. :label="item.value"
  227. :value="item.value"
  228. disabled
  229. >{{ item.label }}</el-radio
  230. >
  231. </el-radio-group>
  232. </el-form-item>
  233. </el-col>
  234. <el-col :span="6">
  235. <el-form-item
  236. label="系统前透析次数 : "
  237. prop="first_dialysis_hospital"
  238. >
  239. <el-input v-model="form.user_sys_before_count" disabled></el-input>
  240. </el-form-item>
  241. </el-col>
  242. <el-col :span="6">
  243. <el-form-item label="首次诊治日期 : ">
  244. <el-date-picker
  245. v-model="form.first_treatment_date"
  246. type="date"
  247. disabled
  248. format="yyyy-MM-dd"
  249. value-format="yyyy-MM-dd"
  250. ></el-date-picker>
  251. </el-form-item>
  252. </el-col>
  253. <el-col :span="6">
  254. <el-form-item label="上家透析医院 : " prop="first_dialysis_hospital">
  255. <el-input
  256. v-model="form.first_dialysis_hospital"
  257. disabled
  258. ></el-input>
  259. </el-form-item>
  260. </el-col>
  261. <el-col :span="24">
  262. <el-form-item label="透析之前情况 : " prop="predialysis_condition">
  263. <el-checkbox-group v-model="form.predialysis_condition">
  264. <el-checkbox
  265. v-for="item in predialysisConditionOptions"
  266. :label="item.label"
  267. :key="item.value"
  268. :value="item.label"
  269. disabled
  270. >{{ item.label }}</el-checkbox
  271. >
  272. </el-checkbox-group>
  273. </el-form-item>
  274. </el-col>
  275. <el-col :span="24">
  276. <el-form-item label="病历号 : " prop="record_number">
  277. <el-input
  278. style="width: 200px;"
  279. v-model="form.record_number"
  280. disabled
  281. ></el-input>
  282. </el-form-item>
  283. </el-col>
  284. <el-col :span="6">
  285. <el-form-item
  286. label="本院前透析频率 : "
  287. prop="pre_hospital_dialysis_frequency"
  288. >
  289. <el-input
  290. v-model="form.pre_hospital_dialysis_frequency"
  291. disabled
  292. ></el-input>
  293. </el-form-item>
  294. </el-col>
  295. <el-col :span="6">
  296. <el-form-item
  297. label="本院前透析次数 : "
  298. prop="pre_hospital_dialysis_times"
  299. >
  300. <el-input
  301. v-model="form.pre_hospital_dialysis_times"
  302. disabled
  303. ></el-input>
  304. </el-form-item>
  305. </el-col>
  306. <el-col :span="6">
  307. <el-form-item
  308. label="本院首次透析 : "
  309. prop="hospital_first_dialysis_date"
  310. >
  311. <el-date-picker
  312. v-model="form.hospital_first_dialysis_date"
  313. type="date"
  314. format="yyyy-MM-dd"
  315. value-format="yyyy-MM-dd"
  316. disabled
  317. ></el-date-picker>
  318. </el-form-item>
  319. </el-col>
  320. <el-col :span="8" style="height: 59px">
  321. <el-form-item
  322. label="患者来源 : "
  323. class="is-required"
  324. prop="source"
  325. >
  326. <el-radio-group v-model="form.source">
  327. <el-radio
  328. v-for="item in sourceOptions"
  329. :key="item.value"
  330. :label="item.value"
  331. :value="item.value"
  332. disabled
  333. >{{ item.label }}</el-radio
  334. >
  335. </el-radio-group>
  336. </el-form-item>
  337. </el-col>
  338. <el-col :span="8" :style="isEdit ? 'width:360px' : ''">
  339. <el-form-item
  340. label="患者去向 : "
  341. >
  342. <el-radio-group v-model="form.patient_source">
  343. <el-radio
  344. disabled
  345. v-for="item in patientSourceList"
  346. :key="item.value"
  347. :label="item.value"
  348. :value="item.value"
  349. >{{ item.label }}</el-radio
  350. >
  351. </el-radio-group>
  352. </el-form-item>
  353. </el-col>
  354. <el-col :span="8" style="margin-bottom: 20px;">
  355. <el-form-item
  356. label="备注 : "
  357. prop="sch_remark">
  358. <el-input
  359. disabled
  360. type="textarea"
  361. :rows="3"
  362. v-model="form.sch_remark"
  363. resize="none"
  364. placeholder
  365. ></el-input>
  366. </el-form-item>
  367. </el-col>
  368. <el-col :span="8" style="height: 59px">
  369. <el-form-item
  370. label="治疗状态(转归) : "
  371. class="is-required"
  372. prop="lapseto"
  373. >
  374. <el-radio-group v-model="form.lapseto">
  375. <el-radio
  376. v-for="item in lapsetoOptions"
  377. :key="item.value"
  378. :label="item.value"
  379. :value="item.value"
  380. disabled
  381. >{{ item.label }}</el-radio
  382. >
  383. </el-radio-group>
  384. </el-form-item>
  385. </el-col>
  386. <el-col :span="24">
  387. <el-form-item label="传染病 : " required prop="is_infectious">
  388. <el-radio-group v-model="form.is_infectious" disabled>
  389. <el-radio :label="1">阴性</el-radio>
  390. <el-radio :label="2">阳性</el-radio>
  391. </el-radio-group>
  392. <el-checkbox-group
  393. v-model="form.contagions"
  394. v-if="form.is_infectious == '2'"
  395. disabled
  396. >
  397. <el-checkbox
  398. v-for="item in contagionList"
  399. v-if="item.type == 2"
  400. :label="item.id"
  401. :key="item.id"
  402. name="contagions"
  403. :value="item.id"
  404. >{{ item.name }}
  405. </el-checkbox>
  406. </el-checkbox-group>
  407. </el-form-item>
  408. <el-form-item label="疑难内瘘:">
  409. <el-radio-group v-model="form.troble_shoot" disabled>
  410. <el-radio :label="1">是</el-radio>
  411. <el-radio :label="2">否</el-radio>m
  412. </el-radio-group>
  413. </el-form-item>
  414. <el-form-item label="人员编码: ">
  415. <el-input v-model="form.zb_patient_id"></el-input>
  416. </el-form-item>
  417. </el-col>
  418. <!--<el-col :span="16" >-->
  419. <!--<el-form-item label="检查结果日期 : " >-->
  420. <!--<el-date-picker v-model="form.record_date" type="date" placeholder="选择日期" :suffix-icon="'el-icon-menu'"-->
  421. <!--format="yyyy-MM-dd"-->
  422. <!--style="width: 200px;"-->
  423. <!--value-format="yyyy-MM-dd"></el-date-picker>-->
  424. <!--&lt;!&ndash;<el-button type="primary" @click="recordCheck()">录入检验检查</el-button>&ndash;&gt;-->
  425. <!--</el-form-item>-->
  426. <!--</el-col>-->
  427. <el-col :span="16">
  428. <el-form-item label="检查结果日期 : ">
  429. <!--<el-date-picker v-model="form.record_date" type="date" placeholder="选择日期" :suffix-icon="'el-icon-menu'"-->
  430. <!--format="yyyy-MM-dd"-->
  431. <!--style="width: 200px;"-->
  432. <!--disabled-->
  433. <!--value-format="yyyy-MM-dd" v-if="isEdit"></el-date-picker>-->
  434. <el-date-picker
  435. v-model="form.record_date"
  436. type="date"
  437. placeholder="选择日期"
  438. :suffix-icon="'el-icon-menu'"
  439. format="yyyy-MM-dd"
  440. disabled
  441. style="width: 200px"
  442. value-format="yyyy-MM-dd"
  443. ></el-date-picker>
  444. <el-button type="primary" @click="showInspectDialog()"
  445. >查看检验检查</el-button
  446. >
  447. </el-form-item>
  448. </el-col>
  449. <el-col :span="24">
  450. <el-form-item label="传染病周期提醒: ">
  451. <el-radio-group
  452. v-model="form.remind_cycle"
  453. @change="changeCycle()"
  454. disabled
  455. >
  456. <el-radio :label="1">一月一次</el-radio>
  457. <el-radio :label="2">两月一次</el-radio>
  458. <el-radio :label="3">三月一次</el-radio>
  459. <el-radio :label="4">半年一次</el-radio>
  460. <el-radio :label="5">一年一次</el-radio>
  461. </el-radio-group>
  462. </el-form-item>
  463. </el-col>
  464. <el-col :span="24">
  465. <el-form-item label="诊断 : " prop="diagnose">
  466. <!-- <textarea v-model="form.diagnose" class="textarea" disabled></textarea> -->
  467. <el-input
  468. type="textarea"
  469. :rows="3"
  470. v-model="form.diagnose"
  471. resize="none"
  472. placeholder=""
  473. readonly
  474. ></el-input>
  475. </el-form-item>
  476. </el-col>
  477. <el-col :span="24">
  478. <el-form-item label="诊疗计划 : " prop="diagnose">
  479. <el-input
  480. type="textarea"
  481. :rows="3"
  482. v-model="form.treatment_plan"
  483. resize="none"
  484. placeholder
  485. readonly
  486. ></el-input>
  487. </el-form-item>
  488. </el-col>
  489. <el-col :span="8">
  490. <el-form-item label="民族 : " prop="nation">
  491. <el-input
  492. v-model="form.nation"
  493. maxlength="30"
  494. disabled
  495. ></el-input>
  496. </el-form-item>
  497. </el-col>
  498. <el-col :span="8">
  499. <el-form-item label="籍贯 : " prop="native_place">
  500. <el-input
  501. v-model="form.native_place"
  502. maxlength="30"
  503. disabled
  504. ></el-input>
  505. </el-form-item>
  506. </el-col>
  507. <el-col :span="8">
  508. <el-form-item label="家庭住址 : " prop="homeAddress">
  509. <el-input v-model="form.homeAddress" disabled></el-input>
  510. </el-form-item>
  511. </el-col>
  512. <div v-show="!generic_info_fold">
  513. <el-col :span="8">
  514. <el-form-item label="别名 : " prop="alias">
  515. <el-input v-model="form.alias" disabled></el-input>
  516. </el-form-item>
  517. </el-col>
  518. <el-col :span="8">
  519. <el-form-item label="身高(cm) : " prop="height">
  520. <el-input
  521. maxlength="5"
  522. v-model="form.height"
  523. disabled
  524. ></el-input>
  525. </el-form-item>
  526. </el-col>
  527. <el-col :span="8">
  528. <el-form-item label="婚姻状况 : " prop="maritalStatus">
  529. <el-select
  530. v-model="form.maritalStatus"
  531. placeholder="请选择婚姻状况"
  532. disabled
  533. >
  534. <el-option
  535. v-for="item in maritalOptions"
  536. :key="item.id"
  537. :label="item.name"
  538. :value="item.id"
  539. />
  540. </el-select>
  541. </el-form-item>
  542. </el-col>
  543. <el-col :span="8">
  544. <el-form-item label="子女情况(个) : " prop="children">
  545. <el-input
  546. maxlength="5"
  547. v-model="form.children"
  548. disabled
  549. ></el-input>
  550. </el-form-item>
  551. <!-- <el-form-item label=" " style="float:left;" label-width="30px" >
  552. </el-form-item> -->
  553. </el-col>
  554. <el-col :span="8">
  555. <el-form-item label="住院(门诊)号 : " prop="admissionNumber">
  556. <el-input v-model="form.admissionNumber" disabled></el-input>
  557. </el-form-item>
  558. </el-col>
  559. <el-col :span="8">
  560. <el-form-item label="医保类型 : " prop="reimbursementWayID">
  561. <el-select v-model="form.reimbursementWayID" disabled>
  562. <el-option
  563. v-for="item in wayOptions"
  564. :key="item.id"
  565. :label="item.name"
  566. :value="item.id"
  567. />
  568. </el-select>
  569. </el-form-item>
  570. </el-col>
  571. <el-col :span="8">
  572. <el-form-item label="医保号 : " prop="healthCareNo">
  573. <el-input v-model="form.healthCareNo" disabled></el-input>
  574. </el-form-item>
  575. </el-col>
  576. <el-col :span="8">
  577. <el-form-item label="教育程度 : " prop="educationOptions">
  578. <el-select v-model="form.education" disabled>
  579. <el-option
  580. v-for="item in educationOptions"
  581. :key="item.id"
  582. :label="item.name"
  583. :value="item.id"
  584. />
  585. </el-select>
  586. </el-form-item>
  587. </el-col>
  588. <el-col :span="8">
  589. <el-form-item label="固定电话 : ">
  590. <el-input
  591. v-model="form.tell_phone"
  592. maxlength="20"
  593. disabled
  594. ></el-input>
  595. </el-form-item>
  596. </el-col>
  597. <el-col :span="8">
  598. <el-form-item label="费别 : ">
  599. <el-select v-model="form.expense_kind" disabled>
  600. <el-option
  601. v-for="item in expenseOptions"
  602. :key="item.id"
  603. :label="item.name"
  604. :value="item.id"
  605. />
  606. </el-select>
  607. </el-form-item>
  608. </el-col>
  609. <el-col :span="8">
  610. <el-form-item label="透析龄(月): ">
  611. <el-input v-model="form.dialysis_age" disabled></el-input>
  612. </el-form-item>
  613. </el-col>
  614. <el-col :span="8">
  615. <el-form-item label="亲友电话: " prop="relative_phone">
  616. <el-input
  617. v-model="form.relative_phone"
  618. maxlength="20"
  619. disabled
  620. ></el-input>
  621. </el-form-item>
  622. </el-col>
  623. <el-col :span="8">
  624. <el-form-item label="亲友关系: " prop="relative_relations">
  625. <el-input
  626. v-model="form.relative_relations"
  627. maxlength="20"
  628. disabled
  629. ></el-input>
  630. </el-form-item>
  631. </el-col>
  632. <el-col :span="8">
  633. <el-form-item label="职业 : " prop="profession">
  634. <el-select v-model="form.profession" disabled>
  635. <el-option
  636. v-for="item in professionOptions"
  637. :key="item.id"
  638. :label="item.name"
  639. :value="item.id"
  640. />
  641. </el-select>
  642. </el-form-item>
  643. </el-col>
  644. <el-col :span="8">
  645. <el-form-item label="工作单位 : " prop="work">
  646. <el-input v-model="form.work" disabled></el-input>
  647. </el-form-item>
  648. </el-col>
  649. <el-col :span="8">
  650. <el-form-item label="单位地址 : " prop="unit_address">
  651. <el-input v-model="form.unit_address" disabled></el-input>
  652. </el-form-item>
  653. </el-col>
  654. </div>
  655. <el-col :span="8">
  656. <el-form-item>
  657. <el-button
  658. type="text"
  659. @click="generic_info_fold = !generic_info_fold"
  660. >{{ generic_info_fold ? "更多资料" : "收起"
  661. }}<i class="el-icon--right" :class="generic_fold_icon"></i
  662. ></el-button>
  663. </el-form-item>
  664. </el-col>
  665. </el-row>
  666. </el-col>
  667. <el-col :span="4" align="center">
  668. <img
  669. width="146px"
  670. height="146px"
  671. v-if="form.avatar"
  672. :src="form.avatar"
  673. class="avatar"
  674. />
  675. <el-form-item prop="avatar">
  676. <el-input
  677. v-model="form.avatar"
  678. type="hidden"
  679. placeholder=""
  680. ></el-input>
  681. </el-form-item>
  682. </el-col>
  683. </el-row>
  684. <div class="dataTitle">治疗信息</div>
  685. <div style="display: flex">
  686. <div style="flex: 1 1 9%;">
  687. <el-row :gutter="24">
  688. <el-col :span="24">
  689. <el-form-item label="主诉 : " prop="patient_complains">
  690. <el-input
  691. type="textarea"
  692. :rows="3"
  693. v-model="form.patient_complains"
  694. resize="none"
  695. placeholder=""
  696. readonly
  697. ></el-input>
  698. </el-form-item>
  699. </el-col>
  700. </el-row>
  701. <el-row :gutter="24">
  702. <el-col :span="24">
  703. <el-form-item label="既往史 : " prop="past_history">
  704. <el-input
  705. type="textarea"
  706. :rows="3"
  707. v-model="form.past_history"
  708. resize="none"
  709. placeholder=""
  710. readonly
  711. ></el-input>
  712. </el-form-item>
  713. </el-col>
  714. </el-row>
  715. <el-row :gutter="24">
  716. <el-col :span="24">
  717. <el-form-item label="体格检查">
  718. <el-input
  719. v-model="form.temperature"
  720. style="width: 200px"
  721. disabled
  722. >
  723. <template slot="prepend">体温:</template>
  724. <template slot="append">℃</template>
  725. </el-input>
  726. <el-input v-model="form.pulse" style="width: 220px" disabled>
  727. <template slot="prepend">脉搏: </template>
  728. <template slot="append">次/分</template>
  729. </el-input>
  730. <el-input
  731. v-model="form.respiratory"
  732. style="width: 220px"
  733. disabled
  734. >
  735. <template slot="prepend">呼吸: </template>
  736. <template slot="append">次/分</template>
  737. </el-input>
  738. </el-form-item>
  739. </el-col>
  740. </el-row>
  741. <el-row :gutter="24">
  742. <el-col>
  743. <el-form-item>
  744. <el-input v-model="form.sbp" style="width: 240px" disabled>
  745. <template slot="prepend">收缩压:</template>
  746. <template slot="append">mmHg</template>
  747. </el-input>
  748. <el-input v-model="form.dbp" style="width: 240px" disabled>
  749. <template slot="prepend">舒张压:</template>
  750. <template slot="append">mmHg</template>
  751. </el-input>
  752. </el-form-item>
  753. </el-col>
  754. </el-row>
  755. </div>
  756. <div style="flex: 1;" class="now_his">
  757. <el-row :gutter="24" style="height:100%;">
  758. <el-col :span="24" style="height:100%;">
  759. <el-form-item label="现病史 : " prop="present_history" style="height:100%;">
  760. <el-input
  761. style="height:100%;"
  762. type="textarea"
  763. :rows="3"
  764. v-model="form.present_history"
  765. resize="none"
  766. placeholder=""
  767. readonly
  768. ></el-input>
  769. </el-form-item>
  770. </el-col>
  771. </el-row>
  772. </div>
  773. </div>
  774. <el-row :gutter="24">
  775. <el-col :span="24">
  776. <el-form-item label="" prop="remark">
  777. <!-- <textarea v-model="form.remark" class="textarea" disabled></textarea> -->
  778. <el-input
  779. type="textarea"
  780. :rows="3"
  781. v-model="form.remark"
  782. resize="none"
  783. placeholder=""
  784. readonly
  785. ></el-input>
  786. </el-form-item>
  787. </el-col>
  788. <el-col :span="8">
  789. <el-form-item label="" prop="sch_remark">
  790. <!-- <textarea v-model="form.remark" class="textarea" disabled></textarea> -->
  791. <el-input
  792. type="textarea"
  793. :rows="3"
  794. v-model="form.sch_remark"
  795. resize="none"
  796. placeholder=""
  797. readonly
  798. ></el-input>
  799. </el-form-item>
  800. </el-col>
  801. <!-- <el-col :span="24">
  802. <el-form-item label="慢性病 : " prop="diseases">
  803. <el-checkbox-group v-model="form.diseases">
  804. <el-checkbox
  805. v-for="item in checkDisease"
  806. :label="item.id"
  807. :key="item.id"
  808. :value="item.id"
  809. disabled
  810. >{{ item.name }}</el-checkbox
  811. >
  812. </el-checkbox-group>
  813. </el-form-item>
  814. </el-col> -->
  815. </el-row>
  816. <!-- <el-col :span="24">
  817. <el-form-item>
  818. <el-button type="text" @click="treat_info_fold = !treat_info_fold"
  819. >{{ treat_info_fold ? "更多治疗信息" : "收起"
  820. }}<i class="el-icon--right" :class="treat_fold_icon"></i
  821. ></el-button>
  822. </el-form-item>
  823. </el-col> -->
  824. <el-col :span="24">
  825. <el-form-item label="登记人员 : ">
  826. <span>{{ form.registrars }} </span>
  827. </el-form-item>
  828. </el-col>
  829. <el-col :span="6">
  830. <el-form-item label="医生 : ">
  831. <el-select v-model="form.doctor" disabled>
  832. <el-option
  833. v-for="item in adminUserOptions"
  834. :key="item.id"
  835. :label="item.name"
  836. :value="item.id"
  837. />
  838. </el-select>
  839. </el-form-item>
  840. </el-col>
  841. </el-form>
  842. <!-- 打印预览 -->
  843. <div style="display: none">
  844. <div id="print-info-box">
  845. <div class="print_main_content" >
  846. <div class="order_title">{{ orgname }} 血液透析门诊病历</div>
  847. <div >
  848. <table >
  849. <!-- 用 thead 规定好宽度 -->
  850. <!-- <thead>
  851. <tr v-show="false">
  852. <td width="7%"></td>
  853. <td width="10%"></td>
  854. <td width="5%"></td>
  855. <td width="10%"></td>
  856. <td width="5%"></td>
  857. <td width="10%"></td>
  858. <td width="5%"></td>
  859. <td width="30%"></td>
  860. </tr>
  861. </thead> -->
  862. <tbody>
  863. <tr>
  864. <!-- -->
  865. <td style="width:8%;padding: 3px 0px;font-size: 17px;font-weight: 500;">
  866. 姓名
  867. <!-- <div class="td_proj_title">姓名</div> -->
  868. </td>
  869. <td style="padding: 3px 0px;font-size: 17px;">
  870. {{ patientPrint.name }}
  871. <!-- <div class="td_proj_content">{{ patientPrint.name }}</div> -->
  872. </td>
  873. <td style="padding: 3px 0px;font-size: 17px;">
  874. 性别
  875. <!-- <div class="td_proj_title">性别</div> -->
  876. </td>
  877. <td style="padding: 3px 0px;font-size: 17px;">
  878. {{ patientPrint.gender }}
  879. <!-- <div class="td_proj_content">{{ patientPrint.gender }}</div> -->
  880. </td>
  881. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">
  882. 年龄
  883. <!-- <div class="td_proj_title">年龄</div> -->
  884. </td>
  885. <td style="padding: 3px 0px;font-size: 17px;">
  886. {{ patientPrint.age }}岁
  887. <!-- <div class="td_proj_content">{{ patientPrint.age }}岁</div> -->
  888. </td>
  889. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">
  890. 籍贯
  891. <!-- <div class="td_proj_title">籍贯</div> -->
  892. </td>
  893. <td style="padding: 3px 0px;font-size: 17px;">
  894. {{ patientPrint.native_place }}
  895. <!-- <div class="td_proj_content td_align_left">
  896. {{ patientPrint.native_place }}
  897. </div> -->
  898. </td>
  899. </tr>
  900. <tr>
  901. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">
  902. 职业
  903. <!-- <div class="td_proj_title">职业</div> -->
  904. </td>
  905. <td style="padding: 3px 0px;font-size: 17px;">
  906. {{ patientPrint.profession }}
  907. <!-- <div class="td_proj_content">
  908. {{ patientPrint.profession }}
  909. </div> -->
  910. </td>
  911. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">
  912. 婚姻
  913. <!-- <div class="td_proj_title">婚姻</div> -->
  914. </td>
  915. <td style="padding: 3px 0px;font-size: 17px;">
  916. {{ patientPrint.marital_status }}
  917. <!-- <div class="td_proj_content">
  918. {{ patientPrint.marital_status }}
  919. </div> -->
  920. </td>
  921. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">
  922. 透析号
  923. <!-- <div class="td_proj_title">透析号</div> -->
  924. </td>
  925. <td style="padding: 3px 0px;font-size: 17px;">
  926. {{ patientPrint.dialysis_no }}
  927. <!-- <div class="td_proj_content">
  928. {{ patientPrint.dialysis_no }}
  929. </div> -->
  930. </td>
  931. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">
  932. 身份证号
  933. <!-- <div class="td_proj_title">身份证号</div> -->
  934. </td>
  935. <td style="padding: 3px 0px;font-size: 17px;">
  936. {{ patientPrint.id_card_no }}
  937. <!-- <div class="td_proj_content td_align_left">
  938. {{ patientPrint.id_card_no }}
  939. </div> -->
  940. </td>
  941. </tr>
  942. <tr>
  943. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">
  944. 民族
  945. <!-- <div class="td_proj_title">民族</div> valign="top" -->
  946. </td>
  947. <td style="padding: 3px 0px;font-size: 17px;">
  948. {{ patientPrint.nation }}
  949. <!-- <div class="td_proj_content">{{ patientPrint.nation }}</div> -->
  950. </td>
  951. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">
  952. 电话
  953. <!-- <div class="td_proj_title">电话</div> -->
  954. </td>
  955. <td colspan="3" style="padding: 3px 0px;font-size: 17px;">
  956. {{ patientPrint.phone }}
  957. <!-- <div class="td_proj_content td_align_left">
  958. {{ patientPrint.phone }}
  959. </div> -->
  960. </td>
  961. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">
  962. 家属电话
  963. <!-- <div class="td_proj_title">家属电话</div> -->
  964. </td>
  965. <td style="padding: 3px 0px;font-size: 17px;">
  966. {{ patientPrint.home_telephone }}
  967. <!-- <div class="td_proj_content td_align_left">
  968. {{ patientPrint.home_telephone }}
  969. </div> -->
  970. </td>
  971. </tr>
  972. <tr>
  973. <td style="padding: 3px 0px;font-size: 17px;font-weight: 500;">地址</td>
  974. <td colspan="7" style="text-align: left; padding:0px 5px;font-size: 17px;">
  975. <!-- class="td_proj_content td_align_left" -->
  976. <!-- <div > -->
  977. {{ patientPrint.home_address }}
  978. <!-- </div> -->
  979. </td>
  980. </tr>
  981. <tr>
  982. <td style="padding: 3px 0px;font-size: 17px; font-weight: 500;">
  983. 主诉
  984. <!-- <div class="td_proj_title">主诉</div> -->
  985. </td>
  986. <!-- class="td_proj_content td_align_left" -->
  987. <td colspan="7" style="text-align: left; padding:0px 5px ;font-size: 17px;">
  988. {{ patientPrint.patient_complains }}
  989. <!-- <div style="padding: 0px 0px;"
  990. v-html="patientPrint.patient_complains"
  991. ></div> -->
  992. </td>
  993. </tr>
  994. <tr >
  995. <td>
  996. <div class="td_proj_title">现<br />病<br />史</div>
  997. </td>
  998. <td colspan="7">
  999. <!-- <div class="td_proj_content td_align_left">{{patientPrint.present_history}}</div> -->
  1000. <div
  1001. class="td_proj_content td_align_left"
  1002. v-html="patientPrint.present_history"
  1003. ></div>
  1004. </td>
  1005. </tr>
  1006. <tr>
  1007. <td>
  1008. <div class="td_proj_title">既<br />往<br />史</div>
  1009. </td>
  1010. <td colspan="7">
  1011. <div class="td_proj_content td_align_left">
  1012. {{ patientPrint.past_history }}
  1013. </div>
  1014. <!-- v-html="patientPrint.past_history" -->
  1015. </td>
  1016. </tr>
  1017. <tr>
  1018. <td>
  1019. <div class="td_proj_title" v-if="org_id !=10278 && org_id!=10138 && org_id!=0">传<br />染<br />病</div>
  1020. <div class="td_proj_title" v-if="org_id==10138 || org_id == 10278 || org_id == 0">过<br />敏<br />史</div>
  1021. </td>
  1022. <td colspan="7">
  1023. <div class="td_proj_content td_align_left">
  1024. {{ patientPrint.contagions }}
  1025. </div>
  1026. </td>
  1027. </tr>
  1028. <tr>
  1029. <td colspan="8"><div class="td_proj_title">体格检查</div></td>
  1030. </tr>
  1031. <tr>
  1032. <td colspan="8">
  1033. <div class="td_proj_title">
  1034. T
  1035. {{
  1036. patientPrint.temperature
  1037. }}℃&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; P
  1038. {{
  1039. patientPrint.pulse
  1040. }}次/分&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; R
  1041. {{
  1042. patientPrint.respiratory
  1043. }}次/分&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; BP
  1044. {{ patientPrint.sbp }}/{{ patientPrint.dbp }} mmHg
  1045. </div>
  1046. </td>
  1047. </tr>
  1048. <tr>
  1049. <td colspan="8">
  1050. <div
  1051. class="td_proj_content td_align_left"
  1052. v-html="patientPrint.remark"
  1053. ></div>
  1054. </td>
  1055. </tr>
  1056. <tr>
  1057. <td>
  1058. <div class="td_proj_title">诊<br />断</div>
  1059. </td>
  1060. <td colspan="7">
  1061. <div
  1062. class="td_proj_content td_align_left"
  1063. v-html="patientPrint.diagnose"
  1064. ></div>
  1065. </td>
  1066. </tr>
  1067. <tr>
  1068. <td>
  1069. <div class="td_proj_title">诊<br />疗<br />计<br />划</div>
  1070. </td>
  1071. <td colspan="7">
  1072. <div
  1073. class="td_proj_content td_align_left"
  1074. v-html="patientPrint.treatment_plan"
  1075. ></div>
  1076. </td>
  1077. </tr>
  1078. </tbody>
  1079. </table>
  1080. <div class="print_footnote_panel">
  1081. <div class="proj">
  1082. <span class="proj_title">日期:</span>
  1083. <!-- {{ getTime(patientPrint.created_time) }} -->
  1084. <span v-if="org_id == 3907 || org_id == 9671|| org_id == 9675 || org_id == 10394">{{
  1085. getTime(patientPrint.created_time)
  1086. }}</span>
  1087. <span v-else>{{ printDate }}</span>
  1088. </div>
  1089. <div class="proj">
  1090. <span class="proj_title">医生签名:
  1091. <span v-if="patientPrint!=undefined&&getDcotorName(patientPrint.doctor) == ''">{{getDcotorNameOne(patientPrint.doctor)}}</span>
  1092. <span v-else>
  1093. <img style="height:30px;margin-top:20px" :src="getDcotorName(patientPrint.doctor)" alt="" srcset="">
  1094. </span>
  1095. </span>
  1096. </div>
  1097. </div>
  1098. </div>
  1099. </div>
  1100. </div>
  1101. </div>
  1102. <div hidden="hidden">
  1103. <div id="print-card-info">
  1104. <div
  1105. class="order_title"
  1106. align="center"
  1107. style="margin-bottom: 20px; font-size: 35px"
  1108. v-if="org_id != 10223"
  1109. >
  1110. 签到卡
  1111. </div>
  1112. <div
  1113. class="order_title"
  1114. align="center"
  1115. style="margin-bottom: 20px; font-size: 25px"
  1116. v-if="org_id == 10223"
  1117. >
  1118. 三优血液透析中心
  1119. </div>
  1120. <div align="center" style="margin-bottom: 4px; font-size: 25px">
  1121. 姓名:<span>&nbsp;&nbsp;{{ patientPrint.name }}</span
  1122. ><br />
  1123. </div>
  1124. <div align="center" style="margin-bottom: 20px; font-size: 25px">
  1125. 透析号:<span>&nbsp;&nbsp;{{ patientPrint.dialysis_no }}</span>
  1126. </div>
  1127. <div>
  1128. <div id="qrcode" align="center"></div>
  1129. </div>
  1130. </div>
  1131. </div>
  1132. </div>
  1133. </template>
  1134. <script>
  1135. import { getDataConfig } from "@/utils/data";
  1136. import { getToken } from "@/api/qiniu";
  1137. // import print from "print-js";
  1138. import {
  1139. getFileExtension,
  1140. isCardNo,
  1141. jsGetAge,
  1142. isPositiveInteger,
  1143. dialysisAge,
  1144. uParseTime,
  1145. } from "@/utils/tools";
  1146. import {
  1147. generateDialysisNo,
  1148. createPatient,
  1149. editPatient,
  1150. fetchPatient,
  1151. } from "@/api/patient";
  1152. import { fetchAllDoctorAndNurse, fetchAllAdminUsers } from "@/api/doctor";
  1153. import { getZones } from "@/api/device/device";
  1154. import print from "print-js";
  1155. import QRCode from "qrcodejs2";
  1156. import { Base64 } from "js-base64";
  1157. import { parse } from "path";
  1158. const defaultForm = {
  1159. avatar: "",
  1160. patientType: "",
  1161. dialysisNo: "",
  1162. admissionNumber: "",
  1163. source: "",
  1164. lapseto: "",
  1165. partition: "",
  1166. bed: "",
  1167. name: "",
  1168. gender: "",
  1169. nation: "",
  1170. native_place: "",
  1171. maritalStatus: "",
  1172. idCardNo: "",
  1173. birth: "",
  1174. age: "",
  1175. reimbursementWayID: "",
  1176. healthCareNo: "",
  1177. healthCareDueDate: "",
  1178. height: "",
  1179. blood: "",
  1180. rh: "",
  1181. healthCareDueAlertDate: "",
  1182. education: "",
  1183. profession: "",
  1184. phone: "",
  1185. homeTelephone: "",
  1186. homeAddress: "",
  1187. work: "",
  1188. receivingDate: "",
  1189. firstDialysisDate: "",
  1190. dialysisAge: "",
  1191. induction: "",
  1192. initial: "",
  1193. dialysisTotal: "",
  1194. contagions: [],
  1195. doctor: "",
  1196. nurse: "",
  1197. assessment: "",
  1198. diseases: [],
  1199. diagnose: "",
  1200. registrars: "",
  1201. patient_complains: "",
  1202. present_history: "",
  1203. past_history: "",
  1204. temperature: "",
  1205. pulse: "",
  1206. respiratory: "",
  1207. sbp: "",
  1208. dbp: "",
  1209. record_date: "",
  1210. response_result: "",
  1211. is_infectious: "",
  1212. formItem: [],
  1213. tell_phone: "",
  1214. first_treatment_date: "",
  1215. dialysis_age: "",
  1216. expense_kind: "",
  1217. contact_name: "",
  1218. sch_remark: "",
  1219. org_id: 0,
  1220. troble_shoot: "",
  1221. zb_patient_id: "",
  1222. treatment_plan: "",
  1223. doctor:"",
  1224. record_number:"",
  1225. patient_source:"",
  1226. };
  1227. export default {
  1228. name: "patientDetail",
  1229. components: {},
  1230. data() {
  1231. return {
  1232. expenseOptions: [
  1233. { id: 1, name: "基本医保" },
  1234. { id: 2, name: "新农合" },
  1235. { id: 3, name: "自费医疗" },
  1236. { id: 4, name: "公费医疗" },
  1237. { id: 5, name: "商业保险" },
  1238. { id: 6, name: "军队医疗" },
  1239. { id: 7, name: "其他" },
  1240. ],
  1241. patientSourceList:[
  1242. {value:1,label:"门诊"},
  1243. {value:2,label:"住院"},
  1244. {value:3,label:"请假"},
  1245. {value:4,label:"备注"}
  1246. ],
  1247. generic_info_fold: true,
  1248. treat_info_fold: true,
  1249. dialogFormVisible: false,
  1250. orgname: "",
  1251. adminusername: "",
  1252. form: Object.assign({}, defaultForm),
  1253. formSubmit: true,
  1254. submitMethod: "",
  1255. uploadData: { token: "", key: "" },
  1256. dialogImageUrl: "",
  1257. qiniuDomain: "https://images.shengws.com/",
  1258. dialogVisible: false,
  1259. typeOptions: null,
  1260. styleOptions: null,
  1261. sourceOptions: [
  1262. { value: 1, label: "门诊" },
  1263. { value: 2, label: "住院" },
  1264. ],
  1265. lapsetoOptions: [
  1266. { value: 1, label: "留治" },
  1267. { value: 2, label: "转出" },
  1268. ],
  1269. partitionOptions: [],
  1270. sexOptions: [
  1271. { value: 1, label: "男" },
  1272. { value: 2, label: "女" },
  1273. ],
  1274. isHospitalFirstDialysisOptions: [
  1275. { value: 1, label: "是" },
  1276. { value: 2, label: "否" },
  1277. ],
  1278. predialysisConditionOptions: [
  1279. { value: 1, label: "腹膜透析" },
  1280. { value: 2, label: "肾移植" },
  1281. ],
  1282. maritalOptions: null,
  1283. wayOptions: null,
  1284. educationOptions: null,
  1285. professionOptions: null,
  1286. inductionOptions: null,
  1287. doctorOptions: null,
  1288. nurseOptions: null,
  1289. adminUserOptions: [],
  1290. infections: [],
  1291. rhOptions: null,
  1292. checkDisease: null,
  1293. contagionList: null,
  1294. loading: null,
  1295. patientID: 0,
  1296. patientPrint: {},
  1297. print_time: "",
  1298. printDate: "",
  1299. rules: {
  1300. contagions: [{ type: "array", required: false, trigger: "change" }],
  1301. avatar: [{ required: true, message: "请上传头像", trigger: "blur" }],
  1302. patientType: [
  1303. { required: true, message: "请选择患者类型", trigger: "blur" },
  1304. ],
  1305. dialysisNo: [
  1306. { required: true, message: "请填写透析号", trigger: "blur" },
  1307. ],
  1308. admissionNumber: [
  1309. { required: true, message: "请填写住院(门诊)号", trigger: "blur" },
  1310. ],
  1311. source: [
  1312. { required: true, message: "请选择患者来源", trigger: "blur" },
  1313. ],
  1314. lapseto: [
  1315. { required: true, message: "请选择治疗状态", trigger: "blur" },
  1316. ],
  1317. name: [{ required: true, message: "请填写姓名", trigger: "blur" }],
  1318. gender: [{ required: true, message: "请选择性别", trigger: "blur" }],
  1319. idCardNo: [
  1320. { required: true, message: "请填写身份证号", trigger: "blur" },
  1321. ],
  1322. birth: [{ required: true, message: "请填写生日", trigger: "blur" }],
  1323. },
  1324. shootList: [
  1325. { id: 1, name: "是" },
  1326. { id: 2, name: "否" },
  1327. ],
  1328. operators:[],
  1329. };
  1330. },
  1331. computed: {
  1332. generic_fold_icon: function () {
  1333. return this.generic_info_fold ? "el-icon-arrow-down" : "el-icon-arrow-up";
  1334. },
  1335. treat_fold_icon: function () {
  1336. return this.treat_info_fold ? "el-icon-arrow-down" : "el-icon-arrow-up";
  1337. },
  1338. },
  1339. created() {
  1340. this.org_id = this.$store.getters.xt_user.org.id;
  1341. this.form.doctor = this.$store.getters.xt_user.user.id
  1342. console.log("owowow",this.$store.getters.xt_user.user.id)
  1343. this.styleOptions = this.$store.getters.patient_types;
  1344. // this.partitionOptions = this.$store.getters.partitions;
  1345. this.maritalOptions = getDataConfig("patient", "marital_options");
  1346. this.wayOptions = getDataConfig("patient", "reimbursement_ways");
  1347. this.typeOptions = this.$store.getters.blood_types;
  1348. this.rhOptions = this.$store.getters.rh;
  1349. this.educationOptions = getDataConfig("patient", "education_types");
  1350. this.professionOptions = getDataConfig("patient", "profession_options");
  1351. this.inductionOptions = this.$store.getters.induction_options;
  1352. this.contagionList = this.$store.getters.contagions;
  1353. this.checkDisease = this.$store.getters.disease;
  1354. var xtuser = this.$store.getters.xt_user;
  1355. this.orgname = xtuser.org.org_name;
  1356. this.adminusername = xtuser.user.user_name;
  1357. this.fetchAllAdminUsers();
  1358. const id = this.$route.params && this.$route.params.id;
  1359. this.patientID = parseInt(id);
  1360. if (isNaN(this.patientID) || this.patientID <= 0) {
  1361. console.log("patient detail not had id");
  1362. this.$notify.error({
  1363. title: "错误",
  1364. message: "无效的id",
  1365. });
  1366. this.$router.push("/patients/patients");
  1367. }
  1368. this.fetchPatient(id);
  1369. this.getZones();
  1370. var ptime = Math.round(new Date().getTime() / 1000);
  1371. // this.print_time = uParseTime(ptime, '{y}-{m}-{d} {h}:{i}');
  1372. var data = new Date();
  1373. var month =
  1374. data.getMonth() < 9 ? "0" + (data.getMonth() + 1) : data.getMonth() + 1;
  1375. var date = data.getDate() <= 9 ? "0" + data.getDate() : data.getDate();
  1376. this.printDate = data.getFullYear() + "-" + month + "-" + date;
  1377. },
  1378. methods: {
  1379. getTime(val) {
  1380. return uParseTime(val, "{y}年{m}月{d}日");
  1381. },
  1382. printThisInfo() {
  1383. var ptime = Math.round(new Date().getTime() / 1000);
  1384. this.print_time = uParseTime(ptime, "{y}年{m}月{d}日");
  1385. const style =
  1386. "@page {margin-top:10px;}@media print { .print_main_content { background-color: white; width:960px; margin:0 auto; padding: 0 0 20px 0; } .print_main_content .order_title { text-align: center; font-size: 23px; line-height: 50px; font-weight: 500; } .print_main_content table { width: 100%; border-collapse: collapse; padding: 2px; } .print_main_content table tbody tr{page-break-inside:avoid;} .print_main_content table tbody tr td { border: 1px solid; text-align: center; padding: 10px 8px; } .td_proj_title { font-size: 18px; line-height: 25px; font-weight: 500; } .td_proj_content { font-size: 18px; line-height: 25px; } .td_align_left { text-align: left; } .print_footnote_panel { font-size: 17px; line-height: 40px; } .print_footnote_panel .proj { display: inline-block; width: 49%; } .print_footnote_panel .proj .proj_title { font-weight: 500;} }";
  1387. setTimeout(() => {
  1388. printJS({
  1389. printable: "print-info-box",
  1390. type: "html",
  1391. style: style,
  1392. scanStyles: false,
  1393. });
  1394. }, 1);
  1395. },
  1396. getZones() {
  1397. getZones().then((response) => {
  1398. if (response.data.state === 1) {
  1399. this.partitionOptions = response.data.data.zones;
  1400. }
  1401. });
  1402. },
  1403. fetchPatient(id) {
  1404. fetchPatient(id)
  1405. .then((response) => {
  1406. console.log(response.data.data);
  1407. if (response.data.state === 1) {
  1408. this.$emit("tran-patient-info", response.data.data.patient);
  1409. var patietInfo = response.data.data.patient;
  1410. console.log("触发了吗无222222", patietInfo);
  1411. this.form.avatar = patietInfo.avatar;
  1412. this.form.name = patietInfo.name;
  1413. this.form.alias = patietInfo.alias;
  1414. this.form.lapseto = patietInfo.lapseto;
  1415. this.form.idCardNo = patietInfo.id_card_no;
  1416. this.form.dialysisNo = patietInfo.dialysis_no;
  1417. this.form.gender = patietInfo.gender;
  1418. this.form.is_infectious = patietInfo.is_infectious;
  1419. this.form.troble_shoot = patietInfo.troble_shoot;
  1420. this.form.zb_patient_id = patietInfo.zb_patient_id;
  1421. // this.form.record_date = patietInfo.is_infectious
  1422. this.form.response_result = patietInfo.response_result;
  1423. this.form.remind_cycle = patietInfo.remind_cycle;
  1424. this.form.treatment_plan = patietInfo.treatment_plan;
  1425. this.form.doctor = patietInfo.doctor
  1426. if(this.form.doctor == 0){
  1427. this.form.doctor = ""
  1428. }
  1429. // if (patietInfo.is_infectious == 1) {
  1430. // this.form.remind_cycle = 0;
  1431. // }
  1432. // console.log("222222", this.form.remind_cycle);
  1433. this.form.user_sys_before_count = patietInfo.user_sys_before_count;
  1434. this.infections = response.data.data.infections;
  1435. this.form.formItem = this.infections;
  1436. if (this.infections != null) {
  1437. if (this.infections.length > 0) {
  1438. this.form.record_date = uParseTime(
  1439. this.infections[0].inspect_date,
  1440. "{y}-{m}-{d}"
  1441. );
  1442. const select_options = ["阴性", "阳性", "弱阳性"];
  1443. for (let i = 0; i < this.infections.length; i++) {
  1444. this.infections[i]["select_options"] = select_options;
  1445. this.infections[i]["value"] =
  1446. this.infections[i].inspect_value;
  1447. }
  1448. }
  1449. }
  1450. if (patietInfo.gender === 1 || patietInfo.gender === 2) {
  1451. this.form.gender = patietInfo.gender;
  1452. }
  1453. this.form.nation = patietInfo.nation;
  1454. this.form.native_place = patietInfo.native_place;
  1455. this.form.birth = uParseTime(patietInfo.birthday, "{y}-{m}-{d}");
  1456. this.form.firstDialysisDate = uParseTime(
  1457. patietInfo.first_dialysis_date,
  1458. "{y}-{m}-{d}"
  1459. );
  1460. this.form.height = patietInfo.height + "";
  1461. // this.form.age = jsGetAge(this.form.birth, "-");
  1462. if (patietInfo.marital_status > 0) {
  1463. this.form.maritalStatus = patietInfo.marital_status;
  1464. }
  1465. this.form.children = patietInfo.children;
  1466. this.form.admissionNumber = patietInfo.admission_number;
  1467. if (patietInfo.reimbursement_way_id > 0) {
  1468. this.form.reimbursementWayID = patietInfo.reimbursement_way_id;
  1469. }
  1470. this.form.healthCareNo = patietInfo.health_care_no;
  1471. this.form.phone = patietInfo.phone;
  1472. this.form.homeTelephone = patietInfo.home_telephone;
  1473. this.form.relative_phone = patietInfo.relative_phone;
  1474. this.form.relative_relations = patietInfo.relative_relations;
  1475. this.form.homeAddress = patietInfo.home_address;
  1476. this.form.work = patietInfo.work_unit;
  1477. this.form.unit_address = patietInfo.unit_address;
  1478. if (patietInfo.age == 0) {
  1479. this.form.age = jsGetAge(this.form.birth, "-");
  1480. } else {
  1481. this.form.age = patietInfo.age;
  1482. }
  1483. if (patietInfo.profession > 0) {
  1484. this.form.profession = patietInfo.profession;
  1485. }
  1486. if (patietInfo.education_level > 0) {
  1487. this.form.education = patietInfo.education_level;
  1488. }
  1489. if (patietInfo.source === 1 || patietInfo.source === 2) {
  1490. this.form.source = patietInfo.source;
  1491. }
  1492. if (patietInfo.lapseto === 1 || patietInfo.lapseto === 2) {
  1493. this.form.lapseto = patietInfo.lapseto;
  1494. }
  1495. if (
  1496. patietInfo.is_hospital_first_dialysis === 1 ||
  1497. patietInfo.is_hospital_first_dialysis === 2
  1498. ) {
  1499. this.form.is_hospital_first_dialysis =
  1500. patietInfo.is_hospital_first_dialysis;
  1501. }
  1502. if (patietInfo.first_dialysis_date !== 0) {
  1503. this.form.firstDialysisDate = uParseTime(
  1504. patietInfo.first_dialysis_date,
  1505. "{y}-{m}-{d}"
  1506. );
  1507. }
  1508. this.form.first_dialysis_hospital =
  1509. patietInfo.first_dialysis_hospital;
  1510. if (patietInfo.predialysis_condition.length > 0) {
  1511. this.form.predialysis_condition =
  1512. patietInfo.predialysis_condition.split(",");
  1513. }
  1514. this.form.pre_hospital_dialysis_frequency =
  1515. patietInfo.pre_hospital_dialysis_frequency;
  1516. this.form.pre_hospital_dialysis_times =
  1517. patietInfo.pre_hospital_dialysis_times;
  1518. if (patietInfo.hospital_first_dialysis_date !== 0) {
  1519. this.form.hospital_first_dialysis_date = uParseTime(
  1520. patietInfo.hospital_first_dialysis_date,
  1521. "{y}-{m}-{d}"
  1522. );
  1523. }
  1524. this.form.contagions = response.data.data.contagions;
  1525. this.form.diseases = response.data.data.diseases;
  1526. this.form.remark = patietInfo.remark;
  1527. this.form.sch_remark = patietInfo.sch_remark;
  1528. this.form.diagnose = patietInfo.diagnose;
  1529. this.form.patient_complains = patietInfo.patient_complains;
  1530. this.form.present_history = patietInfo.present_history;
  1531. this.form.past_history = patietInfo.past_history;
  1532. this.form.temperature = patietInfo.temperature;
  1533. this.form.pulse = patietInfo.pulse;
  1534. this.form.respiratory = patietInfo.respiratory;
  1535. this.form.sbp = patietInfo.sbp;
  1536. this.form.dbp = patietInfo.dbp;
  1537. this.form.contact_name = patietInfo.contact_name;
  1538. this.form.tell_phone = patietInfo.tell_phone;
  1539. this.form.dialysis_age = patietInfo.dialysis_age;
  1540. this.form.record_number = patietInfo.record_number
  1541. if (patietInfo.expense_kind == 0) {
  1542. this.form.expense_kind = "";
  1543. } else {
  1544. this.form.expense_kind = patietInfo.expense_kind;
  1545. }
  1546. this.form.first_treatment_date = uParseTime(
  1547. patietInfo.first_treatment_date,
  1548. "{y}-{m}-{d}"
  1549. );
  1550. this.form.patient_source = patietInfo.patient_source
  1551. // this.form.initial = patietInfo.initial_dialysis + "";
  1552. // this.form.dialysisTotal = patietInfo.total_dialysis + "";
  1553. // this.form.assessment = patietInfo.evaluate;
  1554. // if (patietInfo.patient_type > 0) {
  1555. // this.form.patientType = patietInfo.patient_type;
  1556. // }
  1557. // if (patietInfo.partition_id > 0) {
  1558. // this.form.partition = patietInfo.partition_id;
  1559. // }
  1560. // if (patietInfo.bed_id > 0) {
  1561. // this.form.bed = patietInfo.bed_id;
  1562. // }
  1563. // this.form.healthCareDueDate = uParseTime(
  1564. // patietInfo.health_care_due_date,
  1565. // "{y}-{m}-{d}"
  1566. // );
  1567. // if (patietInfo.blood_type > 0) {
  1568. // this.form.blood = patietInfo.blood_type;
  1569. // }
  1570. // if (patietInfo.rh > 0) {
  1571. // this.form.rh = patietInfo.rh;
  1572. // }
  1573. // this.form.healthCareDueAlertDate = uParseTime(
  1574. // patietInfo.health_care_due_alert_date,
  1575. // "{y}-{m}-{d}"
  1576. // );
  1577. // this.form.receivingDate = uParseTime(
  1578. // patietInfo.receiving_date,
  1579. // "{y}-{m}-{d}"
  1580. // );
  1581. // this.form.dialysisAge = dialysisAge(
  1582. // this.form.firstDialysisDate,
  1583. // "-"
  1584. // );
  1585. // if (patietInfo.induction_period > 0) {
  1586. // this.form.induction = patietInfo.induction_period;
  1587. // }
  1588. // if (patietInfo.attending_doctor_id > 0) {
  1589. // this.form.doctor = patietInfo.attending_doctor_id;
  1590. // }
  1591. // if (patietInfo.head_nurse_id > 0) {
  1592. // this.form.nurse = patietInfo.head_nurse_id;
  1593. // }
  1594. // if (patietInfo.registrars_id > 0) {
  1595. // this.form.registrars = patietInfo.registrars_id;
  1596. // }
  1597. var contagionsArr = response.data.data.contagions;
  1598. var diseasesArr = response.data.data.diseases;
  1599. // console.log('123456',response.data.data);
  1600. this.patientPrint = patietInfo;
  1601. var sourceLen = this.sourceOptions.length;
  1602. for (let index = 0; index < sourceLen; index++) {
  1603. if (this.sourceOptions[index].value === patietInfo.source) {
  1604. this.patientPrint.source = this.sourceOptions[index].label;
  1605. break;
  1606. }
  1607. }
  1608. var styleLen = this.styleOptions.length;
  1609. for (let index = 0; index < styleLen; index++) {
  1610. if (this.styleOptions[index].id === patietInfo.patient_type) {
  1611. this.patientPrint.patient_type = this.styleOptions[index].name;
  1612. break;
  1613. }
  1614. }
  1615. var partitionLen = this.partitionOptions.length;
  1616. for (let index = 0; index < partitionLen; index++) {
  1617. if (this.partitionOptions[index].id === patietInfo.partition_id) {
  1618. this.patientPrint.partition_id =
  1619. this.partitionOptions[index].name;
  1620. break;
  1621. }
  1622. }
  1623. this.patientPrint.bed_id =
  1624. patietInfo.bed_id > 0 ? patietInfo.bed_id : "";
  1625. if (patietInfo.gender === 1) {
  1626. this.patientPrint.gender = "男";
  1627. } else if (patietInfo.gender === 2) {
  1628. this.patientPrint.gender = "女";
  1629. } else {
  1630. this.patientPrint.gender = "";
  1631. }
  1632. var maritalLen = this.maritalOptions.length;
  1633. console.log(maritalLen);
  1634. for (let index = 0; index < maritalLen; index++) {
  1635. if (
  1636. this.maritalOptions[index].id ==
  1637. response.data.data.patient.marital_status
  1638. ) {
  1639. this.patientPrint.marital_status =
  1640. this.maritalOptions[index].name;
  1641. }
  1642. }
  1643. this.patientPrint.birthday = uParseTime(
  1644. patietInfo.birthday,
  1645. "{y}-{m}-{d}"
  1646. );
  1647. this.patientPrint.age = jsGetAge(this.patientPrint.birthday, "-");
  1648. this.patientPrint.patient_complains =
  1649. patietInfo.patient_complains.replace(/\n/g, "<br/>");
  1650. // console.log('qwerewqrt',patietInfo.present_history);
  1651. this.patientPrint.present_history =
  1652. patietInfo.present_history.replace(/\n/g, "<br/>");
  1653. console.log('qwerewqrt',patietInfo.past_history);
  1654. this.patientPrint.past_history = patietInfo.past_history.replace(
  1655. /\n/g,
  1656. "<br/>"
  1657. );
  1658. this.patientPrint.remark = patietInfo.remark.replace(
  1659. /\n/g,
  1660. "<br/>"
  1661. );
  1662. this.patientPrint.sch_remark = patietInfo.sch_remark.replace(
  1663. /\n/g,
  1664. "<br/>"
  1665. );
  1666. this.patientPrint.diagnose = patietInfo.diagnose.replace(
  1667. /\n/g,
  1668. "<br/>"
  1669. );
  1670. if (typeof patietInfo.temperature === "number") {
  1671. this.patientPrint.temperature = patietInfo.temperature.toFixed(1);
  1672. }
  1673. if (patietInfo.reimbursement_way_id > 0) {
  1674. var wayLen = this.wayOptions.length;
  1675. for (let index = 0; index < wayLen; index++) {
  1676. if (
  1677. this.wayOptions[index].id === patietInfo.reimbursement_way_id
  1678. ) {
  1679. this.patientPrint.reimbursement_way_id =
  1680. this.wayOptions[index].name;
  1681. break;
  1682. }
  1683. }
  1684. } else {
  1685. this.patientPrint.reimbursement_way_id = "";
  1686. }
  1687. if (patietInfo.health_care_due_date !== 0) {
  1688. this.patientPrint.health_care_due_date = uParseTime(
  1689. patietInfo.health_care_due_date,
  1690. "{y}-{m}-{d}"
  1691. );
  1692. } else {
  1693. this.patientPrint.health_care_due_date = "";
  1694. }
  1695. if (patietInfo.blood_type > 0) {
  1696. var typeLen = this.typeOptions.length;
  1697. for (let index = 0; index < typeLen; index++) {
  1698. if (this.typeOptions[index].id === patietInfo.blood_type) {
  1699. this.patientPrint.blood_type = this.typeOptions[index].name;
  1700. break;
  1701. }
  1702. }
  1703. } else {
  1704. this.patientPrint.blood_type = "";
  1705. }
  1706. if (patietInfo.rh > 0) {
  1707. var rhLen = this.rhOptions.length;
  1708. for (let index = 0; index < rhLen; index++) {
  1709. if (this.rhOptions[index].id === patietInfo.rh) {
  1710. this.patientPrint.rh = this.rhOptions[index].name;
  1711. break;
  1712. }
  1713. }
  1714. } else {
  1715. this.patientPrint.rh = "";
  1716. }
  1717. if (patietInfo.health_care_due_alert_date !== 0) {
  1718. this.patientPrint.health_care_due_alert_date = uParseTime(
  1719. patietInfo.health_care_due_alert_date,
  1720. "{y}-{m}-{d}"
  1721. );
  1722. } else {
  1723. this.patientPrint.health_care_due_alert_date = "";
  1724. }
  1725. if (patietInfo.education_level > 0) {
  1726. var eLen = this.educationOptions.length;
  1727. for (let index = 0; index < eLen; index++) {
  1728. if (
  1729. this.educationOptions[index].id === patietInfo.education_level
  1730. ) {
  1731. this.patientPrint.education_level =
  1732. this.educationOptions[index].name;
  1733. break;
  1734. }
  1735. }
  1736. } else {
  1737. this.patientPrint.education_level = "";
  1738. }
  1739. if (patietInfo.profession > 0) {
  1740. var eLen = this.professionOptions.length;
  1741. for (let index = 0; index < eLen; index++) {
  1742. if (
  1743. this.professionOptions[index].id === patietInfo.profession
  1744. ) {
  1745. this.patientPrint.profession =
  1746. this.professionOptions[index].name;
  1747. break;
  1748. }
  1749. }
  1750. } else {
  1751. this.patientPrint.profession = "";
  1752. }
  1753. if (patietInfo.receiving_date !== 0) {
  1754. this.patientPrint.receiving_date = uParseTime(
  1755. patietInfo.receiving_date,
  1756. "{y}-{m}-{d}"
  1757. );
  1758. } else {
  1759. this.patientPrint.receiving_date = "";
  1760. }
  1761. if (patietInfo.first_dialysis_date !== 0) {
  1762. this.patientPrint.first_dialysis_date = uParseTime(
  1763. patietInfo.first_dialysis_date,
  1764. "{y}-{m}-{d}"
  1765. );
  1766. this.patientPrint.dialysis_age = dialysisAge(
  1767. this.patientPrint.first_dialysis_date
  1768. );
  1769. } else {
  1770. this.patientPrint.first_dialysis_date = "";
  1771. this.patientPrint.dialysis_age = "";
  1772. }
  1773. if (patietInfo.induction_period > 0) {
  1774. var eLen = this.inductionOptions.length;
  1775. for (let index = 0; index < eLen; index++) {
  1776. if (
  1777. this.inductionOptions[index].id ===
  1778. patietInfo.induction_period
  1779. ) {
  1780. this.patientPrint.induction_period =
  1781. this.inductionOptions[index].name;
  1782. break;
  1783. }
  1784. }
  1785. } else {
  1786. this.patientPrint.induction_period = "";
  1787. }
  1788. if (patietInfo.attending_doctor_id > 0) {
  1789. var eLen = this.adminUserOptions.length;
  1790. for (let index = 0; index < eLen; index++) {
  1791. if (
  1792. this.adminUserOptions[index].id ===
  1793. patietInfo.attending_doctor_id
  1794. ) {
  1795. this.patientPrint.attending_doctor_id =
  1796. this.adminUserOptions[index].name;
  1797. break;
  1798. }
  1799. }
  1800. } else {
  1801. this.patientPrint.attending_doctor_id = "";
  1802. }
  1803. if (patietInfo.head_nurse_id > 0) {
  1804. var eLen = this.adminUserOptions.length;
  1805. for (let index = 0; index < eLen; index++) {
  1806. if (
  1807. this.adminUserOptions[index].id === patietInfo.head_nurse_id
  1808. ) {
  1809. this.patientPrint.head_nurse_id =
  1810. this.adminUserOptions[index].name;
  1811. break;
  1812. }
  1813. }
  1814. } else {
  1815. this.patientPrint.head_nurse_id = "";
  1816. }
  1817. if (contagionsArr.length > 0) {
  1818. var contagionsIdArr = {};
  1819. var alen = contagionsArr.length;
  1820. for (let index = 0; index < alen; index++) {
  1821. contagionsIdArr[contagionsArr[index]] = 1;
  1822. }
  1823. var printContagions = [];
  1824. var clen = this.contagionList.length;
  1825. for (let index = 0; index < clen; index++) {
  1826. if (this.contagionList[index].id in contagionsIdArr) {
  1827. printContagions.push(this.contagionList[index].name);
  1828. }
  1829. }
  1830. this.patientPrint.contagions = printContagions.join("、");
  1831. } else {
  1832. this.patientPrint.contagions = "阴性";
  1833. }
  1834. if (diseasesArr.length > 0) {
  1835. var diseasesIdArr = {};
  1836. var alen = diseasesArr.length;
  1837. for (let index = 0; index < alen; index++) {
  1838. diseasesIdArr[diseasesArr[index]] = 1;
  1839. }
  1840. var printDisease = [];
  1841. var clen = this.checkDisease.length;
  1842. for (let index = 0; index < clen; index++) {
  1843. if (this.checkDisease[index].id in diseasesIdArr) {
  1844. printDisease.push(this.checkDisease[index].name);
  1845. }
  1846. }
  1847. this.patientPrint.diseases = printDisease.join("、");
  1848. } else {
  1849. this.patientPrint.diseases = "";
  1850. }
  1851. if (patietInfo.registrars_id > 0) {
  1852. var eLen = this.adminUserOptions.length;
  1853. for (let index = 0; index < eLen; index++) {
  1854. if (
  1855. this.adminUserOptions[index].id === patietInfo.registrars_id
  1856. ) {
  1857. this.patientPrint.registrars =
  1858. this.adminUserOptions[index].name;
  1859. this.form.registrars = this.adminUserOptions[index].name;
  1860. break;
  1861. }
  1862. }
  1863. } else {
  1864. this.patientPrint.registrars = "";
  1865. }
  1866. if (patietInfo.hospital_first_dialysis_date !== 0) {
  1867. this.patientPrint.hospital_first_dialysis_date = uParseTime(
  1868. patietInfo.hospital_first_dialysis_date,
  1869. "{y}-{m}-{d}"
  1870. );
  1871. } else {
  1872. this.patientPrint.hospital_first_dialysis_date = "";
  1873. }
  1874. this.checkIdCardNo();
  1875. } else {
  1876. console.log("patient get err state");
  1877. this.$notify.error({
  1878. title: "错误",
  1879. message: "网络异常",
  1880. });
  1881. this.$router.push("/patients/patients");
  1882. }
  1883. // this.postForm = response.data
  1884. // // Just for test
  1885. // this.postForm.title += ` Article Id:${this.postForm.id}`
  1886. // this.postForm.content_short += ` Article Id:${this.postForm.id}`
  1887. })
  1888. .catch((err) => {
  1889. console.log("patient get err", err);
  1890. this.$notify.error({
  1891. title: "错误",
  1892. message: "网络异常",
  1893. });
  1894. this.$router.push("/patients/patients");
  1895. });
  1896. },
  1897. fetchAllDoctorAndNurse() {
  1898. fetchAllDoctorAndNurse().then((response) => {
  1899. if (response.data.state === 1) {
  1900. this.doctorOptions = response.data.data.doctors;
  1901. this.nurseOptions = response.data.data.nursers;
  1902. }
  1903. });
  1904. },
  1905. fetchAllAdminUsers() {
  1906. fetchAllAdminUsers().then((response) => {
  1907. if (response.data.state === 1) {
  1908. this.adminUserOptions = response.data.data.users;
  1909. this.operators = response.data.data.operators
  1910. console.log("医生签名",this.operators)
  1911. }
  1912. });
  1913. },
  1914. getDcotorName(admin_user_id){
  1915. var url = ""
  1916. if(this.operators!=null && this.operators.length > 0){
  1917. for(let i=0;i<this.operators.length;i++){
  1918. if(admin_user_id == this.operators[i].admin_user_id){
  1919. url = this.operators[i].url
  1920. }
  1921. }
  1922. }
  1923. return url
  1924. },
  1925. getDcotorNameOne(admin_user_id){
  1926. var name = ""
  1927. for(let i=0;i<this.adminUserOptions.length;i++){
  1928. if(admin_user_id == this.adminUserOptions[i].id){
  1929. name = this.adminUserOptions[i].name
  1930. }
  1931. }
  1932. return name
  1933. },
  1934. printCard() {
  1935. var ptime = Math.round(new Date().getTime() / 1000);
  1936. this.print_time = uParseTime(ptime, "{y}年{m}月{d}日");
  1937. const style =
  1938. "@media print { .print_main_content { background-color: white; width:960px; margin:0 auto; padding: 0 0 20px 0; } .print_main_content .order_title { text-align: center; font-size: 23px; line-height: 50px; font-weight: 500; } .print_main_content table { width: 100%; border: 1px solid; border-collapse: collapse; padding: 2px; } .print_main_content table tbody tr td { border: 1px solid; text-align: center; padding: 10px 8px; } .td_proj_title { font-size: 18px; line-height: 25px; font-weight: 500; } .td_proj_content { font-size: 18px; line-height: 25px; } .td_align_left { text-align: left; } .print_footnote_panel { font-size: 17px; line-height: 40px; } .print_footnote_panel .proj { display: inline-block; width: 49%; } .print_footnote_panel .proj .proj_title { font-weight: 500;} }";
  1939. setTimeout(() => {
  1940. printJS({
  1941. printable: "print-card-info",
  1942. type: "html",
  1943. style: style,
  1944. scanStyles: false,
  1945. });
  1946. }, 1);
  1947. var patientID = this.patientPrint.id;
  1948. var name = this.patientPrint.name;
  1949. var gender = this.patientPrint.gender;
  1950. if (gender === 1) {
  1951. gender = "男";
  1952. }
  1953. if (gender === 2) {
  1954. gender = "女";
  1955. }
  1956. var idCardNo = this.patientPrint.id_card_no;
  1957. var dialysisNo = this.patientPrint.dialysis_no;
  1958. var phone = this.patientPrint.phone;
  1959. var healthCareNo = this.patientPrint.health_care_no;
  1960. // Base64加密
  1961. var epatientID = this.Base64.encode(patientID);
  1962. var ename = this.Base64.encode(name);
  1963. var egender = this.Base64.encode(gender);
  1964. var eidCardNo = this.Base64.encode(idCardNo);
  1965. var edialysisNo = this.Base64.encode(dialysisNo);
  1966. var ephone = this.Base64.encode(phone);
  1967. var eheathCareNo = this.Base64.encode(healthCareNo);
  1968. console.log(
  1969. "id号:" + epatientID,
  1970. "姓名:" + ename,
  1971. "性别:" + egender,
  1972. "身份证:" + eidCardNo,
  1973. "透析号:" + edialysisNo,
  1974. "电话:" + ephone,
  1975. "社保号:" + eheathCareNo
  1976. );
  1977. // var params =new Object();
  1978. // params.id = this.patientPrint.id
  1979. // params.name = this.patientPrint.name;
  1980. // this.$options.methods.qrcode(epatientID, ename, egender, eidCardNo, edialysisNo, ephone, eheathCareNo)// 调用生成二维码的方法
  1981. this.$options.methods.qrcode(
  1982. patientID,
  1983. name,
  1984. gender,
  1985. idCardNo,
  1986. dialysisNo,
  1987. phone,
  1988. healthCareNo
  1989. );
  1990. // this.$options.methods.qrcode(params)
  1991. },
  1992. showInspectDialog() {
  1993. this.dialogFormVisible = true;
  1994. },
  1995. qrcode(patientID, name, gender, idCardNo, dialysisNo, phone, healthCareNo) {
  1996. document.getElementById("qrcode").innerHTML = "";
  1997. new QRCode("qrcode", {
  1998. width: 200,
  1999. height: 200,
  2000. text:
  2001. "user_id:" +
  2002. patientID +
  2003. "," +
  2004. "name:" +
  2005. name +
  2006. "," +
  2007. "dialysis_no:" +
  2008. dialysisNo +
  2009. "," +
  2010. "gender:" +
  2011. gender +
  2012. "," +
  2013. "idcard_no:" +
  2014. idCardNo +
  2015. "," +
  2016. "phone:" +
  2017. phone +
  2018. "," +
  2019. "healthcare_no:" +
  2020. healthCareNo,
  2021. });
  2022. },
  2023. checkIdCardNo() {
  2024. if(this.$store.getters.xt_user.org_id != 10278 && this.$store.getters.xt_user.org_id != 10138) {
  2025. if (!isCardNo(this.form.idCardNo)) {
  2026. this.$message.error("身份证号码信息有误!");
  2027. this.form.birth = "";
  2028. return false;
  2029. }
  2030. }
  2031. var thisLen = this.form.idCardNo.length;
  2032. var birth = "";
  2033. if (thisLen == 15) {
  2034. birth = "19" + this.form.idCardNo.substr(6, 6);
  2035. } else {
  2036. birth = this.form.idCardNo.substr(6, 8);
  2037. }
  2038. this.form.birth =
  2039. birth.substr(0, 4) +
  2040. "-" +
  2041. birth.substr(4, 2) +
  2042. "-" +
  2043. birth.substr(6, 2);
  2044. this.form.age = jsGetAge(this.form.birth, "-");
  2045. },
  2046. // qrcode(params){
  2047. // new QRCode('qrcode',{
  2048. // width:200,
  2049. // height:200,
  2050. // text:params,
  2051. // })
  2052. // }
  2053. },
  2054. };
  2055. </script>
  2056. <style rel="stylesheet/scss" lang="scss" scoped>
  2057. .uploadHead {
  2058. margin-top: 25%;
  2059. }
  2060. .uploadHeadBtn {
  2061. width: 148px;
  2062. margin-top: 10px;
  2063. }
  2064. .el-form {
  2065. .el-col-6,
  2066. .el-col-8 {
  2067. width: 360px;
  2068. height: 59px !important;
  2069. }
  2070. .el-form-item {
  2071. // margin-bottom: 17px !important;
  2072. .el-select {
  2073. width: 100%;
  2074. }
  2075. .el-date-editor.el-input {
  2076. width: 100%;
  2077. }
  2078. .textarea {
  2079. width: 100%;
  2080. height: 70px;
  2081. border-color: #dcdfe6;
  2082. padding: 5px;
  2083. }
  2084. }
  2085. }
  2086. /deep/ .now_his{
  2087. .el-row{
  2088. .el-col-24{
  2089. .el-form-item{
  2090. .el-form-item__content{
  2091. height: 100%;
  2092. .el-textarea{
  2093. .el-textarea__inner{
  2094. height: 93%;
  2095. }
  2096. }
  2097. }
  2098. }
  2099. }
  2100. }
  2101. }
  2102. // #print-info-box .info_print {
  2103. // width: 920px;
  2104. // margin: 0 auto !important;
  2105. // position: relative;
  2106. // top: 0;
  2107. // left: 0;
  2108. // padding: 20px 30px;
  2109. // }
  2110. // #print-info-box .box-title {
  2111. // text-align: center;
  2112. // font-weight: 600;
  2113. // font-size: 30px;
  2114. // line-height: 80px;
  2115. // margin-bottom: 20px;
  2116. // }
  2117. // #print-info-box .unit-title {
  2118. // text-align: center;
  2119. // line-height: 40px;
  2120. // font-size: 20px;
  2121. // font-weight: 400;
  2122. // padding-top: 10px;
  2123. // /* border: 1px solid #333; */
  2124. // }
  2125. // #print-info-box .unit-box {
  2126. // padding: 15px;
  2127. // }
  2128. // #print-info-box .unit-box-item {
  2129. // display: flex;
  2130. // align-items: center;
  2131. // justify-content: space-between;
  2132. // padding: 4px 1em;
  2133. // }
  2134. // #print-info-box .unit-box-item-col3 {
  2135. // width: 30%;
  2136. // display: flex;
  2137. // padding: 4px 0;
  2138. // }
  2139. // #print-info-box .unit-box-item-col4 {
  2140. // width: 23%;
  2141. // display: flex;
  2142. // padding: 4px 0;
  2143. // }
  2144. // #print-info-box .item-value {
  2145. // flex: 1;
  2146. // border-bottom: 1px solid #333;
  2147. // }
  2148. </style>
  2149. <style scoped>
  2150. /* 打印表格的样式 */
  2151. .print_main_content {
  2152. background-color: white;
  2153. width: 960px;
  2154. margin: 0 auto;
  2155. padding: 0 0 0 0;
  2156. page-break-after: always;
  2157. }
  2158. .print_main_content .order_title {
  2159. text-align: center;
  2160. font-size: 23px;
  2161. line-height: 50px;
  2162. font-weight: 500;
  2163. }
  2164. .print_main_content table {
  2165. width: 100%;
  2166. border: 1px solid;
  2167. border-collapse: collapse;
  2168. padding: 2px;
  2169. }
  2170. .print_main_content table tbody tr td {
  2171. border: 1px solid;
  2172. text-align: center;
  2173. /* font-size: 17px; */
  2174. /* padding: 10px 8px; */
  2175. }
  2176. .td_proj_title {
  2177. font-size: 17px;
  2178. /* line-height: 20px; */
  2179. font-weight: 500;
  2180. }
  2181. .td_proj_content {
  2182. font-size: 17px;
  2183. /* line-height: 20px; */
  2184. }
  2185. .td_align_left {
  2186. text-align: left;
  2187. }
  2188. .print_footnote_panel {
  2189. font-size: 17px;
  2190. line-height: 40px;
  2191. }
  2192. .print_footnote_panel .proj {
  2193. display: inline-block;
  2194. width: 49%;
  2195. }
  2196. .print_footnote_panel .proj .proj_title {
  2197. font-weight: 500;
  2198. }
  2199. .el-select-dropdown {
  2200. z-index: 998 !important;
  2201. }
  2202. </style>