Ejemplo n.º 1
0
    protected void Page_Load(object sender, EventArgs e)
    {
        ModuleRedirectPath = ResolveUrl(this.aspxRedirectPath);
        StoreID            = GetStoreID;
        PortalID           = GetPortalID;
        CultureName        = GetCurrentCultureName;
        UserName           = GetUsername;
        CustomerID         = GetCustomerID;

        if (HttpContext.Current.Session.SessionID != null)
        {
            SessionCode = HttpContext.Current.Session.SessionID.ToString();
        }
        StoreSettingConfig ssc = new StoreSettingConfig();

        AllowRealTimeNotifications = ssc.GetStoreSettingsByKey(StoreSetting.AllowRealTimeNotifications, GetStoreID, GetPortalID, GetCurrentCultureName);

        if (AllowRealTimeNotifications.ToLower() == "true")
        {
            IncludeJs("SignalR", false, "/js/SignalR/jquery.signalR-1.0.0-rc2.min.js", "/signalr/hubs", "/Modules/AspxCommerce/AspxStartUpEvents/js/RealTimeAspxMgmt.js");
        }
        StoreDefaultCurrency = ssc.GetStoreSettingsByKey(StoreSetting.MainCurrency, GetStoreID, GetPortalID, GetCurrentCultureName);
        IncludeAPIjs();
        IncludeLanguageAPIJS();
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        SetCustomerID();
        GetStoreSettings();
        LoadGlobalVariables();
        IncludeCoreLanguageJS();
        IncludeRssFeedLanguageJS();
        StoreSettingConfig ssc = new StoreSettingConfig();

        AllowRealTimeNotifications = ssc.GetStoreSettingsByKey(StoreSetting.AllowRealTimeNotifications, GetStoreID, GetPortalID, GetCurrentCultureName);
        if (AllowRealTimeNotifications.ToLower() == "true")
        {
            IncludeJs("SignalR", "/js/SignalR/jquery.signalR-2.2.0.min.js", "/signalr/hubs", "/Modules/AspxCommerce/AspxStartUpEvents/js/RealTimeAspxMgmt.js");
        }
        ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "ratelist", " var currencyRate='[]';", true);
    }
Ejemplo n.º 3
0
    protected void Page_Load(object sender, EventArgs e)
    {
        int    StoreID, PortalID;
        string CultureName, AllowRealTimeNotifications, UserName = string.Empty;

        ModuleRedirectPath = ResolveUrl(this.aspxRedirectPath);
        GetPortalCommonInfo(out StoreID, out PortalID, out UserName, out CultureName);
        StoreSettingConfig ssc = new StoreSettingConfig();

        ssc.GetStoreSettingParamTwo(StoreSetting.AllowRealTimeNotifications, StoreSetting.MainCurrency, out AllowRealTimeNotifications, out StoreDefaultCurrency, StoreID, PortalID, CultureName);
        if (AllowRealTimeNotifications.ToLower() == "true")
        {
            Page.ClientScript.RegisterClientScriptInclude("SignlaR1", ResolveUrl("~/js/SignalR/jquery.signalR-2.2.0.min.js"));
            Page.ClientScript.RegisterClientScriptInclude("SignlaR2", ResolveUrl("~/signalr/hubs"));
            Page.ClientScript.RegisterClientScriptInclude("SignlaR3", ResolveUrl("~/Modules/AspxCommerce/AspxStartUpEvents/js/RealTimeAspxMgmt.js"));
        }
    }
Ejemplo n.º 4
0
    protected void Page_Load(object sender, EventArgs e)
    {
        try
        {
            if (!IsPostBack)
            {
                IncludeCss("OrderManagement", "/Templates/" + TemplateName + "/css/GridView/tablesort.css", "/Templates/" + TemplateName + "/css/MessageBox/style.css");
                IncludeJs("OrderManagement", "/js/GridView/jquery.grid.js", "/js/GridView/SagePaging.js", "/js/GridView/jquery.global.js", "/js/GridView/jquery.dateFormat.js",
                          "/js/MessageBox/jquery.easing.1.3.js", "/js/MessageBox/alertbox.js", "/js/ExportToCSV/table2CSV.js", "/js/CurrencyFormat/jquery.formatCurrency-1.4.0.js",
                          "/js/CurrencyFormat/jquery.formatCurrency.all.js", "/Modules/AspxCommerce/AspxOrderManagement/js/OrderManagement.js");
                UserModuleID = SageUserModuleID;
                StoreID      = GetStoreID;
                PortalID     = GetPortalID;
                UserName     = GetUsername;
                CultureName  = GetCurrentCultureName;

                MembershipController member = new MembershipController();
                UserInfo             user   = member.GetUserDetails(GetPortalID, GetUsername);
                SenderEmail  = user.Email;
                templateName = TemplateName;
                StoreSettingConfig ssc = new StoreSettingConfig();
                StoreName   = ssc.GetStoreSettingsByKey(StoreSetting.StoreName, StoreID, PortalID, CultureName);
                NewOrderRss = ssc.GetStoreSettingsByKey(StoreSetting.NewOrderRss, StoreID, PortalID, CultureName);
                AllowRealTimeNotifications = ssc.GetStoreSettingsByKey(StoreSetting.AllowRealTimeNotifications, StoreID, PortalID, CultureName);
                if (AllowRealTimeNotifications.ToLower() == "true")
                {
                    IncludeJs("SignalR", false, "/js/SignalR/jquery.signalR-2.2.0.min.js", "/signalr/hubs", "/Modules/AspxCommerce/AspxStartUpEvents/js/RealTimeAspxMgmt.js");
                }
                if (NewOrderRss.ToLower() == "true")
                {
                    RssFeedUrl = ssc.GetStoreSettingsByKey(StoreSetting.RssFeedURL, StoreID, PortalID, CultureName);
                }
                AspxCommerce.Core.WareHouseAddress wareHouseAddress = GetWareHouseAddress(StoreID, PortalID);
                if (wareHouseAddress == null)
                {
                    WareHouseAddress = "null";
                }
            }
            IncludeLanguageJS();
        }
        catch (Exception ex)
        {
            ProcessException(ex);
        }
    }
