夏文涛 2 سال پیش
والد
کامیت
eebf4e5040
1فایلهای تغییر یافته به همراه6 افزوده شده و 6 حذف شده
  1. 6 6
      src/main/java/com/template/controller/SmartUserController.java

+ 6 - 6
src/main/java/com/template/controller/SmartUserController.java

@@ -2032,11 +2032,11 @@ public class SmartUserController implements SmartUserControllerAPI {
             boolean updateBatch = smartUserService.updateUserBatchById(updateStudent);
             if (!updateBatch) {
                 return CommonResult.fail("系统批量更新出错,导入失败");
-            }else {
+            } else {
 //                修改需同步到海康平台
                 for (SmartUser su : updateStudent) {
                     Integer identityId = su.getIdentityId();
-                    if (2==identityId || identityId==3) {
+                    if (2 == identityId || identityId == 3) {
                         Integer id = su.getId();
                         SmartOperationUser smartOperationUser = new SmartOperationUser();
                         smartOperationUser.setOperationId(id);
@@ -2635,7 +2635,7 @@ public class SmartUserController implements SmartUserControllerAPI {
         if (result > 0) {
             //        将添加的用户同步到海康平台
             Integer identityId = su.getIdentityId();
-            if (2==identityId || identityId==3) {
+            if (2 == identityId || identityId == 3) {
                 Integer id = su.getId();
                 SmartOperationUser smartOperationUser = new SmartOperationUser();
                 smartOperationUser.setOperationId(id);
@@ -3233,9 +3233,9 @@ public class SmartUserController implements SmartUserControllerAPI {
 
         int result = smartUserService.updateSmartUser(su);
 //        修改需同步到海康平台
-        if (result>0) {
+        if (result > 0) {
             Integer identityId = su.getIdentityId();
-            if (2==identityId || identityId==3) {
+            if (2 == identityId || identityId == 3) {
                 Integer id = su.getId();
                 SmartOperationUser smartOperationUser = new SmartOperationUser();
                 smartOperationUser.setOperationId(id);
@@ -3302,7 +3302,7 @@ public class SmartUserController implements SmartUserControllerAPI {
                             set.setTerm(semester.getName());
                             set.setSubjectId(teacher.getSubjectId());
                             set.setSubject(subjectData != null && subjectData.isPresent() ? subjectData.get().getName() : "");
-                            set.setClassId(su.getSchoolClass());
+                            set.setClassId(teacher.getClassId());
                             set.setClassName(classTeacherData != null && classTeacherData.isPresent() ? classTeacherData.get().getName() : "");
                             set.setTotalScore(0.0);
                             set.setLowingScore(0.0);