增加教师管理清空数据功能

This commit is contained in:
sk1551 2020-04-24 11:31:35 +08:00
parent bbf9bb35ac
commit 6577e41520
2 changed files with 14 additions and 8 deletions

View File

@ -109,7 +109,7 @@
icon="el-icon-delete"
@click="handleDelete(scope.row)"
v-hasPermi="['system:teacher:remove']"
>删除</el-button>
>清空</el-button>
</template>
</el-table-column>
</el-table>
@ -373,7 +373,7 @@ export default {
handleDelete(row) {
const ids = row.id || this.ids;
this.$confirm(
'是否确认删除教师基本信息编号为"' + ids + '"的数据项?',
'是否确认清空教师基本信息编号为"' + ids + '"的数据项?',
"警告",
{
confirmButtonText: "确定",

View File

@ -122,15 +122,21 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
where id = #{id}
</update>
<delete id="deleteByTeacherJbxxById" parameterType="Long">
delete from by_teacher_jbxx where id = #{id}
</delete>
<delete id="deleteByTeacherJbxxByIds" parameterType="String">
delete from by_teacher_jbxx where id in
<update id="deleteByTeacherJbxxById" parameterType="Long">
update by_teacher_jbxx
set zjhm=null, csrq=null, byyx=null, zy=null, xl=null, xw=null, cjgzrq=null, zgzs=null, createuserid=null
where id = #{id}
</update>
<update id="deleteByTeacherJbxxByIds" parameterType="String">
update by_teacher_jbxx
set zjhm=null, csrq=null, byyx=null, zy=null, xl=null, xw=null, cjgzrq=null, zgzs=null, createuserid=null
where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</update>
</mapper>