mirror of
https://github.com/kakwa/ldapcherry
synced 2024-11-22 01:14:21 +01:00
reindent javascript
This commit is contained in:
parent
c67969e2c1
commit
e45c0e862e
@ -1,24 +1,26 @@
|
||||
$('#form').validator({
|
||||
custom: {
|
||||
'ppolicy': function($el) {
|
||||
if(! $el.prop('required') && $el.val() == 0){
|
||||
return true;
|
||||
};
|
||||
var $ret = 'PPolicy error';
|
||||
$.ajax({
|
||||
url: '/checkppolicy',
|
||||
dataType: 'json',
|
||||
async: false,
|
||||
data: 'pwd=' + $el.val(),
|
||||
success: function(data) {
|
||||
if(! $el.prop('required') && $el.val() == 0){
|
||||
return true;
|
||||
};
|
||||
var $ret = 'PPolicy error';
|
||||
$.ajax({
|
||||
url: '/checkppolicy',
|
||||
dataType: 'json',
|
||||
async: false,
|
||||
data: 'pwd=' + $el.val(),
|
||||
success: function(data) {
|
||||
$ret = data;
|
||||
}
|
||||
});
|
||||
this.options.errors['ppolicy'] = $ret['reason'];
|
||||
return $ret['match'];
|
||||
}
|
||||
}
|
||||
});
|
||||
this.options.errors['ppolicy'] = $ret['reason'];
|
||||
return $ret['match'];
|
||||
}
|
||||
},
|
||||
errors: {
|
||||
'ppolicy': 'PPolicy error',
|
||||
}
|
||||
})
|
||||
|
||||
// vim:set expandtab tabstop=4 shiftwidth=4:
|
||||
|
Loading…
Reference in New Issue
Block a user