Browse Source

报表功能开发完成,增加微信自助和支付宝自助收款报表,发票连续功能开发完成。

hurugang 6 years ago
parent
commit
248d777f6d

+ 54 - 12
src/main/java/cn/hnthyy/thmz/controller/ChargeFeeVoController.java

@@ -371,6 +371,16 @@ public class ChargeFeeVoController {
             //挂号所用票号
             List<ReceiptBillVo> ghReceipts=chargeFeeVoService.queryGhReceiptBillVoUnAccount(tokenUser.getUserIdCode());
             sfReceipts.addAll(ghReceipts);
+            List<ReceiptBillVo> notFpList = new ArrayList<>();
+            sfReceipts.forEach(s->{
+                if(s.getReceiptBill()!=null && s.getReceiptBill().length()!=8){
+                    s.setReceiptBill(null);
+                }
+                if(s.getReceiptBill()==null || "00000000".equals(s.getReceiptBill())){
+                    notFpList.add(s);
+                }
+            });
+            sfReceipts.removeAll(notFpList);
             Collections.sort(sfReceipts); // 按发票号排序
             List<String> receiptBills = getStrings(sfReceipts);
             resultMap.put("receiptBills", receiptBills);
@@ -380,7 +390,7 @@ public class ChargeFeeVoController {
             Integer ghfps=chargeFeeVoService.countReqrecReceipt(tokenUser.getUserIdCode(), YesNoEnum.NO.code.toString(), null, null, null);
             Integer ghtpzs=chargeFeeVoService.countReqrecReceipt(tokenUser.getUserIdCode(), YesNoEnum.YES.code.toString(), null, null, null);
             //收费发票总数
-            resultMap.put("sffps",sffps+tpzs+zffps+ghfps+ghtpzs);
+            resultMap.put("sffps",sffps+tpzs+zffps+ghfps+ghtpzs-notFpList.size());
             //退费发票张数
             resultMap.put("tpzs", tpzs+ghtpzs);
             //作废收费发票张数
@@ -390,6 +400,16 @@ public class ChargeFeeVoController {
             //退号发票明细
             List<ReceiptVo> thzffpmx=chargeFeeVoService.queryThMzReceiptSerial(tokenUser.getUserIdCode(), null);
             sfzffpmx.addAll(thzffpmx);
+            List<ReceiptVo> notFpGhList = new ArrayList<>();
+            sfzffpmx.forEach(s->{
+                if(s.getReceiptBill()!=null && s.getReceiptBill().length()!=8){
+                    s.setReceiptBill(null);
+                }
+                if(s.getReceiptBill()==null || "00000000".equals(s.getReceiptBill())){
+                    notFpGhList.add(s);
+                }
+            });
+            sfzffpmx.removeAll(notFpGhList);
             Collections.sort(sfzffpmx); // 按发票号排序
             resultMap.put("zffpmx", sfzffpmx);
             resultMap.put("user", tokenUser);
@@ -434,6 +454,8 @@ public class ChargeFeeVoController {
                 resultMap.put("message", "查询重打费用日结报表失败,结算时间为空");
                 return resultMap;
             }
+            User tokenUser = userService.queryUserByUserIdCode(chargeFeeParamsVo.getOpId());
+            resultMap.put("user", tokenUser);
             //挂号收入构成表格数据
             ReqrecVo reqrecVo = chargeFeeVoService.queryMzReceiptSerialCount(chargeFeeParamsVo.getOpId(), chargeFeeParamsVo.getDcountDate(), null, null).get(0);
             reqrecVo.fomartReqrecVo();
@@ -449,6 +471,16 @@ public class ChargeFeeVoController {
             //挂号所用票号
             List<ReceiptBillVo> ghReceipts=chargeFeeVoService.queryGhReceiptBillVoReprint(chargeFeeParamsVo.getOpId(), chargeFeeParamsVo.getDcountDate());
             sfReceipts.addAll(ghReceipts);
+            List<ReceiptBillVo> notFpList = new ArrayList<>();
+            sfReceipts.forEach(s->{
+                if(s.getReceiptBill()!=null && s.getReceiptBill().length()!=8){
+                    s.setReceiptBill(null);
+                }
+                if(s.getReceiptBill()==null || "00000000".equals(s.getReceiptBill())){
+                    notFpList.add(s);
+                }
+            });
+            sfReceipts.removeAll(notFpList);
             Collections.sort(sfReceipts); // 按发票号排序
             List<String> receiptBills = getStrings(sfReceipts);
             resultMap.put("receiptBills", receiptBills);
@@ -463,7 +495,7 @@ public class ChargeFeeVoController {
             //退号发票张数
             Integer ghtpzs=chargeFeeVoService.countReqrecReceipt(chargeFeeParamsVo.getOpId(), YesNoEnum.YES.code.toString(), chargeFeeParamsVo.getDcountDate(), null, null);
             //收费发票总数
-            resultMap.put("sffps", sffps+tpzs+zffps+ghfps+ghtpzs);
+            resultMap.put("sffps", sffps+tpzs+zffps+ghfps+ghtpzs-notFpList.size());
             //退费发票张数
             resultMap.put("tpzs", tpzs+ghtpzs);
             //作废收费发票张数
@@ -473,10 +505,18 @@ public class ChargeFeeVoController {
             //退号发票明细
             List<ReceiptVo> thzffpmx= chargeFeeVoService.queryThMzReceiptSerial(chargeFeeParamsVo.getOpId(), chargeFeeParamsVo.getDcountDate());
             sfzffpmx.addAll(thzffpmx);
+            List<ReceiptVo> notFpGhList = new ArrayList<>();
+            sfzffpmx.forEach(s->{
+                if(s.getReceiptBill()!=null && s.getReceiptBill().length()!=8){
+                    s.setReceiptBill(null);
+                }
+                if(s.getReceiptBill()==null || "00000000".equals(s.getReceiptBill())){
+                    notFpGhList.add(s);
+                }
+            });
+            sfzffpmx.removeAll(notFpGhList);
             Collections.sort(sfzffpmx); // 按发票号排序
             resultMap.put("zffpmx", sfzffpmx);
-            User tokenUser = userService.queryUserByUserIdCode(chargeFeeParamsVo.getOpId());
-            resultMap.put("user", tokenUser);
             resultMap.put("code", 0);
             resultMap.put("message", "查询重打费用日结报表成功");
             return resultMap;
@@ -500,7 +540,7 @@ public class ChargeFeeVoController {
     public Map<String, Object> getFullChargeCollect(@RequestBody ChargeFeeParamsVo chargeFeeParamsVo, HttpServletRequest httpServletRequest) {
         Map<String, Object> resultMap = new HashMap<>();
         try {
-            User tokenUser = TokenUtil.getUser(httpServletRequest);
+           // User tokenUser = TokenUtil.getUser(httpServletRequest);
             if (chargeFeeParamsVo == null) {
                 resultMap.put("code", -1);
                 resultMap.put("message", "查询费用汇总报表失败,参数为空");
@@ -530,16 +570,18 @@ public class ChargeFeeVoController {
             List<WorkloadVo> sfWorkloadVos = chargeFeeVoService.querySfWorkloadVo(chargeFeeParamsVo.getHisData(), chargeFeeParamsVo.getBeginDate(), chargeFeeParamsVo.getEndDate());
             frmartWorkloadVo(sfWorkloadVos);
             resultMap.put("sfWorkloadVos", sfWorkloadVos);
-            resultMap.put("user", tokenUser);
+            //resultMap.put("user", tokenUser);
             resultMap.put("code", 0);
             resultMap.put("message", "查询费用汇总报表成功");
             return resultMap;
-        } catch (MzException e) {
-            log.error("查询费用汇总报表失败,错误信息{}", e.getMessage());
-            resultMap.put("code", -1);
-            resultMap.put("message", "查询费用汇总报表失败");
-            return resultMap;
-        } catch (Exception e) {
+        }
+//        catch (MzException e) {
+//            log.error("查询费用汇总报表失败,错误信息{}", e.getMessage());
+//            resultMap.put("code", -1);
+//            resultMap.put("message", "查询费用汇总报表失败");
+//            return resultMap;
+//        }
+        catch (Exception e) {
             e.printStackTrace();
             log.error("查询费用汇总报表失败,错误信息{}", e.getMessage());
             resultMap.put("code", -1);

+ 40 - 18
src/main/java/cn/hnthyy/thmz/mapper/his/ChargeFeeVoMapper.java

@@ -375,6 +375,16 @@ public interface ChargeFeeVoMapper {
                     "sum ( amount) zjss," +
                     "sum ( case when pay_mark ='0'  then amount else 0 end ) zjsk," +
                     "sum ( case when pay_mark  <![CDATA[<>]]>'0'  then amount else 0 end ) zjtk," +
+                    "sum ( case when (cheque_type='W' or (cheque_type='E' and op_id ='99999')) then amount else 0 end ) wxzzss," +
+                    "sum ( case when (cheque_type='W' or (cheque_type='E' and op_id ='99999')) and pay_mark ='0'  then amount else 0 end ) wxzzsk," +
+                    "sum ( case when (cheque_type='M' or (cheque_type='F' and op_id ='99999')) then amount else 0 end ) zfbzzss," +
+                    "sum ( case when (cheque_type='M' or (cheque_type='F' and op_id ='99999')) and pay_mark ='0'  then amount else 0 end ) zfbzzsk," +
+                    "count ( distinct case when (cheque_type='W' or (cheque_type='E' and op_id ='99999')) and pay_mark ='0' then receipt_sn else null end ) wxzzbs," +
+                    " count ( distinct case when (cheque_type='W' or (cheque_type='E' and op_id ='99999')) and pay_mark &gt; '0' then receipt_sn else null end ) wxzztfbs," +
+                    "sum ( case when (cheque_type='W' or (cheque_type='E' and op_id ='99999')) and pay_mark ='1' then amount else 0 end ) wxzztf," +
+                    "sum ( case when (cheque_type='M' or (cheque_type='F' and op_id ='99999')) and pay_mark ='1' then amount else 0 end ) zfbzztf," +
+                    "count ( distinct case when (cheque_type='M' or (cheque_type='F' and op_id ='99999')) and pay_mark ='0' then receipt_sn else null end ) zfbzzbs," +
+                    " count ( distinct case when (cheque_type='M' or (cheque_type='F' and op_id ='99999')) and pay_mark &gt; '0' then receipt_sn else null end ) zfbzztfbs," +
                     "count ( distinct case when cheque_type ='1' and pay_mark ='0' then receipt_sn else null end ) xjbs," +
                     "  count ( distinct case when ( cheque_type ='5' or cheque_type ='3' ) and pay_mark ='0' then receipt_sn else null end ) yhsbs," +
                     "  count ( distinct case when cheque_type ='6' and pay_mark ='0' then receipt_sn else null end ) sybbs," +
@@ -387,16 +397,16 @@ public interface ChargeFeeVoMapper {
                     "   count ( distinct case when cheque_type ='2'  and pay_mark &gt; '0'  then receipt_sn else null end ) ybjztfbs," +
                     "    count ( distinct case when pay_mark ='0' then receipt_sn else null end ) zjbs," +
                     "count ( distinct case when pay_mark  <![CDATA[<>]]> '0' then receipt_sn else null end ) ztfbs," +
-                    "count ( distinct case when cheque_type ='E' and pay_mark ='0' then receipt_sn else null end ) wxbs," +
-                    "count ( distinct case when cheque_type ='F' and pay_mark ='0' then receipt_sn else null end ) zfbbs," +
-                    "count ( distinct case when cheque_type ='E' and pay_mark  <![CDATA[<>]]> '0' then receipt_sn else null end ) wxtfbs," +
-                    "count ( distinct case when cheque_type ='F' and pay_mark  <![CDATA[<>]]> '0' then receipt_sn else null end ) zfbtfbs," +
-                    "sum ( case cheque_type when 'E' then amount else 0 end ) wxss," +
-                    "sum ( case when cheque_type ='E' and pay_mark ='0' then amount else 0 end ) wxsk," +
-                    "sum ( case cheque_type when 'F' then amount else 0 end ) zfbss," +
-                    "sum ( case when cheque_type ='F' and pay_mark ='0' then amount else 0 end ) zfbsk," +
-                    "sum ( case when cheque_type ='E' and pay_mark ='1' then amount else 0 end ) wxtf," +
-                    "sum ( case when cheque_type ='F' and pay_mark ='1' then amount else 0 end ) zfbtf " +
+                    "count ( distinct case when cheque_type ='E' and op_id <![CDATA[<>]]> '99999' and pay_mark ='0' then receipt_sn else null end ) wxbs," +
+                    "count ( distinct case when cheque_type ='F' and op_id <![CDATA[<>]]> '99999' and pay_mark ='0' then receipt_sn else null end ) zfbbs," +
+                    "count ( distinct case when cheque_type ='E' and op_id <![CDATA[<>]]> '99999' and pay_mark  <![CDATA[<>]]> '0' then receipt_sn else null end ) wxtfbs," +
+                    "count ( distinct case when cheque_type ='F' and op_id <![CDATA[<>]]> '99999' and pay_mark  <![CDATA[<>]]> '0' then receipt_sn else null end ) zfbtfbs," +
+                    "sum ( case when cheque_type= 'E' and op_id <![CDATA[<>]]> '99999' then amount else 0 end ) wxss," +
+                    "sum ( case when cheque_type ='E' and op_id <![CDATA[<>]]> '99999' and pay_mark ='0' then amount else 0 end ) wxsk," +
+                    "sum ( case when cheque_type= 'F' and op_id <![CDATA[<>]]> '99999' then amount else 0 end ) zfbss," +
+                    "sum ( case when cheque_type ='F' and op_id <![CDATA[<>]]> '99999' and pay_mark ='0' then amount else 0 end ) zfbsk," +
+                    "sum ( case when cheque_type ='E' and op_id <![CDATA[<>]]> '99999' and pay_mark ='1' then amount else 0 end ) wxtf," +
+                    "sum ( case when cheque_type ='F' and op_id <![CDATA[<>]]> '99999' and pay_mark ='1' then amount else 0 end ) zfbtf " +
                     " from mz_deposit_file " +
                     " where 1=1 and pay_mark <![CDATA[<>]]> 2 ",
             "<when test='userIdCode!=null'>",
@@ -481,7 +491,7 @@ public interface ChargeFeeVoMapper {
      * @return
      */
     @Select({"<script>",
-            "select count ( distinct receipt_bill ) from mz_receipt_serial where operator_id =#{userIdCode} and pay_mark =#{payMark} ",
+            "select count ( distinct receipt_bill ) from mz_receipt_serial where operator_id =#{userIdCode} and pay_mark =#{payMark} and len(receipt_bill)=8 and receipt_bill <![CDATA[<>]]> '00000000' ",
             "<when test='payMark!=null and payMark == 1'>",
             " and receipt_no  <![CDATA[<]]> 0 ",
             "</when>",
@@ -541,7 +551,7 @@ public interface ChargeFeeVoMapper {
      * @return
      */
     @Select({"<script>",
-            "select count ( *) from mzy_reqrec where cancel_mark =#{cancelMark} ",
+            "select count ( *) from mzy_reqrec where cancel_mark =#{cancelMark} and len(receipt_bill)=8 and receipt_bill <![CDATA[<>]]> '00000000' ",
             "<when test='cancelMark!=null and cancelMark == 1'>",
             " and times <![CDATA[<]]> 0 ",
             "</when>",
@@ -610,12 +620,24 @@ public interface ChargeFeeVoMapper {
                     " ABS(sum ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 and paymode ='Y' then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end )) byjzth, " +
                     " count ( case when cancel_mark ='0' and paymode ='Y'  then 1 else null end ) byjzsshs," +
                     " sum ( case when paymode ='Y'  then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) byjzss," +
-                    " count ( case when cancel_mark ='0' then 1 else null end ) +count ( case when cancel_mark ='1'   and times  <![CDATA[<]]> 0 then 1 else null end ) hjhs," +
-                    " sum ( case when cancel_mark ='0' then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) +ABS(sum ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ))hjsk, " +
-                    " count ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 then 1 else null end ) hjthhs," +
-                    " ABS(sum ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end )) hjth, " +
-                    " count ( case when cancel_mark ='0'  then 1 else null end ) hjsshs," +
-                    " sum ( req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) ) hjss," +
+                    " count ( case when cancel_mark ='0' and (paymode <![CDATA[<]]> 'hospital_z' or paymode is null) then 1 else null end ) +count ( case when cancel_mark ='1' and (paymode <![CDATA[<]]> 'hospital_z' or paymode is null)  and times  <![CDATA[<]]> 0 then 1 else null end ) hjhs," +
+                    " sum ( case when cancel_mark ='0' and (paymode <![CDATA[<]]> 'hospital_z' or paymode is null) then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) +ABS(sum ( case when cancel_mark ='1' and (paymode <![CDATA[<]]> 'hospital_z' or paymode is null) and times  <![CDATA[<]]> 0 then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ))hjsk, " +
+                    " count ( case when cancel_mark ='1' and (paymode <![CDATA[<]]> 'hospital_z' or paymode is null)  and times  <![CDATA[<]]> 0 then 1 else null end ) hjthhs," +
+                    " ABS(sum ( case when cancel_mark ='1' and (paymode <![CDATA[<]]> 'hospital_z' or paymode is null) and times  <![CDATA[<]]> 0 then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end )) hjth, " +
+                    " count ( case when cancel_mark ='0' and (paymode <![CDATA[<]]> 'hospital_z' or paymode is null) then 1 else null end ) hjsshs," +
+                    " sum ( case when paymode <![CDATA[<]]> 'hospital_z' or paymode is null then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) hjss," +
+                    " count ( case when cancel_mark ='0' and paymode ='WX' then 1 else null end ) + count ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 and paymode ='WX' then 1 else null end ) wxzzhs," +
+                    " sum ( case when cancel_mark ='0' and paymode ='WX'  then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) +ABS( sum ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 and paymode ='WX'  then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end )) wxzzsk, " +
+                    " count ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 and paymode ='WX' then 1 else null end ) wxzzthhs," +
+                    " ABS( sum ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 and paymode ='WX'  then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end )) wxzzth, " +
+                    " count ( case when cancel_mark ='0' and paymode ='WX' then 1 else null end ) wxzzsshs," +
+                    " sum ( case when paymode ='WX' then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) wxzzss, " +
+                    " count ( case when cancel_mark ='0' and paymode ='ZFB' then 1 else null end ) + count ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 and paymode ='ZFB' then 1 else null end ) zfbzzhs," +
+                    " sum ( case when cancel_mark ='0' and paymode ='ZFB'  then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) +ABS( sum ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 and paymode ='ZFB'  then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end )) zfbzzsk, " +
+                    " count ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 and paymode ='ZFB' then 1 else null end ) zfbzzthhs," +
+                    " ABS( sum ( case when cancel_mark ='1'  and times  <![CDATA[<]]> 0 and paymode ='ZFB'  then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end )) zfbzzth, " +
+                    " count ( case when cancel_mark ='0' and paymode ='ZFB' then 1 else null end ) zfbzzsshs," +
+                    " sum ( case when paymode ='ZFB' then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) zfbzzss, " +
                     " sum ( case when isnull ( paymode , '1' ) = 'Y' then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) ghjejz," +
                     " sum ( case when isnull ( paymode , '1' ) <![CDATA[<>]]> 'Y' then req_fee + oth_fee + clinic_fee + isnull ( brochure_fee , 0 ) + isnull ( bl_fee , 0 ) + isnull ( ck_fee , 0 ) else 0 end ) ghjebhjz," +
                     " sum ( clinic_fee ) zcsr," +

+ 41 - 0
src/main/java/cn/hnthyy/thmz/vo/ChargeCountVo.java

@@ -109,6 +109,30 @@ public class ChargeCountVo {
     private Integer wxssbs;
     //支付宝实收笔数
     private Integer zfbssbs;
+    //微信自助实收
+    private BigDecimal wxzzss;
+    //微信自助收款
+    private BigDecimal wxzzsk;
+    //微信自助收款笔数
+    private Integer wxzzbs;
+    //微信自助退费笔数
+    private Integer wxzztfbs;
+    //微信自助退费
+    private Integer wxzztf;
+    //微信自助实收笔数
+    private Integer wxzzssbs;
+    //支付宝自助实收
+    private BigDecimal zfbzzss;
+    //支付宝自助收款
+    private BigDecimal zfbzzsk;
+    //支付宝自助收款笔数
+    private Integer zfbzzbs;
+    //支付宝自助退费笔数
+    private Integer zfbzztfbs;
+    //支付宝自助退费
+    private Integer zfbzztf;
+    //支付宝自助实收笔数
+    private Integer zfbzzssbs;
     //以上次数公式为收款次数--退费次数
 
     //实缴合计
@@ -191,6 +215,23 @@ public class ChargeCountVo {
         }
         zjssbs=zjbs-ztfbs;
 
+        if(wxzzbs==null){
+            wxzzbs=0;
+        }
+        if(wxzztfbs==null){
+            wxzztfbs=0;
+        }
+        wxzzssbs=wxzzbs-wxzztfbs;
+
+        if(zfbzzbs==null){
+            zfbzzbs=0;
+        }
+        if(zfbzztfbs==null){
+            zfbzztfbs=0;
+        }
+        zfbzzssbs=zfbzzbs-zfbzztfbs;
+
+
         if(zfss==null){
             zfss=BigDecimal.ZERO;
         }

+ 24 - 0
src/main/java/cn/hnthyy/thmz/vo/ReqrecVo.java

@@ -103,6 +103,30 @@ public class ReqrecVo {
     private Integer byjzsshs;
     //本院记账实收
     private BigDecimal byjzss;
+    //微信自助号数
+    private Integer wxzzhs;
+    //微信自助收款
+    private BigDecimal wxzzsk;
+    //微信自助退号号数
+    private Integer wxzzthhs;
+    //微信自助退号费
+    private BigDecimal wxzzth;
+    //微信自助实收号数
+    private Integer wxzzsshs;
+    //微信自助实收
+    private BigDecimal wxzzss;
+    //支付宝自助号数
+    private Integer zfbzzhs;
+    //支付宝自助收款
+    private BigDecimal zfbzzsk;
+    //支付宝自助退号号数
+    private Integer zfbzzthhs;
+    //支付宝自助退号费
+    private BigDecimal zfbzzth;
+    //支付宝自助实收号数
+    private Integer zfbzzsshs;
+    //支付宝自助实收
+    private BigDecimal zfbzzss;
     //合计号数
     private Integer hjhs;
     //合计收款

+ 120 - 56
src/main/resources/static/js/daily.js

@@ -53,8 +53,9 @@ function initFeeTable() {
 /**
  * 设置收费参数
  * @param res
+ * @param flag 是否显示的是自助的费用
  */
-function extractedSf (res) {
+function extractedSf (res,flag) {
 //现金收款
     $("#xjbs").html(res.chargeCountVo.xjbs);
     if (res.chargeCountVo.xjsk != null) {
@@ -94,31 +95,60 @@ function extractedSf (res) {
     if (res.chargeCountVo.ybjzss != null) {
         $("#ybjzss").html(res.chargeCountVo.ybjzss.toFixed(2));
     }
-    //支付宝收款
-    $("#zfbbs").html(res.chargeCountVo.zfbbs);
-    if (res.chargeCountVo.zfbsk != null) {
-        $("#zfbsk").html(res.chargeCountVo.zfbsk.toFixed(2));
-    }
-    $("#zfbtfbs").html(res.chargeCountVo.zfbtfbs);
-    if (res.chargeCountVo.zfbtf != null) {
-        $("#zfbtf").html(res.chargeCountVo.zfbtf.toFixed(2));
-    }
-    $("#zfbssbs").html(res.chargeCountVo.zfbssbs);
-    if (res.chargeCountVo.zfbss != null) {
-        $("#zfbss").html(res.chargeCountVo.zfbss.toFixed(2));
-    }
-    //微信收款
-    $("#wxbs").html(res.chargeCountVo.wxbs);
-    if (res.chargeCountVo.wxsk != null) {
-        $("#wxsk").html(res.chargeCountVo.wxsk.toFixed(2));
-    }
-    $("#wxtfbs").html(res.chargeCountVo.wxtfbs);
-    if (res.chargeCountVo.wxtf != null) {
-        $("#wxtf").html(res.chargeCountVo.wxtf.toFixed(2));
-    }
-    $("#wxssbs").html(res.chargeCountVo.wxssbs);
-    if (res.chargeCountVo.wxss != null) {
-        $("#wxss").html(res.chargeCountVo.wxss.toFixed(2));
+    if(flag){
+        //支付宝自助收款
+        $("#zfbbs").html(res.chargeCountVo.zfbzzbs);
+        if (res.chargeCountVo.zfbzzsk != null) {
+            $("#zfbsk").html(res.chargeCountVo.zfbzzsk.toFixed(2));
+        }
+        $("#zfbtfbs").html(res.chargeCountVo.zfbzztfbs);
+        if (res.chargeCountVo.zfbzztf != null) {
+            $("#zfbtf").html(res.chargeCountVo.zfbzztf.toFixed(2));
+        }
+        $("#zfbssbs").html(res.chargeCountVo.zfbzzssbs);
+        if (res.chargeCountVo.zfbzzss != null) {
+            $("#zfbss").html(res.chargeCountVo.zfbzzss.toFixed(2));
+        }
+        //微信自助收款
+        $("#wxbs").html(res.chargeCountVo.wxzzbs);
+        if (res.chargeCountVo.wxzzsk != null) {
+            $("#wxsk").html(res.chargeCountVo.wxzzsk.toFixed(2));
+        }
+        $("#wxtfbs").html(res.chargeCountVo.wxzztfbs);
+        if (res.chargeCountVo.wxzztf != null) {
+            $("#wxtf").html(res.chargeCountVo.wxzztf.toFixed(2));
+        }
+        $("#wxssbs").html(res.chargeCountVo.wxzzssbs);
+        if (res.chargeCountVo.wxzzss != null) {
+            $("#wxss").html(res.chargeCountVo.wxzzss.toFixed(2));
+        }
+    }else {
+        //支付宝收款
+        $("#zfbbs").html(res.chargeCountVo.zfbbs);
+        if (res.chargeCountVo.zfbsk != null) {
+            $("#zfbsk").html(res.chargeCountVo.zfbsk.toFixed(2));
+        }
+        $("#zfbtfbs").html(res.chargeCountVo.zfbtfbs);
+        if (res.chargeCountVo.zfbtf != null) {
+            $("#zfbtf").html(res.chargeCountVo.zfbtf.toFixed(2));
+        }
+        $("#zfbssbs").html(res.chargeCountVo.zfbssbs);
+        if (res.chargeCountVo.zfbss != null) {
+            $("#zfbss").html(res.chargeCountVo.zfbss.toFixed(2));
+        }
+        //微信收款
+        $("#wxbs").html(res.chargeCountVo.wxbs);
+        if (res.chargeCountVo.wxsk != null) {
+            $("#wxsk").html(res.chargeCountVo.wxsk.toFixed(2));
+        }
+        $("#wxtfbs").html(res.chargeCountVo.wxtfbs);
+        if (res.chargeCountVo.wxtf != null) {
+            $("#wxtf").html(res.chargeCountVo.wxtf.toFixed(2));
+        }
+        $("#wxssbs").html(res.chargeCountVo.wxssbs);
+        if (res.chargeCountVo.wxss != null) {
+            $("#wxss").html(res.chargeCountVo.wxss.toFixed(2));
+        }
     }
     //记账绿色通道收款
     $("#zfbs").html(res.chargeCountVo.zfbs);
@@ -187,7 +217,7 @@ function extractedSf (res) {
  * 设置挂号参数
  * @param res
  */
-function extractedGh (res) {
+function extractedGh (res,flag) {
 //现金收款
     $("#ghxjbs").html(res.ghsrgcmx.xjhs);
     if (res.ghsrgcmx.xjsk != null) {
@@ -227,32 +257,61 @@ function extractedGh (res) {
     if (res.ghsrgcmx.ybkss != null) {
         $("#ghsybkss").html(res.ghsrgcmx.ybkss.toFixed(2));
     }
-    //支付宝收款
-    $("#ghzfbbs").html(res.ghsrgcmx.zfbhs);
-    if (res.ghsrgcmx.zfbsk != null) {
-        $("#ghzfbsk").html(res.ghsrgcmx.zfbsk.toFixed(2));
-    }
-    $("#ghzfbtfbs").html(res.ghsrgcmx.zfbthhs);
-    if (res.ghsrgcmx.zfbth != null) {
-        $("#ghzfbtf").html(res.ghsrgcmx.zfbth.toFixed(2));
-    }
-    $("#ghzfbssbs").html(res.ghsrgcmx.zfbsshs);
-    if (res.ghsrgcmx.zfbss != null) {
-        $("#ghzfbss").html(res.ghsrgcmx.zfbss.toFixed(2));
-    }
-    //微信收款
-    $("#ghwxbs").html(res.ghsrgcmx.wxhs);
-    if (res.ghsrgcmx.wxsk != null) {
-        $("#ghwxsk").html(res.ghsrgcmx.wxsk.toFixed(2));
-    }
-    $("#ghwxtfbs").html(res.ghsrgcmx.wxthhs);
-    if (res.ghsrgcmx.wxth != null) {
-        $("#ghwxtf").html(res.ghsrgcmx.wxth.toFixed(2));
-    }
-    $("#ghwxssbs").html(res.ghsrgcmx.wxsshs);
-    if (res.ghsrgcmx.wxss != null) {
-        $("#ghwxss").html(res.ghsrgcmx.wxss.toFixed(2));
-    }
+   if(flag){
+       //支付宝自助收款
+       $("#ghzfbbs").html(res.ghsrgcmx.zfbzzhs);
+       if (res.ghsrgcmx.zfbzzsk != null) {
+           $("#ghzfbsk").html(res.ghsrgcmx.zfbzzsk.toFixed(2));
+       }
+       $("#ghzfbtfbs").html(res.ghsrgcmx.zfbzzthhs);
+       if (res.ghsrgcmx.zfbzzth != null) {
+           $("#ghzfbtf").html(res.ghsrgcmx.zfbzzth.toFixed(2));
+       }
+       $("#ghzfbssbs").html(res.ghsrgcmx.zfbzzsshs);
+       if (res.ghsrgcmx.zfbzzss != null) {
+           $("#ghzfbss").html(res.ghsrgcmx.zfbzzss.toFixed(2));
+       }
+       //微信自助收款
+       $("#ghwxbs").html(res.ghsrgcmx.wxzzhs);
+       if (res.ghsrgcmx.wxzzsk != null) {
+           $("#ghwxsk").html(res.ghsrgcmx.wxzzsk.toFixed(2));
+       }
+       $("#ghwxtfbs").html(res.ghsrgcmx.wxzzthhs);
+       if (res.ghsrgcmx.wxzzth != null) {
+           $("#ghwxtf").html(res.ghsrgcmx.wxzzth.toFixed(2));
+       }
+       $("#ghwxssbs").html(res.ghsrgcmx.wxzzsshs);
+       if (res.ghsrgcmx.wxzzss != null) {
+           $("#ghwxss").html(res.ghsrgcmx.wxzzss.toFixed(2));
+       }
+   }else {
+       //支付宝收款
+       $("#ghzfbbs").html(res.ghsrgcmx.zfbhs);
+       if (res.ghsrgcmx.zfbsk != null) {
+           $("#ghzfbsk").html(res.ghsrgcmx.zfbsk.toFixed(2));
+       }
+       $("#ghzfbtfbs").html(res.ghsrgcmx.zfbthhs);
+       if (res.ghsrgcmx.zfbth != null) {
+           $("#ghzfbtf").html(res.ghsrgcmx.zfbth.toFixed(2));
+       }
+       $("#ghzfbssbs").html(res.ghsrgcmx.zfbsshs);
+       if (res.ghsrgcmx.zfbss != null) {
+           $("#ghzfbss").html(res.ghsrgcmx.zfbss.toFixed(2));
+       }
+       //微信收款
+       $("#ghwxbs").html(res.ghsrgcmx.wxhs);
+       if (res.ghsrgcmx.wxsk != null) {
+           $("#ghwxsk").html(res.ghsrgcmx.wxsk.toFixed(2));
+       }
+       $("#ghwxtfbs").html(res.ghsrgcmx.wxthhs);
+       if (res.ghsrgcmx.wxth != null) {
+           $("#ghwxtf").html(res.ghsrgcmx.wxth.toFixed(2));
+       }
+       $("#ghwxssbs").html(res.ghsrgcmx.wxsshs);
+       if (res.ghsrgcmx.wxss != null) {
+           $("#ghwxss").html(res.ghsrgcmx.wxss.toFixed(2));
+       }
+   }
     //记账绿色通道收款
     $("#ghzfbs").html(res.ghsrgcmx.byjzhs);
     if (res.ghsrgcmx.byjzsk != null) {
@@ -325,6 +384,11 @@ function getRjbb() {
                 return;
             }
             if (res.code == 0) {
+                if(res.user.userCode!=null && res.user.userCode=='9999'){
+                    $(".zz_title").removeClass('hide').addClass('in');
+                }else {
+                    $(".zz_title").removeClass('in').addClass('hide');
+                }
                 $("#userIdCode").html(res.user.userCode);
                 $("#username").html(res.user.userName);
                 $("#dcountDate").html(format(new Date(), "yyyy-MM-dd HH:mm:ss"));
@@ -351,8 +415,8 @@ function getRjbb() {
                 $("#totalCharge").html(res.mzReceiptSerial.totalCharge);
                 $("#totalChargeStr").html(res.mzReceiptSerial.totalChargeStr);
 
-                extractedSf(res);
-                extractedGh (res);
+                extractedSf(res , res.user.userCode!=null && res.user.userCode=='9999');
+                extractedGh (res , res.user.userCode!=null && res.user.userCode=='9999');
 
                 $("#receiptBills_table").html(null);
                 var html = '';
@@ -722,7 +786,7 @@ function dcountCharge() {
                     LODOP.SET_PRINTER_INDEX(printIndex);
                     LODOP.SET_SHOW_MODE("BKIMG_WIDTH", "210mm");
                     LODOP.SET_SHOW_MODE("BKIMG_HEIGHT", "297mm");
-                    var strStyle="<style>table{width: 96%;margin-top: 20px;margin-bottom: 10px;} table,td,th {border-width: 1px;border-style: solid;border-collapse: collapse}</style>"
+                    var strStyle="<style>table{width: 96%;margin-top: 20px;margin-bottom: 10px;} table,td,th {border-width: 1px;border-style: solid;border-collapse: collapse}</style>";
                     LODOP.ADD_PRINT_HTM("0mm", "5mm", "200mm", "280mm",strStyle+ document.getElementById("report_table_1").innerHTML);
                     LODOP.NewPageA();
                     LODOP.ADD_PRINT_HTM("0mm", "5mm", "200mm", "280mm", document.getElementById("zbr_div").innerHTML);

+ 71 - 13
src/main/resources/static/js/daily_collect.js

@@ -128,6 +128,34 @@ function extractedSf (res) {
     if (res.chargeCountVo.wxss != null) {
         $("#wxss").html(res.chargeCountVo.wxss.toFixed(2));
     }
+
+    //支付宝自助收款
+    $("#zfbzzbs").html(res.chargeCountVo.zfbzzbs);
+    if (res.chargeCountVo.zfbzzsk != null) {
+        $("#zfbzzsk").html(res.chargeCountVo.zfbzzsk.toFixed(2));
+    }
+    $("#zfbzztfbs").html(res.chargeCountVo.zfbzztfbs);
+    if (res.chargeCountVo.zfbzztf != null) {
+        $("#zfbzztf").html(res.chargeCountVo.zfbzztf.toFixed(2));
+    }
+    $("#zfbzzssbs").html(res.chargeCountVo.zfbzzssbs);
+    if (res.chargeCountVo.zfbzzss != null) {
+        $("#zfbzzss").html(res.chargeCountVo.zfbzzss.toFixed(2));
+    }
+    //微信自助收款
+    $("#wxzzbs").html(res.chargeCountVo.wxzzbs);
+    if (res.chargeCountVo.wxzzsk != null) {
+        $("#wxzzsk").html(res.chargeCountVo.wxzzsk.toFixed(2));
+    }
+    $("#wxzztfbs").html(res.chargeCountVo.wxzztfbs);
+    if (res.chargeCountVo.wxzztf != null) {
+        $("#wxzztf").html(res.chargeCountVo.wxzztf.toFixed(2));
+    }
+    $("#wxzzssbs").html(res.chargeCountVo.wxzzssbs);
+    if (res.chargeCountVo.wxzzss != null) {
+        $("#wxzzss").html(res.chargeCountVo.wxzzss.toFixed(2));
+    }
+
     //记账绿色通道收款
     $("#zfbs").html(res.chargeCountVo.zfbs);
     if (res.chargeCountVo.zfsk != null) {
@@ -261,6 +289,34 @@ function extractedGh (res) {
     if (res.ghsrgcmx.wxss != null) {
         $("#ghwxss").html(res.ghsrgcmx.wxss.toFixed(2));
     }
+
+    //支付宝自助收款
+    $("#ghzfbzzbs").html(res.ghsrgcmx.zfbzzhs);
+    if (res.ghsrgcmx.zfbzzsk != null) {
+        $("#ghzfbzzsk").html(res.ghsrgcmx.zfbzzsk.toFixed(2));
+    }
+    $("#ghzfbzztfbs").html(res.ghsrgcmx.zfbzzthhs);
+    if (res.ghsrgcmx.zfbzzth != null) {
+        $("#ghzfbzztf").html(res.ghsrgcmx.zfbzzth.toFixed(2));
+    }
+    $("#ghzfbzzssbs").html(res.ghsrgcmx.zfbzzsshs);
+    if (res.ghsrgcmx.zfbzzss != null) {
+        $("#ghzfbzzss").html(res.ghsrgcmx.zfbzzss.toFixed(2));
+    }
+    //微信自助收款
+    $("#ghwxzzbs").html(res.ghsrgcmx.wxzzhs);
+    if (res.ghsrgcmx.wxzzsk != null) {
+        $("#ghwxzzsk").html(res.ghsrgcmx.wxzzsk.toFixed(2));
+    }
+    $("#ghwxzztfbs").html(res.ghsrgcmx.wxzzthhs);
+    if (res.ghsrgcmx.wxzzth != null) {
+        $("#ghwxzztf").html(res.ghsrgcmx.wxzzth.toFixed(2));
+    }
+    $("#ghwxzzssbs").html(res.ghsrgcmx.wxzzsshs);
+    if (res.ghsrgcmx.wxzzss != null) {
+        $("#ghwxzzss").html(res.ghsrgcmx.wxzzss.toFixed(2));
+    }
+
     //记账绿色通道收款
     $("#ghzfbs").html(res.ghsrgcmx.byjzhs);
     if (res.ghsrgcmx.byjzsk != null) {
@@ -367,8 +423,10 @@ function getRjbb() {
 
                 if (res.ghWorkloadVos.length == 0) {
                     $("#ghgzlhzb_parent").css("display", "none");
+                    $("#ghgzlhzb_title").css("display", "none");
                 } else if (res.ghWorkloadVos.length > 0) {
                     $("#ghgzlhzb_parent").css("display", "block");
+                    $("#ghgzlhzb_title").css("display", "block");
                     var html = '';
                     for (var i = 0; i < res.ghWorkloadVos.length - 1; i++) {
                         var temp = res.ghWorkloadVos[i];
@@ -393,8 +451,10 @@ function getRjbb() {
 
                 if (res.sfWorkloadVos.length == 0) {
                     $("#sfgzlhzb_parent").css("display", "none");
+                    $("#sfgzlhzb_parent_title").css("display", "none");
                 } else if (res.sfWorkloadVos.length > 0) {
                     $("#sfgzlhzb_parent").css("display", "block");
+                    $("#sfgzlhzb_parent_title").css("display", "block");
                     var html = '';
                     for (var i = 0; i < res.sfWorkloadVos.length-1; i++) {
                         var temp = res.sfWorkloadVos[i];
@@ -415,7 +475,7 @@ function getRjbb() {
                     html += '<td>' + temp.totalAmount.toFixed(2) + '</td></tr>';
                     $("#sfgzlhzb").html(html);
                 }
-                $("#username_zbr").html(res.user.userName);
+               // $("#username_zbr").html(res.user.userName);
             } else if (res.code == -1) {
                 new PNotify({
                     title: '错误提示',
@@ -765,7 +825,6 @@ function print() {
     setPrint();
     LODOP = getLodop();
     LODOP.PRINT_INITA(6, 0, "210mm", "297mm", "门诊收费收入日报表");
-    var strStyle="<style> table,td,th {border-width: 1px;border-style: solid;border-collapse: collapse}</style>"
     //设置默认打印机
     LODOP.SET_PRINTER_INDEX(printIndex);
     LODOP.SET_PRINT_STYLE("FontSize", 9); //字体大小
@@ -773,25 +832,23 @@ function print() {
     LODOP.SET_PRINTER_INDEX(printIndex);
     LODOP.SET_SHOW_MODE("BKIMG_WIDTH", "210mm");
     LODOP.SET_SHOW_MODE("BKIMG_HEIGHT", "297mm");
-    LODOP.ADD_PRINT_HTM("0mm", "0mm", "200mm", "280mm", document.getElementById("printDiv").innerHTML);
+    var strStyle="<style>table{width: 96%;margin-top: 20px;margin-bottom: 10px;} table,td,th {border-width: 1px;border-style: solid;border-collapse: collapse}</style>";
+    LODOP.ADD_PRINT_HTM("0mm", "0mm", "200mm", "280mm", strStyle+document.getElementById("report_table_1").innerHTML);
     LODOP.NewPageA();
-    //LODOP.ADD_PRINT_HTM("0mm", "0mm", "210mm", "297mm", document.getElementById("ghgzlhzb_parent_p").innerHTML);
-
-    LODOP.ADD_PRINT_TABLE(70,"5%","90%",1000,strStyle+document.getElementById("ghgzlhzb_parent_p").innerHTML);
+    LODOP.ADD_PRINT_TABLE(70,"5%","90%",1000,strStyle+document.getElementById("ghgzlhzb_parent").innerHTML);
     LODOP.SET_PRINT_STYLEA(0,"Vorient",3);
-    LODOP.ADD_PRINT_HTM(26,"5%","90%",109,document.getElementById("ghgzlhzb_p_title").innerHTML);
+    LODOP.ADD_PRINT_HTM(26,"5%","90%",109,document.getElementById("ghgzlhzb_title").innerHTML);
     LODOP.SET_PRINT_STYLEA(0,"ItemType",1);
     LODOP.SET_PRINT_STYLEA(0,"LinkedItem",2);
     LODOP.NewPageA();
-   // LODOP.ADD_PRINT_HTM("0mm", "0mm", "210mm", "297mm", document.getElementById("sfgzlhzb_parent_p").innerHTML);
-    LODOP.ADD_PRINT_TABLE(70,"5%","90%",1000,strStyle+document.getElementById("sfgzlhzb_parent_p").innerHTML);
+    LODOP.ADD_PRINT_TABLE(70,"5%","90%",1000,strStyle+document.getElementById("sfgzlhzb_parent").innerHTML);
     LODOP.SET_PRINT_STYLEA(0,"Vorient",3);
-    LODOP.ADD_PRINT_HTM(26,"5%","90%",109,document.getElementById("sfgzlhzb_parent_p_title").innerHTML);
+    LODOP.ADD_PRINT_HTM(26,"5%","90%",109,document.getElementById("sfgzlhzb_parent_title").innerHTML);
     LODOP.SET_PRINT_STYLEA(0,"ItemType",1);
     LODOP.SET_PRINT_STYLEA(0,"LinkedItem",4);
-    LODOP.ADD_PRINT_HTM(600,"5%","90%",109, document.getElementById("username_zbr_p_parent").innerHTML);
-    //LODOP.PRINT();
-    LODOP.PREVIEW();
+    // LODOP.ADD_PRINT_HTM(600,"5%","90%",109, document.getElementById("username_zbr_parent").innerHTML);
+    LODOP.PRINT();
+    //LODOP.PREVIEW();
 }
 
 
@@ -853,6 +910,7 @@ function daterangepicker(callback) {
 
     //$('#reportrange span').html(moment().subtract(29, 'days').format('YYYY-MM-DD') + ' - ' + moment().format('YYYY-MM-DD'));
     $('#reportrange span').html(moment().format('YYYY-MM-DD') + ' - ' + moment().format('YYYY-MM-DD'));
+    callback();
     $('#reportrange').daterangepicker(optionSet1, cb);
     $('#reportrange').on('show.daterangepicker', function () {
         console.log("show event fired");

+ 122 - 55
src/main/resources/static/js/daily_repeat_print.js

@@ -56,12 +56,12 @@ function initFeeTable() {
 
 }
 
-
 /**
  * 设置收费参数
  * @param res
+ * @param flag 是否显示的是自助的费用
  */
-function extractedSf (res) {
+function extractedSf (res,flag) {
 //现金收款
     $("#xjbs").html(res.chargeCountVo.xjbs);
     if (res.chargeCountVo.xjsk != null) {
@@ -101,31 +101,60 @@ function extractedSf (res) {
     if (res.chargeCountVo.ybjzss != null) {
         $("#ybjzss").html(res.chargeCountVo.ybjzss.toFixed(2));
     }
-    //支付宝收款
-    $("#zfbbs").html(res.chargeCountVo.zfbbs);
-    if (res.chargeCountVo.zfbsk != null) {
-        $("#zfbsk").html(res.chargeCountVo.zfbsk.toFixed(2));
-    }
-    $("#zfbtfbs").html(res.chargeCountVo.zfbtfbs);
-    if (res.chargeCountVo.zfbtf != null) {
-        $("#zfbtf").html(res.chargeCountVo.zfbtf.toFixed(2));
-    }
-    $("#zfbssbs").html(res.chargeCountVo.zfbssbs);
-    if (res.chargeCountVo.zfbss != null) {
-        $("#zfbss").html(res.chargeCountVo.zfbss.toFixed(2));
-    }
-    //微信收款
-    $("#wxbs").html(res.chargeCountVo.wxbs);
-    if (res.chargeCountVo.wxsk != null) {
-        $("#wxsk").html(res.chargeCountVo.wxsk.toFixed(2));
-    }
-    $("#wxtfbs").html(res.chargeCountVo.wxtfbs);
-    if (res.chargeCountVo.wxtf != null) {
-        $("#wxtf").html(res.chargeCountVo.wxtf.toFixed(2));
-    }
-    $("#wxssbs").html(res.chargeCountVo.wxssbs);
-    if (res.chargeCountVo.wxss != null) {
-        $("#wxss").html(res.chargeCountVo.wxss.toFixed(2));
+    if(flag){
+        //支付宝自助收款
+        $("#zfbbs").html(res.chargeCountVo.zfbzzbs);
+        if (res.chargeCountVo.zfbzzsk != null) {
+            $("#zfbsk").html(res.chargeCountVo.zfbzzsk.toFixed(2));
+        }
+        $("#zfbtfbs").html(res.chargeCountVo.zfbzztfbs);
+        if (res.chargeCountVo.zfbzztf != null) {
+            $("#zfbtf").html(res.chargeCountVo.zfbzztf.toFixed(2));
+        }
+        $("#zfbssbs").html(res.chargeCountVo.zfbzzssbs);
+        if (res.chargeCountVo.zfbzzss != null) {
+            $("#zfbss").html(res.chargeCountVo.zfbzzss.toFixed(2));
+        }
+        //微信自助收款
+        $("#wxbs").html(res.chargeCountVo.wxzzbs);
+        if (res.chargeCountVo.wxzzsk != null) {
+            $("#wxsk").html(res.chargeCountVo.wxzzsk.toFixed(2));
+        }
+        $("#wxtfbs").html(res.chargeCountVo.wxzztfbs);
+        if (res.chargeCountVo.wxzztf != null) {
+            $("#wxtf").html(res.chargeCountVo.wxzztf.toFixed(2));
+        }
+        $("#wxssbs").html(res.chargeCountVo.wxzzssbs);
+        if (res.chargeCountVo.wxzzss != null) {
+            $("#wxss").html(res.chargeCountVo.wxzzss.toFixed(2));
+        }
+    }else {
+        //支付宝收款
+        $("#zfbbs").html(res.chargeCountVo.zfbbs);
+        if (res.chargeCountVo.zfbsk != null) {
+            $("#zfbsk").html(res.chargeCountVo.zfbsk.toFixed(2));
+        }
+        $("#zfbtfbs").html(res.chargeCountVo.zfbtfbs);
+        if (res.chargeCountVo.zfbtf != null) {
+            $("#zfbtf").html(res.chargeCountVo.zfbtf.toFixed(2));
+        }
+        $("#zfbssbs").html(res.chargeCountVo.zfbssbs);
+        if (res.chargeCountVo.zfbss != null) {
+            $("#zfbss").html(res.chargeCountVo.zfbss.toFixed(2));
+        }
+        //微信收款
+        $("#wxbs").html(res.chargeCountVo.wxbs);
+        if (res.chargeCountVo.wxsk != null) {
+            $("#wxsk").html(res.chargeCountVo.wxsk.toFixed(2));
+        }
+        $("#wxtfbs").html(res.chargeCountVo.wxtfbs);
+        if (res.chargeCountVo.wxtf != null) {
+            $("#wxtf").html(res.chargeCountVo.wxtf.toFixed(2));
+        }
+        $("#wxssbs").html(res.chargeCountVo.wxssbs);
+        if (res.chargeCountVo.wxss != null) {
+            $("#wxss").html(res.chargeCountVo.wxss.toFixed(2));
+        }
     }
     //记账绿色通道收款
     $("#zfbs").html(res.chargeCountVo.zfbs);
@@ -194,7 +223,7 @@ function extractedSf (res) {
  * 设置挂号参数
  * @param res
  */
-function extractedGh (res) {
+function extractedGh (res,flag) {
 //现金收款
     $("#ghxjbs").html(res.ghsrgcmx.xjhs);
     if (res.ghsrgcmx.xjsk != null) {
@@ -234,31 +263,60 @@ function extractedGh (res) {
     if (res.ghsrgcmx.ybkss != null) {
         $("#ghsybkss").html(res.ghsrgcmx.ybkss.toFixed(2));
     }
-    //支付宝收款
-    $("#ghzfbbs").html(res.ghsrgcmx.zfbhs);
-    if (res.ghsrgcmx.zfbsk != null) {
-        $("#ghzfbsk").html(res.ghsrgcmx.zfbsk.toFixed(2));
-    }
-    $("#ghzfbtfbs").html(res.ghsrgcmx.zfbthhs);
-    if (res.ghsrgcmx.zfbth != null) {
-        $("#ghzfbtf").html(res.ghsrgcmx.zfbth.toFixed(2));
-    }
-    $("#ghzfbssbs").html(res.ghsrgcmx.zfbsshs);
-    if (res.ghsrgcmx.zfbss != null) {
-        $("#ghzfbss").html(res.ghsrgcmx.zfbss.toFixed(2));
-    }
-    //微信收款
-    $("#ghwxbs").html(res.ghsrgcmx.wxhs);
-    if (res.ghsrgcmx.wxsk != null) {
-        $("#ghwxsk").html(res.ghsrgcmx.wxsk.toFixed(2));
-    }
-    $("#ghwxtfbs").html(res.ghsrgcmx.wxthhs);
-    if (res.ghsrgcmx.wxth != null) {
-        $("#ghwxtf").html(res.ghsrgcmx.wxth.toFixed(2));
-    }
-    $("#ghwxssbs").html(res.ghsrgcmx.wxsshs);
-    if (res.ghsrgcmx.wxss != null) {
-        $("#ghwxss").html(res.ghsrgcmx.wxss.toFixed(2));
+    if(flag){
+        //支付宝自助收款
+        $("#ghzfbbs").html(res.ghsrgcmx.zfbzzhs);
+        if (res.ghsrgcmx.zfbzzsk != null) {
+            $("#ghzfbsk").html(res.ghsrgcmx.zfbzzsk.toFixed(2));
+        }
+        $("#ghzfbtfbs").html(res.ghsrgcmx.zfbzzthhs);
+        if (res.ghsrgcmx.zfbzzth != null) {
+            $("#ghzfbtf").html(res.ghsrgcmx.zfbzzth.toFixed(2));
+        }
+        $("#ghzfbssbs").html(res.ghsrgcmx.zfbzzsshs);
+        if (res.ghsrgcmx.zfbzzss != null) {
+            $("#ghzfbss").html(res.ghsrgcmx.zfbzzss.toFixed(2));
+        }
+        //微信自助收款
+        $("#ghwxbs").html(res.ghsrgcmx.wxzzhs);
+        if (res.ghsrgcmx.wxzzsk != null) {
+            $("#ghwxsk").html(res.ghsrgcmx.wxzzsk.toFixed(2));
+        }
+        $("#ghwxtfbs").html(res.ghsrgcmx.wxzzthhs);
+        if (res.ghsrgcmx.wxzzth != null) {
+            $("#ghwxtf").html(res.ghsrgcmx.wxzzth.toFixed(2));
+        }
+        $("#ghwxssbs").html(res.ghsrgcmx.wxzzsshs);
+        if (res.ghsrgcmx.wxzzss != null) {
+            $("#ghwxss").html(res.ghsrgcmx.wxzzss.toFixed(2));
+        }
+    }else {
+        //支付宝收款
+        $("#ghzfbbs").html(res.ghsrgcmx.zfbhs);
+        if (res.ghsrgcmx.zfbsk != null) {
+            $("#ghzfbsk").html(res.ghsrgcmx.zfbsk.toFixed(2));
+        }
+        $("#ghzfbtfbs").html(res.ghsrgcmx.zfbthhs);
+        if (res.ghsrgcmx.zfbth != null) {
+            $("#ghzfbtf").html(res.ghsrgcmx.zfbth.toFixed(2));
+        }
+        $("#ghzfbssbs").html(res.ghsrgcmx.zfbsshs);
+        if (res.ghsrgcmx.zfbss != null) {
+            $("#ghzfbss").html(res.ghsrgcmx.zfbss.toFixed(2));
+        }
+        //微信收款
+        $("#ghwxbs").html(res.ghsrgcmx.wxhs);
+        if (res.ghsrgcmx.wxsk != null) {
+            $("#ghwxsk").html(res.ghsrgcmx.wxsk.toFixed(2));
+        }
+        $("#ghwxtfbs").html(res.ghsrgcmx.wxthhs);
+        if (res.ghsrgcmx.wxth != null) {
+            $("#ghwxtf").html(res.ghsrgcmx.wxth.toFixed(2));
+        }
+        $("#ghwxssbs").html(res.ghsrgcmx.wxsshs);
+        if (res.ghsrgcmx.wxss != null) {
+            $("#ghwxss").html(res.ghsrgcmx.wxss.toFixed(2));
+        }
     }
     //记账绿色通道收款
     $("#ghzfbs").html(res.ghsrgcmx.byjzhs);
@@ -314,6 +372,7 @@ function extractedGh (res) {
 }
 
 
+
 /**
  * 获取日结报表
  */
@@ -332,16 +391,24 @@ function getRjbb() {
                 return;
             }
             if (res.code == 0) {
+                var userCode=null;
                 if(res.user!=null){
+                    userCode=res.user.userCode;
                     $("#userIdCode").html(res.user.userCode);
                     $("#username").html(res.user.userName);
                     $("#username_zbr").html(res.user.userName);
                 }else {
+                    userCode=$("#cashParam").val();
                     $("#userIdCode").html($("#cashParam").val());
                     var uerName=$("#cashParam").find('option:selected').text();
                     $("#username").html(uerName);
                     $("#username_zbr").html(uerName);
                 }
+                if(userCode!=null && userCode=='9999'){
+                    $(".zz_title").removeClass('hide').addClass('in');
+                }else {
+                    $(".zz_title").removeClass('in').addClass('hide');
+                }
                 $("#dcountDate").html(format(new Date(), "yyyy-MM-dd HH:mm:ss"));
                 $("#charge1").html(res.mzReceiptSerial.charge1.toFixed(2));
                 $("#charge2").html(res.mzReceiptSerial.charge2.toFixed(2));
@@ -366,8 +433,8 @@ function getRjbb() {
                 $("#totalCharge").html(res.mzReceiptSerial.totalCharge);
                 $("#totalChargeStr").html(res.mzReceiptSerial.totalChargeStr);
 
-                extractedSf(res);
-                extractedGh (res);
+                extractedSf(res , userCode!=null && userCode=='9999');
+                extractedGh (res , userCode!=null && userCode=='9999');
 
                 $("#receiptBills_table").html(null);
                 var html = '';

+ 4 - 4
src/main/resources/templates/daily.html

@@ -173,7 +173,7 @@
                             <td id="ybjzss">0.00</td>
                         </tr>
                         <tr>
-                            <td class="text-center">支付宝</td>
+                            <td class="text-center">支付宝<span class="zz_title hide">自助</span></td>
                             <td id="zfbbs">0</td>
                             <td id="zfbsk">0.00</td>
                             <td id="zfbtfbs">0</td>
@@ -182,7 +182,7 @@
                             <td id="zfbss">0.00</td>
                         </tr>
                         <tr>
-                            <td class="text-center">微信</td>
+                            <td class="text-center">微信<span class="zz_title hide">自助</span></td>
                             <td id="wxbs">0</td>
                             <td id="wxsk">0.00</td>
                             <td id="wxtfbs">0</td>
@@ -286,7 +286,7 @@
                             <td id="ghsybkss">0.00</td>
                         </tr>
                         <tr>
-                            <td class="text-center">支付宝</td>
+                            <td class="text-center">支付宝<span class="zz_title hide">自助</span></td>
                             <td id="ghzfbbs">0</td>
                             <td id="ghzfbsk">0.00</td>
                             <td id="ghzfbtfbs">0</td>
@@ -295,7 +295,7 @@
                             <td id="ghzfbss">0.00</td>
                         </tr>
                         <tr>
-                            <td class="text-center">微信</td>
+                            <td class="text-center">微信<span class="zz_title hide">自助</span></td>
                             <td id="ghwxbs">0</td>
                             <td id="ghwxsk">0.00</td>
                             <td id="ghwxtfbs">0</td>

+ 50 - 16
src/main/resources/templates/daily_collect.html

@@ -63,11 +63,9 @@
             <div id="report_table" class="in"
                  style="width:920px;height:700px;margin:0 auto;border: 1px solid #337ab7;font-size: 16px;padding: 40px 20px 40px 20px;overflow-y: auto; overflow-x:hidden;">
                 <div id="report_table_1">
-                    <h2 style="text-align:center;font-weight: 700;">门诊收费收入日报表</h2>
-                    <div style="margin-top: 20px;">
-                        <span>收费员:</span><span id="username"></span><span
-                            style="margin-left: 120px;">工号:</span><span id="userIdCode"></span><span
-                            style="margin-left: 120px;">结账时间:</span><span id="dcountDate"></span></div>
+                    <h2 style="text-align:center;font-weight: 700;">泰和医院门诊收入汇总报表</h2>
+                    <div style="margin-top: 20px;"><span
+                            style="margin-left: 390px;">结账时间:</span><span id="dcountDate"></span></div>
                     <table class="table table-striped table-bordered">
                         <tbody>
                         <tr>
@@ -173,12 +171,12 @@
                         </tr>
                         <tr>
                             <td class="text-center">医保卡</td>
-                            <td id="ybjzbs">0</td>
-                            <td id="ybjzsk">0.00</td>
-                            <td id="ybjztfbs">0</td>
-                            <td id="ybjztf">0.00</td>
-                            <td id="ybjzssbs">0</td>
-                            <td id="ybjzss">0.00</td>
+                            <td id="sybbs">0</td>
+                            <td id="sybksk">0.00</td>
+                            <td id="sybtfbs">0</td>
+                            <td id="sybtf">0.00</td>
+                            <td id="sybssbs">0</td>
+                            <td id="sybkss">0.00</td>
                         </tr>
                         <tr>
                             <td class="text-center">支付宝</td>
@@ -198,6 +196,24 @@
                             <td id="wxssbs">0</td>
                             <td id="wxss">0.00</td>
                         </tr>
+                        <tr>
+                            <td class="text-center">支付宝自助</td>
+                            <td id="zfbzzbs">0</td>
+                            <td id="zfbzzsk">0.00</td>
+                            <td id="zfbzztfbs">0</td>
+                            <td id="zfbzztf">0.00</td>
+                            <td id="zfbzzssbs">0</td>
+                            <td id="zfbzzss">0.00</td>
+                        </tr>
+                        <tr>
+                            <td class="text-center">微信自助</td>
+                            <td id="wxzzbs">0</td>
+                            <td id="wxzzsk">0.00</td>
+                            <td id="wxzztfbs">0</td>
+                            <td id="wxzztf">0.00</td>
+                            <td id="wxzzssbs">0</td>
+                            <td id="wxzzss">0.00</td>
+                        </tr>
                         <tr>
                             <td class="text-center">医保卡记账</td>
                             <td id="ybkjzbs">0</td>
@@ -311,6 +327,24 @@
                             <td id="ghwxssbs">0</td>
                             <td id="ghwxss">0.00</td>
                         </tr>
+                        <tr>
+                            <td class="text-center">支付宝自助</td>
+                            <td id="ghzfbzzbs">0</td>
+                            <td id="ghzfbzzsk">0.00</td>
+                            <td id="ghzfbzztfbs">0</td>
+                            <td id="ghzfbzztf">0.00</td>
+                            <td id="ghzfbzzssbs">0</td>
+                            <td id="ghzfbzzss">0.00</td>
+                        </tr>
+                        <tr>
+                            <td class="text-center">微信自助</td>
+                            <td id="ghwxzzbs">0</td>
+                            <td id="ghwxzzsk">0.00</td>
+                            <td id="ghwxzztfbs">0</td>
+                            <td id="ghwxzztf">0.00</td>
+                            <td id="ghwxzzssbs">0</td>
+                            <td id="ghwxzzss">0.00</td>
+                        </tr>
                         <tr>
                             <td class="text-center">全免</td>
                             <td id="ghqmbs">0</td>
@@ -365,9 +399,9 @@
                         </tbody>
                     </table>
                 </div>
+                <div id="ghgzlhzb_title" style="display: none"><h2 style="text-align:center;font-weight: 700" >挂号工作量报表:</h2></div>
                 <div style="display:none;" id="ghgzlhzb_parent">
-                    <h2 style="text-align:center;font-weight: 700">挂号处工作量汇总报表</h2>
-                    <table class="table table-striped table-bordered">
+                    <table  class="table table-striped table-bordered">
                         <thead>
                         <tr>
                             <td>收款员</td>
@@ -383,9 +417,9 @@
                         </tbody>
                     </table>
                 </div>
+                <div id="sfgzlhzb_parent_title" style="display: none"><h2 style="text-align:center;font-weight: 700" >收款工作量报表:</h2></div>
                 <div style="display:none;" id="sfgzlhzb_parent">
-                    <h2 style="text-align:center;font-weight: 700">门诊收费结账单列表</h2>
-                    <table class="table table-striped table-bordered">
+                    <table  class="table table-striped table-bordered">
                         <thead>
                         <tr>
                             <td>收款员</td>
@@ -401,7 +435,7 @@
                         </tbody>
                     </table>
                 </div>
-                <div><span>制表人:</span><span style="text-decoration: underline" id="username_zbr"></span></div>
+                <!--<div id="username_zbr_parent"><span>制表人:</span><span style="text-decoration: underline" id="username_zbr"></span></div>-->
             </div>
             <table id="tb_table"></table>
         </div>

+ 4 - 4
src/main/resources/templates/daily_repeat_print.html

@@ -193,7 +193,7 @@
                             <td id="ybjzss">0.00</td>
                         </tr>
                         <tr>
-                            <td class="text-center">支付宝</td>
+                            <td class="text-center">支付宝<span class="zz_title hide">自助</span></td>
                             <td id="zfbbs">0</td>
                             <td id="zfbsk">0.00</td>
                             <td id="zfbtfbs">0</td>
@@ -202,7 +202,7 @@
                             <td id="zfbss">0.00</td>
                         </tr>
                         <tr>
-                            <td class="text-center">微信</td>
+                            <td class="text-center">微信<span class="zz_title hide">自助</span></td>
                             <td id="wxbs">0</td>
                             <td id="wxsk">0.00</td>
                             <td id="wxtfbs">0</td>
@@ -306,7 +306,7 @@
                             <td id="ghsybkss">0.00</td>
                         </tr>
                         <tr>
-                            <td class="text-center">支付宝</td>
+                            <td class="text-center">支付宝<span class="zz_title hide">自助</span></td>
                             <td id="ghzfbbs">0</td>
                             <td id="ghzfbsk">0.00</td>
                             <td id="ghzfbtfbs">0</td>
@@ -315,7 +315,7 @@
                             <td id="ghzfbss">0.00</td>
                         </tr>
                         <tr>
-                            <td class="text-center">微信</td>
+                            <td class="text-center">微信<span class="zz_title hide">自助</span></td>
                             <td id="ghwxbs">0</td>
                             <td id="ghwxsk">0.00</td>
                             <td id="ghwxtfbs">0</td>