|
|
@@ -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 > '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 > '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 > '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," +
|