From 62abd52e558154724ee2172a4f0af451c8e34f64 Mon Sep 17 00:00:00 2001
From: luxiaotao1123 <t1341870251@163.com>
Date: 星期四, 06 八月 2020 14:54:52 +0800
Subject: [PATCH] #

---
 src/main/java/com/zy/asrs/mapper/LocDetlMapper.java              |   30 
 src/main/java/com/zy/asrs/utils/VersionUtils.java                |   54 
 src/main/java/com/zy/asrs/mapper/WrkDetlMapper.java              |   12 
 src/main/java/com/zy/asrs/entity/MatCode.java                    |  593 ++++++++++
 src/main/resources/mapper/LocDetlMapper.xml                      |   71 +
 src/main/java/com/zy/asrs/mapper/RowLastnoMapper.java            |   12 
 pom.xml                                                          |    6 
 src/main/java/com/zy/common/model/StartupDto.java                |   47 
 src/main/java/com/zy/asrs/mapper/WrkLastnoMapper.java            |   12 
 src/main/java/com/zy/asrs/service/impl/MatCodeServiceImpl.java   |   12 
 src/main/java/com/zy/core/model/protocol/StaProtocol.java        |    3 
 src/main/resources/mapper/WrkDetlMapper.xml                      |   28 
 src/main/java/com/zy/asrs/entity/WrkLastno.java                  |  215 +++
 src/main/java/com/zy/asrs/entity/WrkDetl.java                    |  182 +++
 src/main/java/com/zy/core/MainProcess.java                       |    2 
 src/main/resources/mapper/StaDescMapper.xml                      |   22 
 src/main/java/com/zy/core/properties/SystemProperties.java       |    2 
 src/main/java/com/zy/asrs/service/WrkDetlService.java            |   14 
 src/main/java/com/zy/asrs/service/RowLastnoService.java          |    8 
 src/main/java/com/zy/asrs/service/impl/WrkLastnoServiceImpl.java |   12 
 src/main/resources/mapper/WrkLastnoMapper.xml                    |   19 
 src/main/java/com/zy/asrs/mapper/StaDescMapper.java              |   12 
 src/main/java/com/zy/asrs/service/LocDetlService.java            |   27 
 src/main/resources/mapper/RowLastnoMapper.xml                    |   22 
 src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java      |   92 +
 src/main/resources/mapper/WaitPakinMapper.xml                    |   22 
 src/main/java/com/zy/asrs/service/impl/WrkDetlServiceImpl.java   |   52 
 src/main/java/com/zy/common/utils/HttpHandler.java               |  213 +++
 src/main/java/com/zy/asrs/service/impl/LocDetlServiceImpl.java   |   43 
 src/main/resources/mapper/MatCodeMapper.xml                      |   48 
 src/main/java/com/zy/common/service/WmsService.java              |   50 
 src/main/java/com/zy/asrs/entity/RowLastno.java                  |  262 ++++
 src/main/java/com/zy/asrs/mapper/WaitPakinMapper.java            |   12 
 src/main/java/com/zy/asrs/service/impl/CommonService.java        |  227 ++++
 src/main/java/com/zy/asrs/service/WrkLastnoService.java          |    8 
 src/main/java/com/zy/common/model/MatDto.java                    |   17 
 src/main/java/com/zy/asrs/mapper/MatCodeMapper.java              |   12 
 src/main/java/com/zy/asrs/service/MatCodeService.java            |    8 
 src/main/java/com/zy/asrs/entity/WaitPakin.java                  |  258 ++++
 src/main/java/com/zy/asrs/entity/LocDetl.java                    |  128 ++
 src/main/java/com/zy/asrs/service/impl/RowLastnoServiceImpl.java |   12 
 src/main/java/com/zy/asrs/mapper/WrkMastMapper.java              |    6 
 src/main/java/com/zy/asrs/service/StaDescService.java            |    8 
 src/main/java/com/zy/common/model/Shelves.java                   |  113 ++
 src/main/java/com/zy/asrs/service/impl/StaDescServiceImpl.java   |   12 
 src/main/java/com/zy/asrs/entity/StaDesc.java                    |  291 +++++
 46 files changed, 3,306 insertions(+), 5 deletions(-)

diff --git a/pom.xml b/pom.xml
index 901114c..da038fe 100644
--- a/pom.xml
+++ b/pom.xml
@@ -92,6 +92,12 @@
             <version>1.16.22</version>
             <scope>provided</scope>
         </dependency>
+        <!-- okHttp3 -->
+        <dependency>
+            <groupId>com.squareup.okhttp3</groupId>
+            <artifactId>okhttp</artifactId>
+            <version>3.10.0</version>
+        </dependency>
     </dependencies>
 
     <build>
