I am making an api call from new call api option using js object that ran sucessfully i am trying to filter the data by status field like “pickup”&“drop”. After that in an list widgets i want to print only “drop” status data.how i can filter and display in list.
Hello @shivam.agrawal ,
Can you share a screenshot of what the response from the API looks like?
To filter the data you can use the
.filter() method of arrays in JS to do this. To filter by status you would use something like this:
parcel_reservation_dtl.data.records.filter(record => record.reservation_status === "drop")
This will return a filtered array of containing only records where the status is
Thank you for your response. I will look into that.
Hello @shivam.agrawal, Just to confirm, does the button click redirects you to that page where you need to access the ID?
yes, button is redirecting to the page with information Thank you for your reply.