|
@@ -66,6 +66,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="privacyType != null and privacyType != ''"> and a.privacy_type = #{privacyType}</if>
|
|
|
<if test="scoreClassId != null and scoreClassId != ''"> and find_in_set(a.score_class_id,#{scoreClassId})</if>
|
|
|
</where>
|
|
|
+ order by score_title DESC
|
|
|
</select>
|
|
|
|
|
|
<select id="selectScoreDataByScoreId" parameterType="Long" resultMap="ScoreDataScoreDataDetailsResult">
|
|
@@ -76,6 +77,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
where a.score_id = #{scoreId}
|
|
|
</select>
|
|
|
|
|
|
+ <select id="selectScoreDataForParents" parameterType="ScoreData" resultMap="ScoreDataScoreDataDetailsResult">
|
|
|
+ select a.score_id, a.score_title, a.score_time, a.score_class_id, a.score_class_name, a.privacy_type, a.create_by, a.create_time, a.update_by, a.update_time, a.remark,
|
|
|
+ b.score_details_id as sub_score_details_id, b.score_id as sub_score_id,b.zongfen as sub_zongfen, b.score_sort as sub_score_sort, b.details_type as sub_details_type, b.score_data_name as sub_score_data_name, b.yuwen as sub_yuwen, b.shuxue as sub_shuxue, b.yingyu as sub_yingyu, b.wuli as sub_wuli, b.huaxue as sub_huaxue, b.shengwu as sub_shengwu, b.zhengzhi as sub_zhengzhi, b.lishi as sub_lishi, b.dili as sub_dili, b.tiyu as sub_tiyu, b.wenzong as sub_wenzong, b.lizong as sub_lizong, b.zhengcefen as sub_zhengcefen, b.create_by as sub_create_by, b.create_time as sub_create_time, b.update_by as sub_update_by, b.update_time as sub_update_time, b.remark as sub_remark
|
|
|
+ from score_data a
|
|
|
+ left join score_data_details b on b.score_id = a.score_id
|
|
|
+ where a.score_id = #{scoreId} and find_in_set(b.score_data_name_id,#{params.stdId})
|
|
|
+ </select>
|
|
|
+
|
|
|
<select id="selectScoreIdByScoreClassId" parameterType="string" resultMap="ScoreDataResult">
|
|
|
SELECT
|
|
|
score_id
|
|
@@ -173,9 +182,9 @@ WHERE
|
|
|
</delete>
|
|
|
|
|
|
<insert id="batchScoreDataDetails">
|
|
|
- insert into score_data_details( score_details_id, score_id, score_sort, score_data_name, yuwen, shuxue, yingyu, wuli, huaxue, shengwu, zhengzhi, lishi, dili, tiyu, wenzong, lizong, zhengcefen,zongfen, create_by, create_time, update_by, update_time, remark) values
|
|
|
+ insert into score_data_details( score_details_id, score_id, score_sort, score_data_name,score_data_name_id, yuwen, shuxue, yingyu, wuli, huaxue, shengwu, zhengzhi, lishi, dili, tiyu, wenzong, lizong, zhengcefen,zongfen, details_type,create_by, create_time, update_by, update_time, remark) values
|
|
|
<foreach item="item" index="index" collection="list" separator=",">
|
|
|
- ( #{item.scoreDetailsId}, #{item.scoreId}, #{item.scoreSort}, #{item.scoreDataName}, #{item.yuwen}, #{item.shuxue}, #{item.yingyu}, #{item.wuli}, #{item.huaxue}, #{item.shengwu}, #{item.zhengzhi}, #{item.lishi}, #{item.dili}, #{item.tiyu}, #{item.wenzong}, #{item.lizong}, #{item.zhengcefen},#{item.zongfen}, #{item.createBy}, #{item.createTime}, #{item.updateBy}, #{item.updateTime}, #{item.remark})
|
|
|
+ ( #{item.scoreDetailsId}, #{item.scoreId}, #{item.scoreSort}, #{item.scoreDataName},#{item.scoreDataNameId}, #{item.yuwen}, #{item.shuxue}, #{item.yingyu}, #{item.wuli}, #{item.huaxue}, #{item.shengwu}, #{item.zhengzhi}, #{item.lishi}, #{item.dili}, #{item.tiyu}, #{item.wenzong}, #{item.lizong}, #{item.zhengcefen},#{item.zongfen},#{item.detailsType}, #{item.createBy}, #{item.createTime}, #{item.updateBy}, #{item.updateTime}, #{item.remark})
|
|
|
</foreach>
|
|
|
</insert>
|
|
|
</mapper>
|