后端-活动管理页面校验修改
This commit is contained in:
parent
5fa29fd7c9
commit
6bf8aca3ac
|
|
@ -1050,6 +1050,14 @@
|
||||||
var btnFinish = $('<a id="btn-finish"></a>').text('完成')
|
var btnFinish = $('<a id="btn-finish"></a>').text('完成')
|
||||||
.addClass('btn btn-info')
|
.addClass('btn btn-info')
|
||||||
.on('click', function () {
|
.on('click', function () {
|
||||||
|
var flag = $("#step-7").validate({
|
||||||
|
errorPlacement: function(error, element) {
|
||||||
|
error.appendTo(element.parent().parent().parent());
|
||||||
|
}
|
||||||
|
}).form();
|
||||||
|
if (flag == false){
|
||||||
|
return;
|
||||||
|
}
|
||||||
//添加保存逻辑
|
//添加保存逻辑
|
||||||
var markupStr = $('.summernote').summernote('code');
|
var markupStr = $('.summernote').summernote('code');
|
||||||
$("#btnLink2").val(markupStr);
|
$("#btnLink2").val(markupStr);
|
||||||
|
|
@ -1224,7 +1232,12 @@
|
||||||
// 该事件在离开某个步骤之前触发
|
// 该事件在离开某个步骤之前触发
|
||||||
$("#smartwizard").on("leaveStep", function (e, anchorObject, currentStepNumber, nextStepNumber, stepDirection) {
|
$("#smartwizard").on("leaveStep", function (e, anchorObject, currentStepNumber, nextStepNumber, stepDirection) {
|
||||||
if (stepDirection == 'forward') {
|
if (stepDirection == 'forward') {
|
||||||
return $("#step-" + (currentStepNumber + 1)).validate().form();
|
return $("#step-" + (currentStepNumber + 1)).validate({
|
||||||
|
errorPlacement: function(error, element) {
|
||||||
|
error.appendTo(element.parent().parent().parent());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
).form();
|
||||||
}
|
}
|
||||||
return true;
|
return true;
|
||||||
});
|
});
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue