|
@@ -13,6 +13,7 @@
|
|
<result column="c_content" property="c_content" jdbcType="VARCHAR" />
|
|
<result column="c_content" property="c_content" jdbcType="VARCHAR" />
|
|
<result column="city" property="city" jdbcType="VARCHAR" />
|
|
<result column="city" property="city" jdbcType="VARCHAR" />
|
|
<result column="branches" property="branches" jdbcType="VARCHAR" />
|
|
<result column="branches" property="branches" jdbcType="VARCHAR" />
|
|
|
|
+ <result column="branche_id" property="branche_id" jdbcType="INTEGER" />
|
|
<result column="address" property="address" jdbcType="VARCHAR" />
|
|
<result column="address" property="address" jdbcType="VARCHAR" />
|
|
<result column="startdate" property="startdate" jdbcType="VARCHAR" />
|
|
<result column="startdate" property="startdate" jdbcType="VARCHAR" />
|
|
<result column="enddate" property="enddate" jdbcType="VARCHAR" />
|
|
<result column="enddate" property="enddate" jdbcType="VARCHAR" />
|
|
@@ -25,11 +26,35 @@
|
|
</resultMap>
|
|
</resultMap>
|
|
<!--获取所有数据-->
|
|
<!--获取所有数据-->
|
|
|
|
|
|
- <select id="getAll" resultType="com.ygj.yuemum.domain.college.CollegeCurriculumPractice" >
|
|
|
|
|
|
+ <select id="getAll" resultType="com.ygj.yuemum.domain.college.CollegeCurriculumPractice" parameterType="com.ygj.yuemum.domain.college.CollegeCurriculumPractice">
|
|
select
|
|
select
|
|
*
|
|
*
|
|
from college_curriculum_practice
|
|
from college_curriculum_practice
|
|
- order by id desc
|
|
|
|
|
|
+ where 1=1
|
|
|
|
+ <if test="c_name != null and c_name != ''">
|
|
|
|
+ and c_name like "%"#{c_name,jdbcType=VARCHAR}"%"
|
|
|
|
+ </if>
|
|
|
|
+ <if test="c_type != null and c_type != ''">
|
|
|
|
+ and c_type = #{c_type,jdbcType=VARCHAR}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="c_step != null and c_step != ''">
|
|
|
|
+ and c_step = #{c_step,jdbcType=INTEGER}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="credit != null and credit != ''">
|
|
|
|
+ and credit = #{credit,jdbcType=INTEGER}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="branche_id != null and branche_id != ''">
|
|
|
|
+ and branche_id = #{branche_id,jdbcType=INTEGER}
|
|
|
|
+ </if>
|
|
|
|
+ <if test="deadline != null and deadline != ''">
|
|
|
|
+ and DATE_FORMAT(deadline,'%Y-%m-%d') = DATE_FORMAT(#{deadline,jdbcType=DATE},'%Y-%m-%d')
|
|
|
|
+ </if>
|
|
|
|
+ <if test="startdate != null and startdate != null and enddate != 0 and enddate != 0">
|
|
|
|
+ and startdate >= DATE_FORMAT(#{startdate,jdbcType=VARCHAR},'%Y-%m-%d')
|
|
|
|
+ and enddate <= DATE_FORMAT(#{enddate,jdbcType=VARCHAR},'%Y-%m-%d')
|
|
|
|
+ </if>
|
|
|
|
+
|
|
|
|
+ order by id asc
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
|
|
@@ -146,6 +171,9 @@
|
|
<if test="city != null" >
|
|
<if test="city != null" >
|
|
city,
|
|
city,
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="branche_id != null" >
|
|
|
|
+ branche_id,
|
|
|
|
+ </if>
|
|
<if test="branches != null" >
|
|
<if test="branches != null" >
|
|
branches,
|
|
branches,
|
|
</if>
|
|
</if>
|
|
@@ -202,6 +230,9 @@
|
|
<if test="city != null" >
|
|
<if test="city != null" >
|
|
#{city,jdbcType=VARCHAR},
|
|
#{city,jdbcType=VARCHAR},
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="branche_id != null" >
|
|
|
|
+ #{branche_id,jdbcType=INTEGER},
|
|
|
|
+ </if>
|
|
<if test="branches != null" >
|
|
<if test="branches != null" >
|
|
#{branches,jdbcType=VARCHAR},
|
|
#{branches,jdbcType=VARCHAR},
|
|
</if>
|
|
</if>
|
|
@@ -238,9 +269,6 @@
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.ygj.yuemum.domain.college.CollegeCurriculumPractice" >
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.ygj.yuemum.domain.college.CollegeCurriculumPractice" >
|
|
update college_curriculum_practice
|
|
update college_curriculum_practice
|
|
<set >
|
|
<set >
|
|
- <if test="c_code != null" >
|
|
|
|
- c_code = #{c_code,jdbcType=VARCHAR},
|
|
|
|
- </if>
|
|
|
|
<if test="c_seq != null" >
|
|
<if test="c_seq != null" >
|
|
c_seq = #{c_seq,jdbcType=INTEGER},
|
|
c_seq = #{c_seq,jdbcType=INTEGER},
|
|
</if>
|
|
</if>
|
|
@@ -262,6 +290,9 @@
|
|
<if test="city != null" >
|
|
<if test="city != null" >
|
|
city = #{city,jdbcType=VARCHAR},
|
|
city = #{city,jdbcType=VARCHAR},
|
|
</if>
|
|
</if>
|
|
|
|
+ <if test="branche_id != null" >
|
|
|
|
+ branche_id = #{branche_id,jdbcType=INTEGER},
|
|
|
|
+ </if>
|
|
<if test="branches != null" >
|
|
<if test="branches != null" >
|
|
branches = #{branches,jdbcType=VARCHAR},
|
|
branches = #{branches,jdbcType=VARCHAR},
|
|
</if>
|
|
</if>
|
|
@@ -307,4 +338,11 @@
|
|
where c_code = #{c_code,jdbcType=VARCHAR}
|
|
where c_code = #{c_code,jdbcType=VARCHAR}
|
|
</update>
|
|
</update>
|
|
|
|
|
|
|
|
+ <select id="getPracticeSeq" resultType="com.ygj.yuemum.domain.college.CollegeCurriculumCore">
|
|
|
|
+ select
|
|
|
|
+ *
|
|
|
|
+ from college_curriculum_practice
|
|
|
|
+ order by id desc limit 1
|
|
|
|
+ </select>
|
|
|
|
+
|
|
</mapper>
|
|
</mapper>
|