aboutsummaryrefslogtreecommitdiffstats
path: root/view/js/mod_connedit.js
diff options
context:
space:
mode:
authormrjive <mrjive@mrjive.it>2015-01-06 15:13:03 +0100
committermrjive <mrjive@mrjive.it>2015-01-06 15:13:03 +0100
commitb80c218606994032e76805900cb9b340ea132358 (patch)
treebf625cf4c59bf521e639018399bf1770d116a6a0 /view/js/mod_connedit.js
parentaa6d61d3b19cb13c30bf5a1579adefedf0cc9515 (diff)
parent3185bfe3ca131d471b8fcdc0c94abf1a114486c7 (diff)
downloadvolse-hubzilla-b80c218606994032e76805900cb9b340ea132358.tar.gz
volse-hubzilla-b80c218606994032e76805900cb9b340ea132358.tar.bz2
volse-hubzilla-b80c218606994032e76805900cb9b340ea132358.zip
Merge pull request #1 from friendica/master
test pull request
Diffstat (limited to 'view/js/mod_connedit.js')
-rw-r--r--view/js/mod_connedit.js45
1 files changed, 26 insertions, 19 deletions
diff --git a/view/js/mod_connedit.js b/view/js/mod_connedit.js
index 4d25bb8c4..15b768929 100644
--- a/view/js/mod_connedit.js
+++ b/view/js/mod_connedit.js
@@ -1,20 +1,32 @@
+function abook_perms_msg() {
+ $('.abook-permschange').show();
+// $('.abook-permschange').html(aStr['permschange']);
+ $('.abook-permssave').show();
+}
+
$(document).ready(function() {
- if(typeof(after_following) !== 'undefined' && after_following)
- connectFullShare();
+ if(typeof(after_following) !== 'undefined' && after_following) {
+ if(typeof(connectDefaultShare) !== 'undefined')
+ connectDefaultShare();
+ else
+ connectFullShare();
+ }
$('#id_pending').click(function() {
- connectFullShare();
+ if(typeof(connectDefaultShare) !== 'undefined')
+ connectDefaultShare();
+ else
+ connectFullShare();
});
$('.abook-edit-me').click(function() {
- $('.abook-permschange').show();
- $('.abook-permschange').html(aStr['permschange']);
+ abook_perms_msg();
});
-
});
+
function connectFullShare() {
$('.abook-edit-me').each(function() {
if(! $(this).is(':disabled'))
@@ -34,9 +46,7 @@ function connectFullShare() {
$('#me_id_perms_view_storage').attr('checked','checked');
$('#me_id_perms_republish').attr('checked','checked');
$('#me_id_perms_post_like').attr('checked','checked');
-
- $('.abook-permschange').show();
- $('.abook-permschange').html(aStr['permschange']);
+ abook_perms_msg();
}
function connectCautiousShare() {
@@ -54,8 +64,7 @@ function connectCautiousShare() {
$('#me_id_perms_post_comments').attr('checked','checked');
$('#me_id_perms_post_mail').attr('checked','checked');
$('#me_id_perms_post_like').attr('checked','checked');
- $('.abook-permschange').show();
- $('.abook-permschange').html(aStr['permschange']);
+ abook_perms_msg();
}
@@ -78,8 +87,7 @@ function connectForum() {
$('#me_id_perms_tag_deliver').attr('checked','checked');
$('#me_id_perms_republish').attr('checked','checked');
$('#me_id_perms_post_like').attr('checked','checked');
- $('.abook-permschange').show();
- $('.abook-permschange').html(aStr['permschange']);
+ abook_perms_msg();
}
@@ -88,8 +96,8 @@ function connectClear() {
if(! $(this).is(':disabled'))
$(this).removeAttr('checked');
});
- $('.abook-permschange').show();
- $('.abook-permschange').html(aStr['permschange']);
+ abook_perms_msg();
+
}
function connectSoapBox() {
@@ -104,8 +112,8 @@ function connectSoapBox() {
$('#me_id_perms_view_contacts').attr('checked','checked');
$('#me_id_perms_view_storage').attr('checked','checked');
$('#me_id_perms_view_pages').attr('checked','checked');
- $('.abook-permschange').show();
- $('.abook-permschange').html(aStr['permschange']);
+ abook_perms_msg();
+
}
@@ -116,8 +124,7 @@ function connectFollowOnly() {
});
$('#me_id_perms_send_stream').attr('checked','checked');
- $('.abook-permschange').show();
- $('.abook-permschange').html(aStr['permschange']);
+ abook_perms_msg();
}