add routers themes

This commit is contained in:
张超
2025-04-09 16:56:05 +08:00
parent 577cd10161
commit 33cb413a12
14 changed files with 275 additions and 118 deletions

View File

@@ -4,7 +4,7 @@
@File : config.py
*/
package conf
package config
import (
"fmt"
@@ -35,6 +35,7 @@ type Project struct {
StaticUrlMapPath string
TemplateGlob string
MediaFilePath string
CurrentTheme string
}
type Server struct {
@@ -51,7 +52,7 @@ var (
)
func SetUp() {
cfg, err := ini.Load("conf/conf.ini")
cfg, err := ini.Load("config/conf.ini")
if err != nil {
panic(err)
}
@@ -100,3 +101,9 @@ func SetUp1() {
fmt.Printf("Server Port: %d\n", serverPort)
fmt.Printf("TemplateGlob: %s\n", templateGlob)
}
func GetCurrentTheme() string {
return "default"
}
func SetCurrentTheme(theme string) {
}

View File

@@ -23,4 +23,7 @@ project:
server:
Port: 7890
ReadTimeout: 60
WriteTimeout: 60
WriteTimeout: 60
theme:
current: "default"