xiao547607 пре 5 година
родитељ
комит
585d5b5912

+ 7 - 0
common/src/main/resources/mapper/base/PersonInfo.xml

@@ -206,6 +206,13 @@
             <if test="searchParams.faceBound != null">
                 and a.face_bound = #{searchParams.faceBound}
             </if>
+            <if test="'1'.toString() == searchParams.isUploadPhoto and null != searchParams.isUploadPhoto">
+                and a.face_image_url is not null
+            </if>
+            <if test="'0'.toString() == searchParams.isUploadPhoto and null != searchParams.isUploadPhoto">
+                and a.face_image_url is null
+            </if>
+
             <if test="searchParams.abnormalDate != null">
                 <![CDATA[
                 and a.id_ in (

+ 7 - 1
web/src/main/java/com/jpsoft/smart/modules/base/controller/PersonInfoController.java

@@ -361,7 +361,8 @@ public class PersonInfoController {
             @ApiImplicitParam(name = "position3",value = "三级位置", required = false, paramType = "form",dataType = "String"),
             @ApiImplicitParam(name = "position4",value = "四级位置", required = false, paramType = "form",dataType = "String"),
             @ApiImplicitParam(name = "position5",value = "五级位置", required = false, paramType = "form",dataType = "String"),
-            @ApiImplicitParam(name = "faceBound",value = "是否同步", required = false, paramType = "form",dataType = "String")
+            @ApiImplicitParam(name = "faceBound",value = "是否同步", required = false, paramType = "form",dataType = "String"),
+            @ApiImplicitParam(name = "isUploadPhoto",value = "是否上传照片", required = false, paramType = "form",dataType = "String")
     })
     public MessageResult<Map> pageList(
             @RequestParam(value="name",defaultValue="") String name,
@@ -376,6 +377,7 @@ public class PersonInfoController {
             @RequestParam(value="pageIndex",defaultValue="1") int pageIndex,
             @RequestParam(value="pageSize",defaultValue="20") int pageSize,
             @RequestParam(value="faceBound",defaultValue="") String faceBound,
+            @RequestParam(value="isUploadPhoto",defaultValue="") String isUploadPhoto,
             @RequestAttribute String subject){
 
         //当前用户ID
@@ -433,6 +435,10 @@ public class PersonInfoController {
             searchParams.put("faceBound",faceBound);
         }
 
+        if(StringUtils.isNotEmpty(isUploadPhoto)){
+            searchParams.put("isUploadPhoto", isUploadPhoto);
+        }
+
         Page<PersonInfo> page = personInfoService.pageSearch(searchParams,pageIndex,pageSize,true,sortList);
         Page<PersonInfoDTO> pageDTO = PojoUtils.convertPage(page, PersonInfoDTO.class);