diff --git a/ReleaseNotes.txt b/ReleaseNotes.txt
index 66ecaccbd0..d8ab3d5699 100644
--- a/ReleaseNotes.txt
+++ b/ReleaseNotes.txt
@@ -11,4 +11,9 @@ These notes will form the release notes that go out with each public release
GE 11/06/2012:
Fixed deep linking to Content,Media,DocumentType,MediaType,DataType,Css,Javascript,Razor,XSLT and
added a umbraco.cms.helpers.DeepLink.get class to return valid links based on type and
- id (or file path in the case of js/xslt/razor)
\ No newline at end of file
+ id (or file path in the case of js/xslt/razor)
+GE 11/06/2012:
+ Added links from Document Types to templates via an Edit > link in the checkbox list
+ Rewrote the databinding in DocumentType for Template selection to clean it up
+ Added links from the Template to the Document Type via a new drop down menu in the toolbar
+ Updated umbraco.cms.helpers.DeepLink.Get to be .GetUrl and .GetAnchor and support internal links without page refresh
\ No newline at end of file
diff --git a/components/macroRenderings/umbraco.macroRenderings.csproj b/components/macroRenderings/umbraco.macroRenderings.csproj
index 1d4060b10f..32230df177 100644
--- a/components/macroRenderings/umbraco.macroRenderings.csproj
+++ b/components/macroRenderings/umbraco.macroRenderings.csproj
@@ -36,7 +36,7 @@
3.5
- v3.5
+ v4.0
publish\
true
Disk
@@ -52,6 +52,7 @@
false
false
true
+
bin\Debug\
diff --git a/components/umbraco.controls/TreePicker/BaseTreePickerScripts.Designer.cs b/components/umbraco.controls/TreePicker/BaseTreePickerScripts.Designer.cs
index e21892bfff..5208deb2ad 100644
--- a/components/umbraco.controls/TreePicker/BaseTreePickerScripts.Designer.cs
+++ b/components/umbraco.controls/TreePicker/BaseTreePickerScripts.Designer.cs
@@ -1,7 +1,7 @@
//------------------------------------------------------------------------------
//
// This code was generated by a tool.
-// Runtime Version:4.0.30319.1
+// Runtime Version:4.0.30319.544
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
diff --git a/components/umbraco.controls/umbraco.controls.csproj b/components/umbraco.controls/umbraco.controls.csproj
index f56a5086d8..5581fb5fd1 100644
--- a/components/umbraco.controls/umbraco.controls.csproj
+++ b/components/umbraco.controls/umbraco.controls.csproj
@@ -23,7 +23,7 @@
3.5
- v3.5
+ v4.0
publish\
true
Disk
@@ -39,6 +39,7 @@
false
false
true
+
true
diff --git a/foreign dlls/Examine.dll b/foreign dlls/Examine.dll
index b77f6ebd8c..c238d7375c 100644
Binary files a/foreign dlls/Examine.dll and b/foreign dlls/Examine.dll differ
diff --git a/foreign dlls/ICSharpCode.SharpZipLib.dll b/foreign dlls/ICSharpCode.SharpZipLib.dll
index e829ebf4ba..fe643ebc63 100644
Binary files a/foreign dlls/ICSharpCode.SharpZipLib.dll and b/foreign dlls/ICSharpCode.SharpZipLib.dll differ
diff --git a/foreign dlls/Lucene.Net.dll b/foreign dlls/Lucene.Net.dll
index 138ec60820..28ce25acf0 100644
Binary files a/foreign dlls/Lucene.Net.dll and b/foreign dlls/Lucene.Net.dll differ
diff --git a/foreign dlls/UmbracoExamine.dll b/foreign dlls/UmbracoExamine.dll
index 3881e2d62c..05be41df51 100644
Binary files a/foreign dlls/UmbracoExamine.dll and b/foreign dlls/UmbracoExamine.dll differ
diff --git a/umbraco.MacroEngines.Juno/umbraco.MacroEngines.csproj b/umbraco.MacroEngines.Juno/umbraco.MacroEngines.csproj
index 79299b2705..88f8c449d7 100644
--- a/umbraco.MacroEngines.Juno/umbraco.MacroEngines.csproj
+++ b/umbraco.MacroEngines.Juno/umbraco.MacroEngines.csproj
@@ -41,11 +41,12 @@
..\foreign dlls\Examine.dll
+ False
..\foreign dlls\HtmlAgilityPack.dll
-
+
..\foreign dlls\Lucene.Net.dll
@@ -70,6 +71,7 @@
..\foreign dlls\UmbracoExamine.dll
+ False
diff --git a/umbraco/businesslogic/umbraco.businesslogic.csproj b/umbraco/businesslogic/umbraco.businesslogic.csproj
index e51a7ae406..ff3e038ab9 100644
--- a/umbraco/businesslogic/umbraco.businesslogic.csproj
+++ b/umbraco/businesslogic/umbraco.businesslogic.csproj
@@ -37,7 +37,7 @@
3.5
true
- v3.5
+ v4.0
http://localhost/businesslogic/
true
Web
@@ -52,6 +52,7 @@
1.0.0.%2a
false
true
+
bin\Debug\
@@ -101,9 +102,7 @@
AllRules.ruleset
-
- System
-
+
3.5
diff --git a/umbraco/cms/businesslogic/ContentType.cs b/umbraco/cms/businesslogic/ContentType.cs
index 70532eed4c..8b43a48edd 100644
--- a/umbraco/cms/businesslogic/ContentType.cs
+++ b/umbraco/cms/businesslogic/ContentType.cs
@@ -12,7 +12,9 @@ using umbraco.cms.businesslogic.language;
using umbraco.cms.businesslogic.propertytype;
using umbraco.cms.businesslogic.web;
using umbraco.DataLayer;
+using Tuple = System.Tuple;
using umbraco.BusinessLogic;
+using umbraco.DataLayer.SqlHelpers.MySql;
[assembly: InternalsVisibleTo("Umbraco.Test")]
@@ -851,6 +853,30 @@ namespace umbraco.cms.businesslogic
base.delete();
}
+ public IEnumerable> GetContent()
+ {
+ List> list = new List>();
+ bool mySQL = (SqlHelper.GetType() == typeof(MySqlHelper));
+ string sql = string.Empty;
+ if (!mySQL)
+ {
+ sql = "Select top (100) cmsContent.nodeid, cmsDocument.text from cmsContent join cmsDocument on cmsDocument.nodeId = cmsContent.nodeid where cmsdocument.published = 1 and cmscontent.contentType = " + this.Id;
+ }
+ else
+ {
+ sql = "Select cmsContent.nodeid, cmsDocument.text from cmsContent join cmsDocument on cmsDocument.nodeId = cmsContent.nodeid where cmsdocument.published = 1 and cmscontent.contentType = " + this.Id + " limit 0,100";
+ }
+ using (IRecordsReader dr = SqlHelper.ExecuteReader(sql))
+ {
+ while (dr.Read())
+ {
+ list.Add(new System.Tuple(dr.GetInt("nodeid"), dr.GetString("text")));
+ }
+ dr.Close();
+ }
+ return list;
+ }
+
#endregion
#region Protected Methods
diff --git a/umbraco/cms/businesslogic/Packager/FileResources/PackageFiles.Designer.cs b/umbraco/cms/businesslogic/Packager/FileResources/PackageFiles.Designer.cs
index e8648a47f0..e7eb18304c 100644
--- a/umbraco/cms/businesslogic/Packager/FileResources/PackageFiles.Designer.cs
+++ b/umbraco/cms/businesslogic/Packager/FileResources/PackageFiles.Designer.cs
@@ -1,7 +1,7 @@
//------------------------------------------------------------------------------
//
// This code was generated by a tool.
-// Runtime Version:4.0.30319.1
+// Runtime Version:4.0.30319.544
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
diff --git a/umbraco/cms/businesslogic/Tuple.cs b/umbraco/cms/businesslogic/Tuple.cs
index 6cf5fd404e..6034f187b4 100644
--- a/umbraco/cms/businesslogic/Tuple.cs
+++ b/umbraco/cms/businesslogic/Tuple.cs
@@ -6,6 +6,7 @@ using System.Collections;
namespace umbraco.cms.businesslogic
{
+ [Obsolete("umbraco.cms.businesslogic.Tuple is Obsolete, use System.Tuple instead")]
public class Tuple : IEquatable>
{
public T first { get; set; }
diff --git a/umbraco/cms/businesslogic/macro/MacroEngineFactory.cs b/umbraco/cms/businesslogic/macro/MacroEngineFactory.cs
index 245c6a4cb2..e738664bf5 100644
--- a/umbraco/cms/businesslogic/macro/MacroEngineFactory.cs
+++ b/umbraco/cms/businesslogic/macro/MacroEngineFactory.cs
@@ -11,6 +11,8 @@ namespace umbraco.cms.businesslogic.macro
{
private static readonly Dictionary m_engines = new Dictionary();
private static readonly List m_allEngines = new List();
+ private static object locker = new object();
+
public MacroEngineFactory()
{
Initialize();
@@ -39,7 +41,11 @@ namespace umbraco.cms.businesslogic.macro
{
try
{
- m_engines.Add(typeInstance.Name, t);
+ lock (locker)
+ {
+ if (!m_engines.ContainsKey(typeInstance.Name))
+ m_engines.Add(typeInstance.Name, t);
+ }
}
catch (Exception ee)
{
diff --git a/umbraco/cms/businesslogic/template/Template.cs b/umbraco/cms/businesslogic/template/Template.cs
index f5c6585d80..4053f87894 100644
--- a/umbraco/cms/businesslogic/template/Template.cs
+++ b/umbraco/cms/businesslogic/template/Template.cs
@@ -12,6 +12,8 @@ using umbraco.BusinessLogic;
using umbraco.IO;
using System.Web;
using umbraco.cms.businesslogic.web;
+using Tuple = System.Tuple;
+using umbraco.DataLayer.SqlHelpers.MySql;
namespace umbraco.cms.businesslogic.template
{
@@ -326,8 +328,39 @@ namespace umbraco.cms.businesslogic.template
}
}
-
-
+ public IEnumerable GetDocumentTypes()
+ {
+ return DocumentType.GetAllAsList().Where(x => x.allowedTemplates.Select(t => t.Id).Contains(this.Id));
+ }
+ public IEnumerable> GetContent()
+ {
+ List> list = new List>();
+ bool mySQL = (SqlHelper.GetType() == typeof(MySqlHelper));
+ string sql = string.Empty;
+ if (!mySQL)
+ {
+ sql = "Select top (100) nodeid, text from cmsDocument where published = 1 and templateId = " + this.Id;
+ }
+ else
+ {
+ sql = "Select nodeid, text from cmsDocument where published = 1 and templateId = " + this.Id + " limit 0,100";
+ }
+ using (IRecordsReader dr = SqlHelper.ExecuteReader(sql))
+ {
+ int i = 0;
+ while (dr.Read())
+ {
+ list.Add(new System.Tuple(dr.GetInt("nodeid"), dr.GetString("text")));
+ i++;
+ if (i >= 100)
+ {
+ break;
+ }
+ }
+ dr.Close();
+ }
+ return list;
+ }
public static Template MakeNew(string Name, BusinessLogic.User u, Template master)
{
diff --git a/umbraco/cms/businesslogic/workflow/Notification.cs b/umbraco/cms/businesslogic/workflow/Notification.cs
index 71faa2b6ed..7722fd03ba 100644
--- a/umbraco/cms/businesslogic/workflow/Notification.cs
+++ b/umbraco/cms/businesslogic/workflow/Notification.cs
@@ -124,7 +124,7 @@ namespace umbraco.cms.businesslogic.workflow
summary.Append("");
summary.Append("| " +
p.PropertyType.Name + " | ");
- summary.Append("