aboutsummaryrefslogtreecommitdiffstats
path: root/view/js
diff options
context:
space:
mode:
authorzotlabs <mike@macgirvin.com>2017-02-07 16:08:27 -0800
committerzotlabs <mike@macgirvin.com>2017-02-07 16:08:27 -0800
commitb2bae867d02b62708e09e5abf0ebd03a4d2b095e (patch)
tree10e0c03f1a054ffd262c70a8860474a9b6977b0f /view/js
parent1cef3f15d5174636b59c86bb816a0009940201ef (diff)
downloadvolse-hubzilla-b2bae867d02b62708e09e5abf0ebd03a4d2b095e.tar.gz
volse-hubzilla-b2bae867d02b62708e09e5abf0ebd03a4d2b095e.tar.bz2
volse-hubzilla-b2bae867d02b62708e09e5abf0ebd03a4d2b095e.zip
more background work for permcat support
Diffstat (limited to 'view/js')
-rw-r--r--view/js/mod_connedit.js23
1 files changed, 22 insertions, 1 deletions
diff --git a/view/js/mod_connedit.js b/view/js/mod_connedit.js
index 252ed9e7c..d750f3a2f 100644
--- a/view/js/mod_connedit.js
+++ b/view/js/mod_connedit.js
@@ -1,6 +1,7 @@
$(document).ready(function() {
- $('form').areYouSure({'addRemoveFieldsMarksDirty':true, 'message': aStr['leavethispage'] }); // Warn user about unsaved settings
+ // Warn member about unsaved settings
+ $('form').areYouSure({'addRemoveFieldsMarksDirty':true, 'message': aStr['leavethispage'] });
if(typeof(after_following) !== 'undefined' && after_following) {
if(typeof(connectDefaultShare) !== 'undefined')
@@ -102,3 +103,23 @@ function connectFullShare() {
$('#me_id_perms_republish').attr('checked','checked');
$('#me_id_perms_post_like').attr('checked','checked');
}
+
+function loadAbookRole(name) {
+
+ if(! name)
+ name = 'default';
+
+ $('.abook-edit-me').each(function() {
+ if(! $(this).is(':disabled'))
+ $(this).removeAttr('checked');
+ });
+
+ $.get('permcat/' + name, function(data) {
+ $(data.perms).each(function() {
+ if(this.value)
+ $('#me_id_perms_' + this.name).attr('checked','checked');
+ });
+ });
+}
+
+