|
@@ -108,7 +108,7 @@
|
|
<if test="coachId!=null" > AND t1.TSO_COACHID = #{coachId,jdbcType=NUMERIC } </if>
|
|
<if test="coachId!=null" > AND t1.TSO_COACHID = #{coachId,jdbcType=NUMERIC } </if>
|
|
<if test="appCoachId!=null" > AND t1.TSO_APP_COACH_ID = #{appCoachId,jdbcType=NUMERIC } </if>
|
|
<if test="appCoachId!=null" > AND t1.TSO_APP_COACH_ID = #{appCoachId,jdbcType=NUMERIC } </if>
|
|
<if test="field != null and field != ''"> AND (t1.Tso_Name like '%' || #{field,jdbcType=VARCHAR} || '%' or t1.TSO_IDCARD like '%' || #{field,jdbcType=VARCHAR} || '%' or t1.Tso_Phone like '%' || #{field,jdbcType=VARCHAR} || '%') </if>
|
|
<if test="field != null and field != ''"> AND (t1.Tso_Name like '%' || #{field,jdbcType=VARCHAR} || '%' or t1.TSO_IDCARD like '%' || #{field,jdbcType=VARCHAR} || '%' or t1.Tso_Phone like '%' || #{field,jdbcType=VARCHAR} || '%') </if>
|
|
- <if test="schoolId != null "> and t1.TSO_SCHOOL_ID = #{schoolId,,jdbcType=NUMERIC} </if>
|
|
|
|
|
|
+ <if test="schoolId != null "> and t1.TSO_SCHOOL_ID = #{schoolId,jdbcType=NUMERIC} </if>
|
|
<if test="state != null and state != ''"> AND t1.TSO_STATE = #{state,jdbcType=VARCHAR }</if>
|
|
<if test="state != null and state != ''"> AND t1.TSO_STATE = #{state,jdbcType=VARCHAR }</if>
|
|
</where>
|
|
</where>
|
|
ORDER BY t1.TSO_ID desc
|
|
ORDER BY t1.TSO_ID desc
|
|
@@ -202,6 +202,43 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
+ <select id="getDayStuCountBySchoolId" parameterType="com.miaxis.tms.dto.TmsStudentInfoIdDTO" resultType="com.miaxis.tms.vo.TmsBmCountVo" >
|
|
|
|
+ select trunc(t.tso_applydate) as dateTime,count(1) as stuNum
|
|
|
|
+ from tms_student_info@tms${city} t
|
|
|
|
+ where 1=1
|
|
|
|
+ and t.tso_school_id = #{schoolId}
|
|
|
|
+ and trunc(t.tso_applydate) = trunc(sysdate #{vDay})
|
|
|
|
+ group by trunc(t.tso_applydate)
|
|
|
|
+ </select>
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ <select id="getMonthStuCountBySchoolId" parameterType="com.miaxis.tms.dto.TmsStudentInfoIdDTO" resultType="com.miaxis.tms.vo.TmsBmCountVo" >
|
|
|
|
+ select to_char(tso_applydate, 'yyyy-MM') as dateTime,count(1) as stuNum
|
|
|
|
+ from tms_student_info@tms${city} t
|
|
|
|
+ where 1=1
|
|
|
|
+ and t.tso_school_id = #{schoolId}
|
|
|
|
+ and trunc(t.tso_applydate,'MONTH') = ADD_MONTHS(TRUNC(SYSDATE, 'MONTH'), #{vDay})
|
|
|
|
+ group by to_char(tso_applydate, 'yyyy-MM')
|
|
|
|
+ order by to_char(tso_applydate, 'yyyy-MM')
|
|
|
|
+ </select>
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+ <select id="getYearStuCountBySchoolId" parameterType="com.miaxis.tms.dto.TmsStudentInfoIdDTO" resultType="com.miaxis.tms.vo.TmsBmCountVo" >
|
|
|
|
+ select to_char(tso_applydate, 'yyyy') as dateTime,count(1) as stuNum
|
|
|
|
+ from tms_student_info@tms${city} t
|
|
|
|
+ where 1=1
|
|
|
|
+ and t.tso_school_id = #{schoolId}
|
|
|
|
+ and trunc(t.tso_applydate,'MONTH') = ADD_MONTHS(TRUNC(SYSDATE, 'MONTH'), #{vDay})
|
|
|
|
+ group by to_char(tso_applydate, 'yyyy')
|
|
|
|
+ order by to_char(tso_applydate, 'yyyy')
|
|
|
|
+ </select>
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
|
|
+
|
|
<update id="upStuAppCoachIdById" parameterType="com.miaxis.tms.dto.TmsStudentInfoQrDTO">
|
|
<update id="upStuAppCoachIdById" parameterType="com.miaxis.tms.dto.TmsStudentInfoQrDTO">
|
|
update TMS_STUDENT_INFO@tms${city} set tso_app_coach_id = #{appCoachId} where tso_id = #{id}
|
|
update TMS_STUDENT_INFO@tms${city} set tso_app_coach_id = #{appCoachId} where tso_id = #{id}
|
|
</update>
|
|
</update>
|