TestController.java 1.15 KB
package com.ruoyi.controller;

import com.ruoyi.common.core.domain.ResponseResult;
import com.ruoyi.job.DriverJob;
import com.ruoyi.service.key.location.LinggangKeyWorkLocationService;
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;

/**
 * @author liujun
 * @date 2024年07月30日 14:37
 */
@RestController
@RequestMapping("/test")
public class TestController {
    @Autowired
    private DriverJob driverJob;
    @Autowired
    private LinggangKeyWorkLocationService keyWorkLocationService;

    @GetMapping(value = "/test")
    @ApiOperation("test")
    public ResponseResult<Boolean> test() {
        driverJob.getSchedulingInfo("02:30:30");
        return ResponseResult.success();
    }

    @GetMapping(value = "/key/info/local")
    @ApiOperation("/key/info/local")
    public ResponseResult<Boolean> testKeyInfoLocal() {
        keyWorkLocationService.insertJob("2024-07-30");
        return ResponseResult.success();
    }
}