From 845855c7b411622b93eff866b54cd37983f53797 Mon Sep 17 00:00:00 2001
From: Fancy <Fancy.fx@outlook.com>
Date: 星期五, 13 十二月 2024 09:55:34 +0800
Subject: [PATCH] change wx name
---
pms-parent/pms-web-platform/src/main/java/com/dy/pmsPlatform/station/StationSv.java | 16 ++++++++++++++--
1 files changed, 14 insertions(+), 2 deletions(-)
diff --git a/pms-parent/pms-web-platform/src/main/java/com/dy/pmsPlatform/station/StationSv.java b/pms-parent/pms-web-platform/src/main/java/com/dy/pmsPlatform/station/StationSv.java
index 783a93c..c0858da 100644
--- a/pms-parent/pms-web-platform/src/main/java/com/dy/pmsPlatform/station/StationSv.java
+++ b/pms-parent/pms-web-platform/src/main/java/com/dy/pmsPlatform/station/StationSv.java
@@ -1,11 +1,14 @@
package com.dy.pmsPlatform.station;
+import cn.hutool.json.JSONArray;
+import cn.hutool.json.JSONObject;
import com.alibaba.excel.util.StringUtils;
import com.dy.common.webUtil.QueryResultVo;
import com.dy.pmsGlobal.daoPlt.PltProductionLineMapper;
import com.dy.pmsGlobal.daoPlt.PltStationMapper;
import com.dy.pmsGlobal.pojoPlt.PltProductionLine;
import com.dy.pmsGlobal.pojoPlt.PltStation;
+import com.dy.pmsGlobal.util.QrCodeConstant;
import com.dy.pmsGlobal.util.QrCodeUtil;
import lombok.extern.slf4j.Slf4j;
import org.apache.dubbo.common.utils.PojoUtils;
@@ -23,7 +26,7 @@
private PltStationMapper dao;
private PltProductionLineMapper lineDao;
- private static final String stationPrefix = "103" ;
+// private static final String stationPrefix = "103" ;
private static final String DEFAULT_CODE = "0001";
private static final String CODE_FORMAT = "%04d";
@@ -125,7 +128,7 @@
//鏌ヨ绗﹀悎鏉′欢鐨勮褰�
rsVo.obj = this.dao.selectSome(params) ;
rsVo.obj.parallelStream().forEach(item->{
- item.qrCode = QrCodeUtil.genQrCodeString(stationPrefix+item.id);
+ item.qrCode = QrCodeUtil.genQrCodeString(QrCodeConstant.TypeStation+item.id);
});
return rsVo ;
}
@@ -148,5 +151,14 @@
public List<PltStation> selectAll() {
return dao.selectAll();
}
+
+ public JSONArray selectAllIdAndName() {
+ List<PltStation> list = dao.selectAll();
+ JSONArray child = new JSONArray();
+ list.forEach(item->{
+ child.add(new JSONObject().set("id", String.valueOf(item.getId())).set("name", item.getName()));
+ });
+ return child;
+ }
}
--
Gitblit v1.8.0