Pārlūkot izejas kodu

Merge branch 'dev' of http://101.36.160.140:21044/depot-qinghai/depot-business-qinghai into dev

tangsong 1 gadu atpakaļ
vecāks
revīzija
7aecb49e34

+ 4 - 0
src/main/java/com/chinaitop/depot/grainReserves/common/PageParam.java

@@ -23,4 +23,8 @@ public class PageParam {
23 23
     @NotNull(message = "页码非空")
24 24
     @Min(value = 1, message = "每页条数>=1")
25 25
     private Integer pageSize;
26
+
27
+    @ApiModelProperty(value = "库区编码")
28
+    @NotNull(message = "库区编码非空")
29
+    private Integer orgId;
26 30
 }

+ 1 - 1
src/main/java/com/chinaitop/depot/grainReserves/mapper/BizGopsPlanMapper.java

@@ -14,7 +14,7 @@ import java.util.List;
14 14
  */
15 15
 @Repository
16 16
 public interface BizGopsPlanMapper {
17
-    List<BizGopsPlan> getPageList(@Param("orgName") String orgName);
17
+    List<BizGopsPlan> getPageList(@Param("planName") String planName, @Param("orgId") Integer orgId);
18 18
 
19 19
     List<GopsPlanObject> getPlanSaleList(@Param("id") String id);
20 20
 

+ 3 - 2
src/main/java/com/chinaitop/depot/grainReserves/mapper/BizGopsPlanMapper.xml

@@ -19,8 +19,9 @@
19 19
         LEFT JOIN org_info oi ON bfp.org_id = oi.org_id
20 20
         <where>
21 21
             bfp.`status` = 1
22
-            <if test="orgName != null and orgName != ''">
23
-                oi.org_name LIKE CONCAT("%", orgName, "%")
22
+            and bfp.org_id = #{orgId}
23
+            <if test="planName != null and planName != ''">
24
+               and bfp.plan_name LIKE CONCAT("%", #{planName}, "%")
24 25
             </if>
25 26
         </where>
26 27
     </select>

+ 1 - 1
src/main/java/com/chinaitop/depot/grainReserves/model/BizGopsPlan.java

@@ -42,7 +42,7 @@ public class BizGopsPlan {
42 42
     private Integer planType;
43 43
 
44 44
     @ApiModelProperty(value = "计划下达时间")
45
-    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
45
+    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
46 46
     private Date planReleaseTime;
47 47
 
48 48
     @ApiModelProperty(value = "状态 0:保存;1:下发;")

+ 2 - 2
src/main/java/com/chinaitop/depot/grainReserves/model/BizGopsPlanPage.java

@@ -17,7 +17,7 @@ import java.io.Serializable;
17 17
 public class BizGopsPlanPage extends PageParam implements Serializable {
18 18
     private static final long serialVersionUID = 4988791677403961372L;
19 19
 
20
-    @ApiModelProperty(value = "库区名称")
21
-    private String orgName;
20
+    @ApiModelProperty(value = "计划名称")
21
+    private String planName;
22 22
 
23 23
 }

+ 4 - 4
src/main/java/com/chinaitop/depot/grainReserves/model/GopsPlanObject.java

@@ -50,28 +50,28 @@ public class GopsPlanObject {
50 50
     private Integer warehouseId;
51 51
 
52 52
     @ApiModelProperty(value = "货位名称", position = 6)
53
-    private Integer warehouseName;
53
+    private String warehouseName;
54 54
 
55 55
     /** 粮食品种;外库depot_qh.basic_enum的id; */
56 56
     @ApiModelProperty(value = "粮食品种id", position = 7)
57 57
     private Integer grainVarietyId;
58 58
 
59 59
     @ApiModelProperty(value = "粮食品种名称", position = 8)
60
-    private Integer grainVarietyName;
60
+    private String grainVarietyName;
61 61
 
62 62
     /** 粮食性质;外库depot_qh.basic_enum的id; */
63 63
     @ApiModelProperty(value = "粮食性质id", position = 9)
64 64
     private Integer grainNatureId;
65 65
 
66 66
     @ApiModelProperty(value = "粮食性质名称", position = 10)
67
-    private Integer grainNatureName;
67
+    private String grainNatureName;
68 68
 
69 69
     /** 粮食等级;外库depot_qh.basic_enum的id; */
70 70
     @ApiModelProperty(value = "粮食等级id", position = 11)
71 71
     private Integer grainGradeId;
72 72
 
73 73
     @ApiModelProperty(value = "粮食等级名称", position = 12)
74
-    private Integer grainGradeName;
74
+    private String grainGradeName;
75 75
 
76 76
     /** 计划数量 */
77 77
     @ApiModelProperty(value = "计划数量", position = 13)

+ 1 - 1
src/main/java/com/chinaitop/depot/grainReserves/service/BizGopsPlanService.java

@@ -31,7 +31,7 @@ public interface BizGopsPlanService {
31 31
         @Override
32 32
         public PageInfo<BizGopsPlan> getPageList(BizGopsPlanPage pageParam) {
33 33
             PageHelper.startPage(pageParam.getPageNum(), pageParam.getPageSize());
34
-            List<BizGopsPlan> list = gopsPlanMapper.getPageList(pageParam.getOrgName());
34
+            List<BizGopsPlan> list = gopsPlanMapper.getPageList(pageParam.getPlanName(), pageParam.getOrgId());
35 35
             return new PageInfo<>(list);
36 36
         }
37 37