licenseExamine

This commit is contained in:
guohb
2024-04-30 10:14:47 +08:00
parent cd18479929
commit e697be336a

View File

@@ -30,6 +30,7 @@ import com.github.pagehelper.PageInfo;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.*;
@@ -61,6 +62,7 @@ public class ApplyLicenseServiceImpl implements ApplyLicenseService {
EnterpriseUserMapper userMapper;
@Override
@Transactional(rollbackFor = Exception.class)
public Boolean submitLicense(SubmitLicenseRequest request) {
log.info("submitLicense request{}", JSONObject.toJSONString(request));
if (Objects.isNull(request)){
@@ -143,6 +145,7 @@ public class ApplyLicenseServiceImpl implements ApplyLicenseService {
}
@Override
@Transactional(rollbackFor = Exception.class)
public Boolean licenseExamine(Long shopId, Integer status,String result) {
ShopAuditInfoDO shopAuditInfoDO = new ShopAuditInfoDO();
shopAuditInfoDO.setShopId(shopId);
@@ -153,14 +156,21 @@ public class ApplyLicenseServiceImpl implements ApplyLicenseService {
shopAuditInfoDO.setSubmittedUserName(user.getName());
shopAuditInfoDO.setDataType(1);
shopAuditInfoDO.setResultType(status);
LicenseTransactDO licenseTransactDO = new LicenseTransactDO();
licenseTransactDO.setShopId(shopId);
if (status == Constants.ZERO_INTEGER){
shopAuditInfoDO.setPassReason(result);
shopSubStageStatusEnum = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_43;
licenseTransactDO.setSubmitStatus(3);
applyLicenseMapper.updateByPrimaryKeySelective(licenseTransactDO);
}else if (status == Constants.ONE_INTEGER){
licenseTransactDO.setSubmitStatus(2);
shopAuditInfoDO.setRejectReason(result);
shopSubStageStatusEnum = ShopSubStageStatusEnum.SHOP_SUB_STAGE_STATUS_42;
}
//插入操作/意见
shopAuditInfoMapper.insertSelective(shopAuditInfoDO);
//更新阶段状态
shopStageInfoDAO.updateShopStageAndAuditInfo(shopId,shopSubStageStatusEnum,null);
return null;
}