|
@@ -14,9 +14,7 @@ import com.chuanxia.mcp.bean.enums.DeviceUaLevel;
|
|
import com.chuanxia.mcp.bean.model.*;
|
|
import com.chuanxia.mcp.bean.model.*;
|
|
import com.chuanxia.mcp.bean.vo.Result;
|
|
import com.chuanxia.mcp.bean.vo.Result;
|
|
import com.chuanxia.mcp.exception.ResultException;
|
|
import com.chuanxia.mcp.exception.ResultException;
|
|
-import com.chuanxia.mcp.mapper.CdnDomainMapper;
|
|
|
|
-import com.chuanxia.mcp.mapper.CdnDomainOperatorMapper;
|
|
|
|
-import com.chuanxia.mcp.mapper.CdnUaMapper;
|
|
|
|
|
|
+import com.chuanxia.mcp.mapper.*;
|
|
import com.chuanxia.mcp.service.CdnDoaminService;
|
|
import com.chuanxia.mcp.service.CdnDoaminService;
|
|
import com.chuanxia.mcp.service.CdnDomainCityService;
|
|
import com.chuanxia.mcp.service.CdnDomainCityService;
|
|
import com.chuanxia.mcp.service.UserService;
|
|
import com.chuanxia.mcp.service.UserService;
|
|
@@ -46,6 +44,9 @@ public class CdnDoaminServiceImpl extends ServiceImpl<CdnDomainMapper, CdnDomain
|
|
private final CdnDomainCityService domainCityService;
|
|
private final CdnDomainCityService domainCityService;
|
|
private final CdnUaMapper cdnUaMapper;
|
|
private final CdnUaMapper cdnUaMapper;
|
|
private final CdnDomainOperatorMapper domainOperatorMapper;
|
|
private final CdnDomainOperatorMapper domainOperatorMapper;
|
|
|
|
+ private final CdnDomainCityMapper domainCityMapper;
|
|
|
|
+ private final CdnDomainTimeRuleMapper domainTimeRuleMapper;
|
|
|
|
+ private final CdnCityMapper cityMapper;
|
|
|
|
|
|
@Override
|
|
@Override
|
|
public Result<IPage<CdnDomain>> listPage(DomainQueryDto queryDto) {
|
|
public Result<IPage<CdnDomain>> listPage(DomainQueryDto queryDto) {
|
|
@@ -97,8 +98,11 @@ public class CdnDoaminServiceImpl extends ServiceImpl<CdnDomainMapper, CdnDomain
|
|
List<Integer> cityIds = bindDto.getCityIds();
|
|
List<Integer> cityIds = bindDto.getCityIds();
|
|
List<CdnDomainCity> domainCityList = new ArrayList<>(cityIds.size());
|
|
List<CdnDomainCity> domainCityList = new ArrayList<>(cityIds.size());
|
|
for (Integer cityId : cityIds) {
|
|
for (Integer cityId : cityIds) {
|
|
|
|
+ CdnCity cdnCity = cityMapper.selectById(cityId);
|
|
CdnDomainCity domainCity = new CdnDomainCity();
|
|
CdnDomainCity domainCity = new CdnDomainCity();
|
|
|
|
+ domainCity.setCname(cdnCity.getCname());
|
|
domainCity.setCityId(cityId);
|
|
domainCity.setCityId(cityId);
|
|
|
|
+ domainCity.setDomain(domain.getDomain());
|
|
domainCity.setDomainId(domainId);
|
|
domainCity.setDomainId(domainId);
|
|
domainCityList.add(domainCity);
|
|
domainCityList.add(domainCity);
|
|
}
|
|
}
|
|
@@ -122,7 +126,11 @@ public class CdnDoaminServiceImpl extends ServiceImpl<CdnDomainMapper, CdnDomain
|
|
}
|
|
}
|
|
}
|
|
}
|
|
this.updateById(domain);
|
|
this.updateById(domain);
|
|
- domainOperatorMapper.updateDomainByDomainId(domain.getId(),domain.getDomain());
|
|
|
|
|
|
+
|
|
|
|
+ domainOperatorMapper.updateDomainByDomainId(domain.getId(), domain.getDomain());
|
|
|
|
+ domainCityMapper.updateByDomainId(domain.getId(), domain.getDomain());
|
|
|
|
+ domainTimeRuleMapper.updateDomainByDomainId(domain.getId(), domain.getDomain());
|
|
|
|
+
|
|
return Result.success("操作成功");
|
|
return Result.success("操作成功");
|
|
}
|
|
}
|
|
|
|
|