Compare commits
No commits in common. "0440d9747982a22d2125189ca0f359424e7ee570" and "e6aee06884ecb8864ffeb951f11f7a12339ec4df" have entirely different histories.
0440d97479
...
e6aee06884
@ -6,7 +6,6 @@ import lombok.NoArgsConstructor;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@ -24,11 +23,4 @@ public class XmFee {
|
||||
private String attention;
|
||||
private String indication;
|
||||
private String affect;
|
||||
private Integer bgts;
|
||||
private String yblx;
|
||||
private String dept;
|
||||
private String lisgroup1;
|
||||
private String lisgroup2;
|
||||
private String lisgroup3;
|
||||
|
||||
}
|
||||
|
||||
@ -7,62 +7,57 @@ package com.czlis.common.enums;
|
||||
*/
|
||||
public enum BusinessType {
|
||||
/**
|
||||
* 其它O
|
||||
* 其它
|
||||
*/
|
||||
OTHER,
|
||||
|
||||
/**
|
||||
* 新增1
|
||||
* 新增
|
||||
*/
|
||||
INSERT,
|
||||
|
||||
/**
|
||||
* 修改2
|
||||
* 修改
|
||||
*/
|
||||
UPDATE,
|
||||
|
||||
/**
|
||||
* 删除3
|
||||
* 删除
|
||||
*/
|
||||
DELETE,
|
||||
|
||||
/**
|
||||
* 授权4
|
||||
* 授权
|
||||
*/
|
||||
GRANT,
|
||||
|
||||
/**
|
||||
* 导出5
|
||||
* 导出
|
||||
*/
|
||||
EXPORT,
|
||||
|
||||
/**
|
||||
* 导入6
|
||||
* 导入
|
||||
*/
|
||||
IMPORT,
|
||||
|
||||
/**
|
||||
* 强退7
|
||||
* 强退
|
||||
*/
|
||||
FORCE,
|
||||
|
||||
/**
|
||||
* 生成代码8
|
||||
* 生成代码
|
||||
*/
|
||||
GENCODE,
|
||||
|
||||
/**
|
||||
* 清空数据9
|
||||
* 清空数据
|
||||
*/
|
||||
CLEAN,
|
||||
|
||||
/**
|
||||
* 接口调用10
|
||||
* 接口调用
|
||||
*/
|
||||
INTERFACE_INVOKE,
|
||||
|
||||
/**
|
||||
* 删除明细11
|
||||
*/
|
||||
DELETE_DETAIL,
|
||||
}
|
||||
|
||||
@ -42,14 +42,15 @@ public class FeeitemClassController extends BaseController {
|
||||
|
||||
@ApiOperation("新增条码类别")
|
||||
@PostMapping("/add")
|
||||
public Result add(@RequestBody List<LabFeeitemClass> labFeeitemClassList){
|
||||
return feeitemClassService.add(labFeeitemClassList);
|
||||
public Result add(@RequestBody LabFeeitemClass labFeeitemClass){
|
||||
feeitemClassService.add(labFeeitemClass);
|
||||
return new Result("0","新增条码类别成功!");
|
||||
}
|
||||
|
||||
@ApiOperation("修改条码类别")
|
||||
@PostMapping("/update")
|
||||
public Result update(@RequestBody List<LabFeeitemClass> labFeeitemClassList){
|
||||
feeitemClassService.update(labFeeitemClassList);
|
||||
public Result update(@RequestBody LabFeeitemClass labFeeitemClass){
|
||||
feeitemClassService.update(labFeeitemClass);
|
||||
return new Result("0","修改条码成功!");
|
||||
}
|
||||
|
||||
|
||||
@ -1,11 +1,9 @@
|
||||
package com.czlis.mzcx.controller;
|
||||
|
||||
import com.czlis.common.annotation.Anonymous;
|
||||
import com.czlis.common.core.controller.BaseController;
|
||||
import com.czlis.common.core.domain.Result;
|
||||
import com.czlis.common.core.page.TableDataInfo;
|
||||
import com.czlis.common.core.domain.entity.lis.XmFee;
|
||||
import com.czlis.mzcx.pojo.XmFeeDTO;
|
||||
import com.czlis.mzcx.service.XmFeeService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
@ -31,30 +29,28 @@ public class XmFeeController extends BaseController {
|
||||
@GetMapping("/query")
|
||||
public TableDataInfo query(String sfxmdh,String yljg,String xmlb){
|
||||
startPage();
|
||||
List<XmFeeDTO> xmFeeList = xmFeeService.query(sfxmdh,yljg,xmlb);
|
||||
List<XmFee> xmFeeList = xmFeeService.query(sfxmdh,yljg,xmlb);
|
||||
return getDataTable(xmFeeList);
|
||||
}
|
||||
|
||||
@ApiOperation("新增收费项目")
|
||||
@PostMapping("/addXmfee")
|
||||
public Result addXmfee(@RequestBody List<XmFee> xmFeeList){
|
||||
log.info("新增收费项目:{}",xmFeeList);
|
||||
return xmFeeService.addXmFee(xmFeeList);
|
||||
public Result addXmfee(@RequestBody XmFee xmFee){
|
||||
xmFeeService.addXmFee(xmFee);
|
||||
return new Result("0","新增收费项目成功!");
|
||||
}
|
||||
|
||||
@ApiOperation("修改收费项目")
|
||||
@PostMapping("/update")
|
||||
public Result update(@RequestBody List<XmFee> xmFeeList){
|
||||
log.info("修改收费项目:{}",xmFeeList);
|
||||
xmFeeService.update(xmFeeList);
|
||||
public Result update(@RequestBody XmFee xmFee){
|
||||
xmFeeService.update(xmFee);
|
||||
return new Result("0","修改收费项目成功!");
|
||||
}
|
||||
|
||||
@ApiOperation("删除收费项目")
|
||||
@DeleteMapping("/del")
|
||||
public Result delete(String sfxmdh){
|
||||
log.info("删除收费项目:{}",sfxmdh);
|
||||
return xmFeeService.delete(sfxmdh);
|
||||
public Result delete(String sflbdh){
|
||||
return xmFeeService.delete(sflbdh);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -15,5 +15,4 @@ public interface RptgetRuleMapper {
|
||||
void delete(String bglqdh);
|
||||
void deleteDetail(String bglqdh, Integer xh);
|
||||
Long getLabRptgetRuleDetailCount(String bglqdh);
|
||||
Integer getMaxNo();
|
||||
}
|
||||
|
||||
@ -1,13 +1,12 @@
|
||||
package com.czlis.mzcx.mapper;
|
||||
|
||||
import com.czlis.common.core.domain.entity.lis.XmFee;
|
||||
import com.czlis.mzcx.pojo.XmFeeDTO;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface XmFeeMapper {
|
||||
List<XmFeeDTO> query(@Param("sfxmdh") String sfxmdh, @Param("yljg") String yljg, @Param("xmlb") String xmlb);
|
||||
List<XmFee> query(@Param("sfxmdh") String sfxmdh,@Param("yljg") String yljg,@Param("xmlb") String xmlb);
|
||||
|
||||
void add(XmFee xmFee);
|
||||
|
||||
|
||||
@ -1,35 +0,0 @@
|
||||
package com.czlis.mzcx.pojo;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
public class XmFeeDTO {
|
||||
private String sfxmdh;
|
||||
private String sfxmmc;
|
||||
private String xmlb;
|
||||
private BigDecimal dj;
|
||||
private String zjf;
|
||||
private String bz;
|
||||
private Integer bglqdh;
|
||||
private String spec;
|
||||
private String yljg;
|
||||
private String lisgroup;
|
||||
private String attention;
|
||||
private String indication;
|
||||
private String affect;
|
||||
private Integer bgts;
|
||||
private String yblx;
|
||||
private String dept;
|
||||
private String lisgroup1;
|
||||
private String lisgroup2;
|
||||
private String lisgroup3;
|
||||
private String sflbmc;
|
||||
private String bkcolor;
|
||||
private String sflbdh;
|
||||
}
|
||||
@ -8,9 +8,9 @@ import java.util.List;
|
||||
public interface FeeitemClassService {
|
||||
List<LabFeeitemClass> query(String sflbdh, String sflbmc);
|
||||
|
||||
Result add(List<LabFeeitemClass> labFeeitemClassList);
|
||||
void add(LabFeeitemClass labFeeitemClass);
|
||||
|
||||
void update(List<LabFeeitemClass> labFeeitemClassList);
|
||||
void update(LabFeeitemClass labFeeitemClass);
|
||||
|
||||
Result delete(String sflbdh);
|
||||
}
|
||||
|
||||
@ -2,16 +2,15 @@ package com.czlis.mzcx.service;
|
||||
|
||||
import com.czlis.common.core.domain.Result;
|
||||
import com.czlis.common.core.domain.entity.lis.XmFee;
|
||||
import com.czlis.mzcx.pojo.XmFeeDTO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
public interface XmFeeService {
|
||||
List<XmFeeDTO> query(String sfxmdh, String yljg, String xmlb);
|
||||
List<XmFee> query(String sfxmdh, String yljg, String xmlb);
|
||||
|
||||
Result addXmFee(List<XmFee> xmFeeList);
|
||||
void addXmFee(XmFee xmFee);
|
||||
|
||||
void update(List<XmFee> xmFeeList);
|
||||
void update(XmFee xmFee);
|
||||
|
||||
Result delete(String sfxmdh);
|
||||
}
|
||||
|
||||
@ -1,8 +1,6 @@
|
||||
package com.czlis.mzcx.service.impl;
|
||||
|
||||
import com.czlis.common.annotation.Log;
|
||||
import com.czlis.common.core.domain.Result;
|
||||
import com.czlis.common.enums.BusinessType;
|
||||
import com.czlis.mzcx.mapper.FeeitemClassMapper;
|
||||
import com.czlis.common.core.domain.entity.lis.LabFeeitemClass;
|
||||
import com.czlis.mzcx.service.FeeitemClassService;
|
||||
@ -31,28 +29,18 @@ public class FeeitemClassServiceImpl implements FeeitemClassService {
|
||||
return feeitemClassMapper.query(sflbdh, sflbmc);
|
||||
}
|
||||
|
||||
@Log(title = "条码类别",businessType = BusinessType.INSERT)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public Result add(List<LabFeeitemClass> labFeeitemClassList) {
|
||||
for (LabFeeitemClass labFeeitemClass : labFeeitemClassList) {
|
||||
List<LabFeeitemClass> existList = feeitemClassMapper.query(labFeeitemClass.getSflbdh(), "");
|
||||
if(existList.size()>0) return new Result("-1","条码类别代码:"+labFeeitemClass.getSflbdh()+"已存在!");
|
||||
public void add(LabFeeitemClass labFeeitemClass) {
|
||||
feeitemClassMapper.add(labFeeitemClass);
|
||||
}
|
||||
return new Result("0","新增条码类别成功!");
|
||||
}
|
||||
|
||||
@Log(title = "条码类别",businessType = BusinessType.UPDATE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public void update(List<LabFeeitemClass> labFeeitemClassList) {
|
||||
for (LabFeeitemClass labFeeitemClass : labFeeitemClassList) {
|
||||
public void update(LabFeeitemClass labFeeitemClass) {
|
||||
feeitemClassMapper.update(labFeeitemClass);
|
||||
}
|
||||
}
|
||||
|
||||
@Log(title = "条码类别",businessType = BusinessType.DELETE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public Result delete(String sflbdh) {
|
||||
|
||||
@ -1,8 +1,6 @@
|
||||
package com.czlis.mzcx.service.impl;
|
||||
|
||||
import com.czlis.common.annotation.Log;
|
||||
import com.czlis.common.core.domain.Result;
|
||||
import com.czlis.common.enums.BusinessType;
|
||||
import com.czlis.mzcx.mapper.RptgetRuleMapper;
|
||||
import com.czlis.common.core.domain.entity.lis.LabRptgetRule;
|
||||
import com.czlis.mzcx.pojo.LabRptgetRuleDTO;
|
||||
@ -35,13 +33,10 @@ public class RptgetRuleServiceImpl implements RptgetRuleService {
|
||||
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
@Log(title = "报告领取规则",businessType = BusinessType.INSERT)
|
||||
public Result add(LabRptgetRuleDTO labRptgetRuleDTO) {
|
||||
List<LabRptgetRule> ruleList = labRptgetRuleDTO.getRuleList();
|
||||
Integer maxNo = rptgetRuleMapper.getMaxNo();
|
||||
for (LabRptgetRule labRptgetRule : ruleList) {
|
||||
Integer bglqdh = maxNo++;
|
||||
labRptgetRule.setBglqdh(bglqdh);
|
||||
Integer bglqdh = labRptgetRule.getBglqdh();
|
||||
if(bglqdh == null || bglqdh == 0) return new Result("-1","报告列表中的报告领取代码不可以为空!");
|
||||
rptgetRuleMapper.insert(labRptgetRule);
|
||||
}
|
||||
@ -59,7 +54,6 @@ public class RptgetRuleServiceImpl implements RptgetRuleService {
|
||||
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
@Log(title = "报告领取规则",businessType = BusinessType.UPDATE)
|
||||
public Result update(LabRptgetRuleDTO labRptgetRuleDTO) {
|
||||
List<LabRptgetRule> ruleList = labRptgetRuleDTO.getRuleList();
|
||||
for (LabRptgetRule labRptgetRule : ruleList) {
|
||||
@ -78,7 +72,6 @@ public class RptgetRuleServiceImpl implements RptgetRuleService {
|
||||
}
|
||||
|
||||
@Override
|
||||
@Log(title = "报告领取规则",businessType = BusinessType.DELETE)
|
||||
public Result delete(String bglqdh) {
|
||||
Long labRptgetRuleDetailCount = rptgetRuleMapper.getLabRptgetRuleDetailCount(bglqdh);
|
||||
if(labRptgetRuleDetailCount > 0) return new Result("-1","存在报告领取规则明细数据,请先删除明细数据再删除列表数据!");
|
||||
@ -86,7 +79,6 @@ public class RptgetRuleServiceImpl implements RptgetRuleService {
|
||||
return new Result("0","删除报告领取规则列表成功!");
|
||||
}
|
||||
|
||||
@Log(title = "报告领取规则",businessType = BusinessType.DELETE_DETAIL)
|
||||
@Override
|
||||
public Result deleteDetail(String bglqdh, Integer xh) {
|
||||
rptgetRuleMapper.deleteDetail(bglqdh,xh);
|
||||
|
||||
@ -1,12 +1,8 @@
|
||||
package com.czlis.mzcx.service.impl;
|
||||
|
||||
import com.czlis.common.annotation.Anonymous;
|
||||
import com.czlis.common.annotation.Log;
|
||||
import com.czlis.common.core.domain.Result;
|
||||
import com.czlis.common.enums.BusinessType;
|
||||
import com.czlis.mzcx.mapper.XmFeeMapper;
|
||||
import com.czlis.common.core.domain.entity.lis.XmFee;
|
||||
import com.czlis.mzcx.pojo.XmFeeDTO;
|
||||
import com.czlis.mzcx.service.XmFeeService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@ -24,38 +20,28 @@ public class XmFeeServiceImpl implements XmFeeService {
|
||||
private XmFeeMapper xmFeeMapper;
|
||||
|
||||
@Override
|
||||
public List<XmFeeDTO> query(String sfxmdh, String yljg, String xmlb) {
|
||||
public List<XmFee> query(String sfxmdh, String yljg, String xmlb) {
|
||||
return xmFeeMapper.query(sfxmdh,yljg,xmlb);
|
||||
}
|
||||
|
||||
@Log(title = "收费项目维护",businessType = BusinessType.IMPORT)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public Result addXmFee(List<XmFee> xmFeeList) {
|
||||
for (XmFee xmFee : xmFeeList) {
|
||||
List<XmFeeDTO> existList = xmFeeMapper.query(xmFee.getSfxmdh(), xmFee.getYljg(), "");
|
||||
if(existList.size()>0) return new Result("-1","已经存在收费项目代码:"+xmFee.getSfxmdh()+"的项目!");
|
||||
public void addXmFee(XmFee xmFee) {
|
||||
xmFeeMapper.add(xmFee);
|
||||
}
|
||||
return new Result("0","添加成功!");
|
||||
}
|
||||
|
||||
@Log(title = "收费项目维护",businessType = BusinessType.UPDATE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public void update(List<XmFee> xmFeeList) {
|
||||
for (XmFee xmFee : xmFeeList) {
|
||||
public void update(XmFee xmFee) {
|
||||
xmFeeMapper.update(xmFee);
|
||||
}
|
||||
}
|
||||
|
||||
@Log(title = "收费项目维护",businessType = BusinessType.DELETE)
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public Result delete(String sfxmdh) {
|
||||
//后期再考虑增加删除限制判断
|
||||
//Long xmFeeVsCount = xmFeeMapper.getXmFeeVsCount(sfxmdh);
|
||||
//if(xmFeeVsCount > 0) return new Result("-1","有关联的收费项目代码,要先删掉关联的项目代码才能删掉对应的项目!");
|
||||
//这里需要补逻辑,如果有对应的收费项目,这里应该不能删,要先去掉对应的收费项目
|
||||
Long xmFeeVsCount = xmFeeMapper.getXmFeeVsCount(sfxmdh);
|
||||
if(xmFeeVsCount > 0) return new Result("-1","有关联的收费项目代码,要先删掉关联的项目代码才能删掉对应的项目!");
|
||||
xmFeeMapper.delete(sfxmdh);
|
||||
return new Result("0","删除收费项目代码成功!");
|
||||
}
|
||||
|
||||
@ -90,7 +90,4 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
select count(1) from lab_rptgetruledetail where bglqdh = #{bglqdh}
|
||||
</select>
|
||||
|
||||
<select id="getMaxNo" resultType="int">
|
||||
SELECT max(bglqdh) FROM lab_rptgetrule
|
||||
</select>
|
||||
</mapper>
|
||||
@ -3,19 +3,13 @@
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.czlis.mzcx.mapper.XmFeeMapper">
|
||||
<select id="query" resultType="com.czlis.mzcx.pojo.XmFeeDTO">
|
||||
select xm_Fee.*,
|
||||
lab_feeitemclass.sflbmc,
|
||||
lab_feeitemclass.bkcolor,
|
||||
lab_feeitemclass.sflbdh
|
||||
from xm_Fee left join lab_feeitem_vs_class on lab_feeitem_vs_class.sfxmdh=xm_fee.sfxmdh
|
||||
LEFT JOIN lab_feeitemclass ON lab_feeitem_vs_class.sflbdh=lab_feeitemclass.sflbdh
|
||||
<select id="query" resultType="com.czlis.common.core.domain.entity.lis.XmFee">
|
||||
select * from xm_Fee
|
||||
<where>
|
||||
<if test="sfxmdh != null and sfxmdh != ''"> and (xm_Fee.sfxmdh like '%'+#{sfxmdh}+'%' or xm_Fee.sfxmmc like '%'+#{sfxmdh}+'%')</if>
|
||||
<if test="yljg != null and yljg != ''"> and xm_Fee.yljg = #{yljg}</if>
|
||||
<if test="xmlb != null and xmlb != ''"> and xm_Fee.xmlb = #{xmlb}</if>
|
||||
<if test="sfxmdh != null and sfxmdh != ''"> and sfxmdh = #{sfxmdh}</if>
|
||||
<if test="yljg != null and yljg != ''"> and yljg = #{yljg}</if>
|
||||
<if test="xmlb != null and xmlb != ''"> and xmlb = #{xmlb}</if>
|
||||
</where>
|
||||
order by xm_Fee.sfxmdh
|
||||
</select>
|
||||
|
||||
<insert id="add" parameterType="com.czlis.common.core.domain.entity.lis.XmFee">
|
||||
@ -32,9 +26,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="attention != null and attention != ''">attention,</if>
|
||||
<if test="indication != null and indication != ''">indication,</if>
|
||||
<if test="affect != null and affect != ''">affect,</if>
|
||||
<if test="yblx != null and yblx != ''">yblx,</if>
|
||||
<if test="bgts != null">bgts,</if>
|
||||
<if test="dept != null and dept != ''"> dept,</if>
|
||||
sfxmdh
|
||||
)values (
|
||||
<if test="sfxmmc != null and sfxmmc != ''">#{sfxmmc},</if>
|
||||
@ -49,9 +40,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="attention != null and attention != ''">#{attention},</if>
|
||||
<if test="indication != null and indication != ''">#{indication},</if>
|
||||
<if test="affect != null and affect != ''">#{affect},</if>
|
||||
<if test="yblx != null and yblx != ''">#{yblx},</if>
|
||||
<if test="bgts != null">#{bgts},</if>
|
||||
<if test="dept != null and dept != ''"> #{dept},</if>
|
||||
#{sfxmdh}
|
||||
)
|
||||
</insert>
|
||||
@ -71,10 +59,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="attention != null and attention != ''">attention = #{attention},</if>
|
||||
<if test="indication != null and indication != ''">indication = #{indication},</if>
|
||||
<if test="affect != null and affect != ''">affect = #{affect},</if>
|
||||
<if test="yblx != null and yblx != ''">yblx = #{yblx},</if>
|
||||
<if test="bgts != null">bgts = #{bgts},</if>
|
||||
<if test="dept != null and dept != ''"> dept = #{dept},</if>
|
||||
sfxmdh = #{sfxmdh}
|
||||
#{sfxmdh}
|
||||
</set>
|
||||
where sfxmdh = #{sfxmdh}
|
||||
</update>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user