瀏覽代碼

Merge branch 'dev-hujianchun-bug' of province-qinghai/province-all into dev

hujianchun 3 月之前
父節點
當前提交
337425a907

+ 41 - 0
unis-plugin/unis-plugin-biz/src/main/java/com/unis/mobileInfo/modular/qcqualityinspection/enums/GradeEnum.java

@@ -0,0 +1,41 @@
1
+package com.unis.mobileInfo.modular.qcqualityinspection.enums;
2
+
3
+public enum GradeEnum {
4
+
5
+    FIRST("一等", "1"),
6
+    TWO("二等", "2"),
7
+    THREE("三等", "3"),
8
+    FOUR("四等", "4"),
9
+    FIVE("五等", "5"),
10
+    ENDURES("等外", "6");
11
+
12
+
13
+    GradeEnum(String key, String value) {
14
+        this.key = key;
15
+        this.value = value;
16
+    }
17
+
18
+    private String key;
19
+    private String value;
20
+
21
+
22
+    public String getKey() {
23
+        return key;
24
+    }
25
+
26
+    public String getValue() {
27
+        return value;
28
+    }
29
+
30
+
31
+    //获取对应值
32
+    public static String getIntValue(String key) {
33
+        GradeEnum[] values = GradeEnum.values();
34
+        for (GradeEnum value : values) {
35
+            if (value.getKey().equals(key)) {
36
+                return value.getValue();
37
+            }
38
+        }
39
+        return null;
40
+    }
41
+}

+ 3 - 1
unis-plugin/unis-plugin-biz/src/main/java/com/unis/mobileInfo/modular/qcqualityinspection/service/impl/BusinessQcQualityInspectionServiceImpl.java

@@ -31,6 +31,7 @@ import com.unis.basic.info.modular.storehouseInfo.mapper.StorehouseInfoMapper;
31
 import com.unis.basic.info.modular.unitInfo.mapper.EnumMapper;
31
 import com.unis.basic.info.modular.unitInfo.mapper.EnumMapper;
32
 import com.unis.basic.info.modular.warehouseInfo.entity.WarehouseInfo;
32
 import com.unis.basic.info.modular.warehouseInfo.entity.WarehouseInfo;
33
 import com.unis.basic.info.modular.warehouseInfo.mapper.WarehouseInfoMapper;
33
 import com.unis.basic.info.modular.warehouseInfo.mapper.WarehouseInfoMapper;
34
+import com.unis.mobileInfo.modular.qcqualityinspection.enums.GradeEnum;
34
 import com.unis.mobileInfo.modular.qcqualityinspection.param.*;
35
 import com.unis.mobileInfo.modular.qcqualityinspection.param.*;
35
 import com.unis.mobileInfo.modular.qcqualityinspection.vo.ReserveQualityCityPageVO;
36
 import com.unis.mobileInfo.modular.qcqualityinspection.vo.ReserveQualityCityPageVO;
36
 import com.unis.mobileInfo.modular.qcqualityinspection.vo.ReserveQualityOrgPageVO;
37
 import com.unis.mobileInfo.modular.qcqualityinspection.vo.ReserveQualityOrgPageVO;
@@ -231,9 +232,10 @@ public class BusinessQcQualityInspectionServiceImpl extends ServiceImpl<Business
231
     public Page<ReserveQualityStoreHousePageVO> reserveQualityStoreHousePage(ReserveQualityStoreHousePageParam pageParam) {
232
     public Page<ReserveQualityStoreHousePageVO> reserveQualityStoreHousePage(ReserveQualityStoreHousePageParam pageParam) {
232
 
233
 
233
         Page<BusinessQcQualityInspection> page = new Page<>(pageParam.getCurrent(), pageParam.getSize());
234
         Page<BusinessQcQualityInspection> page = new Page<>(pageParam.getCurrent(), pageParam.getSize());
235
+        String ypdj = GradeEnum.getIntValue(pageParam.getYpdj());
234
 
236
 
235
         return businessQcQualityInspectionMapper.selectMyPage(page, pageParam.getBasicStorehouseName(), pageParam.getGrainVarietyName(),
237
         return businessQcQualityInspectionMapper.selectMyPage(page, pageParam.getBasicStorehouseName(), pageParam.getGrainVarietyName(),
236
-                pageParam.getReceiveYear(), pageParam.getYpdj(), pageParam.getOrgId());
238
+                pageParam.getReceiveYear(), ypdj, pageParam.getOrgId());
237
     }
239
     }
238
 
240
 
239
 
241