printTwo.vue 25KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793
  1. <template>
  2. <div id="prescriptionPrint2">
  3. <div
  4. id="prescription-print"
  5. v-if="item.advices.length == 0"
  6. class="prescription-print"
  7. v-for="(item, index) in advicePrint"
  8. :key="index"
  9. >
  10. <span v-if="org_id == 10138">
  11. <img
  12. src="https://kuyi.shengws.com/bailin/bltotle.jpg"
  13. style="width: 100%"
  14. alt=""
  15. /></span>
  16. <span v-if="org_id == 10278">
  17. <img
  18. src="https://kuyi.shengws.com/beierlog.png"
  19. style="width: 100%"
  20. alt=""
  21. /></span>
  22. <div class="printTitle">
  23. 治疗单
  24. <span
  25. v-if="item.med_type == '1111'"
  26. style="margin-left: 50px; border: 1px solid #000"
  27. >精一</span
  28. >
  29. <span
  30. v-if="item.med_type == '1112'"
  31. style="margin-left: 50px; border: 1px solid #000"
  32. >精二</span
  33. >
  34. </div>
  35. <div style="display: flex">
  36. <div style="width: 33%; display: flex">
  37. 费别:<span class="under_line">{{
  38. faber && faber.transBody
  39. ? getName(faber.transBody.outputlist1)
  40. : "自费"
  41. }}</span>
  42. </div>
  43. <div style="width: 33%; display: flex">
  44. 电脑号:<span class="under_line">{{
  45. faber && faber.transBody ? faber.transBody.aac999 : ""
  46. }}</span>
  47. </div>
  48. <div style="width: 33%; display: flex">
  49. 处方编号:<span class="under_line">{{
  50. item.prescription_number.substring(
  51. item.prescription_number.length - 6
  52. )
  53. }}</span>
  54. </div>
  55. </div>
  56. <div class="infoTitle">
  57. <div>
  58. 姓名:{{
  59. item.patient.name
  60. ? item.patient.name.indexOf("(") > -1
  61. ? item.patient.name.substring(
  62. 0,
  63. item.patient.name.indexOf("(")
  64. )
  65. : item.patient.name
  66. : ""
  67. }}
  68. </div>
  69. <div>
  70. 性别:
  71. <span v-if="item.patient.gender == 1">男</span>
  72. <span v-if="item.patient.gender == 2">女</span>
  73. </div>
  74. <div>
  75. 年龄:{{
  76. getNewAge(item.patient.birthday)
  77. ? getNewAge(item.patient.birthday)
  78. : ""
  79. }}岁
  80. </div>
  81. </div>
  82. <div class="infoMain">
  83. <div style="margin-bottom: 10px; display: flex">
  84. 门诊号码:<span class="under_line">{{
  85. hisPatient.number ? hisPatient.number : ""
  86. }}</span>
  87. </div>
  88. <div style="margin-bottom: 10px; display: flex">
  89. 科别:<span class="under_line">{{
  90. item.info ? getDepart(item.info.departments) : ""
  91. }}</span>
  92. </div>
  93. <div style="margin-bottom: 10px; display: flex">
  94. 临床诊断:{{ getDiagnosis(item.info.diagnosis) }}
  95. </div>
  96. <div style="margin-bottom: 10px; display: flex">
  97. 自费药品签名:<span class="under_line"></span>
  98. </div>
  99. <!-- <div style="margin-bottom: 10px;display:flex;">医保卡号:{{item.hisPatient.number?item.hisPatient.number:""}}</div> -->
  100. <div style="margin-bottom: 10px; display: flex">
  101. 联系方式:<span class="under_line">{{ item.patient.phone }}</span>
  102. </div>
  103. <div style="margin-bottom: 10px; display: flex">
  104. 开具日期:<span class="under_line">{{
  105. getTime(item.pre_time) ? getTime(item.pre_time).split(" ")[0] : ""
  106. }}</span>
  107. </div>
  108. <!-- <div>地址:{{item.patient.home_address}}</div> -->
  109. <!-- <div style="display:flex;width:50%;">临床诊断:{{getDiagnosis(item.info.diagnosis)}}</div> -->
  110. </div>
  111. <!-- <div class="prescriptionBox">
  112. <table style="width:100%;text-align:center;line-height:25px;">
  113. <tr>
  114. <td>序号</td>
  115. <td>项目名称</td>
  116. <td>数量</td>
  117. <td>单位</td>
  118. <td>单价</td>
  119. <td>部位</td>
  120. <td>备注</td>
  121. <td>天数</td>
  122. </tr>
  123. <tr v-for="(it,index) in item.project" :key="index">
  124. <td>{{index+1}}</td>
  125. <td>{{it.type == 2 ?getProjectName(it.project_id):it.good_info.good_name}}</td>
  126. <td>{{it.single_dose}}</td>
  127. <td>{{getUnit(it.unit)}}</td>
  128. <td>{{it.price}}</td>
  129. <td></td>
  130. <td>{{it.remark}}</td>
  131. <td>{{it.day}}</td>
  132. </tr>
  133. <tr v-for="(it,index) in item.advices" :key="index">
  134. <td>{{index+1}}</td>
  135. <td>{{it.advice_name?it.advice_name:''}}</td>
  136. <td>{{it.single_dose?it.single_dose:''}}</td>
  137. <td>{{it.single_dose_unit?it.single_dose_unit:''}}</td>
  138. <td>{{it.price}}</td>
  139. <td></td>
  140. <td>{{it.remark}}</td>
  141. <td>{{it.day}}</td>
  142. </tr>
  143. </table>
  144. </div> -->
  145. <div class="prescriptionBox">
  146. <div class="Rp">Rp:</div>
  147. <!-- <div class="drugsBox" v-for="(it,index) in item.advices" :key="index">
  148. <div class="drugsOne"><span style="font-weight:bold;">{{ index+1 + '.' }}</span>{{it.advice_name?it.advice_name:""}}&nbsp;&nbsp;<span v-if="it.drug.min_unit != it.drug.dose_unit">{{it.drug.dose}}{{it.drug.dose_unit}}&nbsp;* &nbsp;</span>{{it.drug.min_number}}{{it.drug.min_unit}}/{{it.drug.max_unit}}&nbsp;×&nbsp; {{it.prescribing_number}}{{it.prescribing_number_unit}}</div>
  149. </div> -->
  150. <div class="drugsBox" v-for="(it, index) in item.project" :key="index">
  151. <div class="drugsOne">
  152. <span style="font-weight: bold">{{ index + 1 + "." }}</span
  153. >{{
  154. it.type == 2 ? it.project.project_name : it.good_info.good_name
  155. }}&nbsp;&nbsp;×&nbsp; {{ it.count }}{{ unit }}
  156. </div>
  157. </div>
  158. <div style="text-align: center">(以下空白)</div>
  159. </div>
  160. <div style="display: flex">
  161. <div>
  162. 医&nbsp;&nbsp;&nbsp;&nbsp;师:
  163. <span
  164. style="width: 100px; display: inline-block"
  165. v-if="item.creator == ''"
  166. >
  167. {{ item.doctor ? item.doctor : "" }}
  168. </span>
  169. <span
  170. style="width: 100px; display: inline-block"
  171. v-else-if="doc_name != ''"
  172. >
  173. {{ doc_name }}
  174. </span>
  175. <img
  176. style="height: 30px"
  177. :src="setAdminUserES(item.creator,item.doctor)"
  178. alt=""
  179. srcset=""
  180. v-else
  181. />
  182. </div>
  183. <!-- <div>药品金额:{{getTotalOne(item.id).toFixed(2)?getTotalOne(item.id).toFixed(2):''}}</div> -->
  184. </div>
  185. <div style="display: flex">
  186. <div style="display: flex">核对护士:</div>
  187. </div>
  188. <div style="display: flex">
  189. 打印时间:<span style="border-bottom: 1px solid #000">{{
  190. getTime(new Date()) ? getTime(new Date()) : ""
  191. }}</span>
  192. </div>
  193. <span v-if="org_id == 10138"
  194. ><img
  195. src="https://kuyi.shengws.com/bailin/blend.jpg"
  196. style="width: 100%"
  197. alt=""
  198. /></span>
  199. <span v-if="org_id == 10278"
  200. ><img
  201. src="https://kuyi.shengws.com/bailinbeier.png"
  202. style="width: 100%"
  203. alt=""
  204. /></span>
  205. <div style="page-break-after: always"></div>
  206. </div>
  207. <!-- <div id='prescriptionPrint'>
  208. <div v-for="(item,index) in advicePrint" :key="index">
  209. <div id='prescription-print' class="prescription-print" style="page-break-after: always;">
  210. <div style="display:flex;justify-content: space-between;font-weight:bold;">
  211. <div style="width:200px;display:flex;justify-content: space-between;font-weight:bold;">
  212. <span>费别</span>
  213. <span>自费</span>
  214. <span>公费</span>
  215. <span>保险</span>
  216. <span>其他</span>
  217. </div>
  218. <div>就诊日期:{{getTime(item.ctime)}}</div>
  219. </div>
  220. <div class="printTitle">血液透析中心</div>
  221. <div class="printTitle">处方、治疗单</div>
  222. <div class="infoTitle">
  223. <div>门诊编号:</div>
  224. <div>电脑号:</div>
  225. </div>
  226. <div class="infoMain">
  227. <div style="margin-bottom: 10px;width:25%">姓名:{{item.patient.name}}</div>
  228. <div style="margin-bottom: 10px;width:25%">性别:
  229. <span v-if="item.patient.gender == 1">男</span>
  230. <span v-if="item.patient.gender == 2">女</span>
  231. </div>
  232. <div style="margin-bottom: 10px;width:25%">年龄:
  233. <span>{{item.patient.age}}</span>
  234. </div>
  235. <div style="margin-bottom: 10px;width:25%">参保类型:</div>
  236. <div style="margin-bottom: 10px;width:50%;">联系电话:{{item.patient.phone}}</div>
  237. <div style="width:50%;">地址:{{item.patient.unit_address}}</div>
  238. <div style="width:100%;">诊断:{{item.patient.diagnose}}</div>
  239. </div>
  240. <div class="prescriptionBox">
  241. <table style="width:100%;text-align:center;line-height:25px;">
  242. <tr>
  243. <td>序号</td>
  244. <td>项目名称</td>
  245. <td>数量</td>
  246. <td>单位</td>
  247. <td>单价</td>
  248. <td>部位</td>
  249. <td>备注</td>
  250. <td>天数</td>
  251. </tr>
  252. <tr v-for="(it,index) in item.project" :key="index">
  253. <td>{{index+1}}</td>
  254. <td>{{getProjectName(it.project_id)}}</td>
  255. <td>{{it.single_dose}}</td>
  256. <td>{{getUnit(it.unit)}}</td>
  257. <td>{{it.price}}</td>
  258. <td></td>
  259. <td>{{it.remark}}</td>
  260. <td>{{it.day}}</td>
  261. </tr>
  262. </table>
  263. </div>
  264. <div class="infoTitle">
  265. <div>开单医生:{{getDoctor(item.doctor)?getDoctor(item.doctor):""}}</div>
  266. <div>签章:</div>
  267. </div>
  268. <div class="actionBar">
  269. <div>执行医生:{{getDoctor(item.doctor)?getDoctor(item.doctor):""}}</div>
  270. <div>费用:</div>
  271. </div>
  272. <table style="width:100%;text-align:center;line-height:25px;border-collapse: collapse;" border="1">
  273. <tr>
  274. <td style="width:16%;">治疗时间</td>
  275. <td style="width:16%;"></td>
  276. <td style="width:16%;"></td>
  277. <td style="width:16%;"></td>
  278. <td style="width:16%;"></td>
  279. <td style="width:16%;"></td>
  280. </tr>
  281. <tr>
  282. <td style="width:16%;">医生签字</td>
  283. <td style="width:16%;"></td>
  284. <td style="width:16%;"></td>
  285. <td style="width:16%;"></td>
  286. <td style="width:16%;"></td>
  287. <td style="width:16%;"></td>
  288. </tr>
  289. <tr>
  290. <td style="width:16px;">患者签字</td>
  291. <td style="width:16px;"></td>
  292. <td style="width:16px;"></td>
  293. <td style="width:16px;"></td>
  294. <td style="width:16px;"></td>
  295. <td style="width:16px;"></td>
  296. </tr>
  297. </table>
  298. </div>
  299. </div>
  300. </div> -->
  301. </div>
  302. </template>
  303. <script>
  304. import { jsGetAge, uParseTime } from "@/utils/tools";
  305. import { getAllDoctorList, getPrescriptionPrint } from "@/api/project/project";
  306. import { getInitData } from "@/api/his/his";
  307. export default {
  308. props: {
  309. patient_id: Number,
  310. record_date: String,
  311. prescription_id: Number,
  312. ids: String,
  313. },
  314. data() {
  315. return {
  316. doctorList_1: [],
  317. operatorMaps: {},
  318. doctorList: [],
  319. advicePrint: {},
  320. doc_name:"",
  321. patient: {},
  322. tableData: [],
  323. prescriptionInfo: [],
  324. projectList: [],
  325. prescriptions: [],
  326. settlement: [
  327. { value: 1, label: "医保" },
  328. { value: 2, label: "自费" },
  329. { value: 3, label: "公费" },
  330. { value: 4, label: "农保" },
  331. { value: 5, label: "会员" },
  332. { value: 6, label: "职工" },
  333. { value: 7, label: "合同" },
  334. ],
  335. hisPatient: {},
  336. diagnoses: [],
  337. department: [],
  338. faber: {},
  339. org_id: 0,
  340. };
  341. },
  342. methods: {
  343. // 电子签名
  344. setAdminUserES(id,name) {
  345. if (id == 0) {
  346. return "";
  347. }
  348. if (id in this.operatorMaps) {
  349. return this.operatorMaps[id].url;
  350. } else {
  351. this.doc_name = name
  352. return "";
  353. }
  354. },
  355. getNewAge(birthday) {
  356. // var myDate = new Date(birthday * 1000)
  357. // var month = myDate.getMonth() + 1
  358. // var day = myDate.getDate()
  359. // var age = new Date().getFullYear() - myDate.getFullYear()
  360. // if (month < new Date().getMonth() + 1 || new Date().getMonth() + 1 == month && day <= new Date().getDate()) {
  361. // age++
  362. // }
  363. // return age
  364. var nowTime = new Date().getTime();
  365. //一年毫秒数(365 * 86400000 = 31536000000)
  366. return Math.ceil((nowTime - birthday * 1000) / 31536000000);
  367. },
  368. getAge(patient) {
  369. var thisLen = patient.id_card_no.length;
  370. var birth = "";
  371. if (thisLen == 15) {
  372. birth = "19" + patient.id_card_no.substr(6, 6);
  373. } else {
  374. birth = patient.id_card_no.substr(6, 8);
  375. }
  376. var births =
  377. birth.substr(0, 4) +
  378. "-" +
  379. birth.substr(4, 2) +
  380. "-" +
  381. birth.substr(6, 2);
  382. return jsGetAge(births, "-");
  383. },
  384. printThisPage() {
  385. var ptime = Math.round(new Date().getTime() / 1000);
  386. this.print_time = uParseTime(ptime, "{y}-{m}-{d} {h}:{i}");
  387. const style =
  388. "@media print {.printTitle{font-size: 22px;text-align: center;font-weight: bold;}.infoTitle{display: flex;margin-top:10px;line-height: 1px;padding:0 10px;}.infoTitle p{width: 200px;}.otherInfo{display: flex;margin-top:10px;padding:0 10px;}.otherInfo span{display:inline-block;}.recordTitle{display: flex;margin-top:10px;line-height: 24px;padding:0 10px;border-bottom: 2px solid #000;}.recordTitle p{width: 200px;}}";
  389. printJS({
  390. printable: "prescription-print",
  391. type: "html",
  392. style: style,
  393. scanStyles: false,
  394. });
  395. },
  396. getDepart(id) {
  397. var name = "";
  398. for (let i = 0; i < this.department.length; i++) {
  399. if (id == this.department[i].id) {
  400. name = this.department[i].name;
  401. }
  402. }
  403. return name;
  404. },
  405. getAllDoctorList() {
  406. getAllDoctorList().then((response) => {
  407. if (response.data.state == 1) {
  408. var doctor = response.data.data.doctor;
  409. this.doctorList = doctor;
  410. }
  411. });
  412. },
  413. getDoctor(id) {
  414. var name = "";
  415. for (let i = 0; i < this.doctorList.length; i++) {
  416. if (id == this.doctorList[i].admin_user_id) {
  417. name = this.doctorList[i].user_name;
  418. }
  419. }
  420. return name;
  421. },
  422. getTime(value, temp) {
  423. if (value != undefined) {
  424. return uParseTime(value, temp);
  425. }
  426. return "";
  427. },
  428. getPrescriptionPrint() {
  429. var params = {
  430. patient_id: this.patient_id,
  431. record_date: this.record_date,
  432. prescription_id: this.prescription_id,
  433. ids: this.ids,
  434. p_type: 2,
  435. };
  436. console.log("999999", params);
  437. getPrescriptionPrint(params).then((response) => {
  438. if (response.data.state == 1) {
  439. var advicePrint = response.data.data.advicePrint;
  440. console.log("adviceprint", advicePrint);
  441. this.advicePrint = advicePrint;
  442. this.prescriptions = advicePrint;
  443. var projectlist = response.data.data.projectlist;
  444. console.log("所有项目列表", projectlist);
  445. this.projectList = projectlist;
  446. this.hisPatient = response.data.data.hisPatient;
  447. this.doctorList_1 = response.data.data.eles;
  448. console.log(this.doctorList_1, "医生列表");
  449. if (this.doctorList_1.length > 0) {
  450. var operatorsLen = this.doctorList_1.length;
  451. for (var index = 0; index < operatorsLen; index++) {
  452. this.$set(
  453. this.operatorMaps,
  454. this.doctorList_1[index].creator,
  455. this.doctorList_1[index]
  456. );
  457. }
  458. }
  459. let projectPrint = [];
  460. let total = 0;
  461. this.advicePrint.map((item) => {
  462. console.log(item.project.length);
  463. if (item.project.length > 0) {
  464. for (var i = item.project.length - 1; i >= 0; i--) {
  465. if (item.project[i].type == 2) {
  466. if (item.project[i].project.cost_classify == 3) {
  467. item.project.splice(i, 1);
  468. }
  469. }
  470. }
  471. }
  472. });
  473. let outputlist1Name = JSON.parse(response.data.data.his.patient_info);
  474. this.faber = outputlist1Name;
  475. }
  476. });
  477. },
  478. getProjectName(id) {
  479. var project_name = "";
  480. for (let i = 0; i < this.projectList.length; i++) {
  481. if (id == this.projectList[i].id) {
  482. project_name = this.projectList[i].project_name;
  483. }
  484. }
  485. return project_name;
  486. },
  487. getUnit(id) {
  488. var unit = "";
  489. for (let i = 0; i < this.projectList.length; i++) {
  490. if (id == this.projectList[i].id) {
  491. unit = this.projectList[i].unit;
  492. }
  493. }
  494. return unit;
  495. },
  496. getTotalOne(id) {
  497. var total = 0;
  498. var addtotal = 0;
  499. for (let i = 0; i < this.prescriptions.length; i++) {
  500. if (id == this.prescriptions[i].id) {
  501. if (this.prescriptions[i].project != null) {
  502. for (let a = 0; a < this.prescriptions[i].project.length; a++) {
  503. total =
  504. total +
  505. this.prescriptions[i].project[a].price *
  506. this.prescriptions[i].project[a].count;
  507. }
  508. }
  509. if (this.prescriptions[i].additionalcharge != null) {
  510. for (
  511. let a = 0;
  512. a < this.prescriptions[i].additionalcharge.length;
  513. a++
  514. ) {
  515. addtotal =
  516. addtotal +
  517. this.prescriptions[i].additionalcharge[a].price *
  518. this.prescriptions[i].additionalcharge[a].count;
  519. }
  520. }
  521. addtotal = Math.floor(addtotal * 100) / 100;
  522. }
  523. }
  524. for (let i = 0; i < this.prescriptions.length; i++) {
  525. if (id == this.prescriptions[i].id) {
  526. if (this.prescriptions[i].advices != null) {
  527. for (let a = 0; a < this.prescriptions[i].advices.length; a++) {
  528. total =
  529. total +
  530. this.prescriptions[i].advices[a].price *
  531. this.prescriptions[i].advices[a].prescribing_number;
  532. }
  533. }
  534. if (this.prescriptions[i].additionalcharge != null) {
  535. for (
  536. let a = 0;
  537. a < this.prescriptions[i].additionalcharge.length;
  538. a++
  539. ) {
  540. addtotal =
  541. addtotal +
  542. this.prescriptions[i].additionalcharge[a].price *
  543. this.prescriptions[i].additionalcharge[a].count;
  544. }
  545. }
  546. addtotal = Math.floor(addtotal * 100) / 100;
  547. }
  548. }
  549. return total + addtotal;
  550. },
  551. getInitData() {
  552. getInitData().then((response) => {
  553. if (response.data.state == 1) {
  554. this.department = response.data.data.department;
  555. this.diagnoses = response.data.data.diagnose.sort(this.compare("id"));
  556. console.log("争端", this.diagnoses);
  557. }
  558. });
  559. },
  560. getDiagnosis(ids) {
  561. let newIds = ids.split(",").sort(function (a, b) {
  562. return a - b;
  563. });
  564. var name = "";
  565. let nameArr = [];
  566. for (let i = 0; i < this.diagnoses.length; i++) {
  567. // if(id == this.diagnoses[i].id){
  568. // name = this.diagnoses[i].class_name
  569. // }
  570. if (newIds.indexOf(this.diagnoses[i].id.toString()) > -1) {
  571. // name += diagnoses[i].class_name + ' '
  572. nameArr.push(this.diagnoses[i].class_name);
  573. }
  574. }
  575. let newNameArr = [];
  576. nameArr.map((item, index) => {
  577. if (item == "尿毒症") {
  578. newNameArr.push(item);
  579. nameArr.splice(index, 1, "");
  580. }
  581. });
  582. newNameArr.push(...nameArr);
  583. return newNameArr.join(" ");
  584. },
  585. compare(property) {
  586. return function (a, b) {
  587. var value1 = a[property];
  588. var value2 = b[property];
  589. return value1 - value2; //升序排序
  590. };
  591. },
  592. getName(list) {
  593. console.log("list22", list);
  594. let new_list = [];
  595. for (let i = 0; i < list.length; i++) {
  596. if (list[i].aac031 == "1") {
  597. new_list.push(list[i]);
  598. }
  599. }
  600. switch (new_list[0].bcc334) {
  601. case "A31001":
  602. return "深圳医保1档";
  603. break;
  604. case "A31002":
  605. return "深圳医保2档";
  606. break;
  607. case "A31003":
  608. return "深圳医保3档";
  609. break;
  610. case "A31004":
  611. return "二档(少儿)";
  612. break;
  613. case "A31005":
  614. return "学生二档";
  615. break;
  616. case "A31006":
  617. return "大学生二档";
  618. break;
  619. case "A32001":
  620. return "在职公务员";
  621. break;
  622. case "A32002":
  623. return "在职驻深公务员";
  624. break;
  625. case "A39301":
  626. return "家属统筹医疗";
  627. break;
  628. case "A41001":
  629. return "工伤在职";
  630. break;
  631. case "A51001":
  632. return "生育在职";
  633. break;
  634. case "A52001":
  635. return "生育医疗一档";
  636. break;
  637. case "A52002":
  638. return "生育医疗一档";
  639. break;
  640. case "C31001":
  641. return "一档医疗退休";
  642. break;
  643. case "C31002":
  644. return "二档医疗退休";
  645. break;
  646. }
  647. },
  648. },
  649. created() {
  650. this.getInitData();
  651. this.getAllDoctorList();
  652. this.getPrescriptionPrint();
  653. var xtuser = this.$store.getters.xt_user;
  654. this.orgname = xtuser.org.org_name;
  655. this.org_id = this.$store.getters.xt_user.org.id;
  656. },
  657. watch: {
  658. patient_id: function (val) {
  659. console.log(
  660. "101000010101010",
  661. this.patient_id,
  662. this.record_date,
  663. this.prescription_id
  664. );
  665. // this.getPrescriptionPrint()
  666. },
  667. ids: function (val) {
  668. this.ids = val;
  669. console.log("this.idsids", this.ids);
  670. this.getPrescriptionPrint();
  671. },
  672. },
  673. };
  674. </script>
  675. <style lang="scss" scoped>
  676. .prescription-print {
  677. -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27),
  678. 0 0 60px rgba(0, 0, 0, 0.06) inset;
  679. -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27),
  680. 0 0 40px rgba(0, 0, 0, 0.06) inset;
  681. box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
  682. margin-bottom: 20px;
  683. padding: 20px 10px;
  684. }
  685. .printTitle {
  686. font-size: 22px;
  687. text-align: center;
  688. font-weight: bold;
  689. margin-bottom: 10px;
  690. }
  691. .infoTitle {
  692. display: flex;
  693. margin-top: 10px;
  694. line-height: 24px;
  695. }
  696. .infoTitle div {
  697. width: 200px;
  698. }
  699. .infoMain {
  700. display: flex;
  701. flex-wrap: wrap;
  702. margin-top: 10px;
  703. }
  704. .infoMain div {
  705. width: 50%;
  706. line-height: 24px;
  707. }
  708. .prescriptionBox {
  709. padding: 0 10px;
  710. min-height: 400px;
  711. }
  712. .Rp {
  713. font-size: 22px;
  714. font-weight: bold;
  715. }
  716. .drugsBox {
  717. padding-left: 40px;
  718. margin-bottom: 10px;
  719. }
  720. .drugsBox div {
  721. line-height: 20px;
  722. }
  723. .drugsOne {
  724. line-height: 24px;
  725. }
  726. .drugsOne span {
  727. margin-right: 20px;
  728. }
  729. .doctorBox {
  730. display: flex;
  731. justify-content: space-between;
  732. padding: 0 10px;
  733. line-height: 24px;
  734. border-bottom: 2px solid #000;
  735. }
  736. .actionBar {
  737. display: flex;
  738. justify-content: space-between;
  739. line-height: 24px;
  740. padding: 0 10px;
  741. }
  742. .actionBar p {
  743. width: 150px;
  744. }
  745. .under_line {
  746. display: inline-block;
  747. border-bottom: 1px solid #000;
  748. flex: 1;
  749. }
  750. </style>