0

Understand that for POST method, the key - Data is being used instead of Params, however if the data is being used for filtering is it possible to have conditions for these Data ?

var proxyData = {
  lecturer_id: "e9d0bea0-76cb-11e8-adc0-fa7ae01bbebc",
  status: ["pending", "accepted"]
};

try {
  $http({
    method: $scope.proxyMethod,
    url: url,
    data: proxyData
  }).
  success(function(data, status, headers, config) { }).
  error(function(data, status, headers, config) { });

In the above example, I would like to filter out lecturer_id with the exact match, but with status of either "pending" or "accepted".

Is it possible to do something like GET params - "?status=pending,accepted"

Thanks in advance and sorry if my question has any misunderstanding of how AngularJS works as I am still new to it.

Jun Wei
  • 151
  • 1
  • 3

0 Answers0