Elizabeth's proactive approach involves introducing urinal toilet attachment , an ingenious concept that optimizes space and functionality.

prinSeven.vue 25KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743
  1. <template>
  2. <div id="prescriptionPrint">
  3. <div v-for="(item, index) in advicePrint" :key="index">
  4. <div
  5. id="prescription-print"
  6. class="prescription-print"
  7. style="page-break-after: always;"
  8. >
  9. <!-- <div class="printTitle" v-if="prescriptions[index].med_type == '1111'">
  10. {{ orgname }}第一类精神处方笺
  11. </div>
  12. <div class="printTitle" v-if="prescriptions[index].med_type == '1112'">
  13. {{ orgname }}第二类精神处方笺
  14. </div> -->
  15. <div
  16. class="printTitle"
  17. v-if="
  18. prescriptions[index].med_type != '1111' &&
  19. prescriptions[index].med_type != '1112'
  20. "
  21. >
  22. {{ orgname }}处方笺
  23. </div>
  24. <div >
  25. <div class="infoTitle">
  26. <p>姓名:{{ item.patient.name ? item.patient.name : "" }}</p>
  27. <p>
  28. 性别:
  29. <span v-if="item.patient.gender == 1">男</span>
  30. <span v-if="item.patient.gender == 2">女</span>
  31. </p>
  32. <p>年龄:{{ getAge(item.patient) ? getAge(item.patient) : "" }}岁</p>
  33. </div>
  34. <div class="infoMain">
  35. <div style="margin-bottom: 10px">
  36. 门诊号:{{ hisPatient.number ? hisPatient.number : "" }}
  37. </div>
  38. <div style="margin-bottom: 10px">
  39. 科室:{{ item.info ? getDepart(item.info.departments) : "" }}
  40. </div>
  41. <div style="margin-bottom: 10px">
  42. <!-- 医保卡号:{{ item.hisPatient.number ? item.hisPatient.number : "" }} -->
  43. 费别:居民医保/职工医保/自费
  44. </div>
  45. <div style="margin-bottom: 10px" v-if="org_id != 10188">
  46. <!-- 电话:{{ item.patient.phone }} -->
  47. 开方日期:{{ getTime(item.ctime) ? getTime(item.ctime) : "" }}
  48. </div>
  49. <div style="margin-bottom: 10px" v-else>
  50. 日期:{{ getTime(item.ctime) ? getTime(item.ctime) : "" }}
  51. </div>
  52. <div>地址:{{ item.patient.home_address }}</div>
  53. <div style="display: flex; width: 50%">
  54. 临床诊断:{{ getDiagnosis(item.info.diagnosis) }}
  55. </div>
  56. </div>
  57. </div>
  58. <div class="prescriptionBox" >
  59. <div class="Rp">Rp:</div>
  60. <div
  61. class="drugsBox"
  62. v-for="(it, index) in item.advices" :key="index"
  63. :style="{'page-break-after':index==yi&&item.advices.length>5? 'always':'auto'}"
  64. >
  65. <!-- class="drugsBox" item.advices.length>=5 ? 'danzhang' : 'drugsBox' :style="{'page-break-after':index==yi&&item.advices.length>3? 'always':'auto'}"-->
  66. <!-- <div class="drugsOne"><span style="font-weight:bold;">{{ index+1 + '.' }}</span>{{it.advice_name?it.advice_name:""}}&nbsp;&nbsp;{{it.single_dose}}{{it.single_dose_unit}}&nbsp;×&nbsp; {{it.prescribing_number}}{{it.prescribing_number_unit}}</div> -->
  67. <template v-if="index==yi+1&&item.advices.length>5">
  68. <div style="margin: 20px 0px;">
  69. <div class="infoTitle">
  70. <p>姓名:{{ item.patient.name ? item.patient.name : "" }}</p>
  71. <p>
  72. 性别:
  73. <span v-if="item.patient.gender == 1">男</span>
  74. <span v-if="item.patient.gender == 2">女</span>
  75. </p>
  76. <p>年龄:{{ getAge(item.patient) ? getAge(item.patient) : "" }}岁</p>
  77. </div>
  78. <div class="infoMain">
  79. <div style="margin-bottom: 10px">
  80. 门诊号:{{ hisPatient.number ? hisPatient.number : "" }}
  81. </div>
  82. <div style="margin-bottom: 10px">
  83. 科室:{{ item.info ? getDepart(item.info.departments) : "" }}
  84. </div>
  85. <div style="margin-bottom: 10px">
  86. <!-- 医保卡号:{{ item.hisPatient.number ? item.hisPatient.number : "" }} -->
  87. 费别:居民医保/职工医保/自费
  88. </div>
  89. <div style="margin-bottom: 10px" v-if="org_id != 10188">
  90. <!-- 电话:{{ item.patient.phone }} -->
  91. 开方日期:{{ getTime(item.ctime) ? getTime(item.ctime) : "" }}
  92. </div>
  93. <div style="margin-bottom: 10px" v-else>
  94. 日期:{{ getTime(item.ctime) ? getTime(item.ctime) : "" }}
  95. </div>
  96. <div>地址:{{ item.patient.home_address }}</div>
  97. <div style="display: flex; width: 50%">
  98. 临床诊断:{{ getDiagnosis(item.info.diagnosis) }}
  99. </div>
  100. </div>
  101. </div>
  102. </template>
  103. <div style="position: relative;">
  104. <div class="drugsOne" :style="{'border-right':item.arr.length>0 && item.arr[0][0].groupno==it.groupno ? '1px solid black': 'none','width':'80%'}">
  105. <span style="font-weight: bold" >
  106. {{ index + 1 + "." }}
  107. </span>
  108. {{ it.advice_name ? it.advice_name : "" }}&nbsp;&nbsp;
  109. <span v-if="it.drug.min_unit != it.drug.dose_unit">
  110. {{ it.drug.dose }}{{ it.drug.dose_unit }}&nbsp;* {{ it.drug.min_number }}{{ it.drug.min_unit }}/
  111. {{it.drug.max_unit}}
  112. </span>&nbsp;
  113. <div>
  114. <template v-if="item.arr.length>0 && item.arr[0][0].groupno==it.groupno">
  115. <div >
  116. <!-- -->
  117. <span style="margin-left: 38px;">{{item.arr[0][0].advice_name ? item.arr[0][0].advice_name : ""}}</span>&nbsp;&nbsp;
  118. <span v-if="item.arr[0][0].drug.min_unit != item.arr[0][0].drug.dose_unit">
  119. {{ item.arr[0][0].drug.dose }}{{ item.arr[0][0].drug.dose_unit }}&nbsp;* {{ item.arr[0][0].drug.min_number }}{{ item.arr[0][0].drug.min_unit }}/
  120. {{item.arr[0][0].drug.max_unit}}
  121. </span>&nbsp;
  122. </div>
  123. <div style="display: inline-block;position: absolute;left:85%;top:20px;margin-left: 10px;" >
  124. &nbsp;共{{ item.arr[0][0].single_dose }}{{ item.arr[0][0].single_dose_unit }}
  125. </div>
  126. </template>
  127. </div>
  128. <div style="margin-left: 70px">
  129. 用法:
  130. <span v-if="(item.arr.length>0 && item.arr[0][0].groupno!=it.groupno)||arr.length<0">{{ it.single_dose }}{{ it.single_dose_unit }}</span
  131. >&nbsp;&nbsp;<span
  132. >{{ it.execution_frequency }}&nbsp;{{
  133. it.delivery_way
  134. }}&nbsp;</span>&nbsp;&nbsp;<span>{{ it.advice_desc }}</span>
  135. </div>
  136. <!-- v-if="arr.length>0 && arr[0][0].groupno==it.groupno" 'border-right':arr.length>0 && arr[0][0].groupno==it.groupno ? '1px solid black' :'none',-->
  137. </div>
  138. <div style="display: inline-block;position: absolute;left:80%;bottom:0px;margin-left: 10px;" v-if="item.arr.length>0 && item.arr[0][0].groupno==it.groupno">
  139. ×&nbsp;{{ it.prescribing_number}}
  140. </div>
  141. <div style="display: inline-block;position: absolute;left:85%;top:0px;margin-left: 10px;" v-if="item.arr.length>0 && item.arr[0][0].groupno==it.groupno">
  142. <!-- &nbsp;共{{ it.prescribing_number}}{{ it.prescribing_number_unit }} -->
  143. &nbsp;共{{ it.single_dose }}{{ it.single_dose_unit }}
  144. </div>
  145. </div>
  146. <template v-if="index==yi&&item.advices.length>5">
  147. <div style="margin: 20px 0px;">
  148. <div style="border-bottom: 2px solid #000; width: 100%;margin-right: 30px;padding: 0 10px;line-height: 24px;" >
  149. <p style="text-align: right;">医师:{{ item.doctor ? item.doctor : "" }}</p>
  150. </div>
  151. <div class="actionBar" >
  152. <!-- <p>审核:{{getDoctor(item.advices[0].checker)?getDoctor(item.advices[0].checker):""}}</p>
  153. <p>配对:</p>
  154. <p>核对:{{getDoctor(item.advices[0].checker)?getDoctor(item.advices[0].checker):""}}</p>
  155. <p>发药:{{getDoctor(item.advices[0].execution_staff)?getDoctor(item.advices[0].execution_staff):""}}</p>
  156. <p>药费:{{getTotalOne(item.id)?getTotalOne(item.id):0}}元</p> -->
  157. <p>审核:</p>
  158. <p>配对:</p>
  159. <p>核对:</p>
  160. <p>发药:</p>
  161. <p>
  162. 金额:{{
  163. getTotalOne(item.id).toFixed(2)
  164. ? getTotalOne(item.id).toFixed(2)
  165. : 0
  166. }}元
  167. </p>
  168. </div>
  169. <div class="actionBar" style="margin-bottom: 10px;">
  170. <p style="width:300px;">大额处方患者意见:
  171. <el-radio v-model="radio" label="1">同意</el-radio>
  172. <el-radio v-model="radio" label="2">不同意</el-radio>
  173. </p>
  174. <p>收费员:</p>
  175. </div>
  176. <div style="padding: 0px 10px;">
  177. <p >患者签名:</p>
  178. </div>
  179. </div>
  180. </template>
  181. </div>
  182. <div
  183. class="drugsBox"
  184. v-for="(it, i) in item.additionalcharge"
  185. :key="i"
  186. >
  187. <div class="drugsOne">
  188. {{ it.item_name ? it.item_name : "" }}:&nbsp;{{ it.price }}元/{{
  189. it.count
  190. }}次
  191. </div>
  192. </div>
  193. <div
  194. class="drugsBox"
  195. v-for="(it, index) in item.project"
  196. :key="index"
  197. >
  198. <div class="drugsOne">
  199. <span style="font-weight: bold">{{ index + 1 + "." }}</span
  200. >{{
  201. it.type == 2
  202. ? getProjectName(it.project_id)
  203. ? getProjectName(it.project_id)
  204. : ""
  205. : it.good_info.good_name
  206. }}&nbsp;&nbsp;{{ it.single_dose
  207. }}{{ it.single_dose_unit }}&nbsp;×&nbsp; {{ it.count }}{{ unit }}
  208. </div>
  209. <div style="margin-left: 100px">
  210. <span>用法:{{ it.single_dose }}{{ it.single_dose_unit }}</span
  211. >&nbsp;&nbsp;<span>{{ it.delivery_way }}</span
  212. >&nbsp;&nbsp;<span>{{ it.advice_desc }}</span>
  213. </div>
  214. </div>
  215. <div
  216. class="drugsBox"
  217. v-for="(it, i) in item.additionalcharge"
  218. :key="i"
  219. >
  220. <div class="drugsOne">
  221. {{ it.project_id ? it.project_id : "" }}:&nbsp;{{
  222. it.price.toFixed(2)
  223. }}元/{{ it.count }}次
  224. </div>
  225. </div>
  226. <div style="text-align: center">(以下空白)</div>
  227. </div>
  228. <!-- <div class="doctorBox" v-if="org_id != 10188 && org_id != 0">
  229. <p v-if="org_id == 10217 || org_id == 0">
  230. 医师:
  231. <span
  232. style="width: 100px; display: inline-block"
  233. v-if="item.creator == ''"
  234. >
  235. {{ item.doctor }}
  236. </span>
  237. <span
  238. style="width: 100px; display: inline-block"
  239. v-else-if="doc_name != ''"
  240. >
  241. {{ doc_name }}
  242. </span>
  243. <img
  244. style="height: 50px;"
  245. :src="setAdminUserES(item.creator,item.doctor)"
  246. alt=""
  247. srcset=""
  248. />
  249. </p>
  250. <p v-else>
  251. 医师: {{ item.doctor ? item.doctor : "" }}
  252. </p>
  253. <p>日期:{{ getTime(item.ctime) ? getTime(item.ctime) : "" }}</p>
  254. </div> -->
  255. <div style="border-bottom: 2px solid #000; width: 100%;margin-right: 30px;padding: 0 10px;line-height: 24px;" >
  256. <p style="text-align: right;">医师:{{ item.doctor ? item.doctor : "" }}</p>
  257. </div>
  258. <div class="actionBar" >
  259. <!-- <p>审核:{{getDoctor(item.advices[0].checker)?getDoctor(item.advices[0].checker):""}}</p>
  260. <p>配对:</p>
  261. <p>核对:{{getDoctor(item.advices[0].checker)?getDoctor(item.advices[0].checker):""}}</p>
  262. <p>发药:{{getDoctor(item.advices[0].execution_staff)?getDoctor(item.advices[0].execution_staff):""}}</p>
  263. <p>药费:{{getTotalOne(item.id)?getTotalOne(item.id):0}}元</p> -->
  264. <p>审核:</p>
  265. <p>配对:</p>
  266. <p>核对:</p>
  267. <p>发药:</p>
  268. <p>
  269. 金额:{{
  270. getTotalOne(item.id).toFixed(2)
  271. ? getTotalOne(item.id).toFixed(2)
  272. : 0
  273. }}元
  274. </p>
  275. </div>
  276. <div class="actionBar" style="margin-bottom: 10px;">
  277. <p style="width:300px;">大额处方患者意见:
  278. <el-radio v-model="radio" label="1">同意</el-radio>
  279. <el-radio v-model="radio" label="2">不同意</el-radio>
  280. </p>
  281. <p>收费员:</p>
  282. </div>
  283. <div style="padding: 0px 10px;">
  284. <p >患者签名:</p>
  285. </div>
  286. <!-- <div class="actionBar" v-else>
  287. <p >审核、调配:</p>
  288. <p >核对、发药:</p>
  289. <p >
  290. 药费:{{
  291. getTotalOne(item.id).toFixed(2)
  292. ? getTotalOne(item.id).toFixed(2)
  293. : 0
  294. }}元
  295. </p>
  296. </div> -->
  297. <!-- </div> -->
  298. </div>
  299. </div>
  300. </div>
  301. </template>
  302. <script>
  303. import { jsGetAge, uParseTime } from "@/utils/tools";
  304. import {
  305. getAllDoctorList,
  306. getPrescriptionPrint,
  307. getHisPatientDetail,
  308. } from "@/api/project/project";
  309. import { getInitData } from "@/api/his/his";
  310. export default{
  311. props: {
  312. patient_id: Number,
  313. record_date: String,
  314. prescription_id: Number,
  315. ids: String,
  316. },
  317. data() {
  318. return {
  319. doc_name:"",
  320. doctorList: [],
  321. advicePrint: {},
  322. yi:4,
  323. radio:'',
  324. arr:[],
  325. advicess:[],
  326. page:sessionStorage.getItem('dayin'),
  327. patient: {},
  328. tableData: [],
  329. prescriptionInfo: [],
  330. hisPatient: {},
  331. department: [],
  332. prescriptions: [],
  333. projectList: [],
  334. orgname: "",
  335. diagnoses: [],
  336. org_id: 0,
  337. operatorMaps: {},
  338. operators: [],
  339. doctorList_1: [],
  340. };
  341. },
  342. methods: {
  343. // 电子签名
  344. setAdminUserES(id,name) {
  345. console.log(id)
  346. console.log(name)
  347. console.log(this.operatorMaps)
  348. if (id == 0) {
  349. return "";
  350. }
  351. if (id in this.operatorMaps) {
  352. return this.operatorMaps[id].url;
  353. } else {
  354. this.doc_name = name
  355. return "";
  356. }
  357. },
  358. getAge(patient) {
  359. if(patient.id_card_no == "TWN001836483"){
  360. return patient.age
  361. }else{
  362. var thisLen = patient.id_card_no.length;
  363. var birth = "";
  364. if (thisLen == 15) {
  365. birth = "19" + patient.id_card_no.substr(6, 6);
  366. } else {
  367. birth = patient.id_card_no.substr(6, 8);
  368. }
  369. var births =
  370. birth.substr(0, 4) +
  371. "-" +
  372. birth.substr(4, 2) +
  373. "-" +
  374. birth.substr(6, 2);
  375. return jsGetAge(births, "-");
  376. }
  377. },
  378. getAllDoctorList() {
  379. getAllDoctorList().then((response) => {
  380. if (response.data.state == 1) {
  381. var doctor = response.data.data.doctor;
  382. this.doctorList = doctor;
  383. }
  384. });
  385. },
  386. getDoctor(id) {
  387. var name = "";
  388. for (let i = 0; i < this.doctorList.length; i++) {
  389. if (id == this.doctorList[i].admin_user_id) {
  390. name = this.doctorList[i].user_name;
  391. }
  392. }
  393. return name;
  394. },
  395. getTime(value, temp) {
  396. if (value != undefined) {
  397. return uParseTime(value, temp);
  398. }
  399. return "";
  400. },
  401. getPrescriptionPrint() {
  402. var params = {
  403. // patient_id:this.patient_id,
  404. // record_date:this.record_date,
  405. // prescription_id:this.prescription_id,
  406. patient_id: this.patient_id,
  407. record_date: this.record_date,
  408. prescription_id: this.prescription_id,
  409. ids: this.ids,
  410. p_type: 2,
  411. };
  412. console.log("params", params);
  413. getPrescriptionPrint(params).then((response) => {
  414. if (response.data.state == 1) {
  415. var advicePrint = response.data.data.advicePrint;
  416. console.log("adviceprint9999", advicePrint);
  417. this.advicePrint = advicePrint;
  418. this.prescriptions = advicePrint;
  419. this.doctorList_1 = response.data.data.eles;
  420. for(let i=0;i<this.advicePrint.length;i++){
  421. var arr = new Array()
  422. var advicess = new Array()
  423. var advicess=advicePrint[i].advices
  424. for(let j=0;j<advicess.length;j++){
  425. for(let x=j+1;x<advicess.length;x++){
  426. if(advicess[j].groupno == advicess[x].groupno){
  427. arr.push(advicess.splice(x,1))
  428. }
  429. }
  430. }
  431. this.advicePrint[i]["arr"] = arr
  432. // for(let y=0;y<this.advicePrint[i].arr.length;y++){
  433. // console.log('6666666',this.advicePrint[i].arr[y]);
  434. // }
  435. }
  436. console.log('4444444',this.advicePrint);
  437. // console.log('55555555',this.arr);
  438. console.log(this.doctorList_1, "医生列表");
  439. if (this.doctorList_1.length > 0) {
  440. var operatorsLen = this.doctorList_1.length;
  441. for (var index = 0; index < operatorsLen; index++) {
  442. this.$set(
  443. this.operatorMaps,
  444. this.doctorList_1[index].creator,
  445. this.doctorList_1[index]
  446. );
  447. }
  448. }
  449. console.log("处方222222", this.prescriptions);
  450. var hisPatient = response.data.data.hisPatient;
  451. console.log("hisPatient", hisPatient);
  452. this.hisPatient = hisPatient;
  453. var projectlist = response.data.data.projectlist;
  454. console.log("所有项目列表", projectlist);
  455. this.projectList = projectlist;
  456. }
  457. });
  458. },
  459. getHisPatientDetail() {
  460. const params = {
  461. patient_id: this.patient_id,
  462. };
  463. getHisPatientDetail(params).then((response) => {
  464. if (response.data.state == 1) {
  465. var hisPatient = response.data.data.hisPatient;
  466. console.log("挂号病人", hisPatient);
  467. this.hisPatient = hisPatient;
  468. }
  469. });
  470. },
  471. getInitData() {
  472. getInitData().then((response) => {
  473. if (response.data.state == 1) {
  474. this.department = response.data.data.department;
  475. this.diagnoses = response.data.data.diagnose;
  476. console.log("争端", this.diagnoses);
  477. }
  478. });
  479. },
  480. getDepart(id) {
  481. var name = "";
  482. for (let i = 0; i < this.department.length; i++) {
  483. if (id == this.department[i].id) {
  484. name = this.department[i].name;
  485. }
  486. }
  487. return name;
  488. },
  489. getTotalOne(id) {
  490. var total = 0;
  491. var addtotal = 0;
  492. for (let i = 0; i < this.prescriptions.length; i++) {
  493. if (id == this.prescriptions[i].id) {
  494. if (this.prescriptions[i].project != null) {
  495. for (let a = 0; a < this.prescriptions[i].project.length; a++) {
  496. total =
  497. total +
  498. this.prescriptions[i].project[a].price *
  499. this.prescriptions[i].project[a].count;
  500. }
  501. }
  502. if (this.prescriptions[i].additionalcharge != null) {
  503. for (
  504. let a = 0;
  505. a < this.prescriptions[i].additionalcharge.length;
  506. a++
  507. ) {
  508. addtotal =
  509. addtotal +
  510. this.prescriptions[i].additionalcharge[a].price *
  511. this.prescriptions[i].additionalcharge[a].count;
  512. }
  513. }
  514. addtotal = Math.floor(addtotal * 100) / 100;
  515. }
  516. }
  517. for (let i = 0; i < this.prescriptions.length; i++) {
  518. if (id == this.prescriptions[i].id) {
  519. if (this.prescriptions[i].advices != null) {
  520. for (let a = 0; a < this.prescriptions[i].advices.length; a++) {
  521. total =
  522. total +
  523. this.prescriptions[i].advices[a].price *
  524. this.prescriptions[i].advices[a].prescribing_number;
  525. }
  526. }
  527. if (this.prescriptions[i].additionalcharge != null) {
  528. for (
  529. let a = 0;
  530. a < this.prescriptions[i].additionalcharge.length;
  531. a++
  532. ) {
  533. addtotal =
  534. addtotal +
  535. this.prescriptions[i].additionalcharge[a].price *
  536. this.prescriptions[i].additionalcharge[a].count;
  537. }
  538. }
  539. addtotal = Math.floor(addtotal * 100) / 100;
  540. }
  541. }
  542. return total + addtotal;
  543. },
  544. getProjectName(id) {
  545. var project_name = "";
  546. for (let i = 0; i < this.projectList.length; i++) {
  547. if (id == this.projectList[i].id) {
  548. project_name = this.projectList[i].project_name;
  549. }
  550. }
  551. return project_name;
  552. },
  553. getDiagnosis(id) {
  554. let arr = id.split(",");
  555. var name = "";
  556. for (let i = 0; i < this.diagnoses.length; i++) {
  557. if (arr.indexOf(String(this.diagnoses[i].id)) > -1) {
  558. name += this.diagnoses[i].class_name + " ";
  559. }
  560. }
  561. return name;
  562. },
  563. merge(arrA){
  564. var len=arrA.lenfth
  565. // for(let j=0;j<this.advicess.length;j++){
  566. // for(let x=j+1;x<this.advicess.length;x++){
  567. // if(this.advicess[j].groupno == this.advicess[x].groupno){
  568. // // this.arr.push(this.advicess.splice(x,1))
  569. // this.arrs=this.advicess.splice(x,1)
  570. // }
  571. // }
  572. // }
  573. for(let j=0;j<len;j++){
  574. for(let x=j+1;x<len;x++){
  575. if(arrA[j].groupno == arrA[x].groupno){
  576. this.arr.push(arrA.splice(x,1))
  577. }
  578. }
  579. }
  580. console.log('777777777',this.arr);
  581. return this.arr
  582. }
  583. },
  584. created() {
  585. this.getAllDoctorList();
  586. this.getInitData();
  587. this.getPrescriptionPrint();
  588. this.getHisPatientDetail();
  589. var xtuser = this.$store.getters.xt_user;
  590. this.orgname = xtuser.org.org_name;
  591. this.org_id = xtuser.org.id;
  592. // for(let j=0;j<this.advicess.length;j++){
  593. // console.log('44444444');
  594. // for(let x=j+1;x<this.advicess.length;x++){
  595. // if(this.advicess[j].groupno == this.advicess[x].groupno){
  596. // this.arr.push(this.advicess.splice(x,1))
  597. // }
  598. // }
  599. // }
  600. // console.log('777777777',this.arr[0].advice_name);
  601. // return this.arr
  602. },
  603. watch: {
  604. ids: function (val) {
  605. this.ids = val;
  606. this.getPrescriptionPrint();
  607. },
  608. },
  609. };
  610. </script>
  611. <style lang="scss" scoped>
  612. .prescription-print {
  613. -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27),
  614. 0 0 60px rgba(0, 0, 0, 0.06) inset;
  615. -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27),
  616. 0 0 40px rgba(0, 0, 0, 0.06) inset;
  617. box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
  618. margin-bottom: 20px;
  619. padding: 20px 10px;
  620. }
  621. .printTitle {
  622. font-size: 22px;
  623. text-align: center;
  624. font-weight: bold;
  625. }
  626. .infoTitle {
  627. display: flex;
  628. border-top: 2px solid #000;
  629. margin-top: 10px;
  630. line-height: 24px;
  631. padding: 0 10px;
  632. }
  633. .infoTitle p {
  634. width: 200px;
  635. }
  636. .infoMain {
  637. display: flex;
  638. flex-wrap: wrap;
  639. border-bottom: 2px solid #000;
  640. padding: 0 10px;
  641. }
  642. .infoMain div {
  643. width: 50%;
  644. line-height: 24px;
  645. }
  646. .prescriptionBox {
  647. padding: 0 10px;
  648. min-height: 450px;
  649. }
  650. .Rp {
  651. font-size: 22px;
  652. font-weight: bold;
  653. }
  654. .drugsBox {
  655. padding-left: 40px;
  656. margin-bottom: 10px;
  657. position: relative;
  658. }
  659. .drugsBox div {
  660. line-height: 20px;
  661. }
  662. .drugsOne {
  663. line-height: 24px;
  664. display: inline-block;
  665. width: 80%;
  666. }
  667. .drugsOne span {
  668. margin-right: 20px;
  669. }
  670. .doctorBox {
  671. display: flex;
  672. justify-content: space-between;
  673. padding: 0 10px;
  674. line-height: 24px;
  675. border-bottom: 2px solid #000;
  676. }
  677. .doctorBoxs{
  678. width: 100%;
  679. margin-right: 30px;
  680. text-align: right;
  681. padding: 0 10px;
  682. line-height: 24px;
  683. }
  684. .doctorBoxtwo {
  685. display: flex;
  686. justify-content: space-between;
  687. padding: 0 10px;
  688. line-height: 24px;
  689. }
  690. .actionBar {
  691. display: flex;
  692. justify-content: space-between;
  693. line-height: 24px;
  694. padding: 0 10px;
  695. }
  696. .actionBar p {
  697. width: 150px;
  698. }
  699. </style>