From 7052daa1c8fded384e5dd9e7582014a5acd8188e Mon Sep 17 00:00:00 2001 From: Francis Lachapelle Date: Wed, 5 Nov 2014 10:02:55 -0500 Subject: [PATCH] Fix rename of subscribed addressbooks --- NEWS | 1 + UI/Common/product.plist | 2 +- UI/WebServerResources/ContactsUI.js | 10 ++-------- 3 files changed, 4 insertions(+), 9 deletions(-) diff --git a/NEWS b/NEWS index 5ce79af5f..85102bcd9 100644 --- a/NEWS +++ b/NEWS @@ -15,6 +15,7 @@ Bug fixes - fixed many interop issues with Windows Phones over ActiveSync - fixed automatic return receipts crash when not in the recepient list (#2965) - fixed support for Sieve folder encoding parameter (#2622) + - fixed rename of subscribed addressbooks 2.2.9a (2014-09-29) ------------------- diff --git a/UI/Common/product.plist b/UI/Common/product.plist index 160e4155f..d5d6936a1 100644 --- a/UI/Common/product.plist +++ b/UI/Common/product.plist @@ -107,7 +107,7 @@ actionName = "subscribeUsers"; }; renameFolder = { - protectedBy = "Change Permissions"; + protectedBy = "Access Contents Information"; actionClass = "UIxFolderActions"; actionName = "renameFolder"; }; diff --git a/UI/WebServerResources/ContactsUI.js b/UI/WebServerResources/ContactsUI.js index 27a462984..fd460859c 100644 --- a/UI/WebServerResources/ContactsUI.js +++ b/UI/WebServerResources/ContactsUI.js @@ -1113,19 +1113,14 @@ function onAddressBooksMenuPrepareVisibility() { var menu = $("contactFoldersMenu").down("ul");; var listElements = menu.childNodesWithTag("li"); - var modifyOption = listElements[0]; var newListOption = listElements[3]; var removeOption = listElements[5]; var exportOption = listElements[7]; var importOption = listElements[8]; var sharingOption = listElements[listElements.length - 1]; - // Disable the "Sharing" and "Modify" options when address book - // is not owned by user + // Disable the "Sharing" option when address book is not owned by user if (folderOwner == UserLogin || IsSuperUser) { - modifyOption.removeClassName("disabled"); // WARNING: will fail - // for super users - // anyway var aclEditing = selected[0].getAttribute("acl-editing"); if (aclEditing && aclEditing == "available") { sharingOption.removeClassName("disabled"); @@ -1147,8 +1142,7 @@ function onAddressBooksMenuPrepareVisibility() { newListOption.addClassName("disabled"); } - /* Disable the "remove" and "export ab" options when address book is - public */ + // Disable the "remove" and "export ab" options when address book is public if (folderOwner == "nobody") { exportOption.addClassName("disabled"); importOption.addClassName("disabled");