Beispiel #1
0
func mainPageMegaLocals(en bool, ds *calldb.DataStore) *MegaLocals {
	locals := ds.GetMainPageLocalsFromCache(en)
	my.P("locals in toMegaLocas.go")
	my.P(locals)
	// html := my.ParseTemplateNoExtMin("mainPageMainContent", locals.MainPageCodes)
	html := minContentByLayout("mainPageMainContent", locals.MainPageCodes)

	return &MegaLocals{

		Title: template.HTML(locals.Title), Desc: locals.Desc, Keywords: locals.Keywords, NextNumbers: locals.NextNumbers,
		MainContent: html,
	}
}
Beispiel #2
0
func regionMegaLocals(regionId string, en bool, ds *calldb.DataStore) *MegaLocals {
	locals := ds.GetRegionLocals(regionId, en)
	if locals == nil {
		return nil
	} else {
		html := locals.Codes
		title := my.PrepareSymbolsForHtml(locals.Title)
		my.Pat("title in regionMegaLocals")
		my.P(title)
		return &MegaLocals{
			Title: template.HTML(my.PrepareSymbolsForHtml(title)), Desc: locals.Desc, Keywords: locals.Keywords, NextNumbers: locals.NextNumbers,
			MainContent: html,
		}
	}
}