dongfeng-pay/legend/controllers/expection/expection.go

20 lines
543 B
Go
Raw Normal View History

2021-04-27 15:33:49 +08:00
package expection
import (
"github.com/beego/beego/v2/server/web"
"html/template"
"net/http"
)
func PageNotFind(rw http.ResponseWriter, r *http.Request) {
t, _ := template.New("404.html").ParseFiles(web.BConfig.WebConfig.ViewsPath + "/error/404.html")
data := make(map[string]interface{})
t.Execute(rw, data)
}
func SystemExpection(rw http.ResponseWriter, r *http.Request) {
t, _ := template.New("503.html").ParseFiles(web.BConfig.WebConfig.ViewsPath + "/error/503.html")
data := make(map[string]interface{})
t.Execute(rw, data)
}