add
yj
2024-12-05 b9900893177c78fc559223521fe839aa21000017
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
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="com.iotechn.unimall.data.mapper.ImgMapper">
 
    <select id="getImgs" resultType="java.lang.String">
        SELECT url FROM unimall_img WHERE biz_type = #{bizType} AND biz_id = #{bizId};
    </select>
 
    <insert id="insertImgs" parameterType="list">
        INSERT INTO
            unimall_img
            (biz_type,biz_id,url,gmt_update,gmt_create)
        VALUES
        <foreach collection="list" separator="," item="imgDO" index="i">
            (
            #{imgDO.bizType},
            #{imgDO.bizId},
            #{imgDO.url},
            #{imgDO.gmtUpdate},
            #{imgDO.gmtCreate}
            )
        </foreach>
    </insert>
 
</mapper>