|
|
@@ -3,7 +3,7 @@
|
|
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
<mapper namespace="com.takai.ai.mapper.TakaiApplicationMapper">
|
|
|
-
|
|
|
+
|
|
|
<resultMap type="com.takai.ai.domain.entity.TakaiApplication" id="BmApplicationResult">
|
|
|
<id property="appId" column="appId" />
|
|
|
<result property="name" column="name" />
|
|
|
@@ -18,16 +18,17 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<result property="iconType" column="icon_type" />
|
|
|
<result property="maxToken" column="max_token" />
|
|
|
<result property="paramDesc" column="param_desc"/>
|
|
|
+ <result property="knowledgeInfo" column="knowledge_info" />
|
|
|
+ <result property="typeId" column="type_id" />
|
|
|
<result property="remark" column="remark" />
|
|
|
<result property="createBy" column="create_by" />
|
|
|
<result property="createTime" column="create_time" />
|
|
|
<result property="updateBy" column="update_by" />
|
|
|
<result property="updateTime" column="update_time" />
|
|
|
- <result property="knowledgeInfo" column="knowledge_info" />
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectSql">
|
|
|
- select appId, name, description, prompt, top_p, temperature, knowledge_ids, slice_count,model,icon_color,icon_type,max_token, create_by, create_time, remark, knowledge_info
|
|
|
+ select appId, name, description, prompt, top_p, temperature, knowledge_ids, slice_count,model,icon_color,icon_type,max_token, param_desc, knowledge_info, type_id, remark, create_by, create_time, update_by, update_time
|
|
|
from bm_application
|
|
|
</sql>
|
|
|
|
|
|
@@ -37,8 +38,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="appId != null and appId != ''">
|
|
|
AND appId = #{appId}
|
|
|
</if>
|
|
|
+ <if test="typeId != null and typeId != ''">
|
|
|
+ AND type_id = #{typeId}
|
|
|
+ </if>
|
|
|
</where>
|
|
|
- order by create_time asc
|
|
|
+ order by create_time desc
|
|
|
</select>
|
|
|
|
|
|
<select id="selectTargetApplication" parameterType="BmApplication" resultMap="BmApplicationResult">
|
|
|
@@ -63,6 +67,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="createBy != null and createBy != ''">create_by,</if>
|
|
|
<if test="knowledgeInfo != null and knowledgeInfo != ''">knowledge_info,</if>
|
|
|
<if test="maxToken != null and maxToken != ''">max_token,</if>
|
|
|
+ <if test="typeId != null and typeId != ''">type_id,</if>
|
|
|
create_time
|
|
|
)values(
|
|
|
<if test="appId != null">#{appId},</if>
|
|
|
@@ -80,6 +85,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="createBy != null and createBy != ''">#{createBy},</if>
|
|
|
<if test="knowledgeInfo != null and knowledgeInfo != ''">#{knowledgeInfo},</if>
|
|
|
<if test="maxToken != null and maxToken != ''">#{maxToken},</if>
|
|
|
+ <if test="typeId != null and typeId != ''">#{typeId},</if>
|
|
|
sysdate()
|
|
|
)
|
|
|
</insert>
|
|
|
@@ -101,6 +107,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="remark != null">remark = #{remark},</if>
|
|
|
<if test="knowledgeInfo != null and knowledgeInfo != ''">knowledge_info = #{knowledgeInfo},</if>
|
|
|
<if test="maxToken != null and maxToken != ''">max_token = #{maxToken},</if>
|
|
|
+ <if test="typeId != null and typeId != ''">type_id = #{typeId},</if>
|
|
|
update_time = sysdate()
|
|
|
</set>
|
|
|
where appId = #{appId}
|