Documentation
¶
Index ¶
- Constants
- func AroundONS(homepageData zebedee.HomepageContent, images map[string]image.ImageDownload) []model.Feature
- func Census(req *http.Request, cfg *config.Config, localeCode string, ...) model.CensusPage
- func CensusLegacy(req *http.Request, cfg *config.Config, localeCode string, ...) model.CensusPage
- func FeaturedContent(homepageData zebedee.HomepageContent, images map[string]image.ImageDownload) []model.Feature
- func Homepage(cfg config.Config, localeCode string, basePage coreModel.Page, ...) model.Page
- func MainFigure(ctx context.Context, id, datePeriod, differenceInterval string, ...) *model.MainFigure
- type TrendInfo
Constants ¶
View Source
const ( // PeriodYear is the string value for year time period PeriodYear = "year" // PeriodQuarter is the string value for quarter time period PeriodQuarter = "quarter" // PeriodMonth is the string value for month time period PeriodMonth = "month" CensusURI = "/census" CensusPageType = "census" CensusTitle = "Census" )
Variables ¶
This section is empty.
Functions ¶
func AroundONS ¶ added in v1.12.0
func AroundONS(homepageData zebedee.HomepageContent, images map[string]image.ImageDownload) []model.Feature
AroundONS takes the homepageContent as returned from the client and returns an array of featured content
func Census ¶ added in v1.16.0
func Census(req *http.Request, cfg *config.Config, localeCode string, basePage coreModel.Page, navigationContent *topicModel.Navigation, emergencyBannerContent zebedee.EmergencyBanner, censusSubTopics []model.Topics) model.CensusPage
Census maps data to our census frontend model
func CensusLegacy ¶ added in v1.32.0
func CensusLegacy(req *http.Request, cfg *config.Config, localeCode string, basePage coreModel.Page, navigationContent *topicModel.Navigation, emergencyBannerContent zebedee.EmergencyBanner) model.CensusPage
func FeaturedContent ¶ added in v1.6.0
func FeaturedContent(homepageData zebedee.HomepageContent, images map[string]image.ImageDownload) []model.Feature
FeaturedContent takes the homepageContent as returned from the client and returns an array of featured content
func Homepage ¶
func Homepage(cfg config.Config, localeCode string, basePage coreModel.Page, mainFigures map[string]*model.MainFigure, featuredContent, aroundONS *[]model.Feature, serviceMessage string, emergencyBannerContent zebedee.EmergencyBanner, navigationContent *topicModel.Navigation) model.Page
Homepage maps data to our homepage frontend model
func MainFigure ¶ added in v1.1.0
func MainFigure(ctx context.Context, id, datePeriod, differenceInterval string, figure zebedee.TimeseriesMainFigure, trendInfo TrendInfo) *model.MainFigure
MainFigure maps a single main figure object
Types ¶
Click to show internal directories.
Click to hide internal directories.