Radicore Forum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » RADICORE » How To » std.list3 passing middle table to child form
Re: std.list3 passing middle table to child form [message #387 is a reply to message #386] Thu, 09 November 2006 05:09 Go to previous messageGo to previous message
AJM is currently offline  AJM
Messages: 2350
Registered: April 2006
Location: Surrey, UK
Senior Member
Your method of building the $where string from $_SESSION['logon_user_id'] is the approach I would have used. It would not be possible to use the Task Parameter 'Selection (fixed)' in the RBAC system as you can only specify a fixed string, not construct one from a variable.

The method of modifying the primary key details in the middle table so that the correct values are passed to the inner table is what I actually use in table class 'crs_schedule_x01.class.inc', which is used in the example I gave you. The code is:
function _cm_changeConfig ($where, $fieldarray)
{
    // temporarily define a different primary key
    $this->primary_key = array('schedule_id', 'room_id', 'day_no');

    return $fieldarray;

} // _cm_changeConfig

That's one of the advantages of getting the table specifications from the contents of the <table>.dict.inc file which is exported from the Data Dictionary - the contents can be modified at any time. That would not be possible if I read the primary key directly from the database because then I would be stuck with the database definiton. With my method I can change any of those details, so there is MUCH more flexibility.


 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: File picker
Next Topic: Debug application
Goto Forum:
  


Current Time: Fri May 17 02:09:03 EDT 2024

Total time taken to generate the page: 0.00979 seconds