Add proxy for managing tiles
This commit is contained in:
parent
d6407933f8
commit
3743d63692
10 changed files with 316 additions and 198 deletions
|
|
@ -2,9 +2,12 @@ package sync
|
|||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"html/template"
|
||||
"net/http"
|
||||
|
||||
"github.com/Gleipnir-Technology/nidus-sync/background"
|
||||
"github.com/Gleipnir-Technology/nidus-sync/config"
|
||||
"github.com/Gleipnir-Technology/nidus-sync/db/models"
|
||||
"github.com/Gleipnir-Technology/nidus-sync/html"
|
||||
nhttp "github.com/Gleipnir-Technology/nidus-sync/http"
|
||||
|
|
@ -13,6 +16,7 @@ import (
|
|||
|
||||
type contentReviewPool struct {
|
||||
ArcgisAccessToken string
|
||||
URLTiles template.HTMLAttr
|
||||
}
|
||||
type contentReviewRoot struct{}
|
||||
|
||||
|
|
@ -30,6 +34,7 @@ func getReviewPool(ctx context.Context, r *http.Request, org *models.Organizatio
|
|||
}
|
||||
return html.NewResponse("sync/review/pool.html", contentReviewPool{
|
||||
ArcgisAccessToken: access_token,
|
||||
URLTiles: template.HTMLAttr(fmt.Sprintf(`url-tiles="%s"`, config.MakeURLNidus("/api/tile/{z}/{y}/{x}"))),
|
||||
}), nil
|
||||
}
|
||||
func getReviewRoot(ctx context.Context, r *http.Request, org *models.Organization, user *models.User) (*html.Response[contentReviewRoot], *nhttp.ErrorWithStatus) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue