添加限流工具,修改模板onlyIf

This commit is contained in:
2025-01-23 15:10:29 +08:00
parent 1aa1ae5e2b
commit 7bd9a7507f
10 changed files with 64 additions and 32 deletions

View File

@ -96,4 +96,9 @@
)
order by create_at desc
</select>
<select id="getEntity" resultType="com.ycwl.basic.model.pc.faceSample.entity.FaceSampleEntity">
select *
from face_sample
where id = #{id}
</select>
</mapper>

View File

@ -2,8 +2,8 @@
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ycwl.basic.mapper.TemplateMapper">
<insert id="add">
insert into template(id, scenic_id, `name`, pid, is_placeholder, source_url, luts, overlays, audios, cover_url, frame_rate, speed, price, slash_price)
values (#{id}, #{scenicId}, #{name}, #{pid}, #{isPlaceholder}, #{sourceUrl}, #{luts}, #{overlays}, #{audios}, #{coverUrl}, #{frameRate}, #{speed}, #{price}, #{slashPrice})
insert into template(id, scenic_id, `name`, pid, is_placeholder, source_url, luts, overlays, audios, cover_url, frame_rate, speed, price, slash_price, crop_enable, only_if)
values (#{id}, #{scenicId}, #{name}, #{pid}, #{isPlaceholder}, #{sourceUrl}, #{luts}, #{overlays}, #{audios}, #{coverUrl}, #{frameRate}, #{speed}, #{price}, #{slashPrice}, #{cropEnable}, #{onlyIf})
</insert>
<insert id="addConfig">
insert into template_config(id, template_id, create_time)
@ -25,6 +25,9 @@
<if test="price!= null">price = #{price}, </if>
<if test="slashPrice!= null">slash_price = #{slashPrice}, </if>
<if test="speed!= null">speed = #{speed}, </if>
<if test="sort!= null">sort = #{sort}, </if>
<if test="cropEnable!= null">crop_enable = #{cropEnable}, </if>
<if test="onlyIf!= null">only_if = #{onlyIf}, </if>
</set>
where id = #{id}
</update>