public void AddSelectedMallInMap(MallModel item) { var elements = new ObservableCollection <MapElement>(); MapIcon mapIcon = new MapIcon(); var bdPosition = new Geopoint(new BasicGeoposition() { Latitude = Double.Parse(item.lat), Longitude = Double.Parse(item.lon) }); mapIcon.Location = bdPosition;//LocationManager.TransformFromWorldlToMars(bdPosition); mapIcon.Title = item.name; mapIcon.Image = TappedIcon; mapIcon.NormalizedAnchorPoint = new Point(0.5, 0.5); elements.Add(mapIcon); MapElements = elements; MapCenter = new Geopoint(new BasicGeoposition() { Latitude = Double.Parse(item.lat), Longitude = Double.Parse(item.lon) }); MapZoomLevel = 14; SelectedMallItem = item; SelectedItemVisibility = Visibility.Visible; }
public HttpResponseMessage GerAttributeGroupInfo(MallModel model) { string Result = string.Empty; try { //请求中包含的固定参数 model.SOURCE = ParametersFilter.FilterSqlHtml(model.SOURCE, 24); model.CREDENTIALS = ParametersFilter.FilterSqlHtml(model.CREDENTIALS, 24); model.ADDRESS = HttpHelper.IPAddress(); model.TERMINAL = ParametersFilter.FilterSqlHtml(model.TERMINAL, 1); model.INDEX = ParametersFilter.FilterSqlHtml(model.INDEX, 24); model.METHOD = ParametersFilter.FilterSqlHtml(model.METHOD, 24); model.DATA = ParametersFilter.StripSQLInjection(model.DATA); //返回结果 Result = ApiHelper.HttpRequest(username, password, Url, model); ///写日志 string RequestAction = "api/" + username + "/" + HttpContext.Current.Request.RequestContext.RouteData.Values["action"].ToString() + ":"; LogHelper.LogResopnse(RequestAction + Result); } catch (Exception ex) { LogHelper.LogError(ex.ToString()); } HttpResponseMessage Respend = new HttpResponseMessage { Content = new StringContent(Result, Encoding.GetEncoding("UTF-8"), "application/json") }; return(Respend); }
public string Mall_Select(MallModel mallModel) { BaseDL bdl = new BaseDL(); mallModel.Sqlprms = new SqlParameter[0]; return(bdl.SelectJson("Mall_Select", mallModel.Sqlprms)); }
public ActionResult Mall(MallModel model) { if (ModelState.IsValid) { MallConfigInfo mallConfigInfo = BMAConfig.MallConfig; mallConfigInfo.IsGuestSC = model.IsGuestSC; mallConfigInfo.SCSubmitType = model.SCSubmitType; mallConfigInfo.GuestSCCount = model.GuestSCCount; mallConfigInfo.MemberSCCount = model.MemberSCCount; mallConfigInfo.SCExpire = model.SCExpire; mallConfigInfo.OSNFormat = model.OSNFormat; mallConfigInfo.OnlinePayExpire = model.OnlinePayExpire; mallConfigInfo.ReceiveExpire = model.ReceiveExpire; mallConfigInfo.BroHisCount = model.BroHisCount; mallConfigInfo.MaxShipAddress = model.MaxShipAddress; mallConfigInfo.FavoriteProductCount = model.FavoriteProductCount; mallConfigInfo.FavoriteStoreCount = model.FavoriteStoreCount; BMAConfig.SaveMallConfig(mallConfigInfo); Emails.ResetMall(); SMSes.ResetMall(); AddMallAdminLog("修改商城设置"); return(PromptView(Url.Action("mall"), "修改商城设置成功")); } return(View(model)); }
private void GoToListViewIndex(MallModel mall) { //mall 参数没有用 int index = 0; foreach (var group in MallGroupList) { bool flag = false; foreach (var m in group.MallList) { if (m.id == mall.id) { flag = true; break; } else { index++; } } if (flag) { break; } } SelectedIndex = index; }
public AtlasPage_Model(MallModel mall) { //[{"Floor1": "541797c6ac4711c3332d6cd1", //"Floor2": "541797c6ac4711c3332d6cs1"}] SelectedMallModel = mall; Building = mall.buildings.FirstOrDefault(); //Title = Building.name; }
public AtlasPage_Model() { if (IsInDesignMode) { SelectedMallModel = new MallModel() { addr = "某某区 某某路 ", desc = "描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述描述", name = "某某某商场", opentime = "20:00 ------ 10:00", traffic = "公交路线" }; } }
public ActionResult Mall() { MallConfigInfo mallConfigInfo = BMAConfig.MallConfig; MallModel model = new MallModel(); model.IsGuestSC = mallConfigInfo.IsGuestSC; model.SCSubmitType = mallConfigInfo.SCSubmitType; model.GuestSCCount = mallConfigInfo.GuestSCCount; model.MemberSCCount = mallConfigInfo.MemberSCCount; model.SCExpire = mallConfigInfo.SCExpire; model.OSNFormat = mallConfigInfo.OSNFormat; model.OnlinePayExpire = mallConfigInfo.OnlinePayExpire; model.ReceiveExpire = mallConfigInfo.ReceiveExpire; model.BroHisCount = mallConfigInfo.BroHisCount; model.MaxShipAddress = mallConfigInfo.MaxShipAddress; model.FavoriteProductCount = mallConfigInfo.FavoriteProductCount; model.FavoriteStoreCount = mallConfigInfo.FavoriteStoreCount; return(View(model)); }
public HttpResponseMessage ShopCommodityOP(MallModel model) { string Result = string.Empty; try { //请求中包含的固定参数 model.SOURCE = ParametersFilter.FilterSqlHtml(model.SOURCE, 24); model.CREDENTIALS = ParametersFilter.FilterSqlHtml(model.CREDENTIALS, 24); model.ADDRESS = HttpHelper.IPAddress(); model.TERMINAL = ParametersFilter.FilterSqlHtml(model.TERMINAL, 1); model.INDEX = ParametersFilter.FilterSqlHtml(model.INDEX, 24); model.METHOD = ParametersFilter.FilterSqlHtml(model.METHOD, 24); //去除参数中的特殊字符 model.UserAccount = ParametersFilter.FilterSqlHtml(model.UserAccount, 24); model.CommodityNumber = ParametersFilter.FilterSqlHtml(model.CommodityNumber, 64); model.Status = ParametersFilter.FilterSqlHtml(model.Status, 1); model.OPStatus = ParametersFilter.FilterSqlHtml(model.OPStatus, 1); //http请求 Result = ApiHelper.HttpRequest(username, password, Url, model); ///写日志 string RequestAction = "api/" + username + "/" + HttpContext.Current.Request.RequestContext.RouteData.Values["action"].ToString() + ":"; LogHelper.LogResopnse(RequestAction + Result); } catch (Exception ex) { LogHelper.LogError(ex.ToString()); } //返回请求结果 HttpResponseMessage Respend = new HttpResponseMessage { Content = new StringContent(Result, Encoding.GetEncoding("UTF-8"), "application/json") }; return(Respend); }
public static void SetScrollToIndex(DependencyObject obj, MallModel value) { obj.SetValue(ScrollToIndexProperty, value); }
public IHttpActionResult Mall_Select([FromBody] MallModel mallModel) { MallBL mallBL = new MallBL(); return(Ok(mallBL.Mall_Select(mallModel))); }