Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DetectViewsDir ¶
DetectViewsDir 解决 go mod 模式无法注册 qor-admin 等包的 views 如果 pkgname 和 subpath 都是空字符,则检查 pkgorg 是否是绝对路径, 同时会在 $gopath/src, vendor, 等目录下循环检查 pkgorg 项目是否存在。 否则会在 $gopath/pkg/mod/ 目录下(go mod 模式) pkgorg+pkgname+subpath (subpath 为空字符则会默认为 views ,默认会视图目录) 路径是否存在, 如果需要检查非 views 目录例如 */*/views 或者 user/theme/local ,则需要设置 subpath 为 */*/views 或者 user/theme/local 。 只要检查存在目录就会返回相关路径
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.