项目初始化
This commit is contained in:
@@ -0,0 +1,95 @@
|
||||
<?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="com.ruoyi.bas.barcode.data.mapper.BasBarcodeDataMapper">
|
||||
|
||||
<resultMap type="BasBarcodeData" id="BasBarcodeDataResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="formatId" column="format_id" />
|
||||
<result property="barcodeNo" column="barcode_no" />
|
||||
<result property="printNum" column="print_num" />
|
||||
<result property="status" column="status" />
|
||||
<result property="printTime" column="print_time" />
|
||||
<result property="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasBarcodeDataVo">
|
||||
select id, format_id, barcode_no, print_num, status, print_time, remark from bas_barcode_data
|
||||
</sql>
|
||||
|
||||
<select id="selectBasBarcodeDataList" parameterType="BasBarcodeData" resultMap="BasBarcodeDataResult">
|
||||
<include refid="selectBasBarcodeDataVo"/>
|
||||
<where>
|
||||
<if test="formatId != null "> and format_id = #{formatId}</if>
|
||||
<if test="barcodeNo != null and barcodeNo != ''"> and barcode_no = #{barcodeNo}</if>
|
||||
<if test="printNum != null "> and print_num = #{printNum}</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
<if test="printTime != null and printTime != ''"> and print_time = #{printTime}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBasBarcodeDataById" parameterType="Long" resultMap="BasBarcodeDataResult">
|
||||
<include refid="selectBasBarcodeDataVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertBasBarcodeData" parameterType="BasBarcodeData">
|
||||
insert into bas_barcode_data
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,</if>
|
||||
<if test="formatId != null">format_id,</if>
|
||||
<if test="barcodeNo != null">barcode_no,</if>
|
||||
<if test="printNum != null">print_num,</if>
|
||||
<if test="status != null">status,</if>
|
||||
<if test="printTime != null">print_time,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">#{id},</if>
|
||||
<if test="formatId != null">#{formatId},</if>
|
||||
<if test="barcodeNo != null">#{barcodeNo},</if>
|
||||
<if test="printNum != null">#{printNum},</if>
|
||||
<if test="status != null">#{status},</if>
|
||||
<if test="printTime != null">#{printTime},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<insert id="insertBatchBasBarcodeData" parameterType="list">
|
||||
insert into bas_barcode_data (format_id, barcode_no, print_num, status, print_time, remark)
|
||||
values
|
||||
<foreach collection="list" item="item" separator=",">
|
||||
(#{item.formatId,jdbcType=BIGINT},
|
||||
#{item.barcodeNo,jdbcType=VARCHAR},
|
||||
#{item.printNum,jdbcType=INTEGER},
|
||||
#{item.status,jdbcType=VARCHAR},
|
||||
#{item.printTime,jdbcType=TIMESTAMP},
|
||||
#{item.remark,jdbcType=VARCHAR})
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasBarcodeData" parameterType="BasBarcodeData">
|
||||
update bas_barcode_data
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="formatId != null">format_id = #{formatId},</if>
|
||||
<if test="barcodeNo != null">barcode_no = #{barcodeNo},</if>
|
||||
<if test="printNum != null">print_num = #{printNum},</if>
|
||||
<if test="status != null">status = #{status},</if>
|
||||
<if test="printTime != null">print_time = #{printTime},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasBarcodeDataById" parameterType="Long">
|
||||
delete from bas_barcode_data where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasBarcodeDataByIds" parameterType="String">
|
||||
delete from bas_barcode_data where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -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="com.ruoyi.bas.barcode.format.mapper.BasBarcodeFormatMapper">
|
||||
|
||||
<resultMap type="BasBarcodeFormat" id="BasBarcodeFormatResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="formatName" column="format_name" />
|
||||
<result property="barcodeType" column="barcode_type" />
|
||||
<result property="width" column="width" />
|
||||
<result property="height" column="height" />
|
||||
<result property="showText" column="show_text" />
|
||||
<result property="fontSize" column="font_size" />
|
||||
<result property="prefix" column="prefix" />
|
||||
<result property="suffix" column="suffix" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasBarcodeFormatVo">
|
||||
select id, format_name, barcode_type, width, height, show_text, font_size, prefix, suffix, remark, create_time, update_time from bas_barcode_format
|
||||
</sql>
|
||||
|
||||
<select id="selectBasBarcodeFormatList" parameterType="BasBarcodeFormat" resultMap="BasBarcodeFormatResult">
|
||||
<include refid="selectBasBarcodeFormatVo"/>
|
||||
<where>
|
||||
<if test="formatName != null and formatName != ''"> and format_name like concat('%', #{formatName}, '%')</if>
|
||||
<if test="barcodeType != null and barcodeType != ''"> and barcode_type = #{barcodeType}</if>
|
||||
<if test="width != null "> and width = #{width}</if>
|
||||
<if test="height != null "> and height = #{height}</if>
|
||||
<if test="showText != null "> and show_text = #{showText}</if>
|
||||
<if test="fontSize != null "> and font_size = #{fontSize}</if>
|
||||
<if test="prefix != null and prefix != ''"> and prefix = #{prefix}</if>
|
||||
<if test="suffix != null and suffix != ''"> and suffix = #{suffix}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBasBarcodeFormatById" parameterType="Long" resultMap="BasBarcodeFormatResult">
|
||||
<include refid="selectBasBarcodeFormatVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertBasBarcodeFormat" parameterType="BasBarcodeFormat" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into bas_barcode_format
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="formatName != null">format_name,</if>
|
||||
<if test="barcodeType != null">barcode_type,</if>
|
||||
<if test="width != null">width,</if>
|
||||
<if test="height != null">height,</if>
|
||||
<if test="showText != null">show_text,</if>
|
||||
<if test="fontSize != null">font_size,</if>
|
||||
<if test="prefix != null">prefix,</if>
|
||||
<if test="suffix != null">suffix,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
<if test="updateTime != null">update_time,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="formatName != null">#{formatName},</if>
|
||||
<if test="barcodeType != null">#{barcodeType},</if>
|
||||
<if test="width != null">#{width},</if>
|
||||
<if test="height != null">#{height},</if>
|
||||
<if test="showText != null">#{showText},</if>
|
||||
<if test="fontSize != null">#{fontSize},</if>
|
||||
<if test="prefix != null">#{prefix},</if>
|
||||
<if test="suffix != null">#{suffix},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
<if test="updateTime != null">#{updateTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasBarcodeFormat" parameterType="BasBarcodeFormat">
|
||||
update bas_barcode_format
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="formatName != null">format_name = #{formatName},</if>
|
||||
<if test="barcodeType != null">barcode_type = #{barcodeType},</if>
|
||||
<if test="width != null">width = #{width},</if>
|
||||
<if test="height != null">height = #{height},</if>
|
||||
<if test="showText != null">show_text = #{showText},</if>
|
||||
<if test="fontSize != null">font_size = #{fontSize},</if>
|
||||
<if test="prefix != null">prefix = #{prefix},</if>
|
||||
<if test="suffix != null">suffix = #{suffix},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="createTime != null">create_time = #{createTime},</if>
|
||||
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasBarcodeFormatById" parameterType="Long">
|
||||
delete from bas_barcode_format where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasBarcodeFormatByIds" parameterType="String">
|
||||
delete from bas_barcode_format where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -0,0 +1,190 @@
|
||||
<?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="com.ruoyi.bas.cargospace.mapper.BasCargoSpaceMapper">
|
||||
|
||||
<resultMap type="BasCargoSpace" id="BasCargoSpaceResult">
|
||||
<result property="cargoSpaceId" column="cargo_space_id" />
|
||||
<result property="warehouseId" column="warehouse_id" />
|
||||
<result property="roadwayId" column="roadway_id" />
|
||||
<result property="cargoAreaId" column="cargo_area_id" />
|
||||
<result property="theType" column="the_type" />
|
||||
<result property="theTypeName" column="the_type_name" />
|
||||
<result property="cargoSpaceName" column="cargo_space_name" />
|
||||
<result property="thePlatoon" column="the_platoon" />
|
||||
<result property="theColumn" column="the_column" />
|
||||
<result property="theFloor" column="the_floor" />
|
||||
<result property="status" column="status" />
|
||||
<result property="locked" column="locked" />
|
||||
<result property="trayCode" column="tray_code" />
|
||||
<result property="issDouble" column="iss_double" />
|
||||
<result property="groupCodingNo" column="group_coding_no" />
|
||||
<result property="groupCoding" column="group_coding" />
|
||||
<result property="cargoSpaceLogo" column="cargo_space_logo" />
|
||||
<result property="thisCargoArea" column="this_cargo_area" />
|
||||
<result property="deptId" column="dept_id" />
|
||||
<result property="deptName" column="dept_name" />
|
||||
<result property="theWeight" column="the_weight" />
|
||||
<result property="theHeight" column="the_height" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasCargoSpaceVo">
|
||||
select cargo_space_id, warehouse_id, roadway_id, cargo_area_id, the_type, the_type_name, cargo_space_name, the_platoon, the_column, the_floor, status, locked, tray_code, iss_double, group_coding_no, group_coding, cargo_space_logo, this_cargo_area, dept_id, dept_name, the_weight, the_height from bas_cargo_space
|
||||
</sql>
|
||||
|
||||
<select id="selectBasCargoSpaceList" parameterType="BasCargoSpace" resultMap="BasCargoSpaceResult">
|
||||
<include refid="selectBasCargoSpaceVo"/>
|
||||
<where>
|
||||
<if test="warehouseId != null and warehouseId != ''"> and warehouse_id = #{warehouseId}</if>
|
||||
<if test="roadwayId != null and roadwayId != ''"> and roadway_id = #{roadwayId}</if>
|
||||
<if test="cargoAreaId != null and cargoAreaId != ''"> and cargo_area_id = #{cargoAreaId}</if>
|
||||
<if test="theType != null and theType != ''"> and the_type = #{theType}</if>
|
||||
<if test="theTypeName != null and theTypeName != ''"> and the_type_name like concat('%', #{theTypeName}, '%')</if>
|
||||
<if test="cargoSpaceName != null and cargoSpaceName != ''"> and cargo_space_name like concat('%', #{cargoSpaceName}, '%')</if>
|
||||
<if test="thePlatoon != null "> and the_platoon = #{thePlatoon}</if>
|
||||
<if test="theColumn != null "> and the_column = #{theColumn}</if>
|
||||
<if test="theFloor != null "> and the_floor = #{theFloor}</if>
|
||||
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||
<if test="locked != null and locked != ''"> and locked = #{locked}</if>
|
||||
<if test="trayCode != null and trayCode != ''"> and tray_code = #{trayCode}</if>
|
||||
<if test="issDouble != null and issDouble != ''"> and iss_double = #{issDouble}</if>
|
||||
<if test="groupCodingNo != null and groupCodingNo != ''"> and group_coding_no = #{groupCodingNo}</if>
|
||||
<if test="groupCoding != null and groupCoding != ''"> and group_coding = #{groupCoding}</if>
|
||||
<if test="cargoSpaceLogo != null and cargoSpaceLogo != ''"> and cargo_space_logo = #{cargoSpaceLogo}</if>
|
||||
<if test="thisCargoArea != null and thisCargoArea != ''"> and this_cargo_area = #{thisCargoArea}</if>
|
||||
<if test="deptId != null "> and dept_id = #{deptId}</if>
|
||||
<if test="deptName != null and deptName != ''"> and dept_name like concat('%', #{deptName}, '%')</if>
|
||||
<if test="theWeight != null "> and the_weight = #{theWeight}</if>
|
||||
<if test="theHeight != null "> and the_height = #{theHeight}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBasCargoSpaceByCargoSpaceId" parameterType="String" resultMap="BasCargoSpaceResult">
|
||||
<include refid="selectBasCargoSpaceVo"/>
|
||||
where cargo_space_id = #{cargoSpaceId}
|
||||
</select>
|
||||
<select id="selectBasCargoSpaceListByGroupByStatus" resultType="com.ruoyi.kpi.domain.BasCargoSpaceStatus">
|
||||
select status, count(*) as count
|
||||
from bas_cargo_space
|
||||
<where>
|
||||
<if test="warehouseId != null and warehouseId != ''"> and warehouse_id = #{warehouseId}</if>
|
||||
<if test="roadwayId != null and roadwayId != ''"> and roadway_id = #{roadwayId}</if>
|
||||
</where>
|
||||
group by status
|
||||
</select>
|
||||
<select id="selectPlatListByPlatoon" resultType="java.lang.Integer">
|
||||
select distinct the_platoon
|
||||
from bas_cargo_space
|
||||
<where>
|
||||
<if test="warehouseId !=null and warehouseId != ''">
|
||||
and warehouse_id = #{warehouseId}
|
||||
</if>
|
||||
<if test="roadwayId !=null and roadwayId != ''">
|
||||
and roadway_id = #{roadwayId}
|
||||
</if>
|
||||
</where>
|
||||
order by the_platoon
|
||||
</select>
|
||||
|
||||
<select id="selectByCoordinates" parameterType="BasCargoSpace" resultMap="BasCargoSpaceResult">
|
||||
<include refid="selectBasCargoSpaceVo"/>
|
||||
<where>
|
||||
<if test="warehouseId != null and warehouseId != ''"> and warehouse_id = #{warehouseId}</if>
|
||||
<if test="thePlatoon != null"> and the_platoon = #{thePlatoon}</if>
|
||||
<if test="theColumn != null"> and the_column = #{theColumn}</if>
|
||||
<if test="theFloor != null"> and the_floor = #{theFloor}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<insert id="insertBasCargoSpace" parameterType="BasCargoSpace">
|
||||
insert into bas_cargo_space
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="cargoSpaceId != null">cargo_space_id,</if>
|
||||
<if test="warehouseId != null and warehouseId != ''">warehouse_id,</if>
|
||||
<if test="roadwayId != null and roadwayId != ''">roadway_id,</if>
|
||||
<if test="cargoAreaId != null">cargo_area_id,</if>
|
||||
<if test="theType != null">the_type,</if>
|
||||
<if test="theTypeName != null">the_type_name,</if>
|
||||
<if test="cargoSpaceName != null and cargoSpaceName != ''">cargo_space_name,</if>
|
||||
<if test="thePlatoon != null">the_platoon,</if>
|
||||
<if test="theColumn != null">the_column,</if>
|
||||
<if test="theFloor != null">the_floor,</if>
|
||||
<if test="status != null and status != ''">status,</if>
|
||||
<if test="locked != null and locked != ''">locked,</if>
|
||||
<if test="trayCode != null">tray_code,</if>
|
||||
<if test="issDouble != null">iss_double,</if>
|
||||
<if test="groupCodingNo != null">group_coding_no,</if>
|
||||
<if test="groupCoding != null">group_coding,</if>
|
||||
<if test="cargoSpaceLogo != null">cargo_space_logo,</if>
|
||||
<if test="thisCargoArea != null">this_cargo_area,</if>
|
||||
<if test="deptId != null">dept_id,</if>
|
||||
<if test="deptName != null">dept_name,</if>
|
||||
<if test="theWeight != null">the_weight,</if>
|
||||
<if test="theHeight != null">the_height,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="cargoSpaceId != null">#{cargoSpaceId},</if>
|
||||
<if test="warehouseId != null and warehouseId != ''">#{warehouseId},</if>
|
||||
<if test="roadwayId != null and roadwayId != ''">#{roadwayId},</if>
|
||||
<if test="cargoAreaId != null">#{cargoAreaId},</if>
|
||||
<if test="theType != null">#{theType},</if>
|
||||
<if test="theTypeName != null">#{theTypeName},</if>
|
||||
<if test="cargoSpaceName != null and cargoSpaceName != ''">#{cargoSpaceName},</if>
|
||||
<if test="thePlatoon != null">#{thePlatoon},</if>
|
||||
<if test="theColumn != null">#{theColumn},</if>
|
||||
<if test="theFloor != null">#{theFloor},</if>
|
||||
<if test="status != null and status != ''">#{status},</if>
|
||||
<if test="locked != null and locked != ''">#{locked},</if>
|
||||
<if test="trayCode != null">#{trayCode},</if>
|
||||
<if test="issDouble != null">#{issDouble},</if>
|
||||
<if test="groupCodingNo != null">#{groupCodingNo},</if>
|
||||
<if test="groupCoding != null">#{groupCoding},</if>
|
||||
<if test="cargoSpaceLogo != null">#{cargoSpaceLogo},</if>
|
||||
<if test="thisCargoArea != null">#{thisCargoArea},</if>
|
||||
<if test="deptId != null">#{deptId},</if>
|
||||
<if test="deptName != null">#{deptName},</if>
|
||||
<if test="theWeight != null">#{theWeight},</if>
|
||||
<if test="theHeight != null">#{theHeight},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasCargoSpace" parameterType="BasCargoSpace">
|
||||
update bas_cargo_space
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="warehouseId != null and warehouseId != ''">warehouse_id = #{warehouseId},</if>
|
||||
<if test="roadwayId != null and roadwayId != ''">roadway_id = #{roadwayId},</if>
|
||||
<if test="cargoAreaId != null">cargo_area_id = #{cargoAreaId},</if>
|
||||
<if test="theType != null">the_type = #{theType},</if>
|
||||
<if test="theTypeName != null">the_type_name = #{theTypeName},</if>
|
||||
<if test="cargoSpaceName != null and cargoSpaceName != ''">cargo_space_name = #{cargoSpaceName},</if>
|
||||
<if test="thePlatoon != null">the_platoon = #{thePlatoon},</if>
|
||||
<if test="theColumn != null">the_column = #{theColumn},</if>
|
||||
<if test="theFloor != null">the_floor = #{theFloor},</if>
|
||||
<if test="status != null and status != ''">status = #{status},</if>
|
||||
<if test="locked != null and locked != ''">locked = #{locked},</if>
|
||||
<if test="trayCode != null">tray_code = #{trayCode},</if>
|
||||
<if test="issDouble != null">iss_double = #{issDouble},</if>
|
||||
<if test="groupCodingNo != null">group_coding_no = #{groupCodingNo},</if>
|
||||
<if test="groupCoding != null">group_coding = #{groupCoding},</if>
|
||||
<if test="cargoSpaceLogo != null">cargo_space_logo = #{cargoSpaceLogo},</if>
|
||||
<if test="thisCargoArea != null">this_cargo_area = #{thisCargoArea},</if>
|
||||
<if test="deptId != null">dept_id = #{deptId},</if>
|
||||
<if test="deptName != null">dept_name = #{deptName},</if>
|
||||
<if test="theWeight != null">the_weight = #{theWeight},</if>
|
||||
<if test="theHeight != null">the_height = #{theHeight},</if>
|
||||
</trim>
|
||||
where cargo_space_id = #{cargoSpaceId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasCargoSpaceByCargoSpaceId" parameterType="String">
|
||||
delete from bas_cargo_space where cargo_space_id = #{cargoSpaceId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasCargoSpaceByCargoSpaceIds" parameterType="String">
|
||||
delete from bas_cargo_space where cargo_space_id in
|
||||
<foreach item="cargoSpaceId" collection="array" open="(" separator="," close=")">
|
||||
#{cargoSpaceId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -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="com.ruoyi.bas.customer.mapper.BasCustomerMapper">
|
||||
|
||||
<resultMap type="BasCustomer" id="BasCustomerResult">
|
||||
<result property="customerId" column="customer_id" />
|
||||
<result property="customerName" column="customer_name" />
|
||||
<result property="simpleName" column="simple_name" />
|
||||
<result property="useable" column="useable" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="contactName" column="contact_name" />
|
||||
<result property="contactNumber" column="contact_number" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasCustomerVo">
|
||||
select customer_id, customer_name, simple_name, useable, remark, contact_name, contact_number from bas_customer
|
||||
</sql>
|
||||
|
||||
<select id="selectBasCustomerList" parameterType="BasCustomer" resultMap="BasCustomerResult">
|
||||
<include refid="selectBasCustomerVo"/>
|
||||
<where>
|
||||
<if test="customerName != null and customerName != ''"> and customer_name like concat('%', #{customerName}, '%')</if>
|
||||
<if test="simpleName != null and simpleName != ''"> and simple_name like concat('%', #{simpleName}, '%')</if>
|
||||
<if test="useable != null and useable != ''"> and useable = #{useable}</if>
|
||||
<if test="contactName != null and contactName != ''"> and contact_name like concat('%', #{contactName}, '%')</if>
|
||||
<if test="contactNumber != null and contactNumber != ''"> and contact_number = #{contactNumber}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBasCustomerByCustomerId" parameterType="String" resultMap="BasCustomerResult">
|
||||
<include refid="selectBasCustomerVo"/>
|
||||
where customer_id = #{customerId}
|
||||
</select>
|
||||
|
||||
<insert id="insertBasCustomer" parameterType="BasCustomer">
|
||||
insert into bas_customer
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="customerId != null">customer_id,</if>
|
||||
<if test="customerName != null">customer_name,</if>
|
||||
<if test="simpleName != null">simple_name,</if>
|
||||
<if test="useable != null">useable,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="contactName != null">contact_name,</if>
|
||||
<if test="contactNumber != null">contact_number,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="customerId != null">#{customerId},</if>
|
||||
<if test="customerName != null">#{customerName},</if>
|
||||
<if test="simpleName != null">#{simpleName},</if>
|
||||
<if test="useable != null">#{useable},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="contactName != null">#{contactName},</if>
|
||||
<if test="contactNumber != null">#{contactNumber},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasCustomer" parameterType="BasCustomer">
|
||||
update bas_customer
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="customerName != null">customer_name = #{customerName},</if>
|
||||
<if test="simpleName != null">simple_name = #{simpleName},</if>
|
||||
<if test="useable != null">useable = #{useable},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="contactName != null">contact_name = #{contactName},</if>
|
||||
<if test="contactNumber != null">contact_number = #{contactNumber},</if>
|
||||
</trim>
|
||||
where customer_id = #{customerId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasCustomerByCustomerId" parameterType="String">
|
||||
delete from bas_customer where customer_id = #{customerId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasCustomerByCustomerIds" parameterType="String">
|
||||
delete from bas_customer where customer_id in
|
||||
<foreach item="customerId" collection="array" open="(" separator="," close=")">
|
||||
#{customerId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -0,0 +1,87 @@
|
||||
<?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="com.ruoyi.bas.product.mapper.BasProductMapper">
|
||||
|
||||
<resultMap type="BasProduct" id="BasProductResult">
|
||||
<result property="productId" column="product_id" />
|
||||
<result property="productName" column="product_name" />
|
||||
<result property="parentId" column="parent_id" />
|
||||
<result property="price" column="price" />
|
||||
<result property="cargoNo" column="cargo_no" />
|
||||
<result property="unit" column="unit" />
|
||||
<result property="spec" column="spec" />
|
||||
<result property="remark" column="remark" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasProductVo">
|
||||
select product_id, product_name, parent_id, price, cargo_no, unit, spec, remark from bas_product
|
||||
</sql>
|
||||
|
||||
<select id="selectBasProductList" parameterType="BasProduct" resultMap="BasProductResult">
|
||||
<include refid="selectBasProductVo"/>
|
||||
<where>
|
||||
<if test="productName != null and productName != ''"> and product_name like concat('%', #{productName}, '%')</if>
|
||||
<if test="parentId != null and parentId != ''"> and parent_id = #{parentId}</if>
|
||||
<if test="price != null and price != ''"> and price = #{price}</if>
|
||||
<if test="cargoNo != null and cargoNo != ''"> and cargo_no = #{cargoNo}</if>
|
||||
<if test="unit != null and unit != ''"> and unit = #{unit}</if>
|
||||
<if test="spec != null and spec != ''"> and spec = #{spec}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBasProductByProductId" parameterType="String" resultMap="BasProductResult">
|
||||
<include refid="selectBasProductVo"/>
|
||||
where product_id = #{productId}
|
||||
</select>
|
||||
|
||||
<insert id="insertBasProduct" parameterType="BasProduct">
|
||||
insert into bas_product
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="productId != null">product_id,</if>
|
||||
<if test="productName != null">product_name,</if>
|
||||
<if test="parentId != null">parent_id,</if>
|
||||
<if test="price != null">price,</if>
|
||||
<if test="cargoNo != null">cargo_no,</if>
|
||||
<if test="unit != null">unit,</if>
|
||||
<if test="spec != null">spec,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="productId != null">#{productId},</if>
|
||||
<if test="productName != null">#{productName},</if>
|
||||
<if test="parentId != null">#{parentId},</if>
|
||||
<if test="price != null">#{price},</if>
|
||||
<if test="cargoNo != null">#{cargoNo},</if>
|
||||
<if test="unit != null">#{unit},</if>
|
||||
<if test="spec != null">#{spec},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasProduct" parameterType="BasProduct">
|
||||
update bas_product
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="productName != null">product_name = #{productName},</if>
|
||||
<if test="parentId != null">parent_id = #{parentId},</if>
|
||||
<if test="price != null">price = #{price},</if>
|
||||
<if test="cargoNo != null">cargo_no = #{cargoNo},</if>
|
||||
<if test="unit != null">unit = #{unit},</if>
|
||||
<if test="spec != null">spec = #{spec},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
</trim>
|
||||
where product_id = #{productId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasProductByProductId" parameterType="String">
|
||||
delete from bas_product where product_id = #{productId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasProductByProductIds" parameterType="String">
|
||||
delete from bas_product where product_id in
|
||||
<foreach item="productId" collection="array" open="(" separator="," close=")">
|
||||
#{productId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -0,0 +1,81 @@
|
||||
<?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="com.ruoyi.bas.roadway.mapper.BasRoadwayMapper">
|
||||
|
||||
<resultMap type="BasRoadway" id="BasRoadwayResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="roadwayId" column="roadway_id" />
|
||||
<result property="warehouseId" column="warehouse_id" />
|
||||
<result property="roadwayName" column="roadway_name" />
|
||||
<result property="deviceId" column="device_id" />
|
||||
<result property="inLocked" column="in_locked" />
|
||||
<result property="outLocked" column="out_locked" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasRoadwayVo">
|
||||
select id, roadway_id, warehouse_id, roadway_name, device_id, in_locked, out_locked from bas_roadway
|
||||
</sql>
|
||||
|
||||
<select id="selectBasRoadwayList" parameterType="BasRoadway" resultMap="BasRoadwayResult">
|
||||
<include refid="selectBasRoadwayVo"/>
|
||||
<where>
|
||||
<if test="roadwayId != null and roadwayId != ''"> and roadway_id = #{roadwayId}</if>
|
||||
<if test="warehouseId != null and warehouseId != ''"> and warehouse_id = #{warehouseId}</if>
|
||||
<if test="roadwayName != null and roadwayName != ''"> and roadway_name like concat('%', #{roadwayName}, '%')</if>
|
||||
<if test="deviceId != null and deviceId != ''"> and device_id = #{deviceId}</if>
|
||||
<if test="inLocked != null and inLocked != ''"> and in_locked = #{inLocked}</if>
|
||||
<if test="outLocked != null and outLocked != ''"> and out_locked = #{outLocked}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBasRoadwayById" parameterType="Long" resultMap="BasRoadwayResult">
|
||||
<include refid="selectBasRoadwayVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertBasRoadway" parameterType="BasRoadway" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into bas_roadway
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="roadwayId != null and roadwayId != ''">roadway_id,</if>
|
||||
<if test="warehouseId != null and warehouseId != ''">warehouse_id,</if>
|
||||
<if test="roadwayName != null">roadway_name,</if>
|
||||
<if test="deviceId != null">device_id,</if>
|
||||
<if test="inLocked != null and inLocked != ''">in_locked,</if>
|
||||
<if test="outLocked != null">out_locked,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="roadwayId != null and roadwayId != ''">#{roadwayId},</if>
|
||||
<if test="warehouseId != null and warehouseId != ''">#{warehouseId},</if>
|
||||
<if test="roadwayName != null">#{roadwayName},</if>
|
||||
<if test="deviceId != null">#{deviceId},</if>
|
||||
<if test="inLocked != null and inLocked != ''">#{inLocked},</if>
|
||||
<if test="outLocked != null">#{outLocked},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasRoadway" parameterType="BasRoadway">
|
||||
update bas_roadway
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="roadwayId != null and roadwayId != ''">roadway_id = #{roadwayId},</if>
|
||||
<if test="warehouseId != null and warehouseId != ''">warehouse_id = #{warehouseId},</if>
|
||||
<if test="roadwayName != null">roadway_name = #{roadwayName},</if>
|
||||
<if test="deviceId != null">device_id = #{deviceId},</if>
|
||||
<if test="inLocked != null and inLocked != ''">in_locked = #{inLocked},</if>
|
||||
<if test="outLocked != null">out_locked = #{outLocked},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasRoadwayById" parameterType="Long">
|
||||
delete from bas_roadway where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasRoadwayByIds" parameterType="String">
|
||||
delete from bas_roadway where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
176
ruoyi-admin/src/main/resources/mapper/bas/BasStockMapper.xml
Normal file
176
ruoyi-admin/src/main/resources/mapper/bas/BasStockMapper.xml
Normal file
@@ -0,0 +1,176 @@
|
||||
<?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="com.ruoyi.bas.stock.mapper.BasStockMapper">
|
||||
|
||||
<resultMap type="BasStock" id="BasStockResult">
|
||||
<result property="stockId" column="stock_id" />
|
||||
<result property="cargoSpaceId" column="cargo_space_id" />
|
||||
<result property="stockStatus" column="stock_status" />
|
||||
<result property="productStatus" column="product_status" />
|
||||
<result property="lotNo" column="lot_no" />
|
||||
<result property="inDate" column="in_date" />
|
||||
<result property="backDate" column="back_date" />
|
||||
<result property="productId" column="product_id" />
|
||||
<result property="productName" column="product_name" />
|
||||
<result property="quantity" column="quantity" />
|
||||
<result property="jobId" column="job_id" />
|
||||
<result property="jobDetailId" column="job_detail_id" />
|
||||
<result property="trayCode" column="tray_code" />
|
||||
<result property="outQuantity" column="out_quantity" />
|
||||
<result property="stockinDetailId" column="stockin_detail_id" />
|
||||
<result property="stockinId" column="stockin_id" />
|
||||
<result property="inType" column="in_type" />
|
||||
<result property="warehouseId" column="warehouse_id" />
|
||||
<result property="warehouseName" column="warehouse_name" />
|
||||
<result property="userId" column="user_id" />
|
||||
<result property="userName" column="user_name" />
|
||||
<result property="deptId" column="dept_id" />
|
||||
<result property="deptName" column="dept_name" />
|
||||
<result property="suplierId" column="suplier_id" />
|
||||
<result property="suplierName" column="suplier_name" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasStockVo">
|
||||
select stock_id, cargo_space_id, stock_status, product_status, lot_no, in_date, back_date, product_id, product_name, quantity, job_id, job_detail_id, tray_code, out_quantity, stockin_detail_id, stockin_id, in_type, warehouse_id, warehouse_name, user_id, user_name, dept_id, dept_name, suplier_id, suplier_name from bas_stock
|
||||
</sql>
|
||||
|
||||
<select id="selectBasStockList" parameterType="BasStock" resultMap="BasStockResult">
|
||||
select bs.stock_id, bs.cargo_space_id, bs.stock_status, bs.product_status,
|
||||
bs.lot_no, bs.in_date, bs.back_date, bs.product_id, bs.product_name,
|
||||
bs.quantity, bs.job_id, bs.job_detail_id, bs.tray_code, bs.out_quantity,
|
||||
bs.stockin_detail_id, bs.stockin_id, bs.in_type, bs.warehouse_id, bs.warehouse_name,
|
||||
bs.user_id, bs.user_name, bs.dept_id, bs.dept_name, bs.suplier_id, bs.suplier_name
|
||||
from bas_stock bs
|
||||
left join bas_cargo_space bcs on bs.cargo_space_id = bcs.cargo_space_id
|
||||
where
|
||||
bcs.status = '2'
|
||||
<if test="cargoSpaceId != null and cargoSpaceId != ''"> and bs.cargo_space_id = #{cargoSpaceId}</if>
|
||||
<if test="stockStatus != null and stockStatus != ''"> and bs.stock_status = #{stockStatus}</if>
|
||||
<if test="productStatus != null and productStatus != ''"> and bs.product_status = #{productStatus}</if>
|
||||
<if test="lotNo != null and lotNo != ''"> and bs.lot_no = #{lotNo}</if>
|
||||
<if test="params.beginInDate != null and params.beginInDate != '' and params.endInDate != null and params.endInDate != ''"> and bs.in_date between #{params.beginInDate} and #{params.endInDate}</if>
|
||||
<if test="params.beginBackDate != null and params.beginBackDate != '' and params.endBackDate != null and params.endBackDate != ''"> and bs.back_date between #{params.beginBackDate} and #{params.endBackDate}</if>
|
||||
<if test="productId != null and productId != ''"> and bs.product_id = #{productId}</if>
|
||||
<if test="productName != null and productName != ''"> and bs.product_name like concat('%', #{productName}, '%')</if>
|
||||
<if test="quantity != null "> and bs.quantity = #{quantity}</if>
|
||||
<if test="jobId != null and jobId != ''"> and bs.job_id = #{jobId}</if>
|
||||
<if test="jobDetailId != null and jobDetailId != ''"> and bs.job_detail_id = #{jobDetailId}</if>
|
||||
<if test="trayCode != null and trayCode != ''"> and bs.tray_code = #{trayCode}</if>
|
||||
<if test="outQuantity != null "> and bs.out_quantity = #{outQuantity}</if>
|
||||
<if test="stockinDetailId != null and stockinDetailId != ''"> and bs.stockin_detail_id = #{stockinDetailId}</if>
|
||||
<if test="stockinId != null and stockinId != ''"> and bs.stockin_id = #{stockinId}</if>
|
||||
<if test="inType != null and inType != ''"> and bs.in_type = #{inType}</if>
|
||||
<if test="warehouseName != null and warehouseName != ''"> and bs.warehouse_name like concat('%', #{warehouseName}, '%')</if>
|
||||
<if test="userName != null and userName != ''"> and bs.user_name like concat('%', #{userName}, '%')</if>
|
||||
<if test="deptName != null and deptName != ''"> and bs.dept_name like concat('%', #{deptName}, '%')</if>
|
||||
<if test="suplierName != null and suplierName != ''"> and bs.suplier_name like concat('%', #{suplierName}, '%')</if>
|
||||
${params.warehouseScope}
|
||||
</select>
|
||||
|
||||
<select id="selectBasStockByStockId" parameterType="String" resultMap="BasStockResult">
|
||||
<include refid="selectBasStockVo"/>
|
||||
where stock_id = #{stockId}
|
||||
</select>
|
||||
|
||||
<insert id="insertBasStock" parameterType="BasStock">
|
||||
insert into bas_stock
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="stockId != null">stock_id,</if>
|
||||
<if test="cargoSpaceId != null">cargo_space_id,</if>
|
||||
<if test="stockStatus != null">stock_status,</if>
|
||||
<if test="productStatus != null">product_status,</if>
|
||||
<if test="lotNo != null">lot_no,</if>
|
||||
<if test="inDate != null">in_date,</if>
|
||||
<if test="backDate != null">back_date,</if>
|
||||
<if test="productId != null">product_id,</if>
|
||||
<if test="productName != null">product_name,</if>
|
||||
<if test="quantity != null">quantity,</if>
|
||||
<if test="jobId != null">job_id,</if>
|
||||
<if test="jobDetailId != null">job_detail_id,</if>
|
||||
<if test="trayCode != null">tray_code,</if>
|
||||
<if test="outQuantity != null">out_quantity,</if>
|
||||
<if test="stockinDetailId != null">stockin_detail_id,</if>
|
||||
<if test="stockinId != null">stockin_id,</if>
|
||||
<if test="inType != null">in_type,</if>
|
||||
<if test="warehouseId != null">warehouse_id,</if>
|
||||
<if test="warehouseName != null">warehouse_name,</if>
|
||||
<if test="userId != null">user_id,</if>
|
||||
<if test="userName != null">user_name,</if>
|
||||
<if test="deptId != null">dept_id,</if>
|
||||
<if test="deptName != null">dept_name,</if>
|
||||
<if test="suplierId != null">suplier_id,</if>
|
||||
<if test="suplierName != null">suplier_name,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="stockId != null">#{stockId},</if>
|
||||
<if test="cargoSpaceId != null">#{cargoSpaceId},</if>
|
||||
<if test="stockStatus != null">#{stockStatus},</if>
|
||||
<if test="productStatus != null">#{productStatus},</if>
|
||||
<if test="lotNo != null">#{lotNo},</if>
|
||||
<if test="inDate != null">#{inDate},</if>
|
||||
<if test="backDate != null">#{backDate},</if>
|
||||
<if test="productId != null">#{productId},</if>
|
||||
<if test="productName != null">#{productName},</if>
|
||||
<if test="quantity != null">#{quantity},</if>
|
||||
<if test="jobId != null">#{jobId},</if>
|
||||
<if test="jobDetailId != null">#{jobDetailId},</if>
|
||||
<if test="trayCode != null">#{trayCode},</if>
|
||||
<if test="outQuantity != null">#{outQuantity},</if>
|
||||
<if test="stockinDetailId != null">#{stockinDetailId},</if>
|
||||
<if test="stockinId != null">#{stockinId},</if>
|
||||
<if test="inType != null">#{inType},</if>
|
||||
<if test="warehouseId != null">#{warehouseId},</if>
|
||||
<if test="warehouseName != null">#{warehouseName},</if>
|
||||
<if test="userId != null">#{userId},</if>
|
||||
<if test="userName != null">#{userName},</if>
|
||||
<if test="deptId != null">#{deptId},</if>
|
||||
<if test="deptName != null">#{deptName},</if>
|
||||
<if test="suplierId != null">#{suplierId},</if>
|
||||
<if test="suplierName != null">#{suplierName},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasStock" parameterType="BasStock">
|
||||
update bas_stock
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="cargoSpaceId != null">cargo_space_id = #{cargoSpaceId},</if>
|
||||
<if test="stockStatus != null">stock_status = #{stockStatus},</if>
|
||||
<if test="productStatus != null">product_status = #{productStatus},</if>
|
||||
<if test="lotNo != null">lot_no = #{lotNo},</if>
|
||||
<if test="inDate != null">in_date = #{inDate},</if>
|
||||
<if test="backDate != null">back_date = #{backDate},</if>
|
||||
<if test="productId != null">product_id = #{productId},</if>
|
||||
<if test="productName != null">product_name = #{productName},</if>
|
||||
<if test="quantity != null">quantity = #{quantity},</if>
|
||||
<if test="jobId != null">job_id = #{jobId},</if>
|
||||
<if test="jobDetailId != null">job_detail_id = #{jobDetailId},</if>
|
||||
<if test="trayCode != null">tray_code = #{trayCode},</if>
|
||||
<if test="outQuantity != null">out_quantity = #{outQuantity},</if>
|
||||
<if test="stockinDetailId != null">stockin_detail_id = #{stockinDetailId},</if>
|
||||
<if test="stockinId != null">stockin_id = #{stockinId},</if>
|
||||
<if test="inType != null">in_type = #{inType},</if>
|
||||
<if test="warehouseId != null">warehouse_id = #{warehouseId},</if>
|
||||
<if test="warehouseName != null">warehouse_name = #{warehouseName},</if>
|
||||
<if test="userId != null">user_id = #{userId},</if>
|
||||
<if test="userName != null">user_name = #{userName},</if>
|
||||
<if test="deptId != null">dept_id = #{deptId},</if>
|
||||
<if test="deptName != null">dept_name = #{deptName},</if>
|
||||
<if test="suplierId != null">suplier_id = #{suplierId},</if>
|
||||
<if test="suplierName != null">suplier_name = #{suplierName},</if>
|
||||
</trim>
|
||||
where stock_id = #{stockId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasStockByStockId" parameterType="String">
|
||||
delete from bas_stock where stock_id = #{stockId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasStockByStockIds" parameterType="String">
|
||||
delete from bas_stock where stock_id in
|
||||
<foreach item="stockId" collection="array" open="(" separator="," close=")">
|
||||
#{stockId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -0,0 +1,123 @@
|
||||
<?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="com.ruoyi.bas.stockoper.mapper.BasStockOperRecordMapper">
|
||||
|
||||
<resultMap type="BasStockOperRecord" id="BasStockOperRecordResult">
|
||||
<result property="whGuid" column="wh_guid" />
|
||||
<result property="stockId" column="stock_id" />
|
||||
<result property="cargoSpaceId" column="cargo_space_id" />
|
||||
<result property="cargoSpaceName" column="cargo_space_name" />
|
||||
<result property="userId" column="user_id" />
|
||||
<result property="userName" column="user_name" />
|
||||
<result property="deptId" column="dept_id" />
|
||||
<result property="deptName" column="dept_name" />
|
||||
<result property="srcStatus" column="src_status" />
|
||||
<result property="tarStatus" column="tar_status" />
|
||||
<result property="srcQuantity" column="src_quantity" />
|
||||
<result property="tarQuantity" column="tar_quantity" />
|
||||
<result property="warehouseId" column="warehouse_id" />
|
||||
<result property="warehouseName" column="warehouse_name" />
|
||||
<result property="createTime" column="create_time" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasStockOperRecordVo">
|
||||
select wh_guid, stock_id, cargo_space_id, cargo_space_name, user_id, user_name, dept_id, dept_name, src_status, tar_status, src_quantity, tar_quantity, warehouse_id, warehouse_name, create_time from bas_stock_oper_record
|
||||
</sql>
|
||||
|
||||
<select id="selectBasStockOperRecordList" parameterType="BasStockOperRecord" resultMap="BasStockOperRecordResult">
|
||||
<include refid="selectBasStockOperRecordVo"/>
|
||||
<where>
|
||||
<if test="stockId != null and stockId != ''"> and stock_id = #{stockId}</if>
|
||||
<if test="cargoSpaceId != null and cargoSpaceId != ''"> and cargo_space_id = #{cargoSpaceId}</if>
|
||||
<if test="cargoSpaceName != null and cargoSpaceName != ''"> and cargo_space_name like concat('%', #{cargoSpaceName}, '%')</if>
|
||||
<if test="userId != null "> and user_id = #{userId}</if>
|
||||
<if test="userName != null and userName != ''"> and user_name like concat('%', #{userName}, '%')</if>
|
||||
<if test="deptId != null "> and dept_id = #{deptId}</if>
|
||||
<if test="deptName != null and deptName != ''"> and dept_name like concat('%', #{deptName}, '%')</if>
|
||||
<if test="srcStatus != null and srcStatus != ''"> and src_status = #{srcStatus}</if>
|
||||
<if test="tarStatus != null and tarStatus != ''"> and tar_status = #{tarStatus}</if>
|
||||
<if test="srcQuantity != null "> and src_quantity = #{srcQuantity}</if>
|
||||
<if test="tarQuantity != null "> and tar_quantity = #{tarQuantity}</if>
|
||||
<if test="warehouseId != null and warehouseId != ''"> and warehouse_id = #{warehouseId}</if>
|
||||
<if test="warehouseName != null and warehouseName != ''"> and warehouse_name like concat('%', #{warehouseName}, '%')</if>
|
||||
${params.warehouseScope}
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBasStockOperRecordByWhGuid" parameterType="Long" resultMap="BasStockOperRecordResult">
|
||||
<include refid="selectBasStockOperRecordVo"/>
|
||||
where wh_guid = #{whGuid}
|
||||
</select>
|
||||
|
||||
<insert id="insertBasStockOperRecord" parameterType="BasStockOperRecord">
|
||||
insert into bas_stock_oper_record
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="whGuid != null">wh_guid,</if>
|
||||
<if test="stockId != null">stock_id,</if>
|
||||
<if test="cargoSpaceId != null">cargo_space_id,</if>
|
||||
<if test="cargoSpaceName != null">cargo_space_name,</if>
|
||||
<if test="userId != null">user_id,</if>
|
||||
<if test="userName != null">user_name,</if>
|
||||
<if test="deptId != null">dept_id,</if>
|
||||
<if test="deptName != null">dept_name,</if>
|
||||
<if test="srcStatus != null">src_status,</if>
|
||||
<if test="tarStatus != null">tar_status,</if>
|
||||
<if test="srcQuantity != null">src_quantity,</if>
|
||||
<if test="tarQuantity != null">tar_quantity,</if>
|
||||
<if test="warehouseId != null">warehouse_id,</if>
|
||||
<if test="warehouseName != null">warehouse_name,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="whGuid != null">#{whGuid},</if>
|
||||
<if test="stockId != null">#{stockId},</if>
|
||||
<if test="cargoSpaceId != null">#{cargoSpaceId},</if>
|
||||
<if test="cargoSpaceName != null">#{cargoSpaceName},</if>
|
||||
<if test="userId != null">#{userId},</if>
|
||||
<if test="userName != null">#{userName},</if>
|
||||
<if test="deptId != null">#{deptId},</if>
|
||||
<if test="deptName != null">#{deptName},</if>
|
||||
<if test="srcStatus != null">#{srcStatus},</if>
|
||||
<if test="tarStatus != null">#{tarStatus},</if>
|
||||
<if test="srcQuantity != null">#{srcQuantity},</if>
|
||||
<if test="tarQuantity != null">#{tarQuantity},</if>
|
||||
<if test="warehouseId != null">#{warehouseId},</if>
|
||||
<if test="warehouseName != null">#{warehouseName},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasStockOperRecord" parameterType="BasStockOperRecord">
|
||||
update bas_stock_oper_record
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="stockId != null">stock_id = #{stockId},</if>
|
||||
<if test="cargoSpaceId != null">cargo_space_id = #{cargoSpaceId},</if>
|
||||
<if test="cargoSpaceName != null">cargo_space_name = #{cargoSpaceName},</if>
|
||||
<if test="userId != null">user_id = #{userId},</if>
|
||||
<if test="userName != null">user_name = #{userName},</if>
|
||||
<if test="deptId != null">dept_id = #{deptId},</if>
|
||||
<if test="deptName != null">dept_name = #{deptName},</if>
|
||||
<if test="srcStatus != null">src_status = #{srcStatus},</if>
|
||||
<if test="tarStatus != null">tar_status = #{tarStatus},</if>
|
||||
<if test="srcQuantity != null">src_quantity = #{srcQuantity},</if>
|
||||
<if test="tarQuantity != null">tar_quantity = #{tarQuantity},</if>
|
||||
<if test="warehouseId != null">warehouse_id = #{warehouseId},</if>
|
||||
<if test="warehouseName != null">warehouse_name = #{warehouseName},</if>
|
||||
<if test="createTime != null">create_time = #{createTime},</if>
|
||||
</trim>
|
||||
where wh_guid = #{whGuid}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasStockOperRecordByWhGuid" parameterType="Long">
|
||||
delete from bas_stock_oper_record where wh_guid = #{whGuid}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasStockOperRecordByWhGuids" parameterType="String">
|
||||
delete from bas_stock_oper_record where wh_guid in
|
||||
<foreach item="whGuid" collection="array" open="(" separator="," close=")">
|
||||
#{whGuid}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -0,0 +1,83 @@
|
||||
<?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="com.ruoyi.bas.supplier.mapper.BasSupplierMapper">
|
||||
|
||||
<resultMap type="BasSupplier" id="BasSupplierResult">
|
||||
<result property="supplierId" column="supplier_id" />
|
||||
<result property="supplierName" column="supplier_name" />
|
||||
<result property="simpleName" column="simple_name" />
|
||||
<result property="useable" column="useable" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="contactName" column="contact_name" />
|
||||
<result property="contactNumber" column="contact_number" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasSupplierVo">
|
||||
select supplier_id, supplier_name, simple_name, useable, remark, contact_name, contact_number from bas_supplier
|
||||
</sql>
|
||||
|
||||
<select id="selectBasSupplierList" parameterType="BasSupplier" resultMap="BasSupplierResult">
|
||||
<include refid="selectBasSupplierVo"/>
|
||||
<where>
|
||||
<if test="supplierId != null and supplierId != ''"> and supplier_id = #{supplierId}</if>
|
||||
<if test="supplierName != null and supplierName != ''"> and supplier_name like concat('%', #{supplierName}, '%')</if>
|
||||
<if test="simpleName != null and simpleName != ''"> and simple_name like concat('%', #{simpleName}, '%')</if>
|
||||
<if test="useable != null and useable != ''"> and useable = #{useable}</if>
|
||||
<if test="contactName != null and contactName != ''"> and contact_name like concat('%', #{contactName}, '%')</if>
|
||||
<if test="contactNumber != null and contactNumber != ''"> and contact_number = #{contactNumber}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBasSupplierBySupplierId" parameterType="String" resultMap="BasSupplierResult">
|
||||
<include refid="selectBasSupplierVo"/>
|
||||
where supplier_id = #{supplierId}
|
||||
</select>
|
||||
|
||||
<insert id="insertBasSupplier" parameterType="BasSupplier">
|
||||
insert into bas_supplier
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="supplierId != null and supplierId != ''">supplier_id,</if>
|
||||
<if test="supplierName != null">supplier_name,</if>
|
||||
<if test="simpleName != null">simple_name,</if>
|
||||
<if test="useable != null and useable != ''">useable,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="contactName != null">contact_name,</if>
|
||||
<if test="contactNumber != null">contact_number,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="supplierId != null and supplierId != ''">#{supplierId},</if>
|
||||
<if test="supplierName != null">#{supplierName},</if>
|
||||
<if test="simpleName != null">#{simpleName},</if>
|
||||
<if test="useable != null and useable != ''">#{useable},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="contactName != null">#{contactName},</if>
|
||||
<if test="contactNumber != null">#{contactNumber},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasSupplier" parameterType="BasSupplier">
|
||||
update bas_supplier
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="supplierName != null">supplier_name = #{supplierName},</if>
|
||||
<if test="simpleName != null">simple_name = #{simpleName},</if>
|
||||
<if test="useable != null and useable != ''">useable = #{useable},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="contactName != null">contact_name = #{contactName},</if>
|
||||
<if test="contactNumber != null">contact_number = #{contactNumber},</if>
|
||||
</trim>
|
||||
where supplier_id = #{supplierId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasSupplierBySupplierId" parameterType="String">
|
||||
delete from bas_supplier where supplier_id = #{supplierId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasSupplierBySupplierIds" parameterType="String">
|
||||
delete from bas_supplier where supplier_id in
|
||||
<foreach item="supplierId" collection="array" open="(" separator="," close=")">
|
||||
#{supplierId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
@@ -0,0 +1,84 @@
|
||||
<?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="com.ruoyi.bas.warehouse.mapper.BasWarehouseMapper">
|
||||
|
||||
<resultMap type="BasWarehouse" id="BasWarehouseResult">
|
||||
<result property="warehouseId" column="warehouse_id" />
|
||||
<result property="warehouseName" column="warehouse_name" />
|
||||
<result property="address" column="address" />
|
||||
<result property="cDesc" column="c_desc" />
|
||||
<result property="warehouseKind" column="warehouse_kind" />
|
||||
<result property="warehouseType" column="warehouse_type" />
|
||||
<result property="isActive" column="is_active" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBasWarehouseVo">
|
||||
select warehouse_id, warehouse_name, address, c_desc, warehouse_kind, warehouse_type, is_active from bas_warehouse
|
||||
</sql>
|
||||
|
||||
<select id="selectBasWarehouseList" parameterType="BasWarehouse" resultMap="BasWarehouseResult">
|
||||
<include refid="selectBasWarehouseVo"/>
|
||||
<where>
|
||||
<if test="warehouseName != null and warehouseName != ''"> and warehouse_name like concat('%', #{warehouseName}, '%')</if>
|
||||
<if test="address != null and address != ''"> and address = #{address}</if>
|
||||
<if test="cDesc != null and cDesc != ''"> and c_desc = #{cDesc}</if>
|
||||
<if test="warehouseKind != null and warehouseKind != ''"> and warehouse_kind = #{warehouseKind}</if>
|
||||
<if test="warehouseType != null and warehouseType != ''"> and warehouse_type = #{warehouseType}</if>
|
||||
<if test="isActive != null and isActive != ''"> and is_active = #{isActive}</if>
|
||||
${params.warehouseScope}
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBasWarehouseByWarehouseId" parameterType="String" resultMap="BasWarehouseResult">
|
||||
<include refid="selectBasWarehouseVo"/>
|
||||
where warehouse_id = #{warehouseId}
|
||||
</select>
|
||||
|
||||
<insert id="insertBasWarehouse" parameterType="BasWarehouse">
|
||||
insert into bas_warehouse
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="warehouseId != null">warehouse_id,</if>
|
||||
<if test="warehouseName != null and warehouseName != ''">warehouse_name,</if>
|
||||
<if test="address != null">address,</if>
|
||||
<if test="cDesc != null">c_desc,</if>
|
||||
<if test="warehouseKind != null">warehouse_kind,</if>
|
||||
<if test="warehouseType != null and warehouseType != ''">warehouse_type,</if>
|
||||
<if test="isActive != null and isActive != ''">is_active,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="warehouseId != null">#{warehouseId},</if>
|
||||
<if test="warehouseName != null and warehouseName != ''">#{warehouseName},</if>
|
||||
<if test="address != null">#{address},</if>
|
||||
<if test="cDesc != null">#{cDesc},</if>
|
||||
<if test="warehouseKind != null">#{warehouseKind},</if>
|
||||
<if test="warehouseType != null and warehouseType != ''">#{warehouseType},</if>
|
||||
<if test="isActive != null and isActive != ''">#{isActive},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBasWarehouse" parameterType="BasWarehouse">
|
||||
update bas_warehouse
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="warehouseName != null and warehouseName != ''">warehouse_name = #{warehouseName},</if>
|
||||
<if test="address != null">address = #{address},</if>
|
||||
<if test="cDesc != null">c_desc = #{cDesc},</if>
|
||||
<if test="warehouseKind != null">warehouse_kind = #{warehouseKind},</if>
|
||||
<if test="warehouseType != null and warehouseType != ''">warehouse_type = #{warehouseType},</if>
|
||||
<if test="isActive != null and isActive != ''">is_active = #{isActive},</if>
|
||||
</trim>
|
||||
where warehouse_id = #{warehouseId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBasWarehouseByWarehouseId" parameterType="String">
|
||||
delete from bas_warehouse where warehouse_id = #{warehouseId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBasWarehouseByWarehouseIds" parameterType="String">
|
||||
delete from bas_warehouse where warehouse_id in
|
||||
<foreach item="warehouseId" collection="array" open="(" separator="," close=")">
|
||||
#{warehouseId}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
14
ruoyi-admin/src/main/resources/mapper/bas/JobIdMapper.xml
Normal file
14
ruoyi-admin/src/main/resources/mapper/bas/JobIdMapper.xml
Normal file
@@ -0,0 +1,14 @@
|
||||
<?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="com.ruoyi.bas.id.job.mapper.BasJobIdMapper">
|
||||
|
||||
|
||||
<select id="getJobId" parameterType="java.util.Map" statementType="CALLABLE">
|
||||
{call util_serial_job(
|
||||
#{v_param,mode=IN,jdbcType=VARCHAR},
|
||||
#{v_serial,mode=OUT,jdbcType=VARCHAR}
|
||||
)}
|
||||
</select>
|
||||
</mapper>
|
||||
15
ruoyi-admin/src/main/resources/mapper/bas/TaskNoMapper.xml
Normal file
15
ruoyi-admin/src/main/resources/mapper/bas/TaskNoMapper.xml
Normal file
@@ -0,0 +1,15 @@
|
||||
<?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="com.ruoyi.bas.id.taskno.mapper.BasTaskNoMapper">
|
||||
|
||||
|
||||
<select id="getTaskNo" parameterType="java.util.Map" statementType="CALLABLE">
|
||||
{call util_serial_task(
|
||||
#{v_param,mode=IN,jdbcType=VARCHAR},
|
||||
#{v_serial,mode=OUT,jdbcType=VARCHAR}
|
||||
)}
|
||||
</select>
|
||||
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user