public string GetOnlineModules()
    {


        string SageVersion = string.Empty;
        SageFrame.Version.SageFrameVersion app = new SageFrame.Version.SageFrameVersion();
        SageVersion = string.Format("{0}", app.FormatShortVersion(app.Version, true));
        string ModuleList = string.Empty;
        string[] args = new string[1];
        args[0] = SageVersion;
        string service = "WebService";
        string method = "GetModuleList";
        string url = ModuleURl;
        try
        {
            WebServiceInvoker invoker =
          new WebServiceInvoker(
              new Uri(url));
            return ModuleList = invoker.InvokeMethod<string>(service, method, args);
        }
        catch (Exception)
        {
            return ModuleList = string.Empty;

        }

    }
 private void showVersion()
 {
     SageFrame.Version.SageFrameVersion app = new SageFrame.Version.SageFrameVersion();
     lblVersion.Text    = string.Format("V {0}", app.FormatShortVersion(app.Version, true));
     lblVersion.Visible = true;
     chkIsShown.Checked = true;
 }
Exemple #3
0
    //Search online modules.
    public string GetSearchModules(string searchKey)
    {
        string SageVersion = string.Empty;

        SageFrame.Version.SageFrameVersion app = new SageFrame.Version.SageFrameVersion();
        SageVersion = string.Format("{0}", app.FormatShortVersion(app.Version, true));
        string ModuleList = string.Empty;

        string[] args = new string[2];
        args[0] = searchKey;
        args[1] = SageVersion;

        string service = "WebService";
        string method  = "GetSearchResult";

        string url = ModuleURl;

        try
        {
            WebServiceInvoker invoker =
                new WebServiceInvoker(
                    new Uri(url));
            return(ModuleList = invoker.InvokeMethod <string>(service, method, args));
        }
        catch (Exception)
        {
            return(ModuleList = string.Empty);
        }
    }
    public string GetOnlineModules(string modules)
    {
        string SageVersion = string.Empty;

        SageFrame.Version.SageFrameVersion app = new SageFrame.Version.SageFrameVersion();
        SageVersion = string.Format("{0}", app.FormatShortVersion(app.Version, true));
        string ModuleList = string.Empty;

        string[] args = new string[1];
        args[0] = modules;
        string service = "OnlineStore";
        string method  = "ThemeModules";
        string url     = ModuleURl;

        try
        {
            WebServiceInvoker invoker =
                new WebServiceInvoker(new Uri(url));
            return(ModuleList = invoker.InvokeMethod <string>(service, method, args));
        }
        catch (Exception ex)
        {
            return(ModuleList = string.Empty);
        }
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        appPath    = GetApplicationName;
        Extension  = SageFrameSettingKeys.PageExtension;
        UserName   = GetUsername;
        PortalID   = GetPortalID;
        PortalName = GetPortalSEOName;
        SageFrameConfig sfConfig    = new SageFrameConfig();
        bool            ShowSideBar = sfConfig.GetSettingBoolValueByIndividualKey(SageFrameSettingKeys.ShowSideBar);

        IsSideBarVisible = ShowSideBar ? 1 : 0;
        BuildQuickLinks();
        //lblVersion.Text = string.Format("V {0}", Config.GetSetting("SageFrameVersion"));
        SageFrame.Version.SageFrameVersion app = new SageFrame.Version.SageFrameVersion();
        lblVersion.Text = string.Format("V {0}", app.FormatShortVersion(app.Version, true));
    }
 protected void Page_Load(object sender, EventArgs e)
 {
     appPath = GetApplicationName;
     Extension = SageFrameSettingKeys.PageExtension;
     UserName = GetUsername;
     PortalID = GetPortalID;
     PortalName = GetPortalSEOName;
     SageFrameConfig sfConfig = new SageFrameConfig();
     bool ShowSideBar = sfConfig.GetSettingBoolValueByIndividualKey(SageFrameSettingKeys.ShowSideBar);
     IsSideBarVisible = ShowSideBar ? 1 : 0;
     BuildQuickLinks();
     //lblVersion.Text = string.Format("V {0}", Config.GetSetting("SageFrameVersion"));
     SageFrameVersion app = new SageFrameVersion();
     lblVersion.Text = string.Format("V {0}", app.FormatShortVersion(app.Version, true));
     
 }
    protected void Page_Load(object sender, EventArgs e)
    {
        IncludeLanguageJS();
        appPath = GetApplicationName;
        SecurityPolicy objSecurity = new SecurityPolicy();

        userName  = objSecurity.GetUser(GetPortalID);
        Extension = SageFrameSettingKeys.PageExtension;


        if (!IsPostBack)
        {
            // BindThemes();
            //BindLayouts();
            //BindValues();
            hlnkDashboard.Visible = false;
            SageFrameConfig conf = new SageFrameConfig();
            string          ExistingPortalShowProfileLink = conf.GetSettingValueByIndividualKey(SageFrameSettingKeys.PortalShowProfileLink);
            lnkAccount.NavigateUrl = GetProfileLink();
            if (ExistingPortalShowProfileLink == "1")
            {
                lnkAccount.Visible = true;
            }
            else
            {
                lnkAccount.Visible = false;
            }
            SageFrame.Version.SageFrameVersion app = new SageFrame.Version.SageFrameVersion();
            lblVersion.Text = string.Format("V {0}", app.FormatShortVersion(app.Version, true));
        }
        hypLogo.NavigateUrl = GetPortalAdminPage();
        hypLogo.ImageUrl    = appPath + "/Administrator/Templates/Default/images/sageframe.png";
        RoleController _role = new RoleController();

        string[] roles = _role.GetRoleNames(GetUsername, GetPortalID).ToLower().Split(',');
        if (roles.Contains(SystemSetting.SUPER_ROLE[0].ToLower()) || roles.Contains(SystemSetting.SITEADMIN.ToLower()))
        {
            hlnkDashboard.Visible     = true;
            hlnkDashboard.NavigateUrl = GetPortalAdminPage();
            cpanel.Visible            = true;
        }
        else
        {
            cpanel.Visible = false;
        }
    }
    protected void Page_Load(object sender, EventArgs e)
    {
        IncludeLanguageJS();
        appPath = GetApplicationName;
        SecurityPolicy objSecurity = new SecurityPolicy();

        userName  = objSecurity.GetUser(GetPortalID);
        Extension = SageFrameSettingKeys.PageExtension;
        IncludeJs("topstickybar", "/js/TopStickyBar.js");
        if (!IsPostBack)
        {
            // BindThemes();
            //BindLayouts();
            //BindValues();
            hlnkDashboard.Visible = false;
            SageFrameConfig conf = new SageFrameConfig();
            string          ExistingPortalShowProfileLink = conf.GetSettingValueByIndividualKey(SageFrameSettingKeys.PortalShowProfileLink);
            lnkAccount.NavigateUrl = GetProfileLink();
            if (ExistingPortalShowProfileLink == "1")
            {
                lnkAccount.Visible = true;
            }
            else
            {
                lnkAccount.Visible = false;
            }
            SageFrame.Version.SageFrameVersion app = new SageFrame.Version.SageFrameVersion();
            lblVersion.Text = string.Format("V {0}", app.FormatShortVersion(app.Version, true));
        }
        hypLogo.NavigateUrl = GetPortalAdminPage();
        hypLogo.ImageUrl    = appPath + "/Administrator/Templates/Default/images/sageframe.png";
        RoleController _role = new RoleController();
        bool           isDashboardAccessible = _role.IsDashboardAccesible(GetUsername, GetPortalID);

        if (isDashboardAccessible)
        {
            hlnkDashboard.Visible     = true;
            hlnkDashboard.NavigateUrl = GetPortalAdminPage();
            cpanel.Visible            = true;
        }
        else
        {
            cpanel.Visible = false;
        }
    }