Fixes up the GetUrlWithTimeStamp to be called GetUrlWithCacheBust and another extension method to actually generate the hash which will be umb version + cdf version hashed or datetime.ticks if in debug mode. Updates the main view to use CDF to render the CSS which ensures compression/minification/combination + cache busting.

This commit is contained in:
Shannon
2014-03-07 11:03:13 +11:00
parent bb527996b9
commit 9dd5f250c7
4 changed files with 44 additions and 22 deletions

View File

@@ -55,11 +55,8 @@ namespace Umbraco.Web.UI.JavaScript
else
{
//create a unique hash code of the current umb version and the current cdf version
var versionHash = new HashCodeCombiner();
versionHash.AddCaseInsensitiveString(UmbracoVersion.Current.ToString());
versionHash.AddCaseInsensitiveString(ClientDependencySettings.Instance.Version.ToString(CultureInfo.InvariantCulture));
var version = "'" + versionHash.GetCombinedHashCode() + "'";
var versionHash = UrlHelperExtensions.GetCacheBustHash();
var version = "'" + versionHash + "'";
noCache = noCache.Replace("##rnd##", version);
}