Ejemplo n.º 5
0
    protected void Page_Load(object sender, EventArgs e)
    {
        try
        {
            if (!IsPostBack)
            {
                IncludeCss("ItemsManage", "/Templates/" + TemplateName + "/css/GridView/tablesort.css", "/Templates/" + TemplateName + "/css/MessageBox/style.css", "/Templates/" + TemplateName + "/css/AjaxUploader/fileuploader.css",
                           "/Templates/" + TemplateName + "/css/Tabs/slidingtabs-vertical.css", "/Modules/AspxCommerce/AspxItemsManagement/css/module.css");

                IncludeJs("ItemsManage", "/js/GridView/jquery.grid.js", "/js/FormValidation/jquery.validate.js",
                          "/js/GridView/SagePaging.js", "/js/GridView/jquery.global.js",
                          "/js/GridView/jquery.dateFormat.js", "/js/DateTime/date.js",
                          "/js/ImageGallery/jquery.mousewheel.js",
                          "/js/MessageBox/jquery.easing.1.3.js", "/js/MessageBox/alertbox.js",
                          "/js/Tabs/jquery.slidingtabs.js",
                          "/js/AjaxFileUploader/ajaxupload.js", "/js/PopUp/custom.js",
                          "/Modules/AspxCommerce/AspxItemsManagement/js/ItemManagement.js", "/js/PopUp/popbox.js",
                          "/js/CurrencyFormat/jquery.formatCurrency-1.4.0.js",
                          "/js/CurrencyFormat/jquery.formatCurrency.all.js", "/js/AjaxFileUploader/fileuploader.js");

                ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "ckEditorUserModuleID", " var ckEditorUserModuleID='" + SageUserModuleID + "';", true);
                IncludeJs("ItemsManageCk", "/Editors/ckeditor/ckeditor.js", "/Editors/ckeditor/adapters/jquery.js");
                //Page.ClientScript.RegisterClientScriptInclude("JQueryFormValidated", ResolveUrl("~/js/FormValidation/jquery.validate.js"));
                StoreID      = GetStoreID;
                PortalID     = GetPortalID;
                UserName     = GetUsername;
                UserModuleId = SageUserModuleID;
                CultureName  = GetCurrentCultureName;
                SecurityPolicy            objSecurity = new SecurityPolicy();
                FormsAuthenticationTicket ticket      = objSecurity.GetUserTicket(GetPortalID);
                if (ticket != null && ticket.Name != ApplicationKeys.anonymousUser)
                {
                    MembershipController member     = new MembershipController();
                    UserInfo             userDetail = member.GetUserDetails(GetPortalID, GetUsername);
                    userEmail = userDetail.Email;
                }
                StoreSettingConfig ssc = new StoreSettingConfig();
                MaximumFileSize            = int.Parse(ssc.GetStoreSettingsByKey(StoreSetting.MaximumImageSize, StoreID, PortalID, CultureName));
                MaxDownloadFileSize        = int.Parse(ssc.GetStoreSettingsByKey(StoreSetting.MaxDownloadFileSize, StoreID, PortalID, CultureName));
                PriceUnit                  = ssc.GetStoreSettingsByKey(StoreSetting.MainCurrency, StoreID, PortalID, CultureName);
                WeightUnit                 = ssc.GetStoreSettingsByKey(StoreSetting.WeightUnit, StoreID, PortalID, CultureName);
                DimensionUnit              = ssc.GetStoreSettingsByKey(StoreSetting.DimensionUnit, StoreID, PortalID, CultureName);
                LowStockItemRss            = ssc.GetStoreSettingsByKey(StoreSetting.LowStockItemRss, StoreID, PortalID, CultureName);
                CurrencyCodeSlected        = ssc.GetStoreSettingsByKey(StoreSetting.MainCurrency, StoreID, PortalID, CultureName);
                AllowOutStockPurchase      = ssc.GetStoreSettingsByKey(StoreSetting.AllowOutStockPurchase, StoreID, PortalID, CultureName);
                AllowRealTimeNotifications = ssc.GetStoreSettingsByKey(StoreSetting.AllowRealTimeNotifications, StoreID, PortalID, CultureName);
                if (AllowRealTimeNotifications.ToLower() == "true")
                {
                    IncludeJs("SignalR", false, "/js/SignalR/jquery.signalR-2.2.0.min.js", "/signalr/hubs", "/Modules/AspxCommerce/AspxStartUpEvents/js/RealTimeAspxMgmt.js");
                }
                if (LowStockItemRss.ToLower() == "true")
                {
                    RssFeedUrl = ssc.GetStoreSettingsByKey(StoreSetting.RssFeedURL, StoreID, PortalID, CultureName);
                }
                GetItemTabSetting();
            }

            AddLanguage();
            IncludeLanguageJS();
        }
        catch (Exception ex)
        {
            ProcessException(ex);
        }
    }