package cn.iocoder.yudao.module.system.api.remote;

import cn.iocoder.yudao.module.system.api.remote.dto.RemoteRobotMaxSpeedDTO;
import cn.iocoder.yudao.module.system.service.remote.RobotMaxSpeedService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.Collections;
import java.util.List;

@Slf4j
@RestController // 提供 RESTful API 接口，给 Feign 调用
@Validated
public class RemoteRobotMaxSpeedApiImpl implements RemoteRobotMaxSpeedApi{

    @Resource
    private RobotMaxSpeedService robotMaxSpeedService;

    @Override
    public List<RemoteRobotMaxSpeedDTO> getRobotMaxSpeedPage() {
        return robotMaxSpeedService.getAllRobotMaxSpeedList();
    }

    @Override
    public void updateRobotMaxSpeedPage(List<RemoteRobotMaxSpeedDTO> list) {
        robotMaxSpeedService.updateRobotMaxSpeedList(list);
    }
}
