IMPORTANT: This version of Sitefinity CMS is out of support and the respective product documentation is no longer maintained and can be outdated. Use the version selector to view a supported product version.
After Locations module: Implement the view model class of the Locations module web service, you need to create the backend service. To do so:
public
class
LocationsBackendService : ContentServiceBase<LocationItem, LocationItemViewModel, LocationsManager>
{
}
override
IQueryable<LocationItem> GetChildContentItems(Guid parentId,
string
providerName)
throw
new
NotImplementedException();
LocationItem GetContentItem(Guid id,
return
this
.GetManager(providerName).GetLocation(id);
IQueryable<LocationItem> GetContentItems(
.GetManager(providerName).GetLocations();
LocationsManager GetManager(
LocationsManager.GetManager(providerName);
LocationItem GetParentContentItem(Guid id,
IEnumerable<LocationItemViewModel> GetViewModelList(IEnumerable<LocationItem> contentList, ContentDataProviderBase dataProvider)
var list =
List<LocationItemViewModel>();
foreach
(var location
in
contentList)
list.Add(
LocationItemViewModel(location, dataProvider));
list;
Back To Top
To submit feedback, please update your cookie settings and allow the usage of Functional cookies.
Your feedback about this content is important