package com.cm.plugin.controller.routes;

import com.cm.common.constants.ISystemConstant;
import io.swagger.annotations.Api;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.servlet.ModelAndView;

/**
 * When you feel like quitting. Think about why you started
 * 当你想要放弃的时候，想想当初你为何开始
 *
 * @ClassName: SensitiveWordsRouteController
 * @Description: 敏感词
 * @Author: WangGeng
 * @Date: 2020/6/17 3:36 下午
 * @Version: 1.0
 **/
@Api(tags = ISystemConstant.API_TAGS_SYSTEM_PREFIX + "敏感词接口")
@Controller
@RequestMapping(ISystemConstant.ROUTE_PREFIX + "/sensitivewords")
public class SensitiveWordsRouteController {

    @GetMapping("listsensitivewords")
    public ModelAndView listSensitiveWords() {
        ModelAndView mv = new ModelAndView("list-sensitivewords");
        return mv;
    }

    @GetMapping("savesensitivewords")
    public ModelAndView saveSensitiveWords() {
        ModelAndView mv = new ModelAndView("save-sensitivewords");
        return mv;
    }

    @GetMapping("updatesensitivewords")
    public ModelAndView updateSensitiveWords(@RequestParam("sensitiveWordsId") String sensitiveWordsId) {
        ModelAndView mv = new ModelAndView("update-sensitivewords");
        mv.addObject("sensitiveWordsId", sensitiveWordsId);
        return mv;
    }

    @GetMapping("upload/saveuploadexcel")
    public ModelAndView saveUploadExcel() {
        ModelAndView mv = new ModelAndView("upload/save-upload-excel");
        return mv;
    }

}
