| | |
| | | String url="http://"+dinf.getDevIp()+":8080/webService/startTest"; |
| | | //将请求头部和参数合成一个请求 |
| | | MultiValueMap<String, Object> paramMap = new LinkedMultiValueMap<>(); |
| | | paramMap.add("testType",type); |
| | | paramMap.add("testType",type);//1 放电,2 充电 |
| | | ResultA200Dto dto= (ResultA200Dto) TestparamHttpUtil.postforform_dataA200(restTemplate,url,paramMap); |
| | | return dto; |
| | | } |
| | | //a200一体机暂停/继续 |
| | | public Object pauseA200Param(int devId, int type) { |
| | | QueryWrapper wrapper=new QueryWrapper(); |
| | | wrapper.eq("dev_id",devId); |
| | | wrapper.last("limit 1"); |
| | | DevInf dinf=dinfMapper.selectOne(wrapper); |
| | | String url="http://"+dinf.getDevIp()+":8080/webService/pauseTest"; |
| | | //将请求头部和参数合成一个请求 |
| | | MultiValueMap<String, Object> paramMap = new LinkedMultiValueMap<>(); |
| | | paramMap.add("controlType",type);//1 暂停测试 ,2继续测试 |
| | | ResultA200Dto dto= (ResultA200Dto) TestparamHttpUtil.postforform_dataA200(restTemplate,url,paramMap); |
| | | return dto; |
| | | } |
| | |
| | | a200Param.setChargePower(dto.getChargePower()); |
| | | a200Param.setBatteryTemperatureProtect(dto.getBatteryTemperatureProtect()); |
| | | } |
| | | |
| | | |
| | | } |