mirror of
https://github.com/OrchardCMS/Orchard.git
synced 2025-10-14 10:54:50 +08:00
Ensuring the Blog SummaryAdmin template pulls in required scripts and making a couple JS functions better jQuery citizens
--HG-- branch : dev
This commit is contained in:
@@ -85,11 +85,12 @@
|
||||
var firstError = _this.find(".input-validation-error").first();
|
||||
// try to focus the first error on the page
|
||||
if (firstError.size() === 1) {
|
||||
return firstError.focus();
|
||||
firstError.focus();
|
||||
return _this;
|
||||
}
|
||||
// or, give it up to the browser to autofocus
|
||||
if ('autofocus' in document.createElement('input')) {
|
||||
return;
|
||||
return _this;
|
||||
}
|
||||
// otherwise, make the autofocus attribute work
|
||||
var autofocus = _this.find(":input[autofocus]").first();
|
||||
@@ -102,7 +103,7 @@
|
||||
|
||||
// give it up to the browser to handle placeholder text
|
||||
if ('placeholder' in document.createElement('input')) {
|
||||
return;
|
||||
return _this;
|
||||
}
|
||||
// otherwise, make the placeholder attribute work
|
||||
$(":input[placeholder]")
|
||||
|
@@ -3,6 +3,7 @@
|
||||
@using Orchard.ContentManagement;
|
||||
@using Orchard.Utility.Extensions;
|
||||
@{
|
||||
Script.Require("ShapesBase");
|
||||
ContentItem contentItem = Model.ContentItem;
|
||||
var returnUrl = ViewContext.RequestContext.HttpContext.Request.ToUrlString();
|
||||
}
|
||||
|
Reference in New Issue
Block a user