public static List <ShopServiceModel> GetXBYShopServiceModelListByShopId(int shopId) { List <ShopServiceModel> shopservicemodelList = new List <ShopServiceModel>(); try { using (var client = new ShopClient()) { var shopdetail = client.FetchShopDetail(shopId); if (shopdetail != null && shopdetail.Result != null && shopdetail.Result.ShopServices != null && shopdetail.Result.ShopServices.Any()) { shopservicemodelList = shopdetail.Result.ShopServices.Where( q => q.ServiceId.Contains("FU-BY-XBY|")).ToList(); } } } catch (Exception ex) { TuhuShopSyncJob.Logger.Error(ex);; } return(shopservicemodelList); }
public static List <ShopServiceModel> GetShopServiceModelListByShopId(int shopId) { List <ShopServiceModel> shopservicemodelList = new List <ShopServiceModel>(); try { using (var client = new ShopClient()) { client.UpdateShop(shopId); var shopdetail = client.FetchShopDetail(shopId); if (shopdetail != null && shopdetail.Result != null && shopdetail.Result.ShopServices != null && shopdetail.Result.ShopServices.Any()) { shopservicemodelList = shopdetail.Result.ShopServices.Where( q => q.ServersType.Equals("CarWashing", StringComparison.OrdinalIgnoreCase)).ToList(); } } } catch (Exception ex) { TuhuShopSyncJob.Logger.Error(ex);; } return(shopservicemodelList); }