|
@@ -1,6 +1,7 @@
|
|
|
package thyyxxk.webserver.dao.his.medicalinsurance;
|
|
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
|
|
import com.baomidou.mybatisplus.core.toolkit.Constants;
|
|
|
import org.apache.ibatis.annotations.*;
|
|
|
import thyyxxk.webserver.entity.datamodify.GetDropdownBox;
|
|
@@ -10,6 +11,7 @@ import thyyxxk.webserver.entity.medicalinsurance.inpatient.BatjBa4;
|
|
|
import thyyxxk.webserver.entity.medicalinsurance.inpatient.YbZyDisDiag;
|
|
|
import thyyxxk.webserver.entity.medicalinsurance.inpatient.ZyDisDiagYb;
|
|
|
import thyyxxk.webserver.entity.medicalinsurance.inpatient.ZyInactpatient;
|
|
|
+import thyyxxk.webserver.entity.medicalinsurance.log.SiLog;
|
|
|
import thyyxxk.webserver.entity.medicalinsurance.setllistupld.*;
|
|
|
import thyyxxk.webserver.entity.querydata.SiSetlinfoTemp;
|
|
|
import thyyxxk.webserver.entity.querydata.TAutoUploadBill;
|
|
@@ -28,7 +30,7 @@ import java.util.Set;
|
|
|
* @date 2021-11-25 08:42
|
|
|
*/
|
|
|
@Mapper
|
|
|
-public interface UpIdCollectionDao {
|
|
|
+public interface UpIdCollectionDao extends BaseMapper<SetlinfoUpld> {
|
|
|
|
|
|
@Select("select count(1) from t_case_frontsheet_main where bah = #{patNo} " + " and admiss_times = #{times}")
|
|
|
Integer shiFouQianShou(@Param("patNo") String patNo, @Param("times") Integer times);
|
|
@@ -677,4 +679,165 @@ public interface UpIdCollectionDao {
|
|
|
List<TAutoUploadBill> exportAutoUploadInfo(@Param("startTime") String startTime,
|
|
|
@Param("endTime") String endTime);
|
|
|
|
|
|
+
|
|
|
+ @Select("select count(1)\n" +
|
|
|
+ "from t_si_setlinfo a,\n" +
|
|
|
+ " t_si_log b\n" +
|
|
|
+ "where (b.infno = '4101' and a.pat_no = b.pat_no and a.times = b.times and a.ledger_sn = b.ledger_sn)")
|
|
|
+ Integer 获取已经上传的数据总数();
|
|
|
+
|
|
|
+ @Select("select top ${pageSize} *\n" +
|
|
|
+ "from (select row_number() over (order by create_datetime) row_index, create_datetime, body, result\n" +
|
|
|
+ " from t_si_setlinfo a,\n" +
|
|
|
+ " t_si_log b\n" +
|
|
|
+ " where (b.infno = '4101' and a.pat_no = b.pat_no and a.times = b.times and a.ledger_sn = b.ledger_sn)) temp\n" +
|
|
|
+ "where row_index > (${currentPage} - 1) * ${pageSize}\n" +
|
|
|
+ "order by row_index")
|
|
|
+ List<SiLog> 获取上传的文件(int currentPage, int pageSize);
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 是否有上传结算单信息
|
|
|
+ *
|
|
|
+ * @param setlId
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ @Select("select max(setl_id) from t_settlement_setlinfo where setl_id = #{setlId}")
|
|
|
+ Integer whetherThereIsUploadInfo(String setlId);
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 根据setld 删除
|
|
|
+ *
|
|
|
+ * @param id
|
|
|
+ */
|
|
|
+ @Delete("delete t_settlement_diseinfo where setl_id = #{setlId};" +
|
|
|
+ "delete t_settlement_opspdiseinfo where setl_id = #{setlId};" +
|
|
|
+ "delete t_settlement_oprninfo where setl_id = #{setlId}; " +
|
|
|
+ "delete t_settlement_setlinfo where setl_id = #{setlId};" +
|
|
|
+ "delete t_settlement_icuinfo where setl_id = #{setlId};" +
|
|
|
+ "delete t_settlement_bldinfo where setl_id = #{setlId};" +
|
|
|
+ "delete t_settlement_payinfo where setl_id = #{setlId};" +
|
|
|
+ "delete t_settlement_iteminfo where setl_id = #{setlId};")
|
|
|
+ void deleteAccordingToSetlId(String id);
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 插入结算单诊断信息
|
|
|
+ *
|
|
|
+ * @param setlId id
|
|
|
+ * @param list 诊断数据
|
|
|
+ */
|
|
|
+ @Insert("<script>" +
|
|
|
+ "insert into t_settlement_diseinfo " +
|
|
|
+ "(setl_id, subscript, diag_type, diag_code, diag_name, adm_cond_type, maindiag_flag) " +
|
|
|
+ "values " +
|
|
|
+ "<foreach collection='list' item='item' index='index' separator=','>" +
|
|
|
+ "(#{setlId}, ${index} + 1, #{item.diagType}, #{item.diagCode}, #{item.diagName}, #{item.admCondType}, " +
|
|
|
+ "#{item.maindiagFlag})" +
|
|
|
+ "</foreach>" +
|
|
|
+ "</script>")
|
|
|
+ void insertStatementDiagnosisInfo(String setlId, List<DiseinfoUpld> list);
|
|
|
+
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 插入结算单基金支付信息
|
|
|
+ *
|
|
|
+ * @param setlId id
|
|
|
+ * @param list 基金支付信息
|
|
|
+ */
|
|
|
+ @Insert("<script>" +
|
|
|
+ "insert into t_settlement_payinfo (setl_id, subscript, fund_pay_type, fund_payamt) " +
|
|
|
+ " values " +
|
|
|
+ "<foreach collection='list' item='item' index='index' separator=','>" +
|
|
|
+ " (#{setlId},${index} + 1,#{item.fundPayType},#{item.fundPayamt}) " +
|
|
|
+ "</foreach>" +
|
|
|
+ "</script>")
|
|
|
+ void insertFundPaymentInfoOfStatement(String setlId, List<PayinfoUpld> list);
|
|
|
+
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 插入收费项目信息
|
|
|
+ *
|
|
|
+ * @param setlId id
|
|
|
+ * @param list 收费项目
|
|
|
+ */
|
|
|
+ @Insert("<script>" +
|
|
|
+ "insert into t_settlement_iteminfo (setl_id, subscript, med_chrgitm, amt, claa_sumfee, clab_amt, fulamt_ownpay_amt," +
|
|
|
+ " oth_amt)" +
|
|
|
+ "values " +
|
|
|
+ "<foreach collection='list' item='item' index='index' separator=','>" +
|
|
|
+ "(#{setlId},${index} + 1,#{item.medChrgitm},#{item.amt},#{item.claaSumfee},#{item.clabAmt},#{item.fulamtOwnpayAmt}," +
|
|
|
+ "#{item.othAmt})" +
|
|
|
+ "</foreach>" +
|
|
|
+ "</script>")
|
|
|
+ void insertChargingItemInfo(String setlId, List<IteminfoUpld> list);
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 插入门诊慢特病
|
|
|
+ *
|
|
|
+ * @param setlId id
|
|
|
+ * @param list 数据
|
|
|
+ */
|
|
|
+ @Insert("<script>" +
|
|
|
+ "insert into t_settlement_opspdiseinfo (setl_id, subscript, diag_name, diag_code, oprn_oprt_name, oprn_oprt_code," +
|
|
|
+ "maindiag_flag) " +
|
|
|
+ " values " +
|
|
|
+ "<foreach collection='list' item='item' index='index' separator=','>" +
|
|
|
+ "(#{setlId}, ${index} + 1, #{item.diagName}, #{item.diagCode}, #{item.oprnOprtName}, #{item.oprnOprtCode}," +
|
|
|
+ "#{item.maindiagFlag})" +
|
|
|
+ "</foreach>" +
|
|
|
+ "</script>")
|
|
|
+ void insertionOfOutpatientChronicDiseases(String setlId, List<OpspdiseinfoUpld> list);
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 插入手术操作信息
|
|
|
+ *
|
|
|
+ * @param setlId id
|
|
|
+ * @param list 数据
|
|
|
+ */
|
|
|
+ @Insert("<script>" +
|
|
|
+ "insert into t_settlement_oprninfo(setl_id, subscript, oprn_oprt_type, oprn_oprt_name, oprn_oprt_code," +
|
|
|
+ "oprn_oprt_date, " +
|
|
|
+ "anst_way, oper_dr_name, oper_dr_code, anst_dr_name, anst_dr_code, oprn_oprt_begntime,\n" +
|
|
|
+ "oprn_oprt_endtime, anst_begntime, anst_endtime)\n" +
|
|
|
+ "values " +
|
|
|
+ "<foreach collection='list' item='item' index='index' separator=','>" +
|
|
|
+ "(#{setlId},${index} + 1,#{item.oprnOprtType},#{item.oprnOprtName},#{item.oprnOprtCode}," +
|
|
|
+ "#{item.oprnOprtDate},#{item.anstWay},#{item.operDrName},#{item.operDrCode},#{item.anstDrName},#{item.anstDrCode}," +
|
|
|
+ "#{item.oprnOprtBegntime},#{item.oprnOprtEndtime},#{item.anstBegntime},#{item.anstEndtime})" +
|
|
|
+ "</foreach>" +
|
|
|
+ "</script>")
|
|
|
+ void insertSurgicalOperationInfo(String setlId, List<OprninfoUpld> list);
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 插入重症监护信息
|
|
|
+ *
|
|
|
+ * @param setlId id
|
|
|
+ * @param list 数据
|
|
|
+ */
|
|
|
+ @Insert("<script>" +
|
|
|
+ "insert into t_settlement_icuinfo (setl_id, subscript, scs_cutd_ward_type, scs_cutd_inpool_time, " +
|
|
|
+ "scs_cutd_exit_time,scs_cutd_sum_dura) " +
|
|
|
+ "values " +
|
|
|
+ "<foreach collection='list' item='item' index='index' separator=','>" +
|
|
|
+ "(#{setlId},${index} + 1,#{item.scsCutdWardType},#{item.scsCutdInpoolTime}," +
|
|
|
+ "#{item.scsCutdExitTime},#{item.scsCutdSumDura})" +
|
|
|
+ "</foreach>" +
|
|
|
+ "</script>")
|
|
|
+ void insertIntensiveCareInfor(String setlId, List<IcuinfoUpld> list);
|
|
|
+
|
|
|
+ /**
|
|
|
+ * 插入 输血信息
|
|
|
+ *
|
|
|
+ * @param setlId id
|
|
|
+ * @param list 数据
|
|
|
+ */
|
|
|
+ @Insert("<script>" +
|
|
|
+ "insert into t_settlement_bldinfo (setl_id, subscript, bld_cat, bld_amt, bld_unt) " +
|
|
|
+ " values " +
|
|
|
+ "<foreach collection='list' item='item' index='index' separator=','>" +
|
|
|
+ " (#{setlId},${index} + 1,#{item.bldCat},#{item.bldAmt},#{item.bldUnt})" +
|
|
|
+ "</foreach>" +
|
|
|
+ "</script>")
|
|
|
+ void insertTransfusionInfo(String setlId, List<Bldinfo> list);
|
|
|
+
|
|
|
+
|
|
|
}
|