Skip to content
This repository has been archived by the owner on Feb 16, 2024. It is now read-only.

Commit

Permalink
- Adjustment to obtain full list of templates
Browse files Browse the repository at this point in the history
- Package compatible with 21R2 is added
  • Loading branch information
famadoz committed Jan 31, 2022
1 parent 8703012 commit d1141b3
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Binary file added AcumaticaSmartsheetIntegration21R2.zip
Binary file not shown.
7 changes: 5 additions & 2 deletions PX.SmartSheetIntegration/PM/SetupMaintExt.cs
Original file line number Diff line number Diff line change
Expand Up @@ -249,8 +249,11 @@ public Dictionary<string, string> GetTemplateSS(string refreshedToken = "")
.SetAccessToken(token.AccessToken)
.SetDateTimeFixOptOut(true) //See NOTE ON 2.93.0 RELEASE on https://github.com/smartsheet-platform/smartsheet-csharp-sdk
.Build();
PaginatedResult<Template> templates = smartsheetClient.TemplateResources.ListPublicTemplates(null);
PaginatedResult<Template> userTemplates = smartsheetClient.TemplateResources.ListUserCreatedTemplates(null);

PaginationParameters paginationParams = new PaginationParameters(true, null, null); //includeAll = true ==> Ignoring paging and size if defined
PaginatedResult<Template> templates = smartsheetClient.TemplateResources.ListPublicTemplates(paginationParams);
PaginatedResult<Template> userTemplates = smartsheetClient.TemplateResources.ListUserCreatedTemplates(paginationParams);

if (templates.TotalCount > 0)
{
foreach (Template dataTemplate in templates.Data)
Expand Down

0 comments on commit d1141b3

Please sign in to comment.