mirror of
https://gitee.com/orangeform/orange-admin.git
synced 2026-01-17 18:46:36 +08:00
commit:同步1.4版本
This commit is contained in:
@@ -31,7 +31,6 @@
|
||||
AND zz_class.class_level = #{studentClassFilter.classLevel}
|
||||
</if>
|
||||
</if>
|
||||
AND zz_class.status = ${@com.orange.demo.common.core.constant.GlobalDeletedFlag@NORMAL}
|
||||
</sql>
|
||||
|
||||
<select id="getStudentClassList" resultMap="BaseResultMap" parameterType="com.orange.demo.courseclassservice.model.StudentClass">
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
package com.orange.demo.courseclassservice.model;
|
||||
|
||||
import com.alibaba.fastjson.annotation.JSONField;
|
||||
import com.orange.demo.common.core.annotation.DeletedFlagColumn;
|
||||
import lombok.Data;
|
||||
import javax.persistence.*;
|
||||
@@ -32,7 +31,6 @@ public class Grade {
|
||||
/**
|
||||
* 逻辑删除标记字段(1: 正常 -1: 已删除)。
|
||||
*/
|
||||
@JSONField(serialize = false)
|
||||
@DeletedFlagColumn
|
||||
private Integer status;
|
||||
}
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
package com.orange.demo.courseclassservice.model;
|
||||
|
||||
import com.alibaba.fastjson.annotation.JSONField;
|
||||
import com.orange.demo.courseclassinterface.constant.ClassLevel;
|
||||
import com.orange.demo.common.core.annotation.RelationDict;
|
||||
import com.orange.demo.common.core.annotation.RelationConstDict;
|
||||
@@ -77,7 +76,6 @@ public class StudentClass {
|
||||
/**
|
||||
* 逻辑删除标记字段(1: 正常 -1: 已删除)。
|
||||
*/
|
||||
@JSONField(serialize = false)
|
||||
@DeletedFlagColumn
|
||||
private Integer status;
|
||||
|
||||
|
||||
@@ -58,7 +58,6 @@ public class StudentServiceImpl extends BaseService<Student, Long> implements St
|
||||
@Override
|
||||
public Student saveNew(Student student) {
|
||||
student.setStudentId(idGenerator.nextLongId());
|
||||
student.setRegisterTime(new Date());
|
||||
MyModelUtil.setDefaultValue(student, "totalCoin", 0);
|
||||
MyModelUtil.setDefaultValue(student, "leftCoin", 0);
|
||||
MyModelUtil.setDefaultValue(student, "status", StudentStatus.NORMAL);
|
||||
@@ -76,7 +75,6 @@ public class StudentServiceImpl extends BaseService<Student, Long> implements St
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@Override
|
||||
public boolean update(Student student, Student originalStudent) {
|
||||
student.setRegisterTime(originalStudent.getRegisterTime());
|
||||
// 这里重点提示,在执行主表数据更新之前,如果有哪些字段不支持修改操作,请用原有数据对象字段替换当前数据字段。
|
||||
return studentMapper.updateByPrimaryKey(student) == 1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user