package com.lightinit.hsdataportal.controller.share;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

/**
 * @author WangYao
 * @date 2018/7/8 16:09
 * @description 静态页控制器
 */
@Controller("shareStaticController")
@RequestMapping(value = {"/share/static"})
public class StaticController {

    @RequestMapping(value = "/{page}")
    public String index(@PathVariable String page){
        String validPage = page.replace("../", "").replace("./", "");
        validPage = "share/static/" + validPage;
        return validPage;
    }
}
