Details improvements
This commit is contained in:
@@ -1,12 +1,28 @@
|
||||
function initFileUpload(objectContext) {
|
||||
"use strict";
|
||||
|
||||
// enforce true attribute client support
|
||||
// enforcetrue attribute client support
|
||||
jQuery.validator.addMethod("enforcetrue", function (value, element, param) {
|
||||
return element.checked;
|
||||
});
|
||||
jQuery.validator.unobtrusive.adapters.addBool("enforcetrue");
|
||||
|
||||
$("form#create").data("validator").settings.submitHandler =
|
||||
function (form) {
|
||||
var identifier = $(form).find("input[name='Identifier']").val();
|
||||
$("<div>" + "Confirm submitting " + identifier + "</div>")
|
||||
.dialog({
|
||||
buttons: {
|
||||
"Confirm": function () {
|
||||
form.submit();
|
||||
},
|
||||
"Cancel": function () {
|
||||
$(this).dialog("close");
|
||||
}
|
||||
}
|
||||
});
|
||||
};
|
||||
|
||||
// We use the upload handler integrated into Backload:
|
||||
// In this example we set an objectContect (id) in the url query (or as form parameter).
|
||||
// You can use a user id as objectContext give users only access to their own uploads.
|
||||
|
||||
Vendored
+18706
File diff suppressed because it is too large
Load Diff
+13
File diff suppressed because one or more lines are too long
+22
-1
@@ -5,7 +5,28 @@
|
||||
return false;
|
||||
});
|
||||
|
||||
// Making elements equal height
|
||||
$("form.confirm").submit(function () {
|
||||
var form = this;
|
||||
var text = "Confirm";
|
||||
var confirmMsg = $(form).attr("confirm-msg");
|
||||
if (confirmMsg) {
|
||||
text = confirmMsg;
|
||||
}
|
||||
$("<div>" + text + "</div>")
|
||||
.dialog({
|
||||
buttons: {
|
||||
"Confirm": function () {
|
||||
form.submit();
|
||||
},
|
||||
"Cancel": function () {
|
||||
$(this).dialog("close");
|
||||
}
|
||||
}
|
||||
});
|
||||
return false;
|
||||
});
|
||||
|
||||
// Making elements equal height
|
||||
var equalheight = function(container){
|
||||
|
||||
var currentTallest = 0,
|
||||
|
||||
Reference in New Issue
Block a user