first commit

This commit is contained in:
2026-01-16 14:13:44 +08:00
commit 903ff8d495
34603 changed files with 8585054 additions and 0 deletions

View File

@ -0,0 +1,171 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="activiti.LeaveMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.activiti.Leave" >
<id column="id" property="id" jdbcType="NUMERIC" />
<result column="apply_time" property="applyTime" jdbcType="TIMESTAMP" />
<result column="end_time" property="endTime" jdbcType="TIMESTAMP" />
<result column="leave_type" property="leaveType" jdbcType="VARCHAR" />
<result column="process_instance_id" property="processInstanceId" jdbcType="VARCHAR" />
<result column="reality_end_time" property="realityEndTime" jdbcType="TIMESTAMP" />
<result column="reality_start_time" property="realityStartTime" jdbcType="TIMESTAMP" />
<result column="reason" property="reason" jdbcType="VARCHAR" />
<result column="start_time" property="startTime" jdbcType="TIMESTAMP" />
<result column="user_id" property="userId" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, apply_time, end_time, leave_type, process_instance_id, reality_end_time, reality_start_time,
reason, start_time, user_id
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.math.BigDecimal" >
select
<include refid="Base_Column_List" />
from oa_leave
where id = #{id,jdbcType=NUMERIC}
</select>
<select id="selectByID" resultMap="BaseResultMap" parameterType="java.math.BigDecimal" >
select
<include refid="Base_Column_List" />
from oa_leave
where id = #{id,jdbcType=NUMERIC}
order by id
</select>
<delete id="deleteByPrimaryKey" parameterType="java.math.BigDecimal" >
delete from oa_leave
where id = #{id,jdbcType=NUMERIC}
</delete>
<insert id="insert" parameterType="com.sipai.entity.activiti.Leave" >
insert into oa_leave (id, apply_time, end_time,
leave_type, process_instance_id, reality_end_time,
reality_start_time, reason, start_time,
user_id)
values (#{id,jdbcType=NUMERIC}, #{applyTime,jdbcType=TIMESTAMP}, #{endTime,jdbcType=TIMESTAMP},
#{leaveType,jdbcType=VARCHAR}, #{processInstanceId,jdbcType=VARCHAR}, #{realityEndTime,jdbcType=TIMESTAMP},
#{realityStartTime,jdbcType=TIMESTAMP}, #{reason,jdbcType=VARCHAR}, #{startTime,jdbcType=TIMESTAMP},
#{userId,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.activiti.Leave" useGeneratedKeys="true" keyProperty="id">
insert into oa_leave
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="applyTime != null" >
apply_time,
</if>
<if test="endTime != null" >
end_time,
</if>
<if test="leaveType != null" >
leave_type,
</if>
<if test="processInstanceId != null" >
process_instance_id,
</if>
<if test="realityEndTime != null" >
reality_end_time,
</if>
<if test="realityStartTime != null" >
reality_start_time,
</if>
<if test="reason != null" >
reason,
</if>
<if test="startTime != null" >
start_time,
</if>
<if test="userId != null" >
user_id,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=NUMERIC},
</if>
<if test="applyTime != null" >
#{applyTime,jdbcType=TIMESTAMP},
</if>
<if test="endTime != null" >
#{endTime,jdbcType=TIMESTAMP},
</if>
<if test="leaveType != null" >
#{leaveType,jdbcType=VARCHAR},
</if>
<if test="processInstanceId != null" >
#{processInstanceId,jdbcType=VARCHAR},
</if>
<if test="realityEndTime != null" >
#{realityEndTime,jdbcType=TIMESTAMP},
</if>
<if test="realityStartTime != null" >
#{realityStartTime,jdbcType=TIMESTAMP},
</if>
<if test="reason != null" >
#{reason,jdbcType=VARCHAR},
</if>
<if test="startTime != null" >
#{startTime,jdbcType=TIMESTAMP},
</if>
<if test="userId != null" >
#{userId,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.activiti.Leave" >
update oa_leave
<set >
<if test="applyTime != null" >
apply_time = #{applyTime,jdbcType=TIMESTAMP},
</if>
<if test="endTime != null" >
end_time = #{endTime,jdbcType=TIMESTAMP},
</if>
<if test="leaveType != null" >
leave_type = #{leaveType,jdbcType=VARCHAR},
</if>
<if test="processInstanceId != null" >
process_instance_id = #{processInstanceId,jdbcType=VARCHAR},
</if>
<if test="realityEndTime != null" >
reality_end_time = #{realityEndTime,jdbcType=TIMESTAMP},
</if>
<if test="realityStartTime != null" >
reality_start_time = #{realityStartTime,jdbcType=TIMESTAMP},
</if>
<if test="reason != null" >
reason = #{reason,jdbcType=VARCHAR},
</if>
<if test="startTime != null" >
start_time = #{startTime,jdbcType=TIMESTAMP},
</if>
<if test="userId != null" >
user_id = #{userId,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=NUMERIC}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.activiti.Leave" >
update oa_leave
set apply_time = #{applyTime,jdbcType=TIMESTAMP},
end_time = #{endTime,jdbcType=TIMESTAMP},
leave_type = #{leaveType,jdbcType=VARCHAR},
process_instance_id = #{processInstanceId,jdbcType=VARCHAR},
reality_end_time = #{realityEndTime,jdbcType=TIMESTAMP},
reality_start_time = #{realityStartTime,jdbcType=TIMESTAMP},
reason = #{reason,jdbcType=VARCHAR},
start_time = #{startTime,jdbcType=TIMESTAMP},
user_id = #{userId,jdbcType=VARCHAR}
where id = #{id,jdbcType=NUMERIC}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap"
parameterType="java.lang.String">
select
<include refid="Base_Column_List" />
from oa_leave
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from oa_leave
${where}
</delete>
</mapper>

View File

@ -0,0 +1,140 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="base.CommonFileMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.base.CommonFile" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="masterid" property="masterid" jdbcType="VARCHAR" />
<result column="filename" property="filename" jdbcType="VARCHAR" />
<result column="abspath" property="abspath" jdbcType="VARCHAR" />
<result column="size" property="size" jdbcType="INTEGER" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="type" property="type" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, masterid, filename, abspath, size, insuser, insdt, type
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_common_file
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_common_file
where id = #{id,jdbcType=VARCHAR}
</delete>
<delete id="deleteBymasterId" parameterType="java.lang.String" >
delete from tb_common_file
where masterid = #{masterid,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.base.CommonFile" >
insert into tb_common_file (id, masterid, filename,
abspath, size, insuser,
insdt, type)
values (#{id,jdbcType=VARCHAR}, #{masterid,jdbcType=VARCHAR}, #{filename,jdbcType=VARCHAR},
#{abspath,jdbcType=VARCHAR}, #{size,jdbcType=INTEGER}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{type,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.base.CommonFile" >
insert into tb_common_file
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="masterid != null" >
masterid,
</if>
<if test="filename != null" >
filename,
</if>
<if test="abspath != null" >
abspath,
</if>
<if test="size != null" >
size,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="type != null" >
type,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="masterid != null" >
#{masterid,jdbcType=VARCHAR},
</if>
<if test="filename != null" >
#{filename,jdbcType=VARCHAR},
</if>
<if test="abspath != null" >
#{abspath,jdbcType=VARCHAR},
</if>
<if test="size != null" >
#{size,jdbcType=INTEGER},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="type != null" >
#{type,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.base.CommonFile" >
update tb_common_file
<set >
<if test="masterid != null" >
masterid = #{masterid,jdbcType=VARCHAR},
</if>
<if test="filename != null" >
filename = #{filename,jdbcType=VARCHAR},
</if>
<if test="abspath != null" >
abspath = #{abspath,jdbcType=VARCHAR},
</if>
<if test="size != null" >
size = #{size,jdbcType=INTEGER},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="type != null" >
type = #{type,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.base.CommonFile" >
update tb_common_file
set masterid = #{masterid,jdbcType=VARCHAR},
filename = #{filename,jdbcType=VARCHAR},
abspath = #{abspath,jdbcType=VARCHAR},
size = #{size,jdbcType=INTEGER},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
type = #{type,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectByMasterId" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_common_file
where masterid = #{masterid,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,238 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="clean.cleanmonitorMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.clean.CleanMonitor" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="humidity" property="humidity" jdbcType="VARCHAR" />
<result column="temperature" property="temperature" jdbcType="VARCHAR" />
<result column="dust" property="dust" jdbcType="VARCHAR" />
<result column="collection_time" property="collectionTime" jdbcType="TIMESTAMP" />
<result column="clean_state" property="cleanState" jdbcType="VARCHAR" />
<result column="collection_data_one" property="collectionDataOne" jdbcType="VARCHAR" />
<result column="collection_data_two" property="collectionDataTwo" jdbcType="VARCHAR" />
<result column="collection_data_there" property="collectionDataThere" jdbcType="VARCHAR" />
<result column="collection_data_four" property="collectionDataFour" jdbcType="VARCHAR" />
<result column="collection_data_five" property="collectionDataFive" jdbcType="VARCHAR" />
<result column="createdt" property="createdt" jdbcType="TIMESTAMP" />
<result column="createuser" property="createuser" jdbcType="VARCHAR" />
<result column="point_position" property="pointPosition" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, humidity, temperature, dust, collection_time, clean_state, collection_data_one,
collection_data_two, collection_data_there, collection_data_four, collection_data_five,
createdt, createuser, point_position
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_clean_cleanmonitor
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_clean_cleanmonitor
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.clean.CleanMonitor" >
insert into tb_clean_cleanmonitor (id, insuser, insdt,
humidity, temperature, dust,
collection_time, clean_state, collection_data_one,
collection_data_two, collection_data_there,
collection_data_four, collection_data_five,
createdt, createuser, point_position
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{humidity,jdbcType=VARCHAR}, #{temperature,jdbcType=VARCHAR}, #{dust,jdbcType=VARCHAR},
#{collectionTime,jdbcType=TIMESTAMP}, #{cleanState,jdbcType=VARCHAR}, #{collectionDataOne,jdbcType=VARCHAR},
#{collectionDataTwo,jdbcType=VARCHAR}, #{collectionDataThere,jdbcType=VARCHAR},
#{collectionDataFour,jdbcType=VARCHAR}, #{collectionDataFive,jdbcType=VARCHAR},
#{createdt,jdbcType=TIMESTAMP}, #{createuser,jdbcType=VARCHAR}, #{pointPosition,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.clean.CleanMonitor" >
insert into tb_clean_cleanmonitor
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="humidity != null" >
humidity,
</if>
<if test="temperature != null" >
temperature,
</if>
<if test="dust != null" >
dust,
</if>
<if test="collectionTime != null" >
collection_time,
</if>
<if test="cleanState != null" >
clean_state,
</if>
<if test="collectionDataOne != null" >
collection_data_one,
</if>
<if test="collectionDataTwo != null" >
collection_data_two,
</if>
<if test="collectionDataThere != null" >
collection_data_there,
</if>
<if test="collectionDataFour != null" >
collection_data_four,
</if>
<if test="collectionDataFive != null" >
collection_data_five,
</if>
<if test="createdt != null" >
createdt,
</if>
<if test="createuser != null" >
createuser,
</if>
<if test="pointPosition != null" >
point_position,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="humidity != null" >
#{humidity,jdbcType=VARCHAR},
</if>
<if test="temperature != null" >
#{temperature,jdbcType=VARCHAR},
</if>
<if test="dust != null" >
#{dust,jdbcType=VARCHAR},
</if>
<if test="collectionTime != null" >
#{collectionTime,jdbcType=TIMESTAMP},
</if>
<if test="cleanState != null" >
#{cleanState,jdbcType=VARCHAR},
</if>
<if test="collectionDataOne != null" >
#{collectionDataOne,jdbcType=VARCHAR},
</if>
<if test="collectionDataTwo != null" >
#{collectionDataTwo,jdbcType=VARCHAR},
</if>
<if test="collectionDataThere != null" >
#{collectionDataThere,jdbcType=VARCHAR},
</if>
<if test="collectionDataFour != null" >
#{collectionDataFour,jdbcType=VARCHAR},
</if>
<if test="collectionDataFive != null" >
#{collectionDataFive,jdbcType=VARCHAR},
</if>
<if test="createdt != null" >
#{createdt,jdbcType=TIMESTAMP},
</if>
<if test="createuser != null" >
#{createuser,jdbcType=VARCHAR},
</if>
<if test="pointPosition != null" >
#{pointPosition,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.clean.CleanMonitor" >
update tb_clean_cleanmonitor
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="humidity != null" >
humidity = #{humidity,jdbcType=VARCHAR},
</if>
<if test="temperature != null" >
temperature = #{temperature,jdbcType=VARCHAR},
</if>
<if test="dust != null" >
dust = #{dust,jdbcType=VARCHAR},
</if>
<if test="collectionTime != null" >
collection_time = #{collectionTime,jdbcType=TIMESTAMP},
</if>
<if test="cleanState != null" >
clean_state = #{cleanState,jdbcType=VARCHAR},
</if>
<if test="collectionDataOne != null" >
collection_data_one = #{collectionDataOne,jdbcType=VARCHAR},
</if>
<if test="collectionDataTwo != null" >
collection_data_two = #{collectionDataTwo,jdbcType=VARCHAR},
</if>
<if test="collectionDataThere != null" >
collection_data_there = #{collectionDataThere,jdbcType=VARCHAR},
</if>
<if test="collectionDataFour != null" >
collection_data_four = #{collectionDataFour,jdbcType=VARCHAR},
</if>
<if test="collectionDataFive != null" >
collection_data_five = #{collectionDataFive,jdbcType=VARCHAR},
</if>
<if test="createdt != null" >
createdt = #{createdt,jdbcType=TIMESTAMP},
</if>
<if test="createuser != null" >
createuser = #{createuser,jdbcType=VARCHAR},
</if>
<if test="pointPosition != null" >
point_position = #{pointPosition,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.clean.CleanMonitor" >
update tb_clean_cleanmonitor
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
humidity = #{humidity,jdbcType=VARCHAR},
temperature = #{temperature,jdbcType=VARCHAR},
dust = #{dust,jdbcType=VARCHAR},
collection_time = #{collectionTime,jdbcType=TIMESTAMP},
clean_state = #{cleanState,jdbcType=VARCHAR},
collection_data_one = #{collectionDataOne,jdbcType=VARCHAR},
collection_data_two = #{collectionDataTwo,jdbcType=VARCHAR},
collection_data_there = #{collectionDataThere,jdbcType=VARCHAR},
collection_data_four = #{collectionDataFour,jdbcType=VARCHAR},
collection_data_five = #{collectionDataFive,jdbcType=VARCHAR},
createdt = #{createdt,jdbcType=TIMESTAMP},
createuser = #{createuser,jdbcType=VARCHAR},
point_position = #{pointPosition,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap"
parameterType="java.lang.String">
select
<include refid="Base_Column_List" />
from tb_clean_cleanmonitor
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from
tb_clean_cleanmonitor
${where}
</delete>
</mapper>

View File

@ -0,0 +1,370 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="clean.MonitorEquipmentMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.clean.MonitorEquipment" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="equipment_name" property="equipmentName" jdbcType="VARCHAR" />
<result column="mender" property="mender" jdbcType="VARCHAR" />
<result column="lastchangetime" property="lastchangetime" jdbcType="TIMESTAMP" />
<result column="tem_alarmless" property="temAlarmless" jdbcType="VARCHAR" />
<result column="tem_alarmgreater" property="temAlarmgreater" jdbcType="VARCHAR" />
<result column="hum_alarmless" property="humAlarmless" jdbcType="VARCHAR" />
<result column="hum_alarmgreater" property="humAlarmgreater" jdbcType="VARCHAR" />
<result column="dust_alarmgreater" property="dustAlarmgreater" jdbcType="VARCHAR" />
<result column="temperature" property="temperature" jdbcType="VARCHAR" />
<result column="humidity" property="humidity" jdbcType="VARCHAR" />
<result column="dust" property="dust" jdbcType="VARCHAR" />
<result column="equipment_position" property="equipmentPosition" jdbcType="VARCHAR" />
<result column="equipment_state" property="equipmentState" jdbcType="VARCHAR" />
<result column="temperature_point" property="temperaturePoint" jdbcType="VARCHAR" />
<result column="humidity_point" property="humidityPoint" jdbcType="VARCHAR" />
<result column="dust_point" property="dustPoint" jdbcType="VARCHAR" />
<result column="temperature_port" property="temperaturePort" jdbcType="VARCHAR" />
<result column="humidity_port" property="humidityPort" jdbcType="VARCHAR" />
<result column="dust_port" property="dustPort" jdbcType="VARCHAR" />
<result column="temperature_color" property="temperatureColor" jdbcType="VARCHAR" />
<result column="humidity_color" property="humidityColor" jdbcType="VARCHAR" />
<result column="dust_color" property="dustColor" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, equipment_name, mender, lastchangetime, tem_alarmless, tem_alarmgreater,
hum_alarmless, hum_alarmgreater, dust_alarmgreater, temperature, humidity, dust,
equipment_position, equipment_state, temperature_point, humidity_point, dust_point,
temperature_port, humidity_port, dust_port, temperature_color, humidity_color, dust_color
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_clean_monitorequipment
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_clean_monitorequipment
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.clean.MonitorEquipment" >
insert into tb_clean_monitorequipment (id, insuser, insdt,
equipment_name, mender, lastchangetime,
tem_alarmless, tem_alarmgreater, hum_alarmless,
hum_alarmgreater, dust_alarmgreater, temperature,
humidity, dust, equipment_position,
equipment_state, temperature_point, humidity_point,
dust_point, temperature_port, humidity_port,
dust_port, temperature_color, humidity_color,
dust_color)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{equipmentName,jdbcType=VARCHAR}, #{mender,jdbcType=VARCHAR}, #{lastchangetime,jdbcType=TIMESTAMP},
#{temAlarmless,jdbcType=VARCHAR}, #{temAlarmgreater,jdbcType=VARCHAR}, #{humAlarmless,jdbcType=VARCHAR},
#{humAlarmgreater,jdbcType=VARCHAR}, #{dustAlarmgreater,jdbcType=VARCHAR}, #{temperature,jdbcType=VARCHAR},
#{humidity,jdbcType=VARCHAR}, #{dust,jdbcType=VARCHAR}, #{equipmentPosition,jdbcType=VARCHAR},
#{equipmentState,jdbcType=VARCHAR}, #{temperaturePoint,jdbcType=VARCHAR}, #{humidityPoint,jdbcType=VARCHAR},
#{dustPoint,jdbcType=VARCHAR}, #{temperaturePort,jdbcType=VARCHAR}, #{humidityPort,jdbcType=VARCHAR},
#{dustPort,jdbcType=VARCHAR}, #{temperatureColor,jdbcType=VARCHAR}, #{humidityColor,jdbcType=VARCHAR},
#{dustColor,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.clean.MonitorEquipment" >
insert into tb_clean_monitorequipment
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="equipmentName != null" >
equipment_name,
</if>
<if test="mender != null" >
mender,
</if>
<if test="lastchangetime != null" >
lastchangetime,
</if>
<if test="temAlarmless != null" >
tem_alarmless,
</if>
<if test="temAlarmgreater != null" >
tem_alarmgreater,
</if>
<if test="humAlarmless != null" >
hum_alarmless,
</if>
<if test="humAlarmgreater != null" >
hum_alarmgreater,
</if>
<if test="dustAlarmgreater != null" >
dust_alarmgreater,
</if>
<if test="temperature != null" >
temperature,
</if>
<if test="humidity != null" >
humidity,
</if>
<if test="dust != null" >
dust,
</if>
<if test="equipmentPosition != null" >
equipment_position,
</if>
<if test="equipmentState != null" >
equipment_state,
</if>
<if test="temperaturePoint != null" >
temperature_point,
</if>
<if test="humidityPoint != null" >
humidity_point,
</if>
<if test="dustPoint != null" >
dust_point,
</if>
<if test="temperaturePort != null" >
temperature_port,
</if>
<if test="humidityPort != null" >
humidity_port,
</if>
<if test="dustPort != null" >
dust_port,
</if>
<if test="temperatureColor != null" >
temperature_color,
</if>
<if test="humidityColor != null" >
humidity_color,
</if>
<if test="dustColor != null" >
dust_color,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="equipmentName != null" >
#{equipmentName,jdbcType=VARCHAR},
</if>
<if test="mender != null" >
#{mender,jdbcType=VARCHAR},
</if>
<if test="lastchangetime != null" >
#{lastchangetime,jdbcType=TIMESTAMP},
</if>
<if test="temAlarmless != null" >
#{temAlarmless,jdbcType=VARCHAR},
</if>
<if test="temAlarmgreater != null" >
#{temAlarmgreater,jdbcType=VARCHAR},
</if>
<if test="humAlarmless != null" >
#{humAlarmless,jdbcType=VARCHAR},
</if>
<if test="humAlarmgreater != null" >
#{humAlarmgreater,jdbcType=VARCHAR},
</if>
<if test="dustAlarmgreater != null" >
#{dustAlarmgreater,jdbcType=VARCHAR},
</if>
<if test="temperature != null" >
#{temperature,jdbcType=VARCHAR},
</if>
<if test="humidity != null" >
#{humidity,jdbcType=VARCHAR},
</if>
<if test="dust != null" >
#{dust,jdbcType=VARCHAR},
</if>
<if test="equipmentPosition != null" >
#{equipmentPosition,jdbcType=VARCHAR},
</if>
<if test="equipmentState != null" >
#{equipmentState,jdbcType=VARCHAR},
</if>
<if test="temperaturePoint != null" >
#{temperaturePoint,jdbcType=VARCHAR},
</if>
<if test="humidityPoint != null" >
#{humidityPoint,jdbcType=VARCHAR},
</if>
<if test="dustPoint != null" >
#{dustPoint,jdbcType=VARCHAR},
</if>
<if test="temperaturePort != null" >
#{temperaturePort,jdbcType=VARCHAR},
</if>
<if test="humidityPort != null" >
#{humidityPort,jdbcType=VARCHAR},
</if>
<if test="dustPort != null" >
#{dustPort,jdbcType=VARCHAR},
</if>
<if test="temperatureColor != null" >
#{temperatureColor,jdbcType=VARCHAR},
</if>
<if test="humidityColor != null" >
#{humidityColor,jdbcType=VARCHAR},
</if>
<if test="dustColor != null" >
#{dustColor,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.clean.MonitorEquipment" >
update tb_clean_monitorequipment
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="equipmentName != null" >
equipment_name = #{equipmentName,jdbcType=VARCHAR},
</if>
<if test="mender != null" >
mender = #{mender,jdbcType=VARCHAR},
</if>
<if test="lastchangetime != null" >
lastchangetime = #{lastchangetime,jdbcType=TIMESTAMP},
</if>
<if test="temAlarmless != null" >
tem_alarmless = #{temAlarmless,jdbcType=VARCHAR},
</if>
<if test="temAlarmgreater != null" >
tem_alarmgreater = #{temAlarmgreater,jdbcType=VARCHAR},
</if>
<if test="humAlarmless != null" >
hum_alarmless = #{humAlarmless,jdbcType=VARCHAR},
</if>
<if test="humAlarmgreater != null" >
hum_alarmgreater = #{humAlarmgreater,jdbcType=VARCHAR},
</if>
<if test="dustAlarmgreater != null" >
dust_alarmgreater = #{dustAlarmgreater,jdbcType=VARCHAR},
</if>
<if test="temperature != null" >
temperature = #{temperature,jdbcType=VARCHAR},
</if>
<if test="humidity != null" >
humidity = #{humidity,jdbcType=VARCHAR},
</if>
<if test="dust != null" >
dust = #{dust,jdbcType=VARCHAR},
</if>
<if test="equipmentPosition != null" >
equipment_position = #{equipmentPosition,jdbcType=VARCHAR},
</if>
<if test="equipmentState != null" >
equipment_state = #{equipmentState,jdbcType=VARCHAR},
</if>
<if test="temperaturePoint != null" >
temperature_point = #{temperaturePoint,jdbcType=VARCHAR},
</if>
<if test="humidityPoint != null" >
humidity_point = #{humidityPoint,jdbcType=VARCHAR},
</if>
<if test="dustPoint != null" >
dust_point = #{dustPoint,jdbcType=VARCHAR},
</if>
<if test="temperaturePort != null" >
temperature_port = #{temperaturePort,jdbcType=VARCHAR},
</if>
<if test="humidityPort != null" >
humidity_port = #{humidityPort,jdbcType=VARCHAR},
</if>
<if test="dustPort != null" >
dust_port = #{dustPort,jdbcType=VARCHAR},
</if>
<if test="temperatureColor != null" >
temperature_color = #{temperatureColor,jdbcType=VARCHAR},
</if>
<if test="humidityColor != null" >
humidity_color = #{humidityColor,jdbcType=VARCHAR},
</if>
<if test="dustColor != null" >
dust_color = #{dustColor,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.clean.MonitorEquipment" >
update tb_clean_monitorequipment
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
equipment_name = #{equipmentName,jdbcType=VARCHAR},
mender = #{mender,jdbcType=VARCHAR},
lastchangetime = #{lastchangetime,jdbcType=TIMESTAMP},
tem_alarmless = #{temAlarmless,jdbcType=VARCHAR},
tem_alarmgreater = #{temAlarmgreater,jdbcType=VARCHAR},
hum_alarmless = #{humAlarmless,jdbcType=VARCHAR},
hum_alarmgreater = #{humAlarmgreater,jdbcType=VARCHAR},
dust_alarmgreater = #{dustAlarmgreater,jdbcType=VARCHAR},
temperature = #{temperature,jdbcType=VARCHAR},
humidity = #{humidity,jdbcType=VARCHAR},
dust = #{dust,jdbcType=VARCHAR},
equipment_position = #{equipmentPosition,jdbcType=VARCHAR},
equipment_state = #{equipmentState,jdbcType=VARCHAR},
temperature_point = #{temperaturePoint,jdbcType=VARCHAR},
humidity_point = #{humidityPoint,jdbcType=VARCHAR},
dust_point = #{dustPoint,jdbcType=VARCHAR},
temperature_port = #{temperaturePort,jdbcType=VARCHAR},
humidity_port = #{humidityPort,jdbcType=VARCHAR},
dust_port = #{dustPort,jdbcType=VARCHAR},
temperature_color = #{temperatureColor,jdbcType=VARCHAR},
humidity_color = #{humidityColor,jdbcType=VARCHAR},
dust_color = #{dustColor,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap"
parameterType="java.lang.String">
select
<include refid="Base_Column_List" />
from tb_clean_monitorequipment
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from
tb_clean_monitorequipment
${where}
</delete>
<select id="selectEquipmentstate" parameterType="java.lang.String" resultMap="BaseResultMap">
select M.[MPointCode] AS mpointcode,
e.dust AS dust,
e.dust_alarmgreater AS dust_alarmgreater,
e.dust_point AS dust_point,
e.dust_port AS dust_port,
e.equipment_name AS equipment_name,
e.equipment_position AS equipment_position,
e.equipment_state AS equipment_state,
e.hum_alarmgreater AS hum_alarmgreater,
e.hum_alarmless AS hum_alarmless,
e.humidity AS humidity,
e.humidity_point AS humidity_point,
e.humidity_port AS humidity_port,
e.id AS id,
e.insdt AS insdt,
e.insuser AS insuser,
e.lastchangetime AS lastchangetime,
e.mender AS mender,
e.tem_alarmgreater AS tem_alarmgreater,
e.tem_alarmless AS tem_alarmless,
e.temperature AS temperature,
e.temperature_point AS temperature_point,
e.temperature_port AS temperature_port
from [EIP_PRD_RLD].[dbo].[TB_MeasurePoint] M
full outer join [PlantEngine_RLD].[dbo].[tb_clean_monitorequipment] e on M.[MPointCode]= e.id
order by equipment_state
</select>
</mapper>

View File

@ -0,0 +1,199 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="clean.alarmhandleMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.clean.alarmhandle" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="alarmPonit" property="alarmponit" jdbcType="VARCHAR" />
<result column="alarmType" property="alarmtype" jdbcType="VARCHAR" />
<result column="alarmTime" property="alarmtime" jdbcType="TIMESTAMP" />
<result column="alarmReason" property="alarmreason" jdbcType="VARCHAR" />
<result column="handleReault" property="handlereault" jdbcType="VARCHAR" />
<result column="handledt" property="handledt" jdbcType="VARCHAR" />
<result column="handleuser" property="handleuser" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="VARCHAR" />
<result column="temperature" property="temperature" jdbcType="VARCHAR" />
<result column="humidity" property="humidity" jdbcType="VARCHAR" />
<result column="dust" property="dust" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, alarmPonit, alarmType, alarmTime, alarmReason, handleReault, handledt, handleuser,
insuser, insdt, temperature, humidity, dust
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_clean_alarmhandle
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_clean_alarmhandle
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.clean.alarmhandle" >
insert into tb_clean_alarmhandle (id, alarmPonit, alarmType,
alarmTime, alarmReason, handleReault,
handledt, handleuser, insuser,
insdt, temperature, humidity,
dust)
values (#{id,jdbcType=VARCHAR}, #{alarmponit,jdbcType=VARCHAR}, #{alarmtype,jdbcType=VARCHAR},
#{alarmtime,jdbcType=TIMESTAMP}, #{alarmreason,jdbcType=VARCHAR}, #{handlereault,jdbcType=VARCHAR},
#{handledt,jdbcType=VARCHAR}, #{handleuser,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=VARCHAR}, #{temperature,jdbcType=VARCHAR}, #{humidity,jdbcType=VARCHAR},
#{dust,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.clean.alarmhandle" >
insert into tb_clean_alarmhandle
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="alarmponit != null" >
alarmPonit,
</if>
<if test="alarmtype != null" >
alarmType,
</if>
<if test="alarmtime != null" >
alarmTime,
</if>
<if test="alarmreason != null" >
alarmReason,
</if>
<if test="handlereault != null" >
handleReault,
</if>
<if test="handledt != null" >
handledt,
</if>
<if test="handleuser != null" >
handleuser,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="temperature != null" >
temperature,
</if>
<if test="humidity != null" >
humidity,
</if>
<if test="dust != null" >
dust,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="alarmponit != null" >
#{alarmponit,jdbcType=VARCHAR},
</if>
<if test="alarmtype != null" >
#{alarmtype,jdbcType=VARCHAR},
</if>
<if test="alarmtime != null" >
#{alarmtime,jdbcType=TIMESTAMP},
</if>
<if test="alarmreason != null" >
#{alarmreason,jdbcType=VARCHAR},
</if>
<if test="handlereault != null" >
#{handlereault,jdbcType=VARCHAR},
</if>
<if test="handledt != null" >
#{handledt,jdbcType=VARCHAR},
</if>
<if test="handleuser != null" >
#{handleuser,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=VARCHAR},
</if>
<if test="temperature != null" >
#{temperature,jdbcType=VARCHAR},
</if>
<if test="humidity != null" >
#{humidity,jdbcType=VARCHAR},
</if>
<if test="dust != null" >
#{dust,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.clean.alarmhandle" >
update tb_clean_alarmhandle
<set >
<if test="alarmponit != null" >
alarmPonit = #{alarmponit,jdbcType=VARCHAR},
</if>
<if test="alarmtype != null" >
alarmType = #{alarmtype,jdbcType=VARCHAR},
</if>
<if test="alarmtime != null" >
alarmTime = #{alarmtime,jdbcType=TIMESTAMP},
</if>
<if test="alarmreason != null" >
alarmReason = #{alarmreason,jdbcType=VARCHAR},
</if>
<if test="handlereault != null" >
handleReault = #{handlereault,jdbcType=VARCHAR},
</if>
<if test="handledt != null" >
handledt = #{handledt,jdbcType=VARCHAR},
</if>
<if test="handleuser != null" >
handleuser = #{handleuser,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=VARCHAR},
</if>
<if test="temperature != null" >
temperature = #{temperature,jdbcType=VARCHAR},
</if>
<if test="humidity != null" >
humidity = #{humidity,jdbcType=VARCHAR},
</if>
<if test="dust != null" >
dust = #{dust,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.clean.alarmhandle" >
update tb_clean_alarmhandle
set alarmPonit = #{alarmponit,jdbcType=VARCHAR},
alarmType = #{alarmtype,jdbcType=VARCHAR},
alarmTime = #{alarmtime,jdbcType=TIMESTAMP},
alarmReason = #{alarmreason,jdbcType=VARCHAR},
handleReault = #{handlereault,jdbcType=VARCHAR},
handledt = #{handledt,jdbcType=VARCHAR},
handleuser = #{handleuser,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=VARCHAR},
temperature = #{temperature,jdbcType=VARCHAR},
humidity = #{humidity,jdbcType=VARCHAR},
dust = #{dust,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap"
parameterType="java.lang.String">
select
<include refid="Base_Column_List" />
from tb_clean_alarmhandle
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_clean_alarmhandle
${where}
</delete>
</mapper>

View File

@ -0,0 +1,245 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="document.DataMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.document.Data">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="doctype" jdbcType="VARCHAR" property="doctype" />
<result column="docname" jdbcType="VARCHAR" property="docname" />
<result column="number" jdbcType="VARCHAR" property="number" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="updateuser" jdbcType="VARCHAR" property="updateuser" />
<result column="updatedt" jdbcType="TIMESTAMP" property="updatedt" />
<result column="memo" jdbcType="VARCHAR" property="memo" />
<result column="path" jdbcType="VARCHAR" property="path" />
<result column="st" jdbcType="VARCHAR" property="st" />
<result column="level" jdbcType="INTEGER" property="level" />
<result column="pid" jdbcType="VARCHAR" property="pid" />
</resultMap>
<resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.sipai.entity.document.Data">
<result column="details" jdbcType="CLOB" property="details" />
</resultMap>
<sql id="Base_Column_List">
id, doctype, docname, number, details, insuser, insdt, updateuser, updatedt, memo, path, st, pid
</sql>
<sql id="Blob_Column_List">
details
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="ResultMapWithBLOBs">
select
<include refid="Base_Column_List" />
,
<include refid="Blob_Column_List" />
from tb_doc_data
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="selectList" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
,
<include refid="Blob_Column_List" />
from tb_doc_data
order by number
</select>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_doc_data
${where}
</select>
<select id="getListByNumberAndType" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_doc_data
where number = #{number,jdbcType=VARCHAR} and doctype = #{doctype,jdbcType=VARCHAR}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_doc_data
${where}
</delete>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_doc_data
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.document.Data">
insert into tb_doc_data (id, doctype, docname,
number, insuser, insdt,
updateuser, updatedt, memo,
path, st, level, pid,
details)
values (#{id,jdbcType=VARCHAR}, #{doctype,jdbcType=VARCHAR}, #{docname,jdbcType=VARCHAR},
#{number,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{updateuser,jdbcType=VARCHAR}, #{updatedt,jdbcType=TIMESTAMP}, #{memo,jdbcType=VARCHAR},
#{path,jdbcType=VARCHAR}, #{st,jdbcType=VARCHAR}, #{level,jdbcType=INTEGER}, #{pid,jdbcType=VARCHAR},
#{details,jdbcType=CLOB})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.document.Data">
insert into tb_doc_data
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="doctype != null">
doctype,
</if>
<if test="docname != null">
docname,
</if>
<if test="number != null">
number,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="updateuser != null">
updateuser,
</if>
<if test="updatedt != null">
updatedt,
</if>
<if test="memo != null">
memo,
</if>
<if test="path != null">
path,
</if>
<if test="st != null">
st,
</if>
<if test="level != null">
level,
</if>
<if test="pid != null">
pid,
</if>
<if test="details != null">
details,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="doctype != null">
#{doctype,jdbcType=VARCHAR},
</if>
<if test="docname != null">
#{docname,jdbcType=VARCHAR},
</if>
<if test="number != null">
#{number,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="updateuser != null">
#{updateuser,jdbcType=VARCHAR},
</if>
<if test="updatedt != null">
#{updatedt,jdbcType=TIMESTAMP},
</if>
<if test="memo != null">
#{memo,jdbcType=VARCHAR},
</if>
<if test="path != null">
#{path,jdbcType=VARCHAR},
</if>
<if test="st != null">
#{st,jdbcType=VARCHAR},
</if>
<if test="level != null">
#{level,jdbcType=INTEGER},
</if>
<if test="pid != null">
#{pid,jdbcType=VARCHAR},
</if>
<if test="details != null">
#{details,jdbcType=CLOB},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.document.Data">
update tb_doc_data
<set>
<if test="doctype != null">
doctype = #{doctype,jdbcType=VARCHAR},
</if>
<if test="docname != null">
docname = #{docname,jdbcType=VARCHAR},
</if>
<if test="number != null">
number = #{number,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="updateuser != null">
updateuser = #{updateuser,jdbcType=VARCHAR},
</if>
<if test="updatedt != null">
updatedt = #{updatedt,jdbcType=TIMESTAMP},
</if>
<if test="memo != null">
memo = #{memo,jdbcType=VARCHAR},
</if>
<if test="path != null">
path = #{path,jdbcType=VARCHAR},
</if>
<if test="st != null">
st = #{st,jdbcType=VARCHAR},
</if>
<if test="level != null">
level = #{level,jdbcType=INTEGER},
</if>
<if test="pid != null">
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="details != null">
details = #{details,jdbcType=CLOB},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKeyWithBLOBs" parameterType="com.sipai.entity.document.Data">
update tb_doc_data
set doctype = #{doctype,jdbcType=VARCHAR},
docname = #{docname,jdbcType=VARCHAR},
number = #{number,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
updateuser = #{updateuser,jdbcType=VARCHAR},
updatedt = #{updatedt,jdbcType=TIMESTAMP},
memo = #{memo,jdbcType=VARCHAR},
path = #{path,jdbcType=VARCHAR},
st = #{st,jdbcType=VARCHAR},
level = #{level,jdbcType=INTEGER},
pid = #{pid,jdbcType=VARCHAR},
details = #{details,jdbcType=CLOB}
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.document.Data">
update tb_doc_data
set doctype = #{doctype,jdbcType=VARCHAR},
docname = #{docname,jdbcType=VARCHAR},
number = #{number,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
updateuser = #{updateuser,jdbcType=VARCHAR},
updatedt = #{updatedt,jdbcType=TIMESTAMP},
memo = #{memo,jdbcType=VARCHAR},
path = #{path,jdbcType=VARCHAR},
st = #{st,jdbcType=VARCHAR},
level = #{level,jdbcType=INTEGER},
pid = #{pid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
</mapper>

View File

@ -0,0 +1,140 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="document.DocFileMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.base.CommonFile" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="masterid" property="masterid" jdbcType="VARCHAR" />
<result column="filename" property="filename" jdbcType="VARCHAR" />
<result column="abspath" property="abspath" jdbcType="VARCHAR" />
<result column="size" property="size" jdbcType="INTEGER" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="type" property="type" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, masterid, filename, abspath, size, insuser, insdt, type
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_doc_file
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_doc_file
where id = #{id,jdbcType=VARCHAR}
</delete>
<delete id="deleteByMasterId" parameterType="java.lang.String" >
delete from tb_doc_file
where masterid = #{masterid,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.base.CommonFile" >
insert into tb_doc_file (id, masterid, filename,
abspath, size, insuser,
insdt, type)
values (#{id,jdbcType=VARCHAR}, #{masterid,jdbcType=VARCHAR}, #{filename,jdbcType=VARCHAR},
#{abspath,jdbcType=VARCHAR}, #{size,jdbcType=INTEGER}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{type,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.base.CommonFile" >
insert into tb_doc_file
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="masterid != null" >
masterid,
</if>
<if test="filename != null" >
filename,
</if>
<if test="abspath != null" >
abspath,
</if>
<if test="size != null" >
size,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="type != null" >
type,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="masterid != null" >
#{masterid,jdbcType=VARCHAR},
</if>
<if test="filename != null" >
#{filename,jdbcType=VARCHAR},
</if>
<if test="abspath != null" >
#{abspath,jdbcType=VARCHAR},
</if>
<if test="size != null" >
#{size,jdbcType=INTEGER},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="type != null" >
#{type,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.base.CommonFile" >
update tb_doc_file
<set >
<if test="masterid != null" >
masterid = #{masterid,jdbcType=VARCHAR},
</if>
<if test="filename != null" >
filename = #{filename,jdbcType=VARCHAR},
</if>
<if test="abspath != null" >
abspath = #{abspath,jdbcType=VARCHAR},
</if>
<if test="size != null" >
size = #{size,jdbcType=INTEGER},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="type != null" >
type = #{type,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.base.CommonFile" >
update tb_doc_file
set masterid = #{masterid,jdbcType=VARCHAR},
filename = #{filename,jdbcType=VARCHAR},
abspath = #{abspath,jdbcType=VARCHAR},
size = #{size,jdbcType=INTEGER},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
type = #{type,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectByMasterId" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_doc_file
where masterid = #{masterid,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,128 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="document.DoctypeMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.document.Doctype" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="level" property="level" jdbcType="INTEGER" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="updateuser" property="updateuser" jdbcType="VARCHAR" />
<result column="updatedt" property="updatedt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, name, pid, level, insuser, insdt, updateuser, updatedt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_doc_doctype
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_doc_doctype
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.document.Doctype" >
insert into tb_doc_doctype (id, name, pid,
level, insuser, insdt,
updateuser, updatedt)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR},
#{level,jdbcType=INTEGER}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{updateuser,jdbcType=VARCHAR}, #{updatedt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.document.Doctype" >
insert into tb_doc_doctype
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="name != null" >
name,
</if>
<if test="pid != null" >
pid,
</if>
<if test="level != null" >
level,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="updateuser != null" >
updateuser,
</if>
<if test="updatedt != null" >
updatedt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="level != null" >
#{level,jdbcType=INTEGER},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="updateuser != null" >
#{updateuser,jdbcType=VARCHAR},
</if>
<if test="updatedt != null" >
#{updatedt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.document.Doctype" >
update tb_doc_doctype
<set >
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="level != null" >
level = #{level,jdbcType=INTEGER},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="updateuser != null" >
updateuser = #{updateuser,jdbcType=VARCHAR},
</if>
<if test="updatedt != null" >
updatedt = #{updatedt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.document.Doctype" >
update tb_doc_doctype
set name = #{name,jdbcType=VARCHAR},
pid = #{pid,jdbcType=VARCHAR},
level = #{level,jdbcType=INTEGER},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
updateuser = #{updateuser,jdbcType=VARCHAR},
updatedt = #{updatedt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
</mapper>

View File

@ -0,0 +1,198 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="equipment.EquipmentArrangementMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.EquipmentArrangement">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="workorderid" jdbcType="VARCHAR" property="workorderid" />
<result column="taskcode" jdbcType="VARCHAR" property="taskcode" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="equipmentid" jdbcType="VARCHAR" property="equipmentid" />
<result column="arrangementdate" jdbcType="TIMESTAMP" property="arrangementdate" />
<result column="groupManageid" jdbcType="CHAR" property="groupManageid" />
<result column="stdt" jdbcType="TIMESTAMP" property="stdt" />
<result column="enddt" jdbcType="TIMESTAMP" property="enddt" />
</resultMap>
<sql id="Base_Column_List">
id, workorderid, taskcode, insdt, insuser, equipmentid, arrangementdate, groupManageid,
stdt, enddt
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_EM_Arrangement
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from TB_EM_Arrangement
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.EquipmentArrangement">
insert into TB_EM_Arrangement (id, workorderid, taskcode,
insdt, insuser, equipmentid,
arrangementdate, groupManageid, stdt,
enddt)
values (#{id,jdbcType=VARCHAR}, #{workorderid,jdbcType=VARCHAR}, #{taskcode,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{insuser,jdbcType=VARCHAR}, #{equipmentid,jdbcType=VARCHAR},
#{arrangementdate,jdbcType=TIMESTAMP}, #{groupManageid,jdbcType=CHAR}, #{stdt,jdbcType=TIMESTAMP},
#{enddt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.EquipmentArrangement">
insert into TB_EM_Arrangement
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="workorderid != null">
workorderid,
</if>
<if test="taskcode != null">
taskcode,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="equipmentid != null">
equipmentid,
</if>
<if test="arrangementdate != null">
arrangementdate,
</if>
<if test="groupManageid != null">
groupManageid,
</if>
<if test="stdt != null">
stdt,
</if>
<if test="enddt != null">
enddt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="workorderid != null">
#{workorderid,jdbcType=VARCHAR},
</if>
<if test="taskcode != null">
#{taskcode,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="equipmentid != null">
#{equipmentid,jdbcType=VARCHAR},
</if>
<if test="arrangementdate != null">
#{arrangementdate,jdbcType=TIMESTAMP},
</if>
<if test="groupManageid != null">
#{groupManageid,jdbcType=CHAR},
</if>
<if test="stdt != null">
#{stdt,jdbcType=TIMESTAMP},
</if>
<if test="enddt != null">
#{enddt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.EquipmentArrangement">
update TB_EM_Arrangement
<set>
<if test="workorderid != null">
workorderid = #{workorderid,jdbcType=VARCHAR},
</if>
<if test="taskcode != null">
taskcode = #{taskcode,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="equipmentid != null">
equipmentid = #{equipmentid,jdbcType=VARCHAR},
</if>
<if test="arrangementdate != null">
arrangementdate = #{arrangementdate,jdbcType=TIMESTAMP},
</if>
<if test="groupManageid != null">
groupManageid = #{groupManageid,jdbcType=CHAR},
</if>
<if test="stdt != null">
stdt = #{stdt,jdbcType=TIMESTAMP},
</if>
<if test="enddt != null">
enddt = #{enddt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.EquipmentArrangement">
update TB_EM_Arrangement
set workorderid = #{workorderid,jdbcType=VARCHAR},
taskcode = #{taskcode,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
equipmentid = #{equipmentid,jdbcType=VARCHAR},
arrangementdate = #{arrangementdate,jdbcType=TIMESTAMP},
groupManageid = #{groupManageid,jdbcType=CHAR},
stdt = #{stdt,jdbcType=TIMESTAMP},
enddt = #{enddt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_EM_Arrangement
${where}
</select>
<select id="selectByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_EM_Arrangement
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from TB_EM_Arrangement
${where}
</delete>
<resultMap id="ResultMap_groupManage" type="com.sipai.entity.equipment.EquipmentArrangement">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="workorderid" jdbcType="VARCHAR" property="workorderid" />
<result column="taskcode" jdbcType="VARCHAR" property="taskcode" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="equipmentid" jdbcType="VARCHAR" property="equipmentid" />
<result column="arrangementdate" jdbcType="TIMESTAMP" property="arrangementdate" />
<result column="groupManageid" jdbcType="CHAR" property="groupManageid" />
<result column="stdt" jdbcType="TIMESTAMP" property="stdt" />
<result column="enddt" jdbcType="TIMESTAMP" property="enddt" />
<result column="gt_sdt" jdbcType="TIMESTAMP" property="gt_sdt" />
<result column="gt_enddt" jdbcType="TIMESTAMP" property="gt_enddt" />
<result column="gt_name" jdbcType="VARCHAR" property="gt_name" />
<result column="gt_id" jdbcType="VARCHAR" property="gt_id" />
</resultMap>
<!-- 查看设备按班次的安排情况 -->
<select id="selectEquipArrangementByWhere" parameterType="java.lang.String" resultMap="ResultMap_groupManage">
select gt.sdt as gt_sdt,gt.edt as gt_enddt,gt.name as gt_name,gt.id as groupManageid,
agresult.*
from tb_work_groupManage gt
left join (select * from TB_EM_Arrangement
${where}
)agresult
on gt.id=agresult.groupManageid order by agresult.stdt asc
</select>
</mapper>

View File

@ -0,0 +1,362 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="equipment.EquipmentCardMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.EquipmentCard" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="VARCHAR" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="equipmentClassID" property="equipmentclassid" jdbcType="VARCHAR" />
<result column="equipmentModel" property="equipmentmodel" jdbcType="VARCHAR" />
<result column="areaID" property="areaid" jdbcType="VARCHAR" />
<result column="currentManageFlag" property="currentmanageflag" jdbcType="VARCHAR" />
<result column="equipmentName" property="equipmentname" jdbcType="CLOB" />
<result column="remark" property="remark" jdbcType="CLOB" />
<result column="equipmentManufacturer" property="equipmentmanufacturer" jdbcType="VARCHAR" />
<result column="responsiblePerson" property="responsibleperson" jdbcType="VARCHAR" />
<result column="storageLocation" property="storagelocation" jdbcType="VARCHAR" />
<result column="equipmentValue" property="equipmentvalue" jdbcType="VARCHAR" />
<result column="productionDate" property="productiondate" jdbcType="TIMESTAMP" />
<result column="responsibleDepartment" property="responsibledepartment" jdbcType="VARCHAR" />
<result column="equipmentClas" property="equipmentclas" jdbcType="VARCHAR" />
<result column="equipmentStatus" property="equipmentstatus" jdbcType="VARCHAR" />
</resultMap>
<!-- <resultMap id="ResultMapWithBLOBs" type="com.sipai.entity.equipment.EquipmentCardWithBLOBs" extends="BaseResultMap" > -->
<!-- <result column="equipmentName" property="equipmentname" jdbcType="CLOB" /> -->
<!-- <result column="remark" property="remark" jdbcType="CLOB" /> -->
<!-- </resultMap> -->
<sql id="Base_Column_List" >
id, insuser, insdt, equipmentCardID, equipmentClassID, equipmentModel, areaID, currentManageFlag,equipmentName, remark,
equipmentManufacturer, responsiblePerson, storageLocation, equipmentValue, productionDate,
responsibleDepartment,equipmentClas,equipmentStatus
</sql>
<!-- <sql id="Blob_Column_List" > -->
<!-- equipmentName, remark -->
<!-- </sql> -->
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentCard
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_EM_EquipmentCard
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.EquipmentCard" >
insert into TB_EM_EquipmentCard (id, insuser, insdt,
equipmentCardID, equipmentClassID, equipmentModel,
areaID, currentManageFlag, equipmentName,
remark, equipmentManufacturer, responsiblePerson, storageLocation, equipmentValue, productionDate,
responsibleDepartment,equipmentClas,equipmentStatus)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=VARCHAR},
#{equipmentcardid,jdbcType=VARCHAR}, #{equipmentclassid,jdbcType=VARCHAR}, #{equipmentmodel,jdbcType=VARCHAR},
#{areaid,jdbcType=VARCHAR}, #{currentmanageflag,jdbcType=VARCHAR}, #{equipmentname,jdbcType=CLOB},
#{remark,jdbcType=CLOB},#{equipmentmanufacturer,jdbcType=VARCHAR},
#{responsibleperson,jdbcType=VARCHAR}, #{storagelocation,jdbcType=VARCHAR}, #{equipmentvalue,jdbcType=VARCHAR},
#{productiondate,jdbcType=TIMESTAMP}, #{responsibledepartment,jdbcType=VARCHAR},
#{equipmentclas,jdbcType=VARCHAR},#{equipmentstatus,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.EquipmentCard" >
insert into TB_EM_EquipmentCard
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="equipmentcardid != null" >
equipmentCardID,
</if>
<if test="equipmentclassid != null" >
equipmentClassID,
</if>
<if test="equipmentmodel != null" >
equipmentModel,
</if>
<if test="areaid != null" >
areaID,
</if>
<if test="currentmanageflag != null" >
currentManageFlag,
</if>
<if test="equipmentname != null" >
equipmentName,
</if>
<if test="remark != null" >
remark,
</if>
<if test="equipmentmanufacturer != null" >
equipmentManufacturer,
</if>
<if test="responsibleperson != null" >
responsiblePerson,
</if>
<if test="storagelocation != null" >
storageLocation,
</if>
<if test="equipmentvalue != null" >
equipmentValue,
</if>
<if test="productiondate != null" >
productionDate,
</if>
<if test="responsibledepartment != null" >
responsibleDepartment,
</if>
<if test="equipmentclas != null" >
equipmentClas,
</if>
<if test="equipmentstatus != null" >
equipmentStatus,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
#{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="equipmentclassid != null" >
#{equipmentclassid,jdbcType=VARCHAR},
</if>
<if test="equipmentmodel != null" >
#{equipmentmodel,jdbcType=VARCHAR},
</if>
<if test="areaid != null" >
#{areaid,jdbcType=VARCHAR},
</if>
<if test="currentmanageflag != null" >
#{currentmanageflag,jdbcType=VARCHAR},
</if>
<if test="equipmentname != null" >
#{equipmentname,jdbcType=CLOB},
</if>
<if test="remark != null" >
#{remark,jdbcType=CLOB},
</if>
<if test="equipmentmanufacturer != null" >
#{equipmentmanufacturer,jdbcType=VARCHAR},
</if>
<if test="responsibleperson != null" >
#{responsibleperson,jdbcType=VARCHAR},
</if>
<if test="storagelocation != null" >
#{storagelocation,jdbcType=VARCHAR},
</if>
<if test="equipmentvalue != null" >
#{equipmentvalue,jdbcType=VARCHAR},
</if>
<if test="productiondate != null" >
#{productiondate,jdbcType=TIMESTAMP},
</if>
<if test="responsibledepartment != null" >
#{responsibledepartment,jdbcType=VARCHAR},
</if>
<if test="equipmentclas!= null" >
#{equipmentclas,jdbcType=VARCHAR},
</if>
<if test="equipmentstatus!= null" >
#{equipmentstatus,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.EquipmentCard" >
update TB_EM_EquipmentCard
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="equipmentclassid != null" >
equipmentClassID = #{equipmentclassid,jdbcType=VARCHAR},
</if>
<if test="equipmentmodel != null" >
equipmentModel = #{equipmentmodel,jdbcType=VARCHAR},
</if>
<if test="areaid != null" >
areaID = #{areaid,jdbcType=VARCHAR},
</if>
<if test="currentmanageflag != null" >
currentManageFlag = #{currentmanageflag,jdbcType=VARCHAR},
</if>
<if test="equipmentname != null" >
equipmentName = #{equipmentname,jdbcType=CLOB},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=CLOB},
</if>
<if test="equipmentmanufacturer != null" >
equipmentManufacturer = #{equipmentmanufacturer,jdbcType=VARCHAR},
</if>
<if test="responsibleperson != null" >
responsiblePerson = #{responsibleperson,jdbcType=VARCHAR},
</if>
<if test="storagelocation != null" >
storageLocation = #{storagelocation,jdbcType=VARCHAR},
</if>
<if test="equipmentvalue != null" >
equipmentValue = #{equipmentvalue,jdbcType=VARCHAR},
</if>
<if test="productiondate != null" >
productionDate = #{productiondate,jdbcType=TIMESTAMP},
</if>
<if test="responsibledepartment != null" >
responsibleDepartment = #{responsibledepartment,jdbcType=VARCHAR},
</if>
<if test=" equipmentclas != null" >
equipmentClas = #{equipmentclas,jdbcType=VARCHAR},
</if>
<if test=" equipmentstatus != null" >
equipmentStatus = #{ equipmentstatus,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.EquipmentCard" >
update TB_EM_EquipmentCard
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=VARCHAR},
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
equipmentClassID = #{equipmentclassid,jdbcType=VARCHAR},
equipmentModel = #{equipmentmodel,jdbcType=VARCHAR},
areaID = #{areaid,jdbcType=VARCHAR},
currentManageFlag = #{currentmanageflag,jdbcType=VARCHAR},
equipmentName = #{equipmentname,jdbcType=CLOB},
remark = #{remark,jdbcType=CLOB},
equipmentManufacturer = #{equipmentmanufacturer,jdbcType=VARCHAR},
responsiblePerson = #{responsibleperson,jdbcType=VARCHAR},
storageLocation = #{storagelocation,jdbcType=VARCHAR},
equipmentValue = #{equipmentvalue,jdbcType=VARCHAR},
productionDate = #{productiondate,jdbcType=TIMESTAMP},
responsibleDepartment = #{responsibledepartment,jdbcType=VARCHAR},
equipmentClas = #{equipmentclas,jdbcType=VARCHAR},
equipmentStatus = #{equipmentstatus,jdbcType=VARCHAR},
where id = #{id,jdbcType=VARCHAR}
</update>
<!-- <update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.EquipmentCard" >
update TB_EM_EquipmentCard
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=VARCHAR},
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
equipmentClassID = #{equipmentclassid,jdbcType=VARCHAR},
equipmentModel = #{equipmentmodel,jdbcType=VARCHAR},
areaID = #{areaid,jdbcType=VARCHAR},
currentManageFlag = #{currentmanageflag,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update> -->
<select id="selectList" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentCard
order by equipmentName
</select>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentCard
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentCard
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_EM_EquipmentCard
${where}
</delete>
<select id="getEquipmentCard" resultMap="ClassResultMapEquipmentCard" parameterType="java.lang.String">
SELECT
E.id as e_id,
E.equipmentCardID,
E.equipmentName,
E.equipmentClassID,
E.equipmentModel,
E.areaID,
E.currentManageFlag,
E.equipmentManufacturer,
E.responsiblePerson,
E.storageLocation,
E.equipmentValue,
E.productionDate,
E.responsibleDepartment,
E.equipmentClas,
E.equipmentStatus,
E.remark as e_remark,
E.insuser as e_insuser,
E.insdt as e_insdt,
C.id as c_id,
C.name as c_name,
C.status as c_status,
G.id as g_id,
G.name as g_name,
G.status as g_status
FROM TB_EM_EquipmentCard E
LEFT OUTER JOIN TB_EM_EquipmentClass C ON C.id = E.equipmentClassID
LEFT OUTER JOIN TB_EM_GeographyArea G ON G.id = E.areaID
${where}
</select>
<resultMap id="ClassResultMapEquipmentCard" type="com.sipai.entity.equipment.EquipmentCard">
<id property="id" column="e_id" />
<result property="equipmentcardid" column="equipmentCardID"/>
<result property="equipmentname" column="equipmentName"/>
<result property="equipmentclassid" column="equipmentClassID"/>
<result property="equipmentmodel" column="equipmentModel"/>
<result property="areaid" column="areaID"/>
<result property="currentmanageflag" column="currentManageFlag"/>
<result property="remark" column="e_remark"/>
<result column="equipmentManufacturer" property="equipmentmanufacturer" jdbcType="VARCHAR" />
<result column="responsiblePerson" property="responsibleperson" jdbcType="VARCHAR" />
<result column="storageLocation" property="storagelocation" jdbcType="VARCHAR" />
<result column="equipmentValue" property="equipmentvalue" jdbcType="VARCHAR" />
<result column="productionDate" property="productiondate" jdbcType="TIMESTAMP" />
<result column="responsibleDepartment" property="responsibledepartment" jdbcType="VARCHAR" />
<result property="equipmentclas" column="equipmentClas"/>
<result property="equipmentstatus" column="equipmentStatus"/>
<result property="insuser" column="e_insuser"/>
<result property="insdt" column="e_insdt"/>
<association property="equipmentclass" resultMap="equipmentclassResult" />
<association property="geographyarea" resultMap="geographyareaResult" />
</resultMap>
<resultMap id="equipmentclassResult" type="com.sipai.entity.equipment.EquipmentClass">
<id property="id" column="c_id"/>
<result property="name" column="c_name"/>
<result property="status" column="c_status"/>
</resultMap>
<resultMap id="geographyareaResult" type="com.sipai.entity.equipment.GeographyArea">
<id property="id" column="g_id"/>
<result property="name" column="g_name"/>
<result property="status" column="g_status"/>
</resultMap>
<select id="getEquipmentCardByCardId" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentCard
where equipmentcardId = #{equipmentcardid,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,186 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="equipment.EquipmentClassMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.EquipmentClass" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="bizid" property="bizid" jdbcType="VARCHAR" />
<result column="code" property="code" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="flag" property="flag" jdbcType="VARCHAR" />
<result column=" interfacetype" property=" interfacetype" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, name, insdt, insuser, remark, status, bizid, code, pid, flag, interfacetype
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentClass
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_EM_EquipmentClass
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.EquipmentClass" >
insert into TB_EM_EquipmentClass (id, name, insdt,
insuser, remark, status,
bizid, code, pid, flag,
interfacetype
)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{insuser,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR},
#{bizid,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{flag,jdbcType=VARCHAR},
#{interfacetype,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.EquipmentClass" >
insert into TB_EM_EquipmentClass
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="name != null" >
name,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="remark != null" >
remark,
</if>
<if test="status != null" >
status,
</if>
<if test="bizid != null" >
bizid,
</if>
<if test="code != null" >
code,
</if>
<if test="pid != null" >
pid,
</if>
<if test="flag != null" >
flag,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="bizid != null" >
#{bizid,jdbcType=VARCHAR},
</if>
<if test="code != null" >
#{code,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="flag != null" >
#{flag,jdbcType=VARCHAR},
</if>
<if test="interfacetype != null" >
#{ interfacetype,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.EquipmentClass" >
update TB_EM_EquipmentClass
<set >
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="bizid != null" >
bizid = #{bizid,jdbcType=VARCHAR},
</if>
<if test="code != null" >
code = #{code,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="flag != null" >
flag = #{flag,jdbcType=VARCHAR},
</if>
<if test="interfacetype != null" >
interfacetype = #{interfacetype,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.EquipmentClass" >
update TB_EM_EquipmentClass
set name = #{name,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
bizid = #{bizid,jdbcType=VARCHAR},
code = #{code,jdbcType=VARCHAR},
pid = #{pid,jdbcType=VARCHAR},
flag = #{flag,jdbcType=VARCHAR},
interfacetype = #{interfacetype,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectList" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentClass
order by name
</select>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentClass
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentClass
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_EM_EquipmentClass
${where}
</delete>
</mapper>

View File

@ -0,0 +1,215 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="equipment.EquipmentMaintainMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.EquipmentMaintain">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="equipmentCardID" jdbcType="VARCHAR" property="equipmentcardid" />
<result column="equipmentName" jdbcType="VARCHAR" property="equipmentname" />
<result column="equipmentClassID" jdbcType="VARCHAR" property="equipmentclassid" />
<result column="equipmentModel" jdbcType="VARCHAR" property="equipmentmodel" />
<result column="areaID" jdbcType="VARCHAR" property="areaid" />
<result column="currentManageFlag" jdbcType="VARCHAR" property="currentmanageflag" />
<result column="describe" jdbcType="VARCHAR" property="describe" />
<result column="maintenanceman" jdbcType="VARCHAR" property="maintenanceman" />
<result column="time" jdbcType="TIMESTAMP" property="time"/>
<result column="equipmentcode" property="equipmentcode" jdbcType="VARCHAR"/>
<result column="mancaption" property="mancaption" jdbcType="VARCHAR"/>
</resultMap>
<sql id="Base_Column_List">
id, insuser, insdt, equipmentCardID, equipmentName, equipmentClassID, equipmentModel,
areaID, currentManageFlag, describe, maintenanceman, time
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentMaintain
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from TB_EM_EquipmentMaintain
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.EquipmentMaintain">
insert into TB_EM_EquipmentMaintain (id, insuser, insdt,
equipmentCardID, equipmentName, equipmentClassID,
equipmentModel, areaID, currentManageFlag,
describe, maintenanceman, time
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{equipmentcardid,jdbcType=VARCHAR}, #{equipmentname,jdbcType=VARCHAR}, #{equipmentclassid,jdbcType=VARCHAR},
#{equipmentmodel,jdbcType=VARCHAR}, #{areaid,jdbcType=VARCHAR}, #{currentmanageflag,jdbcType=VARCHAR},
#{describe,jdbcType=VARCHAR}, #{maintenanceman,jdbcType=VARCHAR}, #{time,jdbcType=TIMESTAMP}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.EquipmentMaintain">
insert into TB_EM_EquipmentMaintain
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="equipmentcardid != null">
equipmentCardID,
</if>
<if test="equipmentname != null">
equipmentName,
</if>
<if test="equipmentclassid != null">
equipmentClassID,
</if>
<if test="equipmentmodel != null">
equipmentModel,
</if>
<if test="areaid != null">
areaID,
</if>
<if test="currentmanageflag != null">
currentManageFlag,
</if>
<if test="describe != null">
describe,
</if>
<if test="maintenanceman != null">
maintenanceman,
</if>
<if test="time != null">
time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="equipmentcardid != null">
#{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="equipmentname != null">
#{equipmentname,jdbcType=VARCHAR},
</if>
<if test="equipmentclassid != null">
#{equipmentclassid,jdbcType=VARCHAR},
</if>
<if test="equipmentmodel != null">
#{equipmentmodel,jdbcType=VARCHAR},
</if>
<if test="areaid != null">
#{areaid,jdbcType=VARCHAR},
</if>
<if test="currentmanageflag != null">
#{currentmanageflag,jdbcType=VARCHAR},
</if>
<if test="describe != null">
#{describe,jdbcType=VARCHAR},
</if>
<if test="maintenanceman != null">
#{maintenanceman,jdbcType=VARCHAR},
</if>
<if test="time != null">
#{time,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.EquipmentMaintain">
update TB_EM_EquipmentMaintain
<set>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="equipmentcardid != null">
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="equipmentname != null">
equipmentName = #{equipmentname,jdbcType=VARCHAR},
</if>
<if test="equipmentclassid != null">
equipmentClassID = #{equipmentclassid,jdbcType=VARCHAR},
</if>
<if test="equipmentmodel != null">
equipmentModel = #{equipmentmodel,jdbcType=VARCHAR},
</if>
<if test="areaid != null">
areaID = #{areaid,jdbcType=VARCHAR},
</if>
<if test="currentmanageflag != null">
currentManageFlag = #{currentmanageflag,jdbcType=VARCHAR},
</if>
<if test="describe != null">
describe = #{describe,jdbcType=VARCHAR},
</if>
<if test="maintenanceman != null">
maintenanceman = #{maintenanceman,jdbcType=VARCHAR},
</if>
<if test="time != null">
time = #{time,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.EquipmentMaintain">
update TB_EM_EquipmentMaintain
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
equipmentName = #{equipmentname,jdbcType=VARCHAR},
equipmentClassID = #{equipmentclassid,jdbcType=VARCHAR},
equipmentModel = #{equipmentmodel,jdbcType=VARCHAR},
areaID = #{areaid,jdbcType=VARCHAR},
currentManageFlag = #{currentmanageflag,jdbcType=VARCHAR},
describe = #{describe,jdbcType=VARCHAR},
maintenanceman = #{maintenanceman,jdbcType=VARCHAR},
time = #{time,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentMaintain
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from TB_EM_EquipmentMaintain
${where}
</delete>
<select id="getEquipmentMaintain" parameterType="java.lang.String" resultMap="BaseResultMap">
SELECT
E.id,
E.equipmentCardID ,
C.equipmentName as equipmentname,
A.name as equipmentclassid,
C.equipmentModel as equipmentmodel,
G.name as areaid,
C.currentManageFlag as currentManageflag,
E.maintenanceman as maintenanceman,
E.time as time,
E.describe as describe,
C.equipmentCardID as equipmentcode,
U.caption as mancaption
FROM TB_EM_EquipmentMaintain E
Left outer join TB_EM_EquipmentCard C On E.equipmentCardID = C.id
Left outer join tb_user U ON U.id = E.maintenanceman
left outer join TB_EM_GeographyArea G on C.areaID = G.id
left outer join TB_EM_EquipmentClass A on A.id = C.equipmentClassID
${where}
</select>
</mapper>

View File

@ -0,0 +1,128 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="equipment.EquipmentPointMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.EquipmentPoint" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="equipmentCardid" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="pointId" property="pointid" jdbcType="VARCHAR" />
<result column="equipmentCardName" property="equipmentcardname" jdbcType="VARCHAR" />
<result column="pointName" property="pointname" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insdt, insuser, equipmentCardid, pointId, equipmentCardName, pointName
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentPoint
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_EM_EquipmentPoint
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.EquipmentPoint" >
insert into TB_EM_EquipmentPoint (id, insdt, insuser,
equipmentCardid, pointId, equipmentCardName,
pointName)
values (#{id,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{insuser,jdbcType=VARCHAR},
#{equipmentcardid,jdbcType=VARCHAR}, #{pointid,jdbcType=VARCHAR}, #{equipmentcardname,jdbcType=VARCHAR},
#{pointname,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.EquipmentPoint" >
insert into TB_EM_EquipmentPoint
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="equipmentcardid != null" >
equipmentCardid,
</if>
<if test="pointid != null" >
pointId,
</if>
<if test="equipmentcardname != null" >
equipmentCardName,
</if>
<if test="pointname != null" >
pointName,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
#{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="pointid != null" >
#{pointid,jdbcType=VARCHAR},
</if>
<if test="equipmentcardname != null" >
#{equipmentcardname,jdbcType=VARCHAR},
</if>
<if test="pointname != null" >
#{pointname,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.EquipmentPoint" >
update TB_EM_EquipmentPoint
<set >
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
equipmentCardid = #{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="pointid != null" >
pointId = #{pointid,jdbcType=VARCHAR},
</if>
<if test="equipmentcardname != null" >
equipmentCardName = #{equipmentcardname,jdbcType=VARCHAR},
</if>
<if test="pointname != null" >
pointName = #{pointname,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.EquipmentPoint" >
update TB_EM_EquipmentPoint
set insdt = #{insdt,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
equipmentCardid = #{equipmentcardid,jdbcType=VARCHAR},
pointId = #{pointid,jdbcType=VARCHAR},
equipmentCardName = #{equipmentcardname,jdbcType=VARCHAR},
pointName = #{pointname,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_EquipmentPoint
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_EM_EquipmentPoint
${where}
</delete>
</mapper>

View File

@ -0,0 +1,161 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="equipment.GeographyAreaMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.GeographyArea" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="bizid" property="bizid" jdbcType="VARCHAR" />
<result column="code" property="code" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, name, insdt, insuser, remark, status, bizid, code, pid
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_GeographyArea
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_EM_GeographyArea
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.GeographyArea" >
insert into TB_EM_GeographyArea (id, name, insdt,
insuser, remark, status,
bizid, code, pid)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{insuser,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR},
#{bizid,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.GeographyArea" >
insert into TB_EM_GeographyArea
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="name != null" >
name,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="remark != null" >
remark,
</if>
<if test="status != null" >
status,
</if>
<if test="bizid != null" >
bizid,
</if>
<if test="code != null" >
code,
</if>
<if test="pid != null" >
pid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="bizid != null" >
#{bizid,jdbcType=VARCHAR},
</if>
<if test="code != null" >
#{code,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.GeographyArea" >
update TB_EM_GeographyArea
<set >
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="bizid != null" >
bizid = #{bizid,jdbcType=VARCHAR},
</if>
<if test="code != null" >
code = #{code,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.GeographyArea" >
update TB_EM_GeographyArea
set name = #{name,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
bizid = #{bizid,jdbcType=VARCHAR},
code = #{code,jdbcType=VARCHAR},
pid = #{pid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectList" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_GeographyArea
order by name
</select>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_GeographyArea
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_EM_GeographyArea
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_EM_GeographyArea
${where}
</delete>
</mapper>

View File

@ -0,0 +1,122 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="equipment.MaintenancePlanEquipmentMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.MaintenancePlanEquipment" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="maintenanceplanid" property="maintenanceplanid" jdbcType="VARCHAR" />
<result column="EquipmentCardid" property="equipmentcardid" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, maintenanceplanid, EquipmentCardid
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_equipment_maintenanceplan_equipmentcard
where id = #{id,jdbcType=VARCHAR}
</select>
<resultMap id="BaseResultMap1" type="com.sipai.entity.equipment.EquipmentCard" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="VARCHAR" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="equipmentClassID" property="equipmentclassid" jdbcType="VARCHAR" />
<result column="equipmentModel" property="equipmentmodel" jdbcType="VARCHAR" />
<result column="areaID" property="areaid" jdbcType="VARCHAR" />
<result column="currentManageFlag" property="currentmanageflag" jdbcType="VARCHAR" />
<result column="equipmentName" property="equipmentname" jdbcType="CLOB" />
<result column="remark" property="remark" jdbcType="CLOB" />
</resultMap>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_equipment_maintenanceplan_equipmentcard
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.MaintenancePlanEquipment" >
insert into tb_equipment_maintenanceplan_equipmentcard (id, insuser, insdt,
maintenanceplanid, EquipmentCardid)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{maintenanceplanid,jdbcType=VARCHAR}, #{equipmentcardid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.MaintenancePlanEquipment" >
insert into tb_equipment_maintenanceplan_equipmentcard
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="maintenanceplanid != null" >
maintenanceplanid,
</if>
<if test="equipmentcardid != null" >
EquipmentCardid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="maintenanceplanid != null" >
#{maintenanceplanid,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
#{equipmentcardid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.MaintenancePlanEquipment" >
update tb_equipment_maintenanceplan_equipmentcard
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="maintenanceplanid != null" >
maintenanceplanid = #{maintenanceplanid,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
EquipmentCardid = #{equipmentcardid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.MaintenancePlanEquipment" >
update tb_equipment_maintenanceplan_equipmentcard
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
maintenanceplanid = #{maintenanceplanid,jdbcType=VARCHAR},
EquipmentCardid = #{equipmentcardid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectEquipmentCard" resultMap="BaseResultMap1" parameterType="java.lang.String">
select tb_EM_EquipmentCard.* from tb_equipment_maintenanceplan_equipmentcard left join tb_EM_EquipmentCard
on tb_EM_EquipmentCard.id=tb_equipment_maintenanceplan_equipmentcard.EquipmentCardid
${where}
</select>
<select id="selectListByWhere" resultMap="BaseResultMap"
parameterType="java.lang.String">
select
<include refid="Base_Column_List" />
from tb_equipment_maintenanceplan_equipmentcard
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from
tb_equipment_maintenanceplan_equipmentcard
${where}
</delete>
</mapper>

View File

@ -0,0 +1,198 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="equipment.MaintenancePlanMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.MaintenancePlan" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="plantype" property="plantype" jdbcType="VARCHAR" />
<result column="plannumber" property="plannumber" jdbcType="VARCHAR" />
<result column="plancontent" property="plancontent" jdbcType="VARCHAR" />
<result column="condition" property="condition" jdbcType="VARCHAR" />
<result column="plantime" property="plantime" jdbcType="VARCHAR" />
<result column="realtime" property="realtime" jdbcType="VARCHAR" />
<result column="behaviordescription" property="behaviordescription" jdbcType="VARCHAR" />
<result column="performer" property="performer" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, plantype, plannumber, plancontent, condition, plantime, realtime,
behaviordescription, performer,remark
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_equipment_maintenanceplan
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="getListByPlanNumber" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_equipment_maintenanceplan
where plannumber = #{plannumber,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_equipment_maintenanceplan
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.MaintenancePlan" >
insert into tb_equipment_maintenanceplan (id, insuser, insdt,
plantype, plannumber, plancontent,
condition, plantime, realtime,
behaviordescription, performer,remark)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{plantype,jdbcType=VARCHAR}, #{plannumber,jdbcType=VARCHAR}, #{plancontent,jdbcType=VARCHAR},
#{condition,jdbcType=VARCHAR}, #{plantime,jdbcType=VARCHAR}, #{realtime,jdbcType=VARCHAR},
#{behaviordescription,jdbcType=VARCHAR}, #{performer,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.MaintenancePlan" >
insert into tb_plan_maintenanceplan
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="plantype != null" >
plantype,
</if>
<if test="plannumber != null" >
plannumber,
</if>
<if test="plancontent != null" >
plancontent,
</if>
<if test="condition != null" >
condition,
</if>
<if test="plantime != null" >
plantime,
</if>
<if test="realtime != null" >
realtime,
</if>
<if test="behaviordescription != null" >
behaviordescription,
</if>
<if test="performer != null" >
performer,
</if>
<if test="remark != null" >
remark,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plantype != null" >
#{plantype,jdbcType=VARCHAR},
</if>
<if test="plannumber != null" >
#{plannumber,jdbcType=VARCHAR},
</if>
<if test="plancontent != null" >
#{plancontent,jdbcType=VARCHAR},
</if>
<if test="condition != null" >
#{condition,jdbcType=VARCHAR},
</if>
<if test="plantime != null" >
#{plantime,jdbcType=VARCHAR},
</if>
<if test="realtime != null" >
#{realtime,jdbcType=VARCHAR},
</if>
<if test="behaviordescription != null" >
#{behaviordescription,jdbcType=VARCHAR},
</if>
<if test="performer != null" >
#{performer,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.MaintenancePlan" >
update tb_equipment_maintenanceplan
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plantype != null" >
plantype = #{plantype,jdbcType=VARCHAR},
</if>
<if test="plannumber != null" >
plannumber = #{plannumber,jdbcType=VARCHAR},
</if>
<if test="plancontent != null" >
plancontent = #{plancontent,jdbcType=VARCHAR},
</if>
<if test="condition != null" >
condition = #{condition,jdbcType=VARCHAR},
</if>
<if test="plantime != null" >
plantime = #{plantime,jdbcType=VARCHAR},
</if>
<if test="realtime != null" >
realtime = #{realtime,jdbcType=VARCHAR},
</if>
<if test="behaviordescription != null" >
behaviordescription = #{behaviordescription,jdbcType=VARCHAR},
</if>
<if test="performer != null" >
performer = #{performer,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.MaintenancePlan" >
update tb_equipment_maintenanceplan
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
plantype = #{plantype,jdbcType=VARCHAR},
plannumber = #{plannumber,jdbcType=VARCHAR},
plancontent = #{plancontent,jdbcType=VARCHAR},
condition = #{condition,jdbcType=VARCHAR},
plantime = #{plantime,jdbcType=VARCHAR},
realtime = #{realtime,jdbcType=VARCHAR},
behaviordescription = #{behaviordescription,jdbcType=VARCHAR},
performer = #{performer,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_equipment_maintenanceplan
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_equipment_maintenanceplan
${where}
</delete>
<select id="getRootByNumberAndVersion" resultMap="BaseResultMap" parameterType="com.sipai.entity.material.MaterialInfo" >
select
<include refid="Base_Column_List" />
from tb_equipment_maintenanceplan
where plannumber = #{plannumber,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,124 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="equipment.MaintenanceRecordEquipmentMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.MaintenanceRecordEquipment" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="maintenancerecordid" property="maintenancerecordid" jdbcType="VARCHAR" />
<result column="EquipmentCardid" property="equipmentcardid" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, maintenancerecordid, EquipmentCardid
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_equipment_maintenancerecord_equipmentcard
where id = #{id,jdbcType=VARCHAR}
</select>
<resultMap id="BaseResultMap1" type="com.sipai.entity.equipment.EquipmentCard" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="VARCHAR" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="equipmentClassID" property="equipmentclassid" jdbcType="VARCHAR" />
<result column="equipmentModel" property="equipmentmodel" jdbcType="VARCHAR" />
<result column="areaID" property="areaid" jdbcType="VARCHAR" />
<result column="currentManageFlag" property="currentmanageflag" jdbcType="VARCHAR" />
<result column="equipmentName" property="equipmentname" jdbcType="CLOB" />
<result column="remark" property="remark" jdbcType="CLOB" />
</resultMap>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_equipment_maintenancerecord_equipmentcard
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.MaintenanceRecordEquipment" >
insert into tb_equipment_maintenancerecord_equipmentcard (id, insuser, insdt,
maintenancerecordid, EquipmentCardid)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{maintenancerecordid,jdbcType=VARCHAR}, #{equipmentcardid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.MaintenanceRecordEquipment" >
insert into tb_equipment_maintenancerecord_equipmentcard
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="maintenancerecordid != null" >
maintenancerecordid,
</if>
<if test="equipmentcardid != null" >
EquipmentCardid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="maintenancerecordid != null" >
#{maintenancerecordid,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
#{equipmentcardid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.MaintenanceRecordEquipment" >
update tb_equipment_maintenancerecord_equipmentcard
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="maintenancerecordid != null" >
maintenancerecordid = #{maintenancerecordid,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
EquipmentCardid = #{equipmentcardid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.MaintenanceRecordEquipment" >
update tb_equipment_maintenancerecord_equipmentcard
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
maintenancerecordid = #{maintenancerecordid,jdbcType=VARCHAR},
EquipmentCardid = #{equipmentcardid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectEquipmentCard" resultMap="BaseResultMap1" parameterType="java.lang.String">
select tb_EM_EquipmentCard.* from tb_equipment_maintenancerecord_equipmentcard left join tb_EM_EquipmentCard
on tb_EM_EquipmentCard.id=tb_equipment_maintenancerecord_equipmentcard.EquipmentCardid
${where}
</select>
<select id="selectListByWhere" resultMap="BaseResultMap"
parameterType="java.lang.String">
select
<include refid="Base_Column_List" />
from tb_equipment_maintenancerecord_equipmentcard
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from
tb_equipment_maintenancerecord_equipmentcard
${where}
</delete>
</mapper>

View File

@ -0,0 +1,223 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="equipment.MaintenanceRecordMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.MaintenanceRecord" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="plantype" property="plantype" jdbcType="VARCHAR" />
<result column="plannumber" property="plannumber" jdbcType="VARCHAR" />
<result column="plancontent" property="plancontent" jdbcType="VARCHAR" />
<result column="condition" property="condition" jdbcType="VARCHAR" />
<result column="plantime" property="plantime" jdbcType="VARCHAR" />
<result column="realtime" property="realtime" jdbcType="VARCHAR" />
<result column="behaviordescription" property="behaviordescription" jdbcType="VARCHAR" />
<result column="performer" property="performer" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="c_judge" property="c_judge" jdbcType="VARCHAR" />
<result column="c_judge1" property="c_judge1" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, plantype, plannumber, plancontent, condition, plantime, realtime,
behaviordescription, performer, remark,c_judge,c_judge1
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_equipment_maintenancerecord
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="getListByPlanNumber" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_equipment_maintenancerecord
where plannumber = #{plannumber,jdbcType=VARCHAR}
</select>
<select id="getListById" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_equipment_maintenancerecord
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_equipment_maintenancerecord
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.equipment.MaintenanceRecord" >
insert into tb_equipment_maintenancerecord (id, insuser, insdt,
plantype, plannumber, plancontent,
condition, plantime, realtime,
behaviordescription, performer, remark,c_judge,c_judge1
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{plantype,jdbcType=VARCHAR}, #{plannumber,jdbcType=VARCHAR}, #{plancontent,jdbcType=VARCHAR},
#{condition,jdbcType=VARCHAR}, #{plantime,jdbcType=VARCHAR}, #{realtime,jdbcType=VARCHAR},
#{behaviordescription,jdbcType=VARCHAR}, #{performer,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR},#{c_judge,jdbcType=VARCHAR},#{c_judge1,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.equipment.MaintenanceRecord" >
insert into tb_equipment_maintenancerecord
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="plantype != null" >
plantype,
</if>
<if test="plannumber != null" >
plannumber,
</if>
<if test="plancontent != null" >
plancontent,
</if>
<if test="condition != null" >
condition,
</if>
<if test="plantime != null" >
plantime,
</if>
<if test="realtime != null" >
realtime,
</if>
<if test="behaviordescription != null" >
behaviordescription,
</if>
<if test="performer != null" >
performer,
</if>
<if test="remark != null" >
remark,
</if>
<if test="c_judge != null" >
c_judge,
</if>
<if test="c_judge1 != null" >
c_judge1,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plantype != null" >
#{plantype,jdbcType=VARCHAR},
</if>
<if test="plannumber != null" >
#{plannumber,jdbcType=VARCHAR},
</if>
<if test="plancontent != null" >
#{plancontent,jdbcType=VARCHAR},
</if>
<if test="condition != null" >
#{condition,jdbcType=VARCHAR},
</if>
<if test="plantime != null" >
#{plantime,jdbcType=VARCHAR},
</if>
<if test="realtime != null" >
#{realtime,jdbcType=VARCHAR},
</if>
<if test="behaviordescription != null" >
#{behaviordescription,jdbcType=VARCHAR},
</if>
<if test="performer != null" >
#{performer,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="c_judge != null" >
#{c_judge,jdbcType=VARCHAR},
</if>
<if test="c_judge1 != null" >
#{c_judge1,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.equipment.MaintenanceRecord" >
update tb_equipment_maintenancerecord
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plantype != null" >
plantype = #{plantype,jdbcType=VARCHAR},
</if>
<if test="plannumber != null" >
plannumber = #{plannumber,jdbcType=VARCHAR},
</if>
<if test="plancontent != null" >
plancontent = #{plancontent,jdbcType=VARCHAR},
</if>
<if test="condition != null" >
condition = #{condition,jdbcType=VARCHAR},
</if>
<if test="plantime != null" >
plantime = #{plantime,jdbcType=VARCHAR},
</if>
<if test="realtime != null" >
realtime = #{realtime,jdbcType=VARCHAR},
</if>
<if test="behaviordescription != null" >
behaviordescription = #{behaviordescription,jdbcType=VARCHAR},
</if>
<if test="performer != null" >
performer = #{performer,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="c_judge != null" >
c_judge = #{c_judge,jdbcType=VARCHAR},
</if>
<if test="c_judge1 != null" >
c_judge1 = #{c_judge1,jdbcType=VARCHAR},
</if>
</set>
where id= #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.equipment.MaintenanceRecord" >
update tb_equipment_maintenancerecord
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
plantype = #{plantype,jdbcType=VARCHAR},
plannumber = #{plannumber,jdbcType=VARCHAR},
plancontent = #{plancontent,jdbcType=VARCHAR},
condition = #{condition,jdbcType=VARCHAR},
plantime = #{plantime,jdbcType=VARCHAR},
realtime = #{realtime,jdbcType=VARCHAR},
behaviordescription = #{behaviordescription,jdbcType=VARCHAR},
performer = #{performer,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
c_judge = #{c_judge,jdbcType=VARCHAR},
c_judge1 = #{c_judge1,jdbcType=VARCHAR}
where id= #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap"
parameterType="java.lang.String">
select
<include refid="Base_Column_List" />
from tb_equipment_maintenancerecord
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from
tb_equipment_maintenancerecord
${where}
</delete>
</mapper>

View File

@ -0,0 +1,25 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="erp.ERPEquipmentClassMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.equipment.EquipmentClass" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="bizid" property="bizid" jdbcType="VARCHAR" />
<result column="code" property="code" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="flag" property="flag" jdbcType="VARCHAR" />
<result column=" interfacetype" property=" interfacetype" jdbcType="VARCHAR" />
</resultMap>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
code as code,
name as name
from pimMESMachineItem
${where}
</select>
</mapper>

View File

@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="erp.ERPMaterialBOMMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialERPBOM" >
<id column="FParentLevel" property="FParentLevel" jdbcType="VARCHAR" />
<result column="FParentID" property="FParentID" jdbcType="VARCHAR" />
<result column="FParentNumber" property="FParentNumber" jdbcType="VARCHAR" />
<result column="FParentName" property="FParentName" jdbcType="VARCHAR" />
<result column="FParentYield" property="FParentYield" jdbcType="VARCHAR" />
<result column="FParentModel" property="FParentModel" jdbcType="VARCHAR" />
<result column="FParentUnit" property="FParentUnit" jdbcType="VARCHAR" />
<result column="FChildLevel" property="FChildLevel" jdbcType="VARCHAR" />
<result column="FChildID" property="FChildID" jdbcType="VARCHAR" />
<result column="FChildNumber" property="FChildNumber" jdbcType="VARCHAR" />
<result column="FChildName" property="FChildName" jdbcType="VARCHAR" />
<result column="FChildModel" property="FChildModel" jdbcType="VARCHAR" />
<result column="FChildErpCls" property="FChildErpCls" jdbcType="VARCHAR" />
<result column="FChildUnit" property="FChildUnit" jdbcType="VARCHAR" />
<result column="FChildFixLeadTime" property="FChildFixLeadTime" jdbcType="VARCHAR" />
<result column="useunit" property="useunit" jdbcType="VARCHAR" />
<result column="needsum" property="needsum" jdbcType="VARCHAR" />
<result column="FChildSecInv" property="FChildSecInv" jdbcType="VARCHAR" />
<result column="rk_td" property="rk_td" jdbcType="VARCHAR" />
<result column="rkbom_statu" property="rkbom_statu" jdbcType="VARCHAR" />
<result column="FBomNumber" property="FBomNumber" jdbcType="VARCHAR" />
</resultMap>
<update id="updaterkbom" parameterType="com.sipai.entity.material.MaterialERPBOM" >
update icbom
set rkbom_statu = 1
where FBomNumber = #{FBomNumber,jdbcType=VARCHAR}
</update>
<select id="selectListERPBOM" parameterType="java.lang.String" resultMap="BaseResultMap">
EXEC rkzzq_boms #{materialcode,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,134 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="erp.ERPProdTaskMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.Prodtask" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="taskcode" property="taskcode" jdbcType="VARCHAR" />
<result column="billstatus" property="billstatus" jdbcType="VARCHAR" />
<result column="workshop" property="workshop" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="materialname" property="materialname" jdbcType="VARCHAR" />
<result column="model" property="model" jdbcType="VARCHAR" />
<result column="batch" property="batch" jdbcType="VARCHAR" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="planamount" property="planamount" jdbcType="DOUBLE" />
<result column="pstdate" property="pstdate" jdbcType="TIMESTAMP" />
<result column="pendate" property="pendate" jdbcType="TIMESTAMP" />
<result column="type" property="type" jdbcType="VARCHAR" />
<result column="bomno" property="bomno" jdbcType="VARCHAR" />
<result column="costobject" property="costobject" jdbcType="VARCHAR" />
<result column="source" property="source" jdbcType="VARCHAR" />
<result column="planno" property="planno" jdbcType="VARCHAR" />
<result column="salesno" property="salesno" jdbcType="VARCHAR" />
<result column="procompany" property="procompany" jdbcType="VARCHAR" />
<result column="commonunit" property="commonunit" jdbcType="VARCHAR" />
<result column="qualitypart" property="qualitypart" jdbcType="VARCHAR" />
<result column="astdate" property="astdate" jdbcType="TIMESTAMP" />
<result column="aendate" property="aendate" jdbcType="TIMESTAMP" />
<result column="midentification" property="midentification" jdbcType="VARCHAR" />
<result column="runstatus" property="runstatus" jdbcType="VARCHAR" />
<result column="plantype" property="plantype" jdbcType="VARCHAR" />
<result column="bomtype" property="bomtype" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="relation" property="relation" jdbcType="VARCHAR" />
</resultMap>
<!-- 查询ERP所有任务单 -->
<select id="selectList" parameterType="java.lang.String" resultMap="BaseResultMap">
SELECT
FAuxQty planamount ,
a.FBillNo taskcode ,
FOrderInterID salesno ,
FBomInterID bomno,
fmodel model,
f.fname costobject,
g.fname procompany,
FMRP source,
FGMPBatchNo batch,
d.fname unit,
FBOMCategory bomtype,
FPlanOrderInterID planno,
FPlanCategory plantype,
FWorkTypeID type,
FPlanCommitDate pstdate ,
FPlanFinishDate pendate ,
b.FNumber materialcode ,
b.FName materialname,
a.FStatus runstatus ,
e.fname workshopname,
FWorkShop workshop
FROM ICMO a INNER JOIN t_icitem b ON b.FItemID = a.FItemID
INNER JOIN t_Measureunit d ON d.fitemid=a.funitid
left JOIN cbCostObj f ON f.FItemID=a.FCostObjID
left JOIN t_department e ON e.fitemid=a.Fworkshop
left JOIN t_Supplier g ON g.FItemID=a.FSupplyID
WHERE FCancellation=0 --未作废
AND FMrpClosed=0
AND FClosed=0 --未关闭
AND FPlanConfirmed=1 --已计划确认
AND ( a.FStatus=1 OR a.FStatus =2 )--已确认/已下达
AND ( FTranType=85
OR FTranType=571
) --生产任务单/委外任务单
AND FPlanCategory=1 --增加计划类别为STD lgq
</select>
<!-- 查询带条件ERP所有任务单 -->
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
SELECT
FAuxQty planamount ,
a.FBillNo taskcode ,
FOrderInterID salesno ,
FBomInterID bomno,
fmodel model,
f.fname costobject,
g.fname procompany,
FMRP source,
FGMPBatchNo batch,
d.fname unit,
FBOMCategory bomtype,
FPlanOrderInterID planno,
FPlanCategory plantype,
FWorkTypeID type,
FPlanCommitDate pstdate ,
FPlanFinishDate pendate ,
b.FNumber materialcode ,
b.FName materialname,
a.FStatus runstatus ,
e.fname workshopname,
FWorkShop workshop
FROM ICMO a INNER JOIN t_icitem b ON b.FItemID = a.FItemID
INNER JOIN t_Measureunit d ON d.fitemid=a.funitid
left JOIN cbCostObj f ON f.FItemID=a.FCostObjID
left JOIN t_department e ON e.fitemid=a.Fworkshop
left JOIN t_Supplier g ON g.FItemID=a.FSupplyID
WHERE FCancellation=0 --未作废
AND FMrpClosed=0
AND FClosed=0 --未关闭
AND FPlanConfirmed=1 --已计划确认
AND ( a.FStatus=1 OR a.FStatus =2 )--已确认/已下达
AND ( FTranType=85
OR FTranType=571
) --生产任务单/委外任务单
AND FPlanCategory=1 --增加计划类别为STD lgq
${where}
</select>
<!-- 标记任务已同步 -->
<update id="updateTasks" parameterMap="updateTasksMap" >
update ICMO
set rkbom_statu = 1
where FBillNo = #{taskcode,jdbcType=VARCHAR}
</update>
<update id="updateTasksByWhere" parameterType="hashmap" >
update ICMO
set rkbom_statu = 1
${where}
</update>
<parameterMap type="java.util.Map" id="updateTasksMap">
<parameter property="taskcode" mode="IN" jdbcType="VARCHAR"/>
</parameterMap>
</mapper>

View File

@ -0,0 +1,119 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="erp.ERPTaskModelMapper">
<resultMap id="TasksMap" type="com.sipai.entity.process.ProcessTechnics" >
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="modelid" jdbcType="VARCHAR" property="modelid" />
<result column="processid" jdbcType="VARCHAR" property="processid" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="MainProcedure" jdbcType="VARCHAR" property="mainprocedure" />
<result column="MainProcedureCode" jdbcType="VARCHAR" property="mainprocedurecode" />
<result column="SubProcedure" jdbcType="VARCHAR" property="subprocedure" />
<result column="SubProcedureCode" jdbcType="VARCHAR" property="subprocedurecode" />
<result column="ContentNO" jdbcType="VARCHAR" property="contentno" />
<result column="Subject" jdbcType="VARCHAR" property="subject" />
<result column="Specifications" jdbcType="VARCHAR" property="specifications" />
<result column="Mode" jdbcType="VARCHAR" property="mode" />
<result column="Tool" jdbcType="VARCHAR" property="tool" />
<result column="Frequency" jdbcType="VARCHAR" property="frequency" />
<result column="People" jdbcType="VARCHAR" property="people" />
<result column="Rejects" jdbcType="VARCHAR" property="rejects" />
<result column="FileName" jdbcType="VARCHAR" property="filename" />
<result column="FileId" jdbcType="VARCHAR" property="fileid" />
<result column="FormName" jdbcType="VARCHAR" property="formname" />
<result column="FormId" jdbcType="VARCHAR" property="formid" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
</resultMap>
<!-- 根据产品code查询流程任务-->
<select id="selectListByMastrCode" parameterType="java.lang.String" resultMap="TasksMap">
select
gxfl as mainprocedurecode,
gxmc+Case When ISNULL(gygc,'') ='' Then '' Else '-'+gygc End as mainprocedure,
case when cast (jczs as float) >0 then cast (jczs as float)/100
when cast (jczs as float) =0 then 1
else cast (jczs as float) end yield,
itemno as ContentNO,
gyjy as Mode,
bz as Specifications
from pimXTCAPPPBOMItem
where bitemid in
(select MAX(bitemid) from pimXTCAPPPBOMItem
where lbjth=#{code,jdbcType=VARCHAR} group by ItemNo)
order by ItemNo
</select>
<resultMap id="MasterMap" type="com.sipai.entity.material.MaterialInfo" >
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="materialname" property="materialname" jdbcType="VARCHAR" />
<result column="materialmodel" property="materialmodel" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
</resultMap>
<!-- 获取产品列表-->
<select id="selectProductListByWhere" parameterType="java.lang.String" resultMap="MasterMap">
select
PartCode as materialcode,
PartName as materialname,
PartStand as materialmodel,
Create_On as insdt
from pimPartMaster
${where}
and partcode = productcode
order by Create_On desc
<!-- SELECT c.FNumber as materialcode,
c.FName as materialname,
c.fmodel as materialmodel
from t_ICItem c where c.FItemID in (
SELECT max(c.FItemID) FROM SEOrder a INNER JOIN dbo.SEOrderEntry b ON b.FInterID = a.FInterID
INNER JOIN dbo.t_ICItem c ON c.FItemID = b.FItemID
where b.FMrpClosed=0 AND b.FQty-ISNULL(b.FStockQty,0)>0
group by c.FNumber
) ${where} -->
<!-- SELECT distinct top 100 percent c.*,a.FFetchDate FROM SEOrder a INNER JOIN dbo.SEOrderEntry b ON b.FInterID = a.FInterID
INNER JOIN dbo.t_ICItem c ON c.FItemID = b.FItemID
WHERE b.FMrpClosed=0 AND b.FQty-ISNULL(b.FStockQty,0)>0
${where}
order by a.FFetchDate asc -->
</select>
<resultMap id="ProcessConfigMap" type="com.sipai.entity.process.ProcessConfig" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="materialCode" property="materialcode" jdbcType="VARCHAR" />
<result column="processId" property="processid" jdbcType="VARCHAR" />
<result column="procedureNo" property="procedureno" jdbcType="VARCHAR" />
<result column="yield" property="yield" jdbcType="DOUBLE" />
</resultMap>
<!-- 获取产品工序物料对应关系-->
<select id="selectProcessConfigByCode" parameterType="java.lang.String" resultMap="ProcessConfigMap">
select b.materialcode,b.procedureno ,
case when b.yield >0 then b.yield/100
when b.yield =0 then 1
else b.yield end yield
from (
select wxcc as materialcode, gxfl as procedureno,
CAST ( REPLACE(jczs ,'%','') as float ) as yield
from pimXTCAPPPBOMItem where lbjth=#{code,jdbcType=VARCHAR} ) b
</select>
<resultMap id="ProcessConfig_EMMap" type="com.sipai.entity.process.ProcessConfig_EM" >
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="equipmentClassCode" jdbcType="VARCHAR" property="equipmentclasscode" />
<result column="processId" jdbcType="VARCHAR" property="processid" />
<result column="procedureNo" jdbcType="VARCHAR" property="procedureno" />
<result column="capacity" jdbcType="VARCHAR" property="capacity" />
</resultMap>
<!-- 获取产品工序物料对应关系-->
<select id="selectProcessConfig_EMByCode" parameterType="java.lang.String" resultMap="ProcessConfig_EMMap">
select
gxfl as procedureno,
tdclmc as equipmentClassCode,
Other5 as capacity
from pimXTCAPPPBOMItem
where lbjth=#{code,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,24 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="erp.ERPTaskProcedureMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.process.TaskProcedure">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="procedurecode" jdbcType="VARCHAR" property="procedurecode" />
<result column="procedurename" jdbcType="VARCHAR" property="procedurename" />
<result column="workstation" jdbcType="VARCHAR" property="workstation" />
<result column="keywords" jdbcType="VARCHAR" property="keywords" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="semiflag" jdbcType="VARCHAR" property="semiflag" />
</resultMap>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
gxfl as procedurecode,
gxmc as procedurename
from pimPRMProcessItem
${where}
</select>
</mapper>

View File

@ -0,0 +1,70 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="erp.ERPinventoryMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialBOM" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="materialname" property="materialname" jdbcType="VARCHAR" />
<result column="materialmodel" property="materialmodel" jdbcType="VARCHAR" />
<result column="materialproperties" property="materialproperties" jdbcType="VARCHAR" />
<result column="secondaryattribute" property="secondaryattribute" jdbcType="VARCHAR" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="num" property="num" jdbcType="VARCHAR" />
<result column="yield" property="yield" jdbcType="VARCHAR" />
<result column="state" property="state" jdbcType="VARCHAR" />
<result column="audit" property="audit" jdbcType="VARCHAR" />
<result column="version" property="version" jdbcType="VARCHAR" />
<result column="drawnum" property="drawnum" jdbcType="VARCHAR" />
<result column="processlinecode" property="processlinecode" jdbcType="VARCHAR" />
<result column="processlinename" property="processlinename" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="lastinsuser" property="lastinsuser" jdbcType="VARCHAR" />
<result column="lastinsdt" property="lastinsdt" jdbcType="TIMESTAMP" />
<result column="usepeople" property="usepeople" jdbcType="VARCHAR" />
<result column="userdt" property="userdt" jdbcType="TIMESTAMP" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="jumplayer" property="jumplayer" jdbcType="VARCHAR" />
<result column="levels" property="levels" jdbcType="VARCHAR" />
<result column="unituse" property="unituse" jdbcType="VARCHAR" />
<result column="dosage" property="dosage" jdbcType="VARCHAR" />
<result column="usualuseunit" property="usualuseunit" jdbcType="VARCHAR" />
<result column="plannedpercentage" property="plannedpercentage" jdbcType="VARCHAR" />
<result column="wearrate" property="wearrate" jdbcType="VARCHAR" />
<result column="itemtype" property="itemtype" jdbcType="VARCHAR" />
<result column="operationnumber" property="operationnumber" jdbcType="VARCHAR" />
<result column="process" property="process" jdbcType="VARCHAR" />
<result column="station" property="station" jdbcType="VARCHAR" />
<result column="localnum" property="localnum" jdbcType="VARCHAR" />
<result column="billetsize" property="billetsize" jdbcType="VARCHAR" />
<result column="billetnum" property="billetnum" jdbcType="VARCHAR" />
<result column="warehouse" property="warehouse" jdbcType="VARCHAR" />
<result column="keysymbol" property="keysymbol" jdbcType="VARCHAR" />
<result column="usestate" property="usestate" jdbcType="VARCHAR" />
<result column="ifdown" property="ifdown" jdbcType="VARCHAR" />
<result column="remark1" property="remark1" jdbcType="VARCHAR" />
<result column="remark2" property="remark2" jdbcType="VARCHAR" />
<result column="inventory" property="inventory" jdbcType="VARCHAR" />
<result column="ifpour" property="ifpour" jdbcType="VARCHAR" />
<result column="havereplace" property="havereplace" jdbcType="VARCHAR" />
<result column="faildt" property="faildt" jdbcType="TIMESTAMP" />
<result column="effectdt" property="effectdt" jdbcType="TIMESTAMP" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="usuallyunit" property="usuallyunit" jdbcType="VARCHAR" />
</resultMap>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
物料代码 materialcode,
物料名称 materialname,
规格 materialmodel,
仓库代码 inventory,
仓库名称 warehouse,
库存 num,
单位 unit
from rkzzq_stock
${where}
</select>
</mapper>

View File

@ -0,0 +1,187 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.AuxiliaryMaterialPickingMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.AuxiliaryMaterialPicking" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="bomprojects" property="bomprojects" jdbcType="VARCHAR" />
<result column="num" property="num" jdbcType="VARCHAR" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="pickingpeople" property="pickingpeople" jdbcType="VARCHAR" />
<result column="pickingdate" property="pickingdate" jdbcType="TIMESTAMP" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="keyword" property="keyword" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, pid, bomprojects, num, unit, pickingpeople, pickingdate, remark,
keyword, materialcode
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_AuxiliaryMaterialPicking
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_AuxiliaryMaterialPicking
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.AuxiliaryMaterialPicking" >
insert into tb_material_AuxiliaryMaterialPicking (id, insuser, insdt,
pid, bomprojects, num,
unit, pickingpeople, pickingdate,
remark, keyword, materialcode
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{pid,jdbcType=VARCHAR}, #{bomprojects,jdbcType=VARCHAR}, #{num,jdbcType=VARCHAR},
#{unit,jdbcType=VARCHAR}, #{pickingpeople,jdbcType=VARCHAR}, #{pickingdate,jdbcType=TIMESTAMP},
#{remark,jdbcType=VARCHAR}, #{keyword,jdbcType=VARCHAR}, #{materialcode,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.AuxiliaryMaterialPicking" >
insert into tb_material_AuxiliaryMaterialPicking
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="pid != null" >
pid,
</if>
<if test="bomprojects != null" >
bomprojects,
</if>
<if test="num != null" >
num,
</if>
<if test="unit != null" >
unit,
</if>
<if test="pickingpeople != null" >
pickingpeople,
</if>
<if test="pickingdate != null" >
pickingdate,
</if>
<if test="remark != null" >
remark,
</if>
<if test="keyword != null" >
keyword,
</if>
<if test="materialcode != null" >
materialcode,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="bomprojects != null" >
#{bomprojects,jdbcType=VARCHAR},
</if>
<if test="num != null" >
#{num,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
#{unit,jdbcType=VARCHAR},
</if>
<if test="pickingpeople != null" >
#{pickingpeople,jdbcType=VARCHAR},
</if>
<if test="pickingdate != null" >
#{pickingdate,jdbcType=TIMESTAMP},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="keyword != null" >
#{keyword,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
#{materialcode,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.AuxiliaryMaterialPicking" >
update tb_material_AuxiliaryMaterialPicking
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="bomprojects != null" >
bomprojects = #{bomprojects,jdbcType=VARCHAR},
</if>
<if test="num != null" >
num = #{num,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
unit = #{unit,jdbcType=VARCHAR},
</if>
<if test="pickingpeople != null" >
pickingpeople = #{pickingpeople,jdbcType=VARCHAR},
</if>
<if test="pickingdate != null" >
pickingdate = #{pickingdate,jdbcType=TIMESTAMP},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="keyword != null" >
keyword = #{keyword,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
materialcode = #{materialcode,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.AuxiliaryMaterialPicking" >
update tb_material_AuxiliaryMaterialPicking
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
pid = #{pid,jdbcType=VARCHAR},
bomprojects = #{bomprojects,jdbcType=VARCHAR},
num = #{num,jdbcType=VARCHAR},
unit = #{unit,jdbcType=VARCHAR},
pickingpeople = #{pickingpeople,jdbcType=VARCHAR},
pickingdate = #{pickingdate,jdbcType=TIMESTAMP},
remark = #{remark,jdbcType=VARCHAR},
keyword = #{keyword,jdbcType=VARCHAR},
materialcode = #{materialcode,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_AuxiliaryMaterialPicking
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_material_AuxiliaryMaterialPicking
${where}
</delete>
</mapper>

View File

@ -0,0 +1,246 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="material.BoardbatchMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.material.Boardbatch">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="no" jdbcType="VARCHAR" property="no" />
<result column="status" jdbcType="VARCHAR" property="status" />
<result column="starttime" jdbcType="TIMESTAMP" property="starttime" />
<result column="endtime" jdbcType="TIMESTAMP" property="endtime" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="alterdt" jdbcType="TIMESTAMP" property="alterdt" />
<result column="alteruser" jdbcType="VARCHAR" property="alteruser" />
<result column="alterstatus" jdbcType="VARCHAR" property="alterstatus" />
<result column="processrealid" jdbcType="VARCHAR" property="processrealid" />
</resultMap>
<sql id="Base_Column_List">
id, type, name, no, status, starttime, endtime, insuser, insdt, alterdt, alteruser,
alterstatus, processrealid
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_boardbatch
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_material_boardbatch
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.Boardbatch">
insert into tb_material_boardbatch (id, type, name,
no, status, starttime,
endtime, insuser, insdt,
alterdt, alteruser, alterstatus,
processrealid)
values (#{id,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{no,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR}, #{starttime,jdbcType=TIMESTAMP},
#{endtime,jdbcType=TIMESTAMP}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{alterdt,jdbcType=TIMESTAMP}, #{alteruser,jdbcType=VARCHAR}, #{alterstatus,jdbcType=VARCHAR},
#{processrealid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.Boardbatch">
insert into tb_material_boardbatch
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="type != null">
type,
</if>
<if test="name != null">
name,
</if>
<if test="no != null">
no,
</if>
<if test="status != null">
status,
</if>
<if test="starttime != null">
starttime,
</if>
<if test="endtime != null">
endtime,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="alterdt != null">
alterdt,
</if>
<if test="alteruser != null">
alteruser,
</if>
<if test="alterstatus != null">
alterstatus,
</if>
<if test="processrealid != null">
processrealid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="type != null">
#{type,jdbcType=VARCHAR},
</if>
<if test="name != null">
#{name,jdbcType=VARCHAR},
</if>
<if test="no != null">
#{no,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=VARCHAR},
</if>
<if test="starttime != null">
#{starttime,jdbcType=TIMESTAMP},
</if>
<if test="endtime != null">
#{endtime,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="alterdt != null">
#{alterdt,jdbcType=TIMESTAMP},
</if>
<if test="alteruser != null">
#{alteruser,jdbcType=VARCHAR},
</if>
<if test="alterstatus != null">
#{alterstatus,jdbcType=VARCHAR},
</if>
<if test="processrealid != null">
#{processrealid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.Boardbatch">
update tb_material_boardbatch
<set>
<if test="type != null">
type = #{type,jdbcType=VARCHAR},
</if>
<if test="name != null">
name = #{name,jdbcType=VARCHAR},
</if>
<if test="no != null">
no = #{no,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=VARCHAR},
</if>
<if test="starttime != null">
starttime = #{starttime,jdbcType=TIMESTAMP},
</if>
<if test="endtime != null">
endtime = #{endtime,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="alterdt != null">
alterdt = #{alterdt,jdbcType=TIMESTAMP},
</if>
<if test="alteruser != null">
alteruser = #{alteruser,jdbcType=VARCHAR},
</if>
<if test="alterstatus != null">
alterstatus = #{alterstatus,jdbcType=VARCHAR},
</if>
<if test="processrealid != null">
processrealid = #{processrealid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.Boardbatch">
update tb_material_boardbatch
set type = #{type,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
no = #{no,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
starttime = #{starttime,jdbcType=TIMESTAMP},
endtime = #{endtime,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
alterdt = #{alterdt,jdbcType=TIMESTAMP},
alteruser = #{alteruser,jdbcType=VARCHAR},
alterstatus = #{alterstatus,jdbcType=VARCHAR},
processrealid = #{processrealid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_boardbatch
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_material_boardbatch
${where}
</delete>
<select id="getListByNo" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_boardbatch
where no = #{no,jdbcType=VARCHAR}
</select>
<select id="getListByName" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_boardbatch
where name = #{name,jdbcType=VARCHAR}
</select>
<resultMap id="BaseResultMap1" type="com.sipai.entity.material.Boardbatch">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="no" jdbcType="VARCHAR" property="no" />
<result column="status" jdbcType="VARCHAR" property="status" />
<result column="starttime" jdbcType="TIMESTAMP" property="starttime" />
<result column="endtime" jdbcType="TIMESTAMP" property="endtime" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="alterdt" jdbcType="TIMESTAMP" property="alterdt" />
<result column="alteruser" jdbcType="VARCHAR" property="alteruser" />
<result column="equipmentName" jdbcType="VARCHAR" property="equipmentName" />
<result column="equipmentcardid" jdbcType="VARCHAR" property="equipmentcardid" />
<result column="processrealid" jdbcType="VARCHAR" property="processrealid" />
</resultMap>
<sql id="Base_Column_List1">
id, type, name, no, status, starttime, endtime, insuser, insdt, alterdt, alteruser,
alterstatus, processrealid,equipmentcardid,equipmentName
</sql>
<select id="getListByEquipmentName" parameterType="com.sipai.entity.material.Boardbatch" resultMap="BaseResultMap1">
select p.id,p.type,p.name,p.status,p.starttime,p.endtime,p.alteruser,p.alterdt,p.No,p.equipmentcardid,p.processrealid,t.equipmentName
from (select M.equipmentcardid AS equipmentcardid,M.status AS machinestatus,B.type AS type,B.name,B.status,B.starttime,B.No,B.id,
B.endtime,B.alteruser,B.alterdt,B.processrealid
from tb_material_boardbatch B ,tb_material_boardbatchmachine M
where M.No = B.id) p
left outer join TB_EM_EquipmentCard t on p.equipmentcardid = t.id
${where}
</select>
<select id="getListByBoardno" resultMap="BaseResultMap1" parameterType="java.lang.String" >
select
<include refid="Base_Column_List1" />
from tb_material_boardbatch
where no = #{no,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,134 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.BoardbatchmachineMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.Boardbatchmachine" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="no" property="no" jdbcType="VARCHAR" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, no, equipmentCardID, status
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_boardbatchmachine
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_boardbatchmachine
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.Boardbatchmachine" >
insert into tb_material_boardbatchmachine (id, insuser, insdt,
no, equipmentCardID, status
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{no,jdbcType=VARCHAR}, #{equipmentcardid,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.Boardbatchmachine" >
insert into tb_material_boardbatchmachine
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="no != null" >
no,
</if>
<if test="equipmentcardid != null" >
equipmentCardID,
</if>
<if test="status != null" >
status,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="no != null" >
#{no,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
#{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.Boardbatchmachine" >
update tb_material_boardbatchmachine
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="no != null" >
no = #{no,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.Boardbatchmachine" >
update tb_material_boardbatchmachine
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
no = #{no,jdbcType=VARCHAR},
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_boardbatchmachine
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_boardbatchmachine
${where}
</delete>
<resultMap id="BaseResultMap1" type="com.sipai.entity.equipment.EquipmentCard" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="VARCHAR" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="equipmentClassID" property="equipmentclassid" jdbcType="VARCHAR" />
<result column="equipmentModel" property="equipmentmodel" jdbcType="VARCHAR" />
<result column="areaID" property="areaid" jdbcType="VARCHAR" />
<result column="equipmentName" property="equipmentname" jdbcType="CLOB" />
</resultMap>
<select id="getEquipmentCard" resultMap="BaseResultMap1" parameterType="java.lang.String">
select E.*,
M.status AS ibmstatus
from tb_material_boardbatchmachine M
left join TB_EM_EquipmentCard E on E.id=M.equipmentCardID
${where}
</select>
</mapper>

View File

@ -0,0 +1,173 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.ClientsMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.Clients" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="tel" property="tel" jdbcType="VARCHAR" />
<result column="fax" property="fax" jdbcType="VARCHAR" />
<result column="address" property="address" jdbcType="VARCHAR" />
<result column="email" property="email" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="contactname" property="contactname" jdbcType="VARCHAR" />
<result column="contacttel" property="contacttel" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, name, tel, fax, address, email, remark, contactname, contacttel, insuser, insdt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_clients
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_clients
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.Clients" >
insert into tb_clients (id, name, tel,
fax, address, email,
remark, contactname, contacttel,
insuser, insdt)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{tel,jdbcType=VARCHAR},
#{fax,jdbcType=VARCHAR}, #{address,jdbcType=VARCHAR}, #{email,jdbcType=VARCHAR},
#{remark,jdbcType=VARCHAR}, #{contactname,jdbcType=VARCHAR}, #{contacttel,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.Clients" >
insert into tb_clients
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="name != null" >
name,
</if>
<if test="tel != null" >
tel,
</if>
<if test="fax != null" >
fax,
</if>
<if test="address != null" >
address,
</if>
<if test="email != null" >
email,
</if>
<if test="remark != null" >
remark,
</if>
<if test="contactname != null" >
contactname,
</if>
<if test="contacttel != null" >
contacttel,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="tel != null" >
#{tel,jdbcType=VARCHAR},
</if>
<if test="fax != null" >
#{fax,jdbcType=VARCHAR},
</if>
<if test="address != null" >
#{address,jdbcType=VARCHAR},
</if>
<if test="email != null" >
#{email,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="contactname != null" >
#{contactname,jdbcType=VARCHAR},
</if>
<if test="contacttel != null" >
#{contacttel,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.Clients" >
update tb_clients
<set >
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="tel != null" >
tel = #{tel,jdbcType=VARCHAR},
</if>
<if test="fax != null" >
fax = #{fax,jdbcType=VARCHAR},
</if>
<if test="address != null" >
address = #{address,jdbcType=VARCHAR},
</if>
<if test="email != null" >
email = #{email,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="contactname != null" >
contactname = #{contactname,jdbcType=VARCHAR},
</if>
<if test="contacttel != null" >
contacttel = #{contacttel,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.Clients" >
update tb_clients
set name = #{name,jdbcType=VARCHAR},
tel = #{tel,jdbcType=VARCHAR},
fax = #{fax,jdbcType=VARCHAR},
address = #{address,jdbcType=VARCHAR},
email = #{email,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
contactname = #{contactname,jdbcType=VARCHAR},
contacttel = #{contacttel,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_clients
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_clients
${where}
</delete>
</mapper>

View File

@ -0,0 +1,204 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.CutterCNCPointMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.CutterCNCPoint" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="equid" property="equid" jdbcType="VARCHAR" />
<result column="equstatus" property="equstatus" jdbcType="VARCHAR" />
<result column="equrunmode" property="equrunmode" jdbcType="VARCHAR" />
<result column="equgospeed" property="equgospeed" jdbcType="VARCHAR" />
<result column="equcaspeed" property="equcaspeed" jdbcType="VARCHAR" />
<result column="processcumno" property="processcumno" jdbcType="VARCHAR" />
<result column="mechandno" property="mechandno" jdbcType="VARCHAR" />
<result column="cutterlossno" property="cutterlossno" jdbcType="VARCHAR" />
<result column="cutterlossset" property="cutterlossset" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, equid, equstatus, equrunmode, equgospeed, equcaspeed, processcumno,
mechandno, cutterlossno, cutterlossset
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_cncpoint
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_cutter_cncpoint
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.CutterCNCPoint" >
insert into tb_cutter_cncpoint (id, insuser, insdt,
equid, equstatus, equrunmode,
equgospeed, equcaspeed, processcumno,
mechandno, cutterlossno, cutterlossset
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{equid,jdbcType=VARCHAR}, #{equstatus,jdbcType=VARCHAR}, #{equrunmode,jdbcType=VARCHAR},
#{equgospeed,jdbcType=VARCHAR}, #{equcaspeed,jdbcType=VARCHAR}, #{processcumno,jdbcType=VARCHAR},
#{mechandno,jdbcType=VARCHAR}, #{cutterlossno,jdbcType=VARCHAR}, #{cutterlossset,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.CutterCNCPoint" >
insert into tb_cutter_cncpoint
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="equid != null" >
equid,
</if>
<if test="equstatus != null" >
equstatus,
</if>
<if test="equrunmode != null" >
equrunmode,
</if>
<if test="equgospeed != null" >
equgospeed,
</if>
<if test="equcaspeed != null" >
equcaspeed,
</if>
<if test="processcumno != null" >
processcumno,
</if>
<if test="mechandno != null" >
mechandno,
</if>
<if test="cutterlossno != null" >
cutterlossno,
</if>
<if test="cutterlossset != null" >
cutterlossset,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="equid != null" >
#{equid,jdbcType=VARCHAR},
</if>
<if test="equstatus != null" >
#{equstatus,jdbcType=VARCHAR},
</if>
<if test="equrunmode != null" >
#{equrunmode,jdbcType=VARCHAR},
</if>
<if test="equgospeed != null" >
#{equgospeed,jdbcType=VARCHAR},
</if>
<if test="equcaspeed != null" >
#{equcaspeed,jdbcType=VARCHAR},
</if>
<if test="processcumno != null" >
#{processcumno,jdbcType=VARCHAR},
</if>
<if test="mechandno != null" >
#{mechandno,jdbcType=VARCHAR},
</if>
<if test="cutterlossno != null" >
#{cutterlossno,jdbcType=VARCHAR},
</if>
<if test="cutterlossset != null" >
#{cutterlossset,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.CutterCNCPoint" >
update tb_cutter_cncpoint
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="equid != null" >
equid = #{equid,jdbcType=VARCHAR},
</if>
<if test="equstatus != null" >
equstatus = #{equstatus,jdbcType=VARCHAR},
</if>
<if test="equrunmode != null" >
equrunmode = #{equrunmode,jdbcType=VARCHAR},
</if>
<if test="equgospeed != null" >
equgospeed = #{equgospeed,jdbcType=VARCHAR},
</if>
<if test="equcaspeed != null" >
equcaspeed = #{equcaspeed,jdbcType=VARCHAR},
</if>
<if test="processcumno != null" >
processcumno = #{processcumno,jdbcType=VARCHAR},
</if>
<if test="mechandno != null" >
mechandno = #{mechandno,jdbcType=VARCHAR},
</if>
<if test="cutterlossno != null" >
cutterlossno = #{cutterlossno,jdbcType=VARCHAR},
</if>
<if test="cutterlossset != null" >
cutterlossset = #{cutterlossset,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.CutterCNCPoint" >
update tb_cutter_cncpoint
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
equid = #{equid,jdbcType=VARCHAR},
equstatus = #{equstatus,jdbcType=VARCHAR},
equrunmode = #{equrunmode,jdbcType=VARCHAR},
equgospeed = #{equgospeed,jdbcType=VARCHAR},
equcaspeed = #{equcaspeed,jdbcType=VARCHAR},
processcumno = #{processcumno,jdbcType=VARCHAR},
mechandno = #{mechandno,jdbcType=VARCHAR},
cutterlossno = #{cutterlossno,jdbcType=VARCHAR},
cutterlossset = #{cutterlossset,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_cutter_cncpoint
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_cutter_cncpoint
${where}
</delete>
<select id="selectListByEquipment" parameterType="java.lang.String" resultMap="BaseResultMap">
select C.equstatus,C.equrunmode ,C.equgospeed,C.equcaspeed,C.processcumno,C.mechandno,C.cutterlossno,C.cutterlossset,
C.insdt,C.id,C.insuser,C.equid,
E.equipmentCardID,E.equipmentName
from tb_cutter_cncpoint C
left outer join TB_EM_EquipmentCard E on E.id = C.equid
${where}
</select>
<select id="selectByEquid" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_cncpoint
${where}
</select>
</mapper>

View File

@ -0,0 +1,186 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.CutterCNCStandardMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.CutterCNCStandard" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="equid" property="equid" jdbcType="VARCHAR" />
<result column="stequgospeedvalue" property="stequgospeedvalue" jdbcType="VARCHAR" />
<result column="stequcaspeedvalue" property="stequcaspeedvalue" jdbcType="VARCHAR" />
<result column="stprocesscumnovalue" property="stprocesscumnovalue" jdbcType="VARCHAR" />
<result column="stmechandnovalue" property="stmechandnovalue" jdbcType="VARCHAR" />
<result column="stcutterlossnovalue" property="stcutterlossnovalue" jdbcType="VARCHAR" />
<result column="stcutterlosssetvalue" property="stcutterlosssetvalue" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, materialcode, equid, stequgospeedvalue, stequcaspeedvalue, stprocesscumnovalue,
stmechandnovalue, stcutterlossnovalue, stcutterlosssetvalue
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_cncstandardvalue
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_cutter_cncstandardvalue
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.CutterCNCStandard" >
insert into tb_cutter_cncstandardvalue (id, insuser, insdt,
materialcode, equid, stequgospeedvalue,
stequcaspeedvalue, stprocesscumnovalue,
stmechandnovalue, stcutterlossnovalue,
stcutterlosssetvalue)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{materialcode,jdbcType=VARCHAR}, #{equid,jdbcType=VARCHAR}, #{stequgospeedvalue,jdbcType=VARCHAR},
#{stequcaspeedvalue,jdbcType=VARCHAR}, #{stprocesscumnovalue,jdbcType=VARCHAR},
#{stmechandnovalue,jdbcType=VARCHAR}, #{stcutterlossnovalue,jdbcType=VARCHAR},
#{stcutterlosssetvalue,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.CutterCNCStandard" >
insert into tb_cutter_cncstandardvalue
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="materialcode != null" >
materialcode,
</if>
<if test="equid != null" >
equid,
</if>
<if test="stequgospeedvalue != null" >
stequgospeedvalue,
</if>
<if test="stequcaspeedvalue != null" >
stequcaspeedvalue,
</if>
<if test="stprocesscumnovalue != null" >
stprocesscumnovalue,
</if>
<if test="stmechandnovalue != null" >
stmechandnovalue,
</if>
<if test="stcutterlossnovalue != null" >
stcutterlossnovalue,
</if>
<if test="stcutterlosssetvalue != null" >
stcutterlosssetvalue,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="materialcode != null" >
#{materialcode,jdbcType=VARCHAR},
</if>
<if test="equid != null" >
#{equid,jdbcType=VARCHAR},
</if>
<if test="stequgospeedvalue != null" >
#{stequgospeedvalue,jdbcType=VARCHAR},
</if>
<if test="stequcaspeedvalue != null" >
#{stequcaspeedvalue,jdbcType=VARCHAR},
</if>
<if test="stprocesscumnovalue != null" >
#{stprocesscumnovalue,jdbcType=VARCHAR},
</if>
<if test="stmechandnovalue != null" >
#{stmechandnovalue,jdbcType=VARCHAR},
</if>
<if test="stcutterlossnovalue != null" >
#{stcutterlossnovalue,jdbcType=VARCHAR},
</if>
<if test="stcutterlosssetvalue != null" >
#{stcutterlosssetvalue,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.CutterCNCStandard" >
update tb_cutter_cncstandardvalue
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="materialcode != null" >
materialcode = #{materialcode,jdbcType=VARCHAR},
</if>
<if test="equid != null" >
equid = #{equid,jdbcType=VARCHAR},
</if>
<if test="stequgospeedvalue != null" >
stequgospeedvalue = #{stequgospeedvalue,jdbcType=VARCHAR},
</if>
<if test="stequcaspeedvalue != null" >
stequcaspeedvalue = #{stequcaspeedvalue,jdbcType=VARCHAR},
</if>
<if test="stprocesscumnovalue != null" >
stprocesscumnovalue = #{stprocesscumnovalue,jdbcType=VARCHAR},
</if>
<if test="stmechandnovalue != null" >
stmechandnovalue = #{stmechandnovalue,jdbcType=VARCHAR},
</if>
<if test="stcutterlossnovalue != null" >
stcutterlossnovalue = #{stcutterlossnovalue,jdbcType=VARCHAR},
</if>
<if test="stcutterlosssetvalue != null" >
stcutterlosssetvalue = #{stcutterlosssetvalue,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.CutterCNCStandard" >
update tb_cutter_cncstandardvalue
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
materialcode = #{materialcode,jdbcType=VARCHAR},
equid = #{equid,jdbcType=VARCHAR},
stequgospeedvalue = #{stequgospeedvalue,jdbcType=VARCHAR},
stequcaspeedvalue = #{stequcaspeedvalue,jdbcType=VARCHAR},
stprocesscumnovalue = #{stprocesscumnovalue,jdbcType=VARCHAR},
stmechandnovalue = #{stmechandnovalue,jdbcType=VARCHAR},
stcutterlossnovalue = #{stcutterlossnovalue,jdbcType=VARCHAR},
stcutterlosssetvalue = #{stcutterlosssetvalue,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_cutter_cncstandardvalue
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_cutter_cncstandardvalue
${where}
</delete>
<select id="selectListByEquipment" parameterType="java.lang.String" resultMap="BaseResultMap">
select C.stequgospeedvalue,C.stequcaspeedvalue,C.stprocesscumnovalue,C.stmechandnovalue,C.stcutterlossnovalue,C.stcutterlosssetvalue,
C.insdt,C.id,C.insuser,C.equid,C.materialcode,
E.equipmentCardID,E.equipmentName
from tb_cutter_cncstandardvalue C
left outer join TB_EM_EquipmentCard E on E.id = C.equid
${where}
</select>
</mapper>

View File

@ -0,0 +1,293 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.CutterInfoMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.CutterInfo" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="cuttercode" property="cuttercode" jdbcType="VARCHAR" />
<result column="cuttername" property="cuttername" jdbcType="VARCHAR" />
<result column="typeid" property="typeid" jdbcType="VARCHAR" />
<result column="positionid" property="positionid" jdbcType="VARCHAR" />
<result column="life" property="life" jdbcType="DOUBLE" />
<result column="length" property="length" jdbcType="DOUBLE" />
<result column="ply" property="ply" jdbcType="DOUBLE" />
<result column="width" property="width" jdbcType="DOUBLE" />
<result column="producer" property="producer" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<association column="positionid" property="_positionname" jdbcType="VARCHAR" select="selectPosition"/>
<association column="typeid" property="_typename" jdbcType="VARCHAR" select="selectType"/>
</resultMap>
<sql id="Base_Column_List" >
id, cuttercode, cuttername, typeid, positionid, life, length, ply, width, producer,
status, remark, insuser, insdt, modify, modifydt
</sql>
<select id="selectPosition" parameterType="String" resultType="String">
select name from tb_cutter_position where id = #{positionid}
</select>
<select id="selectType" parameterType="String" resultType="String">
select typename from tb_cutter_type where id = #{typeid}
</select>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_info
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_cutter_info
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.CutterInfo" >
insert into tb_cutter_info (id, cuttercode, cuttername,
typeid, positionid, life,
length, ply, width, producer,
status, remark, insuser,
insdt, modify, modifydt
)
values (#{id,jdbcType=VARCHAR}, #{cuttercode,jdbcType=VARCHAR}, #{cuttername,jdbcType=VARCHAR},
#{typeid,jdbcType=VARCHAR}, #{positionid,jdbcType=VARCHAR}, #{life,jdbcType=DOUBLE},
#{length,jdbcType=DOUBLE}, #{ply,jdbcType=DOUBLE}, #{width,jdbcType=DOUBLE}, #{producer,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{modify,jdbcType=VARCHAR}, #{modifydt,jdbcType=TIMESTAMP}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.CutterInfo" >
insert into tb_cutter_info
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="cuttercode != null" >
cuttercode,
</if>
<if test="cuttername != null" >
cuttername,
</if>
<if test="typeid != null" >
typeid,
</if>
<if test="positionid != null" >
positionid,
</if>
<if test="life != null" >
life,
</if>
<if test="length != null" >
length,
</if>
<if test="ply != null" >
ply,
</if>
<if test="width != null" >
width,
</if>
<if test="producer != null" >
producer,
</if>
<if test="status != null" >
status,
</if>
<if test="remark != null" >
remark,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="cuttercode != null" >
#{cuttercode,jdbcType=VARCHAR},
</if>
<if test="cuttername != null" >
#{cuttername,jdbcType=VARCHAR},
</if>
<if test="typeid != null" >
#{typeid,jdbcType=VARCHAR},
</if>
<if test="positionid != null" >
#{positionid,jdbcType=VARCHAR},
</if>
<if test="life != null" >
#{life,jdbcType=DOUBLE},
</if>
<if test="length != null" >
#{length,jdbcType=DOUBLE},
</if>
<if test="ply != null" >
#{ply,jdbcType=DOUBLE},
</if>
<if test="width != null" >
#{width,jdbcType=DOUBLE},
</if>
<if test="producer != null" >
#{producer,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.CutterInfo" >
update tb_cutter_info
<set >
<if test="cuttercode != null" >
cuttercode = #{cuttercode,jdbcType=VARCHAR},
</if>
<if test="cuttername != null" >
cuttername = #{cuttername,jdbcType=VARCHAR},
</if>
<if test="typeid != null" >
typeid = #{typeid,jdbcType=VARCHAR},
</if>
<if test="positionid != null" >
positionid = #{positionid,jdbcType=VARCHAR},
</if>
<if test="life != null" >
life = #{life,jdbcType=DOUBLE},
</if>
<if test="length != null" >
length = #{length,jdbcType=DOUBLE},
</if>
<if test="ply != null" >
ply = #{ply,jdbcType=DOUBLE},
</if>
<if test="width != null" >
width = #{width,jdbcType=DOUBLE},
</if>
<if test="producer != null" >
producer = #{producer,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.CutterInfo" >
update tb_cutter_info
set cuttercode = #{cuttercode,jdbcType=VARCHAR},
cuttername = #{cuttername,jdbcType=VARCHAR},
typeid = #{typeid,jdbcType=VARCHAR},
positionid = #{positionid,jdbcType=VARCHAR},
life = #{life,jdbcType=DOUBLE},
length = #{length,jdbcType=DOUBLE},
ply = #{ply,jdbcType=DOUBLE},
width = #{width,jdbcType=DOUBLE},
producer = #{producer,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_info
${where}
</select>
<select id="getListByCutterCode" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_info
where cuttercode = #{cuttercode,jdbcType=VARCHAR}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_cutter_info
${where}
</delete>
<select id="getCutterInfo" resultMap="ResultMapMInfo" parameterType="java.lang.String">
SELECT
I.*,
T.id as t_id,
T.typename as t_name,
T.status as t_status,
P.id as p_id,
P.name as p_name,
P.status as p_status
FROM tb_cutter_info I
LEFT OUTER JOIN tb_cutter_type T ON I.typeid = T.id
Left join tb_cutter_position P on P.id = I.positionid
${where}
</select>
<resultMap id="ResultMapMInfo" type="com.sipai.entity.material.CutterInfo">
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="cuttercode" property="cuttercode" jdbcType="VARCHAR" />
<result column="cuttername" property="cuttername" jdbcType="VARCHAR" />
<result column="typeid" property="typeid" jdbcType="VARCHAR" />
<result column="positionid" property="positionid" jdbcType="VARCHAR" />
<result column="life" property="life" jdbcType="DOUBLE" />
<result column="length" property="length" jdbcType="DOUBLE" />
<result column="ply" property="ply" jdbcType="DOUBLE" />
<result column="width" property="width" jdbcType="DOUBLE" />
<result column="producer" property="producer" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<association property="cutterType" resultMap="typeResult"/>
<association property="cutterPosition" resultMap="positionResult" />
</resultMap>
<resultMap id="typeResult" type="com.sipai.entity.material.CutterType">
<id property="id" column="id"/>
<result property="typename" column="t_name"/>
<result property="status" column="t_status"/>
</resultMap>
<resultMap id="positionResult" type="com.sipai.entity.material.CutterPosition">
<id property="id" column="p_id"/>
<result property="name" column="p_name"/>
<result property="status" column="p_status"/>
</resultMap>
</mapper>

View File

@ -0,0 +1,188 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.CutterPointSetMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.CutterPointSet" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="cutterno" property="cutterno" jdbcType="VARCHAR" />
<result column="equipmentid" property="equipmentid" jdbcType="VARCHAR" />
<result column="cutterswitch" property="cutterswitch" jdbcType="VARCHAR" />
<result column="cutteramount" property="cutteramount" jdbcType="VARCHAR" />
<result column="firstpieceno" property="firstpieceno" jdbcType="VARCHAR" />
<result column="firstamount" property="firstamount" jdbcType="VARCHAR" />
<result column="autofreq" property="autofreq" jdbcType="VARCHAR" />
<result column="autoamount" property="autoamount" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, cutterno, equipmentid, cutterswitch, cutteramount, firstpieceno,
firstamount, autofreq, autoamount, pid
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_pointset
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_cutter_pointset
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.CutterPointSet" >
insert into tb_cutter_pointset (id, insuser, insdt,
cutterno, equipmentid, cutterswitch,
cutteramount, firstpieceno, firstamount,
autofreq, autoamount, pid
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{cutterno,jdbcType=VARCHAR}, #{equipmentid,jdbcType=VARCHAR}, #{cutterswitch,jdbcType=VARCHAR},
#{cutteramount,jdbcType=VARCHAR}, #{firstpieceno,jdbcType=VARCHAR}, #{firstamount,jdbcType=VARCHAR},
#{autofreq,jdbcType=VARCHAR}, #{autoamount,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.CutterPointSet" >
insert into tb_cutter_pointset
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="cutterno != null" >
cutterno,
</if>
<if test="equipmentid != null" >
equipmentid,
</if>
<if test="cutterswitch != null" >
cutterswitch,
</if>
<if test="cutteramount != null" >
cutteramount,
</if>
<if test="firstpieceno != null" >
firstpieceno,
</if>
<if test="firstamount != null" >
firstamount,
</if>
<if test="autofreq != null" >
autofreq,
</if>
<if test="autoamount != null" >
autoamount,
</if>
<if test="pid != null" >
pid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="cutterno != null" >
#{cutterno,jdbcType=VARCHAR},
</if>
<if test="equipmentid != null" >
#{equipmentid,jdbcType=VARCHAR},
</if>
<if test="cutterswitch != null" >
#{cutterswitch,jdbcType=VARCHAR},
</if>
<if test="cutteramount != null" >
#{cutteramount,jdbcType=VARCHAR},
</if>
<if test="firstpieceno != null" >
#{firstpieceno,jdbcType=VARCHAR},
</if>
<if test="firstamount != null" >
#{firstamount,jdbcType=VARCHAR},
</if>
<if test="autofreq != null" >
#{autofreq,jdbcType=VARCHAR},
</if>
<if test="autoamount != null" >
#{autoamount,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.CutterPointSet" >
update tb_cutter_pointset
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="cutterno != null" >
cutterno = #{cutterno,jdbcType=VARCHAR},
</if>
<if test="equipmentid != null" >
equipmentid = #{equipmentid,jdbcType=VARCHAR},
</if>
<if test="cutterswitch != null" >
cutterswitch = #{cutterswitch,jdbcType=VARCHAR},
</if>
<if test="cutteramount != null" >
cutteramount = #{cutteramount,jdbcType=VARCHAR},
</if>
<if test="firstpieceno != null" >
firstpieceno = #{firstpieceno,jdbcType=VARCHAR},
</if>
<if test="firstamount != null" >
firstamount = #{firstamount,jdbcType=VARCHAR},
</if>
<if test="autofreq != null" >
autofreq = #{autofreq,jdbcType=VARCHAR},
</if>
<if test="autoamount != null" >
autoamount = #{autoamount,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.CutterPointSet" >
update tb_cutter_pointset
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
cutterno = #{cutterno,jdbcType=VARCHAR},
equipmentid = #{equipmentid,jdbcType=VARCHAR},
cutterswitch = #{cutterswitch,jdbcType=VARCHAR},
cutteramount = #{cutteramount,jdbcType=VARCHAR},
firstpieceno = #{firstpieceno,jdbcType=VARCHAR},
firstamount = #{firstamount,jdbcType=VARCHAR},
autofreq = #{autofreq,jdbcType=VARCHAR},
autoamount = #{autoamount,jdbcType=VARCHAR},
pid = #{pid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_cutter_pointset
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_cutter_pointset
${where}
</delete>
</mapper>

View File

@ -0,0 +1,157 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.CutterPositionMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.CutterPosition" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="parentid" property="parentid" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, parentid, name, status, remark, insuser, insdt, modify, modifydt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_position
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_cutter_position
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.CutterPosition" >
insert into tb_cutter_position (id, parentid, name,
status, remark, insuser,
insdt, modify, modifydt
)
values (#{id,jdbcType=VARCHAR}, #{parentid,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{modify,jdbcType=VARCHAR}, #{modifydt,jdbcType=TIMESTAMP}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.CutterPosition" >
insert into tb_cutter_position
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="parentid != null" >
parentid,
</if>
<if test="name != null" >
name,
</if>
<if test="status != null" >
status,
</if>
<if test="remark != null" >
remark,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="parentid != null" >
#{parentid,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.CutterPosition" >
update tb_cutter_position
<set >
<if test="parentid != null" >
parentid = #{parentid,jdbcType=VARCHAR},
</if>
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.CutterPosition" >
update tb_cutter_position
set parentid = #{parentid,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_position
${where}
</select>
<select id="getListByName" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_position
where name = #{name,jdbcType=VARCHAR}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_cutter_position
${where}
</delete>
</mapper>

View File

@ -0,0 +1,154 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.CutterStandardMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.CutterStandard" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="stcutteramountvalue" property="stcutteramountvalue" jdbcType="VARCHAR" />
<result column="stfirstpiecenovalue" property="stfirstpiecenovalue" jdbcType="VARCHAR" />
<result column="stfirstamountvalue" property="stfirstamountvalue" jdbcType="VARCHAR" />
<result column="stautofreqvalue" property="stautofreqvalue" jdbcType="VARCHAR" />
<result column="stautoamountvalue" property="stautoamountvalue" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, stcutteramountvalue, stfirstpiecenovalue, stfirstamountvalue,
stautofreqvalue, stautoamountvalue, pid
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_cutterstandardvalue
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_cutter_cutterstandardvalue
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.CutterStandard" >
insert into tb_cutter_cutterstandardvalue (id, insuser, insdt,
stcutteramountvalue, stfirstpiecenovalue,
stfirstamountvalue, stautofreqvalue, stautoamountvalue,
pid)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{stcutteramountvalue,jdbcType=VARCHAR}, #{stfirstpiecenovalue,jdbcType=VARCHAR},
#{stfirstamountvalue,jdbcType=VARCHAR}, #{stautofreqvalue,jdbcType=VARCHAR}, #{stautoamountvalue,jdbcType=VARCHAR},
#{pid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.CutterStandard" >
insert into tb_cutter_cutterstandardvalue
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="stcutteramountvalue != null" >
stcutteramountvalue,
</if>
<if test="stfirstpiecenovalue != null" >
stfirstpiecenovalue,
</if>
<if test="stfirstamountvalue != null" >
stfirstamountvalue,
</if>
<if test="stautofreqvalue != null" >
stautofreqvalue,
</if>
<if test="stautoamountvalue != null" >
stautoamountvalue,
</if>
<if test="pid != null" >
pid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="stcutteramountvalue != null" >
#{stcutteramountvalue,jdbcType=VARCHAR},
</if>
<if test="stfirstpiecenovalue != null" >
#{stfirstpiecenovalue,jdbcType=VARCHAR},
</if>
<if test="stfirstamountvalue != null" >
#{stfirstamountvalue,jdbcType=VARCHAR},
</if>
<if test="stautofreqvalue != null" >
#{stautofreqvalue,jdbcType=VARCHAR},
</if>
<if test="stautoamountvalue != null" >
#{stautoamountvalue,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.CutterStandard" >
update tb_cutter_cutterstandardvalue
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="stcutteramountvalue != null" >
stcutteramountvalue = #{stcutteramountvalue,jdbcType=VARCHAR},
</if>
<if test="stfirstpiecenovalue != null" >
stfirstpiecenovalue = #{stfirstpiecenovalue,jdbcType=VARCHAR},
</if>
<if test="stfirstamountvalue != null" >
stfirstamountvalue = #{stfirstamountvalue,jdbcType=VARCHAR},
</if>
<if test="stautofreqvalue != null" >
stautofreqvalue = #{stautofreqvalue,jdbcType=VARCHAR},
</if>
<if test="stautoamountvalue != null" >
stautoamountvalue = #{stautoamountvalue,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.CutterStandard" >
update tb_cutter_cutterstandardvalue
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
stcutteramountvalue = #{stcutteramountvalue,jdbcType=VARCHAR},
stfirstpiecenovalue = #{stfirstpiecenovalue,jdbcType=VARCHAR},
stfirstamountvalue = #{stfirstamountvalue,jdbcType=VARCHAR},
stautofreqvalue = #{stautofreqvalue,jdbcType=VARCHAR},
stautoamountvalue = #{stautoamountvalue,jdbcType=VARCHAR},
pid = #{pid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_cutter_cutterstandardvalue
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_cutter_cutterstandardvalue
${where}
</delete>
</mapper>

View File

@ -0,0 +1,157 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.CutterTypeMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.CutterType" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="parentid" property="parentid" jdbcType="VARCHAR" />
<result column="typename" property="typename" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, parentid, typename, status, remark, insuser, insdt, modify, modifydt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_type
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_cutter_type
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.CutterType" >
insert into tb_cutter_type (id, parentid, typename,
status, remark, insuser,
insdt, modify, modifydt
)
values (#{id,jdbcType=VARCHAR}, #{parentid,jdbcType=VARCHAR}, #{typename,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{modify,jdbcType=VARCHAR}, #{modifydt,jdbcType=TIMESTAMP}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.CutterType" >
insert into tb_cutter_type
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="parentid != null" >
parentid,
</if>
<if test="typename != null" >
typename,
</if>
<if test="status != null" >
status,
</if>
<if test="remark != null" >
remark,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="parentid != null" >
#{parentid,jdbcType=VARCHAR},
</if>
<if test="typename != null" >
#{typename,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.CutterType" >
update tb_cutter_type
<set >
<if test="parentid != null" >
parentid = #{parentid,jdbcType=VARCHAR},
</if>
<if test="typename != null" >
typename = #{typename,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.CutterType" >
update tb_cutter_type
set parentid = #{parentid,jdbcType=VARCHAR},
typename = #{typename,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_type
${where}
</select>
<select id="getListByTypename" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_cutter_type
where typename = #{typename,jdbcType=VARCHAR}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_cutter_type
${where}
</delete>
</mapper>

View File

@ -0,0 +1,218 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.inkalertMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.Inkalert" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="inkbatchNo" property="inkbatchno" jdbcType="VARCHAR" />
<result column="boardbatchNo" property="boardbatchno" jdbcType="VARCHAR" />
<result column="handletime" property="handletime" jdbcType="TIMESTAMP" />
<result column="handleuesr" property="handleuesr" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="lastinkbatchNo" property="lastinkbatchno" jdbcType="VARCHAR" />
<result column="lastboardbatchNo" property="lastboardbatchno" jdbcType="VARCHAR" />
<result column="lasthandletime" property="lasthandletime" jdbcType="TIMESTAMP" />
<result column="no" property="no" jdbcType="VARCHAR" />
<result column="equipmentname" property="equipmentname" jdbcType="VARCHAR" />
<result column="starttime" property="starttime" jdbcType="TIMESTAMP" />
<result column="parameter1" property="parameter1" jdbcType="TIMESTAMP" /><!-- 机台油墨提醒时间间隔 -->
<result column="parameter2" property="parameter2" jdbcType="TIMESTAMP" /><!-- 机台网板提醒时间间隔 -->
</resultMap>
<sql id="Base_Column_List" >
id, equipmentCardID, inkbatchNo, boardbatchNo, handletime, handleuesr, insuser, insdt,
lastinkbatchNo, lastboardbatchNo, lasthandletime
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_inkalert
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_inkalert
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.Inkalert" >
insert into tb_material_inkalert (id, equipmentCardID, inkbatchNo,
boardbatchNo, handletime, handleuesr,
insuser, insdt, lastinkbatchNo,
lastboardbatchNo, lasthandletime)
values (#{id,jdbcType=VARCHAR}, #{equipmentcardid,jdbcType=VARCHAR}, #{inkbatchno,jdbcType=VARCHAR},
#{boardbatchno,jdbcType=VARCHAR}, #{handletime,jdbcType=TIMESTAMP}, #{handleuesr,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{lastinkbatchno,jdbcType=VARCHAR},
#{lastboardbatchno,jdbcType=VARCHAR}, #{lasthandletime,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.Inkalert" >
insert into tb_material_inkalert
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="equipmentcardid != null" >
equipmentCardID,
</if>
<if test="inkbatchno != null" >
inkbatchNo,
</if>
<if test="boardbatchno != null" >
boardbatchNo,
</if>
<if test="handletime != null" >
handletime,
</if>
<if test="handleuesr != null" >
handleuesr,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="lastinkbatchno != null" >
lastinkbatchNo,
</if>
<if test="lastboardbatchno != null" >
lastboardbatchNo,
</if>
<if test="lasthandletime != null" >
lasthandletime,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
#{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="inkbatchno != null" >
#{inkbatchno,jdbcType=VARCHAR},
</if>
<if test="boardbatchno != null" >
#{boardbatchno,jdbcType=VARCHAR},
</if>
<if test="handletime != null" >
#{handletime,jdbcType=TIMESTAMP},
</if>
<if test="handleuesr != null" >
#{handleuesr,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="lastinkbatchno != null" >
#{lastinkbatchno,jdbcType=VARCHAR},
</if>
<if test="lastboardbatchno != null" >
#{lastboardbatchno,jdbcType=VARCHAR},
</if>
<if test="lasthandletime != null" >
#{lasthandletime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.Inkalert" >
update tb_material_inkalert
<set >
<if test="equipmentcardid != null" >
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="inkbatchno != null" >
inkbatchNo = #{inkbatchno,jdbcType=VARCHAR},
</if>
<if test="boardbatchno != null" >
boardbatchNo = #{boardbatchno,jdbcType=VARCHAR},
</if>
<if test="handletime != null" >
handletime = #{handletime,jdbcType=TIMESTAMP},
</if>
<if test="handleuesr != null" >
handleuesr = #{handleuesr,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="lastinkbatchno != null" >
lastinkbatchNo = #{lastinkbatchno,jdbcType=VARCHAR},
</if>
<if test="lastboardbatchno != null" >
lastboardbatchNo = #{lastboardbatchno,jdbcType=VARCHAR},
</if>
<if test="lasthandletime != null" >
lasthandletime = #{lasthandletime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.Inkalert" >
update tb_material_inkalert
set equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
inkbatchNo = #{inkbatchno,jdbcType=VARCHAR},
boardbatchNo = #{boardbatchno,jdbcType=VARCHAR},
handletime = #{handletime,jdbcType=TIMESTAMP},
handleuesr = #{handleuesr,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
lastinkbatchNo = #{lastinkbatchno,jdbcType=VARCHAR},
lastboardbatchNo = #{lastboardbatchno,jdbcType=VARCHAR},
lasthandletime = #{lasthandletime,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_inkalert
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_inkalert
${where}
</delete>
<select id="selectInkByMachine" resultMap="BaseResultMap" parameterType="java.lang.String" >
select card.id AS equipmentCardID,
inkb.No as no,inkb.id AS lastinkbatchNo,
inkb.starttime,ink.parameter1,
card.equipmentName
from tb_material_inkinfo ink
left join TB_EM_EquipmentCard card on card.id=ink.equipmentCardID
left join tb_material_inkbatchmachine inkm on card.id=inkm.equipmentCardID
left join tb_material_inkbatch inkb on inkb.id= inkm.No
${where}
</select>
<select id="selectBoardByMachine" resultMap="BaseResultMap" parameterType="java.lang.String" >
select C.id AS equipmentCardID,
B.No as no,B.id AS lastboardbatchNo,
B.starttime,I.parameter2 as parameter2,
C.equipmentName
from tb_material_inkinfo I
left join TB_EM_EquipmentCard C on C.id=I.equipmentCardID
left join tb_material_boardbatchmachine M on C.id=M.equipmentCardID
left join tb_material_boardbatch B on B.id= M.No
${where}
</select>
<select id="getListByAlert" resultMap="BaseResultMap" parameterType="java.lang.String" >
select I.No AS inkbatchno,
E.equipmentcardid,
E.equipmentName,
A.handletime,A.handleuesr,B.no AS boardbatchno,
A.id AS id
from tb_material_inkalert A
left join TB_EM_EquipmentCard E on E.id=A.equipmentCardID
left join tb_material_inkbatch I on I.id= A.inkbatchNo
left join tb_material_boardbatch B on B.id= A.boardbatchNo
${where}
</select>
</mapper>

View File

@ -0,0 +1,248 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="material.inkbatchMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.material.Inkbatch">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="No" jdbcType="VARCHAR" property="no" />
<result column="status" jdbcType="VARCHAR" property="status" />
<result column="starttime" jdbcType="TIMESTAMP" property="starttime" />
<result column="endtime" jdbcType="TIMESTAMP" property="endtime" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="alterdt" jdbcType="TIMESTAMP" property="alterdt" />
<result column="alteruser" jdbcType="VARCHAR" property="alteruser" />
<result column="alterstatus" jdbcType="VARCHAR" property="alterstatus" />
<result column="processrealid" jdbcType="VARCHAR" property="processrealid" />
</resultMap>
<sql id="Base_Column_List">
id, type, name, No, status, starttime, endtime, insuser, insdt, alterdt, alteruser,
alterstatus, processrealid
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_inkbatch
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_material_inkbatch
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.Inkbatch">
insert into tb_material_inkbatch (id, type, name,
No, status, starttime,
endtime, insuser, insdt,
alterdt, alteruser, alterstatus,
processrealid)
values (#{id,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{no,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR}, #{starttime,jdbcType=TIMESTAMP},
#{endtime,jdbcType=TIMESTAMP}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{alterdt,jdbcType=TIMESTAMP}, #{alteruser,jdbcType=VARCHAR}, #{alterstatus,jdbcType=VARCHAR},
#{processrealid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.Inkbatch">
insert into tb_material_inkbatch
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="type != null">
type,
</if>
<if test="name != null">
name,
</if>
<if test="no != null">
No,
</if>
<if test="status != null">
status,
</if>
<if test="starttime != null">
starttime,
</if>
<if test="endtime != null">
endtime,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="alterdt != null">
alterdt,
</if>
<if test="alteruser != null">
alteruser,
</if>
<if test="alterstatus != null">
alterstatus,
</if>
<if test="processrealid != null">
processrealid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="type != null">
#{type,jdbcType=VARCHAR},
</if>
<if test="name != null">
#{name,jdbcType=VARCHAR},
</if>
<if test="no != null">
#{no,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=VARCHAR},
</if>
<if test="starttime != null">
#{starttime,jdbcType=TIMESTAMP},
</if>
<if test="endtime != null">
#{endtime,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="alterdt != null">
#{alterdt,jdbcType=TIMESTAMP},
</if>
<if test="alteruser != null">
#{alteruser,jdbcType=VARCHAR},
</if>
<if test="alterstatus != null">
#{alterstatus,jdbcType=VARCHAR},
</if>
<if test="processrealid != null">
#{processrealid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.Inkbatch">
update tb_material_inkbatch
<set>
<if test="type != null">
type = #{type,jdbcType=VARCHAR},
</if>
<if test="name != null">
name = #{name,jdbcType=VARCHAR},
</if>
<if test="no != null">
No = #{no,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=VARCHAR},
</if>
<if test="starttime != null">
starttime = #{starttime,jdbcType=TIMESTAMP},
</if>
<if test="endtime != null">
endtime = #{endtime,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="alterdt != null">
alterdt = #{alterdt,jdbcType=TIMESTAMP},
</if>
<if test="alteruser != null">
alteruser = #{alteruser,jdbcType=VARCHAR},
</if>
<if test="alterstatus != null">
alterstatus = #{alterstatus,jdbcType=VARCHAR},
</if>
<if test="processrealid != null">
processrealid = #{processrealid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.Inkbatch">
update tb_material_inkbatch
set type = #{type,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
No = #{no,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
starttime = #{starttime,jdbcType=TIMESTAMP},
endtime = #{endtime,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
alterdt = #{alterdt,jdbcType=TIMESTAMP},
alteruser = #{alteruser,jdbcType=VARCHAR},
alterstatus = #{alterstatus,jdbcType=VARCHAR},
processrealid = #{processrealid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_inkbatch
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_material_inkbatch
${where}
</delete>
<select id="getListByNo" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_inkbatch
where No = #{no,jdbcType=VARCHAR}
</select>
<select id="getListByName" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_inkbatch
where name = #{name,jdbcType=VARCHAR}
</select>
<resultMap id="BaseResultMap1" type="com.sipai.entity.material.Inkbatch">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="No" jdbcType="VARCHAR" property="no" />
<result column="status" jdbcType="VARCHAR" property="status" />
<result column="starttime" jdbcType="TIMESTAMP" property="starttime" />
<result column="endtime" jdbcType="TIMESTAMP" property="endtime" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="alterdt" jdbcType="TIMESTAMP" property="alterdt" />
<result column="alteruser" jdbcType="VARCHAR" property="alteruser" />
<result column="equipmentName" jdbcType="VARCHAR" property="equipmentName" />
<result column="equipmentcardid" jdbcType="VARCHAR" property="equipmentcardid" />
<result column="processrealid" jdbcType="VARCHAR" property="processrealid" />
</resultMap>
<sql id="Base_Column_List1">
id, type, name, No, status, starttime, endtime, insuser, insdt, alterdt, alteruser,
alterstatus, processrealid,equipmentcardid,equipmentName
</sql>
<select id="getListByEquipmentName" parameterType="com.sipai.entity.material.Inkbatch" resultMap="BaseResultMap1">
select p.id,p.type,p.name,p.status,p.starttime,p.endtime,p.alteruser,p.alterdt,p.No,p.processrealid,t.equipmentName,t.equipmentcardid
from (select M.equipmentcardid AS equid,M.status AS machinestatus,I.type AS type,I.name,I.status,I.starttime,I.No,I.id,
I.endtime,I.alteruser,I.alterdt,I.processrealid
from tb_material_inkbatch I ,tb_material_inkbatchmachine M
where M.No = I.id) p
left outer join TB_EM_EquipmentCard t on p.equid = t.id
${where}
</select>
<select id="getListByInkno" resultMap="BaseResultMap1" parameterType="java.lang.String" >
select
<include refid="Base_Column_List1" />
from tb_material_inkbatch
where No = #{No,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,135 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.InkbatchmachineMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.Inkbatchmachine" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="No" property="no" jdbcType="VARCHAR" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, No, equipmentCardID, status
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_inkbatchmachine
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_inkbatchmachine
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.Inkbatchmachine" >
insert into tb_material_inkbatchmachine (id, insuser, insdt,
No, equipmentCardID, status
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{no,jdbcType=VARCHAR}, #{equipmentcardid,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.Inkbatchmachine" >
insert into tb_material_inkbatchmachine
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="no != null" >
No,
</if>
<if test="equipmentcardid != null" >
equipmentCardID,
</if>
<if test="status != null" >
status,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="no != null" >
#{no,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
#{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.Inkbatchmachine" >
update tb_material_inkbatchmachine
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="no != null" >
No = #{no,jdbcType=VARCHAR},
</if>
<if test="equipmentcardid != null" >
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.Inkbatchmachine" >
update tb_material_inkbatchmachine
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
No = #{no,jdbcType=VARCHAR},
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_inkbatchmachine
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_inkbatchmachine
${where}
</delete>
<resultMap id="BaseResultMap1" type="com.sipai.entity.equipment.EquipmentCard" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="ibmstatus" property="ibmstatus" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="VARCHAR" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="equipmentClassID" property="equipmentclassid" jdbcType="VARCHAR" />
<result column="equipmentModel" property="equipmentmodel" jdbcType="VARCHAR" />
<result column="areaID" property="areaid" jdbcType="VARCHAR" />
<result column="equipmentName" property="equipmentname" jdbcType="CLOB" />
</resultMap>
<select id="getEquipmentCard" resultMap="BaseResultMap1" parameterType="java.lang.String">
select E.*,
M.status AS ibmstatus
from tb_material_inkbatchmachine M
left join TB_EM_EquipmentCard E on E.id=M.equipmentCardID
${where}
</select>
</mapper>

View File

@ -0,0 +1,259 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.InkinfoMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.Inkinfo" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="operator" property="operator" jdbcType="VARCHAR" />
<result column="time" property="time" jdbcType="TIMESTAMP" />
<result column="parameter1" property="parameter1" jdbcType="VARCHAR" />
<result column="parameter2" property="parameter2" jdbcType="VARCHAR" />
<result column="parameter3" property="parameter3" jdbcType="VARCHAR" />
<result column="parameter4" property="parameter4" jdbcType="VARCHAR" />
<result column="parameter5" property="parameter5" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="equipmentName" property="equipmentname" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id,operator, time, parameter1, parameter2, parameter3, parameter4, parameter5,
insuser, insdt, equipmentCardID
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_inkinfo
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_inkinfo
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.Inkinfo" >
insert into tb_material_inkinfo (id, operator,
time, parameter1, parameter2,
parameter3, parameter4, parameter5,
insuser, insdt, equipmentCardID
)
values (#{id,jdbcType=VARCHAR}, #{operator,jdbcType=VARCHAR},
#{time,jdbcType=TIMESTAMP}, #{parameter1,jdbcType=VARCHAR}, #{parameter2,jdbcType=VARCHAR},
#{parameter3,jdbcType=VARCHAR}, #{parameter4,jdbcType=VARCHAR}, #{parameter5,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{equipmentcardid,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.Inkinfo" >
insert into tb_material_inkinfo
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="operator != null" >
operator,
</if>
<if test="time != null" >
time,
</if>
<if test="parameter1 != null" >
parameter1,
</if>
<if test="parameter2 != null" >
parameter2,
</if>
<if test="parameter3 != null" >
parameter3,
</if>
<if test="parameter4 != null" >
parameter4,
</if>
<if test="parameter5 != null" >
parameter5,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="equipmentcardid != null" >
equipmentCardID,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="operator != null" >
#{operator,jdbcType=VARCHAR},
</if>
<if test="time != null" >
#{time,jdbcType=TIMESTAMP},
</if>
<if test="parameter1 != null" >
#{parameter1,jdbcType=VARCHAR},
</if>
<if test="parameter2 != null" >
#{parameter2,jdbcType=VARCHAR},
</if>
<if test="parameter3 != null" >
#{parameter3,jdbcType=VARCHAR},
</if>
<if test="parameter4 != null" >
#{parameter4,jdbcType=VARCHAR},
</if>
<if test="parameter5 != null" >
#{parameter5,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="equipmentcardid != null" >
#{equipmentcardid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.Inkinfo" >
update tb_material_inkinfo
<set >
<if test="operator != null" >
operator = #{operator,jdbcType=VARCHAR},
</if>
<if test="time != null" >
time = #{time,jdbcType=TIMESTAMP},
</if>
<if test="parameter1 != null" >
parameter1 = #{parameter1,jdbcType=VARCHAR},
</if>
<if test="parameter2 != null" >
parameter2 = #{parameter2,jdbcType=VARCHAR},
</if>
<if test="parameter3 != null" >
parameter3 = #{parameter3,jdbcType=VARCHAR},
</if>
<if test="parameter4 != null" >
parameter4 = #{parameter4,jdbcType=VARCHAR},
</if>
<if test="parameter5 != null" >
parameter5 = #{parameter5,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="equipmentcardid != null" >
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.Inkinfo" >
update tb_material_inkinfo
set operator = #{operator,jdbcType=VARCHAR},
time = #{time,jdbcType=TIMESTAMP},
parameter1 = #{parameter1,jdbcType=VARCHAR},
parameter2 = #{parameter2,jdbcType=VARCHAR},
parameter3 = #{parameter3,jdbcType=VARCHAR},
parameter4 = #{parameter4,jdbcType=VARCHAR},
parameter5 = #{parameter5,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
equipmentCardID = #{equipmentcardid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_inkinfo
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_inkinfo
${where}
</delete>
<resultMap id="BaseResultMap1" type="com.sipai.entity.material.Inkinfo" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="operator" property="operator" jdbcType="VARCHAR" />
<result column="time" property="time" jdbcType="TIMESTAMP" />
<result column="parameter1" property="parameter1" jdbcType="VARCHAR" />
<result column="parameter2" property="parameter2" jdbcType="VARCHAR" />
<result column="parameter3" property="parameter3" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="equipmentName" property="equipmentname" jdbcType="VARCHAR" />
<result column="equipmentcode" property="equipmentcode" jdbcType="VARCHAR" />
<result column="equipmentClassID" property="equipmentclassid" jdbcType="VARCHAR" />
<result column="equipmentModel" property="equipmentmodel" jdbcType="VARCHAR" />
<result column="areaID" property="areaid" jdbcType="VARCHAR" />
<result column="currentManageFlag" property="currentmanageflag" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="equipmentClassName" property="equipmentclassname" jdbcType="VARCHAR" />
<result column="areaName" property="areaname" jdbcType="VARCHAR" />
</resultMap>
<select id="getListByEquipmentcardid" resultMap="BaseResultMap1" parameterType="java.lang.String" >
select I.id AS id,
I.operator AS operator,
I.time AS time,
I.parameter1 AS parameter1,
I.parameter2 AS parameter2,
I.parameter3 AS parameter3,
I.insdt AS I_insdt,
I.insuser AS I_insuser,
E.equipmentCardID AS equipmentcode,
E.id AS equipmentCardID,
E.equipmentName AS equipmentName
from tb_material_inkinfo I
left outer join TB_EM_EquipmentCard E on E.id= I.equipmentCardID
${where}
</select>
<resultMap id="ClassResultMapEquipmentCard" type="com.sipai.entity.equipment.EquipmentCard">
<id property="id" column="e_id" jdbcType="VARCHAR" />
<result column="equipmentCardID" property="equipmentcardid" jdbcType="VARCHAR" />
<result column="equipmentName" property="equipmentname" jdbcType="VARCHAR" />
<result column="equipmentClassID" property="equipmentclassid" jdbcType="VARCHAR" />
<result column="equipmentModel" property="equipmentmodel" jdbcType="VARCHAR" />
<result column="areaID" property="areaid" jdbcType="VARCHAR" />
<result column="currentManageFlag" property="currentmanageflag" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="equipmentcode" property="equipmentcode" jdbcType="VARCHAR" />
<association property="equipmentclass" resultMap="equipmentclassResult" />
<association property="geographyarea" resultMap="geographyareaResult" />
</resultMap>
<resultMap id="equipmentclassResult" type="com.sipai.entity.equipment.EquipmentClass">
<id property="id" column="c_id"/>
<result property="name" column="c_name"/>
</resultMap>
<resultMap id="geographyareaResult" type="com.sipai.entity.equipment.GeographyArea">
<id property="id" column="g_id"/>
<result property="name" column="g_name"/>
</resultMap>
<select id="getEquipmentcard" resultMap="ClassResultMapEquipmentCard" parameterType="java.lang.String" >
SELECT
E.id as e_id,
E.equipmentCardID,
E.equipmentName,
E.equipmentClassID,
E.equipmentModel,
E.areaID,
E.currentManageFlag,
E.remark,
C.id as c_id,
C.name as c_name,
G.id as g_id,
G.name as g_name
FROM tb_material_inkinfo I
LEFT OUTER JOIN TB_EM_EquipmentCard E ON E.id = I.equipmentCardID
LEFT OUTER JOIN TB_EM_EquipmentClass C ON C.id = E.equipmentClassID
LEFT OUTER JOIN TB_EM_GeographyArea G ON G.id = E.areaID
${where}
</select>
</mapper>

View File

@ -0,0 +1,174 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="material.MaterialApplicationMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialApplication">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="workorderid" jdbcType="VARCHAR" property="workorderid" />
<result column="materialcode" jdbcType="VARCHAR" property="materialcode" />
<result column="materialname" jdbcType="VARCHAR" property="materialname" />
<result column="currentInventory" jdbcType="VARCHAR" property="currentinventory" />
<result column="materialRequest" jdbcType="VARCHAR" property="materialrequest" />
<result column="supplyMaterial" jdbcType="VARCHAR" property="supplymaterial" />
<result column="status" jdbcType="VARCHAR" property="status" />
<result column="taskorderid" jdbcType="VARCHAR" property="taskorderid" />
</resultMap>
<sql id="Base_Column_List">
id, insuser, insdt, workorderid, materialcode, materialname, currentInventory, materialRequest,
supplyMaterial, status, taskorderid
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_application
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_material_application
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialApplication">
insert into tb_material_application (id, insuser, insdt,
workorderid, materialcode, materialname,
currentInventory, materialRequest, supplyMaterial,
status, taskorderid)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{workorderid,jdbcType=VARCHAR}, #{materialcode,jdbcType=VARCHAR}, #{materialname,jdbcType=VARCHAR},
#{currentinventory,jdbcType=VARCHAR}, #{materialrequest,jdbcType=VARCHAR}, #{supplymaterial,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR}, #{taskorderid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialApplication">
insert into tb_material_application
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="workorderid != null">
workorderid,
</if>
<if test="materialcode != null">
materialcode,
</if>
<if test="materialname != null">
materialname,
</if>
<if test="currentinventory != null">
currentInventory,
</if>
<if test="materialrequest != null">
materialRequest,
</if>
<if test="supplymaterial != null">
supplyMaterial,
</if>
<if test="status != null">
status,
</if>
<if test="taskorderid != null">
taskorderid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="workorderid != null">
#{workorderid,jdbcType=VARCHAR},
</if>
<if test="materialcode != null">
#{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null">
#{materialname,jdbcType=VARCHAR},
</if>
<if test="currentinventory != null">
#{currentinventory,jdbcType=VARCHAR},
</if>
<if test="materialrequest != null">
#{materialrequest,jdbcType=VARCHAR},
</if>
<if test="supplymaterial != null">
#{supplymaterial,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=VARCHAR},
</if>
<if test="taskorderid != null">
#{taskorderid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialApplication">
update tb_material_application
<set>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="workorderid != null">
workorderid = #{workorderid,jdbcType=VARCHAR},
</if>
<if test="materialcode != null">
materialcode = #{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null">
materialname = #{materialname,jdbcType=VARCHAR},
</if>
<if test="currentinventory != null">
currentInventory = #{currentinventory,jdbcType=VARCHAR},
</if>
<if test="materialrequest != null">
materialRequest = #{materialrequest,jdbcType=VARCHAR},
</if>
<if test="supplymaterial != null">
supplyMaterial = #{supplymaterial,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=VARCHAR},
</if>
<if test="taskorderid != null">
taskorderid = #{taskorderid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialApplication">
update tb_material_application
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
workorderid = #{workorderid,jdbcType=VARCHAR},
materialcode = #{materialcode,jdbcType=VARCHAR},
materialname = #{materialname,jdbcType=VARCHAR},
currentInventory = #{currentinventory,jdbcType=VARCHAR},
materialRequest = #{materialrequest,jdbcType=VARCHAR},
supplyMaterial = #{supplymaterial,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
taskorderid = #{taskorderid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_application
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_material_application
${where}
</delete>
</mapper>

View File

@ -0,0 +1,653 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.MaterialBOMMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialBOM" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="materialname" property="materialname" jdbcType="VARCHAR" />
<result column="materialmodel" property="materialmodel" jdbcType="VARCHAR" />
<result column="materialproperties" property="materialproperties" jdbcType="VARCHAR" />
<result column="secondaryattribute" property="secondaryattribute" jdbcType="VARCHAR" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="num" property="num" jdbcType="VARCHAR" />
<result column="yield" property="yield" jdbcType="VARCHAR" />
<result column="state" property="state" jdbcType="VARCHAR" />
<result column="audit" property="audit" jdbcType="VARCHAR" />
<result column="version" property="version" jdbcType="VARCHAR" />
<result column="drawnum" property="drawnum" jdbcType="VARCHAR" />
<result column="processlinecode" property="processlinecode" jdbcType="VARCHAR" />
<result column="processlinename" property="processlinename" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="lastinsuser" property="lastinsuser" jdbcType="VARCHAR" />
<result column="lastinsdt" property="lastinsdt" jdbcType="TIMESTAMP" />
<result column="usepeople" property="usepeople" jdbcType="VARCHAR" />
<result column="userdt" property="userdt" jdbcType="TIMESTAMP" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="jumplayer" property="jumplayer" jdbcType="VARCHAR" />
<result column="levels" property="levels" jdbcType="VARCHAR" />
<result column="unituse" property="unituse" jdbcType="VARCHAR" />
<result column="dosage" property="dosage" jdbcType="VARCHAR" />
<result column="usualuseunit" property="usualuseunit" jdbcType="VARCHAR" />
<result column="plannedpercentage" property="plannedpercentage" jdbcType="VARCHAR" />
<result column="wearrate" property="wearrate" jdbcType="VARCHAR" />
<result column="itemtype" property="itemtype" jdbcType="VARCHAR" />
<result column="operationnumber" property="operationnumber" jdbcType="VARCHAR" />
<result column="process" property="process" jdbcType="VARCHAR" />
<result column="station" property="station" jdbcType="VARCHAR" />
<result column="localnum" property="localnum" jdbcType="VARCHAR" />
<result column="billetsize" property="billetsize" jdbcType="VARCHAR" />
<result column="billetnum" property="billetnum" jdbcType="VARCHAR" />
<result column="warehouse" property="warehouse" jdbcType="VARCHAR" />
<result column="keysymbol" property="keysymbol" jdbcType="VARCHAR" />
<result column="usestate" property="usestate" jdbcType="VARCHAR" />
<result column="ifdown" property="ifdown" jdbcType="VARCHAR" />
<result column="remark1" property="remark1" jdbcType="VARCHAR" />
<result column="remark2" property="remark2" jdbcType="VARCHAR" />
<result column="inventory" property="inventory" jdbcType="VARCHAR" />
<result column="ifpour" property="ifpour" jdbcType="VARCHAR" />
<result column="havereplace" property="havereplace" jdbcType="VARCHAR" />
<result column="faildt" property="faildt" jdbcType="TIMESTAMP" />
<result column="effectdt" property="effectdt" jdbcType="TIMESTAMP" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="usuallyunit" property="usuallyunit" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, materialcode, materialname, materialmodel, materialproperties, secondaryattribute,
unit, num, yield, state, audit, version, drawnum, processlinecode, processlinename,
insuser, insdt, lastinsuser, lastinsdt, usepeople, userdt, remark, jumplayer, levels,
unituse, dosage, usualuseunit, plannedpercentage, wearrate, itemtype, operationnumber,
process, station, localnum, billetsize, billetnum, warehouse, keysymbol, usestate,
ifdown, remark1, remark2, inventory, ifpour, havereplace, faildt, effectdt, pid, usuallyunit
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_allinfo
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_allinfo
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialBOM" >
insert into tb_material_allinfo (id, materialcode, materialname,
materialmodel, materialproperties, secondaryattribute,
unit, num, yield, state,
audit, version, drawnum,
processlinecode, processlinename, insuser,
insdt, lastinsuser, lastinsdt,
usepeople, userdt, remark,
jumplayer, levels, unituse,
dosage, usualuseunit, plannedpercentage,
wearrate, itemtype, operationnumber,
process, station, localnum,
billetsize, billetnum, warehouse,
keysymbol, usestate, ifdown,
remark1, remark2, inventory,
ifpour, havereplace, faildt,
effectdt, pid, usuallyunit
)
values (#{id,jdbcType=VARCHAR}, #{materialcode,jdbcType=VARCHAR}, #{materialname,jdbcType=VARCHAR},
#{materialmodel,jdbcType=VARCHAR}, #{materialproperties,jdbcType=VARCHAR}, #{secondaryattribute,jdbcType=VARCHAR},
#{unit,jdbcType=VARCHAR}, #{num,jdbcType=VARCHAR}, #{yield,jdbcType=VARCHAR}, #{state,jdbcType=VARCHAR},
#{audit,jdbcType=VARCHAR}, #{version,jdbcType=VARCHAR}, #{drawnum,jdbcType=VARCHAR},
#{processlinecode,jdbcType=VARCHAR}, #{processlinename,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{lastinsuser,jdbcType=VARCHAR}, #{lastinsdt,jdbcType=TIMESTAMP},
#{usepeople,jdbcType=VARCHAR}, #{userdt,jdbcType=TIMESTAMP}, #{remark,jdbcType=VARCHAR},
#{jumplayer,jdbcType=VARCHAR}, #{levels,jdbcType=VARCHAR}, #{unituse,jdbcType=VARCHAR},
#{dosage,jdbcType=VARCHAR}, #{usualuseunit,jdbcType=VARCHAR}, #{plannedpercentage,jdbcType=VARCHAR},
#{wearrate,jdbcType=VARCHAR}, #{itemtype,jdbcType=VARCHAR}, #{operationnumber,jdbcType=VARCHAR},
#{process,jdbcType=VARCHAR}, #{station,jdbcType=VARCHAR}, #{localnum,jdbcType=VARCHAR},
#{billetsize,jdbcType=VARCHAR}, #{billetnum,jdbcType=VARCHAR}, #{warehouse,jdbcType=VARCHAR},
#{keysymbol,jdbcType=VARCHAR}, #{usestate,jdbcType=VARCHAR}, #{ifdown,jdbcType=VARCHAR},
#{remark1,jdbcType=VARCHAR}, #{remark2,jdbcType=VARCHAR}, #{inventory,jdbcType=VARCHAR},
#{ifpour,jdbcType=VARCHAR}, #{havereplace,jdbcType=VARCHAR}, #{faildt,jdbcType=TIMESTAMP},
#{effectdt,jdbcType=TIMESTAMP}, #{pid,jdbcType=VARCHAR}, #{usuallyunit,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialBOM" >
insert into tb_material_allinfo
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="materialcode != null" >
materialcode,
</if>
<if test="materialname != null" >
materialname,
</if>
<if test="materialmodel != null" >
materialmodel,
</if>
<if test="materialproperties != null" >
materialproperties,
</if>
<if test="secondaryattribute != null" >
secondaryattribute,
</if>
<if test="unit != null" >
unit,
</if>
<if test="num != null" >
num,
</if>
<if test="yield != null" >
yield,
</if>
<if test="state != null" >
state,
</if>
<if test="audit != null" >
audit,
</if>
<if test="version != null" >
version,
</if>
<if test="drawnum != null" >
drawnum,
</if>
<if test="processlinecode != null" >
processlinecode,
</if>
<if test="processlinename != null" >
processlinename,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="lastinsuser != null" >
lastinsuser,
</if>
<if test="lastinsdt != null" >
lastinsdt,
</if>
<if test="usepeople != null" >
usepeople,
</if>
<if test="userdt != null" >
userdt,
</if>
<if test="remark != null" >
remark,
</if>
<if test="jumplayer != null" >
jumplayer,
</if>
<if test="levels != null" >
levels,
</if>
<if test="unituse != null" >
unituse,
</if>
<if test="dosage != null" >
dosage,
</if>
<if test="usualuseunit != null" >
usualuseunit,
</if>
<if test="plannedpercentage != null" >
plannedpercentage,
</if>
<if test="wearrate != null" >
wearrate,
</if>
<if test="itemtype != null" >
itemtype,
</if>
<if test="operationnumber != null" >
operationnumber,
</if>
<if test="process != null" >
process,
</if>
<if test="station != null" >
station,
</if>
<if test="localnum != null" >
localnum,
</if>
<if test="billetsize != null" >
billetsize,
</if>
<if test="billetnum != null" >
billetnum,
</if>
<if test="warehouse != null" >
warehouse,
</if>
<if test="keysymbol != null" >
keysymbol,
</if>
<if test="usestate != null" >
usestate,
</if>
<if test="ifdown != null" >
ifdown,
</if>
<if test="remark1 != null" >
remark1,
</if>
<if test="remark2 != null" >
remark2,
</if>
<if test="inventory != null" >
inventory,
</if>
<if test="ifpour != null" >
ifpour,
</if>
<if test="havereplace != null" >
havereplace,
</if>
<if test="faildt != null" >
faildt,
</if>
<if test="effectdt != null" >
effectdt,
</if>
<if test="pid != null" >
pid,
</if>
<if test="usuallyunit != null" >
usuallyunit,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
#{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null" >
#{materialname,jdbcType=VARCHAR},
</if>
<if test="materialmodel != null" >
#{materialmodel,jdbcType=VARCHAR},
</if>
<if test="materialproperties != null" >
#{materialproperties,jdbcType=VARCHAR},
</if>
<if test="secondaryattribute != null" >
#{secondaryattribute,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
#{unit,jdbcType=VARCHAR},
</if>
<if test="num != null" >
#{num,jdbcType=VARCHAR},
</if>
<if test="yield != null" >
#{yield,jdbcType=VARCHAR},
</if>
<if test="state != null" >
#{state,jdbcType=VARCHAR},
</if>
<if test="audit != null" >
#{audit,jdbcType=VARCHAR},
</if>
<if test="version != null" >
#{version,jdbcType=VARCHAR},
</if>
<if test="drawnum != null" >
#{drawnum,jdbcType=VARCHAR},
</if>
<if test="processlinecode != null" >
#{processlinecode,jdbcType=VARCHAR},
</if>
<if test="processlinename != null" >
#{processlinename,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="lastinsuser != null" >
#{lastinsuser,jdbcType=VARCHAR},
</if>
<if test="lastinsdt != null" >
#{lastinsdt,jdbcType=TIMESTAMP},
</if>
<if test="usepeople != null" >
#{usepeople,jdbcType=VARCHAR},
</if>
<if test="userdt != null" >
#{userdt,jdbcType=TIMESTAMP},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="jumplayer != null" >
#{jumplayer,jdbcType=VARCHAR},
</if>
<if test="levels != null" >
#{levels,jdbcType=VARCHAR},
</if>
<if test="unituse != null" >
#{unituse,jdbcType=VARCHAR},
</if>
<if test="dosage != null" >
#{dosage,jdbcType=VARCHAR},
</if>
<if test="usualuseunit != null" >
#{usualuseunit,jdbcType=VARCHAR},
</if>
<if test="plannedpercentage != null" >
#{plannedpercentage,jdbcType=VARCHAR},
</if>
<if test="wearrate != null" >
#{wearrate,jdbcType=VARCHAR},
</if>
<if test="itemtype != null" >
#{itemtype,jdbcType=VARCHAR},
</if>
<if test="operationnumber != null" >
#{operationnumber,jdbcType=VARCHAR},
</if>
<if test="process != null" >
#{process,jdbcType=VARCHAR},
</if>
<if test="station != null" >
#{station,jdbcType=VARCHAR},
</if>
<if test="localnum != null" >
#{localnum,jdbcType=VARCHAR},
</if>
<if test="billetsize != null" >
#{billetsize,jdbcType=VARCHAR},
</if>
<if test="billetnum != null" >
#{billetnum,jdbcType=VARCHAR},
</if>
<if test="warehouse != null" >
#{warehouse,jdbcType=VARCHAR},
</if>
<if test="keysymbol != null" >
#{keysymbol,jdbcType=VARCHAR},
</if>
<if test="usestate != null" >
#{usestate,jdbcType=VARCHAR},
</if>
<if test="ifdown != null" >
#{ifdown,jdbcType=VARCHAR},
</if>
<if test="remark1 != null" >
#{remark1,jdbcType=VARCHAR},
</if>
<if test="remark2 != null" >
#{remark2,jdbcType=VARCHAR},
</if>
<if test="inventory != null" >
#{inventory,jdbcType=VARCHAR},
</if>
<if test="ifpour != null" >
#{ifpour,jdbcType=VARCHAR},
</if>
<if test="havereplace != null" >
#{havereplace,jdbcType=VARCHAR},
</if>
<if test="faildt != null" >
#{faildt,jdbcType=TIMESTAMP},
</if>
<if test="effectdt != null" >
#{effectdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="usuallyunit != null" >
#{usuallyunit,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialBOM" >
update tb_material_allinfo
<set >
<if test="materialcode != null" >
materialcode = #{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null" >
materialname = #{materialname,jdbcType=VARCHAR},
</if>
<if test="materialmodel != null" >
materialmodel = #{materialmodel,jdbcType=VARCHAR},
</if>
<if test="materialproperties != null" >
materialproperties = #{materialproperties,jdbcType=VARCHAR},
</if>
<if test="secondaryattribute != null" >
secondaryattribute = #{secondaryattribute,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
unit = #{unit,jdbcType=VARCHAR},
</if>
<if test="num != null" >
num = #{num,jdbcType=VARCHAR},
</if>
<if test="yield != null" >
yield = #{yield,jdbcType=VARCHAR},
</if>
<if test="state != null" >
state = #{state,jdbcType=VARCHAR},
</if>
<if test="audit != null" >
audit = #{audit,jdbcType=VARCHAR},
</if>
<if test="version != null" >
version = #{version,jdbcType=VARCHAR},
</if>
<if test="drawnum != null" >
drawnum = #{drawnum,jdbcType=VARCHAR},
</if>
<if test="processlinecode != null" >
processlinecode = #{processlinecode,jdbcType=VARCHAR},
</if>
<if test="processlinename != null" >
processlinename = #{processlinename,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="lastinsuser != null" >
lastinsuser = #{lastinsuser,jdbcType=VARCHAR},
</if>
<if test="lastinsdt != null" >
lastinsdt = #{lastinsdt,jdbcType=TIMESTAMP},
</if>
<if test="usepeople != null" >
usepeople = #{usepeople,jdbcType=VARCHAR},
</if>
<if test="userdt != null" >
userdt = #{userdt,jdbcType=TIMESTAMP},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="jumplayer != null" >
jumplayer = #{jumplayer,jdbcType=VARCHAR},
</if>
<if test="levels != null" >
levels = #{levels,jdbcType=VARCHAR},
</if>
<if test="unituse != null" >
unituse = #{unituse,jdbcType=VARCHAR},
</if>
<if test="dosage != null" >
dosage = #{dosage,jdbcType=VARCHAR},
</if>
<if test="usualuseunit != null" >
usualuseunit = #{usualuseunit,jdbcType=VARCHAR},
</if>
<if test="plannedpercentage != null" >
plannedpercentage = #{plannedpercentage,jdbcType=VARCHAR},
</if>
<if test="wearrate != null" >
wearrate = #{wearrate,jdbcType=VARCHAR},
</if>
<if test="itemtype != null" >
itemtype = #{itemtype,jdbcType=VARCHAR},
</if>
<if test="operationnumber != null" >
operationnumber = #{operationnumber,jdbcType=VARCHAR},
</if>
<if test="process != null" >
process = #{process,jdbcType=VARCHAR},
</if>
<if test="station != null" >
station = #{station,jdbcType=VARCHAR},
</if>
<if test="localnum != null" >
localnum = #{localnum,jdbcType=VARCHAR},
</if>
<if test="billetsize != null" >
billetsize = #{billetsize,jdbcType=VARCHAR},
</if>
<if test="billetnum != null" >
billetnum = #{billetnum,jdbcType=VARCHAR},
</if>
<if test="warehouse != null" >
warehouse = #{warehouse,jdbcType=VARCHAR},
</if>
<if test="keysymbol != null" >
keysymbol = #{keysymbol,jdbcType=VARCHAR},
</if>
<if test="usestate != null" >
usestate = #{usestate,jdbcType=VARCHAR},
</if>
<if test="ifdown != null" >
ifdown = #{ifdown,jdbcType=VARCHAR},
</if>
<if test="remark1 != null" >
remark1 = #{remark1,jdbcType=VARCHAR},
</if>
<if test="remark2 != null" >
remark2 = #{remark2,jdbcType=VARCHAR},
</if>
<if test="inventory != null" >
inventory = #{inventory,jdbcType=VARCHAR},
</if>
<if test="ifpour != null" >
ifpour = #{ifpour,jdbcType=VARCHAR},
</if>
<if test="havereplace != null" >
havereplace = #{havereplace,jdbcType=VARCHAR},
</if>
<if test="faildt != null" >
faildt = #{faildt,jdbcType=TIMESTAMP},
</if>
<if test="effectdt != null" >
effectdt = #{effectdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="usuallyunit != null" >
usuallyunit = #{usuallyunit,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialBOM" >
update tb_material_allinfo
set materialcode = #{materialcode,jdbcType=VARCHAR},
materialname = #{materialname,jdbcType=VARCHAR},
materialmodel = #{materialmodel,jdbcType=VARCHAR},
materialproperties = #{materialproperties,jdbcType=VARCHAR},
secondaryattribute = #{secondaryattribute,jdbcType=VARCHAR},
unit = #{unit,jdbcType=VARCHAR},
num = #{num,jdbcType=VARCHAR},
yield = #{yield,jdbcType=VARCHAR},
state = #{state,jdbcType=VARCHAR},
audit = #{audit,jdbcType=VARCHAR},
version = #{version,jdbcType=VARCHAR},
drawnum = #{drawnum,jdbcType=VARCHAR},
processlinecode = #{processlinecode,jdbcType=VARCHAR},
processlinename = #{processlinename,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
lastinsuser = #{lastinsuser,jdbcType=VARCHAR},
lastinsdt = #{lastinsdt,jdbcType=TIMESTAMP},
usepeople = #{usepeople,jdbcType=VARCHAR},
userdt = #{userdt,jdbcType=TIMESTAMP},
remark = #{remark,jdbcType=VARCHAR},
jumplayer = #{jumplayer,jdbcType=VARCHAR},
levels = #{levels,jdbcType=VARCHAR},
unituse = #{unituse,jdbcType=VARCHAR},
dosage = #{dosage,jdbcType=VARCHAR},
usualuseunit = #{usualuseunit,jdbcType=VARCHAR},
plannedpercentage = #{plannedpercentage,jdbcType=VARCHAR},
wearrate = #{wearrate,jdbcType=VARCHAR},
itemtype = #{itemtype,jdbcType=VARCHAR},
operationnumber = #{operationnumber,jdbcType=VARCHAR},
process = #{process,jdbcType=VARCHAR},
station = #{station,jdbcType=VARCHAR},
localnum = #{localnum,jdbcType=VARCHAR},
billetsize = #{billetsize,jdbcType=VARCHAR},
billetnum = #{billetnum,jdbcType=VARCHAR},
warehouse = #{warehouse,jdbcType=VARCHAR},
keysymbol = #{keysymbol,jdbcType=VARCHAR},
usestate = #{usestate,jdbcType=VARCHAR},
ifdown = #{ifdown,jdbcType=VARCHAR},
remark1 = #{remark1,jdbcType=VARCHAR},
remark2 = #{remark2,jdbcType=VARCHAR},
inventory = #{inventory,jdbcType=VARCHAR},
ifpour = #{ifpour,jdbcType=VARCHAR},
havereplace = #{havereplace,jdbcType=VARCHAR},
faildt = #{faildt,jdbcType=TIMESTAMP},
effectdt = #{effectdt,jdbcType=TIMESTAMP},
pid = #{pid,jdbcType=VARCHAR},
usuallyunit = #{usuallyunit,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_allinfo
${where}
</select>
<select id="getListByMaterialCode" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_allinfo
where materialcode = #{materialcode,jdbcType=VARCHAR}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_allinfo
${where}
</delete>
<select id="getRootByCodeAndVersion" resultMap="BaseResultMap" parameterType="com.sipai.entity.material.MaterialBOM" >
select
<include refid="Base_Column_List" />
from tb_material_allinfo
where pid = #{pid,jdbcType=VARCHAR} and materialcode = #{materialcode,jdbcType=VARCHAR}
</select>
<select id="getRootByMaterialcode" resultMap="BaseResultMap" parameterType="com.sipai.entity.material.MaterialBOM" >
select
<include refid="Base_Column_List" />
from tb_material_allinfo
where materialcode = #{materialcode,jdbcType=VARCHAR} order by materialcode
</select>
<update id="updateByCodeSelective" parameterType="com.sipai.entity.material.MaterialBOM" >
update tb_material_allinfo
<set >
<if test="id != null" >
id = #{id,jdbcType=VARCHAR},
</if>
</set>
where materialcode = #{materialcode,jdbcType=VARCHAR}
</update>
</mapper>

View File

@ -0,0 +1,180 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.MaterialBoxMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialBox" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="boxnumber" property="boxnumber" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="workstationid" property="workstationid" jdbcType="VARCHAR" />
<result column="typeid" property="typeid" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, boxnumber, name, workstationid, typeid, status, remark, insuser, insdt, modify,
modifydt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_box
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_box
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialBox" >
insert into tb_material_box (id, boxnumber, name,
workstationid, typeid, status,
remark, insuser, insdt,
modify, modifydt)
values (#{id,jdbcType=VARCHAR}, #{boxnumber,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{workstationid,jdbcType=VARCHAR}, #{typeid,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR},
#{remark,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{modify,jdbcType=VARCHAR}, #{modifydt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialBox" >
insert into tb_material_box
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="boxnumber != null" >
boxnumber,
</if>
<if test="name != null" >
name,
</if>
<if test="workstationid != null" >
workstationid,
</if>
<if test="typeid != null" >
typeid,
</if>
<if test="status != null" >
status,
</if>
<if test="remark != null" >
remark,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="boxnumber != null" >
#{boxnumber,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
#{workstationid,jdbcType=VARCHAR},
</if>
<if test="typeid != null" >
#{typeid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialBox" >
update tb_material_box
<set >
<if test="boxnumber != null" >
boxnumber = #{boxnumber,jdbcType=VARCHAR},
</if>
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
workstationid = #{workstationid,jdbcType=VARCHAR},
</if>
<if test="typeid != null" >
typeid = #{typeid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialBox" >
update tb_material_box
set boxnumber = #{boxnumber,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
workstationid = #{workstationid,jdbcType=VARCHAR},
typeid = #{typeid,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_box
${where}
</select>
<select id="getMaterialBoxByNumber" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_box
where boxnumber = #{boxnumber,jdbcType=VARCHAR}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_box
${where}
</delete>
</mapper>

View File

@ -0,0 +1,223 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.MaterialDateScheduleMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialDateSchedule" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="inventoryFrontLine" property="inventoryfrontline" jdbcType="VARCHAR" />
<result column="pickingDay" property="pickingday" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="plannedConsumption" property="plannedconsumption" jdbcType="VARCHAR" />
<result column="inventoryCountPostpartum" property="inventorycountpostpartum" jdbcType="VARCHAR" />
<result column="actualConsumptionDay" property="actualconsumptionday" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="exceedsPlannedPercentage" property="exceedsplannedpercentage" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="unituse" property="unituse" jdbcType="VARCHAR" />
<result column="theDifferent" property="thedifferent" jdbcType="VARCHAR" />
<result column="bomprojects" property="bomprojects" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, inventoryFrontLine, pickingDay, insuser, insdt, plannedConsumption, inventoryCountPostpartum,
actualConsumptionDay, pid, exceedsPlannedPercentage, remark, materialcode, unituse,
theDifferent, bomprojects
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_dateschedule
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_dateschedule
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialDateSchedule" >
insert into tb_material_dateschedule (id, inventoryFrontLine, pickingDay,
insuser, insdt, plannedConsumption,
inventoryCountPostpartum, actualConsumptionDay,
pid, exceedsPlannedPercentage, remark,
materialcode, unituse, theDifferent,
bomprojects)
values (#{id,jdbcType=VARCHAR}, #{inventoryfrontline,jdbcType=VARCHAR}, #{pickingday,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{plannedconsumption,jdbcType=VARCHAR},
#{inventorycountpostpartum,jdbcType=VARCHAR}, #{actualconsumptionday,jdbcType=VARCHAR},
#{pid,jdbcType=VARCHAR}, #{exceedsplannedpercentage,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR},
#{materialcode,jdbcType=VARCHAR}, #{unituse,jdbcType=VARCHAR}, #{thedifferent,jdbcType=VARCHAR},
#{bomprojects,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialDateSchedule" >
insert into tb_material_dateschedule
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="inventoryfrontline != null" >
inventoryFrontLine,
</if>
<if test="pickingday != null" >
pickingDay,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="plannedconsumption != null" >
plannedConsumption,
</if>
<if test="inventorycountpostpartum != null" >
inventoryCountPostpartum,
</if>
<if test="actualconsumptionday != null" >
actualConsumptionDay,
</if>
<if test="pid != null" >
pid,
</if>
<if test="exceedsplannedpercentage != null" >
exceedsPlannedPercentage,
</if>
<if test="remark != null" >
remark,
</if>
<if test="materialcode != null" >
materialcode,
</if>
<if test="unituse != null" >
unituse,
</if>
<if test="thedifferent != null" >
theDifferent,
</if>
<if test="bomprojects != null" >
bomprojects,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="inventoryfrontline != null" >
#{inventoryfrontline,jdbcType=VARCHAR},
</if>
<if test="pickingday != null" >
#{pickingday,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plannedconsumption != null" >
#{plannedconsumption,jdbcType=VARCHAR},
</if>
<if test="inventorycountpostpartum != null" >
#{inventorycountpostpartum,jdbcType=VARCHAR},
</if>
<if test="actualconsumptionday != null" >
#{actualconsumptionday,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="exceedsplannedpercentage != null" >
#{exceedsplannedpercentage,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
#{materialcode,jdbcType=VARCHAR},
</if>
<if test="unituse != null" >
#{unituse,jdbcType=VARCHAR},
</if>
<if test="thedifferent != null" >
#{thedifferent,jdbcType=VARCHAR},
</if>
<if test="bomprojects != null" >
#{bomprojects,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialDateSchedule" >
update tb_material_dateschedule
<set >
<if test="inventoryfrontline != null" >
inventoryFrontLine = #{inventoryfrontline,jdbcType=VARCHAR},
</if>
<if test="pickingday != null" >
pickingDay = #{pickingday,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plannedconsumption != null" >
plannedConsumption = #{plannedconsumption,jdbcType=VARCHAR},
</if>
<if test="inventorycountpostpartum != null" >
inventoryCountPostpartum = #{inventorycountpostpartum,jdbcType=VARCHAR},
</if>
<if test="actualconsumptionday != null" >
actualConsumptionDay = #{actualconsumptionday,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="exceedsplannedpercentage != null" >
exceedsPlannedPercentage = #{exceedsplannedpercentage,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
materialcode = #{materialcode,jdbcType=VARCHAR},
</if>
<if test="unituse != null" >
unituse = #{unituse,jdbcType=VARCHAR},
</if>
<if test="thedifferent != null" >
theDifferent = #{thedifferent,jdbcType=VARCHAR},
</if>
<if test="bomprojects != null" >
bomprojects = #{bomprojects,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialDateSchedule" >
update tb_material_dateschedule
set inventoryFrontLine = #{inventoryfrontline,jdbcType=VARCHAR},
pickingDay = #{pickingday,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
plannedConsumption = #{plannedconsumption,jdbcType=VARCHAR},
inventoryCountPostpartum = #{inventorycountpostpartum,jdbcType=VARCHAR},
actualConsumptionDay = #{actualconsumptionday,jdbcType=VARCHAR},
pid = #{pid,jdbcType=VARCHAR},
exceedsPlannedPercentage = #{exceedsplannedpercentage,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
materialcode = #{materialcode,jdbcType=VARCHAR},
unituse = #{unituse,jdbcType=VARCHAR},
theDifferent = #{thedifferent,jdbcType=VARCHAR},
bomprojects = #{bomprojects,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_dateschedule
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_material_dateschedule
${where}
</delete>
</mapper>

View File

@ -0,0 +1,636 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.MaterialInfoMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialInfo" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="materialname" property="materialname" jdbcType="VARCHAR" />
<result column="materialmodel" property="materialmodel" jdbcType="VARCHAR" />
<result column="materialproperties" property="materialproperties" jdbcType="VARCHAR" />
<result column="secondaryattribute" property="secondaryattribute" jdbcType="VARCHAR" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="num" property="num" jdbcType="VARCHAR" />
<result column="yield" property="yield" jdbcType="VARCHAR" />
<result column="state" property="state" jdbcType="VARCHAR" />
<result column="audit" property="audit" jdbcType="VARCHAR" />
<result column="version" property="version" jdbcType="VARCHAR" />
<result column="drawnum" property="drawnum" jdbcType="VARCHAR" />
<result column="processlinecode" property="processlinecode" jdbcType="VARCHAR" />
<result column="processlinename" property="processlinename" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="lastinsuser" property="lastinsuser" jdbcType="VARCHAR" />
<result column="lastinsdt" property="lastinsdt" jdbcType="TIMESTAMP" />
<result column="usepeople" property="usepeople" jdbcType="VARCHAR" />
<result column="userdt" property="userdt" jdbcType="TIMESTAMP" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="jumplayer" property="jumplayer" jdbcType="VARCHAR" />
<result column="levels" property="levels" jdbcType="VARCHAR" />
<result column="unituse" property="unituse" jdbcType="VARCHAR" />
<result column="dosage" property="dosage" jdbcType="VARCHAR" />
<result column="usualuseunit" property="usualuseunit" jdbcType="VARCHAR" />
<result column="plannedpercentage" property="plannedpercentage" jdbcType="VARCHAR" />
<result column="wearrate" property="wearrate" jdbcType="VARCHAR" />
<result column="itemtype" property="itemtype" jdbcType="VARCHAR" />
<result column="operationnumber" property="operationnumber" jdbcType="VARCHAR" />
<result column="process" property="process" jdbcType="VARCHAR" />
<result column="station" property="station" jdbcType="VARCHAR" />
<result column="localnum" property="localnum" jdbcType="VARCHAR" />
<result column="billetsize" property="billetsize" jdbcType="VARCHAR" />
<result column="billetnum" property="billetnum" jdbcType="VARCHAR" />
<result column="warehouse" property="warehouse" jdbcType="VARCHAR" />
<result column="keysymbol" property="keysymbol" jdbcType="VARCHAR" />
<result column="usestate" property="usestate" jdbcType="VARCHAR" />
<result column="ifdown" property="ifdown" jdbcType="VARCHAR" />
<result column="remark1" property="remark1" jdbcType="VARCHAR" />
<result column="remark2" property="remark2" jdbcType="VARCHAR" />
<result column="inventory" property="inventory" jdbcType="VARCHAR" />
<result column="ifpour" property="ifpour" jdbcType="VARCHAR" />
<result column="havereplace" property="havereplace" jdbcType="VARCHAR" />
<result column="faildt" property="faildt" jdbcType="TIMESTAMP" />
<result column="effectdt" property="effectdt" jdbcType="TIMESTAMP" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="usuallyunit" property="usuallyunit" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, materialcode, materialname, materialmodel, materialproperties, secondaryattribute,
unit, num, yield, state, audit, version, drawnum, processlinecode, processlinename,
insuser, insdt, lastinsuser, lastinsdt, usepeople, userdt, remark, jumplayer, levels,
unituse, dosage, usualuseunit, plannedpercentage, wearrate, itemtype, operationnumber,
process, station, localnum, billetsize, billetnum, warehouse, keysymbol, usestate,
ifdown, remark1, remark2, inventory, ifpour, havereplace, faildt, effectdt, pid, usuallyunit
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_allinfo
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_allinfo
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialInfo" >
insert into tb_material_allinfo (id, materialcode, materialname,
materialmodel, materialproperties, secondaryattribute,
unit, num, yield, state,
audit, version, drawnum,
processlinecode, processlinename, insuser,
insdt, lastinsuser, lastinsdt,
usepeople, userdt, remark,
jumplayer, levels, unituse,
dosage, usualuseunit, plannedpercentage,
wearrate, itemtype, operationnumber,
process, station, localnum,
billetsize, billetnum, warehouse,
keysymbol, usestate, ifdown,
remark1, remark2, inventory,
ifpour, havereplace, faildt,
effectdt, pid, usuallyunit
)
values (#{id,jdbcType=VARCHAR}, #{materialcode,jdbcType=VARCHAR}, #{materialname,jdbcType=VARCHAR},
#{materialmodel,jdbcType=VARCHAR}, #{materialproperties,jdbcType=VARCHAR}, #{secondaryattribute,jdbcType=VARCHAR},
#{unit,jdbcType=VARCHAR}, #{num,jdbcType=VARCHAR}, #{yield,jdbcType=VARCHAR}, #{state,jdbcType=VARCHAR},
#{audit,jdbcType=VARCHAR}, #{version,jdbcType=VARCHAR}, #{drawnum,jdbcType=VARCHAR},
#{processlinecode,jdbcType=VARCHAR}, #{processlinename,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{lastinsuser,jdbcType=VARCHAR}, #{lastinsdt,jdbcType=TIMESTAMP},
#{usepeople,jdbcType=VARCHAR}, #{userdt,jdbcType=TIMESTAMP}, #{remark,jdbcType=VARCHAR},
#{jumplayer,jdbcType=VARCHAR}, #{levels,jdbcType=VARCHAR}, #{unituse,jdbcType=VARCHAR},
#{dosage,jdbcType=VARCHAR}, #{usualuseunit,jdbcType=VARCHAR}, #{plannedpercentage,jdbcType=VARCHAR},
#{wearrate,jdbcType=VARCHAR}, #{itemtype,jdbcType=VARCHAR}, #{operationnumber,jdbcType=VARCHAR},
#{process,jdbcType=VARCHAR}, #{station,jdbcType=VARCHAR}, #{localnum,jdbcType=VARCHAR},
#{billetsize,jdbcType=VARCHAR}, #{billetnum,jdbcType=VARCHAR}, #{warehouse,jdbcType=VARCHAR},
#{keysymbol,jdbcType=VARCHAR}, #{usestate,jdbcType=VARCHAR}, #{ifdown,jdbcType=VARCHAR},
#{remark1,jdbcType=VARCHAR}, #{remark2,jdbcType=VARCHAR}, #{inventory,jdbcType=VARCHAR},
#{ifpour,jdbcType=VARCHAR}, #{havereplace,jdbcType=VARCHAR}, #{faildt,jdbcType=TIMESTAMP},
#{effectdt,jdbcType=TIMESTAMP}, #{pid,jdbcType=VARCHAR}, #{usuallyunit,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialInfo" >
insert into tb_material_allinfo
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="materialcode != null" >
materialcode,
</if>
<if test="materialname != null" >
materialname,
</if>
<if test="materialmodel != null" >
materialmodel,
</if>
<if test="materialproperties != null" >
materialproperties,
</if>
<if test="secondaryattribute != null" >
secondaryattribute,
</if>
<if test="unit != null" >
unit,
</if>
<if test="num != null" >
num,
</if>
<if test="yield != null" >
yield,
</if>
<if test="state != null" >
state,
</if>
<if test="audit != null" >
audit,
</if>
<if test="version != null" >
version,
</if>
<if test="drawnum != null" >
drawnum,
</if>
<if test="processlinecode != null" >
processlinecode,
</if>
<if test="processlinename != null" >
processlinename,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="lastinsuser != null" >
lastinsuser,
</if>
<if test="lastinsdt != null" >
lastinsdt,
</if>
<if test="usepeople != null" >
usepeople,
</if>
<if test="userdt != null" >
userdt,
</if>
<if test="remark != null" >
remark,
</if>
<if test="jumplayer != null" >
jumplayer,
</if>
<if test="levels != null" >
levels,
</if>
<if test="unituse != null" >
unituse,
</if>
<if test="dosage != null" >
dosage,
</if>
<if test="usualuseunit != null" >
usualuseunit,
</if>
<if test="plannedpercentage != null" >
plannedpercentage,
</if>
<if test="wearrate != null" >
wearrate,
</if>
<if test="itemtype != null" >
itemtype,
</if>
<if test="operationnumber != null" >
operationnumber,
</if>
<if test="process != null" >
process,
</if>
<if test="station != null" >
station,
</if>
<if test="localnum != null" >
localnum,
</if>
<if test="billetsize != null" >
billetsize,
</if>
<if test="billetnum != null" >
billetnum,
</if>
<if test="warehouse != null" >
warehouse,
</if>
<if test="keysymbol != null" >
keysymbol,
</if>
<if test="usestate != null" >
usestate,
</if>
<if test="ifdown != null" >
ifdown,
</if>
<if test="remark1 != null" >
remark1,
</if>
<if test="remark2 != null" >
remark2,
</if>
<if test="inventory != null" >
inventory,
</if>
<if test="ifpour != null" >
ifpour,
</if>
<if test="havereplace != null" >
havereplace,
</if>
<if test="faildt != null" >
faildt,
</if>
<if test="effectdt != null" >
effectdt,
</if>
<if test="pid != null" >
pid,
</if>
<if test="usuallyunit != null" >
usuallyunit,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
#{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null" >
#{materialname,jdbcType=VARCHAR},
</if>
<if test="materialmodel != null" >
#{materialmodel,jdbcType=VARCHAR},
</if>
<if test="materialproperties != null" >
#{materialproperties,jdbcType=VARCHAR},
</if>
<if test="secondaryattribute != null" >
#{secondaryattribute,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
#{unit,jdbcType=VARCHAR},
</if>
<if test="num != null" >
#{num,jdbcType=VARCHAR},
</if>
<if test="yield != null" >
#{yield,jdbcType=VARCHAR},
</if>
<if test="state != null" >
#{state,jdbcType=VARCHAR},
</if>
<if test="audit != null" >
#{audit,jdbcType=VARCHAR},
</if>
<if test="version != null" >
#{version,jdbcType=VARCHAR},
</if>
<if test="drawnum != null" >
#{drawnum,jdbcType=VARCHAR},
</if>
<if test="processlinecode != null" >
#{processlinecode,jdbcType=VARCHAR},
</if>
<if test="processlinename != null" >
#{processlinename,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="lastinsuser != null" >
#{lastinsuser,jdbcType=VARCHAR},
</if>
<if test="lastinsdt != null" >
#{lastinsdt,jdbcType=TIMESTAMP},
</if>
<if test="usepeople != null" >
#{usepeople,jdbcType=VARCHAR},
</if>
<if test="userdt != null" >
#{userdt,jdbcType=TIMESTAMP},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="jumplayer != null" >
#{jumplayer,jdbcType=VARCHAR},
</if>
<if test="levels != null" >
#{levels,jdbcType=VARCHAR},
</if>
<if test="unituse != null" >
#{unituse,jdbcType=VARCHAR},
</if>
<if test="dosage != null" >
#{dosage,jdbcType=VARCHAR},
</if>
<if test="usualuseunit != null" >
#{usualuseunit,jdbcType=VARCHAR},
</if>
<if test="plannedpercentage != null" >
#{plannedpercentage,jdbcType=VARCHAR},
</if>
<if test="wearrate != null" >
#{wearrate,jdbcType=VARCHAR},
</if>
<if test="itemtype != null" >
#{itemtype,jdbcType=VARCHAR},
</if>
<if test="operationnumber != null" >
#{operationnumber,jdbcType=VARCHAR},
</if>
<if test="process != null" >
#{process,jdbcType=VARCHAR},
</if>
<if test="station != null" >
#{station,jdbcType=VARCHAR},
</if>
<if test="localnum != null" >
#{localnum,jdbcType=VARCHAR},
</if>
<if test="billetsize != null" >
#{billetsize,jdbcType=VARCHAR},
</if>
<if test="billetnum != null" >
#{billetnum,jdbcType=VARCHAR},
</if>
<if test="warehouse != null" >
#{warehouse,jdbcType=VARCHAR},
</if>
<if test="keysymbol != null" >
#{keysymbol,jdbcType=VARCHAR},
</if>
<if test="usestate != null" >
#{usestate,jdbcType=VARCHAR},
</if>
<if test="ifdown != null" >
#{ifdown,jdbcType=VARCHAR},
</if>
<if test="remark1 != null" >
#{remark1,jdbcType=VARCHAR},
</if>
<if test="remark2 != null" >
#{remark2,jdbcType=VARCHAR},
</if>
<if test="inventory != null" >
#{inventory,jdbcType=VARCHAR},
</if>
<if test="ifpour != null" >
#{ifpour,jdbcType=VARCHAR},
</if>
<if test="havereplace != null" >
#{havereplace,jdbcType=VARCHAR},
</if>
<if test="faildt != null" >
#{faildt,jdbcType=TIMESTAMP},
</if>
<if test="effectdt != null" >
#{effectdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="usuallyunit != null" >
#{usuallyunit,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialInfo" >
update tb_material_allinfo
<set >
<if test="materialcode != null" >
materialcode = #{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null" >
materialname = #{materialname,jdbcType=VARCHAR},
</if>
<if test="materialmodel != null" >
materialmodel = #{materialmodel,jdbcType=VARCHAR},
</if>
<if test="materialproperties != null" >
materialproperties = #{materialproperties,jdbcType=VARCHAR},
</if>
<if test="secondaryattribute != null" >
secondaryattribute = #{secondaryattribute,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
unit = #{unit,jdbcType=VARCHAR},
</if>
<if test="num != null" >
num = #{num,jdbcType=VARCHAR},
</if>
<if test="yield != null" >
yield = #{yield,jdbcType=VARCHAR},
</if>
<if test="state != null" >
state = #{state,jdbcType=VARCHAR},
</if>
<if test="audit != null" >
audit = #{audit,jdbcType=VARCHAR},
</if>
<if test="version != null" >
version = #{version,jdbcType=VARCHAR},
</if>
<if test="drawnum != null" >
drawnum = #{drawnum,jdbcType=VARCHAR},
</if>
<if test="processlinecode != null" >
processlinecode = #{processlinecode,jdbcType=VARCHAR},
</if>
<if test="processlinename != null" >
processlinename = #{processlinename,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="lastinsuser != null" >
lastinsuser = #{lastinsuser,jdbcType=VARCHAR},
</if>
<if test="lastinsdt != null" >
lastinsdt = #{lastinsdt,jdbcType=TIMESTAMP},
</if>
<if test="usepeople != null" >
usepeople = #{usepeople,jdbcType=VARCHAR},
</if>
<if test="userdt != null" >
userdt = #{userdt,jdbcType=TIMESTAMP},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="jumplayer != null" >
jumplayer = #{jumplayer,jdbcType=VARCHAR},
</if>
<if test="levels != null" >
levels = #{levels,jdbcType=VARCHAR},
</if>
<if test="unituse != null" >
unituse = #{unituse,jdbcType=VARCHAR},
</if>
<if test="dosage != null" >
dosage = #{dosage,jdbcType=VARCHAR},
</if>
<if test="usualuseunit != null" >
usualuseunit = #{usualuseunit,jdbcType=VARCHAR},
</if>
<if test="plannedpercentage != null" >
plannedpercentage = #{plannedpercentage,jdbcType=VARCHAR},
</if>
<if test="wearrate != null" >
wearrate = #{wearrate,jdbcType=VARCHAR},
</if>
<if test="itemtype != null" >
itemtype = #{itemtype,jdbcType=VARCHAR},
</if>
<if test="operationnumber != null" >
operationnumber = #{operationnumber,jdbcType=VARCHAR},
</if>
<if test="process != null" >
process = #{process,jdbcType=VARCHAR},
</if>
<if test="station != null" >
station = #{station,jdbcType=VARCHAR},
</if>
<if test="localnum != null" >
localnum = #{localnum,jdbcType=VARCHAR},
</if>
<if test="billetsize != null" >
billetsize = #{billetsize,jdbcType=VARCHAR},
</if>
<if test="billetnum != null" >
billetnum = #{billetnum,jdbcType=VARCHAR},
</if>
<if test="warehouse != null" >
warehouse = #{warehouse,jdbcType=VARCHAR},
</if>
<if test="keysymbol != null" >
keysymbol = #{keysymbol,jdbcType=VARCHAR},
</if>
<if test="usestate != null" >
usestate = #{usestate,jdbcType=VARCHAR},
</if>
<if test="ifdown != null" >
ifdown = #{ifdown,jdbcType=VARCHAR},
</if>
<if test="remark1 != null" >
remark1 = #{remark1,jdbcType=VARCHAR},
</if>
<if test="remark2 != null" >
remark2 = #{remark2,jdbcType=VARCHAR},
</if>
<if test="inventory != null" >
inventory = #{inventory,jdbcType=VARCHAR},
</if>
<if test="ifpour != null" >
ifpour = #{ifpour,jdbcType=VARCHAR},
</if>
<if test="havereplace != null" >
havereplace = #{havereplace,jdbcType=VARCHAR},
</if>
<if test="faildt != null" >
faildt = #{faildt,jdbcType=TIMESTAMP},
</if>
<if test="effectdt != null" >
effectdt = #{effectdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="usuallyunit != null" >
usuallyunit = #{usuallyunit,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialInfo" >
update tb_material_allinfo
set materialcode = #{materialcode,jdbcType=VARCHAR},
materialname = #{materialname,jdbcType=VARCHAR},
materialmodel = #{materialmodel,jdbcType=VARCHAR},
materialproperties = #{materialproperties,jdbcType=VARCHAR},
secondaryattribute = #{secondaryattribute,jdbcType=VARCHAR},
unit = #{unit,jdbcType=VARCHAR},
num = #{num,jdbcType=VARCHAR},
yield = #{yield,jdbcType=VARCHAR},
state = #{state,jdbcType=VARCHAR},
audit = #{audit,jdbcType=VARCHAR},
version = #{version,jdbcType=VARCHAR},
drawnum = #{drawnum,jdbcType=VARCHAR},
processlinecode = #{processlinecode,jdbcType=VARCHAR},
processlinename = #{processlinename,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
lastinsuser = #{lastinsuser,jdbcType=VARCHAR},
lastinsdt = #{lastinsdt,jdbcType=TIMESTAMP},
usepeople = #{usepeople,jdbcType=VARCHAR},
userdt = #{userdt,jdbcType=TIMESTAMP},
remark = #{remark,jdbcType=VARCHAR},
jumplayer = #{jumplayer,jdbcType=VARCHAR},
levels = #{levels,jdbcType=VARCHAR},
unituse = #{unituse,jdbcType=VARCHAR},
dosage = #{dosage,jdbcType=VARCHAR},
usualuseunit = #{usualuseunit,jdbcType=VARCHAR},
plannedpercentage = #{plannedpercentage,jdbcType=VARCHAR},
wearrate = #{wearrate,jdbcType=VARCHAR},
itemtype = #{itemtype,jdbcType=VARCHAR},
operationnumber = #{operationnumber,jdbcType=VARCHAR},
process = #{process,jdbcType=VARCHAR},
station = #{station,jdbcType=VARCHAR},
localnum = #{localnum,jdbcType=VARCHAR},
billetsize = #{billetsize,jdbcType=VARCHAR},
billetnum = #{billetnum,jdbcType=VARCHAR},
warehouse = #{warehouse,jdbcType=VARCHAR},
keysymbol = #{keysymbol,jdbcType=VARCHAR},
usestate = #{usestate,jdbcType=VARCHAR},
ifdown = #{ifdown,jdbcType=VARCHAR},
remark1 = #{remark1,jdbcType=VARCHAR},
remark2 = #{remark2,jdbcType=VARCHAR},
inventory = #{inventory,jdbcType=VARCHAR},
ifpour = #{ifpour,jdbcType=VARCHAR},
havereplace = #{havereplace,jdbcType=VARCHAR},
faildt = #{faildt,jdbcType=TIMESTAMP},
effectdt = #{effectdt,jdbcType=TIMESTAMP},
pid = #{pid,jdbcType=VARCHAR},
usuallyunit = #{usuallyunit,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_allinfo
${where}
</select>
<select id="getListByMaterialCode" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_allinfo
where materialcode = #{materialcode,jdbcType=VARCHAR}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_allinfo
${where}
</delete>
<select id="getRootByCodeAndVersion" resultMap="BaseResultMap" parameterType="com.sipai.entity.material.MaterialInfo" >
select
<include refid="Base_Column_List" />
from tb_material_allinfo
where pid = #{pid,jdbcType=VARCHAR} and materialcode = #{materialcode,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,301 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="material.MaterialInventoryMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialInventory">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="processid" jdbcType="VARCHAR" property="processid" />
<result column="materialid" jdbcType="VARCHAR" property="materialid" />
<result column="inventoryFrontLine" jdbcType="VARCHAR" property="inventoryfrontline" />
<result column="pickingDay" jdbcType="VARCHAR" property="pickingday" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="plannedConsumption" jdbcType="VARCHAR" property="plannedconsumption" />
<result column="inventoryCountPostpartum" jdbcType="VARCHAR" property="inventorycountpostpartum" />
<result column="actualConsumptionDay" jdbcType="VARCHAR" property="actualconsumptionday" />
<result column="exceedsPlannedPercentage" jdbcType="VARCHAR" property="exceedsplannedpercentage" />
<result column="theDifferent" jdbcType="VARCHAR" property="thedifferent" />
<result column="materialname" jdbcType="VARCHAR" property="materialname" />
<result column="thismatercodeplan" jdbcType="VARCHAR" property="thismatercodeplan" />
</resultMap>
<sql id="Base_Column_List">
id, processid, materialid, inventoryFrontLine, pickingDay, insuser, insdt, plannedConsumption,
inventoryCountPostpartum, actualConsumptionDay, exceedsPlannedPercentage, theDifferent,
materialname,thismatercodeplan
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_inventory
where id = #{id,jdbcType=VARCHAR} order by id
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_material_inventory
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialInventory">
insert into tb_material_inventory (id, processid, materialid,
inventoryFrontLine, pickingDay, insuser,
insdt, plannedConsumption, inventoryCountPostpartum,
actualConsumptionDay, exceedsPlannedPercentage,
theDifferent, materialname,thismatercodeplan)
values (#{id,jdbcType=VARCHAR}, #{processid,jdbcType=VARCHAR}, #{materialid,jdbcType=VARCHAR},
#{inventoryfrontline,jdbcType=VARCHAR}, #{pickingday,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{plannedconsumption,jdbcType=VARCHAR}, #{inventorycountpostpartum,jdbcType=VARCHAR},
#{actualconsumptionday,jdbcType=VARCHAR}, #{exceedsplannedpercentage,jdbcType=VARCHAR},
#{thedifferent,jdbcType=VARCHAR}, #{materialname,jdbcType=VARCHAR},#{thismatercodeplan,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialInventory">
insert into tb_material_inventory
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="processid != null">
processid,
</if>
<if test="materialid != null">
materialid,
</if>
<if test="inventoryfrontline != null">
inventoryFrontLine,
</if>
<if test="pickingday != null">
pickingDay,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="plannedconsumption != null">
plannedConsumption,
</if>
<if test="inventorycountpostpartum != null">
inventoryCountPostpartum,
</if>
<if test="actualconsumptionday != null">
actualConsumptionDay,
</if>
<if test="exceedsplannedpercentage != null">
exceedsPlannedPercentage,
</if>
<if test="thedifferent != null">
theDifferent,
</if>
<if test="materialname != null">
materialname,
</if>
<if test="thismatercodeplan != null">
thismatercodeplan,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="processid != null">
#{processid,jdbcType=VARCHAR},
</if>
<if test="materialid != null">
#{materialid,jdbcType=VARCHAR},
</if>
<if test="inventoryfrontline != null">
#{inventoryfrontline,jdbcType=VARCHAR},
</if>
<if test="pickingday != null">
#{pickingday,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plannedconsumption != null">
#{plannedconsumption,jdbcType=VARCHAR},
</if>
<if test="inventorycountpostpartum != null">
#{inventorycountpostpartum,jdbcType=VARCHAR},
</if>
<if test="actualconsumptionday != null">
#{actualconsumptionday,jdbcType=VARCHAR},
</if>
<if test="exceedsplannedpercentage != null">
#{exceedsplannedpercentage,jdbcType=VARCHAR},
</if>
<if test="thedifferent != null">
#{thedifferent,jdbcType=VARCHAR},
</if>
<if test="materialname != null">
#{materialname,jdbcType=VARCHAR},
</if>
<if test="thismatercodeplan != null">
#{thismatercodeplan,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialInventory">
update tb_material_inventory
<set>
<if test="processid != null">
processid = #{processid,jdbcType=VARCHAR},
</if>
<if test="materialid != null">
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="inventoryfrontline != null">
inventoryFrontLine = #{inventoryfrontline,jdbcType=VARCHAR},
</if>
<if test="pickingday != null">
pickingDay = #{pickingday,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plannedconsumption != null">
plannedConsumption = #{plannedconsumption,jdbcType=VARCHAR},
</if>
<if test="inventorycountpostpartum != null">
inventoryCountPostpartum = #{inventorycountpostpartum,jdbcType=VARCHAR},
</if>
<if test="actualconsumptionday != null">
actualConsumptionDay = #{actualconsumptionday,jdbcType=VARCHAR},
</if>
<if test="exceedsplannedpercentage != null">
exceedsPlannedPercentage = #{exceedsplannedpercentage,jdbcType=VARCHAR},
</if>
<if test="thedifferent != null">
theDifferent = #{thedifferent,jdbcType=VARCHAR},
</if>
<if test="materialname != null">
materialname = #{materialname,jdbcType=VARCHAR},
</if>
<if test="thismatercodeplan != null">
thismatercodeplan = #{thismatercodeplan,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialInventory">
update tb_material_inventory
set processid = #{processid,jdbcType=VARCHAR},
materialid = #{materialid,jdbcType=VARCHAR},
inventoryFrontLine = #{inventoryfrontline,jdbcType=VARCHAR},
pickingDay = #{pickingday,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
plannedConsumption = #{plannedconsumption,jdbcType=VARCHAR},
inventoryCountPostpartum = #{inventorycountpostpartum,jdbcType=VARCHAR},
actualConsumptionDay = #{actualconsumptionday,jdbcType=VARCHAR},
exceedsPlannedPercentage = #{exceedsplannedpercentage,jdbcType=VARCHAR},
theDifferent = #{thedifferent,jdbcType=VARCHAR},
materialname = #{materialname,jdbcType=VARCHAR},
thismatercodeplan = #{thismatercodeplan,jdbcType=VARCHAR},
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_inventory
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_material_inventory
${where}
</delete>
<select id="getMaterialInventory" parameterType="java.lang.String" resultMap="ClassResultMapMaterialInventory">
SELECT
E.id as id,
E.processid,
E.inventoryFrontLine,
E.pickingDay,
E.plannedConsumption,
E.inventoryCountPostpartum,
E.actualConsumptionDay,
E.exceedsPlannedPercentage,
E.theDifferent,
E.thismatercodeplan,
G.materialname,
E.insdt as insdt,
E.materialid as materialid,
C.procedurename as processname,
G.materialcode as materialcode,
G.unit as unit
FROM tb_material_inventory E
LEFT OUTER JOIN tb_process_task_procedure C ON C.id = E.processid
LEFT OUTER JOIN tb_material_allinfo G ON G.id = E.materialid
${where}
</select>
<resultMap id="ClassResultMapMaterialInventory" type="com.sipai.entity.material.MaterialInventory">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="processid" jdbcType="VARCHAR" property="processid" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="materialid" jdbcType="VARCHAR" property="materialid" />
<result column="inventoryFrontLine" jdbcType="VARCHAR" property="inventoryfrontline" />
<result column="pickingDay" jdbcType="VARCHAR" property="pickingday" />
<result column="plannedConsumption" jdbcType="VARCHAR" property="plannedconsumption" />
<result column="inventoryCountPostpartum" jdbcType="VARCHAR" property="inventorycountpostpartum" />
<result column="actualConsumptionDay" jdbcType="VARCHAR" property="actualconsumptionday" />
<result column="exceedsPlannedPercentage" jdbcType="VARCHAR" property="exceedsplannedpercentage" />
<result column="theDifferent" jdbcType="VARCHAR" property="thedifferent" />
<result column="processname" jdbcType="VARCHAR" property="processname" />
<result column="materialname" jdbcType="VARCHAR" property="materialname" />
<result column="thismatercodeplan" jdbcType="VARCHAR" property="thismatercodeplan" />
<result column="materialcode" jdbcType="VARCHAR" property="materialcode" />
<result column="unit" jdbcType="VARCHAR" property="unit" />
</resultMap>
<select id="getpreamount" parameterType="java.lang.String" resultMap="ClassResultMapgetpreamount">
SELECT
E.id as id,
E.procedurecode as procedurecode,
C.preamount as preamount,
G.stdt as stdt,
G.bomid as bomid
FROM tb_process_task_procedure E
LEFT OUTER JOIN tb_plan_taskdemand C ON C.taskcode = E.procedurecode
LEFT OUTER JOIN tb_plan_day G ON G.id = C.planid
${where}
</select>
<resultMap id="ClassResultMapgetpreamount" type="com.sipai.entity.material.MaterialInventory">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="procedurecode" jdbcType="VARCHAR" property="procedurecode" />
<result column="stdt" jdbcType="TIMESTAMP" property="stdt" />
<result column="preamount" jdbcType="VARCHAR" property="preamount" />
<result column="bomid" jdbcType="VARCHAR" property="bomid" />
</resultMap>
<select id="getfutureinfo" parameterType="java.lang.String" resultMap="ClassResultMapgetfutureinfo">
SELECT
t.id id,
p.procedurecode,
t.preamount,
c.stdt,
c.bomid,
I.materialid,
I.thedifferent,
I.inventoryfrontline,
I.thismatercodeplan
FROM [PlantEngine_RLD].[dbo].[tb_material_inventory] I
LEFT OUTER JOIN [PlantEngine_RLD].[dbo].[tb_process_task_procedure] p ON p.id = I.processid
LEFT OUTER JOIN [PlantEngine_RLD].[dbo].[tb_plan_taskdemand] t ON t.taskcode = p.procedurecode
LEFT OUTER JOIN [PlantEngine_RLD].[dbo].[tb_plan_day] C ON C.id = t.planid
${where}
</select>
<resultMap id="ClassResultMapgetfutureinfo" type="com.sipai.entity.material.MaterialInventory">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="procedurecode" jdbcType="VARCHAR" property="procedurecode" />
<result column="stdt" jdbcType="TIMESTAMP" property="stdt" />
<result column="preamount" jdbcType="VARCHAR" property="preamount" />
<result column="bomid" jdbcType="VARCHAR" property="bomid" />
<result column="materialid" jdbcType="VARCHAR" property="materialid" />
<result column="inventoryFrontLine" jdbcType="VARCHAR" property="inventoryfrontline" />
<result column="theDifferent" jdbcType="VARCHAR" property="thedifferent" />
<result column="thismatercodeplan" jdbcType="VARCHAR" property="thismatercodeplan" />
</resultMap>
</mapper>

View File

@ -0,0 +1,138 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="material.MaterialOverneckMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialOverneck">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="materialcode" jdbcType="VARCHAR" property="materialcode" />
<result column="materialname" jdbcType="VARCHAR" property="materialname" />
<result column="num" jdbcType="VARCHAR" property="num" />
<result column="picktime" jdbcType="TIMESTAMP" property="picktime" />
<result column="unit" jdbcType="VARCHAR" property="unit" />
</resultMap>
<sql id="Base_Column_List">
id, insuser, insdt, materialcode, materialname, num, picktime, unit
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_overneck
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_material_overneck
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialOverneck">
insert into tb_material_overneck (id, insuser, insdt,
materialcode, materialname, num,
picktime, unit)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{materialcode,jdbcType=VARCHAR}, #{materialname,jdbcType=VARCHAR}, #{num,jdbcType=VARCHAR},
#{picktime,jdbcType=TIMESTAMP}, #{unit,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialOverneck">
insert into tb_material_overneck
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="materialcode != null">
materialcode,
</if>
<if test="materialname != null">
materialname,
</if>
<if test="num != null">
num,
</if>
<if test="picktime != null">
picktime,
</if>
<if test="unit != null">
unit,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="materialcode != null">
#{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null">
#{materialname,jdbcType=VARCHAR},
</if>
<if test="num != null">
#{num,jdbcType=VARCHAR},
</if>
<if test="picktime != null">
#{picktime,jdbcType=TIMESTAMP},
</if>
<if test="unit != null">
#{unit,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialOverneck">
update tb_material_overneck
<set>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="materialcode != null">
materialcode = #{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null">
materialname = #{materialname,jdbcType=VARCHAR},
</if>
<if test="num != null">
num = #{num,jdbcType=VARCHAR},
</if>
<if test="picktime != null">
picktime = #{picktime,jdbcType=TIMESTAMP},
</if>
<if test="unit != null">
unit = #{unit,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialOverneck">
update tb_material_overneck
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
materialcode = #{materialcode,jdbcType=VARCHAR},
materialname = #{materialname,jdbcType=VARCHAR},
num = #{num,jdbcType=VARCHAR},
picktime = #{picktime,jdbcType=TIMESTAMP},
unit = #{unit,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_overneck
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_material_overneck
${where}
</delete>
</mapper>

View File

@ -0,0 +1,170 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="material.MaterialPidMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialPid">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="pid" jdbcType="VARCHAR" property="pid" />
<result column="materialcode" jdbcType="VARCHAR" property="materialcode" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="num" jdbcType="VARCHAR" property="num" />
<result column="yield" jdbcType="VARCHAR" property="yield" />
<result column="unit" jdbcType="VARCHAR" property="unit" />
<result column="unituse" jdbcType="VARCHAR" property="unituse" />
<result column="dosage" jdbcType="VARCHAR" property="dosage" />
</resultMap>
<sql id="Base_Column_List">
id, pid, materialcode, insuser, insdt, num, yield, unit, unituse, dosage
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_pid
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_material_pid
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialPid">
insert into tb_material_pid (id, pid, materialcode,
insuser, insdt, num,
yield, unit, unituse,
dosage)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{materialcode,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{num,jdbcType=VARCHAR},
#{yield,jdbcType=VARCHAR}, #{unit,jdbcType=VARCHAR}, #{unituse,jdbcType=VARCHAR},
#{dosage,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialPid">
insert into tb_material_pid
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="pid != null">
pid,
</if>
<if test="materialcode != null">
materialcode,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="num != null">
num,
</if>
<if test="yield != null">
yield,
</if>
<if test="unit != null">
unit,
</if>
<if test="unituse != null">
unituse,
</if>
<if test="dosage != null">
dosage,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="pid != null">
#{pid,jdbcType=VARCHAR},
</if>
<if test="materialcode != null">
#{materialcode,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="num != null">
#{num,jdbcType=VARCHAR},
</if>
<if test="yield != null">
#{yield,jdbcType=VARCHAR},
</if>
<if test="unit != null">
#{unit,jdbcType=VARCHAR},
</if>
<if test="unituse != null">
#{unituse,jdbcType=VARCHAR},
</if>
<if test="dosage != null">
#{dosage,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialPid">
update tb_material_pid
<set>
<if test="pid != null">
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="materialcode != null">
materialcode = #{materialcode,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="num != null">
num = #{num,jdbcType=VARCHAR},
</if>
<if test="yield != null">
yield = #{yield,jdbcType=VARCHAR},
</if>
<if test="unit != null">
unit = #{unit,jdbcType=VARCHAR},
</if>
<if test="unituse != null">
unituse = #{unituse,jdbcType=VARCHAR},
</if>
<if test="dosage != null">
dosage = #{dosage,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialPid">
update tb_material_pid
set pid = #{pid,jdbcType=VARCHAR},
materialcode = #{materialcode,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
num = #{num,jdbcType=VARCHAR},
yield = #{yield,jdbcType=VARCHAR},
unit = #{unit,jdbcType=VARCHAR},
unituse = #{unituse,jdbcType=VARCHAR},
dosage = #{dosage,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_pid
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_material_pid
${where}
</delete>
<select id="getRootByCodeAndVersion" parameterType="com.sipai.entity.material.MaterialPid" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_material_pid
where pid = #{pid,jdbcType=VARCHAR} and materialcode = #{materialcode,jdbcType=VARCHAR}
</select>
</mapper>

View File

@ -0,0 +1,326 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.MaterialRequisitionMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialRequisition" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="applyuserid" property="applyuserid" jdbcType="VARCHAR" />
<result column="workstationid" property="workstationid" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="quantity" property="quantity" jdbcType="VARCHAR" />
<result column="requestsenddate" property="requestsenddate" jdbcType="TIMESTAMP" />
<result column="orderno" property="orderno" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="VARCHAR" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<result column="workshopid" property="workshopid" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="deliverquantity" property="deliverquantity" jdbcType="VARCHAR" />
<result column="deliverman" property="deliverman" jdbcType="VARCHAR" />
<result column="deliverdate" property="deliverdate" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, applyuserid, workstationid, materialid, quantity, requestsenddate, orderno, insuser,
insdt, modify, modifydt, workshopid,status,deliverquantity,deliverman,deliverdate
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_MaterialRequisition
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="getListByOrderno" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_MaterialRequisition
where orderno = #{orderno,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_material_MaterialRequisition
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialRequisition" >
insert into TB_material_MaterialRequisition (id, applyuserid, workstationid,
materialid, quantity, requestsenddate,
orderno, insuser, insdt,
modify, modifydt, workshopid,status,deliverquantity,deliverman,deliverdate
)
values (#{id,jdbcType=VARCHAR}, #{applyuserid,jdbcType=VARCHAR}, #{workstationid,jdbcType=VARCHAR},
#{materialid,jdbcType=VARCHAR}, #{quantity,jdbcType=VARCHAR}, #{requestsenddate,jdbcType=TIMESTAMP},
#{orderno,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=VARCHAR},
#{modify,jdbcType=VARCHAR}, #{modifydt,jdbcType=TIMESTAMP}, #{workshopid,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR},#{deliverquantity,jdbcType=VARCHAR},#{deliverman,jdbcType=VARCHAR},#{deliverdate,jdbcType=TIMESTAMP}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialRequisition" >
insert into TB_material_MaterialRequisition
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="applyuserid != null" >
applyuserid,
</if>
<if test="workstationid != null" >
workstationid,
</if>
<if test="materialid != null" >
materialid,
</if>
<if test="quantity != null" >
quantity,
</if>
<if test="requestsenddate != null" >
requestsenddate,
</if>
<if test="orderno != null" >
orderno,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
<if test="workshopid != null" >
workshopid,
</if>
<if test="status != null" >
status,
</if>
<if test="deliverquantity != null" >
deliverquantity,
</if>
<if test="deliverman != null" >
deliverman,
</if>
<if test="deliverdate != null" >
deliverdate,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="applyuserid != null" >
#{applyuserid,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
#{workstationid,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
#{materialid,jdbcType=VARCHAR},
</if>
<if test="quantity != null" >
#{quantity,jdbcType=VARCHAR},
</if>
<if test="requestsenddate != null" >
#{requestsenddate,jdbcType=TIMESTAMP},
</if>
<if test="orderno != null" >
#{orderno,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=VARCHAR},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
<if test="workshopid != null" >
#{workshopid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="deliverquantity != null" >
#{deliverquantity,jdbcType=VARCHAR},
</if>
<if test="deliverman != null" >
#{deliverman,jdbcType=VARCHAR},
</if>
<if test="deliverdate != null" >
#{deliverdate,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialRequisition" >
update TB_material_MaterialRequisition
<set >
<if test="applyuserid != null" >
applyuserid = #{applyuserid,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
workstationid = #{workstationid,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="quantity != null" >
quantity = #{quantity,jdbcType=VARCHAR},
</if>
<if test="requestsenddate != null" >
requestsenddate = #{requestsenddate,jdbcType=TIMESTAMP},
</if>
<if test="orderno != null" >
orderno = #{orderno,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=VARCHAR},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
<if test="workshopid != null" >
workshopid = #{workshopid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="deliverquantity != null" >
deliverquantity = #{deliverquantity,jdbcType=VARCHAR},
</if>
<if test="deliverman != null" >
deliverman = #{deliverman,jdbcType=VARCHAR},
</if>
<if test="deliverdate != null" >
deliverdate = #{deliverdate,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialRequisition" >
update TB_material_MaterialRequisition
set applyuserid = #{applyuserid,jdbcType=VARCHAR},
workstationid = #{workstationid,jdbcType=VARCHAR},
materialid = #{materialid,jdbcType=VARCHAR},
quantity = #{quantity,jdbcType=VARCHAR},
requestsenddate = #{requestsenddate,jdbcType=TIMESTAMP},
orderno = #{orderno,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=VARCHAR},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP},
workshopid = #{workshopid,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
deliverquantity = #{deliverquantity,jdbcType=VARCHAR},
deliverman = #{deliverman,jdbcType=VARCHAR},
deliverdate = #{deliverfate,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectList" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_MaterialRequisition
order by insdt desc
</select>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_MaterialRequisition
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_MaterialRequisition
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_material_MaterialRequisition
${where}
</delete>
<select id="getMaterialRequisitionList" resultMap="ClassResultMapMRlist" parameterType="java.lang.String">
SELECT
R.id as r_id,
R.applyuserid,
R.workstationid as r_workstationid,
R.materialid as r_materialid,
R.quantity as r_quantity,
R.requestsenddate,
R.orderno as r_orderno,
R.insuser as r_insuser,
R.insdt as r_insdt,
R.modify as r_modify,
R.modifydt as r_modifydt,
R.workshopid as r_workshopid,
R.status as r_status,
R.deliverquantity as r_deliverquantity,
R.deliverman as r_deliverman,
R.deliverdate as r_deliverdate,
I.id as i_id,
I.materialname,
I.materialcode,
I.spec,
I.unit,
U.id as u_id,
U.caption as u_username,
U.name as u_name,
W.id as w_id,
W.serial,
W.name as w_name,
L.name as l_name,
T.name as t_name
FROM TB_material_MaterialRequisition R
LEFT OUTER JOIN tb_material_info I ON I.id = R.materialid
LEFT OUTER JOIN tb_user U ON U.id = R.applyuserid
LEFT OUTER JOIN tb_work_workstation W ON W.id = R.workstationid
LEFT OUTER JOIN tb_work_line L ON L.id = W.lineid
LEFT OUTER JOIN uv_unit T ON T.id = L.deptid
${where}
</select>
<resultMap id="ClassResultMapMRlist" type="com.sipai.entity.material.MaterialRequisition">
<id property="id" column="r_id" />
<result property="insuser" column="r_insuser"/>
<result property="insdt" column="r_insdt"/>
<result property="applyuserid" column="applyuserid"/>
<result property="workstationid" column="r_workstationid"/>
<result property="materialid" column="r_materialid"/>
<result property="quantity" column="r_quantity"/>
<result property="requestsenddate" column="requestsenddate"/>
<result property="orderno" column="r_orderno"/>
<result property="modify" column="r_modify"/>
<result property="modifydt" column="r_modifydt"/>
<result property="workshopid" column="r_workshopid"/>
<result property="status" column="r_status"/>
<result property="deliverquantity" column="r_deliverquantity"/>
<result property="deliverman" column="r_deliverman"/>
<result property="deliverdate" column="r_deliverdate"/>
<association property="materialinfo" javaType="com.sipai.entity.material.MaterialInfo" >
<id property="id" column="i_id"/>
<result property="materialname" column="materialname"/>
<result property="materialcode" column="materialcode"/>
<result property="spec" column="spec"/>
<result property="unit" column="unit"/>
</association>
<association property="applyuser" javaType="com.sipai.entity.user.User" >
<id property="id" column="u_id"/>
<result property="caption" column="u_username"/>
<result property="name" column="u_name"/>
</association>
<association property="workstation" javaType="com.sipai.entity.work.Workstation" >
<id property="id" column="w_id"/>
<result property="serial" column="serial"/>
<result property="name" column="w_name"/>
<result property="linename" column="l_name"/>
<result property="deptname" column="t_name"/>
</association>
</resultMap>
</mapper>

View File

@ -0,0 +1,139 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.MaterialShortMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialShort" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="productid" property="productid" jdbcType="VARCHAR" />
<result column="wftaskid" property="wftaskid" jdbcType="VARCHAR" />
<result column="workstationserial" property="workstationserial" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="amount" property="amount" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, materialid, productid, wftaskid, workstationserial, insuser, insdt, amount
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_short
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_short
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialShort" >
insert into tb_material_short (id, materialid, productid,
wftaskid, workstationserial, insuser,
insdt, amount)
values (#{id,jdbcType=VARCHAR}, #{materialid,jdbcType=VARCHAR}, #{productid,jdbcType=VARCHAR},
#{wftaskid,jdbcType=VARCHAR}, #{workstationserial,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{amount,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialShort" >
insert into tb_material_short
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="materialid != null" >
materialid,
</if>
<if test="productid != null" >
productid,
</if>
<if test="wftaskid != null" >
wftaskid,
</if>
<if test="workstationserial != null" >
workstationserial,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="amount != null" >
amount,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
#{materialid,jdbcType=VARCHAR},
</if>
<if test="productid != null" >
#{productid,jdbcType=VARCHAR},
</if>
<if test="wftaskid != null" >
#{wftaskid,jdbcType=VARCHAR},
</if>
<if test="workstationserial != null" >
#{workstationserial,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="amount != null" >
#{amount,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialShort" >
update tb_material_short
<set >
<if test="materialid != null" >
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="productid != null" >
productid = #{productid,jdbcType=VARCHAR},
</if>
<if test="wftaskid != null" >
wftaskid = #{wftaskid,jdbcType=VARCHAR},
</if>
<if test="workstationserial != null" >
workstationserial = #{workstationserial,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="amount != null" >
amount = #{amount,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialShort" >
update tb_material_short
set materialid = #{materialid,jdbcType=VARCHAR},
productid = #{productid,jdbcType=VARCHAR},
wftaskid = #{wftaskid,jdbcType=VARCHAR},
workstationserial = #{workstationserial,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
amount = #{amount,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_short
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_short
${where}
</delete>
</mapper>

View File

@ -0,0 +1,174 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.MaterialTypeMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialType" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="typecode" property="typecode" jdbcType="VARCHAR" />
<result column="typename" property="typename" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<result column="parentid" property="parentid" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, typecode, typename, status, remark, insuser, insdt, modify, modifydt, parentid
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_type
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_type
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialType" >
insert into tb_material_type (id, typecode, typename,
status, remark, insuser,
insdt, modify, modifydt,
parentid)
values (#{id,jdbcType=VARCHAR}, #{typecode,jdbcType=VARCHAR}, #{typename,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{modify,jdbcType=VARCHAR}, #{modifydt,jdbcType=TIMESTAMP},
#{parentid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialType" >
insert into tb_material_type
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="typecode != null" >
typecode,
</if>
<if test="typename != null" >
typename,
</if>
<if test="status != null" >
status,
</if>
<if test="remark != null" >
remark,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
<if test="parentid != null" >
parentid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="typecode != null" >
#{typecode,jdbcType=VARCHAR},
</if>
<if test="typename != null" >
#{typename,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
<if test="parentid != null" >
#{parentid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialType" >
update tb_material_type
<set >
<if test="typecode != null" >
typecode = #{typecode,jdbcType=VARCHAR},
</if>
<if test="typename != null" >
typename = #{typename,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
<if test="parentid != null" >
parentid = #{parentid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialType" >
update tb_material_type
set typecode = #{typecode,jdbcType=VARCHAR},
typename = #{typename,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP},
parentid = #{parentid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_type
${where}
</select>
<select id="getListByTypename" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_type
where typename = #{typename,jdbcType=VARCHAR}
</select>
<select id="getListByTypecode" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_type
where typecode = #{typecode,jdbcType=VARCHAR}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_type
${where}
</delete>
</mapper>

View File

@ -0,0 +1,144 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.MaterialUnitMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.MaterialUnit" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, unit, status, remark, insuser, insdt, modify, modifydt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_unit
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_unit
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.MaterialUnit" >
insert into tb_material_unit (id, unit, status,
remark, insuser, insdt,
modify, modifydt)
values (#{id,jdbcType=VARCHAR}, #{unit,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR},
#{remark,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{modify,jdbcType=VARCHAR}, #{modifydt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.MaterialUnit" >
insert into tb_material_unit
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="unit != null" >
unit,
</if>
<if test="status != null" >
status,
</if>
<if test="remark != null" >
remark,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
#{unit,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.MaterialUnit" >
update tb_material_unit
<set >
<if test="unit != null" >
unit = #{unit,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.MaterialUnit" >
update tb_material_unit
set unit = #{unit,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_unit
${where}
</select>
<select id="getListByUnit" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_unit
where unit = #{unit,jdbcType=VARCHAR}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_unit
${where}
</delete>
</mapper>

View File

@ -0,0 +1,202 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.NotBOMMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.NotBOM" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="handletype" property="handletype" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="materialname" property="materialname" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="linestocknum" property="linestocknum" jdbcType="VARCHAR" />
<result column="warehousestocknum" property="warehousestocknum" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="handlenum" property="handlenum" jdbcType="VARCHAR" />
<result column="handledate" property="handledate" jdbcType="TIMESTAMP" />
<result column="materialmodel" property="materialmodel" jdbcType="VARCHAR" />
<result column="inventoryFrontLine" property="inventoryFrontLine" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, pid, handletype, materialname, materialid, unit, linestocknum, warehousestocknum,
insuser, insdt, handlenum, handledate
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_notbom
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_notbom
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.NotBOM" >
insert into tb_material_notbom (id, pid, handletype,
materialname, materialid,
unit, linestocknum, warehousestocknum,
insuser, insdt, handlenum,
handledate)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{handletype,jdbcType=VARCHAR},
#{materialname,jdbcType=VARCHAR}, #{materialid,jdbcType=VARCHAR},
#{unit,jdbcType=VARCHAR}, #{linestocknum,jdbcType=VARCHAR}, #{warehousestocknum,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{handlenum,jdbcType=VARCHAR},
#{handledate,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.NotBOM" >
insert into tb_material_notbom
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="pid != null" >
pid,
</if>
<if test="handletype != null" >
handletype,
</if>
<if test="materialname != null" >
materialname,
</if>
<if test="materialid != null" >
materialid,
</if>
<if test="unit != null" >
unit,
</if>
<if test="linestocknum != null" >
linestocknum,
</if>
<if test="warehousestocknum != null" >
warehousestocknum,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="handlenum != null" >
handlenum,
</if>
<if test="handledate != null" >
handledate,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="handletype != null" >
#{handletype,jdbcType=VARCHAR},
</if>
<if test="materialname != null" >
#{materialname,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
#{materialid,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
#{unit,jdbcType=VARCHAR},
</if>
<if test="linestocknum != null" >
#{linestocknum,jdbcType=VARCHAR},
</if>
<if test="warehousestocknum != null" >
#{warehousestocknum,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="handlenum != null" >
#{handlenum,jdbcType=VARCHAR},
</if>
<if test="handledate != null" >
#{handledate,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.NotBOM" >
update tb_material_notbom
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="handletype != null" >
handletype = #{handletype,jdbcType=VARCHAR},
</if>
<if test="materialname != null" >
materialname = #{materialname,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
unit = #{unit,jdbcType=VARCHAR},
</if>
<if test="linestocknum != null" >
linestocknum = #{linestocknum,jdbcType=VARCHAR},
</if>
<if test="warehousestocknum != null" >
warehousestocknum = #{warehousestocknum,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="handlenum != null" >
handlenum = #{handlenum,jdbcType=VARCHAR},
</if>
<if test="handledate != null" >
handledate = #{handledate,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.NotBOM" >
update tb_material_notbom
set pid = #{pid,jdbcType=VARCHAR},
handletype = #{handletype,jdbcType=VARCHAR},
materialname = #{materialname,jdbcType=VARCHAR},
materialid = #{materialid,jdbcType=VARCHAR},
unit = #{unit,jdbcType=VARCHAR},
linestocknum = #{linestocknum,jdbcType=VARCHAR},
warehousestocknum = #{warehousestocknum,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
handlenum = #{handlenum,jdbcType=VARCHAR},
handledate = #{handledate,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_notbom
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_notbom
${where}
</delete>
<select id="selectListByMaterial" resultMap="BaseResultMap" parameterType="java.lang.String" >
select A.materialname,A.materialcode,A.unit,A.materialmodel,
I.inventoryFrontLine,
N.handledate,N.materialid,
N.id
from tb_material_notbom N
left outer join tb_material_allinfo A on A.id = N.materialid
left outer join tb_material_inventory I on I.materialid = N.materialid
${where}
</select>
</mapper>

View File

@ -0,0 +1,153 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.NotBOMPickMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.NotBOMPick" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="handletype" property="handletype" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="allinfoid" property="allinfoid" jdbcType="VARCHAR" />
<result column="handlenum" property="handlenum" jdbcType="VARCHAR" />
<result column="handledate" property="handledate" jdbcType="TIMESTAMP" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="materialname" property="materialname" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, handletype, materialid, allinfoid, handlenum, handledate
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_notbompick
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_material_notbompick
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.NotBOMPick" >
insert into tb_material_notbompick (id, insuser, insdt,
handletype, materialid, allinfoid,
handlenum, handledate
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{handletype,jdbcType=VARCHAR}, #{materialid,jdbcType=VARCHAR}, #{allinfoid,jdbcType=VARCHAR},
#{handlenum,jdbcType=VARCHAR}, #{handledate,jdbcType=TIMESTAMP}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.NotBOMPick" >
insert into tb_material_notbompick
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="handletype != null" >
handletype,
</if>
<if test="materialid != null" >
materialid,
</if>
<if test="allinfoid != null" >
allinfoid,
</if>
<if test="handlenum != null" >
handlenum,
</if>
<if test="handledate != null" >
handledate,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="handletype != null" >
#{handletype,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
#{materialid,jdbcType=VARCHAR},
</if>
<if test="allinfoid != null" >
#{allinfoid,jdbcType=VARCHAR},
</if>
<if test="handlenum != null" >
#{handlenum,jdbcType=VARCHAR},
</if>
<if test="handledate != null" >
#{handledate,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.NotBOMPick" >
update tb_material_notbompick
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="handletype != null" >
handletype = #{handletype,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="allinfoid != null" >
allinfoid = #{allinfoid,jdbcType=VARCHAR},
</if>
<if test="handlenum != null" >
handlenum = #{handlenum,jdbcType=VARCHAR},
</if>
<if test="handledate != null" >
handledate = #{handledate,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.NotBOMPick" >
update tb_material_notbompick
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
handletype = #{handletype,jdbcType=VARCHAR},
materialid = #{materialid,jdbcType=VARCHAR},
allinfoid = #{allinfoid,jdbcType=VARCHAR},
handlenum = #{handlenum,jdbcType=VARCHAR},
handledate = #{handledate,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_material_notbompick
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_material_notbompick
${where}
</delete>
<select id="selectListByMaterial" resultMap="BaseResultMap" parameterType="java.lang.String">
select P.handletype,P.handlenum,P.insuser,P.handledate,P.id,P.materialid,
A.materialname,A.materialcode,A.unit
from tb_material_notbompick P
left outer join tb_material_notbom N on N.id = P.materialid
left outer join tb_material_allinfo A on A.id = N.materialid
${where}
</select>
</mapper>

View File

@ -0,0 +1,135 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.OrderProductDetailMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.OrderProductDetail" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="productUId" property="productuid" jdbcType="VARCHAR" />
<result column="productionorderno" property="productionorderno" jdbcType="VARCHAR" />
<result column="workorderId" property="workorderid" jdbcType="VARCHAR" />
<result column="processrealid" property="processrealid" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, pid, productUId, productionorderno,workorderId,processrealid,status
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_OrderProductDetail
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_material_OrderProductDetail
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.OrderProductDetail" >
insert into TB_material_OrderProductDetail (id, insuser, insdt,
pid, productUId,productionorderno,workorderId,processrealid,status)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{pid,jdbcType=VARCHAR}, #{productuid,jdbcType=VARCHAR}, #{productionorderno,jdbcType=VARCHAR}, #{workorderid,jdbcType=VARCHAR},
#{processrealid,jdbcType=VARCHAR},#{status,jdbcType=VARCHAR})
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.OrderProductDetail" >
update TB_material_OrderProductDetail
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="productuid != null" >
productUId = #{productuid,jdbcType=VARCHAR},
</if>
<if test="productionorderno != null" >
productionorderno = #{productionorderno,jdbcType=VARCHAR},
</if>
<if test="workorderid != null" >
workorderId = #{workorderid,jdbcType=VARCHAR},
</if>
<if test="processrealid != null" >
processrealid = #{processrealid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateBySetAndWhere" parameterType="com.sipai.entity.material.OrderProductDetail" >
update
${where}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_OrderProductDetail
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_OrderProductDetail
${where}
</select>
<select id="selectTopNByWhere" resultMap="BaseResultMap" parameterType="java.util.Map" >
select TOP ${numN}
<include refid="Base_Column_List" />
from TB_material_OrderProductDetail
${wherestr}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_material_OrderProductDetail
${where}
</delete>
<select id="getOrderProductDetail" resultMap="ClassResultMapOPD" parameterType="java.lang.String">
SELECT
D.id as d_id,
D.insuser as d_insuser,
D.insdt as d_insdt,
D.pid as d_pid,
D.productUId as d_productUId,
D.productionorderno as d_productionorderno,
D.workorderId as d_workorderId,
D.processrealid as d_processrealid,
D.status as d_status,
O.id as o_id,
O.wfOrderid as o_wfOrderid,
O.productionOrderNo as o_productionOrderNo,
W.id as w_id,
W.order_State as w_orderstate,
P.id as p_id,
S.id as s_id,
S.plandt as s_plandt
from TB_material_OrderProductDetail D
LEFT OUTER JOIN tb_work_order O ON O.id = D.workorderid
LEFT OUTER JOIN wf_hist_order W ON W.id = O.wfOrderid
LEFT OUTER JOIN tb_plan_day P ON P.productionOrderNo = D.productionOrderNo
LEFT OUTER JOIN TB_plan_dailyplanSummary S ON S.id = P.pid
${where}
</select>
<resultMap id="ClassResultMapOPD" type="com.sipai.entity.material.OrderProductDetail">
<id property="id" column="d_id" />
<result property="insuser" column="d_insuser"/>
<result property="insdt" column="d_insdt"/>
<result property="pid" column="d_pid"/>
<result property="productuid" column="d_productUId"/>
<result property="productionorderno" column="d_productionorderno"/>
<result property="workorderid" column="d_workorderId"/>
<result property="processrealid" column="d_processrealid"/>
<result property="status" column="d_status"/>
<result property="finishflag_wfo" column="w_orderstate"/>
<result property="_planid" column="p_id"/>
<association property="workorder" javaType="com.sipai.entity.work.WorkOrder" >
<id property="id" column="o_id"/>
<result property="wforderid" column="o_wforderid"/>
<result property="productionorderno" column="o_productionorderno"/>
</association>
</resultMap>
</mapper>

View File

@ -0,0 +1,133 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="material.OrderProductDetailconnectMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.material.OrderProductDetailconnect" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="planid" property="planid" jdbcType="VARCHAR" />
<result column="productdetailid" property="productdetailid" jdbcType="VARCHAR" />
<result column="workorderid" property="workorderid" jdbcType="VARCHAR" />
<result column="processrealid" property="processrealid" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insdt, insuser, planid, productdetailid, workorderid, processrealid
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_OrderProductDetail_connect
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_material_OrderProductDetail_connect
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.OrderProductDetailconnect" >
insert into TB_material_OrderProductDetail_connect (id, insdt, insuser,
planid, productdetailid, workorderid,
processrealid)
values (#{id,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{insuser,jdbcType=VARCHAR},
#{planid,jdbcType=VARCHAR}, #{productdetailid,jdbcType=VARCHAR}, #{workorderid,jdbcType=VARCHAR},
#{processrealid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.material.OrderProductDetailconnect" >
insert into TB_material_OrderProductDetail_connect
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="planid != null" >
planid,
</if>
<if test="productdetailid != null" >
productdetailid,
</if>
<if test="workorderid != null" >
workorderid,
</if>
<if test="processrealid != null" >
processrealid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="planid != null" >
#{planid,jdbcType=VARCHAR},
</if>
<if test="productdetailid != null" >
#{productdetailid,jdbcType=VARCHAR},
</if>
<if test="workorderid != null" >
#{workorderid,jdbcType=VARCHAR},
</if>
<if test="processrealid != null" >
#{processrealid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.OrderProductDetailconnect" >
update TB_material_OrderProductDetail_connect
<set >
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="planid != null" >
planid = #{planid,jdbcType=VARCHAR},
</if>
<if test="productdetailid != null" >
productdetailid = #{productdetailid,jdbcType=VARCHAR},
</if>
<if test="workorderid != null" >
workorderid = #{workorderid,jdbcType=VARCHAR},
</if>
<if test="processrealid != null" >
processrealid = #{processrealid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.material.OrderProductDetailconnect" >
update TB_material_OrderProductDetail_connect
set insdt = #{insdt,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
planid = #{planid,jdbcType=VARCHAR},
productdetailid = #{productdetailid,jdbcType=VARCHAR},
workorderid = #{workorderid,jdbcType=VARCHAR},
processrealid = #{processrealid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_OrderProductDetail_connect
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_material_OrderProductDetail_connect
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_material_OrderProductDetail_connect
${where}
</delete>
</mapper>

View File

@ -0,0 +1,203 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="material.SalesOrderProductMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.material.SalesOrderProduct">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="SalesOrderNo" jdbcType="VARCHAR" property="salesorderno" />
<result column="clientsid" jdbcType="VARCHAR" property="clientsid" />
<result column="productid" jdbcType="VARCHAR" property="productid" />
<result column="productNum" jdbcType="VARCHAR" property="productnum" />
<result column="OrderCreateDate" jdbcType="TIMESTAMP" property="ordercreatedate" />
<result column="OrderFinishDate" jdbcType="TIMESTAMP" property="orderfinishdate" />
<result column="deliverydate" jdbcType="TIMESTAMP" property="deliverydate" />
<result column="status" jdbcType="VARCHAR" property="status" />
</resultMap>
<sql id="Base_Column_List">
id, insuser, insdt, SalesOrderNo, clientsid, productid, productNum, OrderCreateDate,
OrderFinishDate, deliverydate, status
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_material_SalesOrderProduct
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from TB_material_SalesOrderProduct
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.material.SalesOrderProduct">
insert into TB_material_SalesOrderProduct (id, insuser, insdt,
SalesOrderNo, clientsid, productid,
productNum, OrderCreateDate, OrderFinishDate,
deliverydate, status)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{salesorderno,jdbcType=VARCHAR}, #{clientsid,jdbcType=VARCHAR}, #{productid,jdbcType=VARCHAR},
#{productnum,jdbcType=VARCHAR}, #{ordercreatedate,jdbcType=TIMESTAMP}, #{orderfinishdate,jdbcType=TIMESTAMP},
#{deliverydate,jdbcType=TIMESTAMP}, #{status,jdbcType=VARCHAR})
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.material.SalesOrderProduct">
update TB_material_SalesOrderProduct
<set>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="salesorderno != null">
SalesOrderNo = #{salesorderno,jdbcType=VARCHAR},
</if>
<if test="clientsid != null">
clientsid = #{clientsid,jdbcType=VARCHAR},
</if>
<if test="productid != null">
productid = #{productid,jdbcType=VARCHAR},
</if>
<if test="productnum != null">
productNum = #{productnum,jdbcType=VARCHAR},
</if>
<if test="ordercreatedate != null">
OrderCreateDate = #{ordercreatedate,jdbcType=TIMESTAMP},
</if>
<if test="orderfinishdate != null">
OrderFinishDate = #{orderfinishdate,jdbcType=TIMESTAMP},
</if>
<if test="deliverydate != null">
deliverydate = #{deliverydate,jdbcType=TIMESTAMP},
</if>
<if test="status != null">
status = #{status,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_material_SalesOrderProduct
${where}
</select>
<select id="selectByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_material_SalesOrderProduct
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from TB_material_SalesOrderProduct
${where}
</delete>
<select id="getSalesOrderProductlist" parameterType="java.lang.String" resultMap="ClassResultMapSOPlist">
SELECT
P.id as p_id,
P.insuser as p_insuser,
P.insdt as P_insdt,
P.SalesOrderNo,
P.productid,
P.productNum,
P.OrderCreateDate,
P.OrderFinishDate,
P.deliverydate,
P.status,
I.id as i_id,
I.materialname,
I.materialcode,
I.spec,
C.name as clientname
FROM TB_material_SalesOrderProduct P
LEFT OUTER JOIN tb_material_info I ON I.id = P.productid
LEFT OUTER JOIN tb_clients C ON C.id = P.clientsid
${where}
</select>
<resultMap id="ClassResultMapSOPlist" type="com.sipai.entity.material.SalesOrderProduct">
<id column="p_id" property="id" />
<result column="p_insuser" property="insuser" />
<result column="p_insdt" property="insdt" />
<result column="salesorderno" property="salesorderno" />
<result column="productid" property="productid" />
<result column="productNum" property="productnum" />
<result column="OrderCreateDate" property="ordercreatedate" />
<result column="OrderFinishDate" property="orderfinishdate" />
<result column="deliverydate" property="deliverydate" />
<result column="status" property="status" />
<result column="clientname" property="clientname" />
<association javaType="com.sipai.entity.material.MaterialInfo" property="product">
<id column="i_id" property="id" />
<result column="materialname" property="materialname" />
<result column="materialcode" property="materialcode" />
<result column="spec" property="spec" />
</association>
</resultMap>
<select id="getSalesOrderProduct" parameterType="java.lang.String" resultMap="ClassResultMapSOP">
SELECT
P.id as p_id,
P.insuser as p_insuser,
P.insdt as P_insdt,
P.SalesOrderNo,
P.productid,
P.productNum,
P.OrderCreateDate,
P.OrderFinishDate,
P.deliverydate,
P.status,
D.id as d_id,
D.ProductUId,
D.productionorderno,
D.workorderId,
I.id as i_id,
I.materialname,
I.materialcode,
I.spec,
p.clientsid
FROM TB_material_SalesOrderProduct P
LEFT OUTER JOIN TB_material_OrderProductDetail D ON D.pid = P.id
LEFT OUTER JOIN tb_material_info I ON I.id = P.productid
LEFT OUTER JOIN tb_clients c ON c.id = P.clientsid
${where}
</select>
<resultMap id="ClassResultMapSOP" type="com.sipai.entity.material.SalesOrderProduct">
<id column="p_id" property="id" />
<result column="p_insuser" property="insuser" />
<result column="p_insdt" property="insdt" />
<result column="salesorderno" property="salesorderno" />
<result column="productid" property="productid" />
<result column="productNum" property="productnum" />
<result column="OrderCreateDate" property="ordercreatedate" />
<result column="OrderFinishDate" property="orderfinishdate" />
<result column="deliverydate" property="deliverydate" />
<result column="status" property="status" />
<result column="clientsid" property="clientsid" />
<association javaType="com.sipai.entity.material.MaterialInfo" property="product">
<id column="i_id" property="id" />
<result column="materialname" property="materialname" />
<result column="materialcode" property="materialcode" />
<result column="spec" property="spec" />
</association>
<collection column="clientsid" property="clients" ofType="com.sipai.entity.material.Clients" select="selectclients">
</collection>
<collection ofType="com.sipai.entity.material.OrderProductDetail" property="orderproductdetail">
<id column="d_id" property="id" />
<result column="ProductUId" property="productuid" />
<result column="productionorderno" property="productionorderno" />
<result column="workorderId" property="workorderid" />
</collection>
</resultMap>
<select id="selectclients" resultType="com.sipai.entity.material.Clients" parameterType="java.lang.String" >
select * from tb_clients where id = #{clientsid,jdbcType=VARCHAR}
</select>
<select id="selectDistinctOrderByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select salesorderno,
SUM(case when productNum is not null then convert(int,productNum) else 0 end) as productnum
from TB_material_SalesOrderProduct
${where}
</select>
</mapper>

View File

@ -0,0 +1,193 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.EmppAdminMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.EmppAdmin" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="emppname" property="emppname" jdbcType="VARCHAR" />
<result column="host" property="host" jdbcType="VARCHAR" />
<result column="port" property="port" jdbcType="INTEGER" />
<result column="accountId" property="accountid" jdbcType="VARCHAR" />
<result column="accname" property="accname" jdbcType="VARCHAR" />
<result column="password" property="password" jdbcType="VARCHAR" />
<result column="serviceId" property="serviceid" jdbcType="VARCHAR" />
<result column="insertuserid" property="insertuserid" jdbcType="VARCHAR" />
<result column="insertdate" property="insertdate" jdbcType="TIMESTAMP" />
<result column="updateuserid" property="updateuserid" jdbcType="VARCHAR" />
<result column="updatedate" property="updatedate" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, emppname, host, port, accountId, accname, password, serviceId, insertuserid,
insertdate, updateuserid, updatedate
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_EMPP_EmppAdmin
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_EMPP_EmppAdmin
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.EmppAdmin" >
insert into tb_EMPP_EmppAdmin (id, emppname, host,
port, accountId, accname,
password, serviceId, insertuserid,
insertdate, updateuserid, updatedate
)
values (#{id,jdbcType=VARCHAR}, #{emppname,jdbcType=VARCHAR}, #{host,jdbcType=VARCHAR},
#{port,jdbcType=INTEGER}, #{accountid,jdbcType=VARCHAR}, #{accname,jdbcType=VARCHAR},
#{password,jdbcType=VARCHAR}, #{serviceid,jdbcType=VARCHAR}, #{insertuserid,jdbcType=VARCHAR},
#{insertdate,jdbcType=TIMESTAMP}, #{updateuserid,jdbcType=VARCHAR}, #{updatedate,jdbcType=TIMESTAMP}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.EmppAdmin" >
insert into tb_EMPP_EmppAdmin
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="emppname != null" >
emppname,
</if>
<if test="host != null" >
host,
</if>
<if test="port != null" >
port,
</if>
<if test="accountid != null" >
accountId,
</if>
<if test="accname != null" >
accname,
</if>
<if test="password != null" >
password,
</if>
<if test="serviceid != null" >
serviceId,
</if>
<if test="insertuserid != null" >
insertuserid,
</if>
<if test="insertdate != null" >
insertdate,
</if>
<if test="updateuserid != null" >
updateuserid,
</if>
<if test="updatedate != null" >
updatedate,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="emppname != null" >
#{emppname,jdbcType=VARCHAR},
</if>
<if test="host != null" >
#{host,jdbcType=VARCHAR},
</if>
<if test="port != null" >
#{port,jdbcType=INTEGER},
</if>
<if test="accountid != null" >
#{accountid,jdbcType=VARCHAR},
</if>
<if test="accname != null" >
#{accname,jdbcType=VARCHAR},
</if>
<if test="password != null" >
#{password,jdbcType=VARCHAR},
</if>
<if test="serviceid != null" >
#{serviceid,jdbcType=VARCHAR},
</if>
<if test="insertuserid != null" >
#{insertuserid,jdbcType=VARCHAR},
</if>
<if test="insertdate != null" >
#{insertdate,jdbcType=TIMESTAMP},
</if>
<if test="updateuserid != null" >
#{updateuserid,jdbcType=VARCHAR},
</if>
<if test="updatedate != null" >
#{updatedate,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.EmppAdmin" >
update tb_EMPP_EmppAdmin
<set >
<if test="emppname != null" >
emppname = #{emppname,jdbcType=VARCHAR},
</if>
<if test="host != null" >
host = #{host,jdbcType=VARCHAR},
</if>
<if test="port != null" >
port = #{port,jdbcType=INTEGER},
</if>
<if test="accountid != null" >
accountId = #{accountid,jdbcType=VARCHAR},
</if>
<if test="accname != null" >
accname = #{accname,jdbcType=VARCHAR},
</if>
<if test="password != null" >
password = #{password,jdbcType=VARCHAR},
</if>
<if test="serviceid != null" >
serviceId = #{serviceid,jdbcType=VARCHAR},
</if>
<if test="insertuserid != null" >
insertuserid = #{insertuserid,jdbcType=VARCHAR},
</if>
<if test="insertdate != null" >
insertdate = #{insertdate,jdbcType=TIMESTAMP},
</if>
<if test="updateuserid != null" >
updateuserid = #{updateuserid,jdbcType=VARCHAR},
</if>
<if test="updatedate != null" >
updatedate = #{updatedate,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.EmppAdmin" >
update tb_EMPP_EmppAdmin
set emppname = #{emppname,jdbcType=VARCHAR},
host = #{host,jdbcType=VARCHAR},
port = #{port,jdbcType=INTEGER},
accountId = #{accountid,jdbcType=VARCHAR},
accname = #{accname,jdbcType=VARCHAR},
password = #{password,jdbcType=VARCHAR},
serviceId = #{serviceid,jdbcType=VARCHAR},
insertuserid = #{insertuserid,jdbcType=VARCHAR},
insertdate = #{insertdate,jdbcType=TIMESTAMP},
updateuserid = #{updateuserid,jdbcType=VARCHAR},
updatedate = #{updatedate,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_EMPP_EmppAdmin
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_EMPP_EmppAdmin
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_EMPP_EmppAdmin
${where}
</delete>
</mapper>

View File

@ -0,0 +1,183 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.EmppSendMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.EmppSend" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="emppAdminid" property="emppadminid" jdbcType="VARCHAR" />
<result column="senduserid" property="senduserid" jdbcType="VARCHAR" />
<result column="senddate" property="senddate" jdbcType="TIMESTAMP" />
<result column="insertuserid" property="insertuserid" jdbcType="VARCHAR" />
<result column="insertdate" property="insertdate" jdbcType="TIMESTAMP" />
<result column="updateuserid" property="updateuserid" jdbcType="VARCHAR" />
<result column="updatedate" property="updatedate" jdbcType="TIMESTAMP" />
<result column="recuserid" property="recuserid" jdbcType="CLOB" />
<result column="recusername" property="recusername" jdbcType="CLOB" />
<result column="sendtitle" property="sendtitle" jdbcType="CLOB" />
</resultMap>
<sql id="Base_Column_List" >
id, emppAdminid, senduserid, senddate, insertuserid, insertdate, updateuserid, updatedate,recuserid, recusername, sendtitle
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_EMPP_EmppSend
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_EMPP_EmppSend
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.EmppSend" >
insert into tb_EMPP_EmppSend (id, emppAdminid, senduserid,
senddate, insertuserid, insertdate,
updateuserid, updatedate, recuserid,
recusername, sendtitle)
values (#{id,jdbcType=VARCHAR}, #{emppadminid,jdbcType=VARCHAR}, #{senduserid,jdbcType=VARCHAR},
#{senddate,jdbcType=TIMESTAMP}, #{insertuserid,jdbcType=VARCHAR}, #{insertdate,jdbcType=TIMESTAMP},
#{updateuserid,jdbcType=VARCHAR}, #{updatedate,jdbcType=TIMESTAMP}, #{recuserid,jdbcType=CLOB},
#{recusername,jdbcType=CLOB}, #{sendtitle,jdbcType=CLOB})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.EmppSend" >
insert into tb_EMPP_EmppSend
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="emppadminid != null" >
emppAdminid,
</if>
<if test="senduserid != null" >
senduserid,
</if>
<if test="senddate != null" >
senddate,
</if>
<if test="insertuserid != null" >
insertuserid,
</if>
<if test="insertdate != null" >
insertdate,
</if>
<if test="updateuserid != null" >
updateuserid,
</if>
<if test="updatedate != null" >
updatedate,
</if>
<if test="recuserid != null" >
recuserid,
</if>
<if test="recusername != null" >
recusername,
</if>
<if test="sendtitle != null" >
sendtitle,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="emppadminid != null" >
#{emppadminid,jdbcType=VARCHAR},
</if>
<if test="senduserid != null" >
#{senduserid,jdbcType=VARCHAR},
</if>
<if test="senddate != null" >
#{senddate,jdbcType=TIMESTAMP},
</if>
<if test="insertuserid != null" >
#{insertuserid,jdbcType=VARCHAR},
</if>
<if test="insertdate != null" >
#{insertdate,jdbcType=TIMESTAMP},
</if>
<if test="updateuserid != null" >
#{updateuserid,jdbcType=VARCHAR},
</if>
<if test="updatedate != null" >
#{updatedate,jdbcType=TIMESTAMP},
</if>
<if test="recuserid != null" >
#{recuserid,jdbcType=CLOB},
</if>
<if test="recusername != null" >
#{recusername,jdbcType=CLOB},
</if>
<if test="sendtitle != null" >
#{sendtitle,jdbcType=CLOB},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.EmppSend" >
update tb_EMPP_EmppSend
<set >
<if test="emppadminid != null" >
emppAdminid = #{emppadminid,jdbcType=VARCHAR},
</if>
<if test="senduserid != null" >
senduserid = #{senduserid,jdbcType=VARCHAR},
</if>
<if test="senddate != null" >
senddate = #{senddate,jdbcType=TIMESTAMP},
</if>
<if test="insertuserid != null" >
insertuserid = #{insertuserid,jdbcType=VARCHAR},
</if>
<if test="insertdate != null" >
insertdate = #{insertdate,jdbcType=TIMESTAMP},
</if>
<if test="updateuserid != null" >
updateuserid = #{updateuserid,jdbcType=VARCHAR},
</if>
<if test="updatedate != null" >
updatedate = #{updatedate,jdbcType=TIMESTAMP},
</if>
<if test="recuserid != null" >
recuserid = #{recuserid,jdbcType=CLOB},
</if>
<if test="recusername != null" >
recusername = #{recusername,jdbcType=CLOB},
</if>
<if test="sendtitle != null" >
sendtitle = #{sendtitle,jdbcType=CLOB},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.EmppSend" >
update tb_EMPP_EmppSend
set emppAdminid = #{emppadminid,jdbcType=VARCHAR},
senduserid = #{senduserid,jdbcType=VARCHAR},
senddate = #{senddate,jdbcType=TIMESTAMP},
insertuserid = #{insertuserid,jdbcType=VARCHAR},
insertdate = #{insertdate,jdbcType=TIMESTAMP},
updateuserid = #{updateuserid,jdbcType=VARCHAR},
updatedate = #{updatedate,jdbcType=TIMESTAMP},
recuserid = #{recuserid,jdbcType=CLOB},
recusername = #{recusername,jdbcType=CLOB},
sendtitle = #{sendtitle,jdbcType=CLOB}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_EMPP_EmppSend
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_EMPP_EmppSend
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_EMPP_EmppSend
${where}
</delete>
</mapper>

View File

@ -0,0 +1,193 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.EmppSendUserMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.EmppSendUser" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="emppSendid" property="emppsendid" jdbcType="VARCHAR" />
<result column="senduserid" property="senduserid" jdbcType="VARCHAR" />
<result column="senddate" property="senddate" jdbcType="TIMESTAMP" />
<result column="recuserid" property="recuserid" jdbcType="VARCHAR" />
<result column="mobile" property="mobile" jdbcType="VARCHAR" />
<result column="backdate" property="backdate" jdbcType="TIMESTAMP" />
<result column="insertuserid" property="insertuserid" jdbcType="VARCHAR" />
<result column="insertdate" property="insertdate" jdbcType="TIMESTAMP" />
<result column="updateuserid" property="updateuserid" jdbcType="VARCHAR" />
<result column="updatedate" property="updatedate" jdbcType="TIMESTAMP" />
<result column="msgId" property="msgid" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, emppSendid, senduserid, senddate, recuserid, mobile, backdate, insertuserid,
insertdate, updateuserid, updatedate, msgId
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_EMPP_EmppSendUser
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_EMPP_EmppSendUser
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.EmppSendUser" >
insert into tb_EMPP_EmppSendUser (id, emppSendid, senduserid,
senddate, recuserid, mobile,
backdate, insertuserid, insertdate,
updateuserid, updatedate, msgId
)
values (#{id,jdbcType=VARCHAR}, #{emppsendid,jdbcType=VARCHAR}, #{senduserid,jdbcType=VARCHAR},
#{senddate,jdbcType=TIMESTAMP}, #{recuserid,jdbcType=VARCHAR}, #{mobile,jdbcType=VARCHAR},
#{backdate,jdbcType=TIMESTAMP}, #{insertuserid,jdbcType=VARCHAR}, #{insertdate,jdbcType=TIMESTAMP},
#{updateuserid,jdbcType=VARCHAR}, #{updatedate,jdbcType=TIMESTAMP}, #{msgid,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.EmppSendUser" >
insert into tb_EMPP_EmppSendUser
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="emppsendid != null" >
emppSendid,
</if>
<if test="senduserid != null" >
senduserid,
</if>
<if test="senddate != null" >
senddate,
</if>
<if test="recuserid != null" >
recuserid,
</if>
<if test="mobile != null" >
mobile,
</if>
<if test="backdate != null" >
backdate,
</if>
<if test="insertuserid != null" >
insertuserid,
</if>
<if test="insertdate != null" >
insertdate,
</if>
<if test="updateuserid != null" >
updateuserid,
</if>
<if test="updatedate != null" >
updatedate,
</if>
<if test="msgid != null" >
msgId,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="emppsendid != null" >
#{emppsendid,jdbcType=VARCHAR},
</if>
<if test="senduserid != null" >
#{senduserid,jdbcType=VARCHAR},
</if>
<if test="senddate != null" >
#{senddate,jdbcType=TIMESTAMP},
</if>
<if test="recuserid != null" >
#{recuserid,jdbcType=VARCHAR},
</if>
<if test="mobile != null" >
#{mobile,jdbcType=VARCHAR},
</if>
<if test="backdate != null" >
#{backdate,jdbcType=TIMESTAMP},
</if>
<if test="insertuserid != null" >
#{insertuserid,jdbcType=VARCHAR},
</if>
<if test="insertdate != null" >
#{insertdate,jdbcType=TIMESTAMP},
</if>
<if test="updateuserid != null" >
#{updateuserid,jdbcType=VARCHAR},
</if>
<if test="updatedate != null" >
#{updatedate,jdbcType=TIMESTAMP},
</if>
<if test="msgid != null" >
#{msgid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.EmppSendUser" >
update tb_EMPP_EmppSendUser
<set >
<if test="emppsendid != null" >
emppSendid = #{emppsendid,jdbcType=VARCHAR},
</if>
<if test="senduserid != null" >
senduserid = #{senduserid,jdbcType=VARCHAR},
</if>
<if test="senddate != null" >
senddate = #{senddate,jdbcType=TIMESTAMP},
</if>
<if test="recuserid != null" >
recuserid = #{recuserid,jdbcType=VARCHAR},
</if>
<if test="mobile != null" >
mobile = #{mobile,jdbcType=VARCHAR},
</if>
<if test="backdate != null" >
backdate = #{backdate,jdbcType=TIMESTAMP},
</if>
<if test="insertuserid != null" >
insertuserid = #{insertuserid,jdbcType=VARCHAR},
</if>
<if test="insertdate != null" >
insertdate = #{insertdate,jdbcType=TIMESTAMP},
</if>
<if test="updateuserid != null" >
updateuserid = #{updateuserid,jdbcType=VARCHAR},
</if>
<if test="updatedate != null" >
updatedate = #{updatedate,jdbcType=TIMESTAMP},
</if>
<if test="msgid != null" >
msgId = #{msgid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.EmppSendUser" >
update tb_EMPP_EmppSendUser
set emppSendid = #{emppsendid,jdbcType=VARCHAR},
senduserid = #{senduserid,jdbcType=VARCHAR},
senddate = #{senddate,jdbcType=TIMESTAMP},
recuserid = #{recuserid,jdbcType=VARCHAR},
mobile = #{mobile,jdbcType=VARCHAR},
backdate = #{backdate,jdbcType=TIMESTAMP},
insertuserid = #{insertuserid,jdbcType=VARCHAR},
insertdate = #{insertdate,jdbcType=TIMESTAMP},
updateuserid = #{updateuserid,jdbcType=VARCHAR},
updatedate = #{updatedate,jdbcType=TIMESTAMP},
msgId = #{msgid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_EMPP_EmppSendUser
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_EMPP_EmppSendUser
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_EMPP_EmppSendUser
${where}
</delete>
</mapper>

View File

@ -0,0 +1,162 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.MsgAlarmlevelMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.MsgAlarmlevel" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="alarm_level" property="alarmLevel" jdbcType="VARCHAR" />
<result column="msgsend" property="msgsend" jdbcType="VARCHAR" />
<result column="smssend" property="smssend" jdbcType="VARCHAR" />
<result column="sendway" property="sendway" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="state" property="state" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="msgrole" property="msgrole" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, alarm_level, msgsend, smssend, sendway, remark, state, insuser, insdt, msgrole
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_alarmlevel
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE_alarmlevel
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.MsgAlarmlevel" >
insert into TB_MESSAGE_TYPE_alarmlevel (id, alarm_level, msgsend,
smssend, sendway, remark,
state, insuser, insdt,
msgrole)
values (#{id,jdbcType=VARCHAR}, #{alarmLevel,jdbcType=VARCHAR}, #{msgsend,jdbcType=VARCHAR},
#{smssend,jdbcType=VARCHAR}, #{sendway,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR},
#{state,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{msgrole,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.MsgAlarmlevel" >
insert into TB_MESSAGE_TYPE_alarmlevel
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="alarmLevel != null" >
alarm_level,
</if>
<if test="msgsend != null" >
msgsend,
</if>
<if test="smssend != null" >
smssend,
</if>
<if test="sendway != null" >
sendway,
</if>
<if test="remark != null" >
remark,
</if>
<if test="state != null" >
state,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="msgrole != null" >
msgrole,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="alarmLevel != null" >
#{alarmLevel,jdbcType=VARCHAR},
</if>
<if test="msgsend != null" >
#{msgsend,jdbcType=VARCHAR},
</if>
<if test="smssend != null" >
#{smssend,jdbcType=VARCHAR},
</if>
<if test="sendway != null" >
#{sendway,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="state != null" >
#{state,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="msgrole != null" >
#{msgrole,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.MsgAlarmlevel" >
update TB_MESSAGE_TYPE_alarmlevel
<set >
<if test="alarmLevel != null" >
alarm_level = #{alarmLevel,jdbcType=VARCHAR},
</if>
<if test="msgsend != null" >
msgsend = #{msgsend,jdbcType=VARCHAR},
</if>
<if test="smssend != null" >
smssend = #{smssend,jdbcType=VARCHAR},
</if>
<if test="sendway != null" >
sendway = #{sendway,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="state != null" >
state = #{state,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="msgrole != null" >
msgrole = #{msgrole,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.MsgAlarmlevel" >
update TB_MESSAGE_TYPE_alarmlevel
set alarm_level = #{alarmLevel,jdbcType=VARCHAR},
msgsend = #{msgsend,jdbcType=VARCHAR},
smssend = #{smssend,jdbcType=VARCHAR},
sendway = #{sendway,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
state = #{state,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
msgrole = #{msgrole,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_alarmlevel
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE_alarmlevel
${where}
</delete>
</mapper>

View File

@ -0,0 +1,474 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.MsgMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.Msg" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="suserid" property="suserid" jdbcType="VARCHAR" />
<result column="sdt" property="sdt" jdbcType="TIMESTAMP" />
<result column="url" property="url" jdbcType="VARCHAR" />
<result column="readflag" property="readflag" jdbcType="VARCHAR" />
<result column="content" property="content" jdbcType="VARCHAR" />
<result column="backid" property="backid" jdbcType="VARCHAR" />
<result column="typeid" property="typeid" jdbcType="VARCHAR" />
<result column="plansdt" property="plansdt" jdbcType="VARCHAR" />
<result column="plansdate" property="plansdate" jdbcType="TIMESTAMP" />
<result column="sendflag" property="sendflag" jdbcType="VARCHAR" />
<result column="delflag" property="delflag" jdbcType="VARCHAR" />
<result column="alerturl" property="alerturl" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="bizid" property="bizid" jdbcType="VARCHAR" />
<result column="issms" property="issms" jdbcType="VARCHAR" />
<result column="redflag" property="redflag" jdbcType="VARCHAR" />
<result column="sendview" property="sendview" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, pid, suserid, sdt, url, readflag, content, backid, typeid, plansdt, plansdate,
sendflag, delflag, alerturl, insuser, insdt, bizid,issms,redflag,sendview
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_MESSAGE
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.Msg" >
insert into TB_MESSAGE (id, pid, suserid,
sdt, url, readflag,
content, backid, typeid,
plansdt, plansdate, sendflag,
delflag, alerturl, insuser,
insdt, bizid,issms,redflag,sendview)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{suserid,jdbcType=VARCHAR},
#{sdt,jdbcType=TIMESTAMP}, #{url,jdbcType=VARCHAR}, #{readflag,jdbcType=VARCHAR},
#{content,jdbcType=VARCHAR}, #{backid,jdbcType=VARCHAR}, #{typeid,jdbcType=VARCHAR},
#{plansdt,jdbcType=VARCHAR}, #{plansdate,jdbcType=TIMESTAMP}, #{sendflag,jdbcType=VARCHAR},
#{delflag,jdbcType=VARCHAR}, #{alerturl,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{bizid,jdbcType=VARCHAR}, #{issms,jdbcType=VARCHAR},
#{redflag,jdbcType=VARCHAR}, #{sendview,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.Msg" >
insert into TB_MESSAGE
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="pid != null" >
pid,
</if>
<if test="suserid != null" >
suserid,
</if>
<if test="sdt != null" >
sdt,
</if>
<if test="url != null" >
url,
</if>
<if test="readflag != null" >
readflag,
</if>
<if test="content != null" >
content,
</if>
<if test="backid != null" >
backid,
</if>
<if test="typeid != null" >
typeid,
</if>
<if test="plansdt != null" >
plansdt,
</if>
<if test="plansdate != null" >
plansdate,
</if>
<if test="sendflag != null" >
sendflag,
</if>
<if test="delflag != null" >
delflag,
</if>
<if test="alerturl != null" >
alerturl,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="bizid != null" >
bizid,
</if>
<if test="issms != null" >
issms,
</if>
<if test="redflag != null" >
redflag,
</if>
<if test="sendview != null" >
sendview,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="suserid != null" >
#{suserid,jdbcType=VARCHAR},
</if>
<if test="sdt != null" >
#{sdt,jdbcType=TIMESTAMP},
</if>
<if test="url != null" >
#{url,jdbcType=VARCHAR},
</if>
<if test="readflag != null" >
#{readflag,jdbcType=VARCHAR},
</if>
<if test="content != null" >
#{content,jdbcType=VARCHAR},
</if>
<if test="backid != null" >
#{backid,jdbcType=VARCHAR},
</if>
<if test="typeid != null" >
#{typeid,jdbcType=VARCHAR},
</if>
<if test="plansdt != null" >
#{plansdt,jdbcType=VARCHAR},
</if>
<if test="plansdate != null" >
#{plansdate,jdbcType=TIMESTAMP},
</if>
<if test="sendflag != null" >
#{sendflag,jdbcType=VARCHAR},
</if>
<if test="delflag != null" >
#{delflag,jdbcType=VARCHAR},
</if>
<if test="alerturl != null" >
#{alerturl,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="bizid != null" >
#{bizid,jdbcType=VARCHAR},
</if>
<if test="issms != null" >
#{issms,jdbcType=VARCHAR},
</if>
<if test="redflag != null" >
#{redflag,jdbcType=VARCHAR},
</if>
<if test="sendview != null" >
#{sendview,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.Msg" >
update TB_MESSAGE
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="suserid != null" >
suserid = #{suserid,jdbcType=VARCHAR},
</if>
<if test="sdt != null" >
sdt = #{sdt,jdbcType=TIMESTAMP},
</if>
<if test="url != null" >
url = #{url,jdbcType=VARCHAR},
</if>
<if test="readflag != null" >
readflag = #{readflag,jdbcType=VARCHAR},
</if>
<if test="content != null" >
content = #{content,jdbcType=VARCHAR},
</if>
<if test="backid != null" >
backid = #{backid,jdbcType=VARCHAR},
</if>
<if test="typeid != null" >
typeid = #{typeid,jdbcType=VARCHAR},
</if>
<if test="plansdt != null" >
plansdt = #{plansdt,jdbcType=VARCHAR},
</if>
<if test="plansdate != null" >
plansdate = #{plansdate,jdbcType=TIMESTAMP},
</if>
<if test="sendflag != null" >
sendflag = #{sendflag,jdbcType=VARCHAR},
</if>
<if test="delflag != null" >
delflag = #{delflag,jdbcType=VARCHAR},
</if>
<if test="alerturl != null" >
alerturl = #{alerturl,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="bizid != null" >
bizid = #{bizid,jdbcType=VARCHAR},
</if>
<if test="issms != null" >
issms = #{issms,jdbcType=VARCHAR},
</if>
<if test="redflag != null" >
redflag = #{redflag,jdbcType=VARCHAR},
</if>
<if test="sendview != null" >
sendview = #{sendview,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.Msg" >
update TB_MESSAGE
set pid = #{pid,jdbcType=VARCHAR},
suserid = #{suserid,jdbcType=VARCHAR},
sdt = #{sdt,jdbcType=TIMESTAMP},
url = #{url,jdbcType=VARCHAR},
readflag = #{readflag,jdbcType=VARCHAR},
content = #{content,jdbcType=VARCHAR},
backid = #{backid,jdbcType=VARCHAR},
typeid = #{typeid,jdbcType=VARCHAR},
plansdt = #{plansdt,jdbcType=VARCHAR},
plansdate = #{plansdate,jdbcType=TIMESTAMP},
sendflag = #{sendflag,jdbcType=VARCHAR},
delflag = #{delflag,jdbcType=VARCHAR},
alerturl = #{alerturl,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
bizid = #{bizid,jdbcType=VARCHAR},
issms = #{issms,jdbcType=VARCHAR},
redflag = #{redflag,jdbcType=VARCHAR},
sendview = #{sendview,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_MESSAGE
${where}
</delete>
<select id="getMsgsendlist" resultMap="ClassResultMapsendlist" parameterType="java.lang.String">
SELECT
T.id as t_id,
T.name as t_typename,
U.id as u_id,
U.caption AS u_username,
M.id as m_id,
M.url as m_url,
M.suserid AS m_suserid,
M.sdt AS m_sdt,
M.content AS m_content,
M.typeid AS m_typeid,
M.insdt AS m_insdt,
M.issms AS m_issms,
M.pid AS m_pid,
M.redflag AS m_redflag,
M.sendview AS m_sendview
FROM TB_MESSAGE M
LEFT OUTER JOIN TB_User U ON M.suserid = U.id
LEFT OUTER JOIN TB_MESSAGE_TYPE T ON M.typeid = T.id
${where}
</select>
<select id="getMsgsend" resultMap="ClassResultMaprecv" parameterType="java.lang.String">
SELECT
T.id as t_id,
T.name as t_typename,
U.id as u_id,
U.caption AS u_username,
M.id as m_id,
M.url as m_url,
M.suserid AS m_suserid,
M.sdt AS m_sdt,
M.content AS m_content,
M.typeid AS m_typeid,
M.insdt AS m_insdt,
M.issms AS m_issms,
M.pid AS m_pid,
M.redflag AS m_redflag,
M.sendview AS m_sendview
FROM TB_MESSAGE M
LEFT OUTER JOIN TB_User U ON M.suserid = U.id
LEFT OUTER JOIN TB_MESSAGE_TYPE T ON M.typeid = T.id
${where}
</select>
<select id="getMsgrecv" resultMap="ClassResultMaprecv" parameterType="java.lang.String">
SELECT
T.id as t_id,
T.name as t_typename,
V.id as v_id,
V.status AS v_status,
V.masterid AS v_masterid,
V.delflag as v_delflag,
V.redflag as v_redflag,
V.unitid,
V.readtime,
U.id as u_id,
U.caption AS u_username,
M.id as m_id,
M.url as m_url,
M.suserid AS m_suserid,
M.sdt AS m_sdt,
M.content AS m_content,
M.typeid AS m_typeid,
M.insdt AS m_insdt,
M.issms AS m_issms,
M.pid AS m_pid,
M.redflag AS m_redflag,
M.sendview AS m_sendview
FROM TB_MESSAGE M
LEFT OUTER JOIN TB_MESSAGE_RECV V ON M.id = V.masterid
LEFT OUTER JOIN TB_User U ON M.suserid = U.id
LEFT OUTER JOIN TB_MESSAGE_TYPE T ON M.typeid = T.id
${where}
</select>
<!-- 获取实时表中的消息 -->
<select id="getMsgrecv_RU" resultMap="ClassResultMaprecv" parameterType="java.lang.String">
SELECT
T.id as t_id,
T.name as t_typename,
V.id as v_id,
V.status AS v_status,
V.masterid AS v_masterid,
V.delflag as v_delflag,
V.redflag as v_redflag,
V.unitid,
V.readtime,
U.id as u_id,
U.caption AS u_username,
M.id as m_id,
M.url as m_url,
M.suserid AS m_suserid,
M.sdt AS m_sdt,
M.content AS m_content,
M.typeid AS m_typeid,
M.insdt AS m_insdt,
M.issms AS m_issms,
M.pid AS m_pid,
M.redflag AS m_redflag,
M.sendview AS m_sendview
FROM TB_MESSAGE M
LEFT OUTER JOIN TB_MESSAGE_RECV_RU V ON M.id = V.masterid
LEFT OUTER JOIN TB_User U ON M.suserid = U.id
LEFT OUTER JOIN TB_MESSAGE_TYPE T ON M.typeid = T.id
${where}
</select>
<select id="getMsgrecvTop1" resultMap="ClassResultMaprecv" parameterType="java.lang.String">
SELECT Top 1
T.id as t_id,
T.name as t_typename,
V.id as v_id,
V.status AS v_status,
V.masterid AS v_masterid,
V.delflag as v_delflag,
V.redflag as v_redflag,
V.unitid,
V.readtime,
U.id as u_id,
U.caption AS u_username,
U.name as u_name,
M.id as m_id,
M.url as m_url,
M.suserid AS m_suserid,
M.sdt AS m_sdt,
M.content AS m_content,
M.typeid AS m_typeid,
M.issms AS m_issms,
M.pid AS m_pid,
M.redflag AS m_redflag,
M.sendview AS m_sendview
FROM TB_MESSAGE M
LEFT OUTER JOIN TB_MESSAGE_RECV V ON M.id = V.masterid
LEFT OUTER JOIN TB_User U ON M.suserid = U.id
LEFT OUTER JOIN TB_MESSAGE_TYPE T ON M.typeid = T.id
${where}
</select>
<resultMap id="ClassResultMapsendlist" type="com.sipai.entity.msg.Msg">
<id property="id" column="m_id" />
<result property="url" column="m_url"/>
<result property="suserid" column="m_suserid"/>
<result property="sdt" column="m_sdt"/>
<result property="content" column="m_content"/>
<result property="typeid" column="m_typeid"/>
<result property="insdt" column="m_insdt"/>
<result property="issms" column="m_issms"/>
<result property="redflag" column="m_redflag"/>
<result property="sendview" column="m_sendview"/>
<result property="pid" column="m_pid"/>
<association property="susername" resultMap="userResult" />
<association property="typename" resultMap="typeResult" />
</resultMap>
<resultMap id="ClassResultMaprecv" type="com.sipai.entity.msg.Msg">
<id property="id" column="m_id" />
<result property="url" column="m_url"/>
<result property="suserid" column="m_suserid"/>
<result property="sdt" column="m_sdt"/>
<result property="content" column="m_content"/>
<result property="typeid" column="m_typeid"/>
<result property="insdt" column="m_insdt"/>
<result property="issms" column="m_issms"/>
<result property="redflag" column="m_redflag"/>
<result property="sendview" column="m_sendview"/>
<result property="pid" column="m_pid"/>
<association property="susername" resultMap="userResult" />
<association property="typename" resultMap="typeResult" />
<collection property="mrecv" ofType="com.sipai.entity.msg.MsgRecv" >
<id property="id" column="v_id"/>
<result property="status" column="v_status"/>
<result property="masterid" column="v_masterid"/>
<result property="delflag" column="v_delflag"/>
<result property="unitid" column="unitid"/>
<result property="readtime" column="readtime"/>
<result property="redflag" column="v_redflag"/>
</collection>
</resultMap>
<resultMap id="userResult" type="com.sipai.entity.user.User">
<id property="id" column="u_id"/>
<result property="caption" column="u_username"/>
<result property="name" column="u_name"/>
</resultMap>
<resultMap id="typeResult" type="com.sipai.entity.msg.MsgType">
<id property="id" column="t_id"/>
<result property="name" column="t_typename"/>
</resultMap>
<update id="updateBySetAndWhere" parameterType="com.sipai.entity.msg.Msg" >
update TB_MESSAGE
${where}
</update>
</mapper>

View File

@ -0,0 +1,159 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.MsgRecvMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.MsgRecv" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="masterid" property="masterid" jdbcType="VARCHAR" />
<result column="unitid" property="unitid" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="readtime" property="readtime" jdbcType="TIMESTAMP" />
<result column="delflag" property="delflag" jdbcType="VARCHAR" />
<result column="redflag" property="redflag" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, masterid, unitid, status, readtime, delflag, insuser, insdt,redflag
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_RECV
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_MESSAGE_RECV
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.MsgRecv" >
insert into TB_MESSAGE_RECV (id, masterid, unitid,
status, readtime, delflag,
insuser, insdt,redflag)
values (#{id,jdbcType=VARCHAR}, #{masterid,jdbcType=VARCHAR}, #{unitid,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR}, #{readtime,jdbcType=TIMESTAMP}, #{delflag,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{redflag,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.MsgRecv" >
insert into TB_MESSAGE_RECV
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="masterid != null" >
masterid,
</if>
<if test="unitid != null" >
unitid,
</if>
<if test="status != null" >
status,
</if>
<if test="readtime != null" >
readtime,
</if>
<if test="delflag != null" >
delflag,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="redflag != null" >
redflag,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="masterid != null" >
#{masterid,jdbcType=VARCHAR},
</if>
<if test="unitid != null" >
#{unitid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="readtime != null" >
#{readtime,jdbcType=TIMESTAMP},
</if>
<if test="delflag != null" >
#{delflag,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="redflag != null" >
#{redflag,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.MsgRecv" >
update TB_MESSAGE_RECV
<set >
<if test="masterid != null" >
masterid = #{masterid,jdbcType=VARCHAR},
</if>
<if test="unitid != null" >
unitid = #{unitid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="readtime != null" >
readtime = #{readtime,jdbcType=TIMESTAMP},
</if>
<if test="delflag != null" >
delflag = #{delflag,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="redflag != null" >
redflag = #{redflag,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.MsgRecv" >
update TB_MESSAGE_RECV
set masterid = #{masterid,jdbcType=VARCHAR},
unitid = #{unitid,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
readtime = #{readtime,jdbcType=TIMESTAMP},
delflag = #{delflag,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
redflag = #{redflag,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_RECV
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_RECV
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_MESSAGE_RECV
${where}
</delete>
<update id="updateBySetAndWhere" parameterType="com.sipai.entity.msg.MsgRecv" >
update TB_MESSAGE_RECV
${where}
</update>
</mapper>

View File

@ -0,0 +1,109 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.MsgRoleMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.MsgRole" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="masterid" property="masterid" jdbcType="VARCHAR" />
<result column="roleid" property="roleid" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, masterid, roleid, insuser, insdt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_role
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE_role
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.MsgRole" >
insert into TB_MESSAGE_TYPE_role (id, masterid, roleid,
insuser, insdt)
values (#{id,jdbcType=VARCHAR}, #{masterid,jdbcType=VARCHAR}, #{roleid,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.MsgRole" >
insert into TB_MESSAGE_TYPE_role
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="masterid != null" >
masterid,
</if>
<if test="roleid != null" >
roleid,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="masterid != null" >
#{masterid,jdbcType=VARCHAR},
</if>
<if test="roleid != null" >
#{roleid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.MsgRole" >
update TB_MESSAGE_TYPE_role
<set >
<if test="masterid != null" >
masterid = #{masterid,jdbcType=VARCHAR},
</if>
<if test="roleid != null" >
roleid = #{roleid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.MsgRole" >
update TB_MESSAGE_TYPE_role
set masterid = #{masterid,jdbcType=VARCHAR},
roleid = #{roleid,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_role
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_role
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE_role
${where}
</delete>
</mapper>

View File

@ -0,0 +1,201 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.MsgTypeMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.MsgType" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="sendway" property="sendway" jdbcType="VARCHAR" />
<collection column="id" property="_roleid" jdbcType="VARCHAR" select="selectRoleid" />
<collection column="id" property="_msguserid" jdbcType="VARCHAR" select="selectMsguserid" />
<collection column="id" property="_smsuserid" jdbcType="VARCHAR" select="selectSmsuserid" />
</resultMap>
<select id="selectRoleid" parameterType="String" resultType="String">
select roleid from TB_MESSAGE_TYPE_role where masterid = #{id}
</select>
<select id="selectMsguserid" parameterType="String" resultType="String">
select userid from TB_MESSAGE_TYPE_msguser where masterid = #{id}
</select>
<select id="selectSmsuserid" parameterType="String" resultType="String">
select userid from TB_MESSAGE_TYPE_smsuser where masterid = #{id}
</select>
<sql id="Base_Column_List" >
id, name, insuser, insdt, pid, remark, status,sendway
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.MsgType" >
insert into TB_MESSAGE_TYPE (id, name, insuser,
insdt, pid, remark, status,sendway
)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP},#{pid,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR}, #{sendway,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.MsgType" >
insert into TB_MESSAGE_TYPE
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="name != null" >
name,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="pid != null" >
pid,
</if>
<if test="remark != null" >
remark,
</if>
<if test="status != null" >
status,
</if>
<if test="sendway != null" >
sendway,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="sendway != null" >
#{sendway,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.MsgType" >
update TB_MESSAGE_TYPE
<set >
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="sendway != null" >
sendway = #{sendway,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.MsgType" >
update TB_MESSAGE_TYPE
set name = #{name,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
pid = #{pid,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
sendway = #{sendway,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE
${where}
</delete>
<select id="getMsgType" resultMap="ClassResultMapMsgType" parameterType="java.lang.String">
SELECT
T.id as t_id,
T.name as t_typename,
T.pid,
T.status,
T.insuser,
T.insdt,
T.sendway,
T.remark,
R.id as r_id,
R.roleid as r_roleid,
M.id as m_id,
M.userid as m_userid,
S.id as s_id,
S.userid as s_userid
FROM TB_MESSAGE_TYPE T
LEFT OUTER JOIN TB_MESSAGE_TYPE_role R ON R.masterid = T.id
LEFT OUTER JOIN TB_MESSAGE_TYPE_msguser M ON M.masterid = T.id
LEFT OUTER JOIN TB_MESSAGE_TYPE_smsuser S ON S.masterid = T.id
${where}
</select>
<resultMap id="ClassResultMapMsgType" type="com.sipai.entity.msg.MsgType">
<id property="id" column="t_id" />
<result property="name" column="t_typename"/>
<result property="pid" column="pid"/>
<result property="status" column="status"/>
<result property="insuser" column="insuser"/>
<result property="insdt" column="insdt"/>
<result property="sendway" column="sendway"/>
<result property="remark" column="remark"/>
<collection property="role" ofType="com.sipai.entity.msg.MsgRole" >
<id property="id" column="r_id"/>
<result property="roleid" column="r_roleid"/>
</collection>
<collection property="msguser" ofType="com.sipai.entity.msg.Msguser" >
<id property="id" column="m_id"/>
<result property="userid" column="m_userid"/>
</collection>
<collection property="smsuser" ofType="com.sipai.entity.msg.Smsuser" >
<id property="id" column="s_id"/>
<result property="userid" column="s_userid"/>
</collection>
</resultMap>
</mapper>

View File

@ -0,0 +1,109 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.MsguserMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.Msguser" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="masterid" property="masterid" jdbcType="VARCHAR" />
<result column="userid" property="userid" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, masterid, userid, insuser, insdt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_msguser
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE_msguser
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.Msguser" >
insert into TB_MESSAGE_TYPE_msguser (id, masterid, userid,
insuser, insdt)
values (#{id,jdbcType=VARCHAR}, #{masterid,jdbcType=VARCHAR}, #{userid,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.Msguser" >
insert into TB_MESSAGE_TYPE_msguser
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="masterid != null" >
masterid,
</if>
<if test="userid != null" >
userid,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="masterid != null" >
#{masterid,jdbcType=VARCHAR},
</if>
<if test="userid != null" >
#{userid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.Msguser" >
update TB_MESSAGE_TYPE_msguser
<set >
<if test="masterid != null" >
masterid = #{masterid,jdbcType=VARCHAR},
</if>
<if test="userid != null" >
userid = #{userid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.Msguser" >
update TB_MESSAGE_TYPE_msguser
set masterid = #{masterid,jdbcType=VARCHAR},
userid = #{userid,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_msguser
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_msguser
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE_msguser
${where}
</delete>
</mapper>

View File

@ -0,0 +1,109 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="msg.SmsuserMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.msg.Smsuser" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="masterid" property="masterid" jdbcType="VARCHAR" />
<result column="userid" property="userid" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, masterid, userid, insuser, insdt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_smsuser
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE_smsuser
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.msg.Smsuser" >
insert into TB_MESSAGE_TYPE_smsuser (id, masterid, userid,
insuser, insdt)
values (#{id,jdbcType=VARCHAR}, #{masterid,jdbcType=VARCHAR}, #{userid,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.msg.Smsuser" >
insert into TB_MESSAGE_TYPE_smsuser
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="masterid != null" >
masterid,
</if>
<if test="userid != null" >
userid,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="masterid != null" >
#{masterid,jdbcType=VARCHAR},
</if>
<if test="userid != null" >
#{userid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.msg.Smsuser" >
update TB_MESSAGE_TYPE_smsuser
<set >
<if test="masterid != null" >
masterid = #{masterid,jdbcType=VARCHAR},
</if>
<if test="userid != null" >
userid = #{userid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.msg.Smsuser" >
update TB_MESSAGE_TYPE_smsuser
set masterid = #{masterid,jdbcType=VARCHAR},
userid = #{userid,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_smsuser
${where}
</select>
<select id="selectByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from TB_MESSAGE_TYPE_smsuser
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from TB_MESSAGE_TYPE_smsuser
${where}
</delete>
</mapper>

View File

@ -0,0 +1,570 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="plan.DailyPlanMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.DailyPlan">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="stdt" jdbcType="TIMESTAMP" property="stdt" />
<result column="eddt" jdbcType="TIMESTAMP" property="eddt" />
<result column="productNo" jdbcType="VARCHAR" property="productno" />
<result column="productName" jdbcType="VARCHAR" property="productname" />
<result column="lineid" jdbcType="VARCHAR" property="lineid" />
<result column="bomid" jdbcType="VARCHAR" property="bomid" />
<result column="dwgid" jdbcType="VARCHAR" property="dwgid" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="taskOrderID" jdbcType="VARCHAR" property="taskorderid" />
<result column="productionOrderNo" jdbcType="VARCHAR" property="productionorderno" />
<result column="productQuantity" jdbcType="VARCHAR" property="productquantity" />
<result column="finishedQuantity" jdbcType="VARCHAR" property="finishedquantity" />
<result column="status" jdbcType="VARCHAR" property="status" />
<result column="suspended" jdbcType="VARCHAR" property="suspended" />
<result column="taskchangedstatus" jdbcType="VARCHAR" property="taskchangedstatus" />
<result column="processrealid" jdbcType="VARCHAR" property="processrealid" />
<result column="plandt" jdbcType="TIMESTAMP" property="plandt" />
<result column="pid" jdbcType="VARCHAR" property="pid" />
<result column="porder" jdbcType="INTEGER" property="porder" />
<result column="workorderid" jdbcType="VARCHAR" property="workorderid" />
<result column="wfOrderId" jdbcType="VARCHAR" property="wforderid" />
</resultMap>
<sql id="Base_Column_List">
id, stdt, eddt, productNo, productName, lineid, bomid, dwgid, insuser, insdt, remark,
type, taskOrderID, productionOrderNo, productQuantity, finishedQuantity, status,
suspended, taskchangedstatus, processrealid, plandt, pid, porder, workorderid, wfOrderId
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_plan_day
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_plan_day
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.DailyPlan">
insert into tb_plan_day (id, stdt, eddt,
productNo, productName, lineid,
bomid, dwgid, insuser,
insdt, remark, type,
taskOrderID, productionOrderNo, productQuantity,
finishedQuantity, status, suspended,
taskchangedstatus, processrealid, plandt,
pid, porder, workorderid,
wfOrderId)
values (#{id,jdbcType=VARCHAR}, #{stdt,jdbcType=TIMESTAMP}, #{eddt,jdbcType=TIMESTAMP},
#{productno,jdbcType=VARCHAR}, #{productname,jdbcType=VARCHAR}, #{lineid,jdbcType=VARCHAR},
#{bomid,jdbcType=VARCHAR}, #{dwgid,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{remark,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR},
#{taskorderid,jdbcType=VARCHAR}, #{productionorderno,jdbcType=VARCHAR}, #{productquantity,jdbcType=VARCHAR},
#{finishedquantity,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR}, #{suspended,jdbcType=VARCHAR},
#{taskchangedstatus,jdbcType=VARCHAR}, #{processrealid,jdbcType=VARCHAR}, #{plandt,jdbcType=TIMESTAMP},
#{pid,jdbcType=VARCHAR}, #{porder,jdbcType=INTEGER}, #{workorderid,jdbcType=VARCHAR},
#{wforderid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.DailyPlan">
insert into tb_plan_day
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="stdt != null">
stdt,
</if>
<if test="eddt != null">
eddt,
</if>
<if test="productno != null">
productNo,
</if>
<if test="productname != null">
productName,
</if>
<if test="lineid != null">
lineid,
</if>
<if test="bomid != null">
bomid,
</if>
<if test="dwgid != null">
dwgid,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="remark != null">
remark,
</if>
<if test="type != null">
type,
</if>
<if test="taskorderid != null">
taskOrderID,
</if>
<if test="productionorderno != null">
productionOrderNo,
</if>
<if test="productquantity != null">
productQuantity,
</if>
<if test="finishedquantity != null">
finishedQuantity,
</if>
<if test="status != null">
status,
</if>
<if test="suspended != null">
suspended,
</if>
<if test="taskchangedstatus != null">
taskchangedstatus,
</if>
<if test="processrealid != null">
processrealid,
</if>
<if test="plandt != null">
plandt,
</if>
<if test="pid != null">
pid,
</if>
<if test="porder != null">
porder,
</if>
<if test="workorderid != null">
workorderid,
</if>
<if test="wforderid != null">
wfOrderId,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="stdt != null">
#{stdt,jdbcType=TIMESTAMP},
</if>
<if test="eddt != null">
#{eddt,jdbcType=TIMESTAMP},
</if>
<if test="productno != null">
#{productno,jdbcType=VARCHAR},
</if>
<if test="productname != null">
#{productname,jdbcType=VARCHAR},
</if>
<if test="lineid != null">
#{lineid,jdbcType=VARCHAR},
</if>
<if test="bomid != null">
#{bomid,jdbcType=VARCHAR},
</if>
<if test="dwgid != null">
#{dwgid,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="type != null">
#{type,jdbcType=VARCHAR},
</if>
<if test="taskorderid != null">
#{taskorderid,jdbcType=VARCHAR},
</if>
<if test="productionorderno != null">
#{productionorderno,jdbcType=VARCHAR},
</if>
<if test="productquantity != null">
#{productquantity,jdbcType=VARCHAR},
</if>
<if test="finishedquantity != null">
#{finishedquantity,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=VARCHAR},
</if>
<if test="suspended != null">
#{suspended,jdbcType=VARCHAR},
</if>
<if test="taskchangedstatus != null">
#{taskchangedstatus,jdbcType=VARCHAR},
</if>
<if test="processrealid != null">
#{processrealid,jdbcType=VARCHAR},
</if>
<if test="plandt != null">
#{plandt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null">
#{pid,jdbcType=VARCHAR},
</if>
<if test="porder != null">
#{porder,jdbcType=INTEGER},
</if>
<if test="workorderid != null">
#{workorderid,jdbcType=VARCHAR},
</if>
<if test="wforderid != null">
#{wforderid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.DailyPlan">
update tb_plan_day
<set>
<if test="stdt != null">
stdt = #{stdt,jdbcType=TIMESTAMP},
</if>
<if test="eddt != null">
eddt = #{eddt,jdbcType=TIMESTAMP},
</if>
<if test="productno != null">
productNo = #{productno,jdbcType=VARCHAR},
</if>
<if test="productname != null">
productName = #{productname,jdbcType=VARCHAR},
</if>
<if test="lineid != null">
lineid = #{lineid,jdbcType=VARCHAR},
</if>
<if test="bomid != null">
bomid = #{bomid,jdbcType=VARCHAR},
</if>
<if test="dwgid != null">
dwgid = #{dwgid,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="type != null">
type = #{type,jdbcType=VARCHAR},
</if>
<if test="taskorderid != null">
taskOrderID = #{taskorderid,jdbcType=VARCHAR},
</if>
<if test="productionorderno != null">
productionOrderNo = #{productionorderno,jdbcType=VARCHAR},
</if>
<if test="productquantity != null">
productQuantity = #{productquantity,jdbcType=VARCHAR},
</if>
<if test="finishedquantity != null">
finishedQuantity = #{finishedquantity,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=VARCHAR},
</if>
<if test="suspended != null">
suspended = #{suspended,jdbcType=VARCHAR},
</if>
<if test="taskchangedstatus != null">
taskchangedstatus = #{taskchangedstatus,jdbcType=VARCHAR},
</if>
<if test="processrealid != null">
processrealid = #{processrealid,jdbcType=VARCHAR},
</if>
<if test="plandt != null">
plandt = #{plandt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null">
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="porder != null">
porder = #{porder,jdbcType=INTEGER},
</if>
<if test="workorderid != null">
workorderid = #{workorderid,jdbcType=VARCHAR},
</if>
<if test="wforderid != null">
wfOrderId = #{wforderid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.DailyPlan">
update tb_plan_day
set stdt = #{stdt,jdbcType=TIMESTAMP},
eddt = #{eddt,jdbcType=TIMESTAMP},
productNo = #{productno,jdbcType=VARCHAR},
productName = #{productname,jdbcType=VARCHAR},
lineid = #{lineid,jdbcType=VARCHAR},
bomid = #{bomid,jdbcType=VARCHAR},
dwgid = #{dwgid,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
remark = #{remark,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
taskOrderID = #{taskorderid,jdbcType=VARCHAR},
productionOrderNo = #{productionorderno,jdbcType=VARCHAR},
productQuantity = #{productquantity,jdbcType=VARCHAR},
finishedQuantity = #{finishedquantity,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
suspended = #{suspended,jdbcType=VARCHAR},
taskchangedstatus = #{taskchangedstatus,jdbcType=VARCHAR},
processrealid = #{processrealid,jdbcType=VARCHAR},
plandt = #{plandt,jdbcType=TIMESTAMP},
pid = #{pid,jdbcType=VARCHAR},
porder = #{porder,jdbcType=INTEGER},
workorderid = #{workorderid,jdbcType=VARCHAR},
wfOrderId = #{wforderid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_plan_day
${where}
</select>
<select id="selectByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_plan_day
${where}
</select>
<select id="selectValueBySql" parameterType="java.lang.String" resultMap="BaseResultMap">
${sql}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_plan_day
${where}
</delete>
<select id="getDailyPlanlist" parameterType="java.lang.String" resultMap="ClassResultMapDailyPlanlist">
SELECT
P.id as p_id,
P.stdt,
P.eddt,
P.productNo,
P.productName,
P.lineid,
P.bomid,
P.dwgid,
P.insuser as p_insuser,
P.insdt as p_insdt,
P.remark as p_remark,
P.type as p_type,
P.taskOrderID as p_taskOrderID,
P.productionOrderNo,
P.productQuantity,
P.finishedQuantity,
P.status as p_status,
P.suspended as p_delflag,
P.taskchangedstatus,
P.processrealid,
P.pid as p_pid,
P.porder as p_porder,
S.id as s_id,
S.insuser as s_insuser,
S.insdt as s_insdt,
S.SalesOrderNo,
S.productid,
S.productNum,
s.OrderCreateDate,
S.OrderFinishDate,
I.id as i_id,
I.materialname,
R.name as r_name
FROM tb_plan_day P
LEFT OUTER JOIN TB_material_SalesOrderProduct S ON S.id = P.taskOrderID
LEFT OUTER JOIN tb_material_info I ON I.id = S.productid
LEFT OUTER JOIN tb_process_real R ON R.id = P.processrealid
${where}
</select>
<resultMap id="ClassResultMapDailyPlanlist" type="com.sipai.entity.plan.DailyPlan">
<id column="p_id" property="id" />
<result column="stdt" property="stdt" />
<result column="eddt" property="eddt" />
<result column="productNo" property="productno" />
<result column="productName" property="productname" />
<result column="lineid" property="lineid" />
<result column="bomid" property="bomid" />
<result column="dwgid" property="dwgid" />
<result column="p_insuser" property="insuser" />
<result column="p_insdt" property="insdt" />
<result column="p_remark" property="remark" />
<result column="p_type" property="type" />
<result column="p_taskOrderID" property="taskorderid" />
<result column="productionOrderNo" property="productionorderno" />
<result column="productQuantity" property="productquantity" />
<result column="finishedQuantity" property="finishedquantity" />
<result column="p_status" property="status" />
<result column="p_delflag" property="suspended" />
<result column="taskchangedstatus" property="taskchangedstatus" />
<result column="processrealid" property="processrealid" />
<result column="p_pid" property="pid" />
<result column="p_porder" property="porder" />
<result column="r_name" property="processrealname" />
<association property="salesorderproduct" resultMap="sopResult" />
<association javaType="com.sipai.entity.material.MaterialInfo" property="product">
<id column="i_id" property="id" />
<result column="materialname" property="materialname" />
</association>
</resultMap>
<select id="getDailyPlan" parameterType="java.lang.String" resultMap="ClassResultMapDailyPlan">
SELECT
P.id as p_id,
P.stdt,
P.eddt,
P.productNo,
P.productName,
P.lineid,
P.bomid,
P.dwgid,
P.insuser as p_insuser,
P.insdt as p_insdt,
P.remark as p_remark,
P.type as p_type,
P.taskOrderID as p_taskOrderID,
P.productionOrderNo,
P.productQuantity,
P.finishedQuantity,
P.status as p_status,
P.suspended as p_delflag,
P.taskchangedstatus,
P.processrealid,
P.pid as p_pid,
P.porder as p_porder,
S.id as s_id,
S.insuser as s_insuser,
S.insdt as s_insdt,
S.SalesOrderNo,
S.productid,
S.productNum,
s.OrderCreateDate,
S.OrderFinishDate,
D.id as d_id,
D.ProductUId,
D.productionorderno as d_productionorderno,
D.workorderid as d_workorderid,
O.id as o_id,
O.wfOrderid as o_wfOrderid,
I.id as i_id,
I.materialname,
R.name as r_name
FROM tb_plan_day P
LEFT OUTER JOIN TB_material_SalesOrderProduct S ON S.id = P.taskOrderID
LEFT OUTER JOIN tb_material_info I ON I.id = S.productid
LEFT OUTER JOIN TB_material_OrderProductDetail_connect C ON C.planid =P.id
LEFT OUTER JOIN TB_material_OrderProductDetail D ON D.id = C.productdetailid
LEFT OUTER JOIN tb_work_order O ON (O.id = D.workorderid and O.status!='0')
LEFT OUTER JOIN tb_process_real R ON R.id = P.processrealid
${where}
</select>
<select id="selectLine" parameterType="String" resultType="com.sipai.entity.work.Line">
select tb_work_line.* from tb_work_line
where tb_work_line.id = #{lineid}
</select>
<resultMap id="ClassResultMapDailyPlan" type="com.sipai.entity.plan.DailyPlan">
<id column="p_id" property="id" />
<result column="stdt" property="stdt" />
<result column="eddt" property="eddt" />
<result column="productNo" property="productno" />
<result column="productName" property="productname" />
<result column="lineid" property="lineid" />
<result column="bomid" property="bomid" />
<result column="dwgid" property="dwgid" />
<result column="p_insuser" property="insuser" />
<result column="p_insdt" property="insdt" />
<result column="p_remark" property="remark" />
<result column="p_type" property="type" />
<result column="p_taskOrderID" property="taskorderid" />
<result column="productionOrderNo" property="productionorderno" />
<result column="productQuantity" property="productquantity" />
<result column="finishedQuantity" property="finishedquantity" />
<result column="p_status" property="status" />
<result column="p_delflag" property="suspended" />
<result column="taskchangedstatus" property="taskchangedstatus" />
<result column="processrealid" property="processrealid" />
<result column="p_pid" property="pid" />
<result column="p_porder" property="porder" />
<result column="r_name" property="processrealname" />
<association property="salesorderproduct" resultMap="sopResult" />
<association javaType="com.sipai.entity.material.MaterialInfo" property="product">
<id column="i_id" property="id" />
<result column="materialname" property="materialname" />
</association>
<association column="lineid" jdbcType="VARCHAR" property="line" select="selectLine" />
<collection ofType="com.sipai.entity.material.OrderProductDetail" property="orderproductdetail">
<id column="d_id" property="id" />
<result column="ProductUId" property="productuid" />
<result column="d_productionorderno" property="productionorderno" />
<result column="d_workorderid" property="workorderid" />
<association javaType="com.sipai.entity.work.WorkOrder" property="workorder">
<id column="o_id" property="id" />
<result column="o_wfOrderid" property="wforderid" />
</association>
</collection>
</resultMap>
<resultMap id="sopResult" type="com.sipai.entity.material.SalesOrderProduct">
<id column="s_id" property="id" />
<result column="s_insuser" property="insuser" />
<result column="s_insdt" property="insdt" />
<result column="SalesOrderNo" property="salesorderno" />
<result column="productid" property="productid" />
<result column="productNum" property="productnum" />
<result column="OrderCreateDate" property="ordercreatedate" />
<result column="OrderFinishDate" property="orderfinishdate" />
</resultMap>
<update id="updateBySetAndWhere" parameterType="com.sipai.entity.plan.DailyPlan">
update tb_plan_day
${where}
</update>
<select id="getSOPByPlan" parameterType="java.lang.String" resultMap="ResultMapSOPByPlan">
SELECT
S.id as s_id,
S.insuser as s_insuser,
S.insdt as s_insdt,
S.SalesOrderNo,
S.productid,
S.productNum,
s.OrderCreateDate,
S.OrderFinishDate,
I.id as i_id,
I.materialname
FROM TB_material_SalesOrderProduct S
LEFT OUTER JOIN tb_material_info I ON I.id = S.productid
${where}
</select>
<resultMap id="ResultMapSOPByPlan" type="com.sipai.entity.material.SalesOrderProduct">
<id column="s_id" property="id" />
<result column="s_insuser" property="insuser" />
<result column="s_insdt" property="insdt" />
<result column="SalesOrderNo" property="salesorderno" />
<result column="productid" property="productid" />
<result column="productNum" property="productnum" />
<result column="OrderCreateDate" property="ordercreatedate" />
<result column="OrderFinishDate" property="orderfinishdate" />
<association javaType="com.sipai.entity.material.MaterialInfo" property="product">
<id column="i_id" property="id" />
<result column="materialname" property="materialname" />
</association>
</resultMap>
<select id="getProcessIds4ComboByTaskOrderId" parameterType="java.lang.String" resultType="hashmap">
SELECT processrealid processid
FROM tb_plan_day
where id in
(select MAX(id) from tb_plan_day
where taskOrderID= #{taskorderid}
group by processrealid )
</select>
</mapper>

View File

@ -0,0 +1,200 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="plan.DailyPlanSummaryMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.DailyPlanSummary">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="plandt" jdbcType="TIMESTAMP" property="plandt" />
<result column="auditor" jdbcType="VARCHAR" property="auditor" />
<result column="auditdate" jdbcType="TIMESTAMP" property="auditdate" />
<result column="status" jdbcType="VARCHAR" property="status" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="modifier" jdbcType="VARCHAR" property="modifier" />
<result column="modifydt" jdbcType="TIMESTAMP" property="modifydt" />
<result column="insertpid" jdbcType="VARCHAR" property="insertpid" />
<association column="modifier" property="_modifiername" jdbcType="VARCHAR" select="selectModifier"/>
</resultMap>
<select id="selectModifier" parameterType="String" resultType="String">
select caption from tb_user where id = #{modifier}
</select>
<sql id="Base_Column_List">
id, insuser, insdt, plandt, auditor, auditdate, status, name, remark, modifier, modifydt,insertpid
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_plan_dailyplanSummary
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from TB_plan_dailyplanSummary
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.DailyPlanSummary">
insert into TB_plan_dailyplanSummary (id, insuser, insdt,
plandt, auditor, auditdate,
status, name, remark,
modifier, modifydt,insertpid)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{plandt,jdbcType=TIMESTAMP}, #{auditor,jdbcType=VARCHAR}, #{auditdate,jdbcType=TIMESTAMP},
#{status,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR},
#{modifier,jdbcType=VARCHAR}, #{modifydt,jdbcType=TIMESTAMP}, #{insertpid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.DailyPlanSummary">
insert into TB_plan_dailyplanSummary
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="plandt != null">
plandt,
</if>
<if test="auditor != null">
auditor,
</if>
<if test="auditdate != null">
auditdate,
</if>
<if test="status != null">
status,
</if>
<if test="name != null">
name,
</if>
<if test="remark != null">
remark,
</if>
<if test="modifier != null">
modifier,
</if>
<if test="modifydt != null">
modifydt,
</if>
<if test="insertpid != null">
insertpid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plandt != null">
#{plandt,jdbcType=TIMESTAMP},
</if>
<if test="auditor != null">
#{auditor,jdbcType=VARCHAR},
</if>
<if test="auditdate != null">
#{auditdate,jdbcType=TIMESTAMP},
</if>
<if test="status != null">
#{status,jdbcType=VARCHAR},
</if>
<if test="name != null">
#{name,jdbcType=VARCHAR},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="modifier != null">
#{modifier,jdbcType=VARCHAR},
</if>
<if test="modifydt != null">
#{modifydt,jdbcType=TIMESTAMP},
</if>
<if test="insertpid != null">
#{insertpid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.DailyPlanSummary">
update TB_plan_dailyplanSummary
<set>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="plandt != null">
plandt = #{plandt,jdbcType=TIMESTAMP},
</if>
<if test="auditor != null">
auditor = #{auditor,jdbcType=VARCHAR},
</if>
<if test="auditdate != null">
auditdate = #{auditdate,jdbcType=TIMESTAMP},
</if>
<if test="status != null">
status = #{status,jdbcType=VARCHAR},
</if>
<if test="name != null">
name = #{name,jdbcType=VARCHAR},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="modifier != null">
modifier = #{modifier,jdbcType=VARCHAR},
</if>
<if test="modifydt != null">
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
<if test="insertpid != null">
insertpid = #{insertpid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.DailyPlanSummary">
update TB_plan_dailyplanSummary
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
plandt = #{plandt,jdbcType=TIMESTAMP},
auditor = #{auditor,jdbcType=VARCHAR},
auditdate = #{auditdate,jdbcType=TIMESTAMP},
status = #{status,jdbcType=VARCHAR},
name = #{name,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
modifier = #{modifier,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP},
insertpid = #{insertpid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_plan_dailyplanSummary
${where}
</select>
<select id="selectByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from TB_plan_dailyplanSummary
${where}
</select>
<select id="selectValueBySql" parameterType="java.lang.String" resultMap="BaseResultMap">
${sql}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from TB_plan_dailyplanSummary
${where}
</delete>
</mapper>

View File

@ -0,0 +1,214 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="plan.DailyPlanSummaryMaterialMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.DailyPlanSummaryMaterial" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="planid" property="planid" jdbcType="VARCHAR" />
<result column="workstationid" property="workstationid" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="amount" property="amount" jdbcType="DOUBLE" />
<result column="revokeamount" property="revokeamount" jdbcType="DOUBLE" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, planid, workstationid, materialid, amount, revokeamount, remark, insuser, insdt,
modify, modifydt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_material
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_plan_material
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.DailyPlanSummaryMaterial" >
insert into tb_plan_material (id, planid, workstationid,
materialid, amount, revokeamount,
remark, insuser, insdt,
modify, modifydt)
values (#{id,jdbcType=VARCHAR}, #{planid,jdbcType=VARCHAR}, #{workstationid,jdbcType=VARCHAR},
#{materialid,jdbcType=VARCHAR}, #{amount,jdbcType=DOUBLE}, #{revokeamount,jdbcType=DOUBLE},
#{remark,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{modify,jdbcType=VARCHAR}, #{modifydt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.DailyPlanSummaryMaterial" >
insert into tb_plan_material
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="planid != null" >
planid,
</if>
<if test="workstationid != null" >
workstationid,
</if>
<if test="materialid != null" >
materialid,
</if>
<if test="amount != null" >
amount,
</if>
<if test="revokeamount != null" >
revokeamount,
</if>
<if test="remark != null" >
remark,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="planid != null" >
#{planid,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
#{workstationid,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
#{materialid,jdbcType=VARCHAR},
</if>
<if test="amount != null" >
#{amount,jdbcType=DOUBLE},
</if>
<if test="revokeamount != null" >
#{revokeamount,jdbcType=DOUBLE},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.DailyPlanSummaryMaterial" >
update tb_plan_material
<set >
<if test="planid != null" >
planid = #{planid,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
workstationid = #{workstationid,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="amount != null" >
amount = #{amount,jdbcType=DOUBLE},
</if>
<if test="revokeamount != null" >
revokeamount = #{revokeamount,jdbcType=DOUBLE},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.DailyPlanSummaryMaterial" >
update tb_plan_material
set planid = #{planid,jdbcType=VARCHAR},
workstationid = #{workstationid,jdbcType=VARCHAR},
materialid = #{materialid,jdbcType=VARCHAR},
amount = #{amount,jdbcType=DOUBLE},
revokeamount = #{revokeamount,jdbcType=DOUBLE},
remark = #{remark,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="getDPSMaterial" resultMap="ClassResultMapDPSM" parameterType="java.lang.String">
SELECT
M.id as m_id,
M.planid,
M.workstationid as m_workstationid,
M.materialid as m_materialid,
M.amount as m_amount,
M.revokeamount as m_revokeamount,
M.remark as m_remark,
M.insuser as m_insuser,
M.insdt as m_insdt,
M.modify as m_modify,
M.modifydt as m_modifydt,
I.id as i_id,
I.materialcode as i_materialcode,
I.materialname as i_materialname,
I.unit as i_unit,
S.id as s_id,
S.serial as s_serial,
S.name as s_name
FROM tb_plan_material M
LEFT OUTER JOIN tb_material_info I ON I.id = M.materialid
LEFT OUTER JOIN tb_work_workstation S ON S.id = M.workstationid
${where}
</select>
<resultMap id="ClassResultMapDPSM" type="com.sipai.entity.plan.DailyPlanSummaryMaterial">
<id property="id" column="m_id" />
<result property="planid" column="planid"/>
<result property="workstationid" column="m_workstationid"/>
<result property="materialid" column="m_materialid"/>
<result property="amount" column="m_amount"/>
<result property="revokeamount" column="m_revokeamount"/>
<result property="remark" column="m_remark"/>
<result property="insuser" column="m_insuser"/>
<result property="insdt" column="m_insdt"/>
<result property="modify" column="m_modify"/>
<result property="modifydt" column="m_modifydt"/>
<association property="materialinfo" javaType="com.sipai.entity.material.MaterialInfo" >
<id property="id" column="i_id"/>
<result property="materialname" column="i_materialname"/>
<result property="materialcode" column="i_materialcode"/>
<result property="unit" column="i_unit"/>
</association>
<association property="workstation" javaType="com.sipai.entity.work.Workstation" >
<id property="id" column="s_id"/>
<result property="serial" column="s_serial"/>
<result property="name" column="s_name"/>
</association>
</resultMap>
</mapper>

View File

@ -0,0 +1,275 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="plan.DailyPlanTaskDemandMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.DailyPlanTaskDemand">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="planid" jdbcType="VARCHAR" property="planid" />
<result column="processid" jdbcType="VARCHAR" property="processid" />
<result column="taskcode" jdbcType="VARCHAR" property="taskcode" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="preyield" jdbcType="DOUBLE" property="preyield" />
<result column="actyield" jdbcType="DOUBLE" property="actyield" />
<result column="preamount" jdbcType="DOUBLE" property="preamount" />
<result column="actamount" jdbcType="DOUBLE" property="actamount" />
<result column="unit" jdbcType="VARCHAR" property="unit" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="prodtaskid" jdbcType="VARCHAR" property="prodtaskid" />
<result column="yieldreason" jdbcType="VARCHAR" property="yieldreason" />
<result column="amountreason" jdbcType="VARCHAR" property="amountreason" />
<result column="status" jdbcType="VARCHAR" property="status" />
<result column="_taskName" jdbcType="VARCHAR" property="_taskName" />
<result column="reportuser" jdbcType="VARCHAR" property="reportuser" />
<result column="handleuser" jdbcType="VARCHAR" property="handleuser" />
</resultMap>
<sql id="Base_Column_List">
id, planid, processid, taskcode, insuser, insdt, preyield, actyield, preamount, actamount,
unit, remark, prodtaskid, yieldreason, amountreason, status,reportuser,handleuser
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_plan_taskdemand
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_plan_taskdemand
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.DailyPlanTaskDemand">
insert into tb_plan_taskdemand (id, planid, processid,
taskcode, insuser, insdt,
preyield, actyield, preamount,
actamount, unit, remark,
prodtaskid, yieldreason, amountreason,reportuser,handleuser,
status)
values (#{id,jdbcType=VARCHAR}, #{planid,jdbcType=VARCHAR}, #{processid,jdbcType=VARCHAR},
#{taskcode,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{preyield,jdbcType=DOUBLE}, #{actyield,jdbcType=DOUBLE}, #{preamount,jdbcType=DOUBLE},
#{actamount,jdbcType=DOUBLE}, #{unit,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR},
#{prodtaskid,jdbcType=VARCHAR}, #{yieldreason,jdbcType=VARCHAR}, #{amountreason,jdbcType=VARCHAR},#{reportuser,jdbcType=VARCHAR},#{handleuser,jdbcType=VARCHAR},
#{status,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.DailyPlanTaskDemand">
insert into tb_plan_taskdemand
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="planid != null">
planid,
</if>
<if test="processid != null">
processid,
</if>
<if test="taskcode != null">
taskcode,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="preyield != null">
preyield,
</if>
<if test="actyield != null">
actyield,
</if>
<if test="preamount != null">
preamount,
</if>
<if test="actamount != null">
actamount,
</if>
<if test="unit != null">
unit,
</if>
<if test="remark != null">
remark,
</if>
<if test="prodtaskid != null">
prodtaskid,
</if>
<if test="yieldreason != null">
yieldreason,
</if>
<if test="amountreason != null">
amountreason,
</if>
<if test="status != null">
status,
</if>
<if test="reportuser != null">
reportuser,
</if>
<if test="handleuser != null">
handleuser,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="planid != null">
#{planid,jdbcType=VARCHAR},
</if>
<if test="processid != null">
#{processid,jdbcType=VARCHAR},
</if>
<if test="taskcode != null">
#{taskcode,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="preyield != null">
#{preyield,jdbcType=DOUBLE},
</if>
<if test="actyield != null">
#{actyield,jdbcType=DOUBLE},
</if>
<if test="preamount != null">
#{preamount,jdbcType=DOUBLE},
</if>
<if test="actamount != null">
#{actamount,jdbcType=DOUBLE},
</if>
<if test="unit != null">
#{unit,jdbcType=VARCHAR},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="prodtaskid != null">
#{prodtaskid,jdbcType=VARCHAR},
</if>
<if test="yieldreason != null">
#{yieldreason,jdbcType=VARCHAR},
</if>
<if test="amountreason != null">
#{amountreason,jdbcType=VARCHAR},
</if>
<if test="status != null">
#{status,jdbcType=VARCHAR},
</if>
<if test="reportuser != null">
#{reportuser,jdbcType=VARCHAR},
</if>
<if test="handleuser != null">
#{handleuser,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.DailyPlanTaskDemand">
update tb_plan_taskdemand
<set>
<if test="planid != null">
planid = #{planid,jdbcType=VARCHAR},
</if>
<if test="processid != null">
processid = #{processid,jdbcType=VARCHAR},
</if>
<if test="taskcode != null">
taskcode = #{taskcode,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="preyield != null">
preyield = #{preyield,jdbcType=DOUBLE},
</if>
<if test="actyield != null">
actyield = #{actyield,jdbcType=DOUBLE},
</if>
<if test="preamount != null">
preamount = #{preamount,jdbcType=DOUBLE},
</if>
<if test="actamount != null">
actamount = #{actamount,jdbcType=DOUBLE},
</if>
<if test="unit != null">
unit = #{unit,jdbcType=VARCHAR},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="prodtaskid != null">
prodtaskid = #{prodtaskid,jdbcType=VARCHAR},
</if>
<if test="yieldreason != null">
yieldreason = #{yieldreason,jdbcType=VARCHAR},
</if>
<if test="amountreason != null">
amountreason = #{amountreason,jdbcType=VARCHAR},
</if>
<if test="status != null">
status = #{status,jdbcType=VARCHAR},
</if>
<if test="reportuser != null">
reportuser = #{reportuser,jdbcType=VARCHAR},
</if>
<if test="handleuser != null">
handleuser = #{handleuser,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.DailyPlanTaskDemand">
update tb_plan_taskdemand
set planid = #{planid,jdbcType=VARCHAR},
processid = #{processid,jdbcType=VARCHAR},
taskcode = #{taskcode,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
preyield = #{preyield,jdbcType=DOUBLE},
actyield = #{actyield,jdbcType=DOUBLE},
preamount = #{preamount,jdbcType=DOUBLE},
actamount = #{actamount,jdbcType=DOUBLE},
unit = #{unit,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
prodtaskid = #{prodtaskid,jdbcType=VARCHAR},
yieldreason = #{yieldreason,jdbcType=VARCHAR},
amountreason = #{amountreason,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
handleuser = #{handleuser,jdbcType=VARCHAR},
reportuser = #{reportuser,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_plan_taskdemand
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from
tb_plan_taskdemand
${where}
</delete>
<select id="sumAmountByProdTaskId" parameterType="java.lang.String" resultType="java.lang.String">
select sum(case when actamount is not null then actamount else preamount end) as preamounts
from tb_plan_taskdemand
where prodtaskid=
'${where}'
</select>
<!-- 获取日计划工序对比结果 -->
<select id="getDailyPLanAnalysis" parameterType="java.lang.String" resultMap="BaseResultMap">
select td.*,tp.procedurename as _taskName FROM(SELECT
taskcode,SUM(preamount) as preamount
FROM tb_plan_taskdemand
${where}
group by taskcode) td
left join tb_process_task_procedure tp on td.taskcode=tp.procedurecode
</select>
</mapper>

View File

@ -0,0 +1,252 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="plan.DeliverDetailMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.DeliverDetail" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="planamount" property="planamount" jdbcType="DOUBLE" />
<result column="deliveramount" property="deliveramount" jdbcType="DOUBLE" />
<result column="boxnumber" property="boxnumber" jdbcType="VARCHAR" />
<result column="boxname" property="boxname" jdbcType="VARCHAR" />
<result column="deliverst" property="deliverst" jdbcType="INTEGER" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<association column="materialid" property="materialInfo" jdbcType="VARCHAR" select="selectMaterialInfo"/>
</resultMap>
<sql id="Base_Column_List" >
id, pid, materialid, planamount, deliveramount, boxnumber, boxname, deliverst, remark,
insuser, insdt, modify, modifydt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_material_deliver_detail
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="selectMaterialInfo" parameterType="String" resultType="com.sipai.entity.material.MaterialInfo">
select * from tb_material_info where id = #{materialid}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_plan_material_deliver_detail
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.DeliverDetail" >
insert into tb_plan_material_deliver_detail (id, pid, materialid,
planamount, deliveramount, boxnumber,
boxname, deliverst, remark,
insuser, insdt, modify,
modifydt)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{materialid,jdbcType=VARCHAR},
#{planamount,jdbcType=DOUBLE}, #{deliveramount,jdbcType=DOUBLE}, #{boxnumber,jdbcType=VARCHAR},
#{boxname,jdbcType=VARCHAR}, #{deliverst,jdbcType=INTEGER}, #{remark,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{modify,jdbcType=VARCHAR},
#{modifydt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.DeliverDetail" >
insert into tb_plan_material_deliver_detail
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="pid != null" >
pid,
</if>
<if test="materialid != null" >
materialid,
</if>
<if test="planamount != null" >
planamount,
</if>
<if test="deliveramount != null" >
deliveramount,
</if>
<if test="boxnumber != null" >
boxnumber,
</if>
<if test="boxname != null" >
boxname,
</if>
<if test="deliverst != null" >
deliverst,
</if>
<if test="remark != null" >
remark,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
#{materialid,jdbcType=VARCHAR},
</if>
<if test="planamount != null" >
#{planamount,jdbcType=DOUBLE},
</if>
<if test="deliveramount != null" >
#{deliveramount,jdbcType=DOUBLE},
</if>
<if test="boxnumber != null" >
#{boxnumber,jdbcType=VARCHAR},
</if>
<if test="boxname != null" >
#{boxname,jdbcType=VARCHAR},
</if>
<if test="deliverst != null" >
#{deliverst,jdbcType=INTEGER},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.DeliverDetail" >
update tb_plan_material_deliver_detail
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="planamount != null" >
planamount = #{planamount,jdbcType=DOUBLE},
</if>
<if test="deliveramount != null" >
deliveramount = #{deliveramount,jdbcType=DOUBLE},
</if>
<if test="boxnumber != null" >
boxnumber = #{boxnumber,jdbcType=VARCHAR},
</if>
<if test="boxname != null" >
boxname = #{boxname,jdbcType=VARCHAR},
</if>
<if test="deliverst != null" >
deliverst = #{deliverst,jdbcType=INTEGER},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.DeliverDetail" >
update tb_plan_material_deliver_detail
set pid = #{pid,jdbcType=VARCHAR},
materialid = #{materialid,jdbcType=VARCHAR},
planamount = #{planamount,jdbcType=DOUBLE},
deliveramount = #{deliveramount,jdbcType=DOUBLE},
boxnumber = #{boxnumber,jdbcType=VARCHAR},
boxname = #{boxname,jdbcType=VARCHAR},
deliverst = #{deliverst,jdbcType=INTEGER},
remark = #{remark,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_material_deliver_detail
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_plan_material_deliver_detail
${where}
</delete>
<select id="getDeliverDetail" resultMap="DeliverDetailMap" parameterType="java.lang.String">
select d.*,
m.id as m_id,
m.materialcode as m_materialcode,
m.materialname as m_materialname,
m.unit as m_unit
from tb_plan_material_deliver_detail d
left join tb_material_info m on m.id=d.materialid
${where}
</select>
<resultMap id="DeliverDetailMap" type="com.sipai.entity.plan.DeliverDetail">
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="planamount" property="planamount" jdbcType="DOUBLE" />
<result column="deliveramount" property="deliveramount" jdbcType="DOUBLE" />
<result column="boxnumber" property="boxnumber" jdbcType="VARCHAR" />
<result column="boxname" property="boxname" jdbcType="VARCHAR" />
<result column="deliverst" property="deliverst" jdbcType="INTEGER" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<association property="materialInfo" resultMap="materialInfoResult"/>
</resultMap>
<resultMap id="materialInfoResult" type="com.sipai.entity.material.MaterialInfo">
<id property="id" column="m_id"/>
<result property="materialcode" column="m_materialcode"/>
<result property="materialname" column="m_materialname"/>
<result property="unit" column="m_unit"/>
</resultMap>
<select id="getPlanedAmount" resultMap="BaseResultMap" parameterType="java.lang.String" >
select detail.materialid,SUM(case when detail.planamount is null then 0 else detail.planamount end) as planamount
from tb_plan_material_deliver_detail detail
left join tb_plan_material_deliver deliver on deliver.id=detail.pid
${where}
group by materialid
</select>
<select id="getMaterialDeliverStatus" resultMap="BaseResultMap" parameterType="java.lang.String" >
select (case
when SUM(case when deliverst is null then 0 else deliverst end)=0 then 0
when SUM(case when deliverst is null then 0 else deliverst end)=COUNT(id) then 1
else 2 end) as deliverst
from tb_plan_material_deliver_detail
${where}
group by pid
</select>
</mapper>

View File

@ -0,0 +1,131 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="plan.DeliverProcessorMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.DeliverProcessor" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="processorid" property="processorid" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<association column="processorid" property="processor" jdbcType="VARCHAR" select="selectProcessor"/>
</resultMap>
<sql id="Base_Column_List" >
id, pid, processorid, insuser, insdt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_material_deliver_processor
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="selectProcessor" parameterType="String" resultType="com.sipai.entity.user.User">
select * from tb_user where id = #{processorid}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_plan_material_deliver_processor
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.DeliverProcessor" >
insert into tb_plan_material_deliver_processor (id, pid, processorid,
insuser, insdt)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{processorid,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.DeliverProcessor" >
insert into tb_plan_material_deliver_processor
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="pid != null" >
pid,
</if>
<if test="processorid != null" >
processorid,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="processorid != null" >
#{processorid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.DeliverProcessor" >
update tb_plan_material_deliver_processor
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="processorid != null" >
processorid = #{processorid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.DeliverProcessor" >
update tb_plan_material_deliver_processor
set pid = #{pid,jdbcType=VARCHAR},
processorid = #{processorid,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_material_deliver_processor
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_plan_material_deliver_processor
${where}
</delete>
<select id="getDeliverProcessor" resultMap="DeliverProcessorMap" parameterType="java.lang.String">
select p.*,
u.id as u_id,
u.name as u_name,
u.serial as u_serial
from tb_plan_material_deliver_processor p
left join tb_user u on u.id=p.processorid
${where}
</select>
<resultMap id="DeliverProcessorMap" type="com.sipai.entity.plan.DeliverProcessor" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="processorid" property="processorid" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<association property="processor" resultMap="processorResult"/>
</resultMap>
<resultMap id="processorResult" type="com.sipai.entity.user.User">
<id property="id" column="u_id"/>
<result property="name" column="u_name"/>
<result property="serial" column="u_serial"/>
</resultMap>
</mapper>

View File

@ -0,0 +1,234 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="plan.MaterialDeliverMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.MaterialDeliver" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="dailyplanid" property="dailyplanid" jdbcType="VARCHAR" />
<result column="workstationid" property="workstationid" jdbcType="VARCHAR" />
<result column="starttime" property="starttime" jdbcType="TIMESTAMP" />
<result column="endtime" property="endtime" jdbcType="TIMESTAMP" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<association column="dailyplanid" property="dailyPlanSummary" jdbcType="VARCHAR" select="selectDailyPlanSummary"/>
<association column="workstationid" property="workstation" jdbcType="VARCHAR" select="selectWorkstation"/>
</resultMap>
<sql id="Base_Column_List" >
id, dailyplanid, workstationid, starttime, endtime, status, remark,insuser, insdt, modify, modifydt
</sql>
<select id="selectDailyPlanSummary" parameterType="String" resultType="com.sipai.entity.plan.DailyPlanSummary">
select * from TB_plan_dailyplanSummary where id = #{dailyplanid}
</select>
<select id="selectWorkstation" parameterType="String" resultType="com.sipai.entity.work.Workstation">
select * from tb_work_workstation where id = #{workstationid}
</select>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_material_deliver
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_plan_material_deliver
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.MaterialDeliver" >
insert into tb_plan_material_deliver (id, dailyplanid ,
workstationid, starttime, endtime, status, remark, insuser, insdt, modify,
modifydt)
values (#{id,jdbcType=VARCHAR}, #{dailyplanid,jdbcType=VARCHAR},#{workstationid,jdbcType=VARCHAR},
#{starttime,jdbcType=TIMESTAMP}, #{endtime,jdbcType=TIMESTAMP}, #{status,jdbcType=VARCHAR},
#{remark,jdbcType=VARCHAR},#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{modify,jdbcType=VARCHAR},
#{modifydt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.MaterialDeliver" >
insert into tb_plan_material_deliver
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="dailyplanid != null" >
dailyplanid,
</if>
<if test="workstationid != null" >
workstationid,
</if>
<if test="starttime != null" >
starttime,
</if>
<if test="endtime != null" >
endtime,
</if>
<if test="status != null" >
status,
</if>
<if test="remark != null" >
remark,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="dailyplanid != null" >
#{dailyplanid,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
#{workstationid,jdbcType=VARCHAR},
</if>
<if test="starttime != null" >
#{starttime,jdbcType=TIMESTAMP},
</if>
<if test="endtime != null" >
#{endtime,jdbcType=TIMESTAMP},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
#{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.MaterialDeliver" >
update tb_plan_material_deliver
<set >
<if test="dailyplanid != null" >
dailyplanid = #{dailyplanid,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
workstationid = #{workstationid,jdbcType=VARCHAR},
</if>
<if test="starttime != null" >
starttime = #{starttime,jdbcType=TIMESTAMP},
</if>
<if test="endtime != null" >
endtime = #{endtime,jdbcType=TIMESTAMP},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="remark != null" >
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.MaterialDeliver" >
update tb_plan_material_deliver
set dailyplanid = #{dailyplanid,jdbcType=VARCHAR},
workstationid = #{workstationid,jdbcType=VARCHAR},
starttime = #{starttime,jdbcType=TIMESTAMP},
endtime = #{endtime,jdbcType=TIMESTAMP},
status = #{status,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP},
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_material_deliver
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_plan_material_deliver
${where}
</delete>
<select id="getMaterialDeliver" resultMap="MaterialDeliverMap" parameterType="java.lang.String">
select deliver.*,
dailyplanSummary.id as d_id,
dailyplanSummary.name as d_name,
dailyplanSummary.plandt as d_plandt,
workstation.id as w_id,
workstation.name as w_name,
workstation.serial as w_serial
from tb_plan_material_deliver deliver
left join TB_plan_dailyplanSummary dailyplanSummary on dailyplanSummary.id=deliver.dailyplanid
left join tb_work_workstation workstation on workstation.id=deliver.workstationid
${where}
</select>
<select id="getProcessorDeliver" resultMap="MaterialDeliverMap" parameterType="java.lang.String">
select deliver.*,
dailyplanSummary.id as d_id,
dailyplanSummary.name as d_name,
dailyplanSummary.plandt as d_plandt,
workstation.id as w_id,
workstation.name as w_name,
workstation.serial as w_serial
from tb_plan_material_deliver deliver
left join TB_plan_dailyplanSummary dailyplanSummary on dailyplanSummary.id=deliver.dailyplanid
left join tb_work_workstation workstation on workstation.id=deliver.workstationid
left join tb_plan_material_deliver_processor processor on processor.pid=deliver.id
${where}
</select>
<resultMap id="MaterialDeliverMap" type="com.sipai.entity.plan.MaterialDeliver" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="dailyplanid" property="dailyplanid" jdbcType="VARCHAR" />
<result column="workstationid" property="workstationid" jdbcType="VARCHAR" />
<result column="starttime" property="starttime" jdbcType="TIMESTAMP" />
<result column="endtime" property="endtime" jdbcType="TIMESTAMP" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="remark" property="remark" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<association property="dailyPlanSummary" resultMap="dailyPlanSummaryResult"/>
<association property="workstation" resultMap="workstationResult"/>
</resultMap>
<resultMap id="dailyPlanSummaryResult" type="com.sipai.entity.plan.DailyPlanSummary">
<id property="id" column="d_id"/>
<result property="name" column="d_name"/>
<result property="plandt" column="d_plandt"/>
</resultMap>
<resultMap id="workstationResult" type="com.sipai.entity.work.Workstation">
<id property="id" column="w_id"/>
<result property="name" column="w_name"/>
<result property="serial" column="w_serial"/>
</resultMap>
</mapper>

View File

@ -0,0 +1,41 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="plan.MaterialPlanMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.MaterialPlan">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="name" jdbcType="VARCHAR" property="name" />
<result column="plandt" jdbcType="TIMESTAMP" property="plandt" />
<result column="workstationid" jdbcType="VARCHAR" property="workstationid" />
<result column="workstationname" jdbcType="VARCHAR" property="workstationname" />
<result column="workstationserial" jdbcType="VARCHAR" property="workstationserial" />
<result column="materialid" jdbcType="VARCHAR" property="materialid" />
<result column="materialcode" jdbcType="VARCHAR" property="materialcode" />
<result column="materialname" jdbcType="VARCHAR" property="materialname" />
<result column="amount" property="amount" jdbcType="DOUBLE" />
<result column="unit" jdbcType="VARCHAR" property="unit" />
</resultMap>
<sql id="Base_Column_List">
id, name, plandt, workstationid, workstationname,workstationserial, materialid, materialcode, materialname, CAST((case when amount is null then '' else amount end )as float) as amount,unit
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from uv_material_plan
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="selectStatisticListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select id, name, plandt, workstationid, workstationname,workstationserial, materialid, materialcode, materialname,
Sum(CAST((case when amount is null then '' else amount end )as float)) as amount,unit
from uv_material_plan
${where}
</select>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from uv_material_plan
${where}
</select>
<select id="selectValueBySql" parameterType="java.lang.String" resultMap="BaseResultMap">
${sql}
</select>
</mapper>

View File

@ -0,0 +1,214 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="plan.MaterialRecoverMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.MaterialRecover" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="dailyplanid" property="dailyplanid" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="workstationid" property="workstationid" jdbcType="VARCHAR" />
<result column="recoverid" property="recoverid" jdbcType="VARCHAR" />
<result column="recovertime" property="recovertime" jdbcType="TIMESTAMP" />
<result column="recovernum" property="recovernum" jdbcType="DOUBLE" />
<result column="memo" property="memo" jdbcType="VARCHAR" />
<association column="dailyplanid" property="dailyPlanSummary" jdbcType="VARCHAR" select="selectDailyPlanSummary"/>
<association column="materialid" property="materialInfo" jdbcType="VARCHAR" select="selectMaterialInfo"/>
<association column="workstationid" property="workstation" jdbcType="VARCHAR" select="selectWorkstation"/>
<association column="recoverid" property="recover" jdbcType="VARCHAR" select="selectRecover"/>
</resultMap>
<select id="selectDailyPlanSummary" parameterType="String" resultType="com.sipai.entity.plan.DailyPlanSummary">
select * from TB_plan_dailyplanSummary where id = #{dailyplanid}
</select>
<select id="selectMaterialInfo" parameterType="String" resultType="com.sipai.entity.material.MaterialInfo">
select * from tb_material_info where id = #{materialid}
</select>
<select id="selectWorkstation" parameterType="String" resultType="com.sipai.entity.work.Workstation">
select * from tb_work_workstation where id = #{workstationid}
</select>
<select id="selectRecover" parameterType="String" resultType="com.sipai.entity.user.User">
select * from tb_user where id = #{recoverid}
</select>
<sql id="Base_Column_List" >
id, dailyplanid, materialid, workstationid, recoverid, recovertime, recovernum, memo
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_material_recover
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_plan_material_recover
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.MaterialRecover" >
insert into tb_plan_material_recover (id, dailyplanid, materialid,
workstationid, recoverid, recovertime,
recovernum, memo)
values (#{id,jdbcType=VARCHAR}, #{dailyplanid,jdbcType=VARCHAR}, #{materialid,jdbcType=VARCHAR},
#{workstationid,jdbcType=VARCHAR}, #{recoverid,jdbcType=VARCHAR}, #{recovertime,jdbcType=TIMESTAMP},
#{recovernum,jdbcType=DOUBLE}, #{memo,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.MaterialRecover" >
insert into tb_plan_material_recover
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="dailyplanid != null" >
dailyplanid,
</if>
<if test="materialid != null" >
materialid,
</if>
<if test="workstationid != null" >
workstationid,
</if>
<if test="recoverid != null" >
recoverid,
</if>
<if test="recovertime != null" >
recovertime,
</if>
<if test="recovernum != null" >
recovernum,
</if>
<if test="memo != null" >
memo,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="dailyplanid != null" >
#{dailyplanid,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
#{materialid,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
#{workstationid,jdbcType=VARCHAR},
</if>
<if test="recoverid != null" >
#{recoverid,jdbcType=VARCHAR},
</if>
<if test="recovertime != null" >
#{recovertime,jdbcType=TIMESTAMP},
</if>
<if test="recovernum != null" >
#{recovernum,jdbcType=DOUBLE},
</if>
<if test="memo != null" >
#{memo,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.MaterialRecover" >
update tb_plan_material_recover
<set >
<if test="dailyplanid != null" >
dailyplanid = #{dailyplanid,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
workstationid = #{workstationid,jdbcType=VARCHAR},
</if>
<if test="recoverid != null" >
recoverid = #{recoverid,jdbcType=VARCHAR},
</if>
<if test="recovertime != null" >
recovertime = #{recovertime,jdbcType=TIMESTAMP},
</if>
<if test="recovernum != null" >
recovernum = #{recovernum,jdbcType=DOUBLE},
</if>
<if test="memo != null" >
memo = #{memo,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.MaterialRecover" >
update tb_plan_material_recover
set dailyplanid = #{dailyplanid,jdbcType=VARCHAR},
materialid = #{materialid,jdbcType=VARCHAR},
workstationid = #{workstationid,jdbcType=VARCHAR},
recoverid = #{recoverid,jdbcType=VARCHAR},
recovertime = #{recovertime,jdbcType=TIMESTAMP},
recovernum = #{recovernum,jdbcType=DOUBLE},
memo = #{memo,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_material_recover
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_plan_material_recover
${where}
</delete>
<select id="getMaterialRecover" resultMap="MaterialRecoverMap" parameterType="java.lang.String">
select r.*,
d.id as d_id,
d.name as d_name,
d.plandt as d_plandt,
m.id as m_id,
m.materialcode as m_materialcode,
m.materialname as m_materialname,
m.unit as m_unit,
w.id as w_id,
w.name as w_name,
w.serial as w_serial,
u.id as u_id,
u.name as u_name
from tb_plan_material_recover r
left join TB_plan_dailyplanSummary d on r.dailyplanid=d.id
left join tb_material_info m on r.materialid=m.id
left join tb_work_workstation w on r.workstationid=w.id
left join tb_user u on r.recoverid=u.id
${where}
</select>
<resultMap id="MaterialRecoverMap" type="com.sipai.entity.plan.MaterialRecover">
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="dailyplanid" property="dailyplanid" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="workstationid" property="workstationid" jdbcType="VARCHAR" />
<result column="recoverid" property="recoverid" jdbcType="VARCHAR" />
<result column="recovertime" property="recovertime" jdbcType="TIMESTAMP" />
<result column="recovernum" property="recovernum" jdbcType="DOUBLE" />
<result column="memo" property="memo" jdbcType="VARCHAR" />
<association property="dailyPlanSummary" resultMap="dailyPlanSummaryResult"/>
<association property="materialInfo" resultMap="materialInfoResult"/>
<association property="workstation" resultMap="workstationResult"/>
<association property="recover" resultMap="recoverResult"/>
</resultMap>
<resultMap id="dailyPlanSummaryResult" type="com.sipai.entity.plan.DailyPlanSummary">
<id property="id" column="d_id"/>
<result property="name" column="d_name"/>
<result property="plandt" column="d_plandt"/>
</resultMap>
<resultMap id="materialInfoResult" type="com.sipai.entity.material.MaterialInfo">
<id property="id" column="m_id"/>
<result property="materialcode" column="m_materialcode"/>
<result property="materialname" column="m_materialname"/>
<result property="unit" column="m_unit"/>
</resultMap>
<resultMap id="workstationResult" type="com.sipai.entity.work.Workstation">
<id property="id" column="w_id"/>
<result property="name" column="w_name"/>
<result property="serial" column="w_serial"/>
</resultMap>
<resultMap id="recoverResult" type="com.sipai.entity.user.User">
<id property="id" column="u_id"/>
<result property="name" column="u_name"/>
</resultMap>
</mapper>

View File

@ -0,0 +1,472 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="plan.ProdtaskMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.Prodtask" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="taskcode" property="taskcode" jdbcType="VARCHAR" />
<result column="billstatus" property="billstatus" jdbcType="VARCHAR" />
<result column="workshop" property="workshop" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="materialname" property="materialname" jdbcType="VARCHAR" />
<result column="model" property="model" jdbcType="VARCHAR" />
<result column="batch" property="batch" jdbcType="VARCHAR" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="planamount" property="planamount" jdbcType="DOUBLE" />
<result column="pstdate" property="pstdate" jdbcType="TIMESTAMP" />
<result column="pendate" property="pendate" jdbcType="TIMESTAMP" />
<result column="type" property="type" jdbcType="VARCHAR" />
<result column="bomno" property="bomno" jdbcType="VARCHAR" />
<result column="costobject" property="costobject" jdbcType="VARCHAR" />
<result column="source" property="source" jdbcType="VARCHAR" />
<result column="planno" property="planno" jdbcType="VARCHAR" />
<result column="salesno" property="salesno" jdbcType="VARCHAR" />
<result column="procompany" property="procompany" jdbcType="VARCHAR" />
<result column="commonunit" property="commonunit" jdbcType="VARCHAR" />
<result column="qualitypart" property="qualitypart" jdbcType="VARCHAR" />
<result column="astdate" property="astdate" jdbcType="TIMESTAMP" />
<result column="aendate" property="aendate" jdbcType="TIMESTAMP" />
<result column="midentification" property="midentification" jdbcType="VARCHAR" />
<result column="runstatus" property="runstatus" jdbcType="VARCHAR" />
<result column="plantype" property="plantype" jdbcType="VARCHAR" />
<result column="bomtype" property="bomtype" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="relation" property="relation" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, taskcode, billstatus, workshop, materialcode, materialname, model, batch, unit,
planamount, pstdate, pendate, type, bomno, costobject, source, planno, salesno, procompany,
commonunit, qualitypart, astdate, aendate, midentification, runstatus, plantype,
bomtype, insuser, insdt, pid, relation
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_prodtask
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_plan_prodtask
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.Prodtask" >
insert into tb_plan_prodtask (id, taskcode, billstatus,
workshop, materialcode, materialname,
model, batch, unit,
planamount, pstdate, pendate,
type, bomno, costobject,
source, planno, salesno,
procompany, commonunit, qualitypart,
astdate, aendate, midentification,
runstatus, plantype, bomtype,
insuser, insdt, pid,
relation)
values (#{id,jdbcType=VARCHAR}, #{taskcode,jdbcType=VARCHAR}, #{billstatus,jdbcType=VARCHAR},
#{workshop,jdbcType=VARCHAR}, #{materialcode,jdbcType=VARCHAR}, #{materialname,jdbcType=VARCHAR},
#{model,jdbcType=VARCHAR}, #{batch,jdbcType=VARCHAR}, #{unit,jdbcType=VARCHAR},
#{planamount,jdbcType=DOUBLE}, #{pstdate,jdbcType=TIMESTAMP}, #{pendate,jdbcType=TIMESTAMP},
#{type,jdbcType=VARCHAR}, #{bomno,jdbcType=VARCHAR}, #{costobject,jdbcType=VARCHAR},
#{source,jdbcType=VARCHAR}, #{planno,jdbcType=VARCHAR}, #{salesno,jdbcType=VARCHAR},
#{procompany,jdbcType=VARCHAR}, #{commonunit,jdbcType=VARCHAR}, #{qualitypart,jdbcType=VARCHAR},
#{astdate,jdbcType=TIMESTAMP}, #{aendate,jdbcType=TIMESTAMP}, #{midentification,jdbcType=VARCHAR},
#{runstatus,jdbcType=VARCHAR}, #{plantype,jdbcType=VARCHAR}, #{bomtype,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{pid,jdbcType=VARCHAR},
#{relation,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.Prodtask" >
insert into tb_plan_prodtask
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="taskcode != null" >
taskcode,
</if>
<if test="billstatus != null" >
billstatus,
</if>
<if test="workshop != null" >
workshop,
</if>
<if test="materialcode != null" >
materialcode,
</if>
<if test="materialname != null" >
materialname,
</if>
<if test="model != null" >
model,
</if>
<if test="batch != null" >
batch,
</if>
<if test="unit != null" >
unit,
</if>
<if test="planamount != null" >
planamount,
</if>
<if test="pstdate != null" >
pstdate,
</if>
<if test="pendate != null" >
pendate,
</if>
<if test="type != null" >
type,
</if>
<if test="bomno != null" >
bomno,
</if>
<if test="costobject != null" >
costobject,
</if>
<if test="source != null" >
source,
</if>
<if test="planno != null" >
planno,
</if>
<if test="salesno != null" >
salesno,
</if>
<if test="procompany != null" >
procompany,
</if>
<if test="commonunit != null" >
commonunit,
</if>
<if test="qualitypart != null" >
qualitypart,
</if>
<if test="astdate != null" >
astdate,
</if>
<if test="aendate != null" >
aendate,
</if>
<if test="midentification != null" >
midentification,
</if>
<if test="runstatus != null" >
runstatus,
</if>
<if test="plantype != null" >
plantype,
</if>
<if test="bomtype != null" >
bomtype,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="pid != null" >
pid,
</if>
<if test="relation != null" >
relation,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="taskcode != null" >
#{taskcode,jdbcType=VARCHAR},
</if>
<if test="billstatus != null" >
#{billstatus,jdbcType=VARCHAR},
</if>
<if test="workshop != null" >
#{workshop,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
#{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null" >
#{materialname,jdbcType=VARCHAR},
</if>
<if test="model != null" >
#{model,jdbcType=VARCHAR},
</if>
<if test="batch != null" >
#{batch,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
#{unit,jdbcType=VARCHAR},
</if>
<if test="planamount != null" >
#{planamount,jdbcType=DOUBLE},
</if>
<if test="pstdate != null" >
#{pstdate,jdbcType=TIMESTAMP},
</if>
<if test="pendate != null" >
#{pendate,jdbcType=TIMESTAMP},
</if>
<if test="type != null" >
#{type,jdbcType=VARCHAR},
</if>
<if test="bomno != null" >
#{bomno,jdbcType=VARCHAR},
</if>
<if test="costobject != null" >
#{costobject,jdbcType=VARCHAR},
</if>
<if test="source != null" >
#{source,jdbcType=VARCHAR},
</if>
<if test="planno != null" >
#{planno,jdbcType=VARCHAR},
</if>
<if test="salesno != null" >
#{salesno,jdbcType=VARCHAR},
</if>
<if test="procompany != null" >
#{procompany,jdbcType=VARCHAR},
</if>
<if test="commonunit != null" >
#{commonunit,jdbcType=VARCHAR},
</if>
<if test="qualitypart != null" >
#{qualitypart,jdbcType=VARCHAR},
</if>
<if test="astdate != null" >
#{astdate,jdbcType=TIMESTAMP},
</if>
<if test="aendate != null" >
#{aendate,jdbcType=TIMESTAMP},
</if>
<if test="midentification != null" >
#{midentification,jdbcType=VARCHAR},
</if>
<if test="runstatus != null" >
#{runstatus,jdbcType=VARCHAR},
</if>
<if test="plantype != null" >
#{plantype,jdbcType=VARCHAR},
</if>
<if test="bomtype != null" >
#{bomtype,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="relation != null" >
#{relation,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.Prodtask" >
update tb_plan_prodtask
<set >
<if test="taskcode != null" >
taskcode = #{taskcode,jdbcType=VARCHAR},
</if>
<if test="billstatus != null" >
billstatus = #{billstatus,jdbcType=VARCHAR},
</if>
<if test="workshop != null" >
workshop = #{workshop,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
materialcode = #{materialcode,jdbcType=VARCHAR},
</if>
<if test="materialname != null" >
materialname = #{materialname,jdbcType=VARCHAR},
</if>
<if test="model != null" >
model = #{model,jdbcType=VARCHAR},
</if>
<if test="batch != null" >
batch = #{batch,jdbcType=VARCHAR},
</if>
<if test="unit != null" >
unit = #{unit,jdbcType=VARCHAR},
</if>
<if test="planamount != null" >
planamount = #{planamount,jdbcType=DOUBLE},
</if>
<if test="pstdate != null" >
pstdate = #{pstdate,jdbcType=TIMESTAMP},
</if>
<if test="pendate != null" >
pendate = #{pendate,jdbcType=TIMESTAMP},
</if>
<if test="type != null" >
type = #{type,jdbcType=VARCHAR},
</if>
<if test="bomno != null" >
bomno = #{bomno,jdbcType=VARCHAR},
</if>
<if test="costobject != null" >
costobject = #{costobject,jdbcType=VARCHAR},
</if>
<if test="source != null" >
source = #{source,jdbcType=VARCHAR},
</if>
<if test="planno != null" >
planno = #{planno,jdbcType=VARCHAR},
</if>
<if test="salesno != null" >
salesno = #{salesno,jdbcType=VARCHAR},
</if>
<if test="procompany != null" >
procompany = #{procompany,jdbcType=VARCHAR},
</if>
<if test="commonunit != null" >
commonunit = #{commonunit,jdbcType=VARCHAR},
</if>
<if test="qualitypart != null" >
qualitypart = #{qualitypart,jdbcType=VARCHAR},
</if>
<if test="astdate != null" >
astdate = #{astdate,jdbcType=TIMESTAMP},
</if>
<if test="aendate != null" >
aendate = #{aendate,jdbcType=TIMESTAMP},
</if>
<if test="midentification != null" >
midentification = #{midentification,jdbcType=VARCHAR},
</if>
<if test="runstatus != null" >
runstatus = #{runstatus,jdbcType=VARCHAR},
</if>
<if test="plantype != null" >
plantype = #{plantype,jdbcType=VARCHAR},
</if>
<if test="bomtype != null" >
bomtype = #{bomtype,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="relation != null" >
relation = #{relation,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.Prodtask" >
update tb_plan_prodtask
set taskcode = #{taskcode,jdbcType=VARCHAR},
billstatus = #{billstatus,jdbcType=VARCHAR},
workshop = #{workshop,jdbcType=VARCHAR},
materialcode = #{materialcode,jdbcType=VARCHAR},
materialname = #{materialname,jdbcType=VARCHAR},
model = #{model,jdbcType=VARCHAR},
batch = #{batch,jdbcType=VARCHAR},
unit = #{unit,jdbcType=VARCHAR},
planamount = #{planamount,jdbcType=DOUBLE},
pstdate = #{pstdate,jdbcType=TIMESTAMP},
pendate = #{pendate,jdbcType=TIMESTAMP},
type = #{type,jdbcType=VARCHAR},
bomno = #{bomno,jdbcType=VARCHAR},
costobject = #{costobject,jdbcType=VARCHAR},
source = #{source,jdbcType=VARCHAR},
planno = #{planno,jdbcType=VARCHAR},
salesno = #{salesno,jdbcType=VARCHAR},
procompany = #{procompany,jdbcType=VARCHAR},
commonunit = #{commonunit,jdbcType=VARCHAR},
qualitypart = #{qualitypart,jdbcType=VARCHAR},
astdate = #{astdate,jdbcType=TIMESTAMP},
aendate = #{aendate,jdbcType=TIMESTAMP},
midentification = #{midentification,jdbcType=VARCHAR},
runstatus = #{runstatus,jdbcType=VARCHAR},
plantype = #{plantype,jdbcType=VARCHAR},
bomtype = #{bomtype,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
pid = #{pid,jdbcType=VARCHAR},
relation = #{relation,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_prodtask
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_plan_prodtask
${where}
</delete>
<select id="getListByTaskCode" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_prodtask
where taskcode = #{taskcode,jdbcType=VARCHAR}
</select>
<resultMap id="BaseResultMapForSelect" type="com.sipai.entity.plan.Prodtask" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="taskcode" property="taskcode" jdbcType="VARCHAR" />
<result column="billstatus" property="billstatus" jdbcType="VARCHAR" />
<result column="workshop" property="workshop" jdbcType="VARCHAR" />
<result column="materialcode" property="materialcode" jdbcType="VARCHAR" />
<result column="materialname" property="materialname" jdbcType="VARCHAR" />
<result column="model" property="model" jdbcType="VARCHAR" />
<result column="batch" property="batch" jdbcType="VARCHAR" />
<result column="unit" property="unit" jdbcType="VARCHAR" />
<result column="planamount" property="planamount" jdbcType="DOUBLE" />
<result column="pstdate" property="pstdate" jdbcType="TIMESTAMP" />
<result column="pendate" property="pendate" jdbcType="TIMESTAMP" />
<result column="type" property="type" jdbcType="VARCHAR" />
<result column="bomno" property="bomno" jdbcType="VARCHAR" />
<result column="costobject" property="costobject" jdbcType="VARCHAR" />
<result column="source" property="source" jdbcType="VARCHAR" />
<result column="planno" property="planno" jdbcType="VARCHAR" />
<result column="salesno" property="salesno" jdbcType="VARCHAR" />
<result column="procompany" property="procompany" jdbcType="VARCHAR" />
<result column="commonunit" property="commonunit" jdbcType="VARCHAR" />
<result column="qualitypart" property="qualitypart" jdbcType="VARCHAR" />
<result column="astdate" property="astdate" jdbcType="TIMESTAMP" />
<result column="aendate" property="aendate" jdbcType="TIMESTAMP" />
<result column="midentification" property="midentification" jdbcType="VARCHAR" />
<result column="runstatus" property="runstatus" jdbcType="VARCHAR" />
<result column="plantype" property="plantype" jdbcType="VARCHAR" />
<result column="bomtype" property="bomtype" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="relation" property="relation" jdbcType="VARCHAR" />
<result column="tasklistcode" property="tasklistcode" jdbcType="VARCHAR" />
<result column="productno" property="productno" jdbcType="VARCHAR" />
</resultMap>
<select id="getListForSelect" resultMap="BaseResultMapForSelect" parameterType="java.lang.String" >
select
P.id, taskcode, P.billstatus,
workshop, materialcode, materialname,
model, batch, unit,
planamount, P.pstdate, P.pendate,
type, bomno, costobject,
source, planno, P.salesno,
procompany, commonunit, qualitypart,
astdate, aendate, midentification,
runstatus, plantype, bomtype,
P.insuser, P.insdt, pid,
relation, T.tasklistcode ,T.productno
from tb_plan_prodtask P
left outer join tb_plan_taskorder T on P.pid = T.id
${where}
</select>
</mapper>

View File

@ -0,0 +1,271 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="plan.taskorderMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.Taskorder" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="tasklistcode" property="tasklistcode" jdbcType="VARCHAR" />
<result column="salesno" property="salesno" jdbcType="VARCHAR" />
<result column="productno" property="productno" jdbcType="VARCHAR" />
<result column="productname" property="productname" jdbcType="VARCHAR" />
<result column="prodamount" property="prodamount" jdbcType="DOUBLE" />
<result column="pstdate" property="pstdate" jdbcType="TIMESTAMP" />
<result column="pendate" property="pendate" jdbcType="TIMESTAMP" />
<result column="billstatus" property="billstatus" jdbcType="VARCHAR" />
<result column="billruntime" property="billruntime" jdbcType="TIMESTAMP" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="stdt" property="stdt" jdbcType="TIMESTAMP" />
<result column="taskcode" property="taskcode" jdbcType="VARCHAR" />
<result column="planid" property="planid" jdbcType="VARCHAR" />
<result column="preamount" property="preamount" jdbcType="DOUBLE" />
<result column="actamount" property="actamount" jdbcType="DOUBLE" />
<result column="totalpreamount" property="preamount" jdbcType="DOUBLE" />
<result column="totalactamount" property="actamount" jdbcType="DOUBLE" />
<result column="processrealid" property="processrealid" jdbcType="VARCHAR" />
<result column="checknewstatus" property="checknewstatus" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, tasklistcode, salesno, productno, productname, prodamount, pstdate, pendate,
billstatus, billruntime, insuser, insdt, checknewstatus
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_taskorder
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_plan_taskorder
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.Taskorder" >
insert into tb_plan_taskorder (id, tasklistcode, salesno,
productno, productname, prodamount,
pstdate, pendate, billstatus,
billruntime, insuser, insdt,
checknewstatus)
values (#{id,jdbcType=VARCHAR}, #{tasklistcode,jdbcType=VARCHAR}, #{salesno,jdbcType=VARCHAR},
#{productno,jdbcType=VARCHAR}, #{productname,jdbcType=VARCHAR}, #{prodamount,jdbcType=DOUBLE},
#{pstdate,jdbcType=TIMESTAMP}, #{pendate,jdbcType=TIMESTAMP}, #{billstatus,jdbcType=VARCHAR},
#{billruntime,jdbcType=TIMESTAMP}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{checknewstatus,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.Taskorder" >
insert into tb_plan_taskorder
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="tasklistcode != null" >
tasklistcode,
</if>
<if test="salesno != null" >
salesno,
</if>
<if test="productno != null" >
productno,
</if>
<if test="productname != null" >
productname,
</if>
<if test="prodamount != null" >
prodamount,
</if>
<if test="pstdate != null" >
pstdate,
</if>
<if test="pendate != null" >
pendate,
</if>
<if test="billstatus != null" >
billstatus,
</if>
<if test="billruntime != null" >
billruntime,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="checknewstatus != null" >
checknewstatus,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="tasklistcode != null" >
#{tasklistcode,jdbcType=VARCHAR},
</if>
<if test="salesno != null" >
#{salesno,jdbcType=VARCHAR},
</if>
<if test="productno != null" >
#{productno,jdbcType=VARCHAR},
</if>
<if test="productname != null" >
#{productname,jdbcType=VARCHAR},
</if>
<if test="prodamount != null" >
#{prodamount,jdbcType=DOUBLE},
</if>
<if test="pstdate != null" >
#{pstdate,jdbcType=TIMESTAMP},
</if>
<if test="pendate != null" >
#{pendate,jdbcType=TIMESTAMP},
</if>
<if test="billstatus != null" >
#{billstatus,jdbcType=VARCHAR},
</if>
<if test="billruntime != null" >
#{billruntime,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="checknewstatus != null" >
#{checknewstatus,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.Taskorder" >
update tb_plan_taskorder
<set >
<if test="tasklistcode != null" >
tasklistcode = #{tasklistcode,jdbcType=VARCHAR},
</if>
<if test="salesno != null" >
salesno = #{salesno,jdbcType=VARCHAR},
</if>
<if test="productno != null" >
productno = #{productno,jdbcType=VARCHAR},
</if>
<if test="productname != null" >
productname = #{productname,jdbcType=VARCHAR},
</if>
<if test="prodamount != null" >
prodamount = #{prodamount,jdbcType=DOUBLE},
</if>
<if test="pstdate != null" >
pstdate = #{pstdate,jdbcType=TIMESTAMP},
</if>
<if test="pendate != null" >
pendate = #{pendate,jdbcType=TIMESTAMP},
</if>
<if test="billstatus != null" >
billstatus = #{billstatus,jdbcType=VARCHAR},
</if>
<if test="billruntime != null" >
billruntime = #{billruntime,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="checknewstatus != null" >
checknewstatus = #{checknewstatus,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.Taskorder" >
update tb_plan_taskorder
set tasklistcode = #{tasklistcode,jdbcType=VARCHAR},
salesno = #{salesno,jdbcType=VARCHAR},
productno = #{productno,jdbcType=VARCHAR},
productname = #{productname,jdbcType=VARCHAR},
prodamount = #{prodamount,jdbcType=DOUBLE},
pstdate = #{pstdate,jdbcType=TIMESTAMP},
pendate = #{pendate,jdbcType=TIMESTAMP},
billstatus = #{billstatus,jdbcType=VARCHAR},
billruntime = #{billruntime,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
checknewstatus = #{checknewstatus,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_taskorder
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_plan_taskorder
${where}
</delete>
<select id="selectByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_plan_taskorder
${where}
</select>
<select id="getDayPlanAmount" parameterType="java.lang.String" resultMap="BaseResultMap">
select T.[id] AS id,
P.[stdt] AS stdt,
T.tasklistcode,
D.taskcode AS taskcode,
D.[preamount] AS preamount,
D.[actamount] AS actamount,
C.procedurename AS procedurename
from tb_plan_taskorder T
LEFT OUTER JOIN tb_plan_day P ON P.taskOrderID = T.id
LEFT OUTER JOIN tb_plan_taskdemand D ON D.[planid] = P.id
LEFT OUTER JOIN tb_process_task_procedure C on C.procedurecode = D.taskcode
${where}
</select>
<select id="getTaskcodelist" parameterType="java.lang.String" resultMap="BaseResultMap">
select P.stdt,D.taskcode,D.preamount,D.actamount
from tb_plan_taskorder T
left outer join tb_plan_day P on T.id = P.taskOrderID
left outer join tb_plan_taskdemand D on D.planid = P.id
${where}
</select>
<select id="getProcessrealid" parameterType="java.lang.String" resultMap="BaseResultMap">
select T.id AS id,
P.id AS planid,
T.billstatus AS billstatus,
T.tasklistcode AS tasklistcode,
P.processrealid AS processrealid,
T.salesno AS salesno,
T.productno AS productno,
T.prodamount AS prodamount,
T.pstdate AS pstdate,
T.pendate AS pendate
from tb_plan_taskorder T
left outer join tb_plan_day P ON P.taskOrderID = T.id
${where}
</select>
<select id="getDistinctStdt" parameterType="java.lang.String" resultMap="BaseResultMap">
select distinct P.stdt AS stdt,T.id,T.tasklistcode from tb_plan_taskorder T
left outer join tb_plan_day P On P.taskOrderID = T.id
${where}
</select>
<!-- 测试存储过程 -->
<select id="updateTasks" parameterMap="updateTasksMap" statementType="CALLABLE" resultMap="resultNextSeqMap">
exec updateTasks(#{type},#{resp})
</select>
<parameterMap type="java.util.Map" id="updateTasksMap">
<parameter property="type" mode="IN" jdbcType="VARCHAR"/>
<parameter property="resp" mode="OUT" jdbcType="VARCHAR"/>
</parameterMap>
<resultMap type="java.util.Map" id="resultNextSeqMap">
<result column="resp" property="resp" javaType="String" jdbcType="VARCHAR"/>
</resultMap>
</mapper>

View File

@ -0,0 +1,122 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="plan.TaskorderReProdtaskMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.plan.TaskorderReProdtask" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="taskorderid" property="taskorderid" jdbcType="VARCHAR" />
<result column="prodtaskid" property="prodtaskid" jdbcType="VARCHAR" />
<result column="amount" property="amount" jdbcType="DOUBLE" />
<association column="prodtaskid" property="taskcode" jdbcType="VARCHAR" select="selectTaskcode"></association>
</resultMap>
<select id="selectTaskcode" resultType="String" parameterType="java.lang.String" >
select taskcode from tb_plan_prodtask where id = #{prodtaskid,jdbcType=VARCHAR}
</select>
<sql id="Base_Column_List" >
id, insuser, insdt, taskorderid, prodtaskid, amount
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_taskorder_relation_prodtask
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_plan_taskorder_relation_prodtask
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.plan.TaskorderReProdtask" >
insert into tb_plan_taskorder_relation_prodtask (id, insuser, insdt,
taskorderid, prodtaskid, amount
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{taskorderid,jdbcType=VARCHAR}, #{prodtaskid,jdbcType=VARCHAR}, #{amount,jdbcType=DOUBLE}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.plan.TaskorderReProdtask" >
insert into tb_plan_taskorder_relation_prodtask
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="taskorderid != null" >
taskorderid,
</if>
<if test="prodtaskid != null" >
prodtaskid,
</if>
<if test="amount != null" >
amount,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="taskorderid != null" >
#{taskorderid,jdbcType=VARCHAR},
</if>
<if test="prodtaskid != null" >
#{prodtaskid,jdbcType=VARCHAR},
</if>
<if test="amount != null" >
#{amount,jdbcType=DOUBLE},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.plan.TaskorderReProdtask" >
update tb_plan_taskorder_relation_prodtask
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="taskorderid != null" >
taskorderid = #{taskorderid,jdbcType=VARCHAR},
</if>
<if test="prodtaskid != null" >
prodtaskid = #{prodtaskid,jdbcType=VARCHAR},
</if>
<if test="amount != null" >
amount = #{amount,jdbcType=DOUBLE},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.plan.TaskorderReProdtask" >
update tb_plan_taskorder_relation_prodtask
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
taskorderid = #{taskorderid,jdbcType=VARCHAR},
prodtaskid = #{prodtaskid,jdbcType=VARCHAR},
amount = #{amount,jdbcType=DOUBLE}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_plan_taskorder_relation_prodtask
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_plan_taskorder_relation_prodtask
${where}
</delete>
</mapper>

View File

@ -0,0 +1,127 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.ProcessConfigMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.ProcessConfig" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="materialCode" property="materialcode" jdbcType="VARCHAR" />
<result column="processId" property="processid" jdbcType="VARCHAR" />
<result column="procedureNo" property="procedureno" jdbcType="VARCHAR" />
<result column="yield" property="yield" jdbcType="DOUBLE" />
</resultMap>
<sql id="Base_Column_List" >
id, insdt, insuser, materialCode, processId, procedureNo, yield
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_config
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_config
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.ProcessConfig" >
insert into tb_process_config (id, insdt, insuser,
materialCode, processId, procedureNo,
yield)
values (#{id,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{insuser,jdbcType=VARCHAR},
#{materialcode,jdbcType=VARCHAR}, #{processid,jdbcType=VARCHAR}, #{procedureno,jdbcType=VARCHAR},
#{yield,jdbcType=DOUBLE})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.ProcessConfig" >
insert into tb_process_config
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="materialcode != null" >
materialCode,
</if>
<if test="processid != null" >
processId,
</if>
<if test="procedureno != null" >
procedureNo,
</if>
<if test="yield != null" >
yield,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
#{materialcode,jdbcType=VARCHAR},
</if>
<if test="processid != null" >
#{processid,jdbcType=VARCHAR},
</if>
<if test="procedureno != null" >
#{procedureno,jdbcType=VARCHAR},
</if>
<if test="yield != null" >
#{yield,jdbcType=DOUBLE},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.ProcessConfig" >
update tb_process_config
<set >
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="materialcode != null" >
materialCode = #{materialcode,jdbcType=VARCHAR},
</if>
<if test="processid != null" >
processId = #{processid,jdbcType=VARCHAR},
</if>
<if test="procedureno != null" >
procedureNo = #{procedureno,jdbcType=VARCHAR},
</if>
<if test="yield != null" >
yield = #{yield,jdbcType=DOUBLE},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.ProcessConfig" >
update tb_process_config
set insdt = #{insdt,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
materialCode = #{materialcode,jdbcType=VARCHAR},
processId = #{processid,jdbcType=VARCHAR},
procedureNo = #{procedureno,jdbcType=VARCHAR},
yield = #{yield,jdbcType=DOUBLE}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_process_config
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_process_config
${where}
</delete>
</mapper>

View File

@ -0,0 +1,127 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="process.ProcessConfig_EMMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.process.ProcessConfig_EM">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="equipmentClassCode" jdbcType="VARCHAR" property="equipmentclasscode" />
<result column="processId" jdbcType="VARCHAR" property="processid" />
<result column="procedureNo" jdbcType="VARCHAR" property="procedureno" />
<result column="capacity" jdbcType="VARCHAR" property="capacity" />
</resultMap>
<sql id="Base_Column_List">
id, insdt, insuser, equipmentClassCode, processId, procedureNo, capacity
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_process_config_em
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_process_config_em
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.ProcessConfig_EM">
insert into tb_process_config_em (id, insdt, insuser,
equipmentClassCode, processId, procedureNo,
capacity)
values (#{id,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{insuser,jdbcType=VARCHAR},
#{equipmentclasscode,jdbcType=VARCHAR}, #{processid,jdbcType=VARCHAR}, #{procedureno,jdbcType=VARCHAR},
#{capacity,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.ProcessConfig_EM">
insert into tb_process_config_em
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="equipmentclasscode != null">
equipmentClassCode,
</if>
<if test="processid != null">
processId,
</if>
<if test="procedureno != null">
procedureNo,
</if>
<if test="capacity != null">
capacity,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="equipmentclasscode != null">
#{equipmentclasscode,jdbcType=VARCHAR},
</if>
<if test="processid != null">
#{processid,jdbcType=VARCHAR},
</if>
<if test="procedureno != null">
#{procedureno,jdbcType=VARCHAR},
</if>
<if test="capacity != null">
#{capacity,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.ProcessConfig_EM">
update tb_process_config_em
<set>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="equipmentclasscode != null">
equipmentClassCode = #{equipmentclasscode,jdbcType=VARCHAR},
</if>
<if test="processid != null">
processId = #{processid,jdbcType=VARCHAR},
</if>
<if test="procedureno != null">
procedureNo = #{procedureno,jdbcType=VARCHAR},
</if>
<if test="capacity != null">
capacity = #{capacity,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.ProcessConfig_EM">
update tb_process_config_em
set insdt = #{insdt,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
equipmentClassCode = #{equipmentclasscode,jdbcType=VARCHAR},
processId = #{processid,jdbcType=VARCHAR},
procedureNo = #{procedureno,jdbcType=VARCHAR},
capacity = #{capacity,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_process_config_em
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_process_config_em
${where}
</delete>
</mapper>

View File

@ -0,0 +1,171 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.ProcessMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.Process" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="display_Name" property="displayName" jdbcType="VARCHAR" />
<result column="type" property="type" jdbcType="VARCHAR" />
<result column="instance_Url" property="instanceUrl" jdbcType="VARCHAR" />
<result column="state" property="state" jdbcType="TINYINT" />
<result column="version" property="version" jdbcType="TINYINT" />
<result column="create_Time" property="createTime" jdbcType="VARCHAR" />
<result column="creator" property="creator" jdbcType="VARCHAR" />
</resultMap>
<resultMap id="ResultMapWithBLOBs" type="com.sipai.entity.process.Process" extends="BaseResultMap" >
<result column="content" property="content" jdbcType="BLOB" />
</resultMap>
<sql id="Base_Column_List" >
id, name, display_Name, type, instance_Url, state, version, create_Time, creator
</sql>
<sql id="Blob_Column_List" >
content
</sql>
<select id="selectByPrimaryKey" resultMap="ResultMapWithBLOBs" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
,
<include refid="Blob_Column_List" />
from wf_process
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from wf_process
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.Process" >
insert into wf_process (id, name, display_Name,
type, instance_Url, state,
version, create_Time, creator,
content)
values (#{id,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{displayName,jdbcType=VARCHAR},
#{type,jdbcType=VARCHAR}, #{instanceUrl,jdbcType=VARCHAR}, #{state,jdbcType=TINYINT},
#{version,jdbcType=TINYINT}, #{createTime,jdbcType=VARCHAR}, #{creator,jdbcType=VARCHAR},
#{content,jdbcType=BLOB})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.Process" >
insert into wf_process
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="name != null" >
name,
</if>
<if test="displayName != null" >
display_Name,
</if>
<if test="type != null" >
type,
</if>
<if test="instanceUrl != null" >
instance_Url,
</if>
<if test="state != null" >
state,
</if>
<if test="version != null" >
version,
</if>
<if test="createTime != null" >
create_Time,
</if>
<if test="creator != null" >
creator,
</if>
<if test="content != null" >
content,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="displayName != null" >
#{displayName,jdbcType=VARCHAR},
</if>
<if test="type != null" >
#{type,jdbcType=VARCHAR},
</if>
<if test="instanceUrl != null" >
#{instanceUrl,jdbcType=VARCHAR},
</if>
<if test="state != null" >
#{state,jdbcType=TINYINT},
</if>
<if test="version != null" >
#{version,jdbcType=TINYINT},
</if>
<if test="createTime != null" >
#{createTime,jdbcType=VARCHAR},
</if>
<if test="creator != null" >
#{creator,jdbcType=VARCHAR},
</if>
<if test="content != null" >
#{content,jdbcType=BLOB},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.Process" >
update wf_process
<set >
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="displayName != null" >
display_Name = #{displayName,jdbcType=VARCHAR},
</if>
<if test="type != null" >
type = #{type,jdbcType=VARCHAR},
</if>
<if test="instanceUrl != null" >
instance_Url = #{instanceUrl,jdbcType=VARCHAR},
</if>
<if test="state != null" >
state = #{state,jdbcType=TINYINT},
</if>
<if test="version != null" >
version = #{version,jdbcType=TINYINT},
</if>
<if test="createTime != null" >
create_Time = #{createTime,jdbcType=VARCHAR},
</if>
<if test="creator != null" >
creator = #{creator,jdbcType=VARCHAR},
</if>
<if test="content != null" >
content = #{content,jdbcType=BLOB},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKeyWithBLOBs" parameterType="com.sipai.entity.process.Process" >
update wf_process
set name = #{name,jdbcType=VARCHAR},
display_Name = #{displayName,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
instance_Url = #{instanceUrl,jdbcType=VARCHAR},
state = #{state,jdbcType=TINYINT},
version = #{version,jdbcType=TINYINT},
create_Time = #{createTime,jdbcType=VARCHAR},
creator = #{creator,jdbcType=VARCHAR},
content = #{content,jdbcType=BLOB}
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.Process" >
update wf_process
set name = #{name,jdbcType=VARCHAR},
display_Name = #{displayName,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
instance_Url = #{instanceUrl,jdbcType=VARCHAR},
state = #{state,jdbcType=TINYINT},
version = #{version,jdbcType=TINYINT},
create_Time = #{createTime,jdbcType=VARCHAR},
creator = #{creator,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
</mapper>

View File

@ -0,0 +1,304 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="process.ProcessTechnicsMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.process.ProcessTechnics">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="modelid" jdbcType="VARCHAR" property="modelid" />
<result column="processid" jdbcType="VARCHAR" property="processid" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="MainProcedure" jdbcType="VARCHAR" property="mainprocedure" />
<result column="MainProcedureCode" jdbcType="VARCHAR" property="mainprocedurecode" />
<result column="SubProcedure" jdbcType="VARCHAR" property="subprocedure" />
<result column="SubProcedureCode" jdbcType="VARCHAR" property="subprocedurecode" />
<result column="ContentNO" jdbcType="VARCHAR" property="contentno" />
<result column="Subject" jdbcType="VARCHAR" property="subject" />
<result column="Specifications" jdbcType="VARCHAR" property="specifications" />
<result column="Mode" jdbcType="VARCHAR" property="mode" />
<result column="Tool" jdbcType="VARCHAR" property="tool" />
<result column="Frequency" jdbcType="VARCHAR" property="frequency" />
<result column="People" jdbcType="VARCHAR" property="people" />
<result column="Rejects" jdbcType="VARCHAR" property="rejects" />
<result column="FileName" jdbcType="VARCHAR" property="filename" />
<result column="FileId" jdbcType="VARCHAR" property="fileid" />
<result column="FormName" jdbcType="VARCHAR" property="formname" />
<result column="FormId" jdbcType="VARCHAR" property="formid" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
</resultMap>
<sql id="Base_Column_List">
id, modelid, processid, insdt, insuser, MainProcedure, MainProcedureCode, SubProcedure,
SubProcedureCode, ContentNO, Subject, Specifications, Mode, Tool, Frequency, People,
Rejects, FileName, FileId, FormName, FormId, remark
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_process_technics
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_process_technics
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.ProcessTechnics">
insert into tb_process_technics (id, modelid, processid,
insdt, insuser, MainProcedure,
MainProcedureCode, SubProcedure, SubProcedureCode,
ContentNO, Subject, Specifications,
Mode, Tool, Frequency,
People, Rejects, FileName,
FileId, FormName, FormId,
remark)
values (#{id,jdbcType=VARCHAR}, #{modelid,jdbcType=VARCHAR}, #{processid,jdbcType=VARCHAR},
#{insdt,jdbcType=TIMESTAMP}, #{insuser,jdbcType=VARCHAR}, #{mainprocedure,jdbcType=VARCHAR},
#{mainprocedurecode,jdbcType=VARCHAR}, #{subprocedure,jdbcType=VARCHAR}, #{subprocedurecode,jdbcType=VARCHAR},
#{contentno,jdbcType=VARCHAR}, #{subject,jdbcType=VARCHAR}, #{specifications,jdbcType=VARCHAR},
#{mode,jdbcType=VARCHAR}, #{tool,jdbcType=VARCHAR}, #{frequency,jdbcType=VARCHAR},
#{people,jdbcType=VARCHAR}, #{rejects,jdbcType=VARCHAR}, #{filename,jdbcType=VARCHAR},
#{fileid,jdbcType=VARCHAR}, #{formname,jdbcType=VARCHAR}, #{formid,jdbcType=VARCHAR},
#{remark,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.ProcessTechnics">
insert into tb_process_technics
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="modelid != null">
modelid,
</if>
<if test="processid != null">
processid,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="mainprocedure != null">
MainProcedure,
</if>
<if test="mainprocedurecode != null">
MainProcedureCode,
</if>
<if test="subprocedure != null">
SubProcedure,
</if>
<if test="subprocedurecode != null">
SubProcedureCode,
</if>
<if test="contentno != null">
ContentNO,
</if>
<if test="subject != null">
Subject,
</if>
<if test="specifications != null">
Specifications,
</if>
<if test="mode != null">
Mode,
</if>
<if test="tool != null">
Tool,
</if>
<if test="frequency != null">
Frequency,
</if>
<if test="people != null">
People,
</if>
<if test="rejects != null">
Rejects,
</if>
<if test="filename != null">
FileName,
</if>
<if test="fileid != null">
FileId,
</if>
<if test="formname != null">
FormName,
</if>
<if test="formid != null">
FormId,
</if>
<if test="remark != null">
remark,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="modelid != null">
#{modelid,jdbcType=VARCHAR},
</if>
<if test="processid != null">
#{processid,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="mainprocedure != null">
#{mainprocedure,jdbcType=VARCHAR},
</if>
<if test="mainprocedurecode != null">
#{mainprocedurecode,jdbcType=VARCHAR},
</if>
<if test="subprocedure != null">
#{subprocedure,jdbcType=VARCHAR},
</if>
<if test="subprocedurecode != null">
#{subprocedurecode,jdbcType=VARCHAR},
</if>
<if test="contentno != null">
#{contentno,jdbcType=VARCHAR},
</if>
<if test="subject != null">
#{subject,jdbcType=VARCHAR},
</if>
<if test="specifications != null">
#{specifications,jdbcType=VARCHAR},
</if>
<if test="mode != null">
#{mode,jdbcType=VARCHAR},
</if>
<if test="tool != null">
#{tool,jdbcType=VARCHAR},
</if>
<if test="frequency != null">
#{frequency,jdbcType=VARCHAR},
</if>
<if test="people != null">
#{people,jdbcType=VARCHAR},
</if>
<if test="rejects != null">
#{rejects,jdbcType=VARCHAR},
</if>
<if test="filename != null">
#{filename,jdbcType=VARCHAR},
</if>
<if test="fileid != null">
#{fileid,jdbcType=VARCHAR},
</if>
<if test="formname != null">
#{formname,jdbcType=VARCHAR},
</if>
<if test="formid != null">
#{formid,jdbcType=VARCHAR},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.ProcessTechnics">
update tb_process_technics
<set>
<if test="modelid != null">
modelid = #{modelid,jdbcType=VARCHAR},
</if>
<if test="processid != null">
processid = #{processid,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="mainprocedure != null">
MainProcedure = #{mainprocedure,jdbcType=VARCHAR},
</if>
<if test="mainprocedurecode != null">
MainProcedureCode = #{mainprocedurecode,jdbcType=VARCHAR},
</if>
<if test="subprocedure != null">
SubProcedure = #{subprocedure,jdbcType=VARCHAR},
</if>
<if test="subprocedurecode != null">
SubProcedureCode = #{subprocedurecode,jdbcType=VARCHAR},
</if>
<if test="contentno != null">
ContentNO = #{contentno,jdbcType=VARCHAR},
</if>
<if test="subject != null">
Subject = #{subject,jdbcType=VARCHAR},
</if>
<if test="specifications != null">
Specifications = #{specifications,jdbcType=VARCHAR},
</if>
<if test="mode != null">
Mode = #{mode,jdbcType=VARCHAR},
</if>
<if test="tool != null">
Tool = #{tool,jdbcType=VARCHAR},
</if>
<if test="frequency != null">
Frequency = #{frequency,jdbcType=VARCHAR},
</if>
<if test="people != null">
People = #{people,jdbcType=VARCHAR},
</if>
<if test="rejects != null">
Rejects = #{rejects,jdbcType=VARCHAR},
</if>
<if test="filename != null">
FileName = #{filename,jdbcType=VARCHAR},
</if>
<if test="fileid != null">
FileId = #{fileid,jdbcType=VARCHAR},
</if>
<if test="formname != null">
FormName = #{formname,jdbcType=VARCHAR},
</if>
<if test="formid != null">
FormId = #{formid,jdbcType=VARCHAR},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.ProcessTechnics">
update tb_process_technics
set modelid = #{modelid,jdbcType=VARCHAR},
processid = #{processid,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
insuser = #{insuser,jdbcType=VARCHAR},
MainProcedure = #{mainprocedure,jdbcType=VARCHAR},
MainProcedureCode = #{mainprocedurecode,jdbcType=VARCHAR},
SubProcedure = #{subprocedure,jdbcType=VARCHAR},
SubProcedureCode = #{subprocedurecode,jdbcType=VARCHAR},
ContentNO = #{contentno,jdbcType=VARCHAR},
Subject = #{subject,jdbcType=VARCHAR},
Specifications = #{specifications,jdbcType=VARCHAR},
Mode = #{mode,jdbcType=VARCHAR},
Tool = #{tool,jdbcType=VARCHAR},
Frequency = #{frequency,jdbcType=VARCHAR},
People = #{people,jdbcType=VARCHAR},
Rejects = #{rejects,jdbcType=VARCHAR},
FileName = #{filename,jdbcType=VARCHAR},
FileId = #{fileid,jdbcType=VARCHAR},
FormName = #{formname,jdbcType=VARCHAR},
FormId = #{formid,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_process_technics
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_process_technics
${where}
</delete>
</mapper>

View File

@ -0,0 +1,132 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.RealDetailsBookMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.RealDetailsBook" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="bookid" property="bookid" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="upduser" property="upduser" jdbcType="VARCHAR" />
<result column="upddt" property="upddt" jdbcType="TIMESTAMP" />
<association column="bookid" property="book" jdbcType="VARCHAR" select="selectBook"/>
</resultMap>
<select id="selectBook" parameterType="String" resultType="com.sipai.entity.document.Data">
select * from tb_doc_data where id = #{bookid}
</select>
<sql id="Base_Column_List" >
id, pid, bookid, insuser, insdt, upduser, upddt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_book
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_real_details_book
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.RealDetailsBook" >
insert into tb_process_real_details_book (id, pid, bookid,
insuser, insdt, upduser,
upddt)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{bookid,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{upduser,jdbcType=VARCHAR},
#{upddt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.RealDetailsBook" >
insert into tb_process_real_details_book
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="pid != null" >
pid,
</if>
<if test="bookid != null" >
bookid,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="upduser != null" >
upduser,
</if>
<if test="upddt != null" >
upddt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="pid != null" >
#{pid,jdbcType=VARCHAR},
</if>
<if test="bookid != null" >
#{bookid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="upduser != null" >
#{upduser,jdbcType=VARCHAR},
</if>
<if test="upddt != null" >
#{upddt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.RealDetailsBook" >
update tb_process_real_details_book
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="bookid != null" >
bookid = #{bookid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="upduser != null" >
upduser = #{upduser,jdbcType=VARCHAR},
</if>
<if test="upddt != null" >
upddt = #{upddt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.RealDetailsBook" >
update tb_process_real_details_book
set pid = #{pid,jdbcType=VARCHAR},
bookid = #{bookid,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
upduser = #{upduser,jdbcType=VARCHAR},
upddt = #{upddt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_book
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_real_details_book
${where}
</delete>
</mapper>

View File

@ -0,0 +1,78 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.RealDetailsEquipmentMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.RealDetailsEquipment" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="equipmentid" property="equipmentid" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="upduser" property="upduser" jdbcType="VARCHAR" />
<result column="upddt" property="upddt" jdbcType="TIMESTAMP" />
<association column="equipmentid" property="equipment" jdbcType="VARCHAR" select="selectEquipment"/>
</resultMap>
<select id="selectEquipment" parameterType="String" resultType="com.sipai.entity.equipment.EquipmentCard">
select TB_EM_EquipmentCard.*,TB_EM_EquipmentClass.name as equipmentclassname
from TB_EM_EquipmentCard left join TB_EM_EquipmentClass
on TB_EM_EquipmentClass.id=TB_EM_EquipmentCard.equipmentclassid
where TB_EM_EquipmentCard.id = #{equipmentid}
</select>
<sql id="Base_Column_List" >
id, pid, equipmentid, insuser, insdt, upduser, upddt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_equipment
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_real_details_equipment
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.RealDetailsEquipment" >
insert into tb_process_real_details_equipment (id, pid, equipmentid,
insuser, insdt, upduser,
upddt)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{equipmentid,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{upduser,jdbcType=VARCHAR},
#{upddt,jdbcType=TIMESTAMP})
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.RealDetailsEquipment" >
update tb_process_real_details_equipment
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="equipmentid != null" >
equipmentid = #{equipmentid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="upduser != null" >
upduser = #{upduser,jdbcType=VARCHAR},
</if>
<if test="upddt != null" >
upddt = #{upddt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_equipment
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_real_details_equipment
${where}
</delete>
</mapper>

View File

@ -0,0 +1,82 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.RealDetailsJobMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.RealDetailsJob" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="unitid" property="unitid" jdbcType="VARCHAR" />
<result column="jobid" property="jobid" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="upduser" property="upduser" jdbcType="VARCHAR" />
<result column="upddt" property="upddt" jdbcType="TIMESTAMP" />
<association column="unitid" property="unitname" jdbcType="VARCHAR" select="selectUnit"/>
<association column="jobid" property="jobname" jdbcType="VARCHAR" select="selectJob"/>
</resultMap>
<select id="selectUnit" parameterType="String" resultType="String">
select name from uv_unit where id = #{unitid}
</select>
<select id="selectJob" parameterType="String" resultType="String">
select name from tb_job where id = #{jobid}
</select>
<sql id="Base_Column_List" >
id, pid, unitid, jobid, insuser, insdt, upduser, upddt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_job
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_real_details_job
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.RealDetailsJob" >
insert into tb_process_real_details_job (id, pid, unitid, jobid,
insuser, insdt, upduser,
upddt)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{unitid,jdbcType=VARCHAR}, #{jobid,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{upduser,jdbcType=VARCHAR},
#{upddt,jdbcType=TIMESTAMP})
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.RealDetailsJob" >
update tb_process_real_details_job
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="unitid != null" >
unitid = #{unitid,jdbcType=VARCHAR},
</if>
<if test="jobid != null" >
jobid = #{jobid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="upduser != null" >
upduser = #{upduser,jdbcType=VARCHAR},
</if>
<if test="upddt != null" >
upddt = #{upddt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_job
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_real_details_job
${where}
</delete>
</mapper>

View File

@ -0,0 +1,104 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.RealDetailsMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.RealDetails" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="number" property="number" jdbcType="INTEGER" />
<result column="taskname" property="taskname" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="SOP" property="sop" jdbcType="VARCHAR" />
<result column="worktime" property="worktime" jdbcType="VARCHAR" />
<result column="description" property="description" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="updateuser" property="updateuser" jdbcType="VARCHAR" />
<result column="updatedt" property="updatedt" jdbcType="TIMESTAMP" />
<result column="ST" property="st" jdbcType="VARCHAR" />
<association column="pid" property="pname" jdbcType="VARCHAR" select="selectPname"/>
</resultMap>
<select id="selectPname" resultType="java.lang.String" parameterType="java.lang.String" >
select name from tb_process_real where id = #{pid,jdbcType=VARCHAR}
</select>
<sql id="Base_Column_List" >
id, pid, number, taskname, name, SOP, worktime, description, insuser, insdt, updateuser, updatedt,
ST
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_real_details
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.RealDetails" >
insert into tb_process_real_details (id, pid, number,
taskname, name, SOP, worktime,
description, insuser, insdt,
updateuser, updatedt, ST
)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{number,jdbcType=INTEGER},
#{taskname,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR}, #{sop,jdbcType=VARCHAR}, #{worktime,jdbcType=VARCHAR},
#{description,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{updateuser,jdbcType=VARCHAR}, #{updatedt,jdbcType=TIMESTAMP}, #{st,jdbcType=VARCHAR}
)
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.RealDetails" >
update tb_process_real_details
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="number != null" >
number = #{number,jdbcType=INTEGER},
</if>
<if test="taskname != null" >
taskname = #{taskname,jdbcType=VARCHAR},
</if>
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="sop != null" >
SOP = #{sop,jdbcType=VARCHAR},
</if>
<if test="worktime != null" >
worktime = #{worktime,jdbcType=VARCHAR},
</if>
<if test="description != null" >
description = #{description,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="updateuser != null" >
updateuser = #{updateuser,jdbcType=VARCHAR},
</if>
<if test="updatedt != null" >
updatedt = #{updatedt,jdbcType=TIMESTAMP},
</if>
<if test="st != null" >
ST = #{st,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_real_details
${where}
</delete>
</mapper>

View File

@ -0,0 +1,79 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.RealDetailsMaterialMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.RealDetailsMaterial" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="amount" property="amount" jdbcType="FLOAT" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="upduser" property="upduser" jdbcType="VARCHAR" />
<result column="upddt" property="upddt" jdbcType="TIMESTAMP" />
<association column="materialid" property="material" jdbcType="VARCHAR" select="selectMaterial"/>
</resultMap>
<select id="selectMaterial" parameterType="String" resultType="com.sipai.entity.material.MaterialInfo">
select * from tb_material_info where id = #{materialid}
</select>
<sql id="Base_Column_List" >
id, pid, materialid, amount, insuser, insdt, upduser, upddt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_material
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_real_details_material
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.RealDetailsMaterial" >
insert into tb_process_real_details_material (id, pid, materialid, amount,
insuser, insdt, upduser,
upddt)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{materialid,jdbcType=VARCHAR}, #{amount,jdbcType=FLOAT},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{upduser,jdbcType=VARCHAR},
#{upddt,jdbcType=TIMESTAMP})
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.RealDetailsMaterial" >
update tb_process_real_details_material
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="amount != null" >
amount = #{amount,jdbcType=FLOAT},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="upduser != null" >
upduser = #{upduser,jdbcType=VARCHAR},
</if>
<if test="upddt != null" >
upddt = #{upddt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_material
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_real_details_material
${where}
</delete>
</mapper>

View File

@ -0,0 +1,71 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.RealDetailsStepMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.RealDetailsStep" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="ord" property="ord" jdbcType="INTEGER" />
<result column="content" property="content" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="upduser" property="upduser" jdbcType="VARCHAR" />
<result column="upddt" property="upddt" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, pid, ord, content, insuser, insdt, upduser, upddt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_step
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_real_details_step
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.RealDetailsStep" >
insert into tb_process_real_details_step (id, pid, ord, content,
insuser, insdt, upduser, upddt)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{ord,jdbcType=INTEGER}, #{content,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{upduser,jdbcType=VARCHAR}, #{upddt,jdbcType=TIMESTAMP})
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.RealDetailsStep" >
update tb_process_real_details_step
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="ord != null" >
ord = #{ord,jdbcType=INTEGER},
</if>
<if test="content != null" >
content = #{content,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="upduser != null" >
upduser = #{upduser,jdbcType=VARCHAR},
</if>
<if test="upddt != null" >
upddt = #{upddt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_step
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_real_details_step
${where}
</delete>
</mapper>

View File

@ -0,0 +1,90 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.RealDetailsWorkstationMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.RealDetailsWorkstation" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="pid" property="pid" jdbcType="VARCHAR" />
<result column="workstationid" property="workstationid" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="upduser" property="upduser" jdbcType="VARCHAR" />
<result column="upddt" property="upddt" jdbcType="TIMESTAMP" />
<association column="workstationid" property="workstation" jdbcType="VARCHAR" select="selectWorkstation"/>
</resultMap>
<select id="selectWorkstation" parameterType="String" resultType="com.sipai.entity.work.Workstation">
select tb_work_workstation.* ,tb_work_workstation_type.name as typename ,uv_unit.name as deptname ,tb_work_line.name as linename
from tb_work_workstation
left join tb_work_line_workstation on tb_work_line_workstation.workstationid = tb_work_workstation.id
left join tb_work_line on tb_work_line.id = tb_work_line_workstation.lineid
left join tb_work_workstation_type on tb_work_workstation_type.id = tb_work_workstation.typeid
left join uv_unit on uv_unit.id = tb_work_workstation.deptid
where tb_work_workstation.id = #{workstationid}
</select>
<sql id="Base_Column_List" >
id, pid, workstationid, insuser, insdt, upduser, upddt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_workstation
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_real_details_workstation
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.RealDetailsWorkstation" >
insert into tb_process_real_details_workstation (id, pid, workstationid,
insuser, insdt, upduser,
upddt)
values (#{id,jdbcType=VARCHAR}, #{pid,jdbcType=VARCHAR}, #{workstationid,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{upduser,jdbcType=VARCHAR},
#{upddt,jdbcType=TIMESTAMP})
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.RealDetailsWorkstation" >
update tb_process_real_details_workstation
<set >
<if test="pid != null" >
pid = #{pid,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
workstationid = #{workstationid,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="upduser != null" >
upduser = #{upduser,jdbcType=VARCHAR},
</if>
<if test="upddt != null" >
upddt = #{upddt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real_details_workstation
${where}
</select>
<select id="selectListByWhere1" resultMap="BaseResultMap" parameterType="java.lang.String" >
select tb_process_real_details_workstation.*,tb_work_line.id as lineid,tb_work_line.name as linename
from tb_process_real_details_workstation
left join tb_work_workstation on tb_work_workstation.id=tb_process_real_details_workstation.workstationid
left join tb_work_line_workstation on tb_work_workstation.id=tb_work_line_workstation.workstationid
left join tb_work_line on tb_work_line.id=tb_work_line_workstation.lineid
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_real_details_workstation
${where}
</delete>
</mapper>

View File

@ -0,0 +1,128 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.RealMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.Real" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="processid" property="processid" jdbcType="VARCHAR" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="productid" property="productid" jdbcType="VARCHAR" />
<result column="lineid" property="lineid" jdbcType="VARCHAR" />
<result column="drawing" property="drawing" jdbcType="VARCHAR" />
<result column="bomId" property="bomid" jdbcType="VARCHAR" />
<result column="description" property="description" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="updateuser" property="updateuser" jdbcType="VARCHAR" />
<result column="updatedt" property="updatedt" jdbcType="TIMESTAMP" />
<result column="st" property="st" jdbcType="VARCHAR" />
<association column="productid" property="product" jdbcType="VARCHAR" select="selectProd"/>
<association column="processid" property="process" jdbcType="VARCHAR" select="selectProcess"/>
</resultMap>
<select id="selectProd" parameterType="String" resultType="com.sipai.entity.material.MaterialInfo">
select * from tb_material_info where id = #{productid}
</select>
<select id="selectProcess" parameterType="String" resultType="com.sipai.entity.process.Processes">
select * from wf_process where id = #{processid}
</select>
<sql id="Base_Column_List" >
id, processid, name, productid, lineid, drawing, bomId, description, insuser, insdt, updateuser,
updatedt, st
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real
where id = #{id,jdbcType=VARCHAR}
</select>
<select id="getListByName" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real
where name = #{name,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_real
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.Real" >
insert into tb_process_real (id, processid, name,
productid, lineid, drawing, bomId,
description, insuser, insdt,
updateuser, updatedt, st
)
values (#{id,jdbcType=VARCHAR}, #{processid,jdbcType=VARCHAR}, #{name,jdbcType=VARCHAR},
#{productid,jdbcType=VARCHAR}, #{lineid,jdbcType=VARCHAR}, #{drawing,jdbcType=VARCHAR}, #{bomid,jdbcType=VARCHAR},
#{description,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{updateuser,jdbcType=VARCHAR}, #{updatedt,jdbcType=TIMESTAMP}, #{st,jdbcType=VARCHAR}
)
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.Real" >
update tb_process_real
<set >
<if test="processid != null" >
processid = #{processid,jdbcType=VARCHAR},
</if>
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="productid != null" >
productid = #{productid,jdbcType=VARCHAR},
</if>
<if test="lineid != null" >
lineid = #{lineid,jdbcType=VARCHAR},
</if>
<if test="drawing != null" >
drawing = #{drawing,jdbcType=VARCHAR},
</if>
<if test="bomid != null" >
bomId = #{bomid,jdbcType=VARCHAR},
</if>
<if test="description != null" >
description = #{description,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="updateuser != null" >
updateuser = #{updateuser,jdbcType=VARCHAR},
</if>
<if test="updatedt != null" >
updatedt = #{updatedt,jdbcType=TIMESTAMP},
</if>
<if test="st != null" >
st = #{st,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_real
${where}
</select>
<select id="selectListByDetailsID" resultMap="BaseResultMap" parameterType="java.lang.String" >
select distinct a.* from tb_process_real a
left join tb_process_real_details b on b.pid=a.id
${where}
</select>
<select id="getLineListByWhere" resultType="com.sipai.entity.work.Line" parameterType="java.lang.String" >
SELECT DISTINCT tb_work_line.*
FROM tb_work_line_workstation INNER JOIN
tb_work_workstation ON tb_work_line_workstation.workstationid = tb_work_workstation.id INNER JOIN
tb_work_line ON tb_work_line_workstation.lineid = tb_work_line.id INNER JOIN
tb_process_real_details INNER JOIN
tb_process_real_details_workstation ON tb_process_real_details.id = tb_process_real_details_workstation.pid ON
tb_work_workstation.id = tb_process_real_details_workstation.workstationid
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_real
${where}
</delete>
</mapper>

View File

@ -0,0 +1,103 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.StaffSkillMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.StaffSkill" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="name" property="name" jdbcType="VARCHAR" />
<result column="property" property="property" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, name, property
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_skill
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_skill
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.StaffSkill" >
insert into tb_process_skill (id, insuser, insdt,
name, property)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{name,jdbcType=VARCHAR}, #{property,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.StaffSkill" >
insert into tb_process_skill
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="name != null" >
name,
</if>
<if test="property != null" >
property,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="name != null" >
#{name,jdbcType=VARCHAR},
</if>
<if test="property != null" >
#{property,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.StaffSkill" >
update tb_process_skill
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="name != null" >
name = #{name,jdbcType=VARCHAR},
</if>
<if test="property != null" >
property = #{property,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.StaffSkill" >
update tb_process_skill
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
name = #{name,jdbcType=VARCHAR},
property = #{property,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_skill
${where}
</delete>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_skill
${where}
</select>
</mapper>

View File

@ -0,0 +1,181 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.TaskEquipmentMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.TaskEquipment" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="processid" property="processid" jdbcType="VARCHAR" />
<result column="taskname" property="taskname" jdbcType="VARCHAR" />
<result column="equipmentid" property="equipmentid" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="memo" property="memo" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<association column="equipmentid" property="equipmentCard" jdbcType="VARCHAR" select="selectEquipment"/>
</resultMap>
<select id="selectEquipment" parameterType="String" resultType="com.sipai.entity.equipment.EquipmentCard">
select TB_EM_EquipmentCard.*,TB_EM_EquipmentClass.name as equipmentclassname
from TB_EM_EquipmentCard left join TB_EM_EquipmentClass
on TB_EM_EquipmentClass.id=TB_EM_EquipmentCard.equipmentclassid
where TB_EM_EquipmentCard.id = #{equipmentid}
</select>
<sql id="Base_Column_List" >
id, processid, taskname, equipmentid, status, memo, insuser, insdt, modify, modifydt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_equipment
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_task_equipment
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.TaskEquipment" >
insert into tb_process_task_equipment (id, processid, taskname,
equipmentid, status, memo,
insuser, insdt, modify,
modifydt)
values (#{id,jdbcType=VARCHAR}, #{processid,jdbcType=VARCHAR}, #{taskname,jdbcType=VARCHAR},
#{equipmentid,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR}, #{memo,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{modify,jdbcType=VARCHAR},
#{modifydt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.TaskEquipment" >
insert into tb_process_task_equipment
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="processid != null" >
processid,
</if>
<if test="taskname != null" >
taskname,
</if>
<if test="equipmentid != null" >
equipmentid,
</if>
<if test="status != null" >
status,
</if>
<if test="memo != null" >
memo,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="processid != null" >
#{processid,jdbcType=VARCHAR},
</if>
<if test="taskname != null" >
#{taskname,jdbcType=VARCHAR},
</if>
<if test="equipmentid != null" >
#{equipmentid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="memo != null" >
#{memo,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.TaskEquipment" >
update tb_process_task_equipment
<set >
<if test="processid != null" >
processid = #{processid,jdbcType=VARCHAR},
</if>
<if test="taskname != null" >
taskname = #{taskname,jdbcType=VARCHAR},
</if>
<if test="equipmentid != null" >
equipmentid = #{equipmentid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="memo != null" >
memo = #{memo,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.TaskEquipment" >
update tb_process_task_equipment
set processid = #{processid,jdbcType=VARCHAR},
taskname = #{taskname,jdbcType=VARCHAR},
equipmentid = #{equipmentid,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
memo = #{memo,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_equipment
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_task_equipment
${where}
</delete>
<select id="selectListByWhere1" parameterType="String" resultMap="BaseResultMap">
SELECT tb_process_task_equipment.*,TB_EM_EquipmentCard.equipmentCardID,TB_EM_EquipmentCard.equipmentName,
TB_EM_EquipmentCard.equipmentModel,TB_EM_EquipmentClass.name as equipmentClass,TB_EM_GeographyArea.name as geographyArea,
TB_EM_EquipmentCard.currentManageFlag,TB_EM_EquipmentCard.remark
FROM tb_process_task_equipment
left join TB_EM_EquipmentCard on TB_EM_EquipmentCard.id = tb_process_task_equipment.equipmentid
left join TB_EM_EquipmentClass on TB_EM_EquipmentClass.id = TB_EM_EquipmentCard.equipmentClassID
left join TB_EM_GeographyArea on TB_EM_GeographyArea.id = TB_EM_EquipmentCard.areaID
left join tb_process_real on tb_process_real.processid=tb_process_task_equipment.processid
left join tb_process_real_details on tb_process_real_details.pid=tb_process_real.id
${where}
</select>
</mapper>

View File

@ -0,0 +1,177 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.TaskMaterialMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.TaskMaterial" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="processid" property="processid" jdbcType="VARCHAR" />
<result column="taskname" property="taskname" jdbcType="VARCHAR" />
<result column="materialid" property="materialid" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="memo" property="memo" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<association column="materialid" property="materialInfo" jdbcType="VARCHAR" select="selectMaterial"/>
</resultMap>
<select id="selectMaterial" parameterType="String" resultType="com.sipai.entity.material.MaterialInfo">
select * from tb_material_info where id = #{materialid}
</select>
<sql id="Base_Column_List" >
id, processid, taskname, materialid, status, memo, insuser, insdt, modify, modifydt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_material
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_task_material
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.TaskMaterial" >
insert into tb_process_task_material (id, processid, taskname,
materialid, status, memo,
insuser, insdt, modify,
modifydt)
values (#{id,jdbcType=VARCHAR}, #{processid,jdbcType=VARCHAR}, #{taskname,jdbcType=VARCHAR},
#{materialid,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR}, #{memo,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{modify,jdbcType=VARCHAR},
#{modifydt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.TaskMaterial" >
insert into tb_process_task_material
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="processid != null" >
processid,
</if>
<if test="taskname != null" >
taskname,
</if>
<if test="materialid != null" >
materialid,
</if>
<if test="status != null" >
status,
</if>
<if test="memo != null" >
memo,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="processid != null" >
#{processid,jdbcType=VARCHAR},
</if>
<if test="taskname != null" >
#{taskname,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
#{materialid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="memo != null" >
#{memo,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.TaskMaterial" >
update tb_process_task_material
<set >
<if test="processid != null" >
processid = #{processid,jdbcType=VARCHAR},
</if>
<if test="taskname != null" >
taskname = #{taskname,jdbcType=VARCHAR},
</if>
<if test="materialid != null" >
materialid = #{materialid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="memo != null" >
memo = #{memo,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.TaskMaterial" >
update tb_process_task_material
set processid = #{processid,jdbcType=VARCHAR},
taskname = #{taskname,jdbcType=VARCHAR},
materialid = #{materialid,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
memo = #{memo,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_material
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_task_material
${where}
</delete>
<select id="selectListByWhere1" parameterType="String" resultMap="BaseResultMap">
SELECT tb_process_task_material.*,tb_material_info.materialcode,tb_material_info.materialname,
tb_material_info.spec,tb_material_info.unit,tb_material_type.typename
FROM tb_process_task_material
left join tb_material_info on tb_material_info.id = tb_process_task_material.materialid
left join tb_material_type on tb_material_type.id = tb_material_info.typeid
left join tb_process_real on tb_process_real.processid=tb_process_task_material.processid
left join tb_process_real_details on tb_process_real_details.pid=tb_process_real.id
${where}
</select>
</mapper>

View File

@ -0,0 +1,174 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="process.TaskProcedureMapper">
<resultMap id="BaseResultMap" type="com.sipai.entity.process.TaskProcedure">
<id column="id" jdbcType="VARCHAR" property="id" />
<result column="insuser" jdbcType="VARCHAR" property="insuser" />
<result column="insdt" jdbcType="TIMESTAMP" property="insdt" />
<result column="procedurecode" jdbcType="VARCHAR" property="procedurecode" />
<result column="procedurename" jdbcType="VARCHAR" property="procedurename" />
<result column="workstation" jdbcType="VARCHAR" property="workstation" />
<result column="keywords" jdbcType="VARCHAR" property="keywords" />
<result column="type" jdbcType="VARCHAR" property="type" />
<result column="semiflag" jdbcType="VARCHAR" property="semiflag" />
</resultMap>
<sql id="Base_Column_List">
id, insuser, insdt, procedurecode, procedurename, workstation, keywords, type, semiflag
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_process_task_procedure
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String">
delete from tb_process_task_procedure
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.TaskProcedure">
insert into tb_process_task_procedure (id, insuser, insdt,
procedurecode, procedurename, workstation,
keywords, type, semiflag
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{procedurecode,jdbcType=VARCHAR}, #{procedurename,jdbcType=VARCHAR}, #{workstation,jdbcType=VARCHAR},
#{keywords,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{semiflag,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.TaskProcedure">
insert into tb_process_task_procedure
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="insuser != null">
insuser,
</if>
<if test="insdt != null">
insdt,
</if>
<if test="procedurecode != null">
procedurecode,
</if>
<if test="procedurename != null">
procedurename,
</if>
<if test="workstation != null">
workstation,
</if>
<if test="keywords != null">
keywords,
</if>
<if test="type != null">
type,
</if>
<if test="semiflag != null">
semiflag,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null">
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="procedurecode != null">
#{procedurecode,jdbcType=VARCHAR},
</if>
<if test="procedurename != null">
#{procedurename,jdbcType=VARCHAR},
</if>
<if test="workstation != null">
#{workstation,jdbcType=VARCHAR},
</if>
<if test="keywords != null">
#{keywords,jdbcType=VARCHAR},
</if>
<if test="type != null">
#{type,jdbcType=VARCHAR},
</if>
<if test="semiflag != null">
#{semiflag,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.TaskProcedure">
update tb_process_task_procedure
<set>
<if test="insuser != null">
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null">
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="procedurecode != null">
procedurecode = #{procedurecode,jdbcType=VARCHAR},
</if>
<if test="procedurename != null">
procedurename = #{procedurename,jdbcType=VARCHAR},
</if>
<if test="workstation != null">
workstation = #{workstation,jdbcType=VARCHAR},
</if>
<if test="keywords != null">
keywords = #{keywords,jdbcType=VARCHAR},
</if>
<if test="type != null">
type = #{type,jdbcType=VARCHAR},
</if>
<if test="semiflag != null">
semiflag = #{semiflag,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.TaskProcedure">
update tb_process_task_procedure
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
procedurecode = #{procedurecode,jdbcType=VARCHAR},
procedurename = #{procedurename,jdbcType=VARCHAR},
workstation = #{workstation,jdbcType=VARCHAR},
keywords = #{keywords,jdbcType=VARCHAR},
type = #{type,jdbcType=VARCHAR},
semiflag = #{semiflag,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_process_task_procedure
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String">
delete from tb_process_task_procedure
${where}
</delete>
<select id="selectByProcedurecode" parameterType="java.lang.String" resultMap="BaseResultMap">
select
<include refid="Base_Column_List" />
from tb_process_task_procedure
where procedurecode = #{procedurecode,jdbcType=VARCHAR}
</select>
<select id="selectByProcedureOrder" parameterType="java.lang.String" resultMap="BaseResultMap">
SELECT P.id
,P.insuser
,P.insdt
,P.procedurecode AS procedurecode
,P.procedurename AS procedurename
,P.workstation AS workstation
,P.keywords AS keywords
,P.type AS type
,P.semiflag AS semiflag
,O.priorityorder,
O.sorttype
FROM tb_process_task_procedure_order O
left outer join tb_process_task_procedure P on O.procedureid = P.id
${where}
</select>
</mapper>

View File

@ -0,0 +1,118 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.TaskProcedureOrderMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.TaskProcedureOrder" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="procedureid" property="procedureid" jdbcType="VARCHAR" />
<result column="priorityorder" property="priorityorder" jdbcType="INTEGER" />
<result column="sorttype" property="sorttype" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, procedureid, priorityorder, sorttype
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_procedure_order
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_task_procedure_order
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.TaskProcedureOrder" >
insert into tb_process_task_procedure_order (id, insuser, insdt,
procedureid, priorityorder, sorttype
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{procedureid,jdbcType=VARCHAR}, #{priorityorder,jdbcType=INTEGER}, #{sorttype,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.TaskProcedureOrder" >
insert into tb_process_task_procedure_order
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="procedureid != null" >
procedureid,
</if>
<if test="priorityorder != null" >
priorityorder,
</if>
<if test="sorttype != null" >
sorttype,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="procedureid != null" >
#{procedureid,jdbcType=VARCHAR},
</if>
<if test="priorityorder != null" >
#{priorityorder,jdbcType=INTEGER},
</if>
<if test="sorttype != null" >
#{sorttype,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.TaskProcedureOrder" >
update tb_process_task_procedure_order
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="procedureid != null" >
procedureid = #{procedureid,jdbcType=VARCHAR},
</if>
<if test="priorityorder != null" >
priorityorder = #{priorityorder,jdbcType=INTEGER},
</if>
<if test="sorttype != null" >
sorttype = #{sorttype,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.TaskProcedureOrder" >
update tb_process_task_procedure_order
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
procedureid = #{procedureid,jdbcType=VARCHAR},
priorityorder = #{priorityorder,jdbcType=INTEGER},
sorttype = #{sorttype,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_procedure_order
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_task_procedure_order
${where}
</delete>
</mapper>

View File

@ -0,0 +1,114 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.TaskProcedureSkillMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.TaskProcedureSkill" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="userid" property="userid" jdbcType="VARCHAR" />
<result column="skillid" property="skillid" jdbcType="VARCHAR" />
<association column="userid" property="username" jdbcType="VARCHAR" select="selectUser"></association>
</resultMap>
<select id="selectUser" resultType="String" parameterType="java.lang.String" >
select caption from tb_user where id = #{userid,jdbcType=VARCHAR}
</select>
<sql id="Base_Column_List" >
id, insuser, insdt, userid, skillid
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_procedure_skill
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_task_procedure_skill
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.TaskProcedureSkill" >
insert into tb_process_task_procedure_skill (id, insuser, insdt,
userid, skillid)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{userid,jdbcType=VARCHAR}, #{skillid,jdbcType=VARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.TaskProcedureSkill" >
insert into tb_process_task_procedure_skill
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="userid != null" >
userid,
</if>
<if test="skillid != null" >
skillid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="userid != null" >
#{userid,jdbcType=VARCHAR},
</if>
<if test="skillid != null" >
#{skillid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.TaskProcedureSkill" >
update tb_process_task_procedure_skill
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="userid != null" >
userid = #{userid,jdbcType=VARCHAR},
</if>
<if test="skillid != null" >
skillid = #{skillid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.TaskProcedureSkill" >
update tb_process_task_procedure_skill
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
userid = #{userid,jdbcType=VARCHAR},
skillid = #{skillid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_procedure_skill
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_task_procedure_skill
${where}
</delete>
<select id="selectSkillByUser" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
skillid
from tb_process_task_procedure_skill
${where}
</select>
</mapper>

View File

@ -0,0 +1,124 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.TaskProcedureStaffMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.TaskProcedureStaff" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="procedureid" property="procedureid" jdbcType="VARCHAR" />
<result column="leaderid" property="leaderid" jdbcType="VARCHAR" />
<result column="chiefid" property="chiefid" jdbcType="VARCHAR" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, procedureid, leaderid, chiefid
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_procedure_staff
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_task_procedure_staff
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.TaskProcedureStaff" >
insert into tb_process_task_procedure_staff (id, insuser, insdt,
procedureid, leaderid, chiefid
)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{procedureid,jdbcType=VARCHAR}, #{leaderid,jdbcType=VARCHAR}, #{chiefid,jdbcType=VARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.TaskProcedureStaff" >
insert into tb_process_task_procedure_staff
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="procedureid != null" >
procedureid,
</if>
<if test="leaderid != null" >
leaderid,
</if>
<if test="chiefid != null" >
chiefid,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="procedureid != null" >
#{procedureid,jdbcType=VARCHAR},
</if>
<if test="leaderid != null" >
#{leaderid,jdbcType=VARCHAR},
</if>
<if test="chiefid != null" >
#{chiefid,jdbcType=VARCHAR},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.TaskProcedureStaff" >
update tb_process_task_procedure_staff
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="procedureid != null" >
procedureid = #{procedureid,jdbcType=VARCHAR},
</if>
<if test="leaderid != null" >
leaderid = #{leaderid,jdbcType=VARCHAR},
</if>
<if test="chiefid != null" >
chiefid = #{chiefid,jdbcType=VARCHAR},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.TaskProcedureStaff" >
update tb_process_task_procedure_staff
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
procedureid = #{procedureid,jdbcType=VARCHAR},
leaderid = #{leaderid,jdbcType=VARCHAR},
chiefid = #{chiefid,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_procedure_staff
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_task_procedure_staff
${where}
</delete>
<select id="getObjByProcedureid" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_procedure_staff
where procedureid = #{procedureid,jdbcType=VARCHAR}
order by insdt
</select>
</mapper>

View File

@ -0,0 +1,182 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="process.TaskWorkstationMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.process.TaskWorkstation" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="processid" property="processid" jdbcType="VARCHAR" />
<result column="taskname" property="taskname" jdbcType="VARCHAR" />
<result column="workstationid" property="workstationid" jdbcType="VARCHAR" />
<result column="status" property="status" jdbcType="VARCHAR" />
<result column="memo" property="memo" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="modify" property="modify" jdbcType="VARCHAR" />
<result column="modifydt" property="modifydt" jdbcType="TIMESTAMP" />
<association column="workstationid" property="workStation" jdbcType="VARCHAR" select="selectWorkstation"/>
</resultMap>
<select id="selectWorkstation" parameterType="String" resultType="com.sipai.entity.work.Workstation">
select tb_work_workstation.* ,tb_work_workstation_type.name as typename ,tb_dept.name as deptname
from tb_work_workstation
left join tb_dept on tb_work_workstation.deptid = tb_dept.id
left join tb_work_workstation_type on tb_work_workstation_type.id = tb_work_workstation.typeid
where tb_work_workstation.id = #{workstationid}
</select>
<sql id="Base_Column_List" >
id, processid, taskname, workstationid, status, memo, insuser, insdt, modify, modifydt
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_workstation
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_process_task_workstation
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.process.TaskWorkstation" >
insert into tb_process_task_workstation (id, processid, taskname,
workstationid, status, memo,
insuser, insdt, modify,
modifydt)
values (#{id,jdbcType=VARCHAR}, #{processid,jdbcType=VARCHAR}, #{taskname,jdbcType=VARCHAR},
#{workstationid,jdbcType=VARCHAR}, #{status,jdbcType=VARCHAR}, #{memo,jdbcType=VARCHAR},
#{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP}, #{modify,jdbcType=VARCHAR},
#{modifydt,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.process.TaskWorkstation" >
insert into tb_process_task_workstation
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="processid != null" >
processid,
</if>
<if test="taskname != null" >
taskname,
</if>
<if test="workstationid != null" >
workstationid,
</if>
<if test="status != null" >
status,
</if>
<if test="memo != null" >
memo,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="modify != null" >
modify,
</if>
<if test="modifydt != null" >
modifydt,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="processid != null" >
#{processid,jdbcType=VARCHAR},
</if>
<if test="taskname != null" >
#{taskname,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
#{workstationid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
#{status,jdbcType=VARCHAR},
</if>
<if test="memo != null" >
#{memo,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
#{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
#{modifydt,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.process.TaskWorkstation" >
update tb_process_task_workstation
<set >
<if test="processid != null" >
processid = #{processid,jdbcType=VARCHAR},
</if>
<if test="taskname != null" >
taskname = #{taskname,jdbcType=VARCHAR},
</if>
<if test="workstationid != null" >
workstationid = #{workstationid,jdbcType=VARCHAR},
</if>
<if test="status != null" >
status = #{status,jdbcType=VARCHAR},
</if>
<if test="memo != null" >
memo = #{memo,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="modify != null" >
modify = #{modify,jdbcType=VARCHAR},
</if>
<if test="modifydt != null" >
modifydt = #{modifydt,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.process.TaskWorkstation" >
update tb_process_task_workstation
set processid = #{processid,jdbcType=VARCHAR},
taskname = #{taskname,jdbcType=VARCHAR},
workstationid = #{workstationid,jdbcType=VARCHAR},
status = #{status,jdbcType=VARCHAR},
memo = #{memo,jdbcType=VARCHAR},
insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
modify = #{modify,jdbcType=VARCHAR},
modifydt = #{modifydt,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_process_task_workstation
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_process_task_workstation
${where}
</delete>
<select id="selectListByWhere1" parameterType="String" resultMap="BaseResultMap">
SELECT tb_process_task_workstation.*,tb_dept.name as deptname,tb_work_workstation_type.name as typename,
tb_work_workstation.serial,tb_work_workstation.name
FROM tb_process_task_workstation
left join tb_work_workstation on tb_work_workstation.id = tb_process_task_workstation.workstationid
left join tb_work_workstation_type on tb_work_workstation.typeid = tb_work_workstation_type.id
left join tb_dept on tb_work_workstation.deptid = tb_dept.id
left join tb_process_real on tb_process_real.processid=tb_process_task_workstation.processid
left join tb_process_real_details on tb_process_real_details.pid=tb_process_real.id
${where}
</select>
</mapper>

View File

@ -0,0 +1,471 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="quality.AbnormalQualityMapper" >
<resultMap id="BaseResultMap" type="com.sipai.entity.quality.AbnormalQuality" >
<id column="id" property="id" jdbcType="VARCHAR" />
<result column="insuser" property="insuser" jdbcType="VARCHAR" />
<result column="insdt" property="insdt" jdbcType="TIMESTAMP" />
<result column="sendDept" property="senddept" jdbcType="VARCHAR" />
<result column="sender" property="sender" jdbcType="VARCHAR" />
<result column="sendTime" property="sendtime" jdbcType="TIMESTAMP" />
<result column="formNumber" property="formnumber" jdbcType="VARCHAR" />
<result column="acceptDept" property="acceptdept" jdbcType="VARCHAR" />
<result column="recipient" property="recipient" jdbcType="VARCHAR" />
<result column="acceptTime" property="accepttime" jdbcType="TIMESTAMP" />
<result column="confirmReceipt" property="confirmreceipt" jdbcType="VARCHAR" />
<result column="problemArea" property="problemarea" jdbcType="VARCHAR" />
<result column="severity" property="severity" jdbcType="VARCHAR" />
<result column="problemNumber" property="problemnumber" jdbcType="VARCHAR" />
<result column="descriptionBadPhenomena" property="descriptionbadphenomena" jdbcType="VARCHAR" />
<result column="Confirmor1" property="confirmor1" jdbcType="VARCHAR" />
<result column="date1" property="date1" jdbcType="TIMESTAMP" />
<result column="causeAnalysis" property="causeanalysis" jdbcType="VARCHAR" />
<result column="toDevelop" property="todevelop" jdbcType="VARCHAR" />
<result column="Confirmor2" property="confirmor2" jdbcType="VARCHAR" />
<result column="date2" property="date2" jdbcType="TIMESTAMP" />
<result column="EmergencyMeasuresPlan" property="emergencymeasuresplan" jdbcType="VARCHAR" />
<result column="estimatedFinishTime" property="estimatedfinishtime" jdbcType="TIMESTAMP" />
<result column="actualCompletionTime" property="actualcompletiontime" jdbcType="TIMESTAMP" />
<result column="toDevelop1" property="todevelop1" jdbcType="VARCHAR" />
<result column="Confirmor3" property="confirmor3" jdbcType="VARCHAR" />
<result column="date3" property="date3" jdbcType="TIMESTAMP" />
<result column="preventiveMeasures" property="preventivemeasures" jdbcType="VARCHAR" />
<result column="estimatedFinishTime1" property="estimatedfinishtime1" jdbcType="TIMESTAMP" />
<result column="actualCompletionTime1" property="actualcompletiontime1" jdbcType="TIMESTAMP" />
<result column="toDevelop2" property="todevelop2" jdbcType="VARCHAR" />
<result column="Confirmor4" property="confirmor4" jdbcType="VARCHAR" />
<result column="date4" property="date4" jdbcType="TIMESTAMP" />
<result column="effectTracking" property="effecttracking" jdbcType="VARCHAR" />
<result column="Confirmor5" property="confirmor5" jdbcType="VARCHAR" />
<result column="date5" property="date5" jdbcType="TIMESTAMP" />
</resultMap>
<sql id="Base_Column_List" >
id, insuser, insdt, sendDept, sender, sendTime, formNumber, acceptDept, recipient,
acceptTime, confirmReceipt, problemArea, severity, problemNumber, descriptionBadPhenomena,
Confirmor1, date1, causeAnalysis, toDevelop, Confirmor2, date2, EmergencyMeasuresPlan,
estimatedFinishTime, actualCompletionTime, toDevelop1, Confirmor3, date3, preventiveMeasures,
estimatedFinishTime1, actualCompletionTime1, toDevelop2, Confirmor4, date4, effectTracking,
Confirmor5, date5
</sql>
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_abnormal_quality
where id = #{id,jdbcType=VARCHAR}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.String" >
delete from tb_abnormal_quality
where id = #{id,jdbcType=VARCHAR}
</delete>
<insert id="insert" parameterType="com.sipai.entity.quality.AbnormalQuality" >
insert into tb_abnormal_quality (id, insuser, insdt,
sendDept, sender, sendTime,
formNumber, acceptDept, recipient,
acceptTime, confirmReceipt, problemArea,
severity, problemNumber, descriptionBadPhenomena,
Confirmor1, date1, causeAnalysis,
toDevelop, Confirmor2, date2,
EmergencyMeasuresPlan, estimatedFinishTime,
actualCompletionTime, toDevelop1, Confirmor3,
date3, preventiveMeasures, estimatedFinishTime1,
actualCompletionTime1, toDevelop2, Confirmor4,
date4, effectTracking, Confirmor5,
date5)
values (#{id,jdbcType=VARCHAR}, #{insuser,jdbcType=VARCHAR}, #{insdt,jdbcType=TIMESTAMP},
#{senddept,jdbcType=VARCHAR}, #{sender,jdbcType=VARCHAR}, #{sendtime,jdbcType=TIMESTAMP},
#{formnumber,jdbcType=VARCHAR}, #{acceptdept,jdbcType=VARCHAR}, #{recipient,jdbcType=VARCHAR},
#{accepttime,jdbcType=TIMESTAMP}, #{confirmreceipt,jdbcType=VARCHAR}, #{problemarea,jdbcType=VARCHAR},
#{severity,jdbcType=VARCHAR}, #{problemnumber,jdbcType=VARCHAR}, #{descriptionbadphenomena,jdbcType=VARCHAR},
#{confirmor1,jdbcType=VARCHAR}, #{date1,jdbcType=TIMESTAMP}, #{causeanalysis,jdbcType=VARCHAR},
#{todevelop,jdbcType=VARCHAR}, #{confirmor2,jdbcType=VARCHAR}, #{date2,jdbcType=TIMESTAMP},
#{emergencymeasuresplan,jdbcType=VARCHAR}, #{estimatedfinishtime,jdbcType=TIMESTAMP},
#{actualcompletiontime,jdbcType=TIMESTAMP}, #{todevelop1,jdbcType=VARCHAR}, #{confirmor3,jdbcType=VARCHAR},
#{date3,jdbcType=TIMESTAMP}, #{preventivemeasures,jdbcType=VARCHAR}, #{estimatedfinishtime1,jdbcType=TIMESTAMP},
#{actualcompletiontime1,jdbcType=TIMESTAMP}, #{todevelop2,jdbcType=VARCHAR}, #{confirmor4,jdbcType=VARCHAR},
#{date4,jdbcType=TIMESTAMP}, #{effecttracking,jdbcType=VARCHAR}, #{confirmor5,jdbcType=VARCHAR},
#{date5,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.sipai.entity.quality.AbnormalQuality" >
insert into tb_abnormal_quality
<trim prefix="(" suffix=")" suffixOverrides="," >
<if test="id != null" >
id,
</if>
<if test="insuser != null" >
insuser,
</if>
<if test="insdt != null" >
insdt,
</if>
<if test="senddept != null" >
sendDept,
</if>
<if test="sender != null" >
sender,
</if>
<if test="sendtime != null" >
sendTime,
</if>
<if test="formnumber != null" >
formNumber,
</if>
<if test="acceptdept != null" >
acceptDept,
</if>
<if test="recipient != null" >
recipient,
</if>
<if test="accepttime != null" >
acceptTime,
</if>
<if test="confirmreceipt != null" >
confirmReceipt,
</if>
<if test="problemarea != null" >
problemArea,
</if>
<if test="severity != null" >
severity,
</if>
<if test="problemnumber != null" >
problemNumber,
</if>
<if test="descriptionbadphenomena != null" >
descriptionBadPhenomena,
</if>
<if test="confirmor1 != null" >
Confirmor1,
</if>
<if test="date1 != null" >
date1,
</if>
<if test="causeanalysis != null" >
causeAnalysis,
</if>
<if test="todevelop != null" >
toDevelop,
</if>
<if test="confirmor2 != null" >
Confirmor2,
</if>
<if test="date2 != null" >
date2,
</if>
<if test="emergencymeasuresplan != null" >
EmergencyMeasuresPlan,
</if>
<if test="estimatedfinishtime != null" >
estimatedFinishTime,
</if>
<if test="actualcompletiontime != null" >
actualCompletionTime,
</if>
<if test="todevelop1 != null" >
toDevelop1,
</if>
<if test="confirmor3 != null" >
Confirmor3,
</if>
<if test="date3 != null" >
date3,
</if>
<if test="preventivemeasures != null" >
preventiveMeasures,
</if>
<if test="estimatedfinishtime1 != null" >
estimatedFinishTime1,
</if>
<if test="actualcompletiontime1 != null" >
actualCompletionTime1,
</if>
<if test="todevelop2 != null" >
toDevelop2,
</if>
<if test="confirmor4 != null" >
Confirmor4,
</if>
<if test="date4 != null" >
date4,
</if>
<if test="effecttracking != null" >
effectTracking,
</if>
<if test="confirmor5 != null" >
Confirmor5,
</if>
<if test="date5 != null" >
date5,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides="," >
<if test="id != null" >
#{id,jdbcType=VARCHAR},
</if>
<if test="insuser != null" >
#{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
#{insdt,jdbcType=TIMESTAMP},
</if>
<if test="senddept != null" >
#{senddept,jdbcType=VARCHAR},
</if>
<if test="sender != null" >
#{sender,jdbcType=VARCHAR},
</if>
<if test="sendtime != null" >
#{sendtime,jdbcType=TIMESTAMP},
</if>
<if test="formnumber != null" >
#{formnumber,jdbcType=VARCHAR},
</if>
<if test="acceptdept != null" >
#{acceptdept,jdbcType=VARCHAR},
</if>
<if test="recipient != null" >
#{recipient,jdbcType=VARCHAR},
</if>
<if test="accepttime != null" >
#{accepttime,jdbcType=TIMESTAMP},
</if>
<if test="confirmreceipt != null" >
#{confirmreceipt,jdbcType=VARCHAR},
</if>
<if test="problemarea != null" >
#{problemarea,jdbcType=VARCHAR},
</if>
<if test="severity != null" >
#{severity,jdbcType=VARCHAR},
</if>
<if test="problemnumber != null" >
#{problemnumber,jdbcType=VARCHAR},
</if>
<if test="descriptionbadphenomena != null" >
#{descriptionbadphenomena,jdbcType=VARCHAR},
</if>
<if test="confirmor1 != null" >
#{confirmor1,jdbcType=VARCHAR},
</if>
<if test="date1 != null" >
#{date1,jdbcType=TIMESTAMP},
</if>
<if test="causeanalysis != null" >
#{causeanalysis,jdbcType=VARCHAR},
</if>
<if test="todevelop != null" >
#{todevelop,jdbcType=VARCHAR},
</if>
<if test="confirmor2 != null" >
#{confirmor2,jdbcType=VARCHAR},
</if>
<if test="date2 != null" >
#{date2,jdbcType=TIMESTAMP},
</if>
<if test="emergencymeasuresplan != null" >
#{emergencymeasuresplan,jdbcType=VARCHAR},
</if>
<if test="estimatedfinishtime != null" >
#{estimatedfinishtime,jdbcType=TIMESTAMP},
</if>
<if test="actualcompletiontime != null" >
#{actualcompletiontime,jdbcType=TIMESTAMP},
</if>
<if test="todevelop1 != null" >
#{todevelop1,jdbcType=VARCHAR},
</if>
<if test="confirmor3 != null" >
#{confirmor3,jdbcType=VARCHAR},
</if>
<if test="date3 != null" >
#{date3,jdbcType=TIMESTAMP},
</if>
<if test="preventivemeasures != null" >
#{preventivemeasures,jdbcType=VARCHAR},
</if>
<if test="estimatedfinishtime1 != null" >
#{estimatedfinishtime1,jdbcType=TIMESTAMP},
</if>
<if test="actualcompletiontime1 != null" >
#{actualcompletiontime1,jdbcType=TIMESTAMP},
</if>
<if test="todevelop2 != null" >
#{todevelop2,jdbcType=VARCHAR},
</if>
<if test="confirmor4 != null" >
#{confirmor4,jdbcType=VARCHAR},
</if>
<if test="date4 != null" >
#{date4,jdbcType=TIMESTAMP},
</if>
<if test="effecttracking != null" >
#{effecttracking,jdbcType=VARCHAR},
</if>
<if test="confirmor5 != null" >
#{confirmor5,jdbcType=VARCHAR},
</if>
<if test="date5 != null" >
#{date5,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.sipai.entity.quality.AbnormalQuality" >
update tb_abnormal_quality
<set >
<if test="insuser != null" >
insuser = #{insuser,jdbcType=VARCHAR},
</if>
<if test="insdt != null" >
insdt = #{insdt,jdbcType=TIMESTAMP},
</if>
<if test="senddept != null" >
sendDept = #{senddept,jdbcType=VARCHAR},
</if>
<if test="sender != null" >
sender = #{sender,jdbcType=VARCHAR},
</if>
<if test="sendtime != null" >
sendTime = #{sendtime,jdbcType=TIMESTAMP},
</if>
<if test="formnumber != null" >
formNumber = #{formnumber,jdbcType=VARCHAR},
</if>
<if test="acceptdept != null" >
acceptDept = #{acceptdept,jdbcType=VARCHAR},
</if>
<if test="recipient != null" >
recipient = #{recipient,jdbcType=VARCHAR},
</if>
<if test="accepttime != null" >
acceptTime = #{accepttime,jdbcType=TIMESTAMP},
</if>
<if test="confirmreceipt != null" >
confirmReceipt = #{confirmreceipt,jdbcType=VARCHAR},
</if>
<if test="problemarea != null" >
problemArea = #{problemarea,jdbcType=VARCHAR},
</if>
<if test="severity != null" >
severity = #{severity,jdbcType=VARCHAR},
</if>
<if test="problemnumber != null" >
problemNumber = #{problemnumber,jdbcType=VARCHAR},
</if>
<if test="descriptionbadphenomena != null" >
descriptionBadPhenomena = #{descriptionbadphenomena,jdbcType=VARCHAR},
</if>
<if test="confirmor1 != null" >
Confirmor1 = #{confirmor1,jdbcType=VARCHAR},
</if>
<if test="date1 != null" >
date1 = #{date1,jdbcType=TIMESTAMP},
</if>
<if test="causeanalysis != null" >
causeAnalysis = #{causeanalysis,jdbcType=VARCHAR},
</if>
<if test="todevelop != null" >
toDevelop = #{todevelop,jdbcType=VARCHAR},
</if>
<if test="confirmor2 != null" >
Confirmor2 = #{confirmor2,jdbcType=VARCHAR},
</if>
<if test="date2 != null" >
date2 = #{date2,jdbcType=TIMESTAMP},
</if>
<if test="emergencymeasuresplan != null" >
EmergencyMeasuresPlan = #{emergencymeasuresplan,jdbcType=VARCHAR},
</if>
<if test="estimatedfinishtime != null" >
estimatedFinishTime = #{estimatedfinishtime,jdbcType=TIMESTAMP},
</if>
<if test="actualcompletiontime != null" >
actualCompletionTime = #{actualcompletiontime,jdbcType=TIMESTAMP},
</if>
<if test="todevelop1 != null" >
toDevelop1 = #{todevelop1,jdbcType=VARCHAR},
</if>
<if test="confirmor3 != null" >
Confirmor3 = #{confirmor3,jdbcType=VARCHAR},
</if>
<if test="date3 != null" >
date3 = #{date3,jdbcType=TIMESTAMP},
</if>
<if test="preventivemeasures != null" >
preventiveMeasures = #{preventivemeasures,jdbcType=VARCHAR},
</if>
<if test="estimatedfinishtime1 != null" >
estimatedFinishTime1 = #{estimatedfinishtime1,jdbcType=TIMESTAMP},
</if>
<if test="actualcompletiontime1 != null" >
actualCompletionTime1 = #{actualcompletiontime1,jdbcType=TIMESTAMP},
</if>
<if test="todevelop2 != null" >
toDevelop2 = #{todevelop2,jdbcType=VARCHAR},
</if>
<if test="confirmor4 != null" >
Confirmor4 = #{confirmor4,jdbcType=VARCHAR},
</if>
<if test="date4 != null" >
date4 = #{date4,jdbcType=TIMESTAMP},
</if>
<if test="effecttracking != null" >
effectTracking = #{effecttracking,jdbcType=VARCHAR},
</if>
<if test="confirmor5 != null" >
Confirmor5 = #{confirmor5,jdbcType=VARCHAR},
</if>
<if test="date5 != null" >
date5 = #{date5,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
<update id="updateByPrimaryKey" parameterType="com.sipai.entity.quality.AbnormalQuality" >
update tb_abnormal_quality
set insuser = #{insuser,jdbcType=VARCHAR},
insdt = #{insdt,jdbcType=TIMESTAMP},
sendDept = #{senddept,jdbcType=VARCHAR},
sender = #{sender,jdbcType=VARCHAR},
sendTime = #{sendtime,jdbcType=TIMESTAMP},
formNumber = #{formnumber,jdbcType=VARCHAR},
acceptDept = #{acceptdept,jdbcType=VARCHAR},
recipient = #{recipient,jdbcType=VARCHAR},
acceptTime = #{accepttime,jdbcType=TIMESTAMP},
confirmReceipt = #{confirmreceipt,jdbcType=VARCHAR},
problemArea = #{problemarea,jdbcType=VARCHAR},
severity = #{severity,jdbcType=VARCHAR},
problemNumber = #{problemnumber,jdbcType=VARCHAR},
descriptionBadPhenomena = #{descriptionbadphenomena,jdbcType=VARCHAR},
Confirmor1 = #{confirmor1,jdbcType=VARCHAR},
date1 = #{date1,jdbcType=TIMESTAMP},
causeAnalysis = #{causeanalysis,jdbcType=VARCHAR},
toDevelop = #{todevelop,jdbcType=VARCHAR},
Confirmor2 = #{confirmor2,jdbcType=VARCHAR},
date2 = #{date2,jdbcType=TIMESTAMP},
EmergencyMeasuresPlan = #{emergencymeasuresplan,jdbcType=VARCHAR},
estimatedFinishTime = #{estimatedfinishtime,jdbcType=TIMESTAMP},
actualCompletionTime = #{actualcompletiontime,jdbcType=TIMESTAMP},
toDevelop1 = #{todevelop1,jdbcType=VARCHAR},
Confirmor3 = #{confirmor3,jdbcType=VARCHAR},
date3 = #{date3,jdbcType=TIMESTAMP},
preventiveMeasures = #{preventivemeasures,jdbcType=VARCHAR},
estimatedFinishTime1 = #{estimatedfinishtime1,jdbcType=TIMESTAMP},
actualCompletionTime1 = #{actualcompletiontime1,jdbcType=TIMESTAMP},
toDevelop2 = #{todevelop2,jdbcType=VARCHAR},
Confirmor4 = #{confirmor4,jdbcType=VARCHAR},
date4 = #{date4,jdbcType=TIMESTAMP},
effectTracking = #{effecttracking,jdbcType=VARCHAR},
Confirmor5 = #{confirmor5,jdbcType=VARCHAR},
date5 = #{date5,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=VARCHAR}
</update>
<select id="selectListByWhere" resultMap="BaseResultMap" parameterType="java.lang.String" >
select
<include refid="Base_Column_List" />
from tb_abnormal_quality
${where}
</select>
<delete id="deleteByWhere" parameterType="java.lang.String" >
delete from tb_abnormal_quality
${where}
</delete>
</mapper>

Some files were not shown because too many files have changed in this diff Show More