web.go 319 B

123456789101112131415161718
  1. package utils
  2. import (
  3. "github.com/astaxie/beego/logs"
  4. )
  5. func GetStaticDir() string {
  6. if IsExist("static/web") {
  7. return "static/web"
  8. } else if IsExist("frontend/dist") {
  9. return "frontend/dist"
  10. } else {
  11. logs.Warn("no static web dir for static/web or frontend/dist, please check")
  12. }
  13. return "static/web"
  14. }