| | |
| | | where id = #{id} |
| | | </update> |
| | | |
| | | <select id="selectStandardizedTemplateList" resultType="com.gkhy.exam.system.domain.StandardizedTemplate"> |
| | | <select id="selectStandardizedTemplateList" resultType="com.gkhy.exam.system.domain.StandardizedTemplate" parameterType="com.gkhy.exam.system.domain.StandardizedTemplate"> |
| | | SELECT |
| | | st.`id`, |
| | | st.`company_id`, |
| | |
| | | <if test="companyId!=null and companyId!=''"> |
| | | and st.company_id = #{companyId} |
| | | </if> |
| | | ORDER BY |
| | | st.create_time DESC |
| | | <if test="templateName!=null and templateName!=''"> |
| | | and st.template_name like concat('%',#{templateName},'%') |
| | | </if> |
| | | <if test="sort!=null and sort==1"> |
| | | ORDER BY |
| | | st.template_name asc |
| | | </if> |
| | | <if test="sort!=null and sort==2"> |
| | | ORDER BY |
| | | st.template_name desc |
| | | </if> |
| | | <if test="sort ==null or sort== '' or sort == 0"> |
| | | ORDER BY |
| | | st.create_time desc |
| | | </if> |
| | | |
| | | |
| | | </select> |
| | | |
| | | |
| | | <select id="selectStandardizedTemplateListV2" resultType="com.gkhy.exam.system.domain.StandardizedTemplate"> |
| | | <select id="selectStandardizedTemplateListV2" resultType="com.gkhy.exam.system.domain.StandardizedTemplate" parameterType="com.gkhy.exam.system.domain.StandardizedTemplate"> |
| | | SELECT |
| | | st.`id`, |
| | | st.`company_id`, |
| | |
| | | <if test="industryTypeId!=null "> |
| | | and st.industry_type_id = #{industryTypeId} |
| | | </if> |
| | | ORDER BY |
| | | st.create_time DESC |
| | | <if test="templateName!=null and templateName!=''"> |
| | | and st.template_name like concat('%',#{templateName},'%') |
| | | </if> |
| | | <if test="sort!=null and sort==1"> |
| | | ORDER BY |
| | | st.template_name asc |
| | | </if> |
| | | <if test="sort!=null and sort==2"> |
| | | ORDER BY |
| | | st.template_name desc |
| | | </if> |
| | | <if test="sort ==null or sort== '' or sort == 0"> |
| | | ORDER BY |
| | | st.create_time desc |
| | | </if> |
| | | </select> |
| | | |
| | | </mapper> |