[OGo-Developer] accessing telephone numbers of team members in OGOGroupsPage
Sebastian Reitenbach
developer@opengroupware.org
Tue, 06 Mar 2007 10:02:02 +0100
developer@opengroupware.org wrote:
> On Mar 6, 2007, at 09:09, Sebastian Reitenbach wrote:
> > in OGoGroupsPage.m it fetches the members like this:
> > /* fetch members */
> > members = [cmdctx runCommand:@"team::members",
> > @"teams", self->groupList,
> > @"returnType", intObj(LSDBReturnType_ManyObjects),
> > nil];
> ...
> > /* get telephones */
> > LSRunCommandV(_context, @"person", @"get-telephones",
> > @"objects", m,
> > @"relationKey", @"telephones", nil);
>
> Well, then the telephones should be available in the 'telephones'
> array of the object.
ah, ok, so there is a members.telephones.01_tel key then? or do you mean I have
to add an
NSArray *telephones to the OGoGroupsPage so that the telephone numbers will be
saved in
there, while now as there is no such an array, they just disappear?.
>
> > I see, because of the NSLog statements, the telephone information
> > is fetchted
> > from the database, but If it is not used, I wonder why it is done
> > in the first place.
>
> Because its just a generic fetch method which fetches some superflous
> information.
ok
>
> > another question, what are the differences between calling a
> > command like this:
> > /* get telephones */
> > LSRunCommandV(_context, @"person", @"get-telephones",
> > @"objects", m,
> > @"relationKey", @"telephones", nil);
> >
> > and like this:
> > members = [cmdctx runCommand:@"team::members",
> > @"teams", self->groupList,
> > @"returnType", intObj(LSDBReturnType_ManyObjects),
> > nil];
>
> No difference. One of those probably just calls the other.
ok, yes the team:members some time later calls that get-telephones command.
kind regards
Sebastian