实现路径规则部分功能

This commit is contained in:
GoEdgeLab
2020-09-21 19:51:50 +08:00
parent f796a1d4d7
commit c126d06f70
50 changed files with 630 additions and 114 deletions

View File

@@ -20,6 +20,11 @@ type ParentAction struct {
rpcClient *rpc.RPCClient
}
// 可以调用自身的一个简便方法
func (this *ParentAction) Parent() *ParentAction {
return this
}
func (this *ParentAction) ErrorPage(err error) {
if err == nil {
return
@@ -64,6 +69,10 @@ func (this *ParentAction) SecondMenu(menuItem string) {
this.Data["secondMenuItem"] = menuItem
}
func (this *ParentAction) TinyMenu(menuItem string) {
this.Data["tinyMenuItem"] = menuItem
}
func (this *ParentAction) AdminId() int64 {
return this.Context.GetInt64("adminId")
}