/// <summary> /// 订单留言 /// </summary> /// <param name="user"></param> public static void SendSMS_ordercomment(Lebi_User user, Lebi_Comment model) { BaseConfig conf = ShopCache.GetBaseConfig(); int IsAdminSms = 0; int IsSupplierSms = 0; if (conf.SMS_sendmode.Contains("SMSTPL_Admin_ordercomment")) { IsAdminSms = 1; } Lebi_Order order = B_Lebi_Order.GetModel(model.Keyid); if (order == null) { order = new Lebi_Order(); } if (order.Supplier_id > 0) { Lebi_Supplier supplier = B_Lebi_Supplier.GetModel(order.Supplier_id); if (supplier.IsSupplierTransport == 0) //商家发货 { if (ShopCache.GetBaseConfig_Supplier(order.Supplier_id).SMS_sendmode.Contains("SMSTPL_Admin_ordercomment")) { IsSupplierSms = 1; } } } if (IsAdminSms == 0 && IsSupplierSms == 0) { return; } if (user.Language == "") { user.Language = Language.Languages().FirstOrDefault().Code; } string Admin_content = Language.Content(conf.SMSTPL_Admin_ordercomment, user.Language); Admin_content = ReplaceSMSTag(Admin_content, user, conf); Admin_content = Admin_content.Replace("{$Content}", model.Content); Admin_content = Admin_content.Replace("{$OrderNO}", order.Code); if (IsAdminSms == 1) { Send(conf.SMS_reciveno, Admin_content); } if (IsSupplierSms == 1) { BaseConfig_Supplier config_supplier = ShopCache.GetBaseConfig_Supplier(order.Supplier_id); Send(config_supplier.SMS_reciveno, Admin_content); } }
protected override void LoadPage(string themecode, int siteid, string languagecode, string pcode) { if (CurrentUser.id == 0) { Response.Redirect(URL("P_Login", "" + HttpUtility.UrlEncode(RequestTool.GetRequestUrlNonDomain()) + "," + GetUrlToken(RequestTool.GetRequestUrlNonDomain()) + "")); } LoadTheme(themecode, siteid, languagecode, pcode); if (SYS.IsClosetuihuo == "1") { PageError(); } CurrentPage = B_Lebi_Theme_Page.GetModel("Code='P_UserReturnApply'"); path = "<a href=\"" + URL("P_Index", "") + "\" class=\"home\" title=\"" + Tag("首页") + "\"><span>" + Tag("首页") + "</span></a><em class=\"home\">»</em><a href=\"" + URL("P_UserCenter", "") + "\"><span>" + Tag("会员中心") + "</span></a><em>»</em><a href=\"" + URL("P_UserReturn", "" + id + "") + "\"><span>" + Tag("退货订单") + "</span></a><em>»</em><a href=\"" + URL("P_UserReturnApply", "") + "\"><span>" + Tag("退货申请") + "</span></a>"; CurrentPage = B_Lebi_Theme_Page.GetModel("Code='P_UserReturnApply'"); id = Rint_Para("0"); order = B_Lebi_Order.GetModel("User_id = " + CurrentUser.id + " and id = " + id + ""); if (order == null) { PageError(); } if (order.User_id != CurrentUser.id) { PageError(); } where = "Order_id=" + order.id + ""; order_products = B_Lebi_Order_Product.GetList(where, "id desc"); if (order.Supplier_id > 0) { Lebi_Supplier supplier = B_Lebi_Supplier.GetModel(order.Supplier_id); if (supplier != null) { shouhuoren = supplier.RealName; shouhuodizhi = supplier.Address; shouhuodianhua = supplier.Phone; shouhuoyoubian = supplier.Postalcode; } } else { Lebi_Express_Shipper shipper = B_Lebi_Express_Shipper.GetList("", "Sort desc", 1, 1).FirstOrDefault(); if (shipper != null) { shouhuoren = shipper.UserName; shouhuodizhi = shipper.Address; shouhuodianhua = shipper.Tel; shouhuoyoubian = shipper.ZipCode; } } }
protected override void LoadPage(string themecode, int siteid, string languagecode, string pcode) { LoadTheme(themecode, siteid, languagecode, pcode); path = "<a href=\"" + URL("P_Index", "") + "\" class=\"home\" title=\"" + Tag("首页") + "\"><span>" + Tag("首页") + "</span></a><em class=\"home\">»</em><a href=\"" + URL("P_Pay", "") + "\"><span>" + Tag("在线付款") + "</span></a>"; order_id = Rint("order_id"); order = B_Lebi_Order.GetModel(order_id); if (order == null) { PageError(); } if (order.User_id != CurrentUser.id || order.IsInvalid == 1 || order.IsPaid == 1) { PageError(); } else { if (order.Type_id_OrderType == 215) { List <Lebi_Order> ors = B_Lebi_Order.GetList("Order_id=" + order.id + "", ""); decimal moeny = 0; foreach (Lebi_Order or in ors) { moeny += or.Money_Pay; } order.Money_Pay = moeny; B_Lebi_Order.Update(order); } } string onpaywhere = "IsUsed=1 and parentid=0"; if (CurrentSite.IsMobile == 1) { onpaywhere += " and (showtype='' or showtype like '%wap%')"; } else { onpaywhere += " and (showtype='' or showtype like '%web%')"; } onlinepays = B_Lebi_OnlinePay.GetList(onpaywhere, "Sort desc"); order_products = B_Lebi_Order_Product.GetList("Order_id = " + order.id, "id desc"); }
/// <summary> /// 订单收货 /// </summary> /// <param name="user"></param> /// <param name="torder"></param> public static void SendSMS_orderrecive(Lebi_User user, Lebi_Transport_Order torder) { BaseConfig conf = ShopCache.GetBaseConfig(); int IsAdminSms = 0; int IsSupplierSms = 0; if (conf.SMS_sendmode.Contains("SMSTPL_Admin_orderrecive")) { IsAdminSms = 1; } Lebi_Order order = B_Lebi_Order.GetModel("id=" + torder.Order_id + ""); if (order.Supplier_id > 0) { if (ShopCache.GetBaseConfig_Supplier(order.Supplier_id).SMS_sendmode.Contains("SMSTPL_Admin_orderrecive")) { IsSupplierSms = 1; } } if (IsAdminSms == 0 && IsSupplierSms == 0) { return; } if (user.Language == "") { user.Language = Language.Languages().FirstOrDefault().Code; } string Admin_content = Language.Content(conf.SMSTPL_Admin_orderrecive, user.Language); Admin_content = ReplaceSMSTag(Admin_content, user, conf); Admin_content = Admin_content.Replace("{$OrderNO}", order.Code); if (IsAdminSms == 1) { Send(conf.SMS_reciveno, Admin_content); } if (IsSupplierSms == 1) { BaseConfig_Supplier config_supplier = ShopCache.GetBaseConfig_Supplier(order.Supplier_id); Send(config_supplier.SMS_reciveno, Admin_content); } }
protected override void LoadPage(string themecode, int siteid, string languagecode, string pcode) { if (CurrentUser.id == 0) { Response.Redirect(URL("P_Login", "" + HttpUtility.UrlEncode(RequestTool.GetRequestUrlNonDomain()) + "," + GetUrlToken(RequestTool.GetRequestUrlNonDomain()) + "")); } LoadTheme(themecode, siteid, languagecode, pcode); CurrentPage = B_Lebi_Theme_Page.GetModel("Code='P_UserReturnShip'"); id = Rint("id"); tid = Rint("id"); order = B_Lebi_Order.GetModel("User_id = " + CurrentUser.id + " and id = " + id + ""); if (order == null) { PageError(); } if (order.User_id != CurrentUser.id) { PageError(); } path = "<a href=\"" + URL("P_Index", "") + "\" class=\"home\" title=\"" + Tag("首页") + "\"><span>" + Tag("首页") + "</span></a><em class=\"home\">»</em><a href=\"" + URL("P_UserCenter", "") + "\"><span>" + Tag("会员中心") + "</span></a><em>»</em><a href=\"" + URL("P_UserReturn", "" + id + "") + "\"><span>" + Tag("退货订单") + "</span></a><em>»</em><a href=\"" + URL("P_UserReturnDetails", "" + id + "") + "\"><span>" + Tag("订单") + ":" + order.Code + "</span></a><em>»</em><a href=\"" + URL("P_UserReturnShip", "") + "\"><span>" + Tag("发货") + "</span></a>"; where = "Order_id=" + order.id + ""; order_products = B_Lebi_Order_Product.GetList(where, "id desc"); }
public static Lebi_OnlinePay GetOnlinePay(string ordercode, string paycode) { Lebi_Order order = B_Lebi_Order.GetModel("Code=lbsql{'" + ordercode + "'}"); return(GetOnlinePay(order, paycode)); }