- Home
- Forum
- Angular - EJ 2
- How to pass data through Request Body in DataManager ?
How to pass data through Request Body in DataManager ?
this.ds.getSerchIds(this.searchTemplateText).subscribe((x) => {
if (x.length > 0) {
this.data = new DataManager({
url: this.odataEndpoint + 'FolderGrid/?' + this.generateQueryString(x),
adaptor: new ODataV4Adaptor(),
headers: [this.userService.entireToken]
});
} else {
this.documentList.localData = [];
this.data = new DataManager({});
this.notifyOnError('No Contract Templates are found matching the condition');
}
});
I am Passing List of ids in Querystring to API using DataManager . But I need to Pass this List of ids as an Request Body to API. 1. How to Pass the List of Ids in Request Body to API using DataManager in Angular ? 2. Do we need to use this as an POST request ? Please reply ASAP Thanks Nambi R
SIGN IN To post a reply.
3 Replies
PS
Pavithra Subramaniyam
Syncfusion Team
November 30, 2021 12:58 PM UTC
Hi Nambi,
Thanks for contacting Syncfusion support.
In EJ2 DataManager, it is not feasible to send the details in request Body with Odatav4 GET request. This is the default behavior. If sending POST request will meet your expectation, we suggest you use the “UrlAdaptor” which will send POST request for each action. Also, you can send the additional details by using the “addParams” method of “Query”. Please refer to the below documentation link for more information.
Regards,
Pavithra S
PS
Pavithra Subramaniyam
Syncfusion Team
November 30, 2021 12:58 PM UTC
Hi Nambi,
Thanks for contacting Syncfusion support.
In EJ2 DataManager, it is not feasible to send the details in request Body with Odatav4 GET request. This is the default behavior. If sending POST request will meet your expectation, we suggest you use the “UrlAdaptor” which will send POST request for each action. Also, you can send the additional details by using the “addParams” method of “Query”. Please refer to the below documentation link for more information.
Regards,
Pavithra S
PS
Pavithra Subramaniyam
Syncfusion Team
November 30, 2021 12:58 PM UTC
Hi Nambi,
Thanks for contacting Syncfusion support.
In EJ2 DataManager, it is not feasible to send the details in request Body with Odatav4 GET request. This is the default behavior. If sending POST request will meet your expectation, we suggest you use the “UrlAdaptor” which will send POST request for each action. Also, you can send the additional details by using the “addParams” method of “Query”. Please refer to the below documentation link for more information.
Regards,
Pavithra S
SIGN IN To post a reply.
- 3 Replies
- 2 Participants
-
NR Nambi Ramamoorthy
- Nov 29, 2021 05:46 PM UTC
- Nov 30, 2021 12:58 PM UTC