| | |
| | | import org.springframework.web.bind.annotation.*; |
| | | |
| | | import javax.annotation.Resource; |
| | | import java.security.NoSuchAlgorithmException; |
| | | import java.text.ParseException; |
| | | |
| | | @RequestMapping("interface") |
| | | @RestController |
| | | @Api(tags = "第三方接口") |
| | | public class InterFaceController { |
| | | public class InterFaceController extends BaseController{ |
| | | @Resource |
| | | private InterfaceService service; |
| | | @GetMapping("/getBattInf") |
| | |
| | | |
| | | @GetMapping("/createInterface") |
| | | @ApiOperation("生成第三方验证码") |
| | | public Response createInterface(@RequestParam String interfaceName) { |
| | | public Response createInterface(@RequestParam String interfaceName) throws NoSuchAlgorithmException { |
| | | return service.createInterface(interfaceName); |
| | | } |
| | | |
| | |
| | | public Response getBattHistoryDataList(@RequestBody BattRealdata data, @RequestParam String interfaceNumber) throws ParseException, InterruptedException { |
| | | return service.getBattHistoryDataList(data, interfaceNumber); |
| | | } |
| | | |
| | | /** |
| | | * 1.电池基本信息:电池品牌、电池型号、投入使用时间、标称容量、电池组id |
| | | * 2.运行数据:实际容量、电池组数、负载电流、续航时长 |
| | | */ |
| | | @GetMapping("/getBattGroupDataList") |
| | | @ApiOperation("获取电池的数据信息,以上注释包含所有细节") |
| | | public Response getBattGroupDataList(@RequestParam String stationId, @RequestParam String interfaceNumber){ |
| | | return service.getBattGroupDataList(stationId, interfaceNumber); |
| | | } |
| | | } |