Browse Source

[feat] 编辑的流程添加为submitApply() insert启动新数据改变判断为不存在有getId自增主键的才添加

dev
zhangsiqi 4 months ago
parent
commit
a010833687
  1. 4
      ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseOrderServiceImpl.java
  2. 6
      ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteServiceImpl.java
  3. 2
      ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysCustomerQuoteController.java
  4. 4
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysCustomerQuoteServiceImpl.java
  5. 2
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysCustomerServiceImpl.java
  6. 4
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysSalesOrderServiceImpl.java
  7. 4
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysSupplierServiceImpl.java

4
ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseOrderServiceImpl.java

@ -602,7 +602,9 @@ public class PurchaseOrderServiceImpl implements IPurchaseOrderService
SysUser user = ShiroUtils.getSysUser();
purchaseOrder.setApplyUser(user.getLoginName());
purchaseOrder.setApplyTime(DateUtils.getNowDate());
insertPurchaseOrder(purchaseOrder);
if(purchaseOrder.getPurchaseOrderId()==null) {
insertPurchaseOrder(purchaseOrder);
}
// 启动流程
String applyTitle = user.getUserName()+"发起了采购订单信息提交审批-"+DateUtils.dateTimeNow();
String instanceType = "submit";

6
ruoyi-admin/src/main/java/com/ruoyi/purchase/service/impl/PurchaseQuoteServiceImpl.java

@ -241,7 +241,7 @@ public class PurchaseQuoteServiceImpl implements IPurchaseQuoteService
attachFileService.updateAttachIdByIdList(photoAttachId, fileIdList);
}
List<PurchaseQuoteChild> childList = purchaseQuote.getPurchaseQuoteChildList();
//逻辑删除采购报价单子表
//删除采购报价单子表
purchaseQuoteChildService.deletePurchaseQuoteChildByQuoteCode(purchaseQuote.getPurchaseQuoteCode());
//重新录入子表
int childResult = childList.size();
@ -378,7 +378,9 @@ public class PurchaseQuoteServiceImpl implements IPurchaseQuoteService
SysUser user = ShiroUtils.getSysUser();
purchaseQuote.setApplyUser(user.getLoginName());
purchaseQuote.setApplyTime(DateUtils.getNowDate());
insertPurchaseQuote(purchaseQuote);
if(purchaseQuote.getPurchaseQuoteId()==null){
insertPurchaseQuote(purchaseQuote);
}
// 启动流程
String applyTitle = user.getUserName()+"发起了客户信息提交审批-"+DateUtils.dateTimeNow();
String instanceType = "submit";

2
ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysCustomerQuoteController.java

@ -191,7 +191,7 @@ public class SysCustomerQuoteController extends BaseController
System.out.println("SysCustomerQuoteController.editSave:" + sysCustomerQuote.toString());
sysCustomerQuote.setAuditStatus("0");
sysCustomerQuote.setUseStatus("0");
sysCustomerQuoteService.updateSysCustomerQuote(sysCustomerQuote);
sysCustomerQuoteService.submitApply(sysCustomerQuote);
//修改客户报价信息
return AjaxResult.success();
}

4
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysCustomerQuoteServiceImpl.java

@ -297,7 +297,9 @@ public class SysCustomerQuoteServiceImpl implements ISysCustomerQuoteService {
SysUser user = ShiroUtils.getSysUser();
sysCustomerQuote.setApplyUser(user.getLoginName());
sysCustomerQuote.setApplyTime(DateUtils.getNowDate());
insertSysCustomerQuote(sysCustomerQuote);
if(sysCustomerQuote.getId()==null){
insertSysCustomerQuote(sysCustomerQuote);
}
System.out.println("sysCustomerQuote:"+sysCustomerQuote);
// 启动流程
String applyTitle = user.getUserName()+"发起了客户报价信息提交审批-"+DateUtils.dateTimeNow();

2
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysCustomerServiceImpl.java

@ -384,7 +384,7 @@ public class SysCustomerServiceImpl implements ISysCustomerService
SysUser user = ShiroUtils.getSysUser();
sysCustomer.setApplyUser(user.getLoginName());
sysCustomer.setApplyTime(DateUtils.getNowDate());
if (sysCustomer.getId() == null || sysCustomer.getId() == 0){
if (sysCustomer.getId() == null){
insertSysCustomer(sysCustomer);
}
// 启动流程

4
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysSalesOrderServiceImpl.java

@ -328,7 +328,9 @@ public class SysSalesOrderServiceImpl implements ISysSalesOrderService
SysUser user = ShiroUtils.getSysUser();
sysSalesOrder.setApplyUser(user.getLoginName());
sysSalesOrder.setApplyTime(DateUtils.getNowDate());
insertSysSalesOrder(sysSalesOrder);
if(sysSalesOrder.getSalesOrderId() == null){
insertSysSalesOrder(sysSalesOrder);
}
// 启动流程
String applyTitle = user.getUserName()+"发起了客户销售订单信息提交审批-"+DateUtils.dateTimeNow();
String instanceType = "submit";

4
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysSupplierServiceImpl.java

@ -378,7 +378,9 @@ public class SysSupplierServiceImpl implements ISysSupplierService{
SysUser user = ShiroUtils.getSysUser();
sysSupplier.setApplyUser(user.getLoginName());
sysSupplier.setApplyTime(DateUtils.getNowDate());
insertSysSupplier(sysSupplier);
if(sysSupplier.getSupplierId()==null){
insertSysSupplier(sysSupplier);
}
// 启动流程
String applyTitle = user.getUserName()+"发起了客户信息提交审批-"+DateUtils.dateTimeNow();
String instanceType = "submit";

Loading…
Cancel
Save