General Configuration

You could customize Admin with AdminConfig struct when initializing it, here are some general configurations:

type AdminConfig struct {
  SiteName       string
  DB             *gorm.DB
  Auth           Auth
  SessionManager session.ManagerInterface
  I18n           I18n
  AssetFS        assetfs.Interface


QOR Admin provides a default dashboard page with some dummy text. If you want to customize the dashboard, you can create a file dashboard.tmpl in QOR view paths, QOR Admin will load it as Golang templates when rendering the dashboard page.

If you want to disable the dashboard, you can redirect it to some other page, for example:

Admin.GetRouter().Get("/", func(c *admin.Context) {
  http.Redirect(c.Writer, c.Request, "/admin/clients", http.StatusSeeOther)

results matching ""

    No results matching ""