Commit 9e9fca5f by 刘宇峰

特约店、围栏bug修复

1 parent 2110f62e
...@@ -19,6 +19,7 @@ import java.util.List; ...@@ -19,6 +19,7 @@ import java.util.List;
@Mapper @Mapper
public interface VehicleMapper extends CommonBaseMapper<Vehicle> { public interface VehicleMapper extends CommonBaseMapper<Vehicle> {
@DataPerm(showSql = true)
List<VehicleLinkSnsDTO> linkSnsSearch(VehicleSearch search); List<VehicleLinkSnsDTO> linkSnsSearch(VehicleSearch search);
/** /**
......
...@@ -121,10 +121,13 @@ public class TrialDriveShopService { ...@@ -121,10 +121,13 @@ public class TrialDriveShopService {
// 校验数据 // 校验数据
checkTrialDriveShop(shopBO, true); checkTrialDriveShop(shopBO, true);
TrialDriveShop trialDriveShop = trialDriveShopMapper.selectById(shopBO.getId());
//同步更新特约店围栏记录在围栏表 //同步更新特约店围栏记录在围栏表
syncUpdateFence(shopBO); syncUpdateFence(shopBO);
TrialDriveShop shop = TrialDriveShopConverter.INSTANCE.bo2do(shopBO); TrialDriveShop shop = TrialDriveShopConverter.INSTANCE.bo2do(shopBO);
shop.setFenceId(trialDriveShop.getFenceId());
if (shopBO.getSpecialShopId() != null) { if (shopBO.getSpecialShopId() != null) {
shop.setCreatedBy(shopBO.getSpecialShopId()); shop.setCreatedBy(shopBO.getSpecialShopId());
} else { } else {
...@@ -159,7 +162,7 @@ public class TrialDriveShopService { ...@@ -159,7 +162,7 @@ public class TrialDriveShopService {
} }
} }
public void syncUpdateFence(TrialDriveShopBO shopBO) throws Exception { public ElectricFence syncUpdateFence(TrialDriveShopBO shopBO) throws Exception {
TrialDriveShop shop = trialDriveShopMapper.selectById(shopBO.getId()); TrialDriveShop shop = trialDriveShopMapper.selectById(shopBO.getId());
ElectricFenceBO fenceBO = new ElectricFenceBO(); ElectricFenceBO fenceBO = new ElectricFenceBO();
...@@ -183,7 +186,7 @@ public class TrialDriveShopService { ...@@ -183,7 +186,7 @@ public class TrialDriveShopService {
fenceBO.setSnList(shopBO.getSnList()); fenceBO.setSnList(shopBO.getSnList());
electricFenceService.updateFence(fenceBO); return electricFenceService.updateFence(fenceBO);
} }
public TrialDriveShopDetailsDTO getDetailsById(Long shopId) { public TrialDriveShopDetailsDTO getDetailsById(Long shopId) {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!