Documentation ¶
Index ¶
- Constants
- func CreateCensusBasePage(ctx context.Context, req *http.Request, basePage coreModel.Page, ...) datasetLandingPageCensus.Page
- func CreateCensusFilterOutputsPage(ctx context.Context, req *http.Request, basePage coreModel.Page, ...) datasetLandingPageCensus.Page
- func CreateCensusLandingPage(ctx context.Context, req *http.Request, basePage coreModel.Page, ...) datasetLandingPageCensus.Page
- func CreateCustomDatasetPage(ctx context.Context, req *http.Request, basePage coreModel.Page, ...) createCustomDatasetPage.Page
- func CreateEditionsList(basePage coreModel.Page, ctx context.Context, req *http.Request, ...) datasetEditionsList.Page
- func CreateFilterableLandingPage(basePage coreModel.Page, ctx context.Context, req *http.Request, ...) datasetLandingPageFilterable.Page
- func CreateVersionsList(basePage coreModel.Page, req *http.Request, d dataset.DatasetDetails, ...) datasetVersionsList.Page
- func FindVersion(versionList []zebedee.Dataset, versionURI string) zebedee.Dataset
- func MapCookiePreferences(req *http.Request, preferencesIsSet *bool, policy *coreModel.CookiesPolicy)
- func MapDownloads(downloadsList []zebedee.Download, versionURI string) []datasetPage.Download
- func MapNavigationContent(navigationContent topicModel.Navigation) []coreModel.NavigationItem
- type DatasetPage
- type StaticDatasetLandingPage
- type TimeSlice
Constants ¶
const ( Coverage = "Coverage" AreaType = "Area type" AnalyticsMaxItems = 4 )
Constants...
const ( AlertType = "alert" CorrectionAlertType = "correction" )
Constants...
const ( DimensionTime = "time" DimensionAge = "age" DimensionGeography = "geography" SixteensVersion = "30948d6" )
Constants names
const (
FilterOutput = "_filter_output"
)
Variables ¶
This section is empty.
Functions ¶
func CreateCensusBasePage ¶ added in v1.49.0
func CreateCensusBasePage(ctx context.Context, req *http.Request, basePage coreModel.Page, d dataset.DatasetDetails, version dataset.Version, initialVersionReleaseDate string, hasOtherVersions bool, allVersions []dataset.Version, latestVersionNumber int, latestVersionURL, lang string, isValidationError bool, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner, isEnableMultivariate bool) datasetLandingPageCensus.Page
CreateCensusBasePage builds a base datasetLandingPageCensus.Page with shared functionality between Dataset Landing Pages and Filter Output pages
func CreateCensusFilterOutputsPage ¶ added in v1.49.0
func CreateCensusFilterOutputsPage(ctx context.Context, req *http.Request, basePage coreModel.Page, d dataset.DatasetDetails, version dataset.Version, initialVersionReleaseDate string, hasOtherVersions bool, allVersions []dataset.Version, latestVersionNumber int, latestVersionURL, lang string, queryStrValues []string, maxNumberOfOptions int, isValidationError, hasNoAreaOptions bool, filterOutput filter.Model, fDims []sharedModel.FilterDimension, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner, isEnableMultivariate bool, dimDesc population.GetDimensionsResponse, sdc cantabular.GetBlockedAreaCountResult, population population.GetPopulationTypeResponse) datasetLandingPageCensus.Page
CreateCensusFilterOutputsPage creates a filter output page based on api model responses
func CreateCensusLandingPage ¶ added in v1.49.0
func CreateCensusLandingPage(ctx context.Context, req *http.Request, basePage coreModel.Page, d dataset.DatasetDetails, version dataset.Version, opts []dataset.Options, categorisationsMap map[string]int, initialVersionReleaseDate string, hasOtherVersions bool, allVersions []dataset.Version, latestVersionNumber int, latestVersionURL, lang string, queryStrValues []string, maxNumberOfOptions int, isValidationError bool, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner, isEnableMultivariate bool, population population.GetPopulationTypeResponse) datasetLandingPageCensus.Page
CreateCensusLandingPage creates a census-landing page based on api model responses
func CreateCustomDatasetPage ¶ added in v1.51.0
func CreateCustomDatasetPage(ctx context.Context, req *http.Request, basePage coreModel.Page, populationTypes []population.PopulationType, lang string, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner) createCustomDatasetPage.Page
CreateCustomDatasetPage builds a base datasetLandingPageCensus.Page with shared functionality between Dataset Landing Pages and Filter Output pages
func CreateEditionsList ¶
func CreateEditionsList(basePage coreModel.Page, ctx context.Context, req *http.Request, d dataset.DatasetDetails, editions []dataset.Edition, datasetID string, breadcrumbs []zebedee.Breadcrumb, lang, apiRouterVersion string, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner) datasetEditionsList.Page
CreateEditionsList creates a editions list page based on api model responses
func CreateFilterableLandingPage ¶
func CreateFilterableLandingPage(basePage coreModel.Page, ctx context.Context, req *http.Request, d dataset.DatasetDetails, ver dataset.Version, datasetID string, opts []dataset.Options, dims dataset.VersionDimensions, displayOtherVersionsLink bool, breadcrumbs []zebedee.Breadcrumb, latestVersionNumber int, latestVersionURL, lang, apiRouterVersion string, maxNumOpts int, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner) datasetLandingPageFilterable.Page
CreateFilterableLandingPage creates a filterable dataset landing page based on api model responses
func CreateVersionsList ¶
func CreateVersionsList(basePage coreModel.Page, req *http.Request, d dataset.DatasetDetails, edition dataset.Edition, versions []dataset.Version, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner) datasetVersionsList.Page
CreateVersionsList creates a versions list page based on api model responses
func FindVersion ¶ added in v1.34.0
func MapCookiePreferences ¶ added in v1.13.0
func MapCookiePreferences(req *http.Request, preferencesIsSet *bool, policy *coreModel.CookiesPolicy)
MapCookiePreferences reads cookie policy and preferences cookies and then maps the values to the page model
func MapDownloads ¶ added in v1.34.0
func MapDownloads(downloadsList []zebedee.Download, versionURI string) []datasetPage.Download
func MapNavigationContent ¶ added in v1.41.0
func MapNavigationContent(navigationContent topicModel.Navigation) []coreModel.NavigationItem
mapNavigationContent takes navigationContent as returned from the client and returns information needed for the navigation bar
Types ¶
type DatasetPage ¶ added in v1.34.0
type DatasetPage datasetPage.Page
DatasetPage is a DatasetPage representation
func CreateDatasetPage ¶ added in v1.34.0
func CreateDatasetPage(basePage coreModel.Page, ctx context.Context, req *http.Request, d zebedee.Dataset, dlp zebedee.DatasetLandingPage, bc []zebedee.Breadcrumb, versions []zebedee.Dataset, lang string, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner, navigationContent *topicModel.Navigation) DatasetPage
type StaticDatasetLandingPage ¶ added in v1.13.0
type StaticDatasetLandingPage datasetLandingPageStatic.Page
StaticDatasetLandingPage is a StaticDatasetLandingPage representation
func CreateLegacyDatasetLanding ¶ added in v1.13.0
func CreateLegacyDatasetLanding(basePage coreModel.Page, ctx context.Context, req *http.Request, dlp zebedee.DatasetLandingPage, bcs []zebedee.Breadcrumb, ds []zebedee.Dataset, localeCode string, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner, navigationContent *topicModel.Navigation) StaticDatasetLandingPage
CreateLegacyDatasetLanding maps a zebedee response struct into a frontend model to be used for rendering