Skip to content

Commit

Permalink
upd for open url
Browse files Browse the repository at this point in the history
  • Loading branch information
leedavi committed Mar 11, 2017
1 parent f98e4ad commit 87d128f
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 9 deletions.
32 changes: 25 additions & 7 deletions Base/NBrightBuyBase.cs
Expand Up @@ -41,7 +41,7 @@ protected override void OnInit(EventArgs e)
ModCtrl = new NBrightBuyController();
DebugMode = StoreSettings.Current.DebugMode;

base.OnInit(e);
base.OnInit(e);

#region "Get all Settings for module"
//get Model Level Settings
Expand All @@ -53,6 +53,24 @@ protected override void OnInit(EventArgs e)

if (EnablePaging)
{
// SET NOINDEX if we are paging product list
try
{
var page = Utils.RequestQueryStringParam(Context, "page");
if (page != "")
{
var metarobots = (System.Web.UI.HtmlControls.HtmlMeta)BasePage.Header.FindControl("MetaRobots");
if (metarobots != null)
{
metarobots.Content = "NOINDEX";
}
}
}
catch (Exception)
{
//ignore
}

CtrlPaging = new NBrightCore.controls.PagingCtrl();
this.Controls.Add(CtrlPaging);
CtrlPaging.PageChanged += new RepeaterCommandEventHandler(PagingClick);
Expand Down Expand Up @@ -86,12 +104,12 @@ protected override void OnLoad(EventArgs e)
}
}

protected new int TabId
{
get
{
return PortalSettings.Current.ActiveTab.TabID;
}
protected new int TabId
{
get
{
return PortalSettings.Current.ActiveTab.TabID;
}
}


Expand Down
6 changes: 6 additions & 0 deletions Components/NBrightBuyUtils.cs
Expand Up @@ -188,6 +188,9 @@ public static string GetEntryUrl(int portalId, string entryid, string modulekey,
}
}

// make sure we have the correct culturecode, fo OpenUrlrewriter
objTabInfo.CultureCode = Utils.GetCurrentCulture();

var rdModId = "";
if (modulekey != "") rdModId = "&modkey=" + modulekey;

Expand Down Expand Up @@ -294,6 +297,9 @@ public static string GetSEOLink(int portalId, int tabId, string controlKey, stri
}
if (string.IsNullOrEmpty(title)) title = "Default.aspx";

// make sure we have the correct culturecode, fo OpenUrlrewriter
tabInfo.CultureCode = Utils.GetCurrentCulture();

var url = DotNetNuke.Services.Url.FriendlyUrl.FriendlyUrlProvider.Instance().FriendlyUrl(tabInfo, "~/Default.aspx?tabid=" + tabInfo.TabID.ToString(""), title);
return url;
}
Expand Down
4 changes: 2 additions & 2 deletions Properties/AssemblyInfo.cs
Expand Up @@ -32,5 +32,5 @@
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("3.5.8.3")]
[assembly: AssemblyFileVersion("3.5.8.3")]
[assembly: AssemblyVersion("3.5.9.0")]
[assembly: AssemblyFileVersion("3.5.9.0")]

0 comments on commit 87d128f

Please sign in to comment.