fix:系统编码做唯一校验

This commit is contained in:
zhangxuanming
2024-12-31 11:43:46 +08:00
parent 46121c05b6
commit 1f9350abc2
23 changed files with 137 additions and 4 deletions

View File

@@ -50,7 +50,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<include refid="selectCalPlanVo"/>
where plan_id = #{planId}
</select>
<select id="checkPlanCodeUnique" resultType="com.ktg.mes.cal.domain.CalPlan" resultMap="CalPlanResult">
<include refid="selectCalPlanVo"/>
where plan_code = #{planCode}
limit 1
</select>
<insert id="insertCalPlan" parameterType="CalPlan" useGeneratedKeys="true" keyProperty="planId">
insert into cal_plan
<trim prefix="(" suffix=")" suffixOverrides=",">

View File

@@ -37,7 +37,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<include refid="selectCalTeamVo"/>
where team_id = #{teamId}
</select>
<select id="checkTeamCodeUnique" resultType="com.ktg.mes.cal.domain.CalTeam" resultMap="CalTeamResult">
<include refid="selectCalTeamVo"/>
where team_code = #{teamCode}
limit 1
</select>
<insert id="insertCalTeam" parameterType="CalTeam" useGeneratedKeys="true" keyProperty="teamId">
insert into cal_team
<trim prefix="(" suffix=")" suffixOverrides=",">

View File

@@ -60,6 +60,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<include refid="selectDvMachineryVo"/>
where machinery_code= #{machineryCode}
</select>
<select id="checkRecptCodeUnique" resultType="com.ktg.mes.dv.domain.DvMachinery" resultMap="DvMachineryResult">
<include refid="selectDvMachineryVo"/>
where machinery_code = #{machineryCode}
limit 1
</select>
<insert id="insertDvMachinery" parameterType="DvMachinery" useGeneratedKeys="true" keyProperty="machineryId">
insert into dv_machinery

View File

@@ -74,6 +74,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
and pcp.workstation_id = #{workstationId}
order by pcp.input_time desc
</select>
<select id="checkCardCodeUnique" resultType="com.ktg.mes.pro.domain.ProCard" resultMap="ProCardResult">
<include refid="selectProCardVo"/>
where card_code = #{cardCode}
limit 1
</select>
<insert id="insertProCard" parameterType="ProCard" useGeneratedKeys="true" keyProperty="cardId">