eight
2024-11-20 9454d9561364971e1e56cfbc2ee6d79e84298339
打印
已修改1个文件
9 ■■■■■ 文件已修改
src/views/ecg/doctor/components/DevReadyPanel.vue 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
src/views/ecg/doctor/components/DevReadyPanel.vue
@@ -364,18 +364,19 @@
// 下列方法都是没有拖拽设计页面的, 相当于代码模式, 使用代码设计页面
// 想要实现拖拽设计页面,请往下看 '自定义设计'
  var hiprintTemplate = new hiprint.PrintTemplate();  // 可传参数
  var panel = hiprintTemplate.addPrintPanel({ width: 100, height: 130, paperFooter: 340, paperHeader: 10 });
  //var panel = hiprintTemplate.addPrintPanel({ width: 100, height: 130, paperFooter: 340, paperHeader: 10 }); 导致走三页
  var panel = hiprintTemplate.addPrintPanel({ width: 140, height: 130});
//文本
  const checkTypeName = checkTypeStore.getCheckTypeName(curAppointment.bookCheckType)
  panel.addPrintText({ options: { width: 140, height: 12, top: 2, left: 20, title: checkTypeName, textAlign: 'center', fontSize: 8, fontFamily: '微软雅黑',  fontWeight: 700, } });
  panel.addPrintText({ options: { width: 140, height: 12, top: 2, left: 20, title: checkTypeName, textAlign: 'center', fontSize: 8, fontFamily: '微软雅黑',  fontWeight: '700', } });
  const patientBaisc = curAppointment.patName + "  " + calGender(curAppointment.patGender) + "  " + calculateAge(curAppointment.patBirthday) + "岁"
  panel.addPrintText({ options: { width: 140, height: 12, top: 16, left: 20, title: patientBaisc, textAlign: 'center' , fontSize: 8, fontWeight: 700, } });
  panel.addPrintText({ options: { width: 140, height: 12, top: 16, left: 20, title: patientBaisc, textAlign: 'center' , fontSize: 8, fontWeight: '700', } });
  const ward_bed = curAppointment.patWardDesc + "-" + curAppointment.patBedNo
  panel.addPrintText({ options: { width: 140, height: 12, top: 30, left: 20, title: ward_bed, textAlign: 'center', fontSize: 8, fontFamily: '黑体', } });
  const bookTime = formatTimestamp(curAppointment.bookDate) + " " + getBookBeginTime(curAppointment.bookTimeslot)
  panel.addPrintText({ options: { width: 140, height: 12, top: 44, left: 20, title: bookTime, textAlign: 'center', fontSize: 8 } });
  panel.addPrintText({ options: { width: 140, height: 12, top: 58, left: 20, title: curAppointment.patId, textAlign: 'center', fontSize: 8 } });
  panel.addPrintText({ options: { width: 140, height: 12, top: 72, left: 20, title: curAppointment.patMobile, textAlign: 'center', fontSize: 8, fontFamily: '微软雅黑',  fontWeight: 700, } });
  panel.addPrintText({ options: { width: 140, height: 12, top: 72, left: 20, title: curAppointment.patMobile, textAlign: 'center', fontSize: 8, fontFamily: '微软雅黑',  fontWeight: '700', } });
//条形码
  panel.addPrintText({ options: { width: 140, height: 22, top: 86, left: 20, title: curAppointment.patId, textType: 'barcode' } });