Howdy,

Trying to crank out a real Cocoa app as an experiment - usually spend my time 
doing Cocoa Touch.

Anyway, I have a pretty simple set of models:

Accounts<->>Items

I want to setup a screen with a table of accounts. When you click on an 
account, you see a table of items, click on an item, see it's detail. Simple.

My question is if I can do this all with bindings. The table of accounts works 
fine. What I can't seem to figure out is how to limit the 'Items' in the second 
NSTableView to just be the ones associated with the selected account, using 
bindings.

Is there a way to do so? I see I can set a fetch predicate for the 
NSArrayController that is controlling the items but I'm not sure how to 
reference the selected account in the 'account' table view to limit the 
contents of the second NSTableView - if that's even possible... Or 
alternatively, just have the items NSTableView show entities that are in the 
'items' relationship of the selected account. Seems like a pretty simple use 
case but I'm missing the magic.

I can see a path by subclassing NSArrayController but I was hoping to do it all 
with bindings if I could - I just don't know enough to know which way to go or 
if I should just break out the code.

Any help appreciated.

Cheers,
Hunter_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to