renkang
2024-12-09 515bad8aa248e41bfb402b949b52e95aec70a992
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
package com.doumee.api;
 
import com.doumee.api.BaseController;
import com.doumee.core.model.ApiResponse;
import com.doumee.service.business.impl.hksync.HkSyncEmpowerServiceImpl;
import com.doumee.service.business.impl.hksync.HkSyncParkServiceImpl;
import com.doumee.service.business.impl.hksync.fhk.HkSyncVehicleFromHKServiceImpl;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
 
import java.util.Date;
 
/**
 * @author 江蹄蹄
 * @date 2023/11/30 15:33
 */
@Api(tags = "停车场接口")
@RestController
@RequestMapping("/timer/park")
public class HkParkTimerController extends BaseController {
 
    @Autowired
    private HkSyncVehicleFromHKServiceImpl hkSyncVehicleFromHKService;
    @Autowired
    private HkSyncParkServiceImpl hkSyncParkService;
 
    @ApiOperation("开启定时车辆包期授权")
    @GetMapping("/syncParkBookData")
    public ApiResponse syncParkBookData() {
        hkSyncParkService.syncParkBookData();
        return ApiResponse.success("开启定时车辆包期授权成功");
    }
    @ApiOperation("开启定时查询车辆查询")
    @GetMapping("/syncVehicleUpdateData")
    public ApiResponse syncVehicleUpdateData() {
        hkSyncVehicleFromHKService.syncVehicleUpdateData(new Date(System.currentTimeMillis()-24*60*60*1000));
        return ApiResponse.success("开启定时查询车辆查询成功");
    }
 
}