北京暂降平台短信功能加固

This commit is contained in:
2025-11-14 14:18:40 +08:00
parent 000e201ed7
commit ab1c777432

View File

@@ -356,10 +356,13 @@ public class EventGateController extends BaseController {
if (CollUtil.isNotEmpty(poList)) {
StringBuilder stringBuilder = new StringBuilder(jsonObject.get("timeid").toString());
BigDecimal bigDecimal = new BigDecimal(jsonObject.get("eventvalue").toString()).multiply(new BigDecimal(100)).setScale(2, RoundingMode.HALF_UP);
stringBuilder.append(".").append(jsonObject.get("ms").toString()).append(",").append(jsonObject.get("bdname").toString()).append("_").append(jsonObject.get("busname").toString()).append("_").append(jsonObject.get("pointname").toString())
stringBuilder.append(".").append(jsonObject.get("ms").toString()).append(",").append(jsonObject.get("bdname").toString()).append("_").append(jsonObject.get("pointname").toString())
.append("发生电压暂降事件,事件残余电压").append(bigDecimal).append("%,持续时间:").append(jsonObject.get("persisttime").toString()).append("S;影响用户:");
stringBuilder.append(objStr);
//TODO 临时处理,后面需要用上
/*.append(jsonObject.get("busname").toString()).append("_")*/
String message;
if (stringBuilder.length() > 500) {