
mapper.process.xml Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of snaker-core Show documentation
Show all versions of snaker-core Show documentation
snaker-core as open source.
<?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"> <insert id="SAVE" parameterType="process"> insert into wf_process (id,name,display_Name,type,instance_Url,state,content,version) values (#{id, jdbcType=VARCHAR},#{name, jdbcType=VARCHAR},#{displayName, jdbcType=VARCHAR},#{type, jdbcType=NUMERIC},#{instanceUrl, jdbcType=VARCHAR},#{state, jdbcType=NUMERIC},#{bytes, jdbcType=BLOB},#{version, jdbcType=NUMERIC}) </insert> <update id="UPDATE" parameterType="process"> update wf_process set name=#{name, jdbcType=VARCHAR}, display_Name=#{displayName, jdbcType=VARCHAR}, state=#{state, jdbcType=NUMERIC}, instance_Url=#{instanceUrl, jdbcType=VARCHAR}, content=#{bytes, jdbcType=BLOB} where id=#{id, jdbcType=VARCHAR} </update> <select id="SELECTONE" parameterType="string" resultType="process"> select id, name, display_Name as displayName, type, instance_Url as instanceUrl, state, content as bytes, version from wf_process where id = #{id, jdbcType=VARCHAR} </select> <select id="SELECTVERSION" parameterType="string" resultType="integer"> select max(version) from wf_process where name = #{name, jdbcType=VARCHAR} </select> <select id="SELECTLIST" resultType="process"> select id, name, display_Name as displayName, type, instance_Url as instanceUrl, state, content as bytes, version from wf_process </select> <select id="getProcesss" resultType="process" parameterType="hashmap"> ${limitBefore} select id, name, display_Name as displayName, type, instance_Url as instanceUrl, state, content as bytes, version <include refid="selectProcesss"/> ${orderby} ${limitAfter} </select> <select id="getProcesssCount" resultType="long" parameterType="hashmap"> select count(id) <include refid="selectProcesss"/> </select> <sql id="selectProcesss"> from wf_process <where> <if test="names != null and names.length > 0"> and name in <foreach collection="names" index="index" item="item" open="(" separator="," close=")"> #{item, jdbcType=VARCHAR} </foreach> </if> <if test="displayName != null"> and display_Name like "%#{displayName, jdbcType=VARCHAR}%" </if> <if test="state != null"> and state = #{state, jdbcType=NUMERIC} </if> <if test="version != null"> and version = #{version, jdbcType=NUMERIC} </if> </where> </sql> </mapper>
© 2015 - 2025 Weber Informatics LLC | Privacy Policy