Monotone-Parent: 6de228594e5feb001f4208313d8363017d61a463

Monotone-Revision: b83048b6a7cb04b3bd23bb087f18cf0d7c495d49

Monotone-Author: wsourdeau@inverse.ca
Monotone-Date: 2006-10-12T16:42:59
Monotone-Branch: ca.inverse.sogo
This commit is contained in:
Wolfgang Sourdeau
2006-10-12 16:42:59 +00:00
parent 9fa766dae5
commit 142dff8d5e
12 changed files with 117 additions and 260 deletions
+11 -7
View File
@@ -366,11 +366,6 @@
return @"edit";
}
- (NSString *) contactUID
{
return [[self clientObject] nameInContainer];
}
- (CardElement *) _elementWithTag: (NSString *) tag
ofType: (NSString *) type
{
@@ -462,10 +457,11 @@
[self _saveEmails];
}
- (id) saveAction
- (id <WOActionResults>) saveAction
{
id <SOGoContactObject> contact;
id result;
NSString *jsRefreshMethod;
contact = [self clientObject];
card = [contact vCard];
@@ -474,7 +470,15 @@
[self _saveSnapshot];
[contact save];
result = [self redirectToLocation: @".."];
if ([[[[self context] request] formValueForKey: @"nojs"] intValue])
result = [self redirectToLocation: [self applicationPath]];
else
{
jsRefreshMethod
= [NSString stringWithFormat: @"refreshContacts(\"%@\")",
[contact nameInContainer]];
result = [self jsCloseWithRefreshMethod: jsRefreshMethod];
}
}
else
result = [NSException exceptionWithHTTPStatus: 400 /* Bad Request */