I have a webapi with 2 function in it
like so
[AllowAnonymous]
[HttpGet()]
public string FetchCalendarByRange(string id)//string moduleid, string category, string startDate, string endDate)
{}
and
[AllowAnonymous]
[HttpGet()]
public IEnumerable<Junk> GetEmployees
{}
I have 2 routes like so
mapRouteManager.MapHttpRoute("MyServices", "default", "{controller}/{action}", new[] { "MyServices" });
mapRouteManager.MapHttpRoute("MyServices", "default", "{controller}/{action}/{id}", new[] { "MyServices" });
When I call the getemployees()
/desktopmodules/myservices/api/eventservice/GetEmployees/
It works fine I get JSON of my list of employees
When I call the fetchcalendarbyrange()
/desktopmodules/myservices/api/eventservice/FetchCalendarByRange/1
I get a 404 error
I may be reading it wrong but from what I have read here and on other sites the
fetchcalendarbyrange() should work
What might be wrong with my setup?