|
|
@@ -271,14 +271,18 @@ public class FosterwxMobileServiceImpl extends ServiceImpl<FosterwxMobileMapper,
|
|
|
continue;
|
|
|
}
|
|
|
List<FosterwxDomain> domainList = fosterwxDomainService.list(new QueryWrapper<FosterwxDomain>().eq("station_id",fosterwxMobile.getStationId()));
|
|
|
- Integer rand;
|
|
|
- if (domainList.size() == 1){
|
|
|
- rand = 0;
|
|
|
- }else{
|
|
|
- rand = (int)(0+Math.random()*((domainList.size()-1)-0+1));
|
|
|
- }
|
|
|
FosterwxCashMobile add = new FosterwxCashMobile();
|
|
|
- add.setDomainId(domainList.get(rand).getId());
|
|
|
+ //.站点域名不存在则不插入域名信息
|
|
|
+ if (domainList.size() > 0){
|
|
|
+ Integer rand;
|
|
|
+ if (domainList.size() == 1){
|
|
|
+ rand = 0;
|
|
|
+ }else{
|
|
|
+ rand = (int)(0+Math.random()*((domainList.size()-1)-0+1));
|
|
|
+ }
|
|
|
+ add.setDomainId(rand);
|
|
|
+ }
|
|
|
+
|
|
|
add.setGroupId(setIdsHandle.getId());
|
|
|
add.setMobileId(fosterwxMobile.getId());
|
|
|
add.setStationId(fosterwxMobile.getStationId());
|