基础整理
This commit is contained in:
+13
-3
@@ -2,7 +2,11 @@ package main
|
||||
|
||||
import (
|
||||
. "code.hoteas.com/golang/hotime"
|
||||
"code.hoteas.com/golang/hotime/dri/ddsms"
|
||||
"code.hoteas.com/golang/hotime/dri/wechat"
|
||||
"code.hoteas.com/golang/hotime/example/app"
|
||||
"code.hoteas.com/golang/hotime/example/salesman"
|
||||
|
||||
//. "code.hoteas.com/golang/hotime/common"
|
||||
"fmt"
|
||||
"time"
|
||||
@@ -14,8 +18,13 @@ func main() {
|
||||
//fmt.Println("0123456"[1:7])
|
||||
appIns := Init("config/config.json")
|
||||
app.InitApp(appIns)
|
||||
//a:=Map{}
|
||||
//a.GetBool()
|
||||
//初始化短信
|
||||
ddsms.DDY.Init(appIns.Config.GetString("smsKey"))
|
||||
//初始化公众号配置
|
||||
wechat.H5Program.Init(appIns.Config.GetString("wechatAppID"), appIns.Config.GetString("wechatAppSecret"))
|
||||
//初始化小程序
|
||||
wechat.MiniProgram.Init(appIns.Config.GetString("wechatMiniAppID"), appIns.Config.GetString("wechatMiniAppSecret"))
|
||||
|
||||
appIns.SetConnectListener(func(that *Context) (isFinished bool) {
|
||||
//that.Session("admin_id", 1)
|
||||
|
||||
@@ -30,6 +39,7 @@ func main() {
|
||||
// return isSuccess
|
||||
//})
|
||||
appIns.Run(Router{
|
||||
"app": app.Project,
|
||||
"salesman": salesman.Project,
|
||||
"app": app.Project,
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user