建店数据
This commit is contained in:
@@ -25,6 +25,7 @@ import com.cool.store.service.PreparationService;
|
|||||||
import com.cool.store.service.SysStoreAppService;
|
import com.cool.store.service.SysStoreAppService;
|
||||||
import com.cool.store.service.UserAuthMappingService;
|
import com.cool.store.service.UserAuthMappingService;
|
||||||
import com.cool.store.utils.RedisUtilPool;
|
import com.cool.store.utils.RedisUtilPool;
|
||||||
|
import com.cool.store.utils.poi.StringUtils;
|
||||||
import com.cool.store.utils.poi.constant.Constants;
|
import com.cool.store.utils.poi.constant.Constants;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
@@ -459,8 +460,12 @@ public class SysStoreAppServiceImpl implements SysStoreAppService, AuditResultSe
|
|||||||
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(shopId);
|
ShopInfoDO shopInfoDO = shopInfoMapper.selectByPrimaryKey(shopId);
|
||||||
EnterpriseUserDO supervisor = userAuthMappingService.hierarchicalSearch(UserRoleEnum.SUPERVISION, shopInfoDO.getRegionId());
|
EnterpriseUserDO supervisor = userAuthMappingService.hierarchicalSearch(UserRoleEnum.SUPERVISION, shopInfoDO.getRegionId());
|
||||||
shopInfoDO.setStoreNum(request.getStoreNum()); //更新门店编码
|
shopInfoDO.setStoreNum(request.getStoreNum()); //更新门店编码
|
||||||
|
shopInfoDO.setSupervisorUserId(Objects.isNull(supervisor) ? "" : supervisor.getUserId());//更新督导
|
||||||
SystemBuildingShopDO systemBuildingShopDO = systemBuildingShopMapper.selectOne(SystemBuildingShopDO.builder().shopId(shopId).build());
|
SystemBuildingShopDO systemBuildingShopDO = systemBuildingShopMapper.selectOne(SystemBuildingShopDO.builder().shopId(shopId).build());
|
||||||
shopInfoDO.setSupervisorUserId(Objects.isNull(supervisor) ? systemBuildingShopDO.getSupervisorId() : supervisor.getUserId());//更新督导
|
if (StringUtils.isEmpty(shopInfoDO.getSupervisorUserId())&&StringUtils.isNotEmpty(systemBuildingShopDO.getSupervisorId())){
|
||||||
|
EnterpriseUserDO user = enterpriseUserMapper.getUserInfoByJobnumber(systemBuildingShopDO.getSupervisorId());
|
||||||
|
shopInfoDO.setSupervisorUserId(user!=null?user.getUserId():"");
|
||||||
|
}
|
||||||
shopInfoDO.setShopName(systemBuildingShopDO.getStoreName());//更新铺位名称
|
shopInfoDO.setShopName(systemBuildingShopDO.getStoreName());//更新铺位名称
|
||||||
shopInfoMapper.updateByPrimaryKeySelective(shopInfoDO);
|
shopInfoMapper.updateByPrimaryKeySelective(shopInfoDO);
|
||||||
shopAuditInfoDO.setResultType(Constants.ZERO_INTEGER);
|
shopAuditInfoDO.setResultType(Constants.ZERO_INTEGER);
|
||||||
|
|||||||
Reference in New Issue
Block a user