Removed use of absolute urls in dashboard search and dashlist, root_url option is now not required, it is required if you use oauth or proxy grafana under suburl, #1483

This commit is contained in:
Torkel Ödegaard
2015-02-17 18:43:37 +01:00
parent 946afccbb5
commit 26eb6e559e
4 changed files with 11 additions and 18 deletions

View File

@ -4,7 +4,6 @@ import (
"github.com/grafana/grafana/pkg/bus"
"github.com/grafana/grafana/pkg/middleware"
m "github.com/grafana/grafana/pkg/models"
"github.com/grafana/grafana/pkg/setting"
)
// TODO: this needs to be cached or improved somehow
@ -76,9 +75,6 @@ func Search(c *middleware.Context) {
}
result.Dashboards = query.Result
for _, dash := range result.Dashboards {
dash.Url = setting.ToAbsUrl("dashboard/db/" + dash.Slug)
}
}
c.JSON(200, result)