|
@@ -173,6 +173,25 @@ public interface MzReceiptSerialMapper {
|
|
|
List<MzReceiptSerial> selectSerialForThisTime(@Param(value = "patientId") String patientId, @Param("times") Integer times, @Param("receiptNo") Integer receiptNo);
|
|
|
|
|
|
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 根据病人编号和就诊次数查询其当前就诊次数对应的真实发票
|
|
|
+ *
|
|
|
+ * @param patientId
|
|
|
+ * @param times
|
|
|
+ * @param receiptNo
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ @Select({"<script>",
|
|
|
+ "select rtrim(patient_id) patient_id,times,receipt_no,serial_no,rtrim(operator_id) operator_id,charge1,charge2,charge3,charge4,charge5,charge6,charge7,charge8,charge9,",
|
|
|
+ "charge10,charge11,charge12,charge13,charge14,charge15,charge16,charge17,charge18,charge19,charge20,rtrim(pay_mark) pay_mark,total_charge,charge_date,rtrim(receipt_bill) receipt_bill,",
|
|
|
+ "receipt_sn,dcount_date,rtrim(windows_no) windows_no,dcount_no,serial_yb,rtrim(fp_flag) fp_flag,rtrim(responce_type) responce_type,rtrim(cheque_type) cheque_type,cheque_no," +
|
|
|
+ "rtrim(tf_flag) tf_flag,dept_no,rtrim(pay_id) pay_id,charge_dcount_date,charge_dcount_no",
|
|
|
+ "from ${tableName} where patient_id=#{patientId,jdbcType=CHAR} and times = #{times,jdbcType=INTEGER} and receipt_no = #{receiptNo,jdbcType=INTEGER} and receipt_bill is not null",
|
|
|
+ "</script>"})
|
|
|
+ MzReceiptSerial selectReceiptBillForThisTime(@Param(value = "patientId") String patientId, @Param("times") Integer times, @Param("receiptNo") Short receiptNo,@Param(value = "tableName") String tableName);
|
|
|
+
|
|
|
+
|
|
|
/**
|
|
|
* 根据机制号查询发票信息
|
|
|
*
|
|
@@ -269,9 +288,9 @@ public interface MzReceiptSerialMapper {
|
|
|
"charge10,charge11,charge12,charge13,charge14,charge15,charge16,charge17,charge18,charge19,charge20,rtrim(pay_mark) pay_mark,total_charge,charge_date,rtrim(receipt_bill) receipt_bill,",
|
|
|
"receipt_sn,dcount_date,rtrim(windows_no) windows_no,dcount_no,serial_yb,rtrim(fp_flag) fp_flag,rtrim(responce_type) responce_type,rtrim(cheque_type) cheque_type,cheque_no," +
|
|
|
"rtrim(tf_flag) tf_flag,dept_no,rtrim(pay_id) pay_id,charge_dcount_date,charge_dcount_no",
|
|
|
- "from mz_receipt_serial where receipt_sn =#{receiptSn} and receipt_bill is not null and receipt_bill <![CDATA[<>]]> '' ",
|
|
|
+ "from ${tableName} where receipt_sn =#{receiptSn} and receipt_bill is not null and receipt_bill <![CDATA[<>]]> '' ",
|
|
|
"</script>"})
|
|
|
- MzReceiptSerial selectReceiptDetailsByReceiptSn(@Param(value = "receiptSn") Integer receiptSn);
|
|
|
+ MzReceiptSerial selectReceiptDetailsByReceiptSn(@Param(value = "receiptSn") Integer receiptSn,@Param("tableName") String tableName);
|
|
|
|
|
|
|
|
|
|