mirror of
https://gitee.com/victor123/jjjerp-java.git
synced 2025-12-06 15:51:10 +08:00
修复
This commit is contained in:
parent
a2fb573f5c
commit
bdb88eeba8
@ -6536,3 +6536,6 @@ INSERT INTO `jjjerp_upload_group` VALUES (7, 'image', '11', 0, 0, 10001, '2023-0
|
||||
INSERT INTO `jjjerp_upload_group` VALUES (8, 'image', '2', 0, 1, 10001, '2024-05-07 14:42:50', '2024-05-07 14:42:53');
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
ALTER TABLE `jjjerp_bill_head`
|
||||
MODIFY COLUMN `file_urls` longtext CHARACTER SET utf8 COLLATE utf8_general_ci NULL COMMENT '附件内容' AFTER `print_remark`;
|
||||
|
||||
@ -717,17 +717,17 @@ public class BillHeadServiceImpl extends BaseServiceImpl<BillHeadMapper, BillHea
|
||||
AdminUser sales = shopUserService.getById(head.getSalesId());
|
||||
if(sales != null){
|
||||
//业务员名称
|
||||
head.setSalesName(sales.getRealName());
|
||||
head.setSalesName(sales.getUserName());
|
||||
}
|
||||
AdminUser audit = shopUserService.getById(head.getAuditId());
|
||||
if(audit != null){
|
||||
//审核员名称
|
||||
head.setAuditName(audit.getRealName());
|
||||
head.setAuditName(audit.getUserName());
|
||||
}
|
||||
AdminUser creator = shopUserService.getById(head.getCreatorId());
|
||||
if(creator != null){
|
||||
//创建人名称
|
||||
head.setCreatorName(creator.getRealName());
|
||||
head.setCreatorName(creator.getUserName());
|
||||
}
|
||||
if(BillTypeEnum.CGRKD.getValue().equals(head.getBillType())){
|
||||
//业务类型,1直接采购入库,2订单采购入库
|
||||
@ -1440,7 +1440,7 @@ public class BillHeadServiceImpl extends BaseServiceImpl<BillHeadMapper, BillHea
|
||||
throw new BusinessException("商品Id不能为空");
|
||||
}
|
||||
if(item.getProductExtendId() == null){
|
||||
throw new BusinessException("商品扩展id不能为空");
|
||||
throw new BusinessException("商品规格id不能为空");
|
||||
}
|
||||
if(item.getBasicNumber() == null){
|
||||
throw new BusinessException("操作总数量不能为空");
|
||||
@ -1666,7 +1666,7 @@ public class BillHeadServiceImpl extends BaseServiceImpl<BillHeadMapper, BillHea
|
||||
item.setBillType(oldHead.getBillType());
|
||||
//检查商品属性
|
||||
this.checkItem(item);
|
||||
if(item.getIsDelete() != null && item.getIsDelete() == 0){
|
||||
if(item.getIsDelete() != null && item.getIsDelete() == 0 && item.getAllPrice() != null){
|
||||
totalPrice = totalPrice.add(item.getAllPrice());
|
||||
}
|
||||
totalNum = totalNum + item.getBasicNumber();
|
||||
@ -1742,11 +1742,10 @@ public class BillHeadServiceImpl extends BaseServiceImpl<BillHeadMapper, BillHea
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public boolean auditMarketOrder(BillHead head) {
|
||||
AdminUser adminUser = shopUserService.getById(ShopLoginUtil.getUserId());
|
||||
//是否为超级管理员0不是,1是
|
||||
if(!adminUser.getIsSuper()){
|
||||
throw new BusinessException("只有超管有审批权限");
|
||||
}
|
||||
BillHead oldHead = this.getById(head.getBillId());
|
||||
if(oldHead == null){
|
||||
throw new BusinessException("单据不能为空");
|
||||
}
|
||||
//审核状态,0未审核、1审核通过,2审核拒绝
|
||||
if(oldHead.getAuditStatus() != 10){
|
||||
throw new BusinessException("只有待审核订单才能审核");
|
||||
@ -1774,10 +1773,6 @@ public class BillHeadServiceImpl extends BaseServiceImpl<BillHeadMapper, BillHea
|
||||
//售后类型(10退货退款 20换货 30退款 40补发 50 维修 60 其他)
|
||||
.set(BillHead::getRefundType, oldHead.getRefundType())
|
||||
);
|
||||
//是否为超级管理员0不是,1是
|
||||
if(!adminUser.getIsSuper()){
|
||||
throw new BusinessException("只有超管有审批权限");
|
||||
}
|
||||
//审核状态,0未审核、1审核通过,2审核拒绝
|
||||
if(oldHead.getAuditStatus() != 10){
|
||||
throw new BusinessException("只有待审核订单才能审核");
|
||||
@ -1879,10 +1874,6 @@ public class BillHeadServiceImpl extends BaseServiceImpl<BillHeadMapper, BillHea
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public boolean auditOrder(BillHead head) {
|
||||
AdminUser adminUser = shopUserService.getById(ShopLoginUtil.getUserId());
|
||||
//是否为超级管理员0不是,1是
|
||||
if(!adminUser.getIsSuper()){
|
||||
throw new BusinessException("只有超管有审批权限");
|
||||
}
|
||||
BillHead oldHead = this.getById(head.getBillId());
|
||||
//审核状态,0未审核、1审核通过,2审核拒绝
|
||||
if(oldHead.getAuditStatus() != 10){
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user