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 107 public AjaxResult saveContainer(String receiptCode, String containerCode, Integer receiptDetailId,
108 108 String locationCode, BigDecimal qty, String locatingRule) {
109 109  
  110 + containerCode = containerCode.substring(0, 1).toUpperCase() + containerCode.substring(1);
110 111 ReceiptHeader receiptHeader = receiptHeaderService.getReceiptHeaderByCode(receiptCode);
111 112 ReceiptDetail detail = receiptDetailService.getById(receiptDetailId);
112 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 22 import com.huaheng.pc.receipt.receiptHeader.domain.ReceiptHeader;
23 23 import com.huaheng.pc.receipt.receiptHeader.service.ReceiptHeaderService;
24 24 import com.huaheng.pc.receipt.receiptHeaderHistory.service.ReceiptHeaderHistoryService;
  25 +import com.huaheng.pc.shipment.shipmentHeader.domain.ShipmentHeader;
25 26 import com.huaheng.pc.task.taskHeader.domain.TaskHeader;
26 27 import io.swagger.annotations.Api;
27 28 import io.swagger.annotations.ApiOperation;
... ... @@ -121,6 +122,8 @@ public class ReceiptHeaderController extends BaseController {
121 122 .lt(StringUtils.isNotEmpty(completeTimeEnd), ReceiptHeader::getCompleteTime, completeTimeEnd)
122 123 //物料搜索
123 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 127 .orderByAsc(ReceiptHeader::getLastStatus)
125 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 403 @ApiModelProperty(value = "物料名称")
404 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 228 .eq(ShipmentHeader::getDeleted, 0)
229 229 //物料搜索
230 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 233 .orderByAsc(ShipmentHeader::getLastStatus)
232 234 .orderByAsc(ShipmentHeader::getRequestedStartDate)
233 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 531 @TableField(exist = false)
532 532 @ApiModelProperty(value = "物料名称")
533 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 31 <input type="button" class="btn-success btn" onclick="selectInventoryDetail()" value="选取置换的库存"/>
32 32 <button type="button" style="margin-right: 10px" class="btn btn-primary" onclick="getInventoryDetail()">查看物料详情</button>
33 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 41 <div class="form-group">
36 42 <label class="col-sm-3 control-label">出库口:</label>
... ...
src/main/resources/templates/receipt/receiptHeader/receiptHeader.html
... ... @@ -95,6 +95,9 @@
95 95 物料名称:<input type="text" name="materialName"/>
96 96 </li>
97 97 <li>
  98 + 物料编码:<input type="text" name="materialCode"/>
  99 + </li>
  100 + <li>
98 101 MOM回传状态:<select id="pushSuccessStatus" name="pushSuccessStatus">
99 102 <option value="">所有</option>
100 103 <option value="0">未回传</option>
... ... @@ -574,7 +577,7 @@
574 577 if (value == undefined || value == '')
575 578 value = " "
576 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 581 return actions.join(" ")
579 582 }
580 583 },
... ...
src/main/resources/templates/receipt/receiptHeaderHistory/receiptHeaderHistory.html
... ... @@ -479,7 +479,7 @@
479 479 if (value == undefined || value == '')
480 480 value = " "
481 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 483 return actions.join(" ")
484 484 }
485 485 },
... ...
src/main/resources/templates/shipment/shipmentHeader/shipmentHeader.html
... ... @@ -122,6 +122,9 @@
122 122 物料名称:<input type="text" name="materialName"/>
123 123 </li>
124 124 <li>
  125 + 物料编码:<input type="text" name="materialCode"/>
  126 + </li>
  127 + <li>
125 128 备注:<input type="text" name="shipmentNote"/>
126 129 </li>
127 130 <li>
... ... @@ -573,14 +576,29 @@
573 576 field: 'workshop',
574 577 title: '生产车间',
575 578 },
576   -
577 579 {
578 580 field: 'noticeNo',
579 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 592 field: 'superiorName',
583 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 604 field: 'superiorCode',
... ... @@ -590,7 +608,7 @@
590 608 if (value == undefined || value == '')
591 609 value = " "
592 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 612 return actions.join(" ")
595 613 }
596 614 },
... ... @@ -602,7 +620,7 @@
602 620 if (value == undefined || value == '')
603 621 value = " "
604 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 624 return actions.join(" ")
607 625 }
608 626 },
... ... @@ -658,7 +676,7 @@
658 676 if (value == undefined || value == '')
659 677 value = " "
660 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 680 return actions.join(" ")
663 681 }
664 682 },
... ...
src/main/resources/templates/shipment/shipmentHeaderHistory/shipmentHeaderHistory.html
... ... @@ -507,14 +507,38 @@
507 507 {
508 508 field: 'noticeNo',
509 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 520 field: 'superiorName',
517 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 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 608 field: 'recordCode',
601 609 title: '合并前单号',
602 610 formatter: function (value, row, index) {
... ... @@ -604,7 +612,7 @@
604 612 if (value == undefined || value == '')
605 613 value = " "
606 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 616 return actions.join(" ")
609 617 }
610 618 },
... ... @@ -616,7 +624,7 @@
616 624 if (value == undefined || value == '')
617 625 value = " "
618 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 628 return actions.join(" ")
621 629 }
622 630 },
... ...