package router

import (
	"kra/internal/plugin/announcement/api"

	"gorm.io/gorm"
)

var Router *router

type router struct {
	Info *InfoRouter
}

// NewRouter 创建路由实例
func NewRouter(db *gorm.DB) *router {
	apiInstance := api.NewApi(db)
	r := &router{
		Info: NewInfoRouter(apiInstance.Info),
	}
	Router = r
	return r
}
