diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSalesOrderController.java b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSalesOrderController.java index f2742678..57a1bdc5 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSalesOrderController.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSalesOrderController.java @@ -453,6 +453,8 @@ public class SysSalesOrderController extends BaseController SysSalesOrderVo sysSalesOrderVo1 = sysSalesOrderService.selectSysSalesOrderById(sysSalesOrderVo.getSalesOrderId()); //生产订单生成 sysMakeOrderService.generateMakeOrderBySalesOrderCode(sysSalesOrderVo1.getSalesOrderCode()); + + // 提交 if("submit".equals(instanceType)){ // 使用状态-是 diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysSalesOrder.java b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysSalesOrder.java index 39759ba4..098637d0 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysSalesOrder.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysSalesOrder.java @@ -57,7 +57,7 @@ public class SysSalesOrder extends BaseEntity { /*客户电话*/ private String customerPhone; /*物料合计*/ - private Double materialSum; + private Long materialSum; /*数量合计*/ private Long enterpriseSum; /*不含税单价(RMB)*/ @@ -297,11 +297,11 @@ public class SysSalesOrder extends BaseEntity { this.customerPhone = customerPhone; } - public Double getMaterialSum() { + public Long getMaterialSum() { return materialSum; } - public void setMaterialSum(Double materialSum) { + public void setMaterialSum(Long materialSum) { this.materialSum = materialSum; } diff --git a/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysMakeOrderServiceImpl.java b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysMakeOrderServiceImpl.java index ed3c3f43..1d4c5b5e 100644 --- a/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysMakeOrderServiceImpl.java +++ b/ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysMakeOrderServiceImpl.java @@ -195,6 +195,15 @@ public class SysMakeOrderServiceImpl implements ISysMakeOrderService // 是 makeOrder.setUseStatus("1"); makeOrder.setSaleNo(salesOrderCode); + makeOrder.setMakeStatus("0"); + makeOrder.setSalesman(sysSalesOrderVo.getBusinessMembers()); + makeOrder.setSaleNo(sysSalesOrderVo.getSalesOrderCode()); + makeOrder.setOrderType(sysSalesOrderVo.getSalesOrderType()); + makeOrder.setCustomerId(sysSalesOrderVo.getEnterpriseCode()); + makeOrder.setCustomerName(sysSalesOrderVo.getEnterpriseName()); + makeOrder.setCustomerOderCode(sysSalesOrderVo.getSalesOrderNumber()); + makeOrder.setMaterialSum(sysSalesOrderVo.getEnterpriseSum()); + makeOrder.setMaterial(String.valueOf(sysSalesOrderVo.getMaterialSum())); String makeNo = redisCache.generateBillNo("PO"); makeOrder.setMakeNo(makeNo); insertSysMakeOrder(makeOrder); diff --git a/ruoyi-admin/src/main/resources/mapper/system/SysSalesOrderMapper.xml b/ruoyi-admin/src/main/resources/mapper/system/SysSalesOrderMapper.xml index a96caab6..67b49c24 100644 --- a/ruoyi-admin/src/main/resources/mapper/system/SysSalesOrderMapper.xml +++ b/ruoyi-admin/src/main/resources/mapper/system/SysSalesOrderMapper.xml @@ -126,7 +126,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" and s.apply_time = #{applyTime} and s.apply_title = #{applyTitle} - order by s.apply_time desc + order by s.create_time desc - -
-
-
-
+
+
+
+
+
-
+ +
diff --git a/ruoyi-admin/src/main/resources/templates/system/salesOrder/salesOrder.html b/ruoyi-admin/src/main/resources/templates/system/salesOrder/salesOrder.html index f3576170..4c603bcf 100644 --- a/ruoyi-admin/src/main/resources/templates/system/salesOrder/salesOrder.html +++ b/ruoyi-admin/src/main/resources/templates/system/salesOrder/salesOrder.html @@ -228,6 +228,7 @@ updateUrl: prefix + "/edit/{id}", removeUrl: prefix + "/remove", exportUrl: prefix + "/export", + cancelUrl: prefix + "/cancel/{id}", detailUrl: prefix + "/detail/{id}", pagination: true, pageList: [5, 10, 25, 50], @@ -353,6 +354,11 @@ // 进度查看 actions.push(' 进度查看 '); } + + if (row.makeStatus == "0" || row.makeStatus == "1"){ + actions.push(' 出货 '); + } + // 详情 actions.push(' 详情 '); return actions.join('');