mirror of
				https://github.com/TeaOSLab/EdgeAdmin.git
				synced 2025-11-04 05:00:25 +08:00 
			
		
		
		
	
		
			
				
	
	
		
			19 lines
		
	
	
		
			483 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			19 lines
		
	
	
		
			483 B
		
	
	
	
		
			Go
		
	
	
	
	
	
package dashboard
 | 
						|
 | 
						|
import (
 | 
						|
	"github.com/TeaOSLab/EdgeAdmin/internal/configloaders"
 | 
						|
	"github.com/TeaOSLab/EdgeAdmin/internal/web/helpers"
 | 
						|
	"github.com/iwind/TeaGo"
 | 
						|
)
 | 
						|
 | 
						|
func init() {
 | 
						|
	TeaGo.BeforeStart(func(server *TeaGo.Server) {
 | 
						|
		server.Prefix("/dashboard").
 | 
						|
			Data("teaMenu", "dashboard").
 | 
						|
			Helper(helpers.NewUserMustAuth(configloaders.AdminModuleCodeCommon)).
 | 
						|
			GetPost("", new(IndexAction)).
 | 
						|
			Post("/restartLocalAPINode", new(RestartLocalAPINodeAction)).
 | 
						|
			EndAll()
 | 
						|
	})
 | 
						|
}
 |