Archive
SharePoint 2013: Item template not called in JSLink with group rendering
Hi Friends,
I have explained the Group rendering with JSLink in one my previous blog. I will explain a common problem and a solution for that while group rendering with JSLink.
Scenario:
While rendering grouping in view with JSLink, We normally face an issue that item rendering handler ‘overrideCtx.Templates.Item’ is not getting called. Group rendering was working fine in my case but not item level rendering.
Solution:
Initially I thought something wrong with JSLink file but after analysing and debugging I found the problem is with the grouping configured in data view.
To fix this issue edit your data view and go to grouping section of the view. Change ‘By default, show groupings’ setting to ‘Expanded’ and save the view and bingo it will start working.
Following image shows the setting in data view –
If you are provisioning data view declaratively then you need to add Collapse=”FALSE” to your <GroupBy node.
Possible reason for this problem is, while the groups shown in collapsed state item in that group are not loaded initially and once you click to expand the group it will be loaded on demand hence item template not gets called initially as items not loaded.
Hope this will help some of the developer looking for same kind of answer.
Happy coding!!!

Blog Stats
- 104,195 hits
Archives
- November 2019
- July 2019
- September 2018
- July 2018
- November 2017
- October 2017
- September 2017
- August 2017
- July 2017
- June 2017
- May 2017
- April 2017
- March 2017
- February 2017
- January 2017
- June 2016
- May 2016
- March 2015
- February 2015
- December 2014
- October 2014
- July 2014
- June 2014
- March 2014
- February 2014
- January 2014
- December 2013
- November 2013
- October 2013
- September 2013
- August 2013
- July 2013
- June 2013
- March 2013
- February 2013
- November 2012
- July 2012
- June 2012
- May 2012
- April 2012
- March 2012
- February 2012
- January 2012
- December 2011
- November 2011
- October 2011
- April 2011
- February 2011
- February 2010