| | |
| | | <dependency> |
| | | <groupId>com.alibaba</groupId> |
| | | <artifactId>easyexcel</artifactId> |
| | | <version>2.0.5</version> |
| | | <version>2.2.6</version> |
| | | </dependency> |
| | | <dependency> |
| | | <groupId>org.projectlombok</groupId> |
| | |
| | | return R.error(); |
| | | } |
| | | LocMast oldLocMast = locMastService.selectById(locMast.getLocNo()); |
| | | // 有物料时修改为空库位或者空板库位,则删除库存明细 |
| | | // 有产品时修改为空库位或者空板库位,则删除库存明细 |
| | | if (oldLocMast.getLocSts().equals("R") || oldLocMast.getLocSts().equals("F")) { |
| | | if (locMast.getLocSts().equals("O") || locMast.getLocSts().equals("D")) { |
| | | locDetlService.delete(new EntityWrapper<LocDetl>().eq("loc_no", locMast.getLocNo())); |
| | |
| | | |
| | | // 导出 |
| | | @RequestMapping(value = "/matCode/export/auth") |
| | | @ManagerAuth(value = ManagerAuth.Auth.NONE, memo = "物料编码数据导出") |
| | | @ManagerAuth(value = ManagerAuth.Auth.NONE, memo = "产品代号数据导出") |
| | | public void export(@RequestParam(required = false) String fileName, |
| | | @RequestParam(required = false) Integer rowCount, |
| | | HttpServletResponse response) throws Exception { |
| | |
| | | } |
| | | response.setContentType("application/vnd.ms-excel"); |
| | | response.setCharacterEncoding("utf-8"); |
| | | fileName = URLEncoder.encode(Cools.isEmpty(fileName)?"物料编码":fileName, "UTF-8"); |
| | | fileName = URLEncoder.encode(Cools.isEmpty(fileName)?"产品代号":fileName, "UTF-8"); |
| | | response.setHeader("Content-disposition", "attachment;filename=" + fileName + ".xlsx"); |
| | | EasyExcel.write(response.getOutputStream(), MatCodeExcel.class) |
| | | .registerWriteHandler(new LongestMatchColumnWidthStyleStrategy()) |
| | |
| | | |
| | | // 导入 |
| | | @RequestMapping(value = "/matCode/import/auth") |
| | | @ManagerAuth(memo = "物料编码数据导入") |
| | | @ManagerAuth(memo = "产品代号数据导入") |
| | | @Transactional |
| | | public R matCodeImport(MultipartFile file) throws IOException, InterruptedException { |
| | | MatCodeExcelListener listener = new MatCodeExcelListener(getUserId()); |
| | | EasyExcel.read(file.getInputStream(), MatCodeExcel.class, listener).sheet().doRead(); |
| | | return R.ok("成功导入"+listener.getTotal()+"条物料信息"); |
| | | return R.ok("成功导入"+listener.getTotal()+"条产品信息"); |
| | | } |
| | | |
| | | // 打印 |
| | | @RequestMapping(value = "/matCode/print/auth") |
| | | @ManagerAuth(memo = "物料编码打印") |
| | | @ManagerAuth(memo = "产品代号打印") |
| | | public R matCodePrint(@RequestParam(value = "param[]") String[] param) { |
| | | if(Cools.isEmpty(param)) { |
| | | return R.parse(CodeRes.EMPTY); |
| | |
| | | } |
| | | |
| | | @RequestMapping(value = "/macCode/code/auth") |
| | | // @ManagerAuth(memo = "物料编码条形码获取(type:1(条形码);2(二维码)") |
| | | // @ManagerAuth(memo = "产品代号条形码获取(type:1(条形码);2(二维码)") |
| | | public R matCodeBarcode(@RequestParam(defaultValue = "1") Integer type |
| | | , @RequestParam String param |
| | | , HttpServletResponse response) throws Exception { |
| | |
| | | private String locNo; |
| | | |
| | | /** |
| | | * 物料编号 |
| | | * 产品编号 |
| | | */ |
| | | @ApiModelProperty(value= "物料编号") |
| | | @ApiModelProperty(value= "产品编号") |
| | | @TableField("mat_no") |
| | | private String matNo; |
| | | |
| | |
| | | |
| | | // AdjDetl adjDetl = new AdjDetl( |
| | | // null, // 库位号[非空] |
| | | // null, // 物料编号[非空] |
| | | // null, // 产品编号[非空] |
| | | // null, // 原箱数 |
| | | // null, // 原数量 |
| | | // null, // 原重量 |
| | |
| | | @TableField("loc_no") |
| | | private String locNo; |
| | | |
| | | @ApiModelProperty(value= "物料") |
| | | @ApiModelProperty(value= "产品") |
| | | @TableId(value = "matnr", type = IdType.INPUT) |
| | | private String matnr; |
| | | |
| | | @ApiModelProperty(value= "物料描述") |
| | | @ApiModelProperty(value= "产品描述") |
| | | private String maktx; |
| | | |
| | | @ApiModelProperty(value= "规格") |
| | | private String lgnum; |
| | | |
| | | @ApiModelProperty(value= "物料类别") |
| | | @ApiModelProperty(value= "产品类别") |
| | | private String type; |
| | | |
| | | @ApiModelProperty(value= "颜色") |
| | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 物料编码 |
| | | * 产品代号 |
| | | */ |
| | | @ApiModelProperty(value= "物料编码") |
| | | @ApiModelProperty(value= "产品代号") |
| | | @TableId(value = "mat_no", type = IdType.INPUT) |
| | | @TableField("mat_no") |
| | | private String matNo; |
| | |
| | | private String barcode; |
| | | |
| | | /** |
| | | * 物料名称 |
| | | * 产品名称 |
| | | */ |
| | | @ApiModelProperty(value= "物料名称") |
| | | @ApiModelProperty(value= "产品名称") |
| | | @TableField("mat_name") |
| | | private String matName; |
| | | |
| | | /** |
| | | * 物料单位 |
| | | * 基本单位 |
| | | */ |
| | | @ApiModelProperty(value= "物料单位") |
| | | @ApiModelProperty(value= "基本单位") |
| | | private String str1; |
| | | |
| | | @ApiModelProperty(value= "物料规格") |
| | | @ApiModelProperty(value= "规格型号") |
| | | private String str2; |
| | | |
| | | @ApiModelProperty(value= "颜色") |
| | | private String str3; |
| | | |
| | | @ApiModelProperty(value= "客户") |
| | | @ApiModelProperty(value= "库位名称") |
| | | private String str4; |
| | | |
| | | @ApiModelProperty(value= "") |
| | |
| | | @ApiModelProperty(value= "") |
| | | private String str23; |
| | | |
| | | @ApiModelProperty(value= "重量") |
| | | @ApiModelProperty(value= "") |
| | | private Double num1; |
| | | |
| | | @ApiModelProperty(value= "") |
| | |
| | | |
| | | // MatCode matCode = new MatCode( |
| | | // null, // 条码 |
| | | // null, // 物料名称 |
| | | // null, // 物料单位 |
| | | // null, // 物料规格 |
| | | // null, // 产品名称 |
| | | // null, // 基本单位 |
| | | // null, // 规格型号 |
| | | // null, // |
| | | // null, // |
| | | // null, // |
| | |
| | | public class MatCodePrint { |
| | | |
| | | /** |
| | | * 物料编码 |
| | | * 产品代号 |
| | | */ |
| | | private String matNo; |
| | | |
| | |
| | | private String barcode; |
| | | |
| | | /** |
| | | * 物料名称 |
| | | * 产品名称 |
| | | */ |
| | | private String matName; |
| | | |
| | | /** |
| | | * 物料单位 |
| | | * 基本单位 |
| | | */ |
| | | private String str1; |
| | | |
| | | /** |
| | | * 物料规格 |
| | | * 规格型号 |
| | | */ |
| | | private String str2; |
| | | |
| | |
| | | public class ViewStayTimeBean { |
| | | private int tbnum; //转储请求编号 |
| | | private int tbpos; //行项目 |
| | | private String zmatid; //物料标签ID |
| | | private String zmatid; //产品标签ID |
| | | |
| | | private String matnr; //物料 |
| | | private String maktx; //物料描述 |
| | | private String matnr; //产品 |
| | | private String maktx; //产品描述 |
| | | private String werks; //工厂 |
| | | private double anfme; //数量 |
| | | private String altme; //单位 |
| | |
| | | private String bname; //用户ID |
| | | |
| | | private String lgnum; //规格 |
| | | private String type; // 物料类别 |
| | | private String type; // 产品类别 |
| | | private String color; // 颜色 |
| | | private String supplier; // 供应商 |
| | | private String warehouse; // 仓库 |
| | | private String brand; // 品牌 |
| | | |
| | | private String loc_no; //库位号 |
| | | private String mat_no; //物料编码 |
| | | private String mat_no; //产品代号 |
| | | private Long ctns; //箱数 |
| | | private Long qty; //数量 |
| | | private double wt; //重量 |
| | | private String memo; //备注 |
| | | private String mat_name; //物料名称 |
| | | private String mat_name; //产品名称 |
| | | private String str1; |
| | | private String str2; |
| | | private String str3; |
| | |
| | | |
| | | private int tbnum; //转储请求编号 |
| | | private int tbpos; //行项目 |
| | | private String zmatid; //物料标签ID |
| | | private String zmatid; //产品标签ID |
| | | |
| | | private String matnr; //物料 |
| | | private String maktx; //物料描述 |
| | | private String matnr; //产品 |
| | | private String maktx; //产品描述 |
| | | private String werks; //工厂 |
| | | private double anfme; //数量 |
| | | private String altme; //单位 |
| | |
| | | private String bname; //用户ID |
| | | |
| | | private String lgnum; //规格 |
| | | private String type; // 物料类别 |
| | | private String type; // 产品类别 |
| | | private String color; // 颜色 |
| | | private String supplier; // 供应商 |
| | | private String warehouse; // 仓库 |
| | |
| | | private static final long serialVersionUID = 1L; |
| | | |
| | | /** |
| | | * 物料 |
| | | * 产品 |
| | | */ |
| | | @ApiModelProperty(value= "物料") |
| | | @ApiModelProperty(value= "产品") |
| | | private String matnr; |
| | | |
| | | /** |
| | | * 物料描述 |
| | | * 产品描述 |
| | | */ |
| | | @ApiModelProperty(value= "物料描述") |
| | | @ApiModelProperty(value= "产品描述") |
| | | private String maktx; |
| | | |
| | | |
| | |
| | | /** |
| | | * 仓库号 |
| | | */ |
| | | @ApiModelProperty(value= "物料类别") |
| | | @ApiModelProperty(value= "产品类别") |
| | | private String type; |
| | | |
| | | /** |
| | |
| | | /** |
| | | * 用户ID |
| | | */ |
| | | @ApiModelProperty(value= "用户ID") |
| | | @ApiModelProperty(value= "库位名称") |
| | | private String bname; |
| | | |
| | | @ApiModelProperty(value= "库位号") |
| | |
| | | |
| | | |
| | | /** |
| | | * 物料 |
| | | * 产品 |
| | | */ |
| | | @ApiModelProperty(value= "物料") |
| | | @ApiModelProperty(value= "产品") |
| | | private String matnr; |
| | | |
| | | /** |
| | | * 物料描述 |
| | | * 产品描述 |
| | | */ |
| | | @ApiModelProperty(value= "物料描述") |
| | | @ApiModelProperty(value= "产品描述") |
| | | private String maktx; |
| | | |
| | | |
| | |
| | | /** |
| | | * 仓库号 |
| | | */ |
| | | @ApiModelProperty(value= "物料类别") |
| | | @ApiModelProperty(value= "产品类别") |
| | | private String type; |
| | | |
| | | /** |
| | |
| | | private Date ioTime; |
| | | |
| | | /** |
| | | * 物料 |
| | | * 产品 |
| | | */ |
| | | @ApiModelProperty(value= "物料") |
| | | @ApiModelProperty(value= "产品") |
| | | private String matnr; |
| | | |
| | | /** |
| | | * 物料描述 |
| | | * 产品描述 |
| | | */ |
| | | @ApiModelProperty(value= "物料描述") |
| | | @ApiModelProperty(value= "产品描述") |
| | | private String maktx; |
| | | |
| | | |
| | |
| | | /** |
| | | * 仓库号 |
| | | */ |
| | | @ApiModelProperty(value= "物料类别") |
| | | @ApiModelProperty(value= "产品类别") |
| | | private String type; |
| | | |
| | | /** |
| | |
| | | private Date ioTime; |
| | | |
| | | /** |
| | | * 物料 |
| | | * 产品 |
| | | */ |
| | | @ApiModelProperty(value= "物料") |
| | | @ApiModelProperty(value= "产品") |
| | | private String matnr; |
| | | |
| | | /** |
| | | * 物料描述 |
| | | * 产品描述 |
| | | */ |
| | | @ApiModelProperty(value= "物料描述") |
| | | @ApiModelProperty(value= "产品描述") |
| | | private String maktx; |
| | | |
| | | |
| | |
| | | /** |
| | | * 仓库号 |
| | | */ |
| | | @ApiModelProperty(value= "物料类别") |
| | | @ApiModelProperty(value= "产品类别") |
| | | private String type; |
| | | |
| | | /** |
| | |
| | | |
| | | public static class CombMat { |
| | | |
| | | // 物料编号 |
| | | // 产品编号 |
| | | private String matNo; |
| | | |
| | | // 物料数量 |
| | | // 产品数量 |
| | | private Double count; |
| | | |
| | | public String getMatNo() { |
| | |
| | | // 站点编号 |
| | | private Integer devpNo; |
| | | |
| | | // 物料列表数据 |
| | | // 产品列表数据 |
| | | private List<MatCodeStore> list; |
| | | |
| | | public static class MatCodeStore { |
| | | |
| | | // 物料编号 |
| | | // 产品编号 |
| | | private String matNo; |
| | | |
| | | // 物料数量 |
| | | // 产品数量 |
| | | private Double count; |
| | | |
| | | public String getMatNo() { |
| | |
| | | |
| | | public static class LocDetlAdjust { |
| | | |
| | | // 物料号 |
| | | // 产品号 |
| | | private String matnr; |
| | | |
| | | // 变更数量 |
| | |
| | | // 出站口 |
| | | private Integer outSite; |
| | | |
| | | // 物料编号集合 |
| | | // 产品编号集合 |
| | | private List<LocDetl> locDetls; |
| | | |
| | | public Integer getOutSite() { |
| | |
| | | // 库位号 |
| | | private String locNo; |
| | | |
| | | // 物料号 |
| | | // 产品号 |
| | | private String matnr; |
| | | |
| | | // 数量 |
| | |
| | | |
| | | /** |
| | | * 获取当天相同规格货物的深库位号 |
| | | * @param matnr 物料号 |
| | | * @param matnr 产品号 |
| | | * @return locNo 库位号 |
| | | */ |
| | | List<String> getSameDetlToday(String matnr); |
| | |
| | | /** |
| | | * 出库作业 |
| | | * @param staNo 目标站点 |
| | | * @param locDetls 待出库物料 |
| | | * @param locDetls 待出库产品 |
| | | * @param ioType 入出库类型 |
| | | */ |
| | | void stockOut(BasDevp staNo, List<LocDetlDto> locDetls, Integer ioType, Long userId); |
| | |
| | | for (CombParam.CombMat combMat : param.getCombMats()) { |
| | | MatCode matCode = matCodeService.selectById(combMat.getMatNo()); |
| | | if (Cools.isEmpty(matCode)) { |
| | | throw new CoolException("物料数据错误"); |
| | | throw new CoolException("产品数据错误"); |
| | | } |
| | | WaitPakin waitPakin = new WaitPakin(); |
| | | waitPakin.setZpallet(param.getBarcode()); // 托盘码 |
| | |
| | | // 启动出库开始 101.出库 |
| | | stockOut(staNo, locDetlDtos, null, userId); |
| | | } else { |
| | | throw new CoolException("库位物料不存在"); |
| | | throw new CoolException("库位产品不存在"); |
| | | } |
| | | } |
| | | |
| | |
| | | // 启动出库开始 107.盘点出库 |
| | | stockOut(staNo, locDetlDtos, 107, userId); |
| | | } else { |
| | | throw new CoolException("库位物料不存在"); |
| | | throw new CoolException("库位产品不存在"); |
| | | } |
| | | } |
| | | |
| | |
| | | for (MatCodeCountDto dto : matCodeCountDtos) { |
| | | MatCode matCode = matCodeService.selectById(dto.getMatNo()); |
| | | if (Cools.isEmpty(matCode)){ |
| | | throw new CoolException("物料条码数据为空"); |
| | | throw new CoolException("产品条码数据为空"); |
| | | } |
| | | // 保持工作档明细 |
| | | WrkDetl wrkDetl = new WrkDetl(); |
| | |
| | | // 业务 ---------------------------------------------------------------------- |
| | | |
| | | public static void setWrkDetl(WrkDetl wrkDetl, MatCode matCode) { |
| | | wrkDetl.setMatnr(matCode.getMatNo()); // 物料编号 |
| | | wrkDetl.setMaktx(matCode.getMatName()); // 物料描述 |
| | | wrkDetl.setMatnr(matCode.getMatNo()); // 产品编号 |
| | | wrkDetl.setMaktx(matCode.getMatName()); // 产品描述 |
| | | wrkDetl.setLgnum(matCode.getStr2()); // 规格 |
| | | wrkDetl.setColor(matCode.getStr3()); // 助记码 |
| | | wrkDetl.setAltme(matCode.getStr1()); // 单位 |
| | | wrkDetl.setBname(matCode.getStr4()); // 客户 |
| | | wrkDetl.setBname(matCode.getStr4()); // 库位名称 |
| | | } |
| | | |
| | | public static void setWrkDetl(WrkDetl wrkDetl, LocDetl locDetl) { |
| | | wrkDetl.setMatnr(locDetl.getMatnr()); // 物料编号 |
| | | wrkDetl.setMaktx(locDetl.getMaktx()); // 物料描述 |
| | | wrkDetl.setMatnr(locDetl.getMatnr()); // 产品编号 |
| | | wrkDetl.setMaktx(locDetl.getMaktx()); // 产品描述 |
| | | wrkDetl.setLgnum(locDetl.getLgnum()); // 规格 |
| | | wrkDetl.setColor(locDetl.getColor()); // 助记码 |
| | | wrkDetl.setBname(locDetl.getBname()); // 客户 |
| | | 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.setMatnr(matCode.getMatNo()); // 产品编号 |
| | | locDetl.setMaktx(matCode.getMatName()); // 产品描述 |
| | | locDetl.setLgnum(matCode.getStr2()); // 规格 |
| | | locDetl.setColor(matCode.getStr3()); // 助记码 |
| | | locDetl.setBname(matCode.getStr4()); // 客户 |
| | | 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.setMatnr(wrkDetl.getMatnr()); // 产品编号 |
| | | locDetl.setMaktx(wrkDetl.getMaktx()); // 产品描述 |
| | | locDetl.setLgnum(wrkDetl.getLgnum()); // 规格 |
| | | locDetl.setColor(wrkDetl.getColor()); // 助记码 |
| | | locDetl.setBname(wrkDetl.getBname()); // 客户 |
| | | locDetl.setBname(wrkDetl.getBname()); // 库位名称 |
| | | locDetl.setAnfme(wrkDetl.getAnfme()); // 数量 |
| | | locDetl.setAltme(wrkDetl.getAltme()); // 单位 |
| | | locDetl.setZpallet(wrkDetl.getZpallet()); // 托盘条码 |
| | | } |
| | | |
| | | public static void setWaitPakIn(WaitPakin waitPakIn, MatCode matCode) { |
| | | waitPakIn.setMatnr(matCode.getMatNo()); // 物料编号 |
| | | waitPakIn.setMaktx(matCode.getMatName()); // 物料描述 |
| | | waitPakIn.setMatnr(matCode.getMatNo()); // 产品编号 |
| | | waitPakIn.setMaktx(matCode.getMatName()); // 产品描述 |
| | | waitPakIn.setLgnum(matCode.getStr2()); // 规格 |
| | | waitPakIn.setColor(matCode.getStr3()); // 助记码 |
| | | waitPakIn.setAltme(matCode.getStr1()); // 单位 |
| | | waitPakIn.setBname(matCode.getStr4()); // 客户 |
| | | waitPakIn.setBname(matCode.getStr4()); // 库位名称 |
| | | } |
| | | |
| | | // excel ---------------------------------------------------------------------- |
| | |
| | | * @param whsType 类型 1:双深式货架 |
| | | * @param staDescId 路径ID |
| | | * @param sourceStaNo 源站 |
| | | * @param matNos 物料号集合 |
| | | * @param matNos 产品号集合 |
| | | * @return locNo 检索到的库位号 |
| | | */ |
| | | public StartupDto getLocNo(Integer whsType, Integer staDescId, Integer sourceStaNo, List<String> matNos) { |
| | |
| | | // } |
| | | // } |
| | | |
| | | // 如果没有相近物料,则按规则轮询货架 |
| | | // 如果没有相近产品,则按规则轮询货架 |
| | | if (null == locMast) { |
| | | // 获取目标站所在货架排号 todo:luxiaotao |
| | | if (curRow == sRow) { |
| | |
| | | } |
| | | |
| | | } |
| | | // 对于通过多个代理的情况,第一个IP为客户端真实IP,多个IP按照','分割"***.***.***.***".length()=15 |
| | | // 对于通过多个代理的情况,第一个IP为库位名称端真实IP,多个IP按照','分割"***.***.***.***".length()=15 |
| | | if (ipAddress != null && ipAddress.length() > 15) { |
| | | |
| | | if (ipAddress.indexOf(",") > 0) { |
| | |
| | | package com.zy.common.utils.excel.matcode; |
| | | |
| | | import com.alibaba.excel.annotation.ExcelIgnoreUnannotated; |
| | | import com.alibaba.excel.annotation.ExcelProperty; |
| | | import lombok.Data; |
| | | |
| | | /** |
| | | * 0.A 1.B 2.C 3.D 4.E 5.F 6.G 7.H 8.I |
| | | * 9.J 10.K 11.L 12.M 13.N 14.O 15.P 16.Q 17.R 18.S |
| | | * 19.T 20.U 21.V 22.W 23.X 24.Y 25.Z |
| | | */ |
| | | @Data |
| | | @ExcelIgnoreUnannotated |
| | | public class MatCodeExcel { |
| | | |
| | | @ExcelProperty(value= "物料编码", index = 1) |
| | | @ExcelProperty(value= "产品代号*", index = 0) |
| | | private String matNo; |
| | | |
| | | @ExcelProperty(value= "条形码", index = 4) |
| | | // @ExcelProperty(value= "条形码", index = 4) |
| | | private String barcode; |
| | | |
| | | @ExcelProperty(value= "物料名称", index = 2) |
| | | @ExcelProperty(value= "产品名称", index = 3) |
| | | private String matName; |
| | | |
| | | @ExcelProperty(value= "物料单位", index = 8) |
| | | @ExcelProperty(value= "基本单位", index = 12) |
| | | private String str1; |
| | | |
| | | @ExcelProperty(value= "物料规格", index = 3) |
| | | @ExcelProperty(value= "规格型号", index = 5) |
| | | private String str2; |
| | | |
| | | @ExcelProperty(value= "颜色", index = 5) |
| | | @ExcelProperty(value= "颜色名称", index = 28) |
| | | private String str3; |
| | | |
| | | @ExcelProperty(value= "客户", index = 6) |
| | | @ExcelProperty(value= "库位名称", index = 14) |
| | | private String str4; |
| | | |
| | | // @ExcelProperty(value= "助记码", index = 7) |
| | |
| | | // @ExcelProperty(value= "销售单位", index = 31) |
| | | private String str23; |
| | | |
| | | @ExcelProperty(value= "重量", index = 7) |
| | | // @ExcelProperty(value= "重量", index = 7) |
| | | private Double num1; |
| | | |
| | | // @ExcelProperty(value= "最低库存数量") |
| | |
| | | this.num6 = num6; |
| | | } |
| | | |
| | | 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; |
| | | } |
| | | } |
| | |
| | | */ |
| | | @Override |
| | | public void doAfterAllAnalysed(AnalysisContext ctx) { |
| | | LOGGER.info("新增{}条物料信息!", total); |
| | | LOGGER.info("新增{}条产品信息!", total); |
| | | } |
| | | |
| | | public int getTotal() { |
| | |
| | | } |
| | | |
| | | @RequestMapping(value = "/barcode/qrcode/auth") |
| | | // @ManagerAuth(memo = "物料编码条形码获取(type:1(条形码);2(二维码)") |
| | | // @ManagerAuth(memo = "产品代号条形码获取(type:1(条形码);2(二维码)") |
| | | public R matCodeBarcode(@RequestParam(defaultValue = "1") Integer type |
| | | , @RequestParam String param |
| | | , @RequestParam(required = false) Integer width |
| | |
| | | private Long userId; |
| | | |
| | | /** |
| | | * 客户端IP |
| | | * 库位名称端IP |
| | | */ |
| | | private String ip; |
| | | |
| | |
| | | goto re; |
| | | } |
| | | |
| | | ///根据工作号,查询工作明细档物料编码 |
| | | ///根据工作号,查询工作明细档产品代号 |
| | | string sqlDetl = ""; |
| | | string sqlWaitIn = ""; |
| | | sql = "select lgnum,tbnum,tbpos,zmatid,matnr,maktx,werks,anfme,altme,zpallet,bname from asr_wrk_detl where wrk_no=" + li_wrk_no; |
| | |
| | | #endregion |
| | | #region 拣料再入库 |
| | | case 53: |
| | | ///根据工作号,查询工作明细档物料编码 |
| | | ///根据工作号,查询工作明细档产品代号 |
| | | sqlDetl = ""; |
| | | sqlWaitIn = ""; |
| | | sql = "select lgnum,tbnum,tbpos,zmatid,matnr,maktx,werks,anfme,altme,zpallet,bname from asr_wrk_detl where wrk_no=" + li_wrk_no; |
| | |
| | | #endregion |
| | | #region 并板再入库 |
| | | case 54: |
| | | ///根据工作号,查询工作明细档物料编码 |
| | | ///根据工作号,查询工作明细档产品代号 |
| | | sqlDetl = ""; |
| | | sqlWaitIn = ""; |
| | | sql = "select lgnum,tbnum,tbpos,zmatid,matnr,maktx,werks,anfme,altme,zpallet,bname from asr_wrk_detl where wrk_no=" + li_wrk_no; |
| | |
| | | #endregion |
| | | #region 盘点再入库 |
| | | case 57: |
| | | ///根据工作号,查询工作明细档物料编码 |
| | | ///根据工作号,查询工作明细档产品代号 |
| | | sqlDetl = ""; |
| | | sqlWaitIn = ""; |
| | | sql = "select lgnum,tbnum,tbpos,matnr from asr_wrk_detl where wrk_no=" + li_wrk_no; |
| | |
| | | { |
| | | #region 全板出库 |
| | | case 101: |
| | | ///根据工作号,查询工作明细档物料编码 |
| | | ///根据工作号,查询工作明细档产品代号 |
| | | string sqlWaitIn = ""; |
| | | sql = "select lgnum,tbnum,tbpos,matnr from asr_wrk_detl where wrk_no=" + li_wrk_no; |
| | | DataView dv_wrkdetl = Common.ExecAsrsSelect(sql); |
| | |
| | | } |
| | | |
| | | /// <summary> |
| | | /// 转已完成物料信息到历史档 |
| | | /// 转已完成产品信息到历史档 |
| | | /// </summary> |
| | | public void ProcMatCodeToLog(string seq) |
| | | { |
| | | string ls_error_memo = "", mat_no = ""; |
| | | DisplayInfo(seq, "N", "--处理已完成物料数据转历史档......"); |
| | | DisplayInfo(seq, "N", "--处理已完成产品数据转历史档......"); |
| | | try |
| | | { |
| | | string condition = " and mat_no not in (select mat_no from asr_loc_detl) and mat_no not in (select mat_no from asr_wrk_detl) "; |
| | |
| | | DataView dv = Common.ExecAsrsSelect(sql0); |
| | | if (dv.Count <= 0) |
| | | { |
| | | DisplayInfo("", "N", " " + seq + ".1 物料档 [bas_mat_code] 没有资料处理!"); |
| | | DisplayInfo("", "N", " " + seq + ".1 产品档 [bas_mat_code] 没有资料处理!"); |
| | | return; |
| | | } |
| | | |
| | |
| | | { |
| | | sqltrans.Rollback(); |
| | | //sqlcommon.Close(); |
| | | ls_error_memo = " " + seq + ".1 已完成物料数据转历史档错误 ! 异常:" + t.Message; |
| | | ls_error_memo = " " + seq + ".1 已完成产品数据转历史档错误 ! 异常:" + t.Message; |
| | | DisplayInfo("", "E", ls_error_memo); |
| | | } |
| | | finally |
| | |
| | | } |
| | | catch (Exception t) |
| | | { |
| | | ls_error_memo = " " + seq + ".2 已完成物料数据转历史档失败! 异常:" + t.Message; |
| | | ls_error_memo = " " + seq + ".2 已完成产品数据转历史档失败! 异常:" + t.Message; |
| | | DisplayInfo("", "E", ls_error_memo); |
| | | } |
| | | } |
| | |
| | | { |
| | | sqltrans1.Rollback(); |
| | | //sqlcommon.Close(); |
| | | ls_error_memo = " " + seq + ".1 已完成物料数据转历史档错误 ! 异常:" + t.Message; |
| | | ls_error_memo = " " + seq + ".1 已完成产品数据转历史档错误 ! 异常:" + t.Message; |
| | | DisplayInfo("", "E", ls_error_memo); |
| | | } |
| | | finally |
| | |
| | | //堆垛机&PLC命令转历史档 |
| | | ProcDevCommandToLog("4"); // done |
| | | |
| | | //转已完成物料信息到历史档 |
| | | //转已完成产品信息到历史档 |
| | | //ProcMatCodeToLog("5"); |
| | | //转出库完成待出库档数据到历史档 |
| | | ProcCheckToWorkData("5"); |
| | |
| | | # password: xltys1995 |
| | | servlet: |
| | | multipart: |
| | | maxFileSize: 10MB |
| | | maxFileSize: 100MB |
| | | maxRequestSize: 100MB |
| | | |
| | | mybatis-plus: |
| | |
| | | // ,{field: 'id', title: 'ID', sort: true,align: 'center', fixed: 'left', width: 80} |
| | | // {field: 'adjId', align: 'center',title: '序号'} |
| | | {field: 'locNo$', align: 'center',title: '库位号'} |
| | | ,{field: 'matNo$', align: 'center',title: '物料编号'} |
| | | ,{field: 'matNo$', align: 'center',title: '产品编号'} |
| | | // ,{field: 'oriCtns', align: 'center',title: '原箱数'} |
| | | ,{field: 'oriQty', align: 'center',title: '原数量'} |
| | | // ,{field: 'oriWt', align: 'center',title: '原重量'} |
| | |
| | | }(this); |
| | | |
| | | /*************************************************************************************************************/ |
| | | /********************************************** 物料业务抽象 ***************************************************/ |
| | | /********************************************** 产品业务抽象 ***************************************************/ |
| | | /*************************************************************************************************************/ |
| | | |
| | | function arrRemove(arr, key, val) { |
| | |
| | | } |
| | | |
| | | var matCols = [ |
| | | {field: 'matNo', align: 'center',title: '物料编码'} |
| | | ,{field: 'matName', align: 'center',title: '物料名称'} |
| | | ,{field: 'str2', align: 'center',title: '物料规格'} |
| | | {field: 'matNo', align: 'center',title: '产品代号'} |
| | | ,{field: 'matName', align: 'center',title: '产品名称'} |
| | | ,{field: 'str2', align: 'center',title: '规格型号'} |
| | | ,{field: 'str3', align: 'center',title: '颜色'} |
| | | ,{field: 'num1', align: 'center',title: '数量'} |
| | | ,{field: 'str1', align: 'center',title: '物料单位'} |
| | | ,{field: 'str4', align: 'center',title: '客户'} |
| | | // ,{field: 'num1', align: 'center',title: '数量'} |
| | | ,{field: 'str1', align: 'center',title: '基本单位'} |
| | | ,{field: 'str4', align: 'center',title: '库位名称'} |
| | | ] |
| | | |
| | | var detlCols = [ |
| | | {field: 'matnr', align: 'center',title: '物料号'} |
| | | ,{field: 'maktx', align: 'center',title: '物料名称'} |
| | | {field: 'matnr', align: 'center',title: '产品号'} |
| | | ,{field: 'maktx', align: 'center',title: '产品名称'} |
| | | ,{field: 'lgnum', align: 'center',title: '规格'} |
| | | ,{field: 'color', align: 'center',title: '颜色'} |
| | | ,{field: 'anfme', align: 'center',title: '数量'} |
| | | // ,{field: 'anfme', align: 'center',title: '数量'} |
| | | ,{field: 'altme', align: 'center',title: '单位'} |
| | | ,{field: 'zpallet', align: 'center',title: '托盘条码'} |
| | | ,{field: 'bname', align: 'center',title: '客户'} |
| | | ,{field: 'bname', align: 'center',title: '库位名称'} |
| | | ] |
| | | |
| | |
| | | {type: 'checkbox'} |
| | | ,{field: 'wrkNo', align: 'center',title: '工作号'} |
| | | ,{field: 'ioTime$', align: 'center',title: '工作时间'} |
| | | ,{field: 'matnr', align: 'center',title: '物料'} |
| | | ,{field: 'matnr', align: 'center',title: '产品'} |
| | | ,{field: 'lgnum', align: 'center',title: '仓库号'} |
| | | ,{field: 'tbnum', align: 'center',title: '转储请求编号'} |
| | | ,{field: 'tbpos', align: 'center',title: '行项目'} |
| | | ,{field: 'zmatid', align: 'center',title: '物料标签ID'} |
| | | ,{field: 'maktx', align: 'center',title: '物料描述'} |
| | | ,{field: 'zmatid', align: 'center',title: '产品标签ID'} |
| | | ,{field: 'maktx', align: 'center',title: '产品描述'} |
| | | ,{field: 'werks', align: 'center',title: '工厂'} |
| | | ,{field: 'anfme', align: 'center',title: '数量'} |
| | | ,{field: 'altme', align: 'center',title: '单位'} |
| | |
| | | {field: 'id', title: 'ID', sort: true,align: 'center', width: 80} |
| | | ,{field: 'userId$', align: 'center',title: '用户'} |
| | | ,{field: 'action', align: 'center',title: '操作内容'} |
| | | ,{field: 'ip', align: 'center',title: '客户端IP'} |
| | | ,{field: 'ip', align: 'center',title: '库位名称端IP'} |
| | | ,{field: 'request', align: 'center',title: '请求数据'} |
| | | ,{field: 'response', align: 'center',title: '响应数据'} |
| | | ,{field: 'createTime$', align: 'center',title: '添加时间'} |
| | |
| | | switch (obj.event) { |
| | | case 'outbound': |
| | | if (data.length === 0){ |
| | | layer.msg('请先添加库位物料'); |
| | | layer.msg('请先添加库位产品'); |
| | | } else { |
| | | var staNo = $("#staNoSelect").val(); |
| | | if (staNo === "" || staNo === null){ |
| | |
| | | } |
| | | }) |
| | | |
| | | // 提取物料 |
| | | // 提取产品 |
| | | var locDetlLayerIdx; |
| | | function getLocDetl() { |
| | | locDetlLayerIdx = layer.open({ |
| | |
| | | |
| | | }); |
| | | |
| | | // 搜索库位物料 |
| | | // 搜索库位产品 |
| | | function getLoc(el) { |
| | | tableIns.reload({ |
| | | url: baseUrl+'/locDetl/list/auth' |
| | |
| | | var data = checkStatus.data; |
| | | switch(obj.event) { |
| | | case 'comb': |
| | | // 判断是否存在物料 |
| | | // 判断是否存在产品 |
| | | if (matCodeData.length === 0) { |
| | | layer.msg("请先添加物料"); |
| | | layer.msg("请先添加产品"); |
| | | return; |
| | | } |
| | | // 判断物料数量是否存在异常 |
| | | // 判断产品数量是否存在异常 |
| | | for (var i=0;i<matCodeData.length;i++){ |
| | | if (isNaN(matCodeData[i].count)) { |
| | | layer.msg("请输入数字"); |
| | |
| | | |
| | | }); |
| | | |
| | | // 提取物料 |
| | | // 提取产品 |
| | | var matCodeLayerIdx; |
| | | function getMat() { |
| | | matCodeLayerIdx = layer.open({ |
| | | type: 2, |
| | | title: '提取物料', |
| | | title: '提取产品', |
| | | maxmin: true, |
| | | area: [top.detailWidth, top.detailHeight], |
| | | shadeClose: true, |
| | |
| | | return; |
| | | } |
| | | if (matCodeData.length === 0) { |
| | | layer.msg("请先添加物料"); |
| | | layer.msg("请先添加产品"); |
| | | return; |
| | | } |
| | | for (var i=0;i<matCodeData.length;i++){ |
| | |
| | | } |
| | | }) |
| | | |
| | | // 提取物料 |
| | | // 提取产品 |
| | | var matCodeLayerIdx; |
| | | function getMat() { |
| | | if (isEmpty(currLocNo)) { |
| | |
| | | } |
| | | matCodeLayerIdx = layer.open({ |
| | | type: 2, |
| | | title: '提取物料', |
| | | title: '提取产品', |
| | | maxmin: true, |
| | | area: [top.detailWidth, top.detailHeight], |
| | | shadeClose: true, |
| | |
| | | switch (obj.event) { |
| | | case 'outbound': |
| | | if (data.length === 0){ |
| | | layer.msg('请先添加库位物料'); |
| | | layer.msg('请先添加库位产品'); |
| | | } else { |
| | | var staNo = $("#staNoSelect").val(); |
| | | if (staNo === "" || staNo === null){ |
| | |
| | | } |
| | | }) |
| | | |
| | | // 提取物料 |
| | | // 提取产品 |
| | | var locDetlLayerIdx; |
| | | function getLocDetl() { |
| | | locDetlLayerIdx = layer.open({ |
| | |
| | | } else { |
| | | layer.open({ |
| | | type: 2, |
| | | title: '库位物料', |
| | | title: '库位产品', |
| | | maxmin: true, |
| | | area: [top.detailWidth, top.detailHeight], |
| | | shadeClose: true, |
| | |
| | | || data.locSts.trim() === 'S' |
| | | || data.locSts.trim() === 'D' |
| | | || data.locSts.trim() === 'O') { |
| | | layer.msg("此库位的状态不存在物料"); |
| | | layer.msg("此库位的状态不存在产品"); |
| | | return; |
| | | } |
| | | locDetlToLayer(data.locNo); |
| | |
| | | } |
| | | }); |
| | | |
| | | // iframe物料详情 |
| | | // iframe产品详情 |
| | | function locDetlToLayer(val) { |
| | | locNo = val; |
| | | layer.open({ |
| | |
| | | } |
| | | }); |
| | | } |
| | | // div物料详情 |
| | | // div产品详情 |
| | | var pageCur; |
| | | function locDetl(locNo){ |
| | | $('#detlTable').css("display", 'block'); |
| | |
| | | cols: [[ |
| | | // {type: 'checkbox'} |
| | | {field: 'locNo$', align: 'center',title: '库位号'} |
| | | ,{field: 'matnr', align: 'center',title: '物料'} |
| | | ,{field: 'matnr', align: 'center',title: '产品'} |
| | | ,{field: 'lgnum', align: 'center',title: '仓库号'} |
| | | ,{field: 'tbnum', align: 'center',title: '转储请求编号'} |
| | | // ,{field: 'tbpos', align: 'center',title: '行项目'} |
| | | ,{field: 'zmatid', align: 'center',title: '物料标签ID'} |
| | | ,{field: 'maktx', align: 'center',title: '物料描述'} |
| | | ,{field: 'zmatid', align: 'center',title: '产品标签ID'} |
| | | ,{field: 'maktx', align: 'center',title: '产品描述'} |
| | | ,{field: 'werks', align: 'center',title: '工厂'} |
| | | ,{field: 'anfme', align: 'center',title: '数量'} |
| | | ,{field: 'altme', align: 'center',title: '单位'} |
| | |
| | | {type: 'checkbox'} |
| | | ,{field: 'wrkNo', align: 'center',title: '工作号'} |
| | | ,{field: 'ioTime$', align: 'center',title: '工作时间'} |
| | | ,{field: 'matnr', align: 'center',title: '物料'} |
| | | ,{field: 'matnr', align: 'center',title: '产品'} |
| | | ,{field: 'lgnum', align: 'center',title: '仓库号'} |
| | | ,{field: 'tbnum', align: 'center',title: '转储请求编号'} |
| | | ,{field: 'tbpos', align: 'center',title: '行项目'} |
| | | ,{field: 'zmatid', align: 'center',title: '物料标签ID'} |
| | | ,{field: 'maktx', align: 'center',title: '物料描述'} |
| | | ,{field: 'zmatid', align: 'center',title: '产品标签ID'} |
| | | ,{field: 'maktx', align: 'center',title: '产品描述'} |
| | | ,{field: 'werks', align: 'center',title: '工厂'} |
| | | ,{field: 'anfme', align: 'center',title: '数量'} |
| | | ,{field: 'altme', align: 'center',title: '单位'} |
| | |
| | | ,"spread": true |
| | | ,"list": [{ |
| | | "name": "list" |
| | | ,"title": "物料列表" |
| | | ,"title": "产品列表" |
| | | },{ |
| | | "name": "category" |
| | | ,"title": "分类管理" |
| | |
| | | .cmdlist-text .flow{text-align: right;float: right;} |
| | | #demo0{text-align: center;} |
| | | |
| | | /* 物料列表 */ |
| | | /* 产品列表 */ |
| | | .layadmin-message-fluid .layui-col-md12{background: #fff;height: auto;padding-bottom: 50px;} |
| | | .layadmin-message-fluid .layui-input-block{margin-left: 0;} |
| | | .layadmin-message-fluid .layui-form{padding:45px 40px 0 40px;} |
| | |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="mat_no" placeholder="物料编号" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="mat_no" placeholder="产品编号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <!-- 日期范围 --> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label"><span class="not-null">*</span>物料编号:</label> |
| | | <label class="layui-form-label"><span class="not-null">*</span>产品编号:</label> |
| | | <div class="layui-input-inline cool-auto-complete"> |
| | | <input id="matNo" class="layui-input" type="text" lay-verify="required" style="display: none"> |
| | | <input id="matNo$" class="layui-input cool-auto-complete-div" onclick="autoShow(this.id)" type="text" placeholder="请输入..." onfocus=this.blur()> |
| | |
| | | <!--明细表--> |
| | | <div id="detlTable" style="display: none"> |
| | | <div class="layui-inline" style="width:90%;margin-top: 10px;margin-left: 20px"> |
| | | <span style=" color: indianred">以下为当前工作流的物料明细</span> |
| | | <span style=" color: indianred">以下为当前工作流的产品明细</span> |
| | | </div> |
| | | |
| | | <table class="layui-hide" id="wrkDetlByMap" lay-filter="wrkDetlByMap"></table> |
| | |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="物料编码" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="产品代号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;display: none"> |
| | | <label class="layui-form-label" style="font-size: x-small">物料标签ID:</label> |
| | | <label class="layui-form-label" style="font-size: x-small">产品标签ID:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="zmatid" class="layui-input" type="text" > |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label">物料描述:</label> |
| | | <label class="layui-form-label">产品描述:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="maktx" class="layui-input" type="text"> |
| | | </div> |
| | |
| | | <div id="search-box" class="layui-form layui-card-header"> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="mat_no" placeholder="物料编码" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="mat_no" placeholder="产品代号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <!-- 日期范围 --> |
| | |
| | | <div id="template-preview-1" class="template-preview" style="display: inline-block"> |
| | | <table class="contain" width="280" style="overflow: hidden;font-size: xx-small;table-layout: fixed;"> |
| | | <tr style="height: 74px"> |
| | | <td colspan="3" align="center" scope="col">物料编码</td> |
| | | <td colspan="3" align="center" scope="col">产品代号</td> |
| | | <td class="barcode" colspan="9" align="center" scope="col"> |
| | | <img class="template-code template-barcode" src="" width="90%;"> |
| | | <div style="letter-spacing: 2px;margin-top: 1px; text-align: center;"> |
| | |
| | | </td> |
| | | </tr> |
| | | <tr style="height: 74px"> |
| | | <td align="center" colspan="3">物料名称</td> |
| | | <td align="center" colspan="3">产品名称</td> |
| | | <td align="center" colspan="5">xxxxxx-xx/xx</td> |
| | | <td align="center" colspan="2">单位</td> |
| | | <td align="center" colspan="2">xx</td> |
| | |
| | | <div id="template-preview-2" class="template-preview" style="display: none"> |
| | | <table class="contain" width="280" style="overflow: hidden;font-size: xx-small;table-layout: fixed;"> |
| | | <tr style="height: 30px"> |
| | | <td align="center" width="20%">物料名称</td> |
| | | <td align="center" width="20%">产品名称</td> |
| | | <td align="center" width="80%" style="overflow:hidden; white-space:nowrap; text-overflow:ellipsis;">xxxxxxx</td> |
| | | </tr> |
| | | <tr style="height: 30px"> |
| | | <td align="center" width="20%">物料单位</td> |
| | | <td align="center" width="20%">基本单位</td> |
| | | <td align="center" width="80%">xxxxxxxx</td> |
| | | </tr> |
| | | <tr style="height: 75px;"> |
| | |
| | | <div id="template-preview-3" class="template-preview" style="display: none"> |
| | | <table class="contain" width="280" style="overflow: hidden;font-size: xx-small;table-layout: fixed;"> |
| | | <tr style="height: 74px"> |
| | | <td align="center" scope="col" colspan="1">物料名称</td> |
| | | <td align="center" scope="col" colspan="1">产品名称</td> |
| | | <td align="center" scope="col" colspan="1" style="">xxxxxx-xx/xx</td> |
| | | <td align="center" scope="col" colspan="2" rowspan="2"> |
| | | <img class="template-code template-qrcode" src="" width="80%"> |
| | |
| | | </td> |
| | | </tr> |
| | | <tr style="height: 74px"> |
| | | <td align="center" colspan="1">物料单位</td> |
| | | <td align="center" colspan="1">基本单位</td> |
| | | <td align="center" colspan="1" style="overflow:hidden; white-space:nowrap; text-overflow:ellipsis;">xxxxxxx</td> |
| | | </tr> |
| | | </table> |
| | |
| | | {{#each data}} |
| | | <table class="contain" width="280" style="overflow: hidden;font-size: small;table-layout: fixed;"> |
| | | <tr style="height: 74px"> |
| | | <td align="center" colspan="3" scope="col">物料编码</td> |
| | | <td align="center" colspan="3" scope="col">产品代号</td> |
| | | <td align="center" class="barcode" colspan="9" scope="col"> |
| | | <img class="template-code" src="{{this.barcodeUrl}}" width="90%"> |
| | | <div style="letter-spacing: 2px;margin-top: 1px; text-align: center"> |
| | |
| | | </td> |
| | | </tr> |
| | | <tr style="height: 74px"> |
| | | <td align="center" colspan="3">物料名称</td> |
| | | <td align="center" colspan="3">产品名称</td> |
| | | <td align="center" colspan="5" style="overflow: hidden; white-space: nowrap;text-overflow: ellipsis;">{{this.matName}}</td> |
| | | <td align="center" colspan="2">单位</td> |
| | | <td align="center" colspan="2">{{this.str1}}</td> |
| | |
| | | {{#each data}} |
| | | <table class="contain" width="280" style="overflow: hidden;font-size: xx-small;table-layout: fixed;"> |
| | | <tr style="height: 35px"> |
| | | <td align="center" width="20%">物料名称</td> |
| | | <td align="center" width="20%">产品名称</td> |
| | | <td align="center" width="80%" style="overflow:hidden; white-space:nowrap; text-overflow:ellipsis;">{{this.matName}}</td> |
| | | </tr> |
| | | <tr style="height: 35px"> |
| | | <td align="center" width="20%">物料单位</td> |
| | | <td align="center" width="20%">基本单位</td> |
| | | <td align="center" width="80%">{{this.str1}}</td> |
| | | </tr> |
| | | <tr style="height: 79px;"> |
| | |
| | | {{#each data}} |
| | | <table class="contain" width="280" style="overflow: hidden;font-size: xx-small;table-layout: fixed;"> |
| | | <tr style="height: 74px" > |
| | | <td align="center" scope="col" colspan="1">物料名称</td> |
| | | <td align="center" scope="col" colspan="1">产品名称</td> |
| | | <td align="center" scope="col" colspan="1" style=" |
| | | display: inline-block; |
| | | line-height: 20px; |
| | |
| | | </td> |
| | | </tr> |
| | | <tr style="height: 74px"> |
| | | <td align="center" colspan="1">物料单位</td> |
| | | <td align="center" colspan="1">基本单位</td> |
| | | <td align="center" colspan="1" style="overflow:hidden; white-space:nowrap; text-overflow:ellipsis;">{{this.str1}}</td> |
| | | </tr> |
| | | </table> |
| | |
| | | </div> |
| | | --> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label"><span class="not-null">*</span>物料编码:</label> |
| | | <label class="layui-form-label"><span class="not-null">*</span>产品代号:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="matNo" class="layui-input" type="text" onkeyup="check(this.id, 'matCode')" lay-verify="required" > |
| | | </div> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label">物料名称:</label> |
| | | <label class="layui-form-label">产品名称:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="matName" class="layui-input" type="text"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label">物料单位:</label> |
| | | <label class="layui-form-label">基本单位:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="str1" class="layui-input" type="text"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;display: none"> |
| | | <label class="layui-form-label">物料规格:</label> |
| | | <label class="layui-form-label">规格型号:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="str2" class="layui-input" type="text"> |
| | | </div> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label"><span class="not-null">*</span>客户端IP:</label> |
| | | <label class="layui-form-label"><span class="not-null">*</span>库位名称端IP:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="ip" class="layui-input" type="text" placeholder="客户端IP" lay-verify="required" > |
| | | <input id="ip" class="layui-input" type="text" placeholder="库位名称端IP" lay-verify="required" > |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="物料号" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="产品号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="maktx" placeholder="物料描述" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="maktx" placeholder="产品描述" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <!-- 日期范围 --> |
| | |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="物料号" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="产品号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="maktx" placeholder="物料描述" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="maktx" placeholder="产品描述" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <!-- 日期范围 --> |
| | |
| | | <div id="search-box" class="layui-form layui-card-header"> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="mat_no" placeholder="物料编码" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="mat_no" placeholder="产品代号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <!-- 日期范围 --> |
| | |
| | | var layer = layui.layer; |
| | | var layDate = layui.laydate; |
| | | var form = layui.form; |
| | | // 物料查询数据表 |
| | | // 产品查询数据表 |
| | | matQueryTable = table.render({ |
| | | elem: '#matCode', |
| | | headers: {token: localStorage.getItem('token')}, |
| | |
| | | cellMinWidth: 50, |
| | | cols: [[ |
| | | {fixed: 'left', align: 'center', field: 'count', title: '数量', style:'color: blue', width:50}, |
| | | {field: 'matNo', align: 'center', title: '物料编码'}, |
| | | {field: 'matName', align: 'center', title: '物料名称'} |
| | | {field: 'matNo', align: 'center', title: '产品代号'}, |
| | | {field: 'matName', align: 'center', title: '产品名称'} |
| | | ]], |
| | | done: function (res, curr, count) { |
| | | } |
| | |
| | | function getMat() { |
| | | matCodeLayerIdx = layer.open({ |
| | | type: 2, |
| | | title: '提取物料', |
| | | title: '提取产品', |
| | | shade: [0.3,'#000'], |
| | | area: ['90%', '80%'], |
| | | content: 'matQuery.html', |
| | |
| | | return; |
| | | } |
| | | if (matData.length === 0) { |
| | | tips("请提取物料", true); |
| | | tips("请提取产品", true); |
| | | return; |
| | | } |
| | | $.ajax({ |
| | |
| | | <input id="locNo" type="text" disabled="disabled"> |
| | | </div> |
| | | <div class="form-item"> |
| | | <span>物料编码</span> |
| | | <span>产品代号</span> |
| | | <input id="matnr" type="text" disabled="disabled"> |
| | | </div> |
| | | <div class="form-item"> |
| | | <span>物料名称</span> |
| | | <span>产品名称</span> |
| | | <input id="maktx" type="text" disabled="disabled"> |
| | | </div> |
| | | <div class="form-item"> |
| | |
| | | <head> |
| | | <meta charset="UTF-8"> |
| | | <meta name="viewport" content="width=device-width, target-densitydpi=high-dpi, initial-scale=1.0, user-scalable=no"/> |
| | | <title>物料提取</title> |
| | | <title>产品提取</title> |
| | | <link rel="stylesheet" href="../../static/layui/css/layui.css" media="all"> |
| | | <script type="text/javascript" src="../../static/js/jquery/jquery-3.3.1.min.js"></script> |
| | | <script type="text/javascript" src="../../static/layui/layui.js" charset="utf-8"></script> |
| | |
| | | |
| | | <div class="form-box"> |
| | | <div class="form-item"> |
| | | <span>物料编码</span> |
| | | <span>产品代号</span> |
| | | <input id="matNo" type="text" placeholder="扫码 / 输入" onkeyup="find(this)" autocomplete="off"> |
| | | </div> |
| | | <div class="form-item"> |
| | | <span>物料名称</span> |
| | | <span>产品名称</span> |
| | | <input id="matName" type="text" disabled="disabled"> |
| | | </div> |
| | | <div class="form-item"> |
| | | <span>物料规格</span> |
| | | <span>规格型号</span> |
| | | <input id="str2" type="text" disabled="disabled"> |
| | | </div> |
| | | <div class="form-item"> |
| | |
| | | var pageCurr; |
| | | |
| | | /** |
| | | * 根据物料编码查询物料详情 |
| | | * 根据产品代号查询产品详情 |
| | | */ |
| | | function find(el){ |
| | | if (isEmpty(el.value)) { |
| | |
| | | cellMinWidth: 50, |
| | | cols: [[ |
| | | {fixed: 'left', align: 'center', field: 'count', title: '数量', style:'color: blue', width:50}, |
| | | {field: 'matNo', align: 'center', title: '物料编码'}, |
| | | {field: 'matName', align: 'center', title: '物料名称'} |
| | | {field: 'matNo', align: 'center', title: '产品代号'}, |
| | | {field: 'matName', align: 'center', title: '产品名称'} |
| | | ]], |
| | | done: function (res, curr, count) { |
| | | |
| | |
| | | }) |
| | | } |
| | | |
| | | // 提取物料 |
| | | // 提取产品 |
| | | var matCodeLayerIdx; |
| | | function getMat() { |
| | | matCodeLayerIdx = layer.open({ |
| | | type: 2, |
| | | title: '物料', |
| | | title: '产品', |
| | | shade: [0.3,'#000'], |
| | | area: ['90%', '80%'], |
| | | content: 'matQuery.html', |
| | |
| | | return; |
| | | } |
| | | if (matData.length === 0) { |
| | | tips("请提取物料", true); |
| | | tips("请提取产品", true); |
| | | return; |
| | | } |
| | | // var site = $('input:radio[name="site"]:checked').next("span").html(); |
| | |
| | | |
| | | </div> |
| | | <div class="layui-input-inline"> |
| | | <label class="layui-form-label">物料</label> |
| | | <label class="layui-form-label">产品</label> |
| | | <div class="layui-input-block"> |
| | | <input class="layui-input" type="text" id="matNo" onkeyup="findByMatNo(this)" autocomplete="off"> |
| | | </div> |
| | |
| | | } |
| | | |
| | | /** |
| | | * 根据物料号查找库存明细 |
| | | * 根据产品号查找库存明细 |
| | | */ |
| | | function findByMatNo(el){ |
| | | if (isEmpty(el.value)) { |
| | |
| | | function pakOut() { |
| | | var tableData = layui.table.checkStatus('tableIdx').data; |
| | | if (tableData.length === 0) { |
| | | tips("请选择物料", true); |
| | | tips("请选择产品", true); |
| | | return; |
| | | } |
| | | var site = $('#staNoSelect').val(); |
| | |
| | | <input type="text" id="code"> |
| | | </div> |
| | | <div> |
| | | <span>物料</span> |
| | | <span>产品</span> |
| | | <input type="text" id="matNo" onkeyup="find(this)" autocomplete="off"> |
| | | <button onclick="find()">查询</button> |
| | | </div> |
| | |
| | | return; |
| | | } |
| | | if (matData.length === 0) { |
| | | tips("请提取物料", true); |
| | | tips("请提取产品", true); |
| | | return; |
| | | } |
| | | httpRequest({ |
| | |
| | | |
| | | function help() { |
| | | window.alert("① 按F1输入条码\n" + |
| | | "② 按F2输入物料号,按ENTER查询,选择数量后提取\n" + |
| | | "② 按F2输入产品号,按ENTER查询,选择数量后提取\n" + |
| | | "③ 按F3开始组托\n" + |
| | | "其它:按F5刷新页面"); |
| | | } |
| | |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="物料编码" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="产品代号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width: 300px"> |
| | |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="物料编码" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="产品代号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width: 300px"> |
| | |
| | | <!--明细表--> |
| | | <div id="detlTable" style="display: none"> |
| | | <div class="layui-inline" style="width:90%;margin-top: 10px;margin-left: 20px"> |
| | | <span style=" color: indianred">以下为当前库位的物料明细</span> |
| | | <span style=" color: indianred">以下为当前库位的产品明细</span> |
| | | </div> |
| | | |
| | | <table class="layui-hide" id="locDetlByMap" lay-filter="locDetlByMap"></table> |
| | |
| | | </div> |
| | | <div class="layui-inline"> |
| | | <div class="layui-input-inline"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="物料编码" autocomplete="off"> |
| | | <input class="layui-input" type="text" name="matnr" placeholder="产品代号" autocomplete="off"> |
| | | </div> |
| | | </div> |
| | | <!-- 日期范围 --> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label">物料编码:</label> |
| | | <label class="layui-form-label">产品代号:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="matnr" class="layui-input" type="text"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label">物料描述:</label> |
| | | <label class="layui-form-label">产品描述:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="maktx" class="layui-input" type="text"> |
| | | </div> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label">物料编码:</label> |
| | | <label class="layui-form-label">产品代号:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="matnr" class="layui-input" type="text"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label">物料描述:</label> |
| | | <label class="layui-form-label">产品描述:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="maktx" class="layui-input" type="text"> |
| | | </div> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label" style="font-size: x-small"><span class="not-null">*</span>物料标签ID:</label> |
| | | <label class="layui-form-label" style="font-size: x-small"><span class="not-null">*</span>产品标签ID:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="zmatid" class="layui-input" type="text" lay-verify="required" > |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label">物料描述:</label> |
| | | <label class="layui-form-label">产品描述:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="maktx" class="layui-input" type="text"> |
| | | </div> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label"><span class="not-null">*</span>物料编号:</label> |
| | | <label class="layui-form-label"><span class="not-null">*</span>产品编号:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="matnr" class="layui-input" type="text" lay-verify="required" > |
| | | </div> |
| | |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label" style="font-size: x-small">物料标签ID:</label> |
| | | <label class="layui-form-label" style="font-size: x-small">产品标签ID:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="zmatid" class="layui-input" type="text"> |
| | | </div> |
| | | </div> |
| | | <div class="layui-inline" style="width:31%;"> |
| | | <label class="layui-form-label">物料描述:</label> |
| | | <label class="layui-form-label">产品描述:</label> |
| | | <div class="layui-input-inline"> |
| | | <input id="maktx" class="layui-input" type="text"> |
| | | </div> |
| | |
| | | <!--明细表--> |
| | | <div id="detlTable" style="display: none"> |
| | | <div class="layui-inline" style="width:90%;margin-top: 10px;margin-left: 20px"> |
| | | <span style=" color: indianred">以下为当前工作流的物料明细</span> |
| | | <span style=" color: indianred">以下为当前工作流的产品明细</span> |
| | | </div> |
| | | |
| | | <table class="layui-hide" id="wrkDetlByMap" lay-filter="wrkDetlByMap"></table> |