search envelope-o feed check
Home Unanswered Active Tags New Question
user comment-o

Resolve resource id to resource name on rangeselected

Asked by Simon
10 years ago.

How do I obtain a resource name from a given resource id in javascript?

For instance - I've rendered a scheduler in a view like so:
@Html.DayPilotScheduler(...)
{
...
TimeRangeSelectedJavaScript = "rangeSelected(start, end, resource)",
...
}

In my rangeSelected function I want to get the resource name from the resource(id) passed in as argument.

Is this possible, or do I have to manually retrieve the resource name via a custom ajax call etc?

Answer posted by Simon
10 years ago.

Nvm...
Answer is here: http://forums.daypilot.org/Topic.aspx/921/scheduler_resource_name_and_id

That is - find the resource via dps.resources.

This question is more than 1 months old and has been closed. Please create a new question if you have anything to add.