| | |
| | | "http://mybatis.org/dtd/mybatis-3-mapper.dtd"> |
| | | <mapper namespace="com.aps.core.mapper.ApsWorkCalendarMapper"> |
| | | |
| | | <resultMap type="ApsWorkCalendar" id="ApsWorkCalendarResult"> |
| | | <resultMap type="com.aps.core.domain.ApsWorkCalendar" id="ApsWorkCalendarResult"> |
| | | <result property="id" column="id" /> |
| | | <result property="description" column="description" /> |
| | | <result property="type" column="type" /> |
| | |
| | | select id, description, type, effective_date, expiring_date, content, applicable_factory, applicable_workshop, applicable_process, create_by, create_time, update_by, update_time, holidays, applicable, applicable_translate from aps_work_calendar |
| | | </sql> |
| | | |
| | | <select id="selectApsWorkCalendarList" parameterType="ApsWorkCalendar" resultMap="ApsWorkCalendarResult"> |
| | | <select id="selectApsWorkCalendarList" parameterType="com.aps.core.domain.ApsWorkCalendar" resultMap="ApsWorkCalendarResult"> |
| | | <include refid="selectApsWorkCalendarVo"/> |
| | | <where> |
| | | <if test="description != null and description != ''"> and description like '%' || #{description} || '%'</if> |
| | |
| | | where id = #{id} |
| | | </select> |
| | | |
| | | <insert id="insertApsWorkCalendar" parameterType="ApsWorkCalendar"> |
| | | <insert id="insertApsWorkCalendar" parameterType="com.aps.core.domain.ApsWorkCalendar"> |
| | | insert into aps_work_calendar |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="id != null">id,</if> |
| | |
| | | </trim> |
| | | </insert> |
| | | |
| | | <update id="updateApsWorkCalendar" parameterType="ApsWorkCalendar"> |
| | | <update id="updateApsWorkCalendar" parameterType="com.aps.core.domain.ApsWorkCalendar"> |
| | | update aps_work_calendar |
| | | <trim prefix="SET" suffixOverrides=","> |
| | | <if test="description != null">description = #{description},</if> |
| | |
| | | delete from aps_work_calendar where id = #{id} |
| | | </delete> |
| | | |
| | | <delete id="deleteApsWorkCalendarByIds" parameterType="ApsWorkCalendar"> |
| | | <delete id="deleteApsWorkCalendarByIds" parameterType="com.aps.core.domain.ApsWorkCalendar"> |
| | | delete from aps_work_calendar where id in |
| | | <foreach item="id" collection="array" open="(" separator="," close=")"> |
| | | #{id} |
| | | </foreach> |
| | | </delete> |
| | | |
| | | <delete id="deleteApsWorkCalendar" parameterType="ApsWorkCalendar"> |
| | | <delete id="deleteApsWorkCalendar" parameterType="com.aps.core.domain.ApsWorkCalendar"> |
| | | delete from aps_work_calendar where effective_date=#{effectiveDate} and expiring_date=#{expiringDate} and applicable_factory=#{applicableFactory} and applicable_workshop=#{applicableWorkshop} and applicable_process=#{applicableProcess} |
| | | </delete> |
| | | </mapper> |