|
@@ -8,6 +8,7 @@ import com.songhua.common.utils.uuid.IdUtils;
|
|
|
import com.songhua.system.domain.BasicCruiseShip;
|
|
|
import com.songhua.system.mapper.BasicCruiseShipMapper;
|
|
|
import org.apache.commons.lang3.RandomUtils;
|
|
|
+import org.apache.commons.lang3.StringUtils;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
import com.songhua.system.mapper.CruiseShipMappingMapper;
|
|
@@ -101,12 +102,12 @@ public class CruiseShipMappingServiceImpl implements ICruiseShipMappingService
|
|
|
data.put("id", recentLocations.get(i).getId());
|
|
|
data.put("polylinePath",data1);
|
|
|
data.put("color", color.get(RandomUtils.nextInt(0, 9)));
|
|
|
- data.put("shipName", recentLocations.get(i).getShipName());
|
|
|
- data.put("shipType", recentLocations.get(i).getShipType());
|
|
|
+ data.put("shipName", StringUtils.isBlank(recentLocations.get(i).getShipName()) ? "" : recentLocations.get(i).getShipName());
|
|
|
+ data.put("shipType", StringUtils.isBlank(recentLocations.get(i).getShipType()) ? "" : recentLocations.get(i).getShipType());
|
|
|
data.put("lengthOverall", recentLocations.get(i).getLengthOverall());
|
|
|
data.put("registrationNumber", recentLocations.get(i).getRegistrationNumber());
|
|
|
data.put("quantity", recentLocations.get(i).getQuantity());
|
|
|
- data.put("propulsion", recentLocations.get(i).getPropulsion());
|
|
|
+ data.put("propulsion", StringUtils.isBlank(recentLocations.get(i).getPropulsion()) ? "" : recentLocations.get(i).getPropulsion());
|
|
|
data.put("passengerCapacity", recentLocations.get(i).getPassengerCapacity());
|
|
|
data.put("safetyEquipment", recentLocations.get(i).getSafetyEquipment());
|
|
|
data.put("did", recentLocations.get(i).getDid());
|
|
@@ -139,12 +140,12 @@ public class CruiseShipMappingServiceImpl implements ICruiseShipMappingService
|
|
|
data.put("id", recentLocations.get(i).getId());
|
|
|
data.put("polylinePath",data1);
|
|
|
data.put("color", color.get(RandomUtils.nextInt(0, 9)));
|
|
|
- data.put("shipName", recentLocations.get(i).getShipName());
|
|
|
- data.put("shipType", recentLocations.get(i).getShipType());
|
|
|
+ data.put("shipName", StringUtils.isBlank(recentLocations.get(i).getShipName()) ? "" : recentLocations.get(i).getShipName());
|
|
|
+ data.put("shipType", StringUtils.isBlank(recentLocations.get(i).getShipType()) ? "" : recentLocations.get(i).getShipType());
|
|
|
data.put("lengthOverall", recentLocations.get(i).getLengthOverall());
|
|
|
data.put("registrationNumber", recentLocations.get(i).getRegistrationNumber());
|
|
|
data.put("quantity", recentLocations.get(i).getQuantity());
|
|
|
- data.put("propulsion", recentLocations.get(i).getPropulsion());
|
|
|
+ data.put("propulsion", StringUtils.isBlank(recentLocations.get(i).getPropulsion()) ? "" : recentLocations.get(i).getPropulsion());
|
|
|
data.put("passengerCapacity", recentLocations.get(i).getPassengerCapacity());
|
|
|
data.put("safetyEquipment", recentLocations.get(i).getSafetyEquipment());
|
|
|
data.put("did", recentLocations.get(i).getDid());
|