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

printOne.vue 8.4KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267
  1. <template>
  2. <div id='prescriptionPrint'>
  3. <div v-for="(item,index) in advicePrint" :key="index">
  4. <div id='prescription-print' class="prescription-print" style="page-break-after: always;">
  5. <div class="printTitle">{{orgname}} &nbsp;&nbsp; 血液透析中心处方笺</div>
  6. <div class="infoTitle">
  7. <p>姓名:{{item.patient.name?item.patient.name:""}}</p>
  8. <p>性别:
  9. <span v-if="item.patient.gender == 1">男</span>
  10. <span v-if="item.patient.gender == 2">女</span>
  11. </p>
  12. <p>年龄:{{item.patient.age?item.patient.age:""}}岁</p>
  13. </div>
  14. <div class="infoMain">
  15. <div style="margin-bottom: 10px;">门诊号:{{item.hisPatient.number?item.hisPatient.number:""}}</div>
  16. <div style="margin-bottom: 10px;">科室:{{getDepart(item.hisPatient.departments?item.hisPatient.departments:"")}}</div>
  17. <div style="margin-bottom: 10px;">医保卡号:{{item.hisPatient.number?item.hisPatient.number:""}}</div>
  18. <div style="margin-bottom: 10px;">电话:{{item.patient.phone}}</div>
  19. <div>地址:{{item.patient.home_address}}</div>
  20. <div style="display:flex;width:50%;">临床诊断:{{item.patient.diagnose}}</div>
  21. </div>
  22. <div class="prescriptionBox">
  23. <div class="Rp">Rp:</div>
  24. <div class="drugsBox" v-for="(it,index) in item.advices" :key="index">
  25. <div class="drugsOne">{{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>
  26. <div style="margin-left:100px;"><span>用法:{{it.single_dose}}{{it.single_dose_unit}}</span>&nbsp;&nbsp;<span>{{it.execution_frequency}}</span>&nbsp;&nbsp;<span>{{it.advice_desc}}</span></div>
  27. </div>
  28. <div class="drugsBox" v-for="(it,i) in item.additionalcharge" :key="i">
  29. <div class="drugsOne">{{it.item_name?it.item_name:""}}:&nbsp;{{it.price}}元/{{it.count}}次</div>
  30. </div>
  31. </div>
  32. <div class="doctorBox">
  33. <p>医师:{{item.doctor?item.doctor:""}}</p>
  34. <p>日期:{{getTime(item.ctime)?getTime(item.ctime):""}}</p>
  35. </div>
  36. <div class="actionBar">
  37. <p>审核:{{getDoctor(item.advices[0].checker)?getDoctor(item.advices[0].checker):""}}</p>
  38. <p>配对:</p>
  39. <p>核对:{{getDoctor(item.advices[0].checker)?getDoctor(item.advices[0].checker):""}}</p>
  40. <p>发药:{{getDoctor(item.advices[0].execution_staff)?getDoctor(item.advices[0].execution_staff):""}}</p>
  41. <p>药费:{{getTotalOne(item.id)?getTotalOne(item.id):0}}元</p>
  42. </div>
  43. <div style="page-break-after:always"></div>
  44. </div>
  45. </div>
  46. </div>
  47. </template>
  48. <script>
  49. import { jsGetAge, uParseTime } from '@/utils/tools'
  50. import {getAllDoctorList,getPrescriptionPrint,getHisPatientDetail} from "@/api/project/project"
  51. import {getInitData} from "@/api/his/his"
  52. export default {
  53. props:{
  54. patient_id:Number,
  55. record_date:String,
  56. prescription_id:Number,
  57. ids:String
  58. },
  59. data(){
  60. return {
  61. doctorList:[],
  62. advicePrint:{},
  63. patient:{},
  64. tableData:[],
  65. prescriptionInfo:[],
  66. hisPatient:{},
  67. department:[],
  68. prescriptions:[],
  69. orgname:""
  70. }
  71. },
  72. methods:{
  73. getAllDoctorList(){
  74. getAllDoctorList().then(response=>{
  75. if(response.data.state == 1){
  76. var doctor = response.data.data.doctor
  77. this.doctorList = doctor
  78. }
  79. })
  80. },
  81. getDoctor(id){
  82. var name = ""
  83. for(let i=0;i<this.doctorList.length;i++){
  84. if(id == this.doctorList[i].admin_user_id){
  85. name = this.doctorList[i].user_name
  86. }
  87. }
  88. return name
  89. },
  90. getTime(value, temp) {
  91. if (value != undefined) {
  92. return uParseTime(value, temp)
  93. }
  94. return ''
  95. },
  96. getPrescriptionPrint(){
  97. var params = {
  98. // patient_id:this.patient_id,
  99. // record_date:this.record_date,
  100. // prescription_id:this.prescription_id,
  101. patient_id:this.patient_id,
  102. record_date:this.record_date,
  103. prescription_id:this.prescription_id,
  104. ids:this.ids
  105. }
  106. console.log("params",params)
  107. getPrescriptionPrint(params).then(response=>{
  108. if(response.data.state == 1){
  109. var advicePrint = response.data.data.advicePrint
  110. console.log("adviceprint9999",advicePrint)
  111. this.advicePrint = advicePrint
  112. this.prescriptions = advicePrint
  113. }
  114. })
  115. },
  116. getHisPatientDetail(){
  117. const params = {
  118. patient_id:this.patient_id
  119. }
  120. getHisPatientDetail(params).then(response=>{
  121. if(response.data.state == 1){
  122. var hisPatient = response.data.data.hisPatient
  123. console.log("挂号病人",hisPatient)
  124. this.hisPatient = hisPatient
  125. }
  126. })
  127. },
  128. getInitData(){
  129. getInitData().then(response=>{
  130. if(response.data.state == 1){
  131. this.department = response.data.data.department
  132. }
  133. })
  134. },
  135. getDepart(id){
  136. var name = ""
  137. for(let i=0;i<this.department.length;i++){
  138. if(id == this.department[i].id){
  139. name = this.department[i].name
  140. }
  141. }
  142. return name
  143. },
  144. getTotalOne(id) {
  145. var total = 0
  146. var addtotal = 0
  147. for (let i = 0; i < this.prescriptions.length; i++) {
  148. if(id == this.prescriptions[i].id){
  149. if (this.prescriptions[i].advices != null) {
  150. for (let a = 0; a < this.prescriptions[i].advices.length; a++) {
  151. total = total + this.prescriptions[i].advices[a].price * this.prescriptions[i].advices[a].prescribing_number
  152. }
  153. }
  154. if (this.prescriptions[i].additionalcharge != null) {
  155. for (let b = 0; b < this.prescriptions[i].additionalcharge.length; b++) {
  156. addtotal = addtotal + this.prescriptions[i].additionalcharge[b].price * this.prescriptions[i].additionalcharge[b].count
  157. }
  158. }
  159. addtotal = Math.floor(addtotal * 100) / 100
  160. }
  161. }
  162. return total + addtotal
  163. },
  164. },
  165. created(){
  166. this.getAllDoctorList()
  167. this.getInitData()
  168. this.getPrescriptionPrint()
  169. this.getHisPatientDetail()
  170. var xtuser = this.$store.getters.xt_user
  171. this.orgname = xtuser.org.org_name
  172. },
  173. // watch:{
  174. // patient_id:function(val){
  175. // console.log("101000010101010",this.patient_id,this.record_date,this.prescription_id)
  176. // this.getPrescriptionPrint()
  177. // this.getHisPatientDetail()
  178. // }
  179. // }
  180. }
  181. </script>
  182. <style lang="scss" scoped>
  183. .prescription-print{
  184. -webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 60px rgba(0, 0, 0, 0.06) inset;
  185. -moz-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
  186. box-shadow: 0 1px 4px rgba(0, 0, 0, 0.27), 0 0 40px rgba(0, 0, 0, 0.06) inset;
  187. margin-bottom: 20px;
  188. padding:20px 0px;
  189. }
  190. .printTitle{
  191. font-size: 22px;
  192. text-align: center;
  193. font-weight: bold;
  194. }
  195. .infoTitle{
  196. display: flex;
  197. border-bottom: 2px solid #000;
  198. margin-top:10px;
  199. line-height: 24px;
  200. padding:0 10px;
  201. }
  202. .infoTitle p{
  203. width: 200px;
  204. }
  205. .infoMain{
  206. display: flex;
  207. flex-wrap: wrap;
  208. border-bottom: 2px solid #000;
  209. padding:0 10px;
  210. }
  211. .infoMain div{
  212. width: 50%;
  213. line-height: 24px;
  214. }
  215. .prescriptionBox{
  216. padding:0 10px;
  217. min-height:450px;
  218. }
  219. .Rp{
  220. font-size: 22px;
  221. font-weight: bold;
  222. }
  223. .drugsBox{
  224. padding-left: 40px;
  225. margin-bottom: 10px;
  226. }
  227. .drugsBox div{
  228. line-height: 20px;
  229. }
  230. .drugsOne{
  231. line-height: 24px;
  232. }
  233. .drugsOne span{
  234. margin-right: 20px;
  235. }
  236. .doctorBox{
  237. display: flex;
  238. justify-content: space-between;
  239. padding:0 10px;
  240. line-height: 24px;
  241. border-bottom: 2px solid #000;
  242. }
  243. .actionBar{
  244. display: flex;
  245. justify-content: space-between;
  246. line-height: 24px;
  247. padding:0 10px;
  248. }
  249. .actionBar p{
  250. width:150px;
  251. }
  252. </style>