PublicDashboards: Add middleware function (#80582)

This commit is contained in:
Juan Cabanas 2024-01-18 15:12:29 -03:00 committed by GitHub
parent 0ba7866e2c
commit fb4125dfbb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 16 additions and 7 deletions

View File

@ -83,3 +83,6 @@ func (m *Middleware) HandleView(c *contextmodel.ReqContext) {
}
func (m *Middleware) HandleAccessView(c *contextmodel.ReqContext) {
}
func (m *Middleware) HandleConfirmAccessView(c *contextmodel.ReqContext) {
}

View File

@ -12,18 +12,23 @@ type FakePublicDashboardMiddleware struct {
mock.Mock
}
// HandleAccessView provides a mock function with given fields: c
func (_m *FakePublicDashboardMiddleware) HandleAccessView(c *contextmodel.ReqContext) {
_m.Called(c)
}
// HandleApi provides a mock function with given fields: c
func (_m *FakePublicDashboardMiddleware) HandleApi(c *contextmodel.ReqContext) {
_m.Called(c)
}
// HandleGet provides a mock function with given fields: c
func (_m *FakePublicDashboardMiddleware) HandleView(c *contextmodel.ReqContext) {
// HandleConfirmAccessView provides a mock function with given fields: c
func (_m *FakePublicDashboardMiddleware) HandleConfirmAccessView(c *contextmodel.ReqContext) {
_m.Called(c)
}
// HandleRequestOrConfirmAccess provides a mock function with given fields: c
func (_m *FakePublicDashboardMiddleware) HandleAccessView(c *contextmodel.ReqContext) {
// HandleView provides a mock function with given fields: c
func (_m *FakePublicDashboardMiddleware) HandleView(c *contextmodel.ReqContext) {
_m.Called(c)
}

View File

@ -1,4 +1,4 @@
// Code generated by mockery v2.32.0. DO NOT EDIT.
// Code generated by mockery v2.36.1. DO NOT EDIT.
package publicdashboards

View File

@ -1,4 +1,4 @@
// Code generated by mockery v2.32.0. DO NOT EDIT.
// Code generated by mockery v2.36.1. DO NOT EDIT.
package publicdashboards

View File

@ -1,4 +1,4 @@
// Code generated by mockery v2.32.0. DO NOT EDIT.
// Code generated by mockery v2.36.1. DO NOT EDIT.
package publicdashboards

View File

@ -70,4 +70,5 @@ type Middleware interface {
HandleApi(c *contextmodel.ReqContext)
HandleView(c *contextmodel.ReqContext)
HandleAccessView(c *contextmodel.ReqContext)
HandleConfirmAccessView(c *contextmodel.ReqContext)
}