From 4eb43a2966b1ae68425804b747134cd497ddbe21 Mon Sep 17 00:00:00 2001 From: helge Date: Mon, 30 May 2005 11:25:03 +0000 Subject: [PATCH] string-value shortcut in product.plist git-svn-id: http://svn.opengroupware.org/SOPE/trunk@814 e4a50df8-12e2-0310-a44c-efbce7f8a7e3 --- sope-appserver/NGObjWeb/ChangeLog | 5 +++++ sope-appserver/NGObjWeb/SoObjects/SoProductClassInfo.m | 7 ++++++- sope-appserver/NGObjWeb/Version | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/sope-appserver/NGObjWeb/ChangeLog b/sope-appserver/NGObjWeb/ChangeLog index af8f40c1..383c1485 100644 --- a/sope-appserver/NGObjWeb/ChangeLog +++ b/sope-appserver/NGObjWeb/ChangeLog @@ -1,3 +1,8 @@ +2005-05-30 Helge Hess + + * SoObjects/SoProductClassInfo.m: allow plain string values for slots + in product.plist (v4.5.161) + 2005-05-05 Helge Hess * WEClientCapabilities.m: added Perl HTTP::DAV as a known WebDAV user diff --git a/sope-appserver/NGObjWeb/SoObjects/SoProductClassInfo.m b/sope-appserver/NGObjWeb/SoObjects/SoProductClassInfo.m index d4ef97dc..d72ced18 100644 --- a/sope-appserver/NGObjWeb/SoObjects/SoProductClassInfo.m +++ b/sope-appserver/NGObjWeb/SoObjects/SoProductClassInfo.m @@ -514,6 +514,11 @@ static int loadDebugOn = 0; NSString *valueClassName; Class valueClass; id value; + + if ([_m isKindOfClass:[NSString class]]) { + /* user used: slots = { abc = 15; } */ + _m = [NSDictionary dictionaryWithObject:_m forKey:@"value"]; + } /* security */ @@ -537,7 +542,7 @@ static int loadDebugOn = 0; else valueClass = Nil; - if ((value = [_m objectForKey:@"value"])) { + if ((value = [_m objectForKey:@"value"]) != nil) { if (valueClass) { value = [self instantiateObjectOfClass:valueClass withPlist:value]; diff --git a/sope-appserver/NGObjWeb/Version b/sope-appserver/NGObjWeb/Version index 21496a2b..82d5051f 100644 --- a/sope-appserver/NGObjWeb/Version +++ b/sope-appserver/NGObjWeb/Version @@ -1,6 +1,6 @@ # version file -SUBMINOR_VERSION:=160 +SUBMINOR_VERSION:=161 # v4.5.122 requires libNGExtensions v4.5.153 # v4.5.91 requires libNGExtensions v4.5.134 -- 2.39.5