添加 产品,质检项目,不合格原因,报废原因的 禁用启用方法;id序列化
| | |
| | | */ |
| | | @Mapper |
| | | public interface PltProductQualityInspectionItemsMapper { |
| | | |
| | | int deleteByPrimaryKey(Long id); |
| | | |
| | | int insert(PltProductQualityInspectionItems record); |
| | | |
| | | int insertSelective(PltProductQualityInspectionItems record); |
| | | |
| | | PltProductQualityInspectionItems selectByPrimaryKey(Long id); |
| | | |
| | | int updateByPrimaryKeySelective(PltProductQualityInspectionItems record); |
| | | |
| | | int updateByPrimaryKey(PltProductQualityInspectionItems record); |
| | | |
| | | Long selectSomeCount(Map<String,Object> params); |
| | | |
| | |
| | | @Mapper |
| | | public interface PltProductScrappingReasonMapper { |
| | | |
| | | int deleteByPrimaryKey(Long id); |
| | | |
| | | int insert(PltProductScrappingReason record); |
| | | |
| | | int insertSelective(PltProductScrappingReason record); |
| | | |
| | | PltProductScrappingReason selectByPrimaryKey(Long id); |
| | | |
| | | int updateByPrimaryKeySelective(PltProductScrappingReason record); |
| | | |
| | | int updateByPrimaryKey(PltProductScrappingReason record); |
| | | |
| | | Long selectSomeCount(Map<String,Object> params); |
| | | |
| | |
| | | @Mapper |
| | | public interface PltProductUnqualifiedReasonMapper { |
| | | |
| | | int deleteByPrimaryKey(Long id); |
| | | |
| | | int insert(PltProductUnqualifiedReason record); |
| | | |
| | | int insertSelective(PltProductUnqualifiedReason record); |
| | | |
| | | PltProductUnqualifiedReason selectByPrimaryKey(Long id); |
| | | |
| | | int updateByPrimaryKeySelective(PltProductUnqualifiedReason record); |
| | | |
| | | int updateByPrimaryKey(PltProductUnqualifiedReason record); |
| | | |
| | | Long selectSomeCount(Map<String,Object> params); |
| | | |
| | | List<PltProductUnqualifiedReason> selectSome(Map<String,Object> params); |
| | | |
| | | int deleteLogicById(Long id); |
| | | |
| | | } |
| | |
| | | package com.dy.pmsGlobal.pojoPlt; |
| | | |
| | | import com.alibaba.fastjson2.annotation.JSONField; |
| | | import com.alibaba.fastjson2.writer.ObjectWriterImplToString; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | |
| | | /** |
| | | * 编号 |
| | | */ |
| | | @JSONField(serializeUsing= ObjectWriterImplToString.class) |
| | | @TableId(type = IdType.AUTO) |
| | | public Integer id; |
| | | |
| | |
| | | package com.dy.pmsGlobal.pojoPlt; |
| | | |
| | | import com.alibaba.fastjson2.annotation.JSONField; |
| | | import com.alibaba.fastjson2.writer.ObjectWriterImplToString; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | |
| | | /** |
| | | * |
| | | */ |
| | | @JSONField(serializeUsing= ObjectWriterImplToString.class) |
| | | @TableId(type = IdType.AUTO) |
| | | public Long id; |
| | | |
| | |
| | | */ |
| | | @NotEmpty(message = "品检项目不能为空") |
| | | public String item; |
| | | |
| | | /** |
| | | * 是否禁用,1是,0否 |
| | | */ |
| | | public Boolean disabled; |
| | | /** |
| | | * 是否删除,1是,0否 |
| | | */ |
| | |
| | | package com.dy.pmsGlobal.pojoPlt; |
| | | |
| | | import com.alibaba.fastjson2.annotation.JSONField; |
| | | import com.alibaba.fastjson2.writer.ObjectWriterImplToString; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | |
| | | /** |
| | | * |
| | | */ |
| | | @JSONField(serializeUsing= ObjectWriterImplToString.class) |
| | | @TableId(type = IdType.AUTO) |
| | | public Long id; |
| | | |
| | | /** |
| | | * 产品实体编号 |
| | | */ |
| | | // @NotNull(message = "产品实体编号不能为空") |
| | | public Long proId; |
| | | |
| | | /** |
| | | * 产品名称 |
| | | */ |
| | | @TableField(exist = false) |
| | | public String proName; |
| | | |
| | | /** |
| | | * 报废原因 |
| | |
| | | public String reason; |
| | | |
| | | /** |
| | | * 是否禁用,1是,0否 |
| | | */ |
| | | public Boolean disabled; |
| | | /** |
| | | * 是否删除,1是,0否 |
| | | */ |
| | | public Boolean deleted; |
| | |
| | | package com.dy.pmsGlobal.pojoPlt; |
| | | |
| | | import com.alibaba.fastjson2.annotation.JSONField; |
| | | import com.alibaba.fastjson2.writer.ObjectWriterImplToString; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableField; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | |
| | | /** |
| | | * |
| | | */ |
| | | @JSONField(serializeUsing= ObjectWriterImplToString.class) |
| | | @TableId(type = IdType.AUTO) |
| | | public Long id; |
| | | |
| | | /** |
| | | * 产品实体编号 |
| | | */ |
| | | // @NotNull(message = "产品实体编号不能为空") |
| | | public Long proId; |
| | | /** |
| | | * 产品名称 |
| | | */ |
| | | @TableField(exist = false) |
| | | public String proName; |
| | | |
| | | /** |
| | | * 不合格原因 |
| | |
| | | public String reason; |
| | | |
| | | /** |
| | | * 是否禁用,1是,0否 |
| | | */ |
| | | public Boolean disabled; |
| | | /** |
| | | * 是否删除,1是,0否 |
| | | */ |
| | | public Boolean deleted; |
| | |
| | | package com.dy.pmsGlobal.pojoPlt; |
| | | |
| | | import com.alibaba.fastjson2.annotation.JSONField; |
| | | import com.alibaba.fastjson2.writer.ObjectWriterImplToString; |
| | | import com.baomidou.mybatisplus.annotation.IdType; |
| | | import com.baomidou.mybatisplus.annotation.TableId; |
| | | import com.baomidou.mybatisplus.annotation.TableName; |
| | |
| | | /** |
| | | * |
| | | */ |
| | | @JSONField(serializeUsing= ObjectWriterImplToString.class) |
| | | @TableId(type = IdType.AUTO) |
| | | public Long id; |
| | | |
| | |
| | | package com.dy.pmsGlobal.pojoPlt; |
| | | |
| | | import com.alibaba.fastjson2.annotation.JSONField; |
| | | import com.alibaba.fastjson2.writer.ObjectWriterImplToString; |
| | | import com.baomidou.mybatisplus.annotation.*; |
| | | import com.dy.common.po.BaseEntity; |
| | | import com.fasterxml.jackson.annotation.JsonFormat; |
| | |
| | | /** |
| | | * |
| | | */ |
| | | @JSONField(serializeUsing= ObjectWriterImplToString.class) |
| | | @TableId(type = IdType.AUTO) |
| | | public Long id; |
| | | |
| | |
| | | public Date dt; |
| | | |
| | | /** |
| | | * 是否禁用,1是,0否 |
| | | */ |
| | | public Boolean disabled; |
| | | /** |
| | | * 是否删除,1是,0否 |
| | | */ |
| | | public Boolean deleted; |
| | |
| | | <id property="id" column="id" jdbcType="BIGINT"/> |
| | | <result property="proId" column="pro_id" jdbcType="BIGINT"/> |
| | | <result property="item" column="item" jdbcType="VARCHAR"/> |
| | | <result property="deleted" column="deleted" jdbcType="TINYINT"/> |
| | | <result column="disabled" property="disabled" typeHandler="com.dy.common.mybatis.BooleanTypeHandler"/> |
| | | <result property="deleted" column="deleted" typeHandler="com.dy.common.mybatis.BooleanTypeHandler"/> |
| | | <association property="proName" column="pro_id" javaType="java.lang.Long" |
| | | select="selectProNameById" fetchType="eager" /> |
| | | </resultMap> |
| | | |
| | | <sql id="Base_Column_List"> |
| | | id,pro_id,item, |
| | | id,pro_id,item,disabled, |
| | | deleted |
| | | </sql> |
| | | <sql id="part_Column_List"> |
| | | ${alias}.id, |
| | | ${alias}.pro_id, |
| | | ${alias}.item, |
| | | ${alias}.disabled, |
| | | ${alias}.deleted |
| | | </sql> |
| | | <select id="selectProNameById" parameterType="java.lang.Long" resultType="java.lang.String"> |
| | |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </select> |
| | | |
| | | <delete id="deleteByPrimaryKey" parameterType="java.lang.Long"> |
| | | delete from plt_product_quality_inspection_items |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </delete> |
| | | <insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductQualityInspectionItems" useGeneratedKeys="true"> |
| | | insert into plt_product_quality_inspection_items |
| | | ( id,pro_id,item |
| | | ,deleted) |
| | | values (#{id,jdbcType=BIGINT},#{proId,jdbcType=BIGINT},#{item,jdbcType=VARCHAR} |
| | | ,#{deleted,jdbcType=TINYINT}) |
| | | </insert> |
| | | <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductQualityInspectionItems" useGeneratedKeys="true"> |
| | | insert into plt_product_quality_inspection_items |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">id,</if> |
| | | <if test="proId != null">pro_id,</if> |
| | | <if test="item != null">item,</if> |
| | | <if test="disabled != null">disabled,</if> |
| | | <if test="deleted != null">deleted,</if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">#{id,jdbcType=BIGINT},</if> |
| | | <if test="proId != null">#{proId,jdbcType=BIGINT},</if> |
| | | <if test="item != null">#{item,jdbcType=VARCHAR},</if> |
| | | <if test="disabled != null">#{disabled,jdbcType=TINYINT},</if> |
| | | <if test="deleted != null">#{deleted,jdbcType=TINYINT},</if> |
| | | </trim> |
| | | </insert> |
| | | <update id="updateByPrimaryKeySelective" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductQualityInspectionItems"> |
| | | update plt_product_quality_inspection_items |
| | | <set> |
| | | <if test="proId != null"> |
| | | pro_id = #{proId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="item != null"> |
| | | item = #{item,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="deleted != null"> |
| | | deleted = #{deleted,jdbcType=TINYINT}, |
| | | </if> |
| | | <if test="proId != null"> |
| | | pro_id = #{proId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="disabled != null"> |
| | | disabled = #{disabled,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="item != null"> |
| | | item = #{item,jdbcType=VARCHAR}, |
| | | </if> |
| | | </set> |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | <update id="updateByPrimaryKey" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductQualityInspectionItems"> |
| | | update plt_product_quality_inspection_items |
| | | set |
| | | pro_id = #{proId,jdbcType=BIGINT}, |
| | | item = #{item,jdbcType=VARCHAR}, |
| | | deleted = #{deleted,jdbcType=TINYINT} |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | |
| | |
| | | |
| | | <resultMap id="BaseResultMap" type="com.dy.pmsGlobal.pojoPlt.PltProductScrappingReason"> |
| | | <id property="id" column="id" jdbcType="BIGINT"/> |
| | | <result property="proId" column="pro_id" jdbcType="BIGINT"/> |
| | | <result property="reason" column="reason" jdbcType="VARCHAR"/> |
| | | <result property="deleted" column="deleted" jdbcType="TINYINT"/> |
| | | <association property="proName" column="pro_id" javaType="java.lang.Long" |
| | | select="selectProNameById" fetchType="eager" /> |
| | | <result column="disabled" property="disabled" typeHandler="com.dy.common.mybatis.BooleanTypeHandler"/> |
| | | <result property="deleted" column="deleted" typeHandler="com.dy.common.mybatis.BooleanTypeHandler"/> |
| | | </resultMap> |
| | | |
| | | <sql id="Base_Column_List"> |
| | | id,pro_id,reason, |
| | | id,reason,disabled, |
| | | deleted |
| | | </sql> |
| | | <sql id="part_Column_List"> |
| | | ${alias}.id, |
| | | ${alias}.pro_id, |
| | | ${alias}.reason, |
| | | ${alias}.deleted |
| | | ${alias}.deleted, |
| | | ${alias}.disabled |
| | | </sql> |
| | | <select id="selectProNameById" parameterType="java.lang.Long" resultType="java.lang.String"> |
| | | select name proName from plt_product where id=#{id} |
| | | </select> |
| | | |
| | | <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap"> |
| | | select |
| | | <include refid="Base_Column_List" /> |
| | |
| | | insert into plt_product_scrapping_reason |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">id,</if> |
| | | <if test="proId != null">pro_id,</if> |
| | | <if test="reason != null">reason,</if> |
| | | <if test="deleted != null">deleted,</if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">#{id,jdbcType=BIGINT},</if> |
| | | <if test="proId != null">#{proId,jdbcType=BIGINT},</if> |
| | | <if test="reason != null">#{reason,jdbcType=VARCHAR},</if> |
| | | <if test="deleted != null">#{deleted,jdbcType=TINYINT},</if> |
| | | </trim> |
| | |
| | | <update id="updateByPrimaryKeySelective" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductScrappingReason"> |
| | | update plt_product_scrapping_reason |
| | | <set> |
| | | <if test="proId != null"> |
| | | pro_id = #{proId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="reason != null"> |
| | | reason = #{reason,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="deleted != null"> |
| | | deleted = #{deleted,jdbcType=TINYINT}, |
| | | </if> |
| | | <if test="reason != null"> |
| | | reason = #{reason,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="disabled != null"> |
| | | disabled = #{disabled,jdbcType=TINYINT}, |
| | | </if> |
| | | <if test="deleted != null"> |
| | | deleted = #{deleted,jdbcType=TINYINT}, |
| | | </if> |
| | | </set> |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | <update id="updateByPrimaryKey" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductScrappingReason"> |
| | | update plt_product_scrapping_reason |
| | | set |
| | | pro_id = #{proId,jdbcType=BIGINT}, |
| | | reason = #{reason,jdbcType=VARCHAR}, |
| | | deleted = #{deleted,jdbcType=TINYINT} |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | <!-- <update id="updateByPrimaryKey" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductScrappingReason">--> |
| | | <!-- update plt_product_scrapping_reason--> |
| | | <!-- set --> |
| | | <!-- pro_id = #{proId,jdbcType=BIGINT},--> |
| | | <!-- reason = #{reason,jdbcType=VARCHAR},--> |
| | | <!-- deleted = #{deleted,jdbcType=TINYINT}--> |
| | | <!-- where id = #{id,jdbcType=BIGINT} --> |
| | | <!-- </update>--> |
| | | |
| | | <select id="selectSome" resultMap="BaseResultMap"> |
| | | select |
| | |
| | | <property name="alias" value="t"/> |
| | | </include> |
| | | from plt_product_scrapping_reason t |
| | | inner join plt_product p on t.pro_id = p.id |
| | | where t.deleted!=1 |
| | | <trim prefix="and" suffixOverrides="and"> |
| | | <if test="proName != null and proName != ''"> |
| | | p.name like concat('%', #{proName}, '%') and |
| | | </if> |
| | | <if test="reason != null and reason != ''"> |
| | | t.reason like concat('%', #{reason}, '%') and |
| | | </if> |
| | |
| | | <select id="selectSomeCount" resultType="java.lang.Long"> |
| | | select count(1) |
| | | from plt_product_scrapping_reason t |
| | | inner join plt_product p on t.pro_id = p.id |
| | | where t.deleted!=1 |
| | | <trim prefix="and" suffixOverrides="and"> |
| | | <if test="proName != null and proName != ''"> |
| | | p.name like concat('%', #{proName}, '%') and |
| | | </if> |
| | | <if test="reason != null and reason != ''"> |
| | | t.reason like concat('%', #{reason}, '%') and |
| | | </if> |
| | |
| | | |
| | | <resultMap id="BaseResultMap" type="com.dy.pmsGlobal.pojoPlt.PltProductUnqualifiedReason"> |
| | | <id property="id" column="id" jdbcType="BIGINT"/> |
| | | <result property="proId" column="pro_id" jdbcType="BIGINT"/> |
| | | <result property="reason" column="reason" jdbcType="VARCHAR"/> |
| | | <result property="deleted" column="deleted" jdbcType="TINYINT"/> |
| | | <association property="proName" column="pro_id" javaType="java.lang.Long" |
| | | select="selectProNameById" fetchType="eager" /> |
| | | <result column="disabled" property="disabled" typeHandler="com.dy.common.mybatis.BooleanTypeHandler"/> |
| | | <result property="deleted" column="deleted" typeHandler="com.dy.common.mybatis.BooleanTypeHandler"/> |
| | | </resultMap> |
| | | |
| | | <sql id="Base_Column_List"> |
| | | id,pro_id,reason, |
| | | id,pro_id,reason,disabled, |
| | | deleted |
| | | </sql> |
| | | <sql id="part_Column_List"> |
| | | ${alias}.id, |
| | | ${alias}.pro_id, |
| | | ${alias}.reason, |
| | | ${alias}.deleted |
| | | </sql> |
| | | <select id="selectProNameById" parameterType="java.lang.Long" resultType="java.lang.String"> |
| | | select name proName from plt_product where id=#{id} |
| | | </select> |
| | | <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap"> |
| | | select |
| | | <include refid="Base_Column_List" /> |
| | |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </select> |
| | | |
| | | <delete id="deleteByPrimaryKey" parameterType="java.lang.Long"> |
| | | delete from plt_product_unqualified_reason |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </delete> |
| | | <insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductUnqualifiedReason" useGeneratedKeys="true"> |
| | | insert into plt_product_unqualified_reason |
| | | ( id,pro_id,reason |
| | | ,deleted) |
| | | values (#{id,jdbcType=BIGINT},#{proId,jdbcType=BIGINT},#{reason,jdbcType=VARCHAR} |
| | | ,#{deleted,jdbcType=TINYINT}) |
| | | </insert> |
| | | <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductUnqualifiedReason" useGeneratedKeys="true"> |
| | | insert into plt_product_unqualified_reason |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">id,</if> |
| | | <if test="proId != null">pro_id,</if> |
| | | <if test="reason != null">reason,</if> |
| | | <if test="deleted != null">deleted,</if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">#{id,jdbcType=BIGINT},</if> |
| | | <if test="proId != null">#{proId,jdbcType=BIGINT},</if> |
| | | <if test="reason != null">#{reason,jdbcType=VARCHAR},</if> |
| | | <if test="deleted != null">#{deleted,jdbcType=TINYINT},</if> |
| | | </trim> |
| | |
| | | <update id="updateByPrimaryKeySelective" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductUnqualifiedReason"> |
| | | update plt_product_unqualified_reason |
| | | <set> |
| | | <if test="proId != null"> |
| | | pro_id = #{proId,jdbcType=BIGINT}, |
| | | </if> |
| | | <if test="reason != null"> |
| | | reason = #{reason,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="deleted != null"> |
| | | deleted = #{deleted,jdbcType=TINYINT}, |
| | | </if> |
| | | <if test="disabled != null"> |
| | | disabled = #{disabled,jdbcType=TINYINT}, |
| | | </if> |
| | | <if test="reason != null"> |
| | | reason = #{reason,jdbcType=VARCHAR}, |
| | | </if> |
| | | <if test="deleted != null"> |
| | | deleted = #{deleted,jdbcType=TINYINT}, |
| | | </if> |
| | | </set> |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | <update id="updateByPrimaryKey" parameterType="com.dy.pmsGlobal.pojoPlt.PltProductUnqualifiedReason"> |
| | | update plt_product_unqualified_reason |
| | | set |
| | | pro_id = #{proId,jdbcType=BIGINT}, |
| | | reason = #{reason,jdbcType=VARCHAR}, |
| | | deleted = #{deleted,jdbcType=TINYINT} |
| | | where id = #{id,jdbcType=BIGINT} |
| | | </update> |
| | | |
| | | <select id="selectSome" resultMap="BaseResultMap"> |
| | | select |
| | | <include refid="part_Column_List" > |
| | | <property name="alias" value="t"/> |
| | | </include> |
| | | select <include refid="Base_Column_List" /> |
| | | from plt_product_unqualified_reason t |
| | | inner join plt_product p on t.pro_id = p.id |
| | | where t.deleted!=1 |
| | | <trim prefix="and" suffixOverrides="and"> |
| | | <if test="proName != null and proName != ''"> |
| | | p.name like concat('%', #{proName}, '%') and |
| | | </if> |
| | | <if test="reason != null and reason != ''"> |
| | | t.reason like concat('%', #{reason}, '%') and |
| | | </if> |
| | |
| | | <select id="selectSomeCount" resultType="java.lang.Long"> |
| | | select count(1) |
| | | from plt_product_unqualified_reason t |
| | | inner join plt_product p on t.pro_id = p.id |
| | | where t.deleted!=1 |
| | | <trim prefix="and" suffixOverrides="and"> |
| | | <if test="proName != null and proName != ''"> |
| | | p.name like concat('%', #{proName}, '%') and |
| | | </if> |
| | | <if test="reason != null and reason != ''"> |
| | | t.reason like concat('%', #{reason}, '%') and |
| | | </if> |
| | |
| | | <mapper namespace="com.dy.pmsGlobal.daoPlt.PltStationMapper"> |
| | | |
| | | <resultMap id="BaseResultMap" type="com.dy.pmsGlobal.pojoPlt.PltStation"> |
| | | <id property="id" column="id" jdbcType="BIGINT"/> |
| | | <result property="code" column="code" jdbcType="VARCHAR"/> |
| | | <result property="name" column="name" jdbcType="VARCHAR"/> |
| | | <result property="remark" column="remark" jdbcType="VARCHAR"/> |
| | | <result property="dt" column="dt" jdbcType="TIMESTAMP"/> |
| | | <result property="deleted" column="deleted" jdbcType="TINYINT"/> |
| | | <id property="id" column="id" jdbcType="BIGINT"/> |
| | | <result property="code" column="code" jdbcType="VARCHAR"/> |
| | | <result property="name" column="name" jdbcType="VARCHAR"/> |
| | | <result property="remark" column="remark" jdbcType="VARCHAR"/> |
| | | <result property="dt" column="dt" jdbcType="TIMESTAMP"/> |
| | | <result column="disabled" property="disabled" typeHandler="com.dy.common.mybatis.BooleanTypeHandler"/> |
| | | <result property="deleted" column="deleted" typeHandler="com.dy.common.mybatis.BooleanTypeHandler"/> |
| | | </resultMap> |
| | | |
| | | <sql id="Base_Column_List"> |
| | | id,code,name, |
| | | id,code,name,disabled, |
| | | remark,dt,deleted |
| | | </sql> |
| | | |
| | |
| | | import com.dy.common.webUtil.BaseResponseUtils; |
| | | import com.dy.common.webUtil.QueryResultVo; |
| | | import com.dy.pmsGlobal.aop.Log; |
| | | import com.dy.pmsGlobal.pojoBa.BaRole; |
| | | import com.dy.pmsGlobal.pojoPlt.PltProductParams; |
| | | import com.dy.pmsGlobal.pojoPlt.PltProductQualityInspectionItems; |
| | | import com.dy.pmsGlobal.pojoPlt.PltProductUnqualifiedReason; |
| | | import jakarta.validation.Valid; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage()); |
| | | } |
| | | item.deleted = false; |
| | | item.disabled = false; |
| | | return BaseResponseUtils.buildSuccess(sv.save(item)); |
| | | }catch (Exception e){ |
| | | log.error("保存产品品质检查项目异常", e); |
| | |
| | | return BaseResponseUtils.buildException(e.getMessage()); |
| | | } |
| | | } |
| | | /** |
| | | * 禁用或启用 |
| | | * @param reason |
| | | * @return |
| | | */ |
| | | @PostMapping(path="disabled") |
| | | @SsoPowerAop(power = "10100011") |
| | | @Log("禁用或启用质检项目") |
| | | public BaseResponse<BaRole> disabled(@RequestBody PltProductUnqualifiedReason reason){ |
| | | try { |
| | | return BaseResponseUtils.buildSuccess(sv.disabled(reason.id,reason.disabled)); |
| | | }catch (Exception e){ |
| | | log.error("禁用或启用质检项目异常", e); |
| | | return BaseResponseUtils.buildException(e.getMessage()); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | |
| | | |
| | | @Transactional |
| | | public int save(PltProductQualityInspectionItems item) { |
| | | int count = dao.insert(item); |
| | | int count = dao.insertSelective(item); |
| | | return count; |
| | | } |
| | | |
| | |
| | | rsVo.obj = this.dao.selectSome(params) ; |
| | | return rsVo ; |
| | | } |
| | | |
| | | public Object disabled(Long id, Boolean disabled) { |
| | | PltProductQualityInspectionItems item = new PltProductQualityInspectionItems(); |
| | | item.setId(id); |
| | | item.setDisabled(disabled); |
| | | return dao.updateByPrimaryKeySelective(item); |
| | | } |
| | | } |
| | |
| | | import com.dy.common.webUtil.BaseResponseUtils; |
| | | import com.dy.common.webUtil.QueryResultVo; |
| | | import com.dy.pmsGlobal.aop.Log; |
| | | import com.dy.pmsGlobal.pojoBa.BaRole; |
| | | import com.dy.pmsGlobal.pojoPlt.PltProductScrappingReason; |
| | | import com.dy.pmsGlobal.pojoPlt.PltProductUnqualifiedReason; |
| | | import jakarta.validation.Valid; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 禁用或启用 |
| | | * @param reason |
| | | * @return |
| | | */ |
| | | @PostMapping(path="disabled") |
| | | @SsoPowerAop(power = "10100011") |
| | | @Log("禁用或启用报废原因") |
| | | public BaseResponse<BaRole> disabled(@RequestBody PltProductUnqualifiedReason reason){ |
| | | try { |
| | | return BaseResponseUtils.buildSuccess(sv.disabled(reason.id,reason.disabled)); |
| | | }catch (Exception e){ |
| | | log.error("禁用或启用报废原因异常", e); |
| | | return BaseResponseUtils.buildException(e.getMessage()); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | |
| | | |
| | | @Transactional |
| | | public int save(PltProductScrappingReason reason) { |
| | | int count = dao.insert(reason); |
| | | int count = dao.insertSelective(reason); |
| | | return count; |
| | | } |
| | | |
| | |
| | | return rsVo ; |
| | | } |
| | | |
| | | public Object disabled(Long id, Boolean disabled) { |
| | | PltProductScrappingReason reason = new PltProductScrappingReason(); |
| | | reason.setId(id); |
| | | reason.setDisabled(disabled); |
| | | return dao.updateByPrimaryKeySelective(reason); |
| | | } |
| | | } |
| | | |
| | |
| | | import com.dy.common.webUtil.BaseResponseUtils; |
| | | import com.dy.common.webUtil.QueryResultVo; |
| | | import com.dy.pmsGlobal.aop.Log; |
| | | import com.dy.pmsGlobal.pojoBa.BaRole; |
| | | import com.dy.pmsGlobal.pojoPlt.PltProductParams; |
| | | import com.dy.pmsGlobal.pojoPlt.PltProductUnqualifiedReason; |
| | | import jakarta.validation.Valid; |
| | |
| | | return BaseResponseUtils.buildFail(Objects.requireNonNull(bindingResult.getFieldError()).getDefaultMessage()); |
| | | } |
| | | reason.deleted = false; |
| | | reason.disabled = false; |
| | | return BaseResponseUtils.buildSuccess(sv.save(reason)); |
| | | }catch (Exception e){ |
| | | log.error("保存产品生产不合格原因异常", e); |
| | |
| | | } |
| | | } |
| | | |
| | | /** |
| | | * 禁用或启用 |
| | | * @param reason |
| | | * @return |
| | | */ |
| | | @PostMapping(path="disabled") |
| | | @SsoPowerAop(power = "10100011") |
| | | @Log("禁用或启用不合格原因") |
| | | public BaseResponse<BaRole> disabled(@RequestBody PltProductUnqualifiedReason reason){ |
| | | try { |
| | | return BaseResponseUtils.buildSuccess(sv.disabled(reason.id,reason.disabled)); |
| | | }catch (Exception e){ |
| | | log.error("禁用或启用不合格原因异常", e); |
| | | return BaseResponseUtils.buildException(e.getMessage()); |
| | | } |
| | | } |
| | | |
| | | } |
| | | |
| | |
| | | |
| | | @Transactional |
| | | public int save(PltProductUnqualifiedReason reason) { |
| | | int count = dao.insert(reason); |
| | | int count = dao.insertSelective(reason); |
| | | return count; |
| | | } |
| | | |
| | |
| | | return rsVo ; |
| | | } |
| | | |
| | | public Object disabled(Long id, Boolean disabled) { |
| | | PltProductUnqualifiedReason reason = new PltProductUnqualifiedReason(); |
| | | reason.setId(id); |
| | | reason.setDisabled(disabled); |
| | | return dao.updateByPrimaryKeySelective(reason); |
| | | } |
| | | } |
| | | |