shicf
2025-01-09 9b5da188281e5ae4b6fb6219c8813e2e02a2e617
src/main/java/com/product/mobile/core/service/FaceMobileService.java
@@ -10,6 +10,7 @@
import com.alibaba.fastjson.JSONObject;
import com.drew.metadata.Face;
import com.google.common.collect.Lists;
import com.google.common.collect.Maps;
import com.google.common.collect.Sets;
import com.product.common.lang.StringUtils;
import com.product.core.cache.DataPoolCacheImpl;
@@ -187,7 +188,9 @@
         FieldSetEntity f = dte.getFieldSetEntity(j);
         if ("pk".equals(f.getString("field_type"))
               || "updated_by".equals(f.getString("field_name"))
               || "updated_utc_datetime".equals(f.getString("field_name"))) {
               || "updated_utc_datetime".equals(f.getString("field_name"))
               || "flowsign".equals(f.getString("field_type"))
               ) {
            continue;
         }
         if ("uuid".equals(f.getString("field_name"))) {
@@ -312,7 +315,7 @@
      if (CollectionUtil.isEmpty(groupMap)) {
         throw new BaseException(MobileCoreCode.GET_FACE_CONFIG_FAIL);
      }
      Map<String, Map<String, Object>> group = new HashMap<>();
      List<FaceFieldEntity> result = new ArrayList<>();
      Map<String, List<FieldSetEntity>> subTableFieldMap = new HashMap<>();
      for (FieldSetEntity fs : tagFieldSetEntityList) {
@@ -327,7 +330,21 @@
         String parentUuid1 = fieldSetEntity.get(0).getString("parent_uuid");
         if (!CollectionUtil.isEmpty(fieldSetEntity) && !StringUtils.isEmpty(parentUuid1)) {
            if (i + 1 == result.size()) {
               result.get(i).putOtherParam("parent_uuid", parentUuid1);
               Map<String, Object> o = group.get(parentUuid1);
               if (o == null) {
                  List<FieldSetEntity> fieldSetEntity1 = productSysFaceControlProperty.getFieldSetEntity(parentUuid1);
                  List<FieldSetEntity> fieldSetEntity2 = productSysFaceControlProperty.getFieldSetEntity(fieldSetEntity1.get(0).getString("parent_uuid"));
                  List<FieldSetEntity> fieldSetEntities = groupMap.get(fieldSetEntity2.get(0).getString("group_uuid"));
                  //list转map
                  Map<String, Object> map = new HashMap<>();
                  for (FieldSetEntity fieldSetEntity3 : fieldSetEntities) {
                     map.put(fieldSetEntity3.getString("property_name"), fieldSetEntity3.getString("property_value"));
                  }
                  group.put(parentUuid1, map);
                  o = map;
               }
               result.get(i).putOtherParam("parentContainerName", BaseUtil.ifNull(o.get("title"), o.get("label")));
               result.get(i).putOtherParam("parentContainer", parentUuid1);
            }
         }
      }