Index: lams_admin/web/integration/ltiConsumer.jsp
===================================================================
diff -u -r6773df2f14e862722e0c63f969649af559ec0439 -re3a1990532eb6f5524cd15ec1feec08131d9b3d2
--- lams_admin/web/integration/ltiConsumer.jsp (.../ltiConsumer.jsp) (revision 6773df2f14e862722e0c63f969649af559ec0439)
+++ lams_admin/web/integration/ltiConsumer.jsp (.../ltiConsumer.jsp) (revision e3a1990532eb6f5524cd15ec1feec08131d9b3d2)
@@ -19,7 +19,8 @@
$(document).ready(function(){
// validate signup form on keyup and submit
var validator = $("#ltiConsumerForm").validate({
- errorClass: 'text-danger form-text font-italic',
+ validClass: "is-valid",
+ errorClass: 'is-invalid',
rules: {
serverid: "required",
serverkey: "required",
Index: lams_admin/web/integration/servermaintain.jsp
===================================================================
diff -u -r509e81cd8bc4486fab7de352c4e8cfafd38efe48 -re3a1990532eb6f5524cd15ec1feec08131d9b3d2
--- lams_admin/web/integration/servermaintain.jsp (.../servermaintain.jsp) (revision 509e81cd8bc4486fab7de352c4e8cfafd38efe48)
+++ lams_admin/web/integration/servermaintain.jsp (.../servermaintain.jsp) (revision e3a1990532eb6f5524cd15ec1feec08131d9b3d2)
@@ -29,7 +29,8 @@
// validate signup form on keyup and submit
var validator = $("#extServerForm").validate({
- errorClass: 'text-danger form-text font-italic',
+ validClass: "is-valid",
+ errorClass: 'is-invalid',
rules: {
serverid: "required",
serverkey: "required",
@@ -83,7 +84,7 @@
*
-
+
*
Index: lams_admin/web/orgPasswordChange.jsp
===================================================================
diff -u -r509e81cd8bc4486fab7de352c4e8cfafd38efe48 -re3a1990532eb6f5524cd15ec1feec08131d9b3d2
--- lams_admin/web/orgPasswordChange.jsp (.../orgPasswordChange.jsp) (revision 509e81cd8bc4486fab7de352c4e8cfafd38efe48)
+++ lams_admin/web/orgPasswordChange.jsp (.../orgPasswordChange.jsp) (revision e3a1990532eb6f5524cd15ec1feec08131d9b3d2)
@@ -62,11 +62,6 @@
.ui-jqgrid-btable tr.success > td {
background-color: transparent !important;
}
-
- #formValidationErrors {
- display: none;
- text-align: center;
- }
@@ -115,7 +110,7 @@
grid.slideUp();
pass.val(null).prop('disabled', true);
}
- });
+ });
// generate new password on click
$('.generatePassword').click(function(){
@@ -130,12 +125,10 @@
});
});
-
-
// Setup form validation
$("#orgPasswordChangeForm").validate({
- errorLabelContainer : '#formValidationErrors',
- errorClass : 'errorMessage',
+ validClass: "is-valid",
+ errorClass: 'is-invalid',
rules : {
learnerPass : {
required: false,
@@ -151,7 +144,6 @@
charactersAllowed : true,
pwcheck : true
}
-
},
// Specify the validation error messages
@@ -411,10 +403,7 @@
-
-
+
Index: lams_admin/web/policies/editPolicy.jsp
===================================================================
diff -u -r509e81cd8bc4486fab7de352c4e8cfafd38efe48 -re3a1990532eb6f5524cd15ec1feec08131d9b3d2
--- lams_admin/web/policies/editPolicy.jsp (.../editPolicy.jsp) (revision 509e81cd8bc4486fab7de352c4e8cfafd38efe48)
+++ lams_admin/web/policies/editPolicy.jsp (.../editPolicy.jsp) (revision e3a1990532eb6f5524cd15ec1feec08131d9b3d2)
@@ -18,25 +18,26 @@
$(document).ready(function(){
// validate signup form on keyup and submit
var validator = $("#policy-form").validate({
- errorClass: 'text-danger form-text font-italic',
+ validClass: "is-valid",
+ errorClass: 'is-invalid',
ignore: [],
rules: {
policyName: "required",
summary:{
required: function() {
-
- //var ckeditorData = CKEDITOR.instances.summary.getData();
+ var ckeditorData = CKEDITOR.instances.summary.getData();
//skip out empty values
//CKEDITOR.instances.summary.value = ((ckeditorData == null) || (ckeditorData.replace(/ | |
|\s||<\/p>|\xa0/g, "").length == 0)) ? "" : ckeditorData;
CKEDITOR.instances.summary.updateElement();
- //alert("s"+ckeditorData);
- //return false;
+ return (ckeditorData == null || ckeditorData.replace(/ | |
|\s|
|<\/p>|\xa0/g, "").length == 0);
}
},
fullPolicy:{
required: function() {
+ var ckeditorData = CKEDITOR.instances.fullPolicy.getData();
CKEDITOR.instances.fullPolicy.updateElement();
+ return (ckeditorData == null || ckeditorData.replace(/ | |
|\s|
|<\/p>|\xa0/g, "").length == 0);
}
}
},
@@ -47,11 +48,22 @@
},
errorPlacement: function(error, element) {
var placement = $(element).data('error');
-
+
+ //show error below CKEditor
if (element.attr("name") == "summary" ) { //Id of input field
error.appendTo('#summary-error');
+
+ //add .is-invalid to the CKEditor div
+ $("#summary").next().addClass("is-invalid");
+
+ //show error below CKEditor
} else if (element.attr("name") == "fullPolicy" ) {//Id of input field
error.appendTo('#full-policy-error');
+
+ //add .is-invalid to the CKEditor div
+ $("#fullPolicy").next().addClass("is-invalid");
+
+ //show error at the default place
} else {
error.insertAfter(element);
}
Index: lams_admin/web/user.jsp
===================================================================
diff -u -r6773df2f14e862722e0c63f969649af559ec0439 -re3a1990532eb6f5524cd15ec1feec08131d9b3d2
--- lams_admin/web/user.jsp (.../user.jsp) (revision 6773df2f14e862722e0c63f969649af559ec0439)
+++ lams_admin/web/user.jsp (.../user.jsp) (revision e3a1990532eb6f5524cd15ec1feec08131d9b3d2)
@@ -1,5 +1,4 @@
-
<%@ include file="/taglibs.jsp"%>
<%@ page import="org.lamsfoundation.lams.util.Configuration"%>
<%@ page import="org.lamsfoundation.lams.util.ConfigurationKeys"%>
@@ -60,7 +59,8 @@
$(function() {
// Setup form validation
$("#userForm").validate({
- errorClass : 'text-danger form-text font-italic',
+ validClass: "is-valid",
+ errorClass: 'is-invalid',
// validation rules
rules : {
login : {
@@ -315,16 +315,19 @@
-
+ :
+
+