|
@@ -323,18 +323,40 @@ public class XiangMuLuRuService {
|
|
|
}
|
|
|
|
|
|
|
|
|
+ @Data
|
|
|
+ public static class SearchMb {
|
|
|
+ private String searchName;
|
|
|
+ private long total = 0;
|
|
|
+ private long currentPage;
|
|
|
+ private long pageSize;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
/**
|
|
|
* 获取模板
|
|
|
*
|
|
|
- * @param deptCode 根据科室搜索
|
|
|
* @return 返回模板
|
|
|
*/
|
|
|
- public ResultVo<IPage<ZyDetailCharge>> getMuBan(String deptCode, long currentPage, long pageSize, long total) {
|
|
|
- IPage<ZyDetailCharge> page = new Page<>(currentPage, pageSize, total == 0);
|
|
|
+ public ResultVo<IPage<ZyDetailCharge>> getMuBan(SearchMb params) {
|
|
|
+ IPage<ZyDetailCharge> page = new Page<>(params.getCurrentPage(), params.getPageSize(), params.getTotal() == 0);
|
|
|
QueryWrapper<?> qw = new QueryWrapper<>();
|
|
|
+ UserInfo userInfo = userCache.getUserInfoByToken();
|
|
|
qw.ne("isnull(pattern_name,'')", "''");
|
|
|
if (publicServer.noNeedRule()) {
|
|
|
- qw.eq("op_dept", deptCode);
|
|
|
+ qw.eq("op_dept", userInfo.getDeptCode());
|
|
|
+ }
|
|
|
+ if (StrUtil.isNotBlank(params.getSearchName())) {
|
|
|
+ qw.and(
|
|
|
+ queryWrapper -> {
|
|
|
+ queryWrapper.like("pattern_name", params.getSearchName())
|
|
|
+ .or()
|
|
|
+ .like("py_code", params.getSearchName().toUpperCase())
|
|
|
+ .or()
|
|
|
+ .like("d_code", params.getSearchName().toUpperCase())
|
|
|
+
|
|
|
+ ;
|
|
|
+ }
|
|
|
+ );
|
|
|
}
|
|
|
dao.getMuBan(page, qw);
|
|
|
return ResultVoUtil.success(page);
|
|
@@ -376,11 +398,11 @@ public class XiangMuLuRuService {
|
|
|
* @param xiangMuHuoYaoPinFlag 判断是查询项目还是药品 0 - 项目 1- 药品
|
|
|
* @return 返回项目
|
|
|
*/
|
|
|
- public ResultVo<List<ZyDetailCharge>> queryXiangMu(String pyCode, Integer xiangMuHuoYaoPinFlag) {
|
|
|
+ public ResultVo<List<ZyDetailCharge>> queryXiangMu(String pyCode, Integer xiangMuHuoYaoPinFlag, String yfType) {
|
|
|
if (xiangMuHuoYaoPinFlag == 0) {
|
|
|
return ResultVoUtil.success(dao.queryXiangMu("%" + pyCode.toUpperCase() + "%"));
|
|
|
}
|
|
|
- return ResultVoUtil.success(dao.queryYaoPin("%" + pyCode.toUpperCase() + "%"));
|
|
|
+ return ResultVoUtil.success(dao.queryYaoPin("%" + pyCode.toUpperCase() + "%", yfType));
|
|
|
}
|
|
|
|
|
|
/**
|
|
@@ -506,10 +528,13 @@ public class XiangMuLuRuService {
|
|
|
if (zyDetailCharge.getSelfFlag() == null) {
|
|
|
zyDetailCharge.setSelfFlag("0");
|
|
|
}
|
|
|
+ if (StrUtil.isBlank(zyDetailCharge.getGroupNo())) {
|
|
|
+ zyDetailCharge.setGroupNo("73");
|
|
|
+ }
|
|
|
}
|
|
|
Integer ledgerSn = publicServer.getLedgerSn(param.getInpatientNo(), param.getAdmissTimes());
|
|
|
// 在此处 插入费用
|
|
|
- dao. chaRuFeiYong(param, param.getList(),
|
|
|
+ dao.chaRuFeiYong(param, param.getList(),
|
|
|
infantFlag,
|
|
|
ledgerSn,
|
|
|
DateUtil.formatDatetime(param.getChargeDate(),
|