I am using the steps mentioned in DXA XO implementation guide to display the promotion on the webpage. I have installed the DXA XO module in cms and website:
1)I am using XO Region Name="Example1" and RegionView="SmartTargetRegion" in my PT and CT both.
2)In CMS have created Promotion where Region defined as "Example1". and for content to use for promotion have added the component(using custom schema) mapped with dynamic CT.
3)On my webapplication page view when I am making call to the Region "Example1" using @Html.DxaRegion("Example1") it execute the Region View "SmartTargetRegion" but did not find any promotion content to render here. @Model.HasSmartTargetContent display False.it seems webpage not even make a query to promotional content
My Custom CT (Promotion Content CT) below:
JSON response when page url hit with ?format=json below:
{
"$id":"1",
"Regions":[
{
"$id":"2",
"HasSmartTargetContent":false,
"MaxItems":0,
"Entities":[
],
"Regions":[
],
"Name":"Example1",
"MvcData":{
"$id":"3",
"ControllerName":"Region",
"ControllerAreaName":"Core",
"ActionName":"Region",
"ViewName":"SmartTargetRegion",
"AreaName":"SmartTarget"
}
},
{
"$id":"4",
"Entities":[
{
"$id":"5",
"InfoText":"Showing Information For ",
"SelectorList":[
{
"$id":"6",
"CssClassName":"state_selector",
"Contentlist":[
{
"$id":"7",
"LabelText":"California",
"XpmPropertyMetadata":{
"$id":"8",
"LabelText":"tcm:Content/custom:TopRowHeader/custom:type_size[1]/custom:contentlist[1]/custom:labeltext"
}
},
{
"$id":"9",
"LabelText":"Florida",
"XpmPropertyMetadata":{
"$id":"10",
"LabelText":"tcm:Content/custom:TopRowHeader/custom:type_size[1]/custom:contentlist[2]/custom:labeltext"
}
},
{
"$id":"11",
"LabelText":"Texas",
"XpmPropertyMetadata":{
"$id":"12",
"LabelText":"tcm:Content/custom:TopRowHeader/custom:type_size[1]/custom:contentlist[3]/custom:labeltext"
}
},
{
"$id":"13",
"LabelText":"Other States",
"XpmPropertyMetadata":{
"$id":"14",
"LabelText":"tcm:Content/custom:TopRowHeader/custom:type_size[1]/custom:contentlist[4]/custom:labeltext"
}
}
],
"XpmPropertyMetadata":{
"$id":"15",
"CssClassName":"tcm:Content/custom:TopRowHeader/custom:type_size[1]/custom:title",
"Contentlist":"tcm:Content/custom:TopRowHeader/custom:type_size[1]/custom:contentlist"
}
},
{
"$id":"16",
"CssClassName":"language_selector",
"Contentlist":[
{
"$id":"17",
"LabelText":"English",
"XpmPropertyMetadata":{
"$id":"18",
"LabelText":"tcm:Content/custom:TopRowHeader/custom:type_size[2]/custom:contentlist[1]/custom:labeltext"
}
}
],
"XpmPropertyMetadata":{
"$id":"19",
"CssClassName":"tcm:Content/custom:TopRowHeader/custom:type_size[2]/custom:title",
"Contentlist":"tcm:Content/custom:TopRowHeader/custom:type_size[2]/custom:contentlist"
}
}
],
"Id":"1422",
"XpmPropertyMetadata":{
"$id":"20",
"InfoText":"tcm:Content/custom:TopRowHeader/custom:info_text",
"SelectorList":"tcm:Content/custom:TopRowHeader/custom:type_size"
},
"MvcData":{
"$id":"21",
"ControllerName":"Entity",
"ControllerAreaName":"Core",
"ActionName":"Entity",
"ViewName":"HeaderTopView",
"AreaName":"MyTestPOC",
"RegionName":"Header",
"RegionAreaName":"MyTestPOC"
},
"XpmMetadata":{
"$id":"22",
"ComponentID":"tcm:15-1422",
"ComponentModified":"2016-12-16T03:10:21",
"ComponentTemplateID":"tcm:15-1423-32",
"ComponentTemplateModified":"2016-11-28T04:09:17",
"IsRepositoryPublished":false
}
},
{
"$id":"23",
"Logo":{
"$id":"24",
"Url":"/media/MyTestLogo_tcm15-1441.png",
"FileName":"MyTestLogo.png",
"FileSize":17434,
"MimeType":"image/png",
"IsEmbedded":false,
"Id":"1441",
"XpmPropertyMetadata":{
"$id":"25"
},
"MvcData":{
"$id":"26",
"ViewName":"Image",
"AreaName":"Core"
}
},
"Search":"Search",
"Go":"Go",
"Sitemap":"Sitemap",
"SignIn":"Sign In",
"Register":"Register",
"Id":"1419",
"XpmPropertyMetadata":{
"$id":"27",
"Logo":"tcm:Content/custom:Header/custom:logo",
"Search":"tcm:Content/custom:Header/custom:search",
"Go":"tcm:Content/custom:Header/custom:go",
"Sitemap":"tcm:Content/custom:Header/custom:sitemap",
"SignIn":"tcm:Content/custom:Header/custom:signin",
"Register":"tcm:Content/custom:Header/custom:register"
},
"MvcData":{
"$id":"28",
"ControllerName":"Entity",
"ControllerAreaName":"Core",
"ActionName":"Entity",
"ViewName":"HeaderMain",
"AreaName":"MyTestPOC",
"RegionName":"Header",
"RegionAreaName":"MyTestPOC"
},
"XpmMetadata":{
"$id":"29",
"ComponentID":"tcm:15-1419",
"ComponentModified":"2016-11-30T04:56:14",
"ComponentTemplateID":"tcm:15-1418-32",
"ComponentTemplateModified":"2016-11-28T03:08:17",
"IsRepositoryPublished":false
}
},
{
"$id":"30",
"Components":[
{
"$id":"31",
"Title":"Become a Member",
"UrlLink":"/ca/en/becomeamember",
"UrlList":[
{
"$id":"32",
"LinkLabel":"Medi-Cal",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"33",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[1]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[1]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[1]/custom:displaychoice"
}
},
{
"$id":"34",
"LinkLabel":"Medicare",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"35",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[2]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[2]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[2]/custom:displaychoice"
}
},
{
"$id":"36",
"LinkLabel":"MyTest Dual Options Cal MediConnect Plan (Medicare-Medicaid Plan)",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"37",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[3]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[3]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[3]/custom:displaychoice"
}
},
{
"$id":"38",
"LinkLabel":"Covered California - MyTest Marketplace",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"39",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[4]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[4]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks[4]/custom:displaychoice"
}
}
],
"XpmPropertyMetadata":{
"$id":"40",
"Title":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:title",
"UrlLink":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:urlLink",
"UrlList":"tcm:Content/custom:LinkChain/custom:linkchainlist[1]/custom:listoflinks"
}
},
{
"$id":"41",
"Title":"Members",
"UrlLink":"/ca/en/memberlogin",
"UrlList":[
{
"$id":"42",
"LinkLabel":" Medi-Cal",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"43",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[1]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[1]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[1]/custom:displaychoice"
}
},
{
"$id":"44",
"LinkLabel":"Medicare",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"45",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[2]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[2]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[2]/custom:displaychoice"
}
},
{
"$id":"46",
"LinkLabel":"MyTest Dual Options Cal MediConnect Plan (Medicare-Medicaid Plan)",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"47",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[3]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[3]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[3]/custom:displaychoice"
}
},
{
"$id":"48",
"LinkLabel":"Covered California - MyTest Marketplace",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"49",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[4]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[4]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[4]/custom:displaychoice"
}
},
{
"$id":"50",
"LinkLabel":"Staying Healthy",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"51",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[5]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[5]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[5]/custom:displaychoice"
}
},
{
"$id":"52",
"LinkLabel":"My MyTest Portal",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
"$id":"53",
"LinkLabel":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[6]/custom:linklabel",
"LinkUrl":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[6]/custom:linkurl",
"LinkType":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks[6]/custom:displaychoice"
}
}
],
"XpmPropertyMetadata":{
"$id":"54",
"Title":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:title",
"UrlLink":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:urlLink",
"UrlList":"tcm:Content/custom:LinkChain/custom:linkchainlist[2]/custom:listoflinks"
}
},
{
"$id":"55",
"Title":"Health Care Professionals",
"UrlList":[
{
"$id":"56",
"LinkLabel":"Medicare",
"LinkUrl":"#",
"LinkType":"Link",
"XpmPropertyMetadata":{
Website Logs below:
2017-01-13 05:44:13,745 [1] INFO - -------- Initializing DXA Framework v1.6.0.223 --------
2017-01-13 05:44:13,874 [1] INFO - Using implementation type 'Sdl.Web.Tridion.DefaultCacheProvider' for interface ICacheProvider.
2017-01-13 05:44:13,876 [1] INFO - Using implementation type 'Sdl.Web.Tridion.Mapping.DefaultContentProvider' for interface IContentProvider.
2017-01-13 05:44:13,877 [1] INFO - Using implementation type 'Sdl.Web.Tridion.Navigation.StaticNavigationProvider' for interface INavigationProvider.
2017-01-13 05:44:17,329 [1] INFO - Using implementation type 'Sdl.Web.Tridion.Context.ContextServiceClaimsProvider' for interface IContextClaimsProvider.
2017-01-13 05:44:17,331 [1] INFO - Using implementation type 'Sdl.Web.Tridion.Linking.DefaultLinkResolver' for interface ILinkResolver.
2017-01-13 05:44:17,332 [1] INFO - Using implementation type 'Sdl.Web.Tridion.Mapping.DefaultRichTextProcessor' for interface IRichTextProcessor.
2017-01-13 05:44:17,332 [1] INFO - No implementation type configured for optional interface IConditionalEntityEvaluator.
2017-01-13 05:44:17,334 [1] INFO - Using implementation type 'Sdl.Web.Mvc.Html.BaseMediaHelper' for interface IMediaHelper.
2017-01-13 05:44:17,337 [1] INFO - Using implementation type 'Sdl.Web.Tridion.CdApiLocalizationResolver' for interface ILocalizationResolver.
2017-01-13 05:44:17,338 [1] INFO - Using implementation type 'Sdl.Web.Mvc.Statics.BaseStaticFileManager' for interface IStaticFileManager.
2017-01-13 05:44:17,339 [1] INFO - No implementation type configured for optional interface IUnknownLocalizationHandler.
2017-01-13 05:44:17,876 [1] DEBUG - Model type 'Sdl.Web.Modules.Core.Models.ItemList' has semantic type(s) 's:ItemList'.
2017-01-13 05:44:17,877 [1] DEBUG - Registered property 'Headline' as semantic property 's:headline'
2017-01-13 05:44:17,877 [1] DEBUG - Registered property 'ItemListElements' as semantic property 's:itemListElement'
2017-01-13 05:44:17,878 [1] DEBUG - Model type 'Sdl.Web.Modules.Core.Models.Article' has semantic type(s) 's:Article'.
2017-01-13 05:44:17,879 [1] DEBUG - Registered property 'Headline' as semantic property 's:headline'
2017-01-13 05:44:17,879 [1] DEBUG - Registered property 'Image' as semantic property 's:image'
2017-01-13 05:44:17,880 [1] DEBUG - Registered property 'Date' as semantic property 's:dateCreated'
2017-01-13 05:44:17,880 [1] DEBUG - Registered property 'Description' as semantic property 's:about'
2017-01-13 05:44:17,881 [1] DEBUG - Registered property 'ArticleBody' as semantic property 's:articleBody'
2017-01-13 05:44:17,882 [1] DEBUG - Model type 'Sdl.Web.Modules.Core.Models.Download' has semantic type(s) 's:DataDownload s:MediaObject'.
2017-01-13 05:44:17,883 [1] DEBUG - Registered property 'Description' as semantic property 's:name s:description'
2017-01-13 05:44:17,883 [1] DEBUG - Registered property 'Url' as semantic property 's:contentUrl'
2017-01-13 05:44:17,884 [1] DEBUG - Registered property 'FileSize' as semantic property 's:contentSize'
2017-01-13 05:44:17,886 [1] DEBUG - Model type 'Sdl.Web.Modules.Core.Models.Image' has semantic type(s) 's:ImageObject s:MediaObject'.
2017-01-13 05:44:17,886 [1] DEBUG - Registered property 'AlternateText' as semantic property 's:name'
2017-01-13 05:44:17,887 [1] DEBUG - Registered property 'Url' as semantic property 's:contentUrl'
2017-01-13 05:44:17,887 [1] DEBUG - Registered property 'FileSize' as semantic property 's:contentSize'
2017-01-13 05:44:17,889 [1] DEBUG - Model type 'Sdl.Web.Modules.Core.Models.Place' has semantic type(s) 's:Place'.
2017-01-13 05:44:17,889 [1] DEBUG - Registered property 'Name' as semantic property 's:name'
2017-01-13 05:44:17,890 [1] DEBUG - Registered property 'Image' as semantic property 's:image'
2017-01-13 05:44:17,891 [1] DEBUG - Registered property 'Address' as semantic property 's:address'
2017-01-13 05:44:17,891 [1] DEBUG - Registered property 'Telephone' as semantic property 's:telephone'
2017-01-13 05:44:17,892 [1] DEBUG - Registered property 'FaxNumber' as semantic property 's:faxNumber'
2017-01-13 05:44:17,892 [1] DEBUG - Registered property 'Email' as semantic property 's:email'
2017-01-13 05:44:17,893 [1] DEBUG - Registered property 'Location' as semantic property 's:geo'
2017-01-13 05:44:17,894 [1] DEBUG - Model type 'Sdl.Web.Modules.Core.Models.YouTubeVideo' has semantic type(s) 's:VideoObject s:MediaObject'.
2017-01-13 05:44:17,894 [1] DEBUG - Registered property 'Url' as semantic property 's:contentUrl'
2017-01-13 05:44:17,895 [1] DEBUG - Registered property 'FileSize' as semantic property 's:contentSize'
2017-01-13 05:44:17,896 [1] DEBUG - Model type 'Sdl.Web.Modules.Core.Models.ContentList`1[[Sdl.Web.Modules.Core.Models.Teaser, Sdl.Web.Modules.Core, Version=1.6.0.0, Culture=neutral, PublicKeyToken=null]]' has semantic type(s) 's:ItemList'.
2017-01-13 05:44:17,897 [1] DEBUG - Registered property 'Headline' as semantic property 's:headline'
2017-01-13 05:44:17,898 [1] DEBUG - Model type 'Sdl.Web.Modules.Core.Models.ContentList`1[[Sdl.Web.Modules.Core.Models.Article, Sdl.Web.Modules.Core, Version=1.6.0.0, Culture=neutral, PublicKeyToken=null]]' has semantic type(s) 's:ItemList'.
2017-01-13 05:44:17,898 [1] DEBUG - Registered property 'Headline' as semantic property 's:headline'
2017-01-13 05:44:17,910 [1] DEBUG - Model type 'Sdl.Web.Site.Areas.Test.Models.MyItem' has semantic type(s) 's:MyItemSample'.
2017-01-13 05:44:17,910 [1] DEBUG - Registered property 'name' as semantic property 's:name'
2017-01-13 05:44:17,911 [1] DEBUG - Registered property 'description' as semantic property 's:description'
2017-01-13 05:44:18,276 [7] WARN - HTML design is not published nor does file 'D:\Jhalender\GTDevelopment\src\Site\system\assets\version.json' exist on disk. Setting version to v0.0
2017-01-13 05:44:18,353 [7] DEBUG - Binary with URL '/ca/en/system/config/_all.json' is still up to date, no action required
2017-01-13 05:44:18,831 [7] DEBUG - Binary with URL '/ca/en/system/config/core.json' is still up to date, no action required
2017-01-13 05:44:18,850 [7] DEBUG - Request URL 'http://localhost:92/ca/en/landing' maps to Localization [15 ('English')]
2017-01-13 05:44:20,006 [7] DEBUG - Binary with URL '/ca/en/system/mappings/includes.json' is still up to date, no action required
2017-01-13 05:44:20,144 [7] ERROR - Could not load file or assembly 'DD4T.ContentModel.Contracts, Version=2.1.0.0, Culture=neutral, PublicKeyToken=4450e3c7f68bf872' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
System.IO.FileLoadException: Could not load file or assembly 'DD4T.ContentModel.Contracts, Version=2.1.0.0, Culture=neutral, PublicKeyToken=4450e3c7f68bf872' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
File name: 'DD4T.ContentModel.Contracts, Version=2.1.0.0, Culture=neutral, PublicKeyToken=4450e3c7f68bf872'
at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMarkHandle stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName, ObjectHandleOnStack type)
at System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean loadTypeFromPartialName)
at System.RuntimeType.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark)
at System.Type.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase)
at Sdl.Web.Tridion.Mapping.ModelBuilderPipeline..cctor()
WRN: Assembly binding logging is turned OFF.
To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.
Note: There is some performance penalty associated with assembly bind failure logging.
To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
2017-01-13 05:44:20,146 [7] WARN - An error occurred while initializing the Model Builder Pipeline. Using the Default Model Builder.
2017-01-13 05:44:20,199 [7] DEBUG - Binary with URL '/ca/en/system/mappings/schemas.json' is still up to date, no action required
2017-01-13 05:44:20,249 [7] DEBUG - Binary with URL '/ca/en/system/mappings/vocabularies.json' is still up to date, no action required
2017-01-13 05:44:20,285 [7] DEBUG - No semantic mapping found between Schema 1047 (http://www.sdl.com/web/schemas/core:DefaultMultimediaSchema) and model type 'Sdl.Web.Modules.Core.Models.Image'. Sticking with model type.
2017-01-13 05:44:20,307 [7] DEBUG - No semantic mapping found between Schema 1047 (http://www.sdl.com/web/schemas/core:DefaultMultimediaSchema) and model type 'Sdl.Web.Modules.Core.Models.Image'. Sticking with model type.
2017-01-13 05:44:20,311 [7] DEBUG - No semantic mapping found between Schema 1047 (http://www.sdl.com/web/schemas/core:DefaultMultimediaSchema) and model type 'Sdl.Web.Modules.Core.Models.Image'. Sticking with model type.
2017-01-13 05:44:20,312 [7] DEBUG - No semantic mapping found between Schema 1047 (http://www.sdl.com/web/schemas/core:DefaultMultimediaSchema) and model type 'Sdl.Web.Modules.Core.Models.Image'. Sticking with model type.
2017-01-13 05:44:20,313 [7] DEBUG - No semantic mapping found between Schema
Log.config
). You can also try to retrieve the Page with?format=json
in the URL; I'm curious how theXpmMetadata
of the ST Region looks in the JSON.