| | |
| | | package com.ruoyi.jianguan.util; |
| | | |
| | | import com.alibaba.fastjson2.JSONObject; |
| | | import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; |
| | | import com.ruoyi.account.api.feignClient.AppUserClient; |
| | | import com.ruoyi.account.api.model.TAppUser; |
| | | import com.ruoyi.chargingPile.api.feignClient.ChargingGunClient; |
| | |
| | | import com.ruoyi.order.api.model.TChargingOrder; |
| | | import com.ruoyi.order.api.vo.TChargingOrderVo; |
| | | import com.ruoyi.other.api.domain.Operator; |
| | | import com.ruoyi.other.api.domain.TSystemConfiguration; |
| | | import com.ruoyi.other.api.feignClient.OtherClient; |
| | | import lombok.extern.slf4j.Slf4j; |
| | | import org.springframework.data.redis.core.RedisTemplate; |
| | | import org.springframework.scheduling.annotation.Scheduled; |
| | |
| | | private ChargingOrderClient chargingOrderClient; |
| | | @Resource |
| | | private AppUserClient appUserClient; |
| | | |
| | | @Resource |
| | | private OtherClient otherClient; |
| | | |
| | | @Resource |
| | | private RedisTemplate redisTemplate; |
| | |
| | | chuanYiChongSuperviseUtil.notificationStationStatus(new Operator(), jsonObject); |
| | | break; |
| | | case 4: |
| | | tempStatus=3; |
| | | jsonObject.put("StartChargeSeqStat",tempStatus); |
| | | if (startTime!=null){ |
| | | jsonObject.put("StartTime",startTime.format(java.time.format.DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"))); |
| | | }else{ |
| | | LocalDateTime now = LocalDateTime.now(); |
| | | // 转化为yyyy-MM-dd HH:mm:ss格式字符串 |
| | | jsonObject.put("StartTime",now.format(java.time.format.DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss"))); |
| | | } |
| | | chuanYiChongSuperviseUtil.notificationStationStatus(new Operator(), jsonObject); |
| | | break; |
| | | case 5: |
| | | jsonObject.put("StartChargeSeqStat",4); |
| | |
| | | } |
| | | }); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | @Scheduled(cron = "0 0 0 * * ?") |
| | | public void reset() { |
| | | String electricity = KsolarUtils.getElectricity(); |
| | | otherClient.reset(electricity); |
| | | |
| | | } |
| | | |
| | | |
| | | } |