package com.kiisoo.ic.activity.controller;

import com.kiisoo.ic.activity.bean.WelcomeVO;
import com.kiisoo.ic.common.BaseController;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.*;

import java.util.Map;

@RestController
@Api(value = "后台-欢迎语", tags = {"后台-欢迎语"})
@RequestMapping(value = "/welcome")
@Slf4j
public class WelcomeController extends BaseController {

    @ApiOperation(value = "欢迎语列表")
    @GetMapping("/list")
    public Map<String, Object> list() {
        return data(null);
    }

    @ApiOperation(value = "欢迎语详情")
    @GetMapping("/detail")
    public Map<String, Object> detail() {
        return data(null);
    }

    @ApiOperation(value = "欢迎语修改/保存")
    @PostMapping("/save")
    public Map<String, Object> save(@RequestBody WelcomeVO welcomeVO) {
        // TODO 先创建schedule，再创建case，再创建instance（三者都是一对一关系，category_code = welcome），并保存相关参数，关联店铺
        return data(null);
    }

    @ApiOperation(value = "欢迎语删除")
    @PostMapping("/delete")
    public Map<String, Object> delete() {
        return data(null);
    }
}
