/// <summary> /// Gets the label translation. /// </summary> /// <param name="labelId">The label identifier.</param> /// <param name="userLanguage">The user language.</param> /// <returns>Returns translated text.</returns> public string GetLabelTranslation(string labelId, string userLanguage) { using (var client = new RoadsServiceClient.RoadsServiceClient()) { return client.GetLabelTranslation(labelId, userLanguage); } }
/// <summary> /// Saves the map object. /// </summary> /// <param name="model">The model.</param> public static void SaveMapObject(CreateMapObjectViewModel model) { using (var client = new RoadsServiceClient.RoadsServiceClient()) { var regionId = model.UseRegion ? model.RegionId : 0; client.CreateMapObjectWithTranslation( model.Translations.Select(s => new MapObjectTranslationData { Value = s.Value, LanguageId = s.LanguageId }).ToArray(), regionId, model.LanguageKey); } }