package com.yh.saas.plugin.yiliangyiyun.controller;


import com.yh.saas.plugin.yiliangyiyun.entity.EnabledInfo;
import com.yh.saas.plugin.yiliangyiyun.service.IEnabledInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * <p>
 * 记录启用信息 前端控制器
 * </p>
 *
 * @author Gdc
 * @since 2021-12-15
 */
@RestController
@RequestMapping("/enabledInfo")
public class EnabledInfoController {
    @Autowired
    private IEnabledInfoService iEnabledInfoService;
    /**
     * 启用信息查看
     * @param enabledInfo
     * @return
     */
    @GetMapping("/getEnabledInfo")
    public EnabledInfo getEnabledInfo(EnabledInfo enabledInfo){
        return iEnabledInfoService.getEnabledInfo(enabledInfo);
    }
    /**
     * 添加（编辑）启用信息
     * @param enabledInfo
     * @return
     */
    @PostMapping("/api/setEnabledInfo")
    public String setEnabledInfo(@RequestBody EnabledInfo enabledInfo){
        return iEnabledInfoService.setEnabledInfo(enabledInfo);
    }
}

