| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111 |
- <?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.fs.aiSipCall.mapper.AiSipCallLlmAgentAccountMapper">
-
- <resultMap type="AiSipCallLlmAgentAccount" id="AiSipCallLlmAgentAccountResult">
- <result property="id" column="id" />
- <result property="accountJson" column="account_json" />
- <result property="providerClassName" column="provider_class_name" />
- <result property="name" column="name" />
- <result property="accountEntity" column="account_entity" />
- <result property="interruptFlag" column="interrupt_flag" />
- <result property="interruptKeywords" column="interrupt_keywords" />
- <result property="interruptIgnoreKeywords" column="interrupt_ignore_keywords" />
- <result property="intentionTips" column="intention_tips" />
- <result property="concurrentNum" column="concurrent_num" />
- <result property="transferManualDigit" column="transfer_manual_digit" />
- <result property="kbCatId" column="kb_cat_id" />
- <result property="remoteLlmAgentAccountId" column="remote_llm_agent_account_id" />
- </resultMap>
- <sql id="selectAiSipCallLlmAgentAccountVo">
- select id, account_json, provider_class_name, name, account_entity, interrupt_flag, interrupt_keywords, interrupt_ignore_keywords, intention_tips, concurrent_num, transfer_manual_digit, kb_cat_id, remote_llm_agent_account_id from ai_sip_call_llm_agent_account
- </sql>
- <select id="selectAiSipCallLlmAgentAccountList" parameterType="AiSipCallLlmAgentAccount" resultMap="AiSipCallLlmAgentAccountResult">
- <include refid="selectAiSipCallLlmAgentAccountVo"/>
- <where>
- <if test="accountJson != null and accountJson != ''"> and account_json = #{accountJson}</if>
- <if test="providerClassName != null and providerClassName != ''"> and provider_class_name like concat('%', #{providerClassName}, '%')</if>
- <if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
- <if test="accountEntity != null and accountEntity != ''"> and account_entity = #{accountEntity}</if>
- <if test="interruptFlag != null "> and interrupt_flag = #{interruptFlag}</if>
- <if test="interruptKeywords != null and interruptKeywords != ''"> and interrupt_keywords = #{interruptKeywords}</if>
- <if test="interruptIgnoreKeywords != null and interruptIgnoreKeywords != ''"> and interrupt_ignore_keywords = #{interruptIgnoreKeywords}</if>
- <if test="intentionTips != null and intentionTips != ''"> and intention_tips = #{intentionTips}</if>
- <if test="concurrentNum != null "> and concurrent_num = #{concurrentNum}</if>
- <if test="transferManualDigit != null and transferManualDigit != ''"> and transfer_manual_digit = #{transferManualDigit}</if>
- <if test="kbCatId != null "> and kb_cat_id = #{kbCatId}</if>
- <if test="remoteLlmAgentAccountId != null "> and remote_llm_agent_account_id = #{remoteLlmAgentAccountId}</if>
- </where>
- </select>
-
- <select id="selectAiSipCallLlmAgentAccountById" parameterType="Long" resultMap="AiSipCallLlmAgentAccountResult">
- <include refid="selectAiSipCallLlmAgentAccountVo"/>
- where id = #{id}
- </select>
-
- <insert id="insertAiSipCallLlmAgentAccount" parameterType="AiSipCallLlmAgentAccount" useGeneratedKeys="true" keyProperty="id">
- insert into ai_sip_call_llm_agent_account
- <trim prefix="(" suffix=")" suffixOverrides=",">
- <if test="accountJson != null">account_json,</if>
- <if test="providerClassName != null and providerClassName != ''">provider_class_name,</if>
- <if test="name != null and name != ''">name,</if>
- <if test="accountEntity != null and accountEntity != ''">account_entity,</if>
- <if test="interruptFlag != null">interrupt_flag,</if>
- <if test="interruptKeywords != null">interrupt_keywords,</if>
- <if test="interruptIgnoreKeywords != null">interrupt_ignore_keywords,</if>
- <if test="intentionTips != null">intention_tips,</if>
- <if test="concurrentNum != null">concurrent_num,</if>
- <if test="transferManualDigit != null and transferManualDigit != ''">transfer_manual_digit,</if>
- <if test="kbCatId != null">kb_cat_id,</if>
- <if test="remoteLlmAgentAccountId != null">remote_llm_agent_account_id,</if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides=",">
- <if test="accountJson != null">#{accountJson},</if>
- <if test="providerClassName != null and providerClassName != ''">#{providerClassName},</if>
- <if test="name != null and name != ''">#{name},</if>
- <if test="accountEntity != null and accountEntity != ''">#{accountEntity},</if>
- <if test="interruptFlag != null">#{interruptFlag},</if>
- <if test="interruptKeywords != null">#{interruptKeywords},</if>
- <if test="interruptIgnoreKeywords != null">#{interruptIgnoreKeywords},</if>
- <if test="intentionTips != null">#{intentionTips},</if>
- <if test="concurrentNum != null">#{concurrentNum},</if>
- <if test="transferManualDigit != null and transferManualDigit != ''">#{transferManualDigit},</if>
- <if test="kbCatId != null">#{kbCatId},</if>
- <if test="remoteLlmAgentAccountId != null">#{remoteLlmAgentAccountId},</if>
- </trim>
- </insert>
- <update id="updateAiSipCallLlmAgentAccount" parameterType="AiSipCallLlmAgentAccount">
- update ai_sip_call_llm_agent_account
- <trim prefix="SET" suffixOverrides=",">
- <if test="accountJson != null">account_json = #{accountJson},</if>
- <if test="providerClassName != null and providerClassName != ''">provider_class_name = #{providerClassName},</if>
- <if test="name != null and name != ''">name = #{name},</if>
- <if test="accountEntity != null and accountEntity != ''">account_entity = #{accountEntity},</if>
- <if test="interruptFlag != null">interrupt_flag = #{interruptFlag},</if>
- <if test="interruptKeywords != null">interrupt_keywords = #{interruptKeywords},</if>
- <if test="interruptIgnoreKeywords != null">interrupt_ignore_keywords = #{interruptIgnoreKeywords},</if>
- <if test="intentionTips != null">intention_tips = #{intentionTips},</if>
- <if test="concurrentNum != null">concurrent_num = #{concurrentNum},</if>
- <if test="transferManualDigit != null and transferManualDigit != ''">transfer_manual_digit = #{transferManualDigit},</if>
- <if test="kbCatId != null">kb_cat_id = #{kbCatId},</if>
- <if test="remoteLlmAgentAccountId != null">remote_llm_agent_account_id = #{remoteLlmAgentAccountId},</if>
- </trim>
- where id = #{id}
- </update>
- <delete id="deleteAiSipCallLlmAgentAccountById" parameterType="Long">
- delete from ai_sip_call_llm_agent_account where id = #{id}
- </delete>
- <delete id="deleteAiSipCallLlmAgentAccountByIds" parameterType="String">
- delete from ai_sip_call_llm_agent_account where id in
- <foreach item="id" collection="array" open="(" separator="," close=")">
- #{id}
- </foreach>
- </delete>
- </mapper>
|