diff --git a/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java b/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java index 28c6730..deb51c6 100644 --- a/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java +++ b/src/main/java/com/xkrs/service/impl/FirePointServiceImpl.java @@ -23,6 +23,7 @@ import org.springframework.web.multipart.MultipartFile; import javax.annotation.Resource; import javax.transaction.Transactional; import java.io.IOException; +import java.text.DecimalFormat; import java.time.LocalDate; import java.time.LocalDateTime; import java.util.*; @@ -334,7 +335,11 @@ public class FirePointServiceImpl implements FirePointService { } } if (weixinIdList.size() > 0) { - String content = "【星科瑞升】您注册的区域卫星监测到疑似火点," + firePointEntity.getFirePointAddress() + ",\n请登录系统查看"; + java.text.DecimalFormat decimalFormat = new DecimalFormat("#.000000"); + String formatLongitude = decimalFormat.format(firePointEntity.getLongitude()); + String formatLatitude = decimalFormat.format(firePointEntity.getLatitude()); + String countyName = firePointEntity.getCountyName(); + String content = firePointEntity.getSatelliteType() + "发现1个火点。\nlongitude:" + formatLongitude + ";\nlatitude:" + formatLatitude + ";\ncountyName:" + countyName; for (String weixinId : weixinIdList) { try { WDWxSendMsgUtil.sendMsg(weixinId, content, 0);