2 Commits 93058b7cb5 ... f2bcaefefc

Auteur SHA1 Bericht Datum
  brealinxx f2bcaefefc Merge branch 'dev' of https://git.yingcaibx.com/tl/api into dev 5 maanden geleden
  brealinxx 1342921b53 性别修改 5 maanden geleden

+ 10 - 10
src/main/java/com/xjrsoft/module/hikvision/util/OutInRecordUtil.java

@@ -126,16 +126,16 @@ public class OutInRecordUtil {
             }
             if (personId == null) continue;
 
-            int statusInt = item.get("inAndOutType").getAsInt();
-            int status = -1;
-            switch (statusInt){
-                case 0:
-                    status = 1;
-                    break;
-                case 1:
-                    status = 0;
-                    break;
-            }
+            int status = item.get("inAndOutType").getAsInt();
+//            int status = -1;
+//            switch (statusInt){
+//                case 0:
+//                    status = 1;
+//                    break;
+//                case 1:
+//                    status = 0;
+//                    break;
+//            }
 
             String uri = item.get("picUri").isJsonNull() ? null : item.get("picUri").getAsString();
             String recordTime = item.get("eventTime").isJsonNull() ? null : item.get("eventTime").getAsString();

+ 5 - 2
src/main/java/com/xjrsoft/module/outint/controller/StudentOutInRecordController.java

@@ -42,6 +42,7 @@ import javax.validation.Valid;
 import java.text.SimpleDateFormat;
 import java.util.ArrayList;
 import java.util.List;
+import java.util.Objects;
 
 /**
 * @title: 学生出入记录
@@ -76,11 +77,13 @@ public class StudentOutInRecordController {
                 .leftJoin(XjrUser.class,XjrUser::getId,StudentOutInRecord::getUserId,
                         ext->ext.selectAs(XjrUser::getCredentialNumber,StudentOutInRecordPageVo::getIdentityCard)
                                 .selectAs(XjrUser::getMobile,StudentOutInRecordPageVo::getPhone)
-                                .select(XjrUser::getName))
+                                .select(XjrUser::getName)
+                                .leftJoin(DictionaryDetail.class, DictionaryDetail::getCode, XjrUser::getGender,
+                                        genderExt -> genderExt.selectAs(DictionaryDetail::getName, StudentOutInRecordPageVo::getGender)))
                 .leftJoin(BaseClass.class,BaseClass::getId,StudentOutInRecord::getClassId,ext->ext.selectAs(BaseClass::getName,StudentOutInRecordPageVo::getClassCn))
                 .leftJoin(XjrUser.class,XjrUser::getId,StudentOutInRecord::getTeacherId,ext->ext.selectAs(XjrUser::getName,StudentOutInRecordPageVo::getTeacherCn))
                 .leftJoin(BaseStudentSchoolRoll.class,BaseStudentSchoolRoll::getUserId,StudentOutInRecord::getUserId)
-                .leftJoin(DictionaryDetail.class,DictionaryDetail::getCode, XjrUser::getGender, ext->ext.selectAs(DictionaryDetail::getName, StudentOutInRecordPageVo::getGender))
+                .leftJoin(DictionaryDetail.class, DictionaryDetail::getCode, XjrUser::getGender,ext -> ext.selectAs(DictionaryDetail::getName, StudentOutInRecordPageVo::getGender))
                 .leftJoin(DictionaryDetail.class,DictionaryDetail::getCode, BaseStudentSchoolRoll::getStduyStatus, ext->ext.selectAs(DictionaryDetail::getName, StudentOutInRecordPageVo::getStduyStatusCn))
                 ;