Files
CasSsoService/overlays/org.apereo.cas.cas-server-webapp-tomcat-5.3.16/WEB-INF/classes/static/js/consent.js
T
chenxing 60da1f6edf
build-push / build-push (push) Failing after 24s
ci
2026-08-31 18:26:28 +08:00

46 lines
1.0 KiB
JavaScript

var strings = strings;
/* global data */
$(document).ready(function(){
resolveAttributes();
optionSelected();
});
function optionSelected() {
var v = $('input[name=option]:checked', '#fm1').val();
if (v == 0) {
$('#reminderPanel').hide();
$('#reminderTab').hide();
} else {
$('#reminderPanel').show();
$('#reminderTab').show();
}
}
function resolveAttributes() {
var table;
if ( $.fn.dataTable.isDataTable( '#attributesTable' ) ) {
table = $('#attributesTable').DataTable();
}
else {
table = $('#attributesTable').DataTable( {
paging : false,
searching : false,
language: {
info: strings.info
}
} );
}
table.clear();
var attrs = data.attributes;
for (var property in attrs) {
if (attrs.hasOwnProperty(property)) {
table.row.add([
'<code>' + property + '</code>', '<code>' + attrs[property] + '</code>'
]).draw(false);
}
}
}