diff --git a/ChangeLog b/ChangeLog index 71173d93b..07cc5fd38 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2007-03-21 Wolfgang Sourdeau + * UI/Contacts/UIxContactsListView.m ([UIxContactsListView + -deleteAction]): new web method to delete personal addressbook + folders. + * SoObjects/Contacts/SOGoContactGCSFolder.m ([SOGoContactGCSFolder -delete]): override method to refuse the deletion of the folder if its nameInContainer is "personal". diff --git a/UI/Contacts/UIxContactsListView.m b/UI/Contacts/UIxContactsListView.m index 7a3cdd99d..a709758b7 100644 --- a/UI/Contacts/UIxContactsListView.m +++ b/UI/Contacts/UIxContactsListView.m @@ -19,6 +19,9 @@ 02111-1307, USA. */ +#import +#import + #import #import #import @@ -104,6 +107,25 @@ return self; } +- (id ) deleteAction +{ + id result; + NSException *ex; + WOResponse *response; + + ex = [[self clientObject] delete]; + if (ex) + result = ex; + else + { + response = [context response]; + [response setStatus: 200]; + result = response; + } + + return result; +} + - (NSString *) defaultSortKey { return @"fn"; diff --git a/UI/Contacts/product.plist b/UI/Contacts/product.plist index a3424d7ba..6e4d7ea82 100644 --- a/UI/Contacts/product.plist +++ b/UI/Contacts/product.plist @@ -111,6 +111,11 @@ pageName = "UIxContactsListView"; actionName = "addressBooksContacts"; }; + delete = { + protectedBy = "View"; + pageName = "UIxContactsListView"; + actionName = "delete"; + }; }; };