public JsonResult SendGift(long id, string expname, string expnum) { Result result = new Result(); orderser.SendGood(id, expname, expnum); result.success = true; result.status = 1; result.msg = "发货成功"; return(Json(result)); }
public JsonResult SendGift(long id, string expname, string expnum) { Result result = new Result(); _iGiftsOrderService.SendGood(id, expname, expnum); string host = CurrentUrlHelper.CurrentUrl(); var returnurl = String.Format("{0}/Common/ExpressData/SaveExpressData", host); var key = SiteSettingApplication.SiteSettings.Kuaidi100Key; if (!string.IsNullOrEmpty(key)) { Task.Factory.StartNew(() => ServiceApplication.Create <IExpressService>().SubscribeExpress100(expname, expnum, key, string.Empty, returnurl)); } result.success = true; result.status = 1; result.msg = "发货成功"; return(Json(result)); }
public JsonResult SendGift(long id, string expname, string expnum) { Result result = new Result(); _iGiftsOrderService.SendGood(id, expname, expnum); string host = Request.Url.Host; host += Request.Url.Port != 80 ? ":" + Request.Url.Port.ToString() : ""; var returnurl = String.Format("http://{0}/Common/ExpressData/SaveExpressData", host); var key = ServiceHelper.Create <ISiteSettingService>().GetSiteSettings().Kuaidi100Key; if (!string.IsNullOrEmpty(key)) { Task.Factory.StartNew(() => ServiceHelper.Create <IExpressService>().SubscribeExpress100(expname, expnum, key, string.Empty, returnurl)); } result.success = true; result.status = 1; result.msg = "发货成功"; return(Json(result)); }