package com.wteam.controller.hardware;

import com.wteam.framework.common.vo.ResultMessage;
import com.wteam.framework.modules.book.service.OrderInfoService;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.extern.slf4j.Slf4j;
import org.nfunk.jep.function.Sum;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.security.KeyStore;

/**
 * @author doncic
 * @date 2023/10/14 13:34
 */

@Slf4j
@Tag(name = "轮询相关接口管理")
@RestController
@RequestMapping("/v1/poll")
public class PollingController {

    @Autowired
    private OrderInfoService orderInfoService;


    @Operation(summary = "轮询计时码订单状态")
    @GetMapping("/getTimer/{userId}")
    public ResultMessage getTimer(@PathVariable String userId) {
        return orderInfoService.getTimer(userId);

    }
}
