|
@@ -4,6 +4,7 @@ import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
|
|
import org.apache.ibatis.annotations.*;
|
|
|
import thyyxxk.webserver.entity.casefrontsheet.JieShouHuiZhenPojo;
|
|
|
+import thyyxxk.webserver.entity.executeItem.YzZyPatientFee;
|
|
|
import thyyxxk.webserver.entity.datamodify.YzActOrder;
|
|
|
|
|
|
import java.math.BigDecimal;
|
|
@@ -40,7 +41,7 @@ public interface JieShouHuiZhenDao {
|
|
|
@Select("SELECT order_code FROM zd_emp_title where code = #{code} ")
|
|
|
String getOrderCodeByEmpTit(String code);
|
|
|
|
|
|
- @Select("select a.inpatient_no, " +
|
|
|
+ @Select("select rtrim(a.inpatient_no) inpatient_no , " +
|
|
|
" b.admiss_date, " +
|
|
|
" rtrim(name) name, " +
|
|
|
" bed_no, " +
|
|
@@ -94,10 +95,17 @@ public interface JieShouHuiZhenDao {
|
|
|
@Select("select name from zd_unit_code with(nolock) where code = #{deptCode}")
|
|
|
String getDeptName(String deptCode);
|
|
|
|
|
|
-// @Insert("insert into zy_detail_charge (inpatient_no, admiss_times, ledger_sn, detail_sn, charge_code, op_id_code, charge_code,\n" +
|
|
|
-// " infant_flag, charge_status, charge_amount, charge_fee, ward_code, dept_code, order_no,\n" +
|
|
|
-// " ope_flag, exec_unit, gen_time, charge_code_mx, serial, doctor_code, trans_flag_yb,\n" +
|
|
|
-// " refer_physician)\n" +
|
|
|
-// "values (#{yz.inpatientNo},#{yz.admissTimes} , #{} ),")
|
|
|
-// void insertFees(YzActOrder yz);
|
|
|
+ @Select("select top 1 occ_code\n" +
|
|
|
+ "from yz_order_occurence\n" +
|
|
|
+ "where order_code = '${orderCode}';")
|
|
|
+ String getOccCode(String orderCode);
|
|
|
+
|
|
|
+ @Insert("insert into yz_zy_patient_fee (inpatient_no, admiss_times, ledger_sn, detail_sn, charge_date, op_id_code, charge_code,\n" +
|
|
|
+ " infant_flag, charge_status, charge_fee, occ_time, act_order_no, dept_code, ward_code,\n" +
|
|
|
+ " order_count, exec_unit)\n" +
|
|
|
+ "values (#{inpatientNo}, #{admissTimes}, NULL, 0, #{chargeDate}, #{opIdCode}, #{chargeCode},\n" +
|
|
|
+ " #{infantflag, '1', (SELECT charge_amount FROM zd_charge_item where code = '${chargeCode}'), getdate(), #{actOrderNo},\n" +
|
|
|
+ " #{deptCode}, #{deptCode},\n" +
|
|
|
+ " 1, #{execUnit}})")
|
|
|
+ void insertYzZyPatientFee(YzZyPatientFee fee);
|
|
|
}
|