Commit 223b671c7bb89da9dd9ed579dc1be78d3f904008

Authored by 易文鹏
1 parent e9aaf4be

feat: 入库组盘托盘小写自动转大写

src/main/java/com/huaheng/pc/receipt/receiptContainerHeader/service/ReceiptContainerHeaderServiceImpl.java
@@ -107,6 +107,7 @@ public class ReceiptContainerHeaderServiceImpl extends ServiceImpl<ReceiptContai @@ -107,6 +107,7 @@ public class ReceiptContainerHeaderServiceImpl extends ServiceImpl<ReceiptContai
107 public AjaxResult saveContainer(String receiptCode, String containerCode, Integer receiptDetailId, 107 public AjaxResult saveContainer(String receiptCode, String containerCode, Integer receiptDetailId,
108 String locationCode, BigDecimal qty, String locatingRule) { 108 String locationCode, BigDecimal qty, String locatingRule) {
109 109
  110 + containerCode = containerCode.substring(0, 1).toUpperCase() + containerCode.substring(1);
110 ReceiptHeader receiptHeader = receiptHeaderService.getReceiptHeaderByCode(receiptCode); 111 ReceiptHeader receiptHeader = receiptHeaderService.getReceiptHeaderByCode(receiptCode);
111 ReceiptDetail detail = receiptDetailService.getById(receiptDetailId); 112 ReceiptDetail detail = receiptDetailService.getById(receiptDetailId);
112 if (detail.getIsMustFlatWarehouseMaterial()) { 113 if (detail.getIsMustFlatWarehouseMaterial()) {
src/main/java/com/huaheng/pc/receipt/receiptHeader/controller/ReceiptHeaderController.java
@@ -22,6 +22,7 @@ import com.huaheng.pc.receipt.receiptDetailHistory.service.ReceiptDetailHistoryS @@ -22,6 +22,7 @@ import com.huaheng.pc.receipt.receiptDetailHistory.service.ReceiptDetailHistoryS
22 import com.huaheng.pc.receipt.receiptHeader.domain.ReceiptHeader; 22 import com.huaheng.pc.receipt.receiptHeader.domain.ReceiptHeader;
23 import com.huaheng.pc.receipt.receiptHeader.service.ReceiptHeaderService; 23 import com.huaheng.pc.receipt.receiptHeader.service.ReceiptHeaderService;
24 import com.huaheng.pc.receipt.receiptHeaderHistory.service.ReceiptHeaderHistoryService; 24 import com.huaheng.pc.receipt.receiptHeaderHistory.service.ReceiptHeaderHistoryService;
  25 +import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader;
25 import com.huaheng.pc.task.taskHeader.domain.TaskHeader; 26 import com.huaheng.pc.task.taskHeader.domain.TaskHeader;
26 import io.swagger.annotations.Api; 27 import io.swagger.annotations.Api;
27 import io.swagger.annotations.ApiOperation; 28 import io.swagger.annotations.ApiOperation;
@@ -121,6 +122,8 @@ public class ReceiptHeaderController extends BaseController { @@ -121,6 +122,8 @@ public class ReceiptHeaderController extends BaseController {
121 .lt(StringUtils.isNotEmpty(completeTimeEnd), ReceiptHeader::getCompleteTime, completeTimeEnd) 122 .lt(StringUtils.isNotEmpty(completeTimeEnd), ReceiptHeader::getCompleteTime, completeTimeEnd)
122 //物料搜索 123 //物料搜索
123 .inSql(StringUtils.isNotEmpty(receiptHeader.getMaterialName()), ReceiptHeader::getId, "SELECT receiptId FROM receipt_detail WHERE materialName LIKE '%" + receiptHeader.getMaterialName() + "%'") 124 .inSql(StringUtils.isNotEmpty(receiptHeader.getMaterialName()), ReceiptHeader::getId, "SELECT receiptId FROM receipt_detail WHERE materialName LIKE '%" + receiptHeader.getMaterialName() + "%'")
  125 + .inSql(StringUtils.isNotEmpty(receiptHeader.getMaterialCode()), ReceiptHeader::getId, "SELECT receiptId FROM receipt_detail WHERE materialCode LIKE '%" + receiptHeader.getMaterialCode() + "%'")
  126 +
124 .orderByAsc(ReceiptHeader::getLastStatus) 127 .orderByAsc(ReceiptHeader::getLastStatus)
125 .orderByDesc(ReceiptHeader::getCreated); 128 .orderByDesc(ReceiptHeader::getCreated);
126 129
src/main/java/com/huaheng/pc/receipt/receiptHeader/domain/ReceiptHeader.java
@@ -403,6 +403,10 @@ public class ReceiptHeader implements Serializable { @@ -403,6 +403,10 @@ public class ReceiptHeader implements Serializable {
403 @ApiModelProperty(value = "物料名称") 403 @ApiModelProperty(value = "物料名称")
404 private String materialName; 404 private String materialName;
405 405
  406 + @TableField(exist = false)
  407 + @ApiModelProperty(value = "物料编码")
  408 + private String materialCode;
  409 +
406 410
407 /** 411 /**
408 * 是否快速入库 412 * 是否快速入库
src/main/java/com/huaheng/pc/shipment/shipmentHeader/controller/ShipmentHeaderController.java
@@ -228,6 +228,8 @@ public class ShipmentHeaderController extends BaseController { @@ -228,6 +228,8 @@ public class ShipmentHeaderController extends BaseController {
228 .eq(ShipmentHeader::getDeleted, 0) 228 .eq(ShipmentHeader::getDeleted, 0)
229 //物料搜索 229 //物料搜索
230 .inSql(StringUtils.isNotEmpty(shipmentHeader.getMaterialName()), ShipmentHeader::getId, "SELECT shipmentId FROM shipment_detail WHERE materialName LIKE '%" + shipmentHeader.getMaterialName() + "%'") 230 .inSql(StringUtils.isNotEmpty(shipmentHeader.getMaterialName()), ShipmentHeader::getId, "SELECT shipmentId FROM shipment_detail WHERE materialName LIKE '%" + shipmentHeader.getMaterialName() + "%'")
  231 + .inSql(StringUtils.isNotEmpty(shipmentHeader.getMaterialCode()), ShipmentHeader::getId, "SELECT shipmentId FROM shipment_detail WHERE materialCode LIKE '%" + shipmentHeader.getMaterialCode() + "%'")
  232 +
231 .orderByAsc(ShipmentHeader::getLastStatus) 233 .orderByAsc(ShipmentHeader::getLastStatus)
232 .orderByAsc(ShipmentHeader::getRequestedStartDate) 234 .orderByAsc(ShipmentHeader::getRequestedStartDate)
233 .orderByAsc(ShipmentHeader::getCreated); 235 .orderByAsc(ShipmentHeader::getCreated);
src/main/java/com/huaheng/pc/shipment/shipmentHeader/domain/ShipmentHeader.java
@@ -531,4 +531,8 @@ public class ShipmentHeader implements Serializable { @@ -531,4 +531,8 @@ public class ShipmentHeader implements Serializable {
531 @TableField(exist = false) 531 @TableField(exist = false)
532 @ApiModelProperty(value = "物料名称") 532 @ApiModelProperty(value = "物料名称")
533 private String materialName; 533 private String materialName;
  534 +
  535 + @TableField(exist = false)
  536 + @ApiModelProperty(value = "物料编码")
  537 + private String materialCode;
534 } 538 }
src/main/resources/templates/inventory/inventoryTransaction/displace.html
@@ -31,6 +31,12 @@ @@ -31,6 +31,12 @@
31 <input type="button" class="btn-success btn" onclick="selectInventoryDetail()" value="选取置换的库存"/> 31 <input type="button" class="btn-success btn" onclick="selectInventoryDetail()" value="选取置换的库存"/>
32 <button type="button" style="margin-right: 10px" class="btn btn-primary" onclick="getInventoryDetail()">查看物料详情</button> 32 <button type="button" style="margin-right: 10px" class="btn btn-primary" onclick="getInventoryDetail()">查看物料详情</button>
33 </div> 33 </div>
  34 + <div class="form-group">
  35 + <label class="col-sm-3 control-label">置换的数量:</label>
  36 + <div class="col-sm-2">
  37 + <input id="qty" name="qty" class="form-control" type="text">
  38 + </div>
  39 + </div>
34 40
35 <div class="form-group"> 41 <div class="form-group">
36 <label class="col-sm-3 control-label">出库口:</label> 42 <label class="col-sm-3 control-label">出库口:</label>
src/main/resources/templates/receipt/receiptHeader/receiptHeader.html
@@ -95,6 +95,9 @@ @@ -95,6 +95,9 @@
95 物料名称:<input type="text" name="materialName"/> 95 物料名称:<input type="text" name="materialName"/>
96 </li> 96 </li>
97 <li> 97 <li>
  98 + 物料编码:<input type="text" name="materialCode"/>
  99 + </li>
  100 + <li>
98 MOM回传状态:<select id="pushSuccessStatus" name="pushSuccessStatus"> 101 MOM回传状态:<select id="pushSuccessStatus" name="pushSuccessStatus">
99 <option value="">所有</option> 102 <option value="">所有</option>
100 <option value="0">未回传</option> 103 <option value="0">未回传</option>
@@ -574,7 +577,7 @@ @@ -574,7 +577,7 @@
574 if (value == undefined || value == '') 577 if (value == undefined || value == '')
575 value = " " 578 value = " "
576 else 579 else
577 - actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:500px">' + value + '</pre>') 580 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
578 return actions.join(" ") 581 return actions.join(" ")
579 } 582 }
580 }, 583 },
src/main/resources/templates/receipt/receiptHeaderHistory/receiptHeaderHistory.html
@@ -479,7 +479,7 @@ @@ -479,7 +479,7 @@
479 if (value == undefined || value == '') 479 if (value == undefined || value == '')
480 value = " " 480 value = " "
481 else 481 else
482 - actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:500px">' + value + '</pre>') 482 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
483 return actions.join(" ") 483 return actions.join(" ")
484 } 484 }
485 }, 485 },
src/main/resources/templates/shipment/shipmentHeader/shipmentHeader.html
@@ -122,6 +122,9 @@ @@ -122,6 +122,9 @@
122 物料名称:<input type="text" name="materialName"/> 122 物料名称:<input type="text" name="materialName"/>
123 </li> 123 </li>
124 <li> 124 <li>
  125 + 物料编码:<input type="text" name="materialCode"/>
  126 + </li>
  127 + <li>
125 备注:<input type="text" name="shipmentNote"/> 128 备注:<input type="text" name="shipmentNote"/>
126 </li> 129 </li>
127 <li> 130 <li>
@@ -573,14 +576,29 @@ @@ -573,14 +576,29 @@
573 field: 'workshop', 576 field: 'workshop',
574 title: '生产车间', 577 title: '生产车间',
575 }, 578 },
576 -  
577 { 579 {
578 field: 'noticeNo', 580 field: 'noticeNo',
579 title: '通知单号', 581 title: '通知单号',
  582 + formatter: function (value, row, index) {
  583 + var actions = [];
  584 + if (value == undefined || value == '')
  585 + value = " "
  586 + else
  587 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
  588 + return actions.join(" ")
  589 + }
580 }, 590 },
581 { 591 {
582 field: 'superiorName', 592 field: 'superiorName',
583 title: '母件名称', 593 title: '母件名称',
  594 + formatter: function (value, row, index) {
  595 + var actions = [];
  596 + if (value == undefined || value == '')
  597 + value = " "
  598 + else
  599 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
  600 + return actions.join(" ")
  601 + }
584 }, 602 },
585 { 603 {
586 field: 'superiorCode', 604 field: 'superiorCode',
@@ -590,7 +608,7 @@ @@ -590,7 +608,7 @@
590 if (value == undefined || value == '') 608 if (value == undefined || value == '')
591 value = " " 609 value = " "
592 else 610 else
593 - actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:500px">' + value + '</pre>') 611 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
594 return actions.join(" ") 612 return actions.join(" ")
595 } 613 }
596 }, 614 },
@@ -602,7 +620,7 @@ @@ -602,7 +620,7 @@
602 if (value == undefined || value == '') 620 if (value == undefined || value == '')
603 value = " " 621 value = " "
604 else 622 else
605 - actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:500px">' + value + '</pre>') 623 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
606 return actions.join(" ") 624 return actions.join(" ")
607 } 625 }
608 }, 626 },
@@ -658,7 +676,7 @@ @@ -658,7 +676,7 @@
658 if (value == undefined || value == '') 676 if (value == undefined || value == '')
659 value = " " 677 value = " "
660 else 678 else
661 - actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:500px">' + value + '</pre>') 679 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
662 return actions.join(" ") 680 return actions.join(" ")
663 } 681 }
664 }, 682 },
src/main/resources/templates/shipment/shipmentHeaderHistory/shipmentHeaderHistory.html
@@ -507,14 +507,38 @@ @@ -507,14 +507,38 @@
507 { 507 {
508 field: 'noticeNo', 508 field: 'noticeNo',
509 title: '通知单号', 509 title: '通知单号',
510 - },  
511 - {  
512 - field: 'superiorCode',  
513 - title: '母件编码', 510 + formatter: function (value, row, index) {
  511 + var actions = [];
  512 + if (value == undefined || value == '')
  513 + value = " "
  514 + else
  515 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
  516 + return actions.join(" ")
  517 + }
514 }, 518 },
515 { 519 {
516 field: 'superiorName', 520 field: 'superiorName',
517 title: '母件名称', 521 title: '母件名称',
  522 + formatter: function (value, row, index) {
  523 + var actions = [];
  524 + if (value == undefined || value == '')
  525 + value = " "
  526 + else
  527 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
  528 + return actions.join(" ")
  529 + }
  530 + },
  531 + {
  532 + field: 'superiorCode',
  533 + title: '母件编码',
  534 + formatter: function (value, row, index) {
  535 + var actions = [];
  536 + if (value == undefined || value == '')
  537 + value = " "
  538 + else
  539 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
  540 + return actions.join(" ")
  541 + }
518 }, 542 },
519 543
520 { 544 {
@@ -581,22 +605,6 @@ @@ -581,22 +605,6 @@
581 visible: true 605 visible: true
582 }, 606 },
583 { 607 {
584 - field: 'superiorName',  
585 - title: '母件名称',  
586 - },  
587 - {  
588 - field: 'superiorCode',  
589 - title: '母件编码',  
590 - formatter: function (value, row, index) {  
591 - var actions = [];  
592 - if (value == undefined || value == '')  
593 - value = " "  
594 - else  
595 - actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:500px">' + value + '</pre>')  
596 - return actions.join(" ")  
597 - }  
598 - },  
599 - {  
600 field: 'recordCode', 608 field: 'recordCode',
601 title: '合并前单号', 609 title: '合并前单号',
602 formatter: function (value, row, index) { 610 formatter: function (value, row, index) {
@@ -604,7 +612,7 @@ @@ -604,7 +612,7 @@
604 if (value == undefined || value == '') 612 if (value == undefined || value == '')
605 value = " " 613 value = " "
606 else 614 else
607 - actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:500px">' + value + '</pre>') 615 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
608 return actions.join(" ") 616 return actions.join(" ")
609 } 617 }
610 }, 618 },
@@ -616,7 +624,7 @@ @@ -616,7 +624,7 @@
616 if (value == undefined || value == '') 624 if (value == undefined || value == '')
617 value = " " 625 value = " "
618 else 626 else
619 - actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:500px">' + value + '</pre>') 627 + actions.push('<pre style="max-height:50px; white-space: pre-wrap; width:250px">' + value + '</pre>')
620 return actions.join(" ") 628 return actions.join(" ")
621 } 629 }
622 }, 630 },