public static PoiDto CreatePoi(PoiRequestDto.PointOfInterestAdd addPoi) { using (var uow = new BlueprintUnitOfWork()) { var fp = uow.FloorPlans.Find(addPoi.FloorPlanId); var poi = addPoi.ToEntity(); fp.PointsOfInterest.Add(poi); poi.Location.FloorPlan = fp; uow.FloorPlanLocations.Add(poi.Location); uow.Save(); return poi.ToDto(); } }
public object Put(PoiRequestDto.PointOfInterestUpdateLocation put) { return PoiServices.UpdatePoiLocation(put.PointOfInterestId, put.XPos, put.YPos); }
public object Put(PoiRequestDto.PointOfInterestUpdate put) { return PoiServices.UpdatePoi(put.PointOfInterestId, put.Name, put.Description); }
public object Post(PoiRequestDto.PointOfInterestAddUpdateThumbnail post) { return PoiServices.AddUpdatePoiThumbnail(post.PointOfInterestId, post.Image); }
public object Post(PoiRequestDto.PointOfInterestAdd post) { return PoiServices.CreatePoi(post); }
public object Get(PoiRequestDto.FindPointOfInterestForFloorPlan get) { return PoiServices.FindPoiForFloorPlan(get.FloorPlanId); }
public object Get(PoiRequestDto.FindPointOfInterestForBluePrint get) { return PoiServices.FindPoiForBluePrint(get.BluePrintId); }
public object Get(PoiRequestDto.GetPointOfInterestThumbnail get) { return PoiServices.GetPoiThumbnail(get.PointOfInterestId); }
public object Get(PoiRequestDto.PointOfInterestAddEntranceExit post) { return PoiServices.CreateEntranceExit(post); }
public object Get(PoiRequestDto.GetPointOfInterest get) { return PoiServices.GetPointOfInterest(get.PointOfInterestId); }
public object Delete(PoiRequestDto.PointOfInterestDelete delete) { return PoiServices.DeletePoi(delete.PoiId, delete.UserId, delete.BlueprintId, delete.FloorplanId); }