On Aug 21, 2008, at 4:34 PM, Guido Neitzer wrote:
On 21.08.08 14:26, "Ramsey Gurley" <[EMAIL PROTECTED]> wrote:(task = 'edit' and not (smartRelationship.isToMany = 1)) => componentName = "ERD2WEditToOneRelationship" propertyName = 'location' => componentName = "ERD2WEditToOneRelationship" in my rules file and some combination of those two was resulting in the exceptions. Strangely, I had them disabled in RuleModeler, but they were still taking effect. Deleting the rules solved the exception, but I'm back to a blank area for setting my manufacturer relationship.Yeah, I see now that the first rule I wrote is crap. But I'd say that thisrule: 10 : (task = 'edit' and smartRelationship != null andsmartRelationship .destinationEntity.sharedObjectFetchSpecificationNames.count > 0 and not (smartRelationship.isToMany = 1)) => componentName = ERD2WEditToOneRelationship [com.webobjects.directtoweb.Assignment], Should take care of your problem. Are you really linking againstERDirectToWeb? The rule above is copied from ERDirectToWeb and should takecare of your relationship. cug
Hmm, the above doesn't work unless I remove the sharedObjectFetchSpecNames part of the rule... If I take that out, I get a list of radio buttons that allows me to select a Manufacturer. Indeed, the rule you mention is already there when I enable rule tracing...
But what I think I'm hearing is that I really need to take a closer look at how to set up fetch specs in entity modeler. I'll confess that is something I haven't done before. I took a look at the shared tab on my entity and clicked "share all objects," then removed the new rule to see if my "FetchAll" would cause
smartRelationship .destinationEntity.sharedObjectFetchSpecificationNames.count > 0
to evaluate differently. It did. The result is that Manufacturer disappears from my MenuHeader and QueryAll task. The ones I already created are now available in a popup menu in the create Product page... But I'm now wondering why Manufacturer became hidden all of a sudden. Without the fetch spec, I can't set up a product, but with a fetch spec, I can't create, edit, or delete a Manufacturer... the problem reversed itself...
Ramsey
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list ([email protected]) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