diff --git a/src/main/java/com/zy/asrs/entity/LocDetl.java b/src/main/java/com/zy/asrs/entity/LocDetl.java
new file mode 100644
index 0000000..0954644
--- /dev/null
+++ b/src/main/java/com/zy/asrs/entity/LocDetl.java
@@ -0,0 +1,128 @@
+package com.zy.asrs.entity;
+
+import com.baomidou.mybatisplus.annotations.TableField;
+import com.baomidou.mybatisplus.annotations.TableId;
+import com.baomidou.mybatisplus.annotations.TableName;
+import com.baomidou.mybatisplus.enums.IdType;
+import com.core.common.Cools;
+import com.core.common.SpringUtils;
+import com.zy.asrs.service.LocMastService;
+import com.zy.system.entity.User;
+import com.zy.system.service.UserService;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.io.Serializable;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+
+@Data
+@TableName("asr_loc_detl")
+public class LocDetl implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    @ApiModelProperty(value= "搴撲綅鍙�")
+    @TableId(value = "loc_no", type = IdType.INPUT)
+    @TableField("loc_no")
+    private String locNo;
+
+    @ApiModelProperty(value= "鐗╂枡")
+    @TableId(value = "matnr", type = IdType.INPUT)
+    private String matnr;
+
+    @ApiModelProperty(value= "鐗╂枡鎻忚堪")
+    private String maktx;
+
+    @ApiModelProperty(value= "瑙勬牸")
+    private String lgnum;
+
+    @ApiModelProperty(value= "鐗╂枡绫诲埆")
+    private String type;
+
+    @ApiModelProperty(value= "棰滆壊")
+    private String color;
+
+    @ApiModelProperty(value= "渚涘簲鍟�")
+    private String supplier;
+
+    @ApiModelProperty(value= "浠撳簱")
+    private String warehouse;
+
+    @ApiModelProperty(value= "鍝佺墝")
+    private String brand;
+
+    @ApiModelProperty(value= "鏁伴噺")
+    private Double anfme;
+
+    @ApiModelProperty(value= "鍗曚綅")
+    private String altme;
+
+    @ApiModelProperty(value= "鎵樼洏鏉$爜")
+    private String zpallet;
+
+    @ApiModelProperty(value= "鐢ㄦ埛ID")
+    private String bname;
+
+    @ApiModelProperty(value= "澶囨敞")
+    private String memo;
+
+    @ApiModelProperty(value= "淇敼浜哄憳")
+    @TableField("modi_user")
+    private Long modiUser;
+
+    @ApiModelProperty(value= "淇敼鏃堕棿")
+    @TableField("modi_time")
+    private Date modiTime;
+
+    @ApiModelProperty(value= "鍒涘缓鑰�")
+    @TableField("appe_user")
+    private Long appeUser;
+
+    @ApiModelProperty(value= "娣诲姞鏃堕棿")
+    @TableField("appe_time")
+    private Date appeTime;
+
+    public String getLocNo$(){
+        LocMastService service = SpringUtils.getBean(LocMastService.class);
+        LocMast locMast = service.selectById(this.locNo);
+        if (!Cools.isEmpty(locMast)){
+            return String.valueOf(locMast.getLocNo());
+        }
+        return null;
+    }
+
+    public String getModiUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.modiUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public String getModiTime$(){
+        if (Cools.isEmpty(this.modiTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.modiTime);
+    }
+
+
+    public String getAppeUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.appeUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public String getAppeTime$(){
+        if (Cools.isEmpty(this.appeTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.appeTime);
+    }
+
+}
diff --git a/src/main/java/com/zy/asrs/entity/MatCode.java b/src/main/java/com/zy/asrs/entity/MatCode.java
new file mode 100644
index 0000000..ddaa1a0
--- /dev/null
+++ b/src/main/java/com/zy/asrs/entity/MatCode.java
@@ -0,0 +1,593 @@
+package com.zy.asrs.entity;
+
+import com.baomidou.mybatisplus.annotations.TableField;
+import com.baomidou.mybatisplus.annotations.TableId;
+import com.baomidou.mybatisplus.annotations.TableName;
+import com.baomidou.mybatisplus.enums.IdType;
+import com.core.common.Cools;
+import com.core.common.SpringUtils;
+import com.zy.system.entity.User;
+import com.zy.system.service.UserService;
+import io.swagger.annotations.ApiModelProperty;
+
+import java.io.Serializable;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+
+@TableName("bas_mat_code")
+public class MatCode implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 鐗╂枡缂栫爜
+     */
+    @ApiModelProperty(value= "鐗╂枡缂栫爜")
+    @TableId(value = "mat_no", type = IdType.INPUT)
+    @TableField("mat_no")
+    private String matNo;
+
+    /**
+     * 鏉$爜
+     */
+    @ApiModelProperty(value= "鏉″舰鐮�")
+    private String barcode;
+
+    /**
+     * 鐗╂枡鍚嶇О
+     */
+    @ApiModelProperty(value= "鐗╂枡鍚嶇О")
+    @TableField("mat_name")
+    private String matName;
+
+    /**
+     * 鐗╂枡鍗曚綅
+     */
+    @ApiModelProperty(value= "鐗╂枡鍗曚綅")
+    private String str1;
+
+    @ApiModelProperty(value= "鐗╂枡瑙勬牸")
+    private String str2;
+
+    @ApiModelProperty(value= "棰滆壊")
+    private String str3;
+
+    @ApiModelProperty(value= "瀹㈡埛")
+    private String str4;
+
+    @ApiModelProperty(value= "")
+    private String str5;
+
+    @ApiModelProperty(value= "")
+    private String str6;
+
+    @ApiModelProperty(value= "")
+    private String str7;
+
+    @ApiModelProperty(value= "")
+    private String str8;
+
+    @ApiModelProperty(value= "")
+    private String str9;
+
+    @ApiModelProperty(value= "")
+    private String str10;
+
+    @ApiModelProperty(value= "")
+    private String str11;
+
+    @ApiModelProperty(value= "")
+    private String str12;
+
+    @ApiModelProperty(value= "")
+    private String str13;
+
+    @ApiModelProperty(value= "")
+    private String str14;
+
+    @ApiModelProperty(value= "")
+    private String str15;
+
+    @ApiModelProperty(value= "")
+    private String str16;
+
+    @ApiModelProperty(value= "")
+    private String str17;
+
+    @ApiModelProperty(value= "")
+    private String str18;
+
+    @ApiModelProperty(value= "")
+    private String str19;
+
+    @ApiModelProperty(value= "")
+    private String str20;
+
+    @ApiModelProperty(value= "")
+    private String str21;
+
+    @ApiModelProperty(value= "")
+    private String str22;
+
+    @ApiModelProperty(value= "")
+    private String str23;
+
+    @ApiModelProperty(value= "閲嶉噺")
+    private Double num1;
+
+    @ApiModelProperty(value= "")
+    private Double num2;
+
+    @ApiModelProperty(value= "")
+    private Double num3;
+
+    @ApiModelProperty(value= "")
+    private Double num4;
+
+    @ApiModelProperty(value= "")
+    private Double num5;
+
+    @ApiModelProperty(value= "")
+    private Double num6;
+
+    @ApiModelProperty(value= "")
+    private Date date1;
+
+    /**
+     * 鍒涘缓鑰�
+     */
+    @ApiModelProperty(value= "鍒涘缓鑰�")
+    @TableField("appe_user")
+    private Long appeUser;
+
+    /**
+     * 娣诲姞鏃堕棿
+     */
+    @ApiModelProperty(value= "娣诲姞鏃堕棿")
+    @TableField("appe_time")
+    private Date appeTime;
+
+    /**
+     * 淇敼浜哄憳
+     */
+    @ApiModelProperty(value= "淇敼浜哄憳")
+    @TableField("modi_user")
+    private Long modiUser;
+
+    /**
+     * 淇敼鏃堕棿
+     */
+    @ApiModelProperty(value= "淇敼鏃堕棿")
+    @TableField("modi_time")
+    private Date modiTime;
+
+    @ApiModelProperty(value= "")
+    private Short status;
+
+    public MatCode() {}
+
+    public MatCode(String barcode, String matName, String str1, String str2, String str3, String str4, String str5, String str6, String str7, String str8, String str9, String str10, String str11, String str12, String str13, String str14, String str15, String str16, String str17, String str18, String str19, String str20, String str21, String str22, String str23, Double num1, Double num2, Double num3, Double num4, Double num5, Double num6, Date date1, Long appeUser, Date appeTime, Long modiUser, Date modiTime, Short status) {
+        this.barcode = barcode;
+        this.matName = matName;
+        this.str1 = str1;
+        this.str2 = str2;
+        this.str3 = str3;
+        this.str4 = str4;
+        this.str5 = str5;
+        this.str6 = str6;
+        this.str7 = str7;
+        this.str8 = str8;
+        this.str9 = str9;
+        this.str10 = str10;
+        this.str11 = str11;
+        this.str12 = str12;
+        this.str13 = str13;
+        this.str14 = str14;
+        this.str15 = str15;
+        this.str16 = str16;
+        this.str17 = str17;
+        this.str18 = str18;
+        this.str19 = str19;
+        this.str20 = str20;
+        this.str21 = str21;
+        this.str22 = str22;
+        this.str23 = str23;
+        this.num1 = num1;
+        this.num2 = num2;
+        this.num3 = num3;
+        this.num4 = num4;
+        this.num5 = num5;
+        this.num6 = num6;
+        this.date1 = date1;
+        this.appeUser = appeUser;
+        this.appeTime = appeTime;
+        this.modiUser = modiUser;
+        this.modiTime = modiTime;
+        this.status = status;
+    }
+
+//    MatCode matCode = new MatCode(
+//            null,    // 鏉$爜
+//            null,    // 鐗╂枡鍚嶇О
+//            null,    // 鐗╂枡鍗曚綅
+//            null,    // 鐗╂枡瑙勬牸
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 
+//            null,    // 鍒涘缓鑰�
+//            null,    // 娣诲姞鏃堕棿
+//            null,    // 淇敼浜哄憳
+//            null,    // 淇敼鏃堕棿
+//            null    // 
+//    );
+
+    public String getMatNo() {
+        return matNo;
+    }
+
+    public void setMatNo(String matNo) {
+        this.matNo = matNo;
+    }
+
+    public String getBarcode() {
+        return barcode;
+    }
+
+    public void setBarcode(String barcode) {
+        this.barcode = barcode;
+    }
+
+    public String getMatName() {
+        return matName;
+    }
+
+    public void setMatName(String matName) {
+        this.matName = matName;
+    }
+
+    public String getStr1() {
+        return str1;
+    }
+
+    public void setStr1(String str1) {
+        this.str1 = str1;
+    }
+
+    public String getStr2() {
+        return str2;
+    }
+
+    public void setStr2(String str2) {
+        this.str2 = str2;
+    }
+
+    public String getStr3() {
+        return str3;
+    }
+
+    public void setStr3(String str3) {
+        this.str3 = str3;
+    }
+
+    public String getStr4() {
+        return str4;
+    }
+
+    public void setStr4(String str4) {
+        this.str4 = str4;
+    }
+
+    public String getStr5() {
+        return str5;
+    }
+
+    public void setStr5(String str5) {
+        this.str5 = str5;
+    }
+
+    public String getStr6() {
+        return str6;
+    }
+
+    public void setStr6(String str6) {
+        this.str6 = str6;
+    }
+
+    public String getStr7() {
+        return str7;
+    }
+
+    public void setStr7(String str7) {
+        this.str7 = str7;
+    }
+
+    public String getStr8() {
+        return str8;
+    }
+
+    public void setStr8(String str8) {
+        this.str8 = str8;
+    }
+
+    public String getStr9() {
+        return str9;
+    }
+
+    public void setStr9(String str9) {
+        this.str9 = str9;
+    }
+
+    public String getStr10() {
+        return str10;
+    }
+
+    public void setStr10(String str10) {
+        this.str10 = str10;
+    }
+
+    public String getStr11() {
+        return str11;
+    }
+
+    public void setStr11(String str11) {
+        this.str11 = str11;
+    }
+
+    public String getStr12() {
+        return str12;
+    }
+
+    public void setStr12(String str12) {
+        this.str12 = str12;
+    }
+
+    public String getStr13() {
+        return str13;
+    }
+
+    public void setStr13(String str13) {
+        this.str13 = str13;
+    }
+
+    public String getStr14() {
+        return str14;
+    }
+
+    public void setStr14(String str14) {
+        this.str14 = str14;
+    }
+
+    public String getStr15() {
+        return str15;
+    }
+
+    public void setStr15(String str15) {
+        this.str15 = str15;
+    }
+
+    public String getStr16() {
+        return str16;
+    }
+
+    public void setStr16(String str16) {
+        this.str16 = str16;
+    }
+
+    public String getStr17() {
+        return str17;
+    }
+
+    public void setStr17(String str17) {
+        this.str17 = str17;
+    }
+
+    public String getStr18() {
+        return str18;
+    }
+
+    public void setStr18(String str18) {
+        this.str18 = str18;
+    }
+
+    public String getStr19() {
+        return str19;
+    }
+
+    public void setStr19(String str19) {
+        this.str19 = str19;
+    }
+
+    public String getStr20() {
+        return str20;
+    }
+
+    public void setStr20(String str20) {
+        this.str20 = str20;
+    }
+
+    public String getStr21() {
+        return str21;
+    }
+
+    public void setStr21(String str21) {
+        this.str21 = str21;
+    }
+
+    public String getStr22() {
+        return str22;
+    }
+
+    public void setStr22(String str22) {
+        this.str22 = str22;
+    }
+
+    public String getStr23() {
+        return str23;
+    }
+
+    public void setStr23(String str23) {
+        this.str23 = str23;
+    }
+
+    public Double getNum1() {
+        return num1;
+    }
+
+    public void setNum1(Double num1) {
+        this.num1 = num1;
+    }
+
+    public Double getNum2() {
+        return num2;
+    }
+
+    public void setNum2(Double num2) {
+        this.num2 = num2;
+    }
+
+    public Double getNum3() {
+        return num3;
+    }
+
+    public void setNum3(Double num3) {
+        this.num3 = num3;
+    }
+
+    public Double getNum4() {
+        return num4;
+    }
+
+    public void setNum4(Double num4) {
+        this.num4 = num4;
+    }
+
+    public Double getNum5() {
+        return num5;
+    }
+
+    public void setNum5(Double num5) {
+        this.num5 = num5;
+    }
+
+    public Double getNum6() {
+        return num6;
+    }
+
+    public void setNum6(Double num6) {
+        this.num6 = num6;
+    }
+
+    public Date getDate1() {
+        return date1;
+    }
+
+    public String getDate1$(){
+        if (Cools.isEmpty(this.date1)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.date1);
+    }
+
+    public void setDate1(Date date1) {
+        this.date1 = date1;
+    }
+
+    public Long getAppeUser() {
+        return appeUser;
+    }
+
+    public String getAppeUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.appeUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setAppeUser(Long appeUser) {
+        this.appeUser = appeUser;
+    }
+
+    public Date getAppeTime() {
+        return appeTime;
+    }
+
+    public String getAppeTime$(){
+        if (Cools.isEmpty(this.appeTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.appeTime);
+    }
+
+    public void setAppeTime(Date appeTime) {
+        this.appeTime = appeTime;
+    }
+
+    public Long getModiUser() {
+        return modiUser;
+    }
+
+    public String getModiUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.modiUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setModiUser(Long modiUser) {
+        this.modiUser = modiUser;
+    }
+
+    public Date getModiTime() {
+        return modiTime;
+    }
+
+    public String getModiTime$(){
+        if (Cools.isEmpty(this.modiTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.modiTime);
+    }
+
+    public void setModiTime(Date modiTime) {
+        this.modiTime = modiTime;
+    }
+
+    public Short getStatus() {
+        return status;
+    }
+
+    public void setStatus(Short status) {
+        this.status = status;
+    }
+
+
+}
diff --git a/src/main/java/com/zy/asrs/entity/RowLastno.java b/src/main/java/com/zy/asrs/entity/RowLastno.java
new file mode 100644
index 0000000..07107cd
--- /dev/null
+++ b/src/main/java/com/zy/asrs/entity/RowLastno.java
@@ -0,0 +1,262 @@
+package com.zy.asrs.entity;
+
+import com.baomidou.mybatisplus.annotations.TableField;
+import com.baomidou.mybatisplus.annotations.TableId;
+import com.baomidou.mybatisplus.annotations.TableName;
+import com.baomidou.mybatisplus.enums.IdType;
+import com.core.common.Cools;
+import com.core.common.SpringUtils;
+import com.zy.system.entity.User;
+import com.zy.system.service.UserService;
+import io.swagger.annotations.ApiModelProperty;
+
+import java.io.Serializable;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+
+@TableName("asr_row_lastno")
+public class RowLastno implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 绫诲埆
+     */
+    @ApiModelProperty(value= "绫诲埆")
+    @TableId(value = "whs_type", type = IdType.INPUT)
+    @TableField("whs_type")
+    private Integer whsType;
+
+    /**
+     * 褰撳墠宸ヤ綔鍙�
+     */
+    @ApiModelProperty(value= "褰撳墠宸ヤ綔鍙�")
+    @TableField("wrk_mk")
+    private String wrkMk;
+
+    /**
+     * 褰撳墠鎺掑彿
+     */
+    @ApiModelProperty(value= "褰撳墠鎺掑彿")
+    @TableField("current_row")
+    private Integer currentRow;
+
+    /**
+     * 璧峰鎺掑彿
+     */
+    @ApiModelProperty(value= "璧峰鎺掑彿")
+    @TableField("s_row")
+    private Integer sRow;
+
+    /**
+     * 缁堟鎺掑彿
+     */
+    @ApiModelProperty(value= "缁堟鎺掑彿")
+    @TableField("e_row")
+    private Integer eRow;
+
+    /**
+     * 鍫嗗灈鏈烘暟閲�
+     */
+    @ApiModelProperty(value= "鍫嗗灈鏈烘暟閲�")
+    @TableField("crn_qty")
+    private Integer crnQty;
+
+    /**
+     * 澶囨敞
+     */
+    @ApiModelProperty(value= "澶囨敞")
+    private String memo;
+
+    /**
+     * 淇敼浜哄憳
+     */
+    @ApiModelProperty(value= "淇敼浜哄憳")
+    @TableField("modi_user")
+    private Long modiUser;
+
+    /**
+     * 淇敼鏃堕棿
+     */
+    @ApiModelProperty(value= "淇敼鏃堕棿")
+    @TableField("modi_time")
+    private Date modiTime;
+
+    /**
+     * 鍒涘缓鑰�
+     */
+    @ApiModelProperty(value= "鍒涘缓鑰�")
+    @TableField("appe_user")
+    private Long appeUser;
+
+    /**
+     * 娣诲姞鏃堕棿
+     */
+    @ApiModelProperty(value= "娣诲姞鏃堕棿")
+    @TableField("appe_time")
+    private Date appeTime;
+
+    @ApiModelProperty(value= "")
+    @TableField("limint_loc")
+    private Integer limintLoc;
+
+    public RowLastno() {}
+
+    public RowLastno(String wrkMk,Integer currentRow,Integer sRow,Integer eRow,Integer crnQty,String memo,Long modiUser,Date modiTime,Long appeUser,Date appeTime,Integer limintLoc) {
+        this.wrkMk = wrkMk;
+        this.currentRow = currentRow;
+        this.sRow = sRow;
+        this.eRow = eRow;
+        this.crnQty = crnQty;
+        this.memo = memo;
+        this.modiUser = modiUser;
+        this.modiTime = modiTime;
+        this.appeUser = appeUser;
+        this.appeTime = appeTime;
+        this.limintLoc = limintLoc;
+    }
+
+//    RowLastno rowLastno = new RowLastno(
+//            null,    // 褰撳墠宸ヤ綔鍙穂闈炵┖]
+//            null,    // 褰撳墠鎺掑彿
+//            null,    // 璧峰鎺掑彿
+//            null,    // 缁堟鎺掑彿
+//            null,    // 鍫嗗灈鏈烘暟閲�
+//            null,    // 澶囨敞
+//            null,    // 淇敼浜哄憳
+//            null,    // 淇敼鏃堕棿
+//            null,    // 鍒涘缓鑰�
+//            null,    // 娣诲姞鏃堕棿
+//            null    // 
+//    );
+
+    public Integer getWhsType() {
+        return whsType;
+    }
+
+    public void setWhsType(Integer whsType) {
+        this.whsType = whsType;
+    }
+
+    public String getWrkMk() {
+        return wrkMk;
+    }
+
+    public void setWrkMk(String wrkMk) {
+        this.wrkMk = wrkMk;
+    }
+
+    public Integer getCurrentRow() {
+        return currentRow;
+    }
+
+    public void setCurrentRow(Integer currentRow) {
+        this.currentRow = currentRow;
+    }
+
+    public Integer getsRow() {
+        return sRow;
+    }
+
+    public void setsRow(Integer sRow) {
+        this.sRow = sRow;
+    }
+
+    public Integer geteRow() {
+        return eRow;
+    }
+
+    public void seteRow(Integer eRow) {
+        this.eRow = eRow;
+    }
+
+    public Integer getCrnQty() {
+        return crnQty;
+    }
+
+    public void setCrnQty(Integer crnQty) {
+        this.crnQty = crnQty;
+    }
+
+    public String getMemo() {
+        return memo;
+    }
+
+    public void setMemo(String memo) {
+        this.memo = memo;
+    }
+
+    public Long getModiUser() {
+        return modiUser;
+    }
+
+    public String getModiUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.modiUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setModiUser(Long modiUser) {
+        this.modiUser = modiUser;
+    }
+
+    public Date getModiTime() {
+        return modiTime;
+    }
+
+    public String getModiTime$(){
+        if (Cools.isEmpty(this.modiTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.modiTime);
+    }
+
+    public void setModiTime(Date modiTime) {
+        this.modiTime = modiTime;
+    }
+
+    public Long getAppeUser() {
+        return appeUser;
+    }
+
+    public String getAppeUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.appeUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setAppeUser(Long appeUser) {
+        this.appeUser = appeUser;
+    }
+
+    public Date getAppeTime() {
+        return appeTime;
+    }
+
+    public String getAppeTime$(){
+        if (Cools.isEmpty(this.appeTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.appeTime);
+    }
+
+    public void setAppeTime(Date appeTime) {
+        this.appeTime = appeTime;
+    }
+
+    public Integer getLimintLoc() {
+        return limintLoc;
+    }
+
+    public void setLimintLoc(Integer limintLoc) {
+        this.limintLoc = limintLoc;
+    }
+
+
+}
diff --git a/src/main/java/com/zy/asrs/entity/StaDesc.java b/src/main/java/com/zy/asrs/entity/StaDesc.java
new file mode 100644
index 0000000..9c61158
--- /dev/null
+++ b/src/main/java/com/zy/asrs/entity/StaDesc.java
@@ -0,0 +1,291 @@
+package com.zy.asrs.entity;
+
+import com.baomidou.mybatisplus.annotations.TableField;
+import com.baomidou.mybatisplus.annotations.TableId;
+import com.baomidou.mybatisplus.annotations.TableName;
+import com.baomidou.mybatisplus.enums.IdType;
+import com.core.common.Cools;
+import com.core.common.SpringUtils;
+import com.zy.asrs.service.BasCrnpService;
+import com.zy.asrs.service.BasDevpService;
+import com.zy.system.entity.User;
+import com.zy.system.service.UserService;
+import io.swagger.annotations.ApiModelProperty;
+
+import java.io.Serializable;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+
+@TableName("asr_sta_desc")
+public class StaDesc implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 璺緞ID
+     */
+    @ApiModelProperty(value= "璺緞ID")
+    @TableId(value = "type_id", type = IdType.AUTO)
+    @TableField("type_id")
+    private Long typeId;
+
+    /**
+     * 鍏ュ嚭搴撶被鍨�
+     */
+    @ApiModelProperty(value= "鍏ュ嚭搴撶被鍨�")
+    @TableId(value = "type_no", type = IdType.INPUT)
+    @TableField("type_no")
+    private Integer typeNo;
+
+    /**
+     * 浣滀笟绫诲瀷
+     */
+    @ApiModelProperty(value= "浣滀笟绫诲瀷")
+    @TableField("type_desc")
+    private String typeDesc;
+
+    /**
+     * 浣滀笟绔欑偣
+     */
+    @ApiModelProperty(value= "浣滀笟绔欑偣")
+    @TableId(value = "stn_no", type = IdType.INPUT)
+    @TableField("stn_no")
+    private Integer stnNo;
+
+    /**
+     * 绔欑偣鍚嶇О
+     */
+    @ApiModelProperty(value= "绔欑偣鍚嶇О")
+    @TableField("stn_desc")
+    private String stnDesc;
+
+    /**
+     * 鍫嗗灈鏈哄彿
+     */
+    @ApiModelProperty(value= "鍫嗗灈鏈哄彿")
+    @TableId(value = "crn_no", type = IdType.INPUT)
+    @TableField("crn_no")
+    private Integer crnNo;
+
+    /**
+     * 鍫嗗灈鏈虹珯鐐�
+     */
+    @ApiModelProperty(value= "鍫嗗灈鏈虹珯鐐�")
+    @TableField("crn_stn")
+    private Integer crnStn;
+
+    /**
+     * 澶囨敞
+     */
+    @ApiModelProperty(value= "澶囨敞")
+    private String memo;
+
+    /**
+     * 淇敼浜哄憳
+     */
+    @ApiModelProperty(value= "淇敼浜哄憳")
+    @TableField("modi_user")
+    private Long modiUser;
+
+    /**
+     * 淇敼鏃堕棿
+     */
+    @ApiModelProperty(value= "淇敼鏃堕棿")
+    @TableField("modi_time")
+    private Date modiTime;
+
+    /**
+     * 鍒涘缓鑰�
+     */
+    @ApiModelProperty(value= "鍒涘缓鑰�")
+    @TableField("appe_user")
+    private Long appeUser;
+
+    /**
+     * 娣诲姞鏃堕棿
+     */
+    @ApiModelProperty(value= "娣诲姞鏃堕棿")
+    @TableField("appe_time")
+    private Date appeTime;
+
+    public StaDesc() {}
+
+    public StaDesc(String typeDesc,String stnDesc,Integer crnStn,String memo,Long modiUser,Date modiTime,Long appeUser,Date appeTime) {
+        this.typeDesc = typeDesc;
+        this.stnDesc = stnDesc;
+        this.crnStn = crnStn;
+        this.memo = memo;
+        this.modiUser = modiUser;
+        this.modiTime = modiTime;
+        this.appeUser = appeUser;
+        this.appeTime = appeTime;
+    }
+
+//    StaDesc staDesc = new StaDesc(
+//            null,    // 浣滀笟绫诲瀷
+//            null,    // 绔欑偣鍚嶇О
+//            null,    // 鍫嗗灈鏈虹珯鐐�
+//            null,    // 澶囨敞
+//            null,    // 淇敼浜哄憳
+//            null,    // 淇敼鏃堕棿
+//            null,    // 鍒涘缓鑰�
+//            null    // 娣诲姞鏃堕棿
+//    );
+
+    public Long getTypeId() {
+        return typeId;
+    }
+
+    public void setTypeId(Long typeId) {
+        this.typeId = typeId;
+    }
+
+    public Integer getTypeNo() {
+        return typeNo;
+    }
+
+    public void setTypeNo(Integer typeNo) {
+        this.typeNo = typeNo;
+    }
+
+    public String getTypeDesc() {
+        return typeDesc;
+    }
+
+    public void setTypeDesc(String typeDesc) {
+        this.typeDesc = typeDesc;
+    }
+
+    public Integer getStnNo() {
+        return stnNo;
+    }
+
+    public String getStnNo$(){
+        BasDevpService service = SpringUtils.getBean(BasDevpService.class);
+        BasDevp basDevp = service.selectById(this.stnNo);
+        if (!Cools.isEmpty(basDevp)){
+            return String.valueOf(basDevp.getDevNo());
+        }
+        return null;
+    }
+
+    public void setStnNo(Integer stnNo) {
+        this.stnNo = stnNo;
+    }
+
+    public String getStnDesc() {
+        return stnDesc;
+    }
+
+    public void setStnDesc(String stnDesc) {
+        this.stnDesc = stnDesc;
+    }
+
+    public Integer getCrnNo() {
+        return crnNo;
+    }
+
+    public String getCrnNo$(){
+        BasCrnpService service = SpringUtils.getBean(BasCrnpService.class);
+        BasCrnp basCrnp = service.selectById(this.crnNo);
+        if (!Cools.isEmpty(basCrnp)){
+            return String.valueOf(basCrnp.getCrnNo());
+        }
+        return null;
+    }
+
+    public void setCrnNo(Integer crnNo) {
+        this.crnNo = crnNo;
+    }
+
+    public Integer getCrnStn() {
+        return crnStn;
+    }
+
+    public String getCrnStn$(){
+        BasDevpService service = SpringUtils.getBean(BasDevpService.class);
+        BasDevp basDevp = service.selectById(this.crnStn);
+        if (!Cools.isEmpty(basDevp)){
+            return String.valueOf(basDevp.getDevNo());
+        }
+        return null;
+    }
+
+    public void setCrnStn(Integer crnStn) {
+        this.crnStn = crnStn;
+    }
+
+    public String getMemo() {
+        return memo;
+    }
+
+    public void setMemo(String memo) {
+        this.memo = memo;
+    }
+
+    public Long getModiUser() {
+        return modiUser;
+    }
+
+    public String getModiUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.modiUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setModiUser(Long modiUser) {
+        this.modiUser = modiUser;
+    }
+
+    public Date getModiTime() {
+        return modiTime;
+    }
+
+    public String getModiTime$(){
+        if (Cools.isEmpty(this.modiTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.modiTime);
+    }
+
+    public void setModiTime(Date modiTime) {
+        this.modiTime = modiTime;
+    }
+
+    public Long getAppeUser() {
+        return appeUser;
+    }
+
+    public String getAppeUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.appeUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setAppeUser(Long appeUser) {
+        this.appeUser = appeUser;
+    }
+
+    public Date getAppeTime() {
+        return appeTime;
+    }
+
+    public String getAppeTime$(){
+        if (Cools.isEmpty(this.appeTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.appeTime);
+    }
+
+    public void setAppeTime(Date appeTime) {
+        this.appeTime = appeTime;
+    }
+
+
+}
diff --git a/src/main/java/com/zy/asrs/entity/WaitPakin.java b/src/main/java/com/zy/asrs/entity/WaitPakin.java
new file mode 100644
index 0000000..05ed026
--- /dev/null
+++ b/src/main/java/com/zy/asrs/entity/WaitPakin.java
@@ -0,0 +1,258 @@
+package com.zy.asrs.entity;
+
+import com.baomidou.mybatisplus.annotations.TableField;
+import com.baomidou.mybatisplus.annotations.TableId;
+import com.baomidou.mybatisplus.annotations.TableName;
+import com.baomidou.mybatisplus.enums.IdType;
+import com.core.common.Cools;
+import com.core.common.SpringUtils;
+import com.zy.system.entity.User;
+import com.zy.system.service.UserService;
+import io.swagger.annotations.ApiModelProperty;
+
+import java.io.Serializable;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+
+@TableName("cust_wait_pakin")
+public class WaitPakin implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 缂栧彿
+     */
+    @ApiModelProperty(value= "缂栧彿")
+    @TableId(value = "id", type = IdType.AUTO)
+    private Long id;
+
+    /**
+     * 鎵樼洏鐮�
+     */
+    @ApiModelProperty(value= "鎵樼洏鐮�")
+    private String barcode;
+
+    /**
+     * 鐗╂枡缂栫爜
+     */
+    @ApiModelProperty(value= "鐗╂枡缂栫爜")
+    private String matnr;
+
+    /**
+     * 鐗╂枡鎻忚堪
+     */
+    @ApiModelProperty(value= "鐗╂枡鎻忚堪")
+    private String maktx;
+
+    /**
+     * 鏁伴噺
+     */
+    @ApiModelProperty(value= "鏁伴噺")
+    private Double anfme;
+
+    /**
+     * 鍗曚綅
+     */
+    @ApiModelProperty(value= "鍗曚綅")
+    private String unit;
+
+    /**
+     * 鐘舵��
+     */
+    @ApiModelProperty(value= "鐘舵��")
+    private String status;
+
+    /**
+     * 澶囨敞
+     */
+    @ApiModelProperty(value= "澶囨敞")
+    private String memo;
+
+    /**
+     * 淇敼鏃堕棿
+     */
+    @ApiModelProperty(value= "淇敼鏃堕棿")
+    @TableField("modi_time")
+    private Date modiTime;
+
+    /**
+     * 淇敼浜哄憳
+     */
+    @ApiModelProperty(value= "淇敼浜哄憳")
+    @TableField("modi_user")
+    private Long modiUser;
+
+    /**
+     * 娣诲姞鏃堕棿
+     */
+    @ApiModelProperty(value= "娣诲姞鏃堕棿")
+    @TableField("appe_time")
+    private Date appeTime;
+
+    /**
+     * 鍒涘缓鑰�
+     */
+    @ApiModelProperty(value= "鍒涘缓鑰�")
+    @TableField("appe_user")
+    private Long appeUser;
+
+    public WaitPakin() {}
+
+    public WaitPakin(String barcode, String matnr, String maktx, Double anfme, String unit, String status, String memo, Date modiTime, Long modiUser, Date appeTime, Long appeUser) {
+        this.barcode = barcode;
+        this.matnr = matnr;
+        this.maktx = maktx;
+        this.anfme = anfme;
+        this.unit = unit;
+        this.status = status;
+        this.memo = memo;
+        this.modiTime = modiTime;
+        this.modiUser = modiUser;
+        this.appeTime = appeTime;
+        this.appeUser = appeUser;
+    }
+
+//    WaitPakin waitPakin = new WaitPakin(
+//            null,    // 鎵樼洏鐮�
+//            null,    // 鐗╂枡缂栫爜
+//            null,    // 鐗╂枡鎻忚堪
+//            null,    // 鏁伴噺
+//            null,    // 鍗曚綅
+//            null,    // 鐘舵��
+//            null,    // 澶囨敞
+//            null,    // 淇敼鏃堕棿
+//            null,    // 淇敼浜哄憳
+//            null,    // 娣诲姞鏃堕棿
+//            null    // 鍒涘缓鑰�
+//    );
+
+    public Long getId() {
+        return id;
+    }
+
+    public void setId(Long id) {
+        this.id = id;
+    }
+
+    public String getBarcode() {
+        return barcode;
+    }
+
+    public void setBarcode(String barcode) {
+        this.barcode = barcode;
+    }
+
+    public String getMatnr() {
+        return matnr;
+    }
+
+    public void setMatnr(String matnr) {
+        this.matnr = matnr;
+    }
+
+    public String getMaktx() {
+        return maktx;
+    }
+
+    public void setMaktx(String maktx) {
+        this.maktx = maktx;
+    }
+
+    public Double getAnfme() {
+        return anfme;
+    }
+
+    public void setAnfme(Double anfme) {
+        this.anfme = anfme;
+    }
+
+    public String getUnit() {
+        return unit;
+    }
+
+    public void setUnit(String unit) {
+        this.unit = unit;
+    }
+
+    public String getStatus() {
+        return status;
+    }
+
+    public void setStatus(String status) {
+        this.status = status;
+    }
+
+    public String getMemo() {
+        return memo;
+    }
+
+    public void setMemo(String memo) {
+        this.memo = memo;
+    }
+
+    public Date getModiTime() {
+        return modiTime;
+    }
+
+    public String getModiTime$(){
+        if (Cools.isEmpty(this.modiTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.modiTime);
+    }
+
+    public void setModiTime(Date modiTime) {
+        this.modiTime = modiTime;
+    }
+
+    public Long getModiUser() {
+        return modiUser;
+    }
+
+    public String getModiUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.modiUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setModiUser(Long modiUser) {
+        this.modiUser = modiUser;
+    }
+
+    public Date getAppeTime() {
+        return appeTime;
+    }
+
+    public String getAppeTime$(){
+        if (Cools.isEmpty(this.appeTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.appeTime);
+    }
+
+    public void setAppeTime(Date appeTime) {
+        this.appeTime = appeTime;
+    }
+
+    public Long getAppeUser() {
+        return appeUser;
+    }
+
+    public String getAppeUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.appeUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setAppeUser(Long appeUser) {
+        this.appeUser = appeUser;
+    }
+
+
+}
diff --git a/src/main/java/com/zy/asrs/entity/WrkDetl.java b/src/main/java/com/zy/asrs/entity/WrkDetl.java
new file mode 100644
index 0000000..9a72f82
--- /dev/null
+++ b/src/main/java/com/zy/asrs/entity/WrkDetl.java
@@ -0,0 +1,182 @@
+package com.zy.asrs.entity;
+
+import com.baomidou.mybatisplus.annotations.TableField;
+import com.baomidou.mybatisplus.annotations.TableName;
+import com.core.common.Cools;
+import com.core.common.SpringUtils;
+import com.zy.system.entity.User;
+import com.zy.system.service.UserService;
+import io.swagger.annotations.ApiModelProperty;
+import lombok.Data;
+
+import java.io.Serializable;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+
+@Data
+@TableName("asr_wrk_detl")
+public class WrkDetl implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 宸ヤ綔鍙�
+     */
+    @ApiModelProperty(value= "宸ヤ綔鍙�")
+    @TableField("wrk_no")
+    private Integer wrkNo;
+
+    /**
+     * 宸ヤ綔鏃堕棿
+     */
+    @ApiModelProperty(value= "宸ヤ綔鏃堕棿")
+    @TableField("io_time")
+    private Date ioTime;
+
+    /**
+     * 鐗╂枡
+     */
+    @ApiModelProperty(value= "鐗╂枡")
+    private String matnr;
+
+    /**
+     * 鐗╂枡鎻忚堪
+     */
+    @ApiModelProperty(value= "鐗╂枡鎻忚堪")
+    private String maktx;
+
+
+    /**
+     * 浠撳簱鍙�
+     */
+    @ApiModelProperty(value= "瑙勬牸")
+    private String lgnum;
+
+    /**
+     * 浠撳簱鍙�
+     */
+    @ApiModelProperty(value= "鐗╂枡绫诲埆")
+    private String type;
+
+    /**
+     * 浠撳簱鍙�
+     */
+    @ApiModelProperty(value= "棰滆壊")
+    private String color;
+
+    /**
+     * 浠撳簱鍙�
+     */
+    @ApiModelProperty(value= "渚涘簲鍟�")
+    private String supplier;
+
+    /**
+     * 浠撳簱鍙�
+     */
+    @ApiModelProperty(value= "浠撳簱")
+    private String warehouse;
+
+    /**
+     * 浠撳簱鍙�
+     */
+    @ApiModelProperty(value= "鍝佺墝")
+    private String brand;
+
+    /**
+     * 鏁伴噺
+     */
+    @ApiModelProperty(value= "鏁伴噺")
+    private Double anfme;
+
+    /**
+     * 鍗曚綅
+     */
+    @ApiModelProperty(value= "鍗曚綅")
+    private String altme;
+
+    /**
+     * 鎵樼洏鏉$爜
+     */
+    @ApiModelProperty(value= "鎵樼洏鏉$爜")
+    private String zpallet;
+
+    /**
+     * 鐢ㄦ埛ID
+     */
+    @ApiModelProperty(value= "鐢ㄦ埛ID")
+    private String bname;
+
+    /**
+     * 澶囨敞
+     */
+    @ApiModelProperty(value= "澶囨敞")
+    private String memo;
+
+    /**
+     * 淇敼浜哄憳
+     */
+    @ApiModelProperty(value= "淇敼浜哄憳")
+    @TableField("modi_user")
+    private Long modiUser;
+
+    /**
+     * 淇敼鏃堕棿
+     */
+    @ApiModelProperty(value= "淇敼鏃堕棿")
+    @TableField("modi_time")
+    private Date modiTime;
+
+    /**
+     * 鍒涘缓鑰�
+     */
+    @ApiModelProperty(value= "鍒涘缓鑰�")
+    @TableField("appe_user")
+    private Long appeUser;
+
+    /**
+     * 娣诲姞鏃堕棿
+     */
+    @ApiModelProperty(value= "娣诲姞鏃堕棿")
+    @TableField("appe_time")
+    private Date appeTime;
+
+    public String getIoTime$(){
+        if (Cools.isEmpty(this.ioTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.ioTime);
+    }
+
+    public String getModiUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.modiUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public String getModiTime$(){
+        if (Cools.isEmpty(this.modiTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.modiTime);
+    }
+
+    public String getAppeUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.appeUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public String getAppeTime$(){
+        if (Cools.isEmpty(this.appeTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.appeTime);
+    }
+
+}
diff --git a/src/main/java/com/zy/asrs/entity/WrkLastno.java b/src/main/java/com/zy/asrs/entity/WrkLastno.java
new file mode 100644
index 0000000..514079f
--- /dev/null
+++ b/src/main/java/com/zy/asrs/entity/WrkLastno.java
@@ -0,0 +1,215 @@
+package com.zy.asrs.entity;
+
+import com.baomidou.mybatisplus.annotations.TableField;
+import com.baomidou.mybatisplus.annotations.TableId;
+import com.baomidou.mybatisplus.annotations.TableName;
+import com.baomidou.mybatisplus.enums.IdType;
+import com.core.common.Cools;
+import com.core.common.SpringUtils;
+import com.zy.system.entity.User;
+import com.zy.system.service.UserService;
+import io.swagger.annotations.ApiModelProperty;
+
+import java.io.Serializable;
+import java.text.SimpleDateFormat;
+import java.util.Date;
+
+@TableName("asr_wrk_lastno")
+public class WrkLastno implements Serializable {
+
+    private static final long serialVersionUID = 1L;
+
+    /**
+     * 绫诲瀷
+     */
+    @ApiModelProperty(value= "绫诲瀷")
+    @TableId(value = "wrk_mk", type = IdType.INPUT)
+    @TableField("wrk_mk")
+    private Integer wrkMk;
+
+    /**
+     * 褰撳墠ID
+     */
+    @ApiModelProperty(value= "褰撳墠ID")
+    @TableField("wrk_no")
+    private Integer wrkNo;
+
+    /**
+     * 淇敼浜哄憳
+     */
+    @ApiModelProperty(value= "淇敼浜哄憳")
+    @TableField("modi_user")
+    private Long modiUser;
+
+    /**
+     * 淇敼鏃堕棿
+     */
+    @ApiModelProperty(value= "淇敼鏃堕棿")
+    @TableField("modi_time")
+    private Date modiTime;
+
+    /**
+     * 鍒涘缓鑰�
+     */
+    @ApiModelProperty(value= "鍒涘缓鑰�")
+    @TableField("appe_user")
+    private Long appeUser;
+
+    /**
+     * 娣诲姞鏃堕棿
+     */
+    @ApiModelProperty(value= "娣诲姞鏃堕棿")
+    @TableField("appe_time")
+    private Date appeTime;
+
+    /**
+     * 璧峰ID
+     */
+    @ApiModelProperty(value= "璧峰ID")
+    @TableField("s_no")
+    private Integer sNo;
+
+    /**
+     * 缁堟ID
+     */
+    @ApiModelProperty(value= "缁堟ID")
+    @TableField("e_no")
+    private Integer eNo;
+
+    /**
+     * 澶囨敞
+     */
+    @ApiModelProperty(value= "澶囨敞")
+    @TableField("memo_m")
+    private String memoM;
+
+    public WrkLastno() {}
+
+    public WrkLastno(Integer wrkNo,Long modiUser,Date modiTime,Long appeUser,Date appeTime,Integer sNo,Integer eNo,String memoM) {
+        this.wrkNo = wrkNo;
+        this.modiUser = modiUser;
+        this.modiTime = modiTime;
+        this.appeUser = appeUser;
+        this.appeTime = appeTime;
+        this.sNo = sNo;
+        this.eNo = eNo;
+        this.memoM = memoM;
+    }
+
+//    WrkLastno wrkLastno = new WrkLastno(
+//            null,    // 褰撳墠ID[闈炵┖]
+//            null,    // 淇敼浜哄憳
+//            null,    // 淇敼鏃堕棿
+//            null,    // 鍒涘缓鑰�
+//            null,    // 娣诲姞鏃堕棿
+//            null,    // 璧峰ID[闈炵┖]
+//            null,    // 缁堟ID[闈炵┖]
+//            null    // 澶囨敞
+//    );
+
+    public Integer getWrkMk() {
+        return wrkMk;
+    }
+
+    public void setWrkMk(Integer wrkMk) {
+        this.wrkMk = wrkMk;
+    }
+
+    public Integer getWrkNo() {
+        return wrkNo;
+    }
+
+    public void setWrkNo(Integer wrkNo) {
+        this.wrkNo = wrkNo;
+    }
+
+    public Long getModiUser() {
+        return modiUser;
+    }
+
+    public String getModiUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.modiUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setModiUser(Long modiUser) {
+        this.modiUser = modiUser;
+    }
+
+    public Date getModiTime() {
+        return modiTime;
+    }
+
+    public String getModiTime$(){
+        if (Cools.isEmpty(this.modiTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.modiTime);
+    }
+
+    public void setModiTime(Date modiTime) {
+        this.modiTime = modiTime;
+    }
+
+    public Long getAppeUser() {
+        return appeUser;
+    }
+
+    public String getAppeUser$(){
+        UserService service = SpringUtils.getBean(UserService.class);
+        User user = service.selectById(this.appeUser);
+        if (!Cools.isEmpty(user)){
+            return String.valueOf(user.getUsername());
+        }
+        return null;
+    }
+
+    public void setAppeUser(Long appeUser) {
+        this.appeUser = appeUser;
+    }
+
+    public Date getAppeTime() {
+        return appeTime;
+    }
+
+    public String getAppeTime$(){
+        if (Cools.isEmpty(this.appeTime)){
+            return "";
+        }
+        return new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(this.appeTime);
+    }
+
+    public void setAppeTime(Date appeTime) {
+        this.appeTime = appeTime;
+    }
+
+    public Integer getSNo() {
+        return sNo;
+    }
+
+    public void setSNo(Integer sNo) {
+        this.sNo = sNo;
+    }
+
+    public Integer getENo() {
+        return eNo;
+    }
+
+    public void setENo(Integer eNo) {
+        this.eNo = eNo;
+    }
+
+    public String getMemoM() {
+        return memoM;
+    }
+
+    public void setMemoM(String memoM) {
+        this.memoM = memoM;
+    }
+
+
+}
diff --git a/src/main/java/com/zy/asrs/mapper/LocDetlMapper.java b/src/main/java/com/zy/asrs/mapper/LocDetlMapper.java
new file mode 100644
index 0000000..77a8a07
--- /dev/null
+++ b/src/main/java/com/zy/asrs/mapper/LocDetlMapper.java
@@ -0,0 +1,30 @@
+package com.zy.asrs.mapper;
+
+import com.baomidou.mybatisplus.mapper.BaseMapper;
+import com.zy.asrs.entity.LocDetl;
+import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Select;
+import org.apache.ibatis.annotations.Update;
+import org.springframework.stereotype.Repository;
+
+import java.util.List;
+import java.util.Map;
+
+@Mapper
+@Repository
+public interface LocDetlMapper extends BaseMapper<LocDetl> {
+
+    List<LocDetl> getStockOutPage(Map<String, Object> map);
+
+    Integer getStockOutPageCount(Map<String, Object> map);
+
+    @Update("update asr_loc_detl set anfme=#{anfme}, modi_time = getDate() where loc_no = #{locNo} and matnr = #{matnr}")
+    int updateAnfme(Double anfme, String locNo, String matnr);
+
+    @Update("update asr_loc_detl set loc_no = #{newLocNo}, modi_time=getDate() where loc_no = #{oldLocNo}")
+    int updateLocNo(String newLocNo, String oldLocNo);
+
+    @Select("SELECT ld.loc_no FROM asr_loc_detl ld LEFT JOIN asr_loc_mast lm ON ld.loc_no = lm.loc_no WHERE (1 = 1 AND ld.matnr = #{matnr} AND lm.loc_sts = 'F' AND DateDiff(dd, lm.modi_time, getdate()) = 0) ORDER BY lm.modi_time ASC")
+    List<String> selectSameDetlToday(String matnr);
+
+}
diff --git a/src/main/java/com/zy/asrs/mapper/MatCodeMapper.java b/src/main/java/com/zy/asrs/mapper/MatCodeMapper.java
new file mode 100644
index 0000000..a09bd26
--- /dev/null
+++ b/src/main/java/com/zy/asrs/mapper/MatCodeMapper.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.mapper;
+
+import com.baomidou.mybatisplus.mapper.BaseMapper;
+import com.zy.asrs.entity.MatCode;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+@Mapper
+@Repository
+public interface MatCodeMapper extends BaseMapper<MatCode> {
+
+}
diff --git a/src/main/java/com/zy/asrs/mapper/RowLastnoMapper.java b/src/main/java/com/zy/asrs/mapper/RowLastnoMapper.java
new file mode 100644
index 0000000..bfb9079
--- /dev/null
+++ b/src/main/java/com/zy/asrs/mapper/RowLastnoMapper.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.mapper;
+
+import com.baomidou.mybatisplus.mapper.BaseMapper;
+import com.zy.asrs.entity.RowLastno;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+@Mapper
+@Repository
+public interface RowLastnoMapper extends BaseMapper<RowLastno> {
+
+}
diff --git a/src/main/java/com/zy/asrs/mapper/StaDescMapper.java b/src/main/java/com/zy/asrs/mapper/StaDescMapper.java
new file mode 100644
index 0000000..1518045
--- /dev/null
+++ b/src/main/java/com/zy/asrs/mapper/StaDescMapper.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.mapper;
+
+import com.baomidou.mybatisplus.mapper.BaseMapper;
+import com.zy.asrs.entity.StaDesc;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+@Mapper
+@Repository
+public interface StaDescMapper extends BaseMapper<StaDesc> {
+
+}
diff --git a/src/main/java/com/zy/asrs/mapper/WaitPakinMapper.java b/src/main/java/com/zy/asrs/mapper/WaitPakinMapper.java
new file mode 100644
index 0000000..cbca94b
--- /dev/null
+++ b/src/main/java/com/zy/asrs/mapper/WaitPakinMapper.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.mapper;
+
+import com.baomidou.mybatisplus.mapper.BaseMapper;
+import com.zy.asrs.entity.WaitPakin;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+@Mapper
+@Repository
+public interface WaitPakinMapper extends BaseMapper<WaitPakin> {
+
+}
diff --git a/src/main/java/com/zy/asrs/mapper/WrkDetlMapper.java b/src/main/java/com/zy/asrs/mapper/WrkDetlMapper.java
new file mode 100644
index 0000000..6193859
--- /dev/null
+++ b/src/main/java/com/zy/asrs/mapper/WrkDetlMapper.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.mapper;
+
+import com.baomidou.mybatisplus.mapper.BaseMapper;
+import com.zy.asrs.entity.WrkDetl;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+@Mapper
+@Repository
+public interface WrkDetlMapper extends BaseMapper<WrkDetl> {
+
+}
diff --git a/src/main/java/com/zy/asrs/mapper/WrkLastnoMapper.java b/src/main/java/com/zy/asrs/mapper/WrkLastnoMapper.java
new file mode 100644
index 0000000..ebeb20f
--- /dev/null
+++ b/src/main/java/com/zy/asrs/mapper/WrkLastnoMapper.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.mapper;
+
+import com.baomidou.mybatisplus.mapper.BaseMapper;
+import com.zy.asrs.entity.WrkLastno;
+import org.apache.ibatis.annotations.Mapper;
+import org.springframework.stereotype.Repository;
+
+@Mapper
+@Repository
+public interface WrkLastnoMapper extends BaseMapper<WrkLastno> {
+
+}
diff --git a/src/main/java/com/zy/asrs/mapper/WrkMastMapper.java b/src/main/java/com/zy/asrs/mapper/WrkMastMapper.java
index dd349bd..c9154ef 100644
--- a/src/main/java/com/zy/asrs/mapper/WrkMastMapper.java
+++ b/src/main/java/com/zy/asrs/mapper/WrkMastMapper.java
@@ -3,6 +3,8 @@
 import com.baomidou.mybatisplus.mapper.BaseMapper;
 import com.zy.asrs.entity.WrkMast;
 import org.apache.ibatis.annotations.Mapper;
+import org.apache.ibatis.annotations.Param;
+import org.apache.ibatis.annotations.Select;
 import org.springframework.stereotype.Repository;
 
 import java.util.List;
@@ -16,4 +18,8 @@
 
     List<WrkMast> selectToBeHistoryData();
 
+    // wcs ---------------------------------------------
+    @Select("select top 1 wrk_no,loc_no,source_sta_no,sta_no,crn_no,wrk_sts,io_type from asr_wrk_mast where source_sta_no=#{sourceStaNo} and wrk_sts=2 and barcode=#{barcode} and (io_type=1 or io_type=10) order by io_pri desc,io_time,wrk_no ASC")
+    WrkMast selectPakInStep1(@Param("sourceStaNo")Integer sourceStaNo, @Param("barcode")String barcode);
+
 }
diff --git a/src/main/java/com/zy/asrs/service/LocDetlService.java b/src/main/java/com/zy/asrs/service/LocDetlService.java
new file mode 100644
index 0000000..94be71a
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/LocDetlService.java
@@ -0,0 +1,27 @@
+package com.zy.asrs.service;
+
+import com.baomidou.mybatisplus.plugins.Page;
+import com.baomidou.mybatisplus.service.IService;
+import com.zy.asrs.entity.LocDetl;
+
+import java.util.List;
+
+public interface LocDetlService extends IService<LocDetl> {
+
+    Page<LocDetl> getStockOut(Page<LocDetl> page);
+
+    /**
+     * 淇敼搴撳瓨鏄庣粏鏁伴噺锛屽鏋滄暟閲忎负0锛屽垯鍒犻櫎璁板綍
+     */
+    boolean updateAnfme(Double anfme, String locNo, String matnr);
+
+    boolean updateLocNo(String newLocNo, String oldLocNo);
+
+    /**
+     * 鑾峰彇褰撳ぉ鐩稿悓瑙勬牸璐х墿鐨勬繁搴撲綅鍙�
+     * @param matnr 鐗╂枡鍙�
+     * @return locNo 搴撲綅鍙�
+     */
+    List<String> getSameDetlToday(String matnr);
+
+}
diff --git a/src/main/java/com/zy/asrs/service/MatCodeService.java b/src/main/java/com/zy/asrs/service/MatCodeService.java
new file mode 100644
index 0000000..0f78ed5
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/MatCodeService.java
@@ -0,0 +1,8 @@
+package com.zy.asrs.service;
+
+import com.baomidou.mybatisplus.service.IService;
+import com.zy.asrs.entity.MatCode;
+
+public interface MatCodeService extends IService<MatCode> {
+
+}
diff --git a/src/main/java/com/zy/asrs/service/RowLastnoService.java b/src/main/java/com/zy/asrs/service/RowLastnoService.java
new file mode 100644
index 0000000..dca50fd
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/RowLastnoService.java
@@ -0,0 +1,8 @@
+package com.zy.asrs.service;
+
+import com.baomidou.mybatisplus.service.IService;
+import com.zy.asrs.entity.RowLastno;
+
+public interface RowLastnoService extends IService<RowLastno> {
+
+}
diff --git a/src/main/java/com/zy/asrs/service/StaDescService.java b/src/main/java/com/zy/asrs/service/StaDescService.java
new file mode 100644
index 0000000..b0ea462
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/StaDescService.java
@@ -0,0 +1,8 @@
+package com.zy.asrs.service;
+
+import com.baomidou.mybatisplus.service.IService;
+import com.zy.asrs.entity.StaDesc;
+
+public interface StaDescService extends IService<StaDesc> {
+
+}
diff --git a/src/main/java/com/zy/asrs/service/WrkDetlService.java b/src/main/java/com/zy/asrs/service/WrkDetlService.java
new file mode 100644
index 0000000..92b410d
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/WrkDetlService.java
@@ -0,0 +1,14 @@
+package com.zy.asrs.service;
+
+import com.baomidou.mybatisplus.service.IService;
+import com.zy.asrs.entity.WaitPakin;
+import com.zy.asrs.entity.WrkDetl;
+
+import java.util.List;
+
+public interface WrkDetlService extends IService<WrkDetl> {
+
+
+    void createWorkDetail(Integer workNo, List<WaitPakin> waitPakins, String barcode);
+
+}
diff --git a/src/main/java/com/zy/asrs/service/WrkLastnoService.java b/src/main/java/com/zy/asrs/service/WrkLastnoService.java
new file mode 100644
index 0000000..c3c2df8
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/WrkLastnoService.java
@@ -0,0 +1,8 @@
+package com.zy.asrs.service;
+
+import com.baomidou.mybatisplus.service.IService;
+import com.zy.asrs.entity.WrkLastno;
+
+public interface WrkLastnoService extends IService<WrkLastno> {
+
+}
diff --git a/src/main/java/com/zy/asrs/service/impl/CommonService.java b/src/main/java/com/zy/asrs/service/impl/CommonService.java
new file mode 100644
index 0000000..48ab58c
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/impl/CommonService.java
@@ -0,0 +1,227 @@
+package com.zy.asrs.service.impl;
+
+import com.baomidou.mybatisplus.mapper.EntityWrapper;
+import com.baomidou.mybatisplus.mapper.Wrapper;
+import com.core.common.Arith;
+import com.core.common.Cools;
+import com.core.exception.CoolException;
+import com.zy.asrs.entity.*;
+import com.zy.asrs.service.*;
+import com.zy.common.model.Shelves;
+import com.zy.common.model.StartupDto;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+/**
+ * 璐ф灦鏍稿績鍔熻兘
+ * Created by vincent on 2020/6/11
+ */
+@Service
+public class CommonService {
+
+    @Autowired
+    private WrkMastService wrkMastService;
+    @Autowired
+    private WrkLastnoService wrkLastnoService;
+    @Autowired
+    private RowLastnoService rowLastnoService;
+    @Autowired
+    private BasCrnpService basCrnpService;
+    @Autowired
+    private StaDescService staDescService;
+    @Autowired
+    private BasDevpService basDevpService;
+    @Autowired
+    private LocMastService locMastService;
+    @Autowired
+    private LocDetlService locDetlService;
+
+    /**
+     * 鐢熸垚宸ヤ綔鍙�
+     * @param wrkMk 0:鍏ュ嚭搴� ; 1:鍏朵粬
+     * @return workNo(宸ヤ綔鍙�)
+     */
+    public int getWorkNo(Integer wrkMk) {
+        WrkLastno wrkLastno = wrkLastnoService.selectById(wrkMk);
+        if (Cools.isEmpty(wrkLastno)) {
+            throw new CoolException("鏁版嵁寮傚父锛岃鑱旂郴绠$悊鍛�");
+        }
+        int workNo = 0;
+        // 鍏ュ嚭搴撶被鍨�
+        if (wrkLastno.getWrkMk() == 0) {
+            workNo = wrkLastno.getWrkNo();
+            int sNo = wrkLastno.getSNo();
+            int eNo = wrkLastno.getENo();
+
+            workNo = workNo>=eNo ? sNo : workNo+1;
+
+            while (true) {
+                WrkMast wrkMast = wrkMastService.selectById(workNo);
+                if (null != wrkMast) {
+                    workNo = workNo>=eNo ? sNo : workNo+1;
+                } else {
+                    break;
+                }
+            }
+            if (workNo > 0){
+                wrkLastno.setWrkNo(workNo);
+                wrkLastnoService.updateById(wrkLastno);
+            }
+        }
+        if (workNo == 0) {
+            throw new CoolException("鐢熸垚宸ヤ綔鍙峰け璐ワ紝璇疯仈绯荤鐞嗗憳");
+        } else {
+            if (wrkMastService.selectById(workNo)!=null) {
+                throw new CoolException("鐢熸垚宸ヤ綔鍙�" + workNo + "鍦ㄥ伐浣滄。涓凡瀛樺湪");
+            }
+        }
+        return workNo;
+    }
+
+    /**
+     * 妫�绱㈠簱浣嶅彿
+     * @param whsType 绫诲瀷 1:鍙屾繁寮忚揣鏋�
+     * @param staDescId 璺緞宸ヤ綔绫诲瀷
+     * @param sourceStaNo 婧愮珯
+     * @param matNos 鐗╂枡鍙烽泦鍚�
+     * @return locNo 妫�绱㈠埌鐨勫簱浣嶅彿
+     */
+    public StartupDto getLocNo(Integer whsType, Integer staDescId, Integer sourceStaNo, List<String> matNos) {
+        StartupDto startupDto = new StartupDto();
+        RowLastno rowLastno = rowLastnoService.selectById(whsType);
+        if (Cools.isEmpty(rowLastno)) {
+            throw new CoolException("鏁版嵁寮傚父锛岃鑱旂郴绠$悊鍛�");
+        }
+        if (rowLastno.getWhsType() == 1){
+            int curRow = rowLastno.getCurrentRow();
+            int sRow = rowLastno.getsRow();
+            int eRow = rowLastno.geteRow();
+            int crn_qty = rowLastno.getCrnQty();
+            int rowCount = eRow - sRow + 1;
+            // 鐩爣鍫嗗灈鏈哄彿
+            int crnNo = 0;
+            // 鐩爣搴撲綅
+            LocMast locMast = null;
+
+            // 鍚屼竴澶╁悓瑙勬牸璐х墿闈犺繎鎽嗘硶瑙勫垯
+            if (!Cools.isEmpty(matNos)) {
+                List<String> locNos = locDetlService.getSameDetlToday(matNos.get(0));
+                for (String locNo : locNos) {
+                    // 鑾峰彇鎺�
+                    int row = Integer.parseInt(locNo.substring(0, 2));
+                    // 鍒ゆ柇鏄惁涓烘繁搴撲綅
+                    double remainder = Arith.remainder(row, rowCount / crn_qty);
+                    int targetRow;
+                    if (remainder == 1) {
+                        // 寰楀埌褰撳墠搴撲綅鐨勫鍥村簱浣�
+                        targetRow =  row + 1;
+                    } else if (remainder == 0) {
+                        // 寰楀埌褰撳墠搴撲綅鐨勫唴鍥村簱浣�
+                        targetRow =  row - 1;
+                    } else {
+                        continue;
+                    }
+                    String targetLocNo = zerofill(String.valueOf(targetRow), 2)+locNo.substring(2);
+                    // 妫�娴嬬洰鏍囧簱浣嶆槸鍚︿负绌哄簱浣�
+                    LocMast targetLocMast = locMastService.selectById(targetLocNo);
+                    if (targetLocMast != null && targetLocMast.getLocSts().equals("O")) {
+                        locMast = targetLocMast;
+                        crnNo = locMast.getCrnNo();
+                        break;
+                    }
+                }
+            }
+
+            // 濡傛灉娌℃湁鐩歌繎鐗╂枡锛屽垯鎸夎鍒欒疆璇㈣揣鏋�
+            if (null == locMast) {
+                // 鑾峰彇鐩爣绔欐墍鍦ㄨ揣鏋舵帓鍙�
+                Shelves shelves = new Shelves(rowCount, crn_qty);
+                curRow = shelves.start(curRow);
+                if (curRow < 0) {
+                    throw new CoolException("妫�绱㈠簱浣嶅け璐ワ紝璇疯仈绯荤鐞嗗憳");
+                }
+                for (List<Integer> node : shelves.nodes){
+                    if (node.contains(curRow)) {
+                        crnNo = shelves.nodes.indexOf(node) + 1;
+                        break;
+                    }
+                }
+            }
+
+            basCrnpService.checkSiteStatus(crnNo);
+            // 鑾峰彇鐩爣绔�
+            Wrapper<StaDesc> wrapper = new EntityWrapper<StaDesc>()
+                    .eq("type_no", staDescId)
+                    .eq("stn_no", sourceStaNo)
+                    .eq("crn_no", crnNo);
+            StaDesc staDesc = staDescService.selectOne(wrapper);
+            if (Cools.isEmpty(staDesc)) {
+                throw new CoolException("鍏ュ簱璺緞涓嶅瓨鍦�");
+            }
+            BasDevp staNo = basDevpService.selectById(staDesc.getCrnStn());
+            int inQty = staNo.getInQty()==null?0:staNo.getInQty();
+            if (staNo.getInEnable().equals("Y") && staNo.getAutoing().equals("Y") && inQty<2) {
+                // 鏌ユ壘搴撲綅
+                if (locMast == null) {
+                    locMast = locMastService.queryFreeLocMast(curRow);
+                }
+                if (Cools.isEmpty(locMast)) {
+                    throw new CoolException("娌℃湁绌哄簱浣�");
+                }
+                String locNo = locMast.getLocNo();
+
+                // 鏇存柊搴撲綅鎺掑彿
+                rowLastno.setCurrentRow(curRow);
+                rowLastnoService.updateById(rowLastno);
+
+                // 杩斿洖dto
+                startupDto.setCrnNo(crnNo);
+                startupDto.setSourceStaNo(sourceStaNo);
+                startupDto.setStaNo(staNo.getDevNo());
+                startupDto.setLocNo(locNo);
+            } else {
+                throw new CoolException("鐩爣绔�"+staDesc.getCrnStn()+"涓嶅彲鐢�");
+            }
+        } else {
+            throw new CoolException(rowLastno.getWhsType()+"鍙峰簱浣嶆帓鍙峰垎閰嶈鍒欎笉鍙敤");
+        }
+        return startupDto;
+    }
+
+    public static void main(String[] args) {
+        System.out.println(Arith.remainder(1, 4));
+        System.out.println("0200201".substring(0, 2));
+        String locNo = "0800201";
+        int row = Integer.parseInt(locNo.substring(0, 2));
+        double remainder = Arith.remainder(row, 4);
+        int targetRow;
+        if (remainder == 1) {
+            // 寰楀埌褰撳墠搴撲綅鐨勫鍥村簱浣�
+            targetRow =  row + 1;
+        } else if (remainder == 0) {
+            // 寰楀埌褰撳墠搴撲綅鐨勫唴鍥村簱浣�
+            targetRow =  row - 1;
+        } else {
+            return;
+        }
+        String zerofill = zerofill(String.valueOf(targetRow), 2)+locNo.substring(2);
+        System.out.println(zerofill);
+    }
+
+    public static String zerofill(String msg, Integer count) {
+        if (msg.length() == count) {
+            return msg;
+        } else if (msg.length() > count) {
+            return msg.substring(0, 16);
+        } else {
+            StringBuilder msgBuilder = new StringBuilder(msg);
+            for(int i = 0; i < count - msg.length(); ++i) {
+                msgBuilder.insert(0, "0");
+            }
+            return msgBuilder.toString();
+        }
+    }
+
+}
\ No newline at end of file
diff --git a/src/main/java/com/zy/asrs/service/impl/LocDetlServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/LocDetlServiceImpl.java
new file mode 100644
index 0000000..ddb1d0a
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/impl/LocDetlServiceImpl.java
@@ -0,0 +1,43 @@
+package com.zy.asrs.service.impl;
+
+import com.baomidou.mybatisplus.mapper.EntityWrapper;
+import com.baomidou.mybatisplus.plugins.Page;
+import com.baomidou.mybatisplus.service.impl.ServiceImpl;
+import com.zy.asrs.entity.LocDetl;
+import com.zy.asrs.mapper.LocDetlMapper;
+import com.zy.asrs.service.LocDetlService;
+import org.springframework.stereotype.Service;
+
+import java.util.List;
+
+@Service("locDetlService")
+public class LocDetlServiceImpl extends ServiceImpl<LocDetlMapper, LocDetl> implements LocDetlService {
+
+    @Override
+    public Page<LocDetl> getStockOut(Page<LocDetl> page) {
+        page.setRecords(baseMapper.getStockOutPage(page.getCondition()));
+        page.setTotal(baseMapper.getStockOutPageCount(page.getCondition()));
+        return page;
+    }
+
+    @Override
+    public boolean updateAnfme(Double anfme, String locNo, String matnr) {
+        if (anfme <= 0) {
+            return delete(new EntityWrapper<LocDetl>().eq("loc_no", locNo).eq("matnr", matnr));
+        } else {
+            int res = baseMapper.updateAnfme(anfme, locNo, matnr);
+            return res > 0;
+        }
+    }
+
+    @Override
+    public boolean updateLocNo(String newLocNo, String oldLocNo) {
+        return baseMapper.updateLocNo(newLocNo, oldLocNo) > 0;
+    }
+
+    @Override
+    public List<String> getSameDetlToday(String matnr) {
+        return this.baseMapper.selectSameDetlToday(matnr);
+    }
+
+}
diff --git a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
index 8ccdcaa..8660126 100644
--- a/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
+++ b/src/main/java/com/zy/asrs/service/impl/MainServiceImpl.java
@@ -1,6 +1,16 @@
 package com.zy.asrs.service.impl;
 
+import com.baomidou.mybatisplus.mapper.EntityWrapper;
 import com.core.common.Cools;
+import com.core.exception.CoolException;
+import com.zy.asrs.entity.LocMast;
+import com.zy.asrs.entity.WaitPakin;
+import com.zy.asrs.entity.WrkMast;
+import com.zy.asrs.mapper.WaitPakinMapper;
+import com.zy.asrs.mapper.WrkMastMapper;
+import com.zy.asrs.service.LocMastService;
+import com.zy.asrs.service.WrkDetlService;
+import com.zy.common.model.StartupDto;
 import com.zy.core.cache.SlaveConnection;
 import com.zy.core.enums.SlaveType;
 import com.zy.core.model.DevpSlave;
@@ -8,21 +18,40 @@
 import com.zy.core.properties.SlaveProperties;
 import com.zy.core.thread.BarcodeThread;
 import com.zy.core.thread.DevpThread;
+import lombok.extern.slf4j.Slf4j;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.jdbc.core.JdbcTemplate;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
+
+import java.util.Date;
+import java.util.List;
+import java.util.stream.Collectors;
 
 /**
  * Created by vincent on 2020/8/6
  */
+@Slf4j
 @Service("mainService")
 public class MainServiceImpl {
 
     @Autowired
+    private CommonService commonService;
+    @Autowired
     private SlaveProperties slaveProperties;
+    @Autowired
+    private WrkMastMapper wrkMastMapper;
+    @Autowired
+    private WrkDetlService wrkDetlService;
+    @Autowired
+    private WaitPakinMapper waitPakinMapper;
+    @Autowired
+    private LocMastService locMastService;
+    @Autowired
+    private JdbcTemplate jdbcTemplate;
 
     /**
-     * 鍏ュ簱绔欙紝鏍规嵁鏉$爜鎵弿鐢熸垚鍏ュ簱宸ヤ綔妗o紝宸ヤ綔鐘舵��1
+     * 鍏ュ簱绔欙紝鏍规嵁鏉$爜鎵弿鐢熸垚鍏ュ簱宸ヤ綔妗o紝宸ヤ綔鐘舵�� 2
      */
     @Transactional
     public void generateStoreWrkFile() {
@@ -39,14 +68,69 @@
                 // 鍒ゆ柇鏄惁婊¤冻鍏ュ簱鏉′欢
                 if (staProtocol.isAutoing() && staProtocol.isLoading() && staProtocol.isInreq1()
                         && !staProtocol.isEmptyMk() && staProtocol.isInreq1() && staProtocol.getWorkNO() ==0
-                        && !Cools.isEmpty(barcode)) {
-                    // 鐢熸垚宸ヤ綔妗�
+                        && staProtocol.isPakMk() && !Cools.isEmpty(barcode)) {
+                    // 鍒ゆ柇閲嶅宸ヤ綔妗�
+                    WrkMast wrkMast = wrkMastMapper.selectPakInStep1(inSta.getStaNo(), barcode);
+                    if (wrkMast != null) {
+                        log.warn("宸ヤ綔妗d腑宸插瓨鍦ㄨ绔欑姸鎬佷负1鐨勬暟鎹�,宸ヤ綔鍙�-{}", wrkMast.getWrkNo());
+                        continue;
+                    }
+                    // 鑾峰彇鍏ュ簱閫氱煡妗�
+                    List<WaitPakin> waitPakins = waitPakinMapper.selectList(new EntityWrapper<WaitPakin>().eq("barcode", barcode));
+                    // 宸ヤ綔鍙�
+                    int workNo = commonService.getWorkNo(0);
+                    // 妫�绱㈠簱浣�
+                    List<String> matNos = waitPakins.stream().map(WaitPakin::getMatnr).distinct().collect(Collectors.toList());
+                    StartupDto startupDto = commonService.getLocNo(1, 1, inSta.getStaNo(), matNos);
+                    String locNo = startupDto.getLocNo();
+                    if (!waitPakins.isEmpty()) {
+                        // 鎻掑叆宸ヤ綔鏄庣粏妗�
+                        wrkDetlService.createWorkDetail(workNo, waitPakins, barcode);
+                    } else {
+                        log.warn("鏃犳鍏ュ簱鏉$爜鏁版嵁---{}", barcode);
+                        continue;
+                    }
+
+                    // 鎻掑叆宸ヤ綔涓绘。
+                    wrkMast = new WrkMast();
+                    wrkMast.setWrkNo(workNo);
+                    wrkMast.setIoTime(new Date());
+                    wrkMast.setWrkSts(2L); // 宸ヤ綔鐘舵�侊細2.璁惧涓婅蛋
+                    wrkMast.setIoType(1); // 鍏ュ嚭搴撶姸鎬侊細1.鍏ュ簱
+                    wrkMast.setIoPri(10D); // 浼樺厛绾э細10
+                    wrkMast.setCrnNo(startupDto.getCrnNo());
+                    wrkMast.setSourceStaNo(startupDto.getSourceStaNo());
+                    wrkMast.setStaNo(startupDto.getStaNo());
+                    wrkMast.setLocNo(startupDto.getLocNo());
+                    wrkMast.setBarcode(barcode); // 鎵樼洏鐮�
+                    wrkMast.setFullPlt("Y"); // 婊℃澘锛歒
+                    wrkMast.setPicking("N"); // 鎷f枡
+                    wrkMast.setExitMk("N"); // 閫�鍑�
+                    wrkMast.setEmptyMk("N"); // 绌烘澘
+                    wrkMast.setLinkMis("N");
+//                    wrkMast.setCtnType(sourceStaNo.getCtnType()); // 瀹瑰櫒绫诲瀷
+                    // 鎿嶄綔浜哄憳鏁版嵁
+                    wrkMast.setAppeTime(new Date());
+                    wrkMast.setModiTime(new Date());
+                    Integer insert = wrkMastMapper.insert(wrkMast);
+                    if (insert == 0) {
+                        throw new CoolException("淇濆瓨宸ヤ綔妗eけ璐�");
+                    }
+                    // 鏇存柊鐩爣搴撲綅鐘舵��
+                    LocMast locMast = locMastService.selectById(startupDto.getLocNo());
+                    locMast.setLocSts("S"); // S.鍏ュ簱棰勭害
+                    locMast.setModiTime(new Date());
+                    if (!locMastService.updateById(locMast)){
+                        throw new CoolException("鏀瑰彉搴撲綅鐘舵�佸け璐�");
+                    }
+
+                    // 涓嬪彂plc鍛戒护
+
 
                 }
 
 
             }
-
         }
 
     }
diff --git a/src/main/java/com/zy/asrs/service/impl/MatCodeServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/MatCodeServiceImpl.java
new file mode 100644
index 0000000..72ae4e0
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/impl/MatCodeServiceImpl.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.service.impl;
+
+import com.baomidou.mybatisplus.service.impl.ServiceImpl;
+import com.zy.asrs.entity.MatCode;
+import com.zy.asrs.mapper.MatCodeMapper;
+import com.zy.asrs.service.MatCodeService;
+import org.springframework.stereotype.Service;
+
+@Service("matCodeService")
+public class MatCodeServiceImpl extends ServiceImpl<MatCodeMapper, MatCode> implements MatCodeService {
+
+}
diff --git a/src/main/java/com/zy/asrs/service/impl/RowLastnoServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/RowLastnoServiceImpl.java
new file mode 100644
index 0000000..1a32cff
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/impl/RowLastnoServiceImpl.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.service.impl;
+
+import com.baomidou.mybatisplus.service.impl.ServiceImpl;
+import com.zy.asrs.entity.RowLastno;
+import com.zy.asrs.mapper.RowLastnoMapper;
+import com.zy.asrs.service.RowLastnoService;
+import org.springframework.stereotype.Service;
+
+@Service("rowLastnoService")
+public class RowLastnoServiceImpl extends ServiceImpl<RowLastnoMapper, RowLastno> implements RowLastnoService {
+
+}
diff --git a/src/main/java/com/zy/asrs/service/impl/StaDescServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/StaDescServiceImpl.java
new file mode 100644
index 0000000..87a3f20
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/impl/StaDescServiceImpl.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.service.impl;
+
+import com.baomidou.mybatisplus.service.impl.ServiceImpl;
+import com.zy.asrs.entity.StaDesc;
+import com.zy.asrs.mapper.StaDescMapper;
+import com.zy.asrs.service.StaDescService;
+import org.springframework.stereotype.Service;
+
+@Service("staDescService")
+public class StaDescServiceImpl extends ServiceImpl<StaDescMapper, StaDesc> implements StaDescService {
+
+}
diff --git a/src/main/java/com/zy/asrs/service/impl/WrkDetlServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/WrkDetlServiceImpl.java
new file mode 100644
index 0000000..18af108
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/impl/WrkDetlServiceImpl.java
@@ -0,0 +1,52 @@
+package com.zy.asrs.service.impl;
+
+import com.baomidou.mybatisplus.service.impl.ServiceImpl;
+import com.core.common.Cools;
+import com.core.exception.CoolException;
+import com.zy.asrs.entity.MatCode;
+import com.zy.asrs.entity.WaitPakin;
+import com.zy.asrs.entity.WrkDetl;
+import com.zy.asrs.mapper.WrkDetlMapper;
+import com.zy.asrs.service.MatCodeService;
+import com.zy.asrs.service.WrkDetlService;
+import com.zy.asrs.utils.VersionUtils;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import org.springframework.transaction.annotation.Transactional;
+
+import java.util.Date;
+import java.util.List;
+
+@Service("wrkDetlService")
+public class WrkDetlServiceImpl extends ServiceImpl<WrkDetlMapper, WrkDetl> implements WrkDetlService {
+
+    @Autowired
+    private MatCodeService matCodeService;
+
+    @Override
+    @Transactional
+    public void createWorkDetail(Integer workNo, List<WaitPakin> waitPakins, String barcode) {
+        if (waitPakins.isEmpty()){
+            return;
+        }
+        for (WaitPakin waitPakin : waitPakins) {
+            MatCode matCode = matCodeService.selectById(waitPakin.getMatnr());
+            if (Cools.isEmpty(matCode)){
+                throw new CoolException("鐗╂枡鏉$爜鏁版嵁涓虹┖");
+            }
+            // 淇濇寔宸ヤ綔妗f槑缁�
+            WrkDetl wrkDetl = new WrkDetl();
+            wrkDetl.setWrkNo(workNo);
+            wrkDetl.setIoTime(new Date());
+            wrkDetl.setAnfme(waitPakin.getAnfme()); // 鏁伴噺
+            VersionUtils.setWrkDetl(wrkDetl, matCode); // 鐗堟湰鎺у埗
+            wrkDetl.setZpallet(barcode); // 鎵樼洏鏉$爜
+            wrkDetl.setAppeTime(new Date());
+            wrkDetl.setModiTime(new Date());
+            if (!this.insert(wrkDetl)) {
+                throw new CoolException("淇濆瓨宸ヤ綔鏄庣粏澶辫触");
+            }
+        }
+    }
+
+}
diff --git a/src/main/java/com/zy/asrs/service/impl/WrkLastnoServiceImpl.java b/src/main/java/com/zy/asrs/service/impl/WrkLastnoServiceImpl.java
new file mode 100644
index 0000000..f069f52
--- /dev/null
+++ b/src/main/java/com/zy/asrs/service/impl/WrkLastnoServiceImpl.java
@@ -0,0 +1,12 @@
+package com.zy.asrs.service.impl;
+
+import com.baomidou.mybatisplus.service.impl.ServiceImpl;
+import com.zy.asrs.entity.WrkLastno;
+import com.zy.asrs.mapper.WrkLastnoMapper;
+import com.zy.asrs.service.WrkLastnoService;
+import org.springframework.stereotype.Service;
+
+@Service("wrkLastnoService")
+public class WrkLastnoServiceImpl extends ServiceImpl<WrkLastnoMapper, WrkLastno> implements WrkLastnoService {
+
+}
diff --git a/src/main/java/com/zy/asrs/utils/VersionUtils.java b/src/main/java/com/zy/asrs/utils/VersionUtils.java
new file mode 100644
index 0000000..4803050
--- /dev/null
+++ b/src/main/java/com/zy/asrs/utils/VersionUtils.java
@@ -0,0 +1,54 @@
+package com.zy.asrs.utils;
+
+import com.zy.asrs.entity.LocDetl;
+import com.zy.asrs.entity.MatCode;
+import com.zy.asrs.entity.WrkDetl;
+
+/**
+ * Created by vincent on 2020/7/14
+ */
+public class VersionUtils {
+
+    // 涓氬姟 ----------------------------------------------------------------------
+
+    public static void setWrkDetl(WrkDetl wrkDetl, MatCode matCode) {
+        wrkDetl.setMatnr(matCode.getMatNo()); // 鐗╂枡缂栧彿
+        wrkDetl.setMaktx(matCode.getMatName()); // 鐗╂枡鎻忚堪
+        wrkDetl.setLgnum(matCode.getStr2()); // 瑙勬牸
+        wrkDetl.setColor(matCode.getStr3()); // 鍔╄鐮�
+        wrkDetl.setAltme(matCode.getStr1()); // 鍗曚綅
+        wrkDetl.setBname(matCode.getStr4()); // 瀹㈡埛
+    }
+
+    public static void setWrkDetl(WrkDetl wrkDetl, LocDetl locDetl) {
+        wrkDetl.setMatnr(locDetl.getMatnr()); // 鐗╂枡缂栧彿
+        wrkDetl.setMaktx(locDetl.getMaktx()); // 鐗╂枡鎻忚堪
+        wrkDetl.setLgnum(locDetl.getLgnum()); // 瑙勬牸
+        wrkDetl.setColor(locDetl.getColor()); // 鍔╄鐮�
+        wrkDetl.setBname(locDetl.getBname()); // 瀹㈡埛
+        wrkDetl.setAltme(locDetl.getAltme()); // 鍗曚綅
+        wrkDetl.setZpallet(locDetl.getZpallet()); // 鎵樼洏鏉$爜
+    }
+
+    public static void setLocDetl(LocDetl locDetl, MatCode matCode) {
+        locDetl.setMatnr(matCode.getMatNo()); // 鐗╂枡缂栧彿
+        locDetl.setMaktx(matCode.getMatName()); // 鐗╂枡鎻忚堪
+        locDetl.setLgnum(matCode.getStr2()); // 瑙勬牸
+        locDetl.setColor(matCode.getStr3()); // 鍔╄鐮�
+        locDetl.setBname(matCode.getStr4()); // 瀹㈡埛
+        locDetl.setAltme(matCode.getStr1()); // 鍗曚綅
+    }
+
+    public static void setLocDetl(LocDetl locDetl, WrkDetl wrkDetl) {
+        locDetl.setMatnr(wrkDetl.getMatnr()); // 鐗╂枡缂栧彿
+        locDetl.setMaktx(wrkDetl.getMaktx()); // 鐗╂枡鎻忚堪
+        locDetl.setLgnum(wrkDetl.getLgnum()); // 瑙勬牸
+        locDetl.setColor(wrkDetl.getColor()); // 鍔╄鐮�
+        locDetl.setBname(wrkDetl.getBname()); // 瀹㈡埛
+        locDetl.setAnfme(wrkDetl.getAnfme()); // 鏁伴噺
+        locDetl.setAltme(wrkDetl.getAltme()); // 鍗曚綅
+        locDetl.setZpallet(wrkDetl.getZpallet()); // 鎵樼洏鏉$爜
+    }
+
+
+}
diff --git a/src/main/java/com/zy/common/model/MatDto.java b/src/main/java/com/zy/common/model/MatDto.java
new file mode 100644
index 0000000..e8e488b
--- /dev/null
+++ b/src/main/java/com/zy/common/model/MatDto.java
@@ -0,0 +1,17 @@
+package com.zy.common.model;
+
+import lombok.Data;
+
+/**
+ * Created by vincent on 2020/8/6
+ */
+@Data
+public class MatDto {
+
+    // 鐗╂枡缂栧彿
+    private String matNo;
+
+    // 鐗╂枡鏁伴噺
+    private Double count;
+
+}
diff --git a/src/main/java/com/zy/common/model/Shelves.java b/src/main/java/com/zy/common/model/Shelves.java
new file mode 100644
index 0000000..17515ce
--- /dev/null
+++ b/src/main/java/com/zy/common/model/Shelves.java
@@ -0,0 +1,113 @@
+package com.zy.common.model;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+/**
+ * <strong>绔嬪簱璐ф灦瀹炰綋绫�</strong>
+ * Created by vincent on 2020/6/11
+ */
+public class Shelves {
+
+    // 璐ф灦鎺掓暟閲�
+    private final int size;
+
+    // 璐ф灦缁勬暟閲�
+    private final int group;
+
+    // 鍋忕Щ閲廩default:0]
+    private final int offset;
+
+    // 璐ф灦瀹炰緥鑺傜偣闆嗗悎
+    public List<List<Integer>> nodes;
+
+    public Shelves(int size, int group) {
+        this(size, group, 0);
+    }
+
+    /**
+     * @param size 璐ф灦鍗曟帓鎬绘暟
+     * @param group 璐ф灦缁勬暟閲�
+     * @param offset 搴忓垪鍙峰亸绉婚噺
+     */
+    public Shelves(int size, int group, int offset) {
+        this.size = size;
+        this.group = group;
+        this.offset = offset;
+        init();
+    }
+
+    /**
+     * 鍒濆鍖栨柟娉曘�愮鏈夈��
+     */
+    private void init(){
+        if (group == 0 || size%group != 0) {
+            throw new RuntimeException("shelves init fail!");
+        }
+        nodes = new ArrayList<>();
+        for (int g = 1; g <= this.group; g++){
+            int unit = size/group;
+            List<Integer> node = new ArrayList<>();
+            for (int i = (g-1)*unit+1+offset ; i <= g*unit+offset; i++){
+                node.add(i);
+            }
+            nodes.add(node);
+        }
+    }
+
+    /**
+     * 寮�濮嬭绠� =======>>>
+     *
+     *          璐ф灦鍛戒腑瑙勫垯濡備笅锛�
+     *              瀹夎浣嶇疆锛�   [1]  [2]  |  [3]  [4]  --------  [5] [6]  |  [7] [8]
+     *                  鍛戒腑椤哄簭锛�      1 -> 5 -> 4 -> 8 -> 2 -> 6 -> 3 -> 7 -> 1 ...
+     *
+     *          1.璇ヨ鍒欓�備笉闄愬埗璐ф灦鏁伴噺锛屾�绘暟涓庣粍鍒湪鏋勯�犲櫒涓缃�
+     *          2.濡傛湁搴忓垪鍙疯捣濮嬮棶棰橈紝鐢ㄥ亸绉婚噺瑙勯伩鍗冲彲
+     *
+     * @param curSeq 褰撳墠璐ф灦鍙�
+     * @return 瑙勫垯鍛戒腑璐ф灦鍙�
+     */
+    public int start(int curSeq){
+        Iterator<List<Integer>> iterator = nodes.iterator();
+        while (iterator.hasNext()){
+            List<Integer> node = iterator.next();
+            if (node.contains(curSeq)) {
+                int idx = node.indexOf(curSeq);
+                // 鏄惁涓烘湯灏捐揣鏋�
+                if (iterator.hasNext()) {
+                    return iterator.next().get(idx);
+                } else {
+                    List<Integer> first = nodes.get(0);
+                    int val = first.get(idx);
+                    int res = size / group + 1 + offset - val;
+                    // 鍙嶅悜鍛戒腑璐ф灦鏃朵笉鍐嶆槸瀵圭珛涓嬫爣锛堢浉瀵逛簬宸烽亾锛�
+                    if (res < val) {
+                        // 杞鎵�鏈夎揣鏋跺悗閲嶆柊寮�濮嬪畾浣�
+                        if (val - res - offset == 1) {
+                            return first.get(0);
+                        }
+                        res = res + 1;
+                    }
+                    return res + offset;
+                }
+            }
+        }
+        return -1;
+    }
+
+
+    public static void main(String[] args) throws InterruptedException {
+        Shelves shelves = new Shelves(8,2);
+        System.out.println(shelves.nodes.toString());
+        int start = 1;
+        while (true) {
+            System.out.println(start);
+            start = shelves.start(start);
+            Thread.sleep(500L);
+        }
+    }
+
+}
+
diff --git a/src/main/java/com/zy/common/model/StartupDto.java b/src/main/java/com/zy/common/model/StartupDto.java
new file mode 100644
index 0000000..dacec79
--- /dev/null
+++ b/src/main/java/com/zy/common/model/StartupDto.java
@@ -0,0 +1,47 @@
+package com.zy.common.model;
+
+/**
+ * Created by vincent on 2020/6/11
+ */
+public class StartupDto {
+
+    private Integer sourceStaNo;
+
+    private Integer staNo;
+
+    private Integer crnNo;
+
+    private String locNo;
+
+    public Integer getSourceStaNo() {
+        return sourceStaNo;
+    }
+
+    public void setSourceStaNo(Integer sourceStaNo) {
+        this.sourceStaNo = sourceStaNo;
+    }
+
+    public Integer getStaNo() {
+        return staNo;
+    }
+
+    public void setStaNo(Integer staNo) {
+        this.staNo = staNo;
+    }
+
+    public Integer getCrnNo() {
+        return crnNo;
+    }
+
+    public void setCrnNo(Integer crnNo) {
+        this.crnNo = crnNo;
+    }
+
+    public String getLocNo() {
+        return locNo;
+    }
+
+    public void setLocNo(String locNo) {
+        this.locNo = locNo;
+    }
+}
diff --git a/src/main/java/com/zy/common/service/WmsService.java b/src/main/java/com/zy/common/service/WmsService.java
new file mode 100644
index 0000000..d188461
--- /dev/null
+++ b/src/main/java/com/zy/common/service/WmsService.java
@@ -0,0 +1,50 @@
+package com.zy.common.service;
+
+import com.alibaba.fastjson.JSON;
+import com.zy.asrs.entity.WaitPakin;
+import com.zy.common.utils.HttpHandler;
+import com.zy.core.properties.SystemProperties;
+import lombok.extern.slf4j.Slf4j;
+import org.springframework.stereotype.Service;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * Created by vincent on 2020/8/6
+ */
+@Slf4j
+@Service
+public class WmsService {
+
+    public boolean fullStorePutStart(String barcode, Integer sourceStaNo, List<WaitPakin> waitPakins) {
+
+        try {
+            Map<String, Object> param = new HashMap<>();
+            param.put("barcode", barcode);
+            param.put("devpNo", sourceStaNo);
+            List<Map<String, Object>> list = new ArrayList<>();
+            for (WaitPakin waitPakin : waitPakins) {
+                Map<String, Object> mat = new HashMap<>();
+                mat.put("matNo", waitPakin.getMatnr());
+                mat.put("count", waitPakin.getAnfme());
+                list.add(mat);
+            }
+            param.put("list", list);
+
+            String response = new HttpHandler.Builder()
+                    .setUri(SystemProperties.WMS_URL)
+                    .setPath("/full/store/put/start")
+                    .setJson(JSON.toJSONString(param))
+                    .build()
+                    .doPost();
+        } catch (IOException e) {
+
+        }
+        return true;
+    }
+
+}
diff --git a/src/main/java/com/zy/common/utils/HttpHandler.java b/src/main/java/com/zy/common/utils/HttpHandler.java
new file mode 100644
index 0000000..70adcc7
--- /dev/null
+++ b/src/main/java/com/zy/common/utils/HttpHandler.java
@@ -0,0 +1,213 @@
+package com.zy.common.utils;
+
+
+import okhttp3.*;
+
+import java.io.IOException;
+import java.util.Map;
+import java.util.Optional;
+import java.util.concurrent.TimeUnit;
+
+/**
+ * Http鍗忚瀹㈡埛绔�
+ * @author luxiaotao
+ * @date 2018-9-27
+ */
+public class HttpHandler {
+
+    private static final Integer DEFAULT_TIMEOUT_SECONDS = 5;
+    private static final MediaType MEDIA_TYPE = MediaType.parse("application/json;charset=utf-8");
+
+    private String uri;
+    private String path;
+    private String json;
+    private Map<String, Object> params;
+    private Map<String, Object> headers;
+    private boolean https;
+    private Integer timeout;
+    private TimeUnit timeUnit;
+
+    public HttpHandler(Builder builder){
+        this.uri = builder.uri;
+        this.path = builder.path;
+        this.json = builder.json;
+        this.params = builder.params;
+        this.headers = builder.headers;
+        this.https = builder.https;
+        this.timeout = builder.timeout;
+        this.timeUnit = builder.timeUnit;
+    }
+
+    /**
+     * GET璇锋眰鎵ц
+     * @return the HttpHandler response
+     */
+    public String doGet() throws IOException {
+        String url = paramsToUrl(uri, path, params, https);
+        Request.Builder headerBuilder = new Request.Builder();
+        if (headers != null && headers.size()>0){
+            for (Map.Entry<String, Object> entry : headers.entrySet()){
+                headerBuilder.addHeader(entry.getKey(), String.valueOf(entry.getValue()));
+            }
+        }
+        Request request = headerBuilder.url(url).build();
+        Response response = getClient(timeout, timeUnit).newCall(request).execute();
+        return response.isSuccessful() ? response.body().string() : null;
+    }
+
+    /**
+     * POST璇锋眰鎵ц
+     * @return the HttpHandler response
+     */
+    public String doPost() throws IOException {
+        Request request;
+        Request.Builder headerBuilder = new Request.Builder();
+        if (headers != null && headers.size()>0){
+            for (Map.Entry<String, Object> entry : headers.entrySet()){
+                headerBuilder.addHeader(entry.getKey(), String.valueOf(entry.getValue()));
+            }
+        }
+        if (json == null || "".equals(json)){
+            FormBody.Builder builder = new FormBody.Builder();
+            for (Map.Entry<String, Object> entry : params.entrySet()){
+                builder.add(entry.getKey(), String.valueOf(entry.getValue()));
+            }
+            FormBody body = builder.build();
+            request = headerBuilder
+                    .url((https?"https://":"http://")+uri+path)
+                    .post(body)
+                    .build();
+        } else {
+            RequestBody body = RequestBody.create(MEDIA_TYPE, json);
+            Request.Builder builder = headerBuilder.url((https?"https://":"http://")+uri+path);
+            builder.header("Content-Type", "application/json;charset=UTF-8");
+            request = builder.post(body).build();
+
+        }
+        Call call = getClient(timeout, timeUnit).newCall(request);
+        Response response = call.execute();
+        return response.body().string();
+
+    }
+
+    /**
+     * get璇锋眰鍙傛暟鎷兼帴鏂规硶
+     * @return 璇锋眰琛�
+     */
+    private String paramsToUrl(String uri, String path, Map<String, Object> params, boolean isHttps) {
+        StringBuilder res = new StringBuilder();
+        res.append(isHttps ? "https://" : "http://");
+        res.append(uri);
+        if (path.length() > 0 && !(path.charAt(0) == '/')){
+            res.append("/");
+        }
+        res.append(path);
+        Optional.ofNullable(params).ifPresent(
+                args -> {
+                    res.append("?");
+                    args.forEach((key, value) -> {
+                        res.append(key);
+                        res.append("=");
+                        res.append(value);
+                        res.append("&");
+                    });
+                }
+        );
+        String url = res.toString();
+        if ("&".equals(url.substring(url.length()-1, url.length()))){
+            url = url.substring(0, url.length()-1);
+        }
+        return url;
+    }
+
+    /**
+     * 鑾峰彇 okHttpClient
+     * @return the HttpHandler instance
+     */
+    private OkHttpClient getClient(Integer timeout, TimeUnit timeUnit){
+        return new OkHttpClient
+                .Builder()
+                .connectTimeout(timeout, timeUnit)
+                .readTimeout(timeout, timeUnit)
+                .build();
+    }
+
+    /**
+     * Http鍗忚鎶ユ枃寤洪�犺��
+     */
+    public static class Builder {
+
+        private String uri;
+        private String path;
+        private String json;
+        private Map<String, Object> params;
+        private Map<String, Object> headers;
+        private boolean https;
+        private Integer timeout;
+        private TimeUnit timeUnit;
+
+        {
+            // 榛樿5s瓒呮椂
+            timeout = DEFAULT_TIMEOUT_SECONDS;
+            timeUnit = TimeUnit.SECONDS;
+            path = "";
+        }
+
+        /**
+         * 寤洪�犲櫒
+         * @return the HttpHandler instance
+         */
+        public HttpHandler build(){
+            if (null == this.uri || "".equals(this.uri)){
+                throw new RuntimeException("uri is null");
+            }
+            if (this.uri.startsWith("http://")){
+                this.uri = this.uri.substring(6,uri.length());
+            } else if (this.uri.startsWith("https://")){
+                this.uri = this.uri.substring(7,uri.length());
+            }
+            return new HttpHandler(this);
+        }
+
+        public Builder setUri(String uri) {
+            this.uri = uri;
+            return this;
+        }
+
+        public Builder setPath(String path) {
+            if (!path.startsWith("/")){
+                path = "/" + path;
+            }
+            this.path = path;
+            return this;
+        }
+
+        public Builder setTimeout(Integer timeout, TimeUnit timeUnit) {
+            this.timeout = timeout;
+            this.timeUnit = timeUnit;
+            return this;
+        }
+
+        public Builder setParams(Map<String, Object> params) {
+            this.params = params;
+            return this;
+        }
+
+        public Builder setHeaders(Map<String, Object> headers) {
+            this.headers = headers;
+            return this;
+        }
+
+        public Builder setHttps(boolean https) {
+            this.https = https;
+            return this;
+        }
+
+        public Builder setJson(String json) {
+            this.json = json;
+            return this;
+        }
+
+    }
+
+}
diff --git a/src/main/java/com/zy/core/MainProcess.java b/src/main/java/com/zy/core/MainProcess.java
index 58f36e8..dc8bcdb 100644
--- a/src/main/java/com/zy/core/MainProcess.java
+++ b/src/main/java/com/zy/core/MainProcess.java
@@ -34,7 +34,7 @@
                     if (SystemProperties.WCS_RUNNING_STATUS.get()) {
                         continue;
                     }
-                    // 鍏ュ簱绔欙紝鏍规嵁鏉$爜鎵弿鐢熸垚鍏ュ簱宸ヤ綔妗o紝宸ヤ綔鐘舵��1锛屾棤璁惧鍛戒护涓嬪彂
+                    // 鍏ュ簱绔欙紝鏍规嵁鏉$爜鎵弿鐢熸垚鍏ュ簱宸ヤ綔妗o紝宸ヤ綔鐘舵��2锛屾棤璁惧鍛戒护涓嬪彂
                     mainService.generateStoreWrkFile();
 
 
diff --git a/src/main/java/com/zy/core/model/protocol/StaProtocol.java b/src/main/java/com/zy/core/model/protocol/StaProtocol.java
index 5b99cee..61d016a 100644
--- a/src/main/java/com/zy/core/model/protocol/StaProtocol.java
+++ b/src/main/java/com/zy/core/model/protocol/StaProtocol.java
@@ -27,6 +27,9 @@
     // 闇�姹�1
     private boolean inreq1;
 
+    // 閿佸畾鏍囪
+    private boolean pakMk;
+
     // 宸ヤ綔鍙�
     private Integer workNO;
 
diff --git a/src/main/java/com/zy/core/properties/SystemProperties.java b/src/main/java/com/zy/core/properties/SystemProperties.java
index e7a8f1b..39672ae 100644
--- a/src/main/java/com/zy/core/properties/SystemProperties.java
+++ b/src/main/java/com/zy/core/properties/SystemProperties.java
@@ -12,4 +12,6 @@
     // 绯荤粺杩愯鐘舵��
     public static final AtomicBoolean WCS_RUNNING_STATUS = new AtomicBoolean(Boolean.TRUE);
 
+    public static final String WMS_URL = "localhost";
+
 }
diff --git a/src/main/resources/mapper/LocDetlMapper.xml b/src/main/resources/mapper/LocDetlMapper.xml
new file mode 100644
index 0000000..26dabee
--- /dev/null
+++ b/src/main/resources/mapper/LocDetlMapper.xml
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.zy.asrs.mapper.LocDetlMapper">
+
+    <!-- 閫氱敤鏌ヨ鏄犲皠缁撴灉 -->
+    <resultMap id="BaseResultMap" type="com.zy.asrs.entity.LocDetl">
+        <result column="loc_no" property="locNo" />
+        <result column="matnr" property="matnr" />
+        <result column="maktx" property="maktx" />
+        <result column="lgnum" property="lgnum" />
+        <result column="type" property="type" />
+        <result column="color" property="color" />
+        <result column="supplier" property="supplier" />
+        <result column="warehouse" property="warehouse" />
+        <result column="brand" property="brand" />
+        <result column="anfme" property="anfme" />
+        <result column="altme" property="altme" />
+        <result column="zpallet" property="zpallet" />
+        <result column="bname" property="bname" />
+        <result column="memo" property="memo" />
+        <result column="modi_user" property="modiUser" />
+        <result column="modi_time" property="modiTime" />
+        <result column="appe_user" property="appeUser" />
+        <result column="appe_time" property="appeTime" />
+    </resultMap>
+
+    <sql id="stockOutCondition">
+        <if test="loc_no!=null and loc_no!='' ">
+            and a.loc_no like '%' + #{loc_no} + '%'
+        </if>
+        <if test="matnr!=null and matnr!='' ">
+            and a.matnr like '%' + #{matnr} + '%'
+        </if>
+        <if test="maktx!=null and maktx!='' ">
+            and a.maktx like '%' + #{maktx} + '%'
+        </if>
+        <if test="anfme!=null and anfme!='' ">
+            and a.anfme like '%' + #{anfme} + '%'
+        </if>
+        <if test="altme!=null and altme!='' ">
+            and a.altme like '%' + #{altme} + '%'
+        </if>
+        <if test="startTime!=null and endTime!=null">
+            and a.modi_time between #{startTime} and #{endTime}
+        </if>
+    </sql>
+
+    <select id="getStockOutPage" resultMap="BaseResultMap">
+        select * from
+        (
+            select
+            ROW_NUMBER() over (order by a.appe_time,a.matnr,a.loc_no) as row,
+            a.*
+            from asr_loc_detl a
+            left join asr_loc_mast b on a.loc_no = b.loc_no
+            where 1=1
+            and b.loc_sts = 'F'
+            <include refid="stockOutCondition"></include>
+        ) t where t.row between ((#{pageNumber}-1)*#{pageSize}+1) and (#{pageNumber}*#{pageSize})
+    </select>
+
+    <select id="getStockOutPageCount" parameterType="java.util.Map" resultType="java.lang.Integer">
+        select
+        count(1)
+        from asr_loc_detl a
+        left join asr_loc_mast b on a.loc_no = b.loc_no
+        where 1=1
+        and b.loc_sts = 'F'
+        <include refid="stockOutCondition"></include>
+    </select>
+</mapper>
diff --git a/src/main/resources/mapper/MatCodeMapper.xml b/src/main/resources/mapper/MatCodeMapper.xml
new file mode 100644
index 0000000..8e78b20
--- /dev/null
+++ b/src/main/resources/mapper/MatCodeMapper.xml
@@ -0,0 +1,48 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.zy.asrs.mapper.MatCodeMapper">
+
+    <!-- 閫氱敤鏌ヨ鏄犲皠缁撴灉 -->
+    <resultMap id="BaseResultMap" type="com.zy.asrs.entity.MatCode">
+        <result column="mat_no" property="matNo" />
+        <result column="barcode" property="barcode" />
+        <result column="mat_name" property="matName" />
+        <result column="str1" property="str1" />
+        <result column="str2" property="str2" />
+        <result column="str3" property="str3" />
+        <result column="str4" property="str4" />
+        <result column="str5" property="str5" />
+        <result column="str6" property="str6" />
+        <result column="str7" property="str7" />
+        <result column="str8" property="str8" />
+        <result column="str9" property="str9" />
+        <result column="str10" property="str10" />
+        <result column="str11" property="str11" />
+        <result column="str12" property="str12" />
+        <result column="str13" property="str13" />
+        <result column="str14" property="str14" />
+        <result column="str15" property="str15" />
+        <result column="str16" property="str16" />
+        <result column="str17" property="str17" />
+        <result column="str18" property="str18" />
+        <result column="str19" property="str19" />
+        <result column="str20" property="str20" />
+        <result column="str21" property="str21" />
+        <result column="str22" property="str22" />
+        <result column="str23" property="str23" />
+        <result column="num1" property="num1" />
+        <result column="num2" property="num2" />
+        <result column="num3" property="num3" />
+        <result column="num4" property="num4" />
+        <result column="num5" property="num5" />
+        <result column="num6" property="num6" />
+        <result column="date1" property="date1" />
+        <result column="appe_user" property="appeUser" />
+        <result column="appe_time" property="appeTime" />
+        <result column="modi_user" property="modiUser" />
+        <result column="modi_time" property="modiTime" />
+        <result column="status" property="status" />
+
+    </resultMap>
+
+</mapper>
diff --git a/src/main/resources/mapper/RowLastnoMapper.xml b/src/main/resources/mapper/RowLastnoMapper.xml
new file mode 100644
index 0000000..45639f6
--- /dev/null
+++ b/src/main/resources/mapper/RowLastnoMapper.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.zy.asrs.mapper.RowLastnoMapper">
+
+    <!-- 閫氱敤鏌ヨ鏄犲皠缁撴灉 -->
+    <resultMap id="BaseResultMap" type="com.zy.asrs.entity.RowLastno">
+        <id column="whs_type" property="whsType" />
+        <result column="wrk_mk" property="wrkMk" />
+        <result column="current_row" property="currentRow" />
+        <result column="s_row" property="sRow" />
+        <result column="e_row" property="eRow" />
+        <result column="crn_qty" property="crnQty" />
+        <result column="memo" property="memo" />
+        <result column="modi_user" property="modiUser" />
+        <result column="modi_time" property="modiTime" />
+        <result column="appe_user" property="appeUser" />
+        <result column="appe_time" property="appeTime" />
+        <result column="limint_loc" property="limintLoc" />
+
+    </resultMap>
+
+</mapper>
diff --git a/src/main/resources/mapper/StaDescMapper.xml b/src/main/resources/mapper/StaDescMapper.xml
new file mode 100644
index 0000000..b3bde73
--- /dev/null
+++ b/src/main/resources/mapper/StaDescMapper.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.zy.asrs.mapper.StaDescMapper">
+
+    <!-- 閫氱敤鏌ヨ鏄犲皠缁撴灉 -->
+    <resultMap id="BaseResultMap" type="com.zy.asrs.entity.StaDesc">
+        <id column="type_id" property="typeId" />
+        <result column="type_no" property="typeNo" />
+        <result column="type_desc" property="typeDesc" />
+        <result column="stn_no" property="stnNo" />
+        <result column="stn_desc" property="stnDesc" />
+        <result column="crn_no" property="crnNo" />
+        <result column="crn_stn" property="crnStn" />
+        <result column="memo" property="memo" />
+        <result column="modi_user" property="modiUser" />
+        <result column="modi_time" property="modiTime" />
+        <result column="appe_user" property="appeUser" />
+        <result column="appe_time" property="appeTime" />
+
+    </resultMap>
+
+</mapper>
diff --git a/src/main/resources/mapper/WaitPakinMapper.xml b/src/main/resources/mapper/WaitPakinMapper.xml
new file mode 100644
index 0000000..42be7fd
--- /dev/null
+++ b/src/main/resources/mapper/WaitPakinMapper.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.zy.asrs.mapper.WaitPakinMapper">
+
+    <!-- 閫氱敤鏌ヨ鏄犲皠缁撴灉 -->
+    <resultMap id="BaseResultMap" type="com.zy.asrs.entity.WaitPakin">
+        <id column="id" property="id" />
+        <result column="barcode" property="barcode" />
+        <result column="matnr" property="matnr" />
+        <result column="maktx" property="maktx" />
+        <result column="anfme" property="anfme" />
+        <result column="unit" property="unit" />
+        <result column="status" property="status" />
+        <result column="memo" property="memo" />
+        <result column="modi_time" property="modiTime" />
+        <result column="modi_user" property="modiUser" />
+        <result column="appe_time" property="appeTime" />
+        <result column="appe_user" property="appeUser" />
+
+    </resultMap>
+
+</mapper>
diff --git a/src/main/resources/mapper/WrkDetlMapper.xml b/src/main/resources/mapper/WrkDetlMapper.xml
new file mode 100644
index 0000000..a4d6384
--- /dev/null
+++ b/src/main/resources/mapper/WrkDetlMapper.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.zy.asrs.mapper.WrkDetlMapper">
+
+    <!-- 閫氱敤鏌ヨ鏄犲皠缁撴灉 -->
+    <resultMap id="BaseResultMap" type="com.zy.asrs.entity.WrkDetl">
+        <result column="wrk_no" property="wrkNo" />
+        <result column="io_time" property="ioTime" />
+        <result column="matnr" property="matnr" />
+        <result column="maktx" property="maktx" />
+        <result column="lgnum" property="lgnum" />
+        <result column="type" property="type" />
+        <result column="color" property="color" />
+        <result column="supplier" property="supplier" />
+        <result column="warehouse" property="warehouse" />
+        <result column="brand" property="brand" />
+        <result column="anfme" property="anfme" />
+        <result column="altme" property="altme" />
+        <result column="zpallet" property="zpallet" />
+        <result column="bname" property="bname" />
+        <result column="memo" property="memo" />
+        <result column="modi_user" property="modiUser" />
+        <result column="modi_time" property="modiTime" />
+        <result column="appe_user" property="appeUser" />
+        <result column="appe_time" property="appeTime" />
+    </resultMap>
+
+</mapper>
diff --git a/src/main/resources/mapper/WrkLastnoMapper.xml b/src/main/resources/mapper/WrkLastnoMapper.xml
new file mode 100644
index 0000000..86bc298
--- /dev/null
+++ b/src/main/resources/mapper/WrkLastnoMapper.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.zy.asrs.mapper.WrkLastnoMapper">
+
+    <!-- 閫氱敤鏌ヨ鏄犲皠缁撴灉 -->
+    <resultMap id="BaseResultMap" type="com.zy.asrs.entity.WrkLastno">
+        <id column="wrk_mk" property="wrkMk" />
+        <result column="wrk_no" property="wrkNo" />
+        <result column="modi_user" property="modiUser" />
+        <result column="modi_time" property="modiTime" />
+        <result column="appe_user" property="appeUser" />
+        <result column="appe_time" property="appeTime" />
+        <result column="s_no" property="sNo" />
+        <result column="e_no" property="eNo" />
+        <result column="memo_m" property="memoM" />
+
+    </resultMap>
+
+</mapper>

--
Gitblit v1.9.1