pipIrr-platform/pipIrr-global/src/main/java/com/dy/pipIrrGlobal/command/ComSupport.java
@@ -19,6 +19,7 @@
import com.dy.pipIrrGlobal.pojoSe.SeVirtualCard;
import jakarta.annotation.PostConstruct;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.http.HttpEntity;
import org.springframework.http.HttpHeaders;
import org.springframework.http.HttpMethod;
@@ -48,13 +49,20 @@
    //@Value("${mw.comSendUrl}")
    protected String comSendUrl;
    protected static String controllerType = null;
    protected static Integer projectNo = null;
    //protected static String controllerType = null;
    //protected static Integer projectNo = null;
    @Value("${project.projectNo}")
    protected Integer projectNo;
    @Value("${project.controllerType}")
    protected String controllerType;
    protected String commandTypeOuter = CommandType.outerCommand;
    // 存储实例化的 CompletableFuture<Data> 对象
    protected static Map<Long, Object> features = new HashMap<>();
    protected static Boolean setuped = false;
    //protected static Boolean setuped = false;
    @Autowired
    private RestTemplate restTemplate;
@@ -89,11 +97,11 @@
    /**
     * 获取系统配置参数
     */
    public void setUp() {
        controllerType = comSupport.baSettingsMapper.getItemValue("controllerType");
        projectNo = Integer.parseInt(comSupport.baSettingsMapper.getItemValue("projectNo"));
        setuped = true;
    }
    //public void setUp() {
    //    controllerType = comSupport.baSettingsMapper.getItemValue("controllerType");
    //    projectNo = Integer.parseInt(comSupport.baSettingsMapper.getItemValue("projectNo"));
    //    setuped = true;
    //}
    /**
     * 生成订单号
@@ -322,6 +330,21 @@
            seVirtualCardMapper.updateByPrimaryKeySelective(virtualCard);
        }
        // 如果是开发命令(92-平台开阀,91-小程序开阀),返回结果中添加阀控器地址、虚拟卡编号、订单号
        if(commandCode.equals("92") || commandCode.equals("97")) {
            JSONObject job_response = (JSONObject) JSON.toJSON(response_CallBack);
            JSONObject job_param = (JSONObject) JSON.toJSON(param);
            JSONObject job_data = job_response.getJSONObject("content").getJSONObject("data");
            job_data.remove("success");
            job_data.put("intakeId", intakeId);
            job_data.put("rtuAddr", rtuAddr);
            job_data.put("vcNum", job_param.getString("icCardNo"));
            job_data.put("orderNo", job_param.getString("orderNo"));
            response_CallBack = JSON.parseObject(job_response.toJSONString(), BaseResponse.class);
        }
        // 回调返回的内容,回调结果写入命令日志表的任务由中间件完成
        return response_CallBack;