[ic] Ok heres my problem...

Ron Phipps interchange-users@interchange.redhat.com
Mon Mar 25 17:20:01 2002


> From: interchange-users-admin@interchange.redhat.com
[mailto:interchange-
> users-admin@interchange.redhat.com] On Behalf Of Mike Heins
> 
> Quoting Ron Phipps (rphipps@reliant-solutions.com):
> > > From: interchange-users-admin@interchange.redhat.com
> > [mailto:interchange-
> > > users-admin@interchange.redhat.com] On Behalf Of micah abrams
> > >
> > > Dear list --
> > >
> > > I am hoping one of you can help me (or at least point me in the
right
> > > direction).  I have a storefront that I setup using interchange.
I am
> > > selling products for a few different companies and would like to
give
> > each
> > > customer a unique login to the admin section which would allow
them to
> > > manage their own inventories (and only thier inventories).  I am
> > rather
> > > new
> > > to interchange and am looking for the easiest possible way to
solve
> > this
> > > problem.
> >
> > IC does not provide row level ownership of records, only table level
> > ownership.  The main reason is most of the underlying databases do
not
> > have this functionality.
> 
> Actually, it does. If you set tables permission owner_field to
> "related", and set the "related" field in products to the username of
> the owner, I think you will find that user will only be able to edit
> their own records.
> 
> The table_control entry in access.asc that would enable this is:
> 
> 	{ owner_field => 'related' }
> 
> You could just as easily add a field called owner or vendor to the
> products
> table and user that.
> 
> There are issues in displaying the edit list, but that would be
relatively
> easy to fix in a custom version of admin/flex_select.html, whereby you
> just qualify any search term with related=[data session username].
> 

Thanks for the example Mike.  We don't have a use for this now, but may
in the future.

-Ron