修改添加桩

This commit is contained in:
yuyang 2021-09-17 18:27:53 +08:00
parent 1fd977cfd8
commit 8193d7a169
3 changed files with 8 additions and 16 deletions

View File

@ -73,7 +73,7 @@ public class XhpcChargingPileServiceImpl implements IXhpcChargingPileService {
return AjaxResult.error("终端数量不能大于26");
}
if(xhpcChargingPile.getSerialNumber() ==null || xhpcChargingPile.getSerialNumber().length()!=14){
return AjaxResult.error("桩编号14");
return AjaxResult.error("桩编号14");
}
Long chargingStationId = xhpcChargingPile.getChargingStationId();
//获取计费模型id
@ -98,9 +98,9 @@ public class XhpcChargingPileServiceImpl implements IXhpcChargingPileService {
}
}
//插入redis 桩的编号
HashSet<String> noSet = new HashSet<>();
noSet.add(serialNumber);
powerPileService.addPileWhitelist(chargingStationId, noSet);
// HashSet<String> noSet = new HashSet<>();
// noSet.add(serialNumber);
// powerPileService.addPileWhitelist(chargingStationId, noSet);
return AjaxResult.success();
}

View File

@ -37,15 +37,7 @@ public class QrImgUtils {
//3.拼接成完整图片
//3.1生成指定规则的图片名
String finallyImgFileName = DateUtil.format(new Date(), "yyyyMMddHHmmssSSS") + serialNumber + ".png";
// new ImageUtil().createXhImg(
// new File(environment.getProperty("oss.bottomImg")),
// QrCode,
// new File(environment.getProperty("oss.bottomLogoImg")),
// serialNumber,
// new File(environment.getProperty("oss.fullImgDestPath")+finallyImgFileName),
// chargingStationName,
// String.valueOf(xhpcTerminal.getNumber()),
// String.valueOf(letterMap.get(forIndex)));
new ImageUtil().fastCreateImg(
new File(environment.getProperty("oss.bottomImg")),
QrCode,

View File

@ -176,7 +176,7 @@
update_by,
</if>
<if test="null != remark and '' != remark">
remark
remark,
</if>
<if test="null != brandModel ">
brand_model
@ -259,7 +259,7 @@
#{updateBy},
</if>
<if test="null != remark and '' != remark">
#{remark}
#{remark},
</if>
<if test="null != brandModel ">
#{brandModel}
@ -355,6 +355,6 @@
</update>
<select id="countXhpcTerminal" resultType="int">
select count(id) from xhpc_charging_pile where charging_station_id = #{chargingStationId}
select count(charging_pile_id) from xhpc_charging_pile where charging_station_id = #{chargingStationId}
</select>
</mapper>