Merge pull request #1576 from Abderahman88/FaqLimit

Fix limit 100 items (react-faqapp)
This commit is contained in:
Hugo Bernier 2020-11-01 21:02:29 -05:00 committed by GitHub
commit 03a4417635
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 3 deletions

View File

@ -35,12 +35,14 @@ extensions:
Solution|Author(s)
--------|---------
react-FAQApp | Ashok Swain - LinkedIn: https://www.linkedin.com/in/ashok-kumar-swain-2627a514
react-FAQApp | Abderahman Moujahid
## Version history
Version|Date|Comments
-------|----|--------
1.0 | April 25, 2020 | Initial release
1.0.0 | April 25, 2020 | Initial release
1.0.1 | October 30, 2020 | Fix limit 100 items
## Disclaimer

View File

@ -3,7 +3,7 @@
"solution": {
"name": "spfxwebparts-client-side-solution",
"id": "f3b9b2b7-533c-42db-9a81-d3ea68e1e8b6",
"version": "1.0.0.0",
"version": "1.0.1.0",
"includeClientSideAssets": true,
"isDomainIsolated": false
},

View File

@ -64,7 +64,8 @@ export class FaqServices implements IFaqServices {
try {
const FaqProp:IFaqProp[] = [];
let restUrl: string = this._currentWebUrl;
restUrl += "/_api/web/lists/getbytitle('" + listName + "')/items?$select=Id,Title,Answer,Category,CategorySortOrder,QuestionSortOrder,Modified";
//fix: load more than 100 items using top=5000
restUrl += "/_api/web/lists/getbytitle('" + listName + "')/items?$select=Id,Title,Answer,Category,CategorySortOrder,QuestionSortOrder,Modified&$top=5000";
return await this._spHttpClient.get(restUrl, SPHttpClient.configurations.v1,
{
headers: {