package net.northking.cctp.mobile.api.device;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import net.northking.cctp.common.http.ResultWrapper;
import net.northking.cctp.mobile.db.service.MobileConnectService;
import net.northking.cctp.mobile.dto.device.DeviceUiTreeDto;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@Api("业务层设备管理列表")
@RequestMapping("/v1/device/mobile")
public class DeviceMobileCtrl {

    private Logger logger = LoggerFactory.getLogger(DeviceMobileCtrl.class);

    @Autowired
    private MobileConnectService mobileConnectService;

    @ApiOperation("获取UI树")
    @PostMapping("/getUiTree")
    public ResultWrapper<String> getUiTree(@RequestBody DeviceUiTreeDto dto) {

        String result = mobileConnectService.getUiTree(dto);



        return new ResultWrapper<String>().success(result);
    }
}
