|
@@ -53,7 +53,7 @@ public interface TransferInOfExpensesDao {
|
|
|
@Select("select " +
|
|
|
" patient_name =rtrim(a.name), " +
|
|
|
" item_name = c.name, " +
|
|
|
- " charge_amount = a.quantity, " +
|
|
|
+ " a.quantity , " +
|
|
|
" self_flag=c.self_flag, " +
|
|
|
" separate_flag = c.separate_flag, " +
|
|
|
" suppress_flag = c.suppress_flag, " +
|
|
@@ -61,13 +61,13 @@ public interface TransferInOfExpensesDao {
|
|
|
" charge_code_mx = a.charge_item_code, " +
|
|
|
" serial = a.serial, " +
|
|
|
" group_no = a.group_no, " +
|
|
|
- " price = a.unit_price, " +
|
|
|
- " charge_fee=a.unit_price * a.quantity * isnull(a.drug_win,1), " +
|
|
|
+ " a.unit_price, " +
|
|
|
" check_flag='0', " +
|
|
|
" warn_dept =a.warn_dept, " +
|
|
|
" doctor_code = a.doctor_code, " +
|
|
|
" bill_item_code = rtrim(a.bill_item_code), " +
|
|
|
- " exec_dept = a.exec_dept " +
|
|
|
+ " exec_dept = a.exec_dept," +
|
|
|
+ " a.drug_win " +
|
|
|
"from ${mzTableName} a,${tableName} b,zd_charge_item c " +
|
|
|
"where a.patient_id = b.patient_id and " +
|
|
|
" a.times = b.times and " +
|
|
@@ -79,7 +79,7 @@ public interface TransferInOfExpensesDao {
|
|
|
"union all " +
|
|
|
"select patient_name =rtrim(a.name), " +
|
|
|
" item_name = (select name from yp_zd_dict where yp_zd_dict.code=c.charge_code and yp_zd_dict.serial=c.serial),/*c.drugname,*/ " +
|
|
|
- " charge_amount = a.quantity, " +
|
|
|
+ " a.quantity, " +
|
|
|
" self_flag=a.self_flag, " +
|
|
|
" separate_flag = (select separate_flag from yp_zd_dict where yp_zd_dict.code=c.charge_code and yp_zd_dict.serial=c.serial), " +
|
|
|
" suppress_flag = (select suprice_flag from yp_zd_dict where yp_zd_dict.code=c.charge_code and yp_zd_dict.serial=c.serial), " +
|
|
@@ -87,13 +87,13 @@ public interface TransferInOfExpensesDao {
|
|
|
" charge_code_mx = a.charge_item_code, " +
|
|
|
" serial = a.serial, " +
|
|
|
" group_no = a.group_no, " +
|
|
|
- " price = a.unit_price, " +
|
|
|
- " charge_fee= Convert(decimal(18,2),a.unit_price * a.quantity * isnull(a.drug_win,1)) , " +
|
|
|
+ " a.unit_price, " +
|
|
|
" check_flag='0', " +
|
|
|
" warn_dept =a.warn_dept, " +
|
|
|
" doctor_code = a.doctor_code, " +
|
|
|
" bill_item_code = rtrim(a.bill_item_code), " +
|
|
|
- " exec_dept = a.exec_dept " +
|
|
|
+ " exec_dept = a.exec_dept," +
|
|
|
+ " a.drug_win " +
|
|
|
"from ${mzTableName} a,${tableName} b,yp_base_yf c " +
|
|
|
"where a.patient_id = b.patient_id and " +
|
|
|
" a.times = b.times and " +
|
|
@@ -184,7 +184,7 @@ public interface TransferInOfExpensesDao {
|
|
|
"gen_time,charge_code_mx,serial,doctor_code,trans_flag_yb,refer_physician,consult_physician,exec_unit,zy_serial_no) VALUES " +
|
|
|
"<foreach collection='list' item='fee' separator=',' open='' close=''>" +
|
|
|
"(#{info.inpatientNo}, #{info.admissTimes}, #{info.ledgerSn}, #{fee.detailSn}, #{info.chargeDate}, #{info.staffId}, " +
|
|
|
- "#{fee.chargeCode}, 0, 2, #{fee.chargeAmount}, cast(#{fee.chargeFee,jdbcType=DECIMAL} as decimal(14,5)), #{info.zkWard}, #{info.dept}, 6, " +
|
|
|
+ "#{fee.chargeCode}, 0, 2, #{fee.chargeQuantity}, cast(#{fee.chargeFee,jdbcType=DECIMAL} as decimal(14,5)), #{info.zkWard}, #{info.dept}, 6, " +
|
|
|
"'',#{info.chargeDate}, #{fee.chargeCodeMx},#{fee.serial},#{fee.doctorCode},0,#{info.referPhysician}," +
|
|
|
"#{info.consultPhysician},#{info.execUnit},#{info.zySerialNo})" +
|
|
|
"</foreach>" +
|