Changes between Version 62 and Version 63 of AjaxList


Ignore:
Timestamp:
2010-09-08T16:49:46Z (14 years ago)
Author:
Serge Okon
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • AjaxList

    v62 v63  
    186186$joinTables = array(
    187187   array( "joinTable" => "table_name",  // - The name of the table to be joined in
    188           "joinModel" => "ModelName",   // - The name of the Model to create from this table.
     188          "joinModel" => "JoinModel",   // - The name of the Model to create from this table.
    189189                                        //     this does not have to march any CakePHP model at all, and
    190190                                        //     in fact, should be different if you're joining in the same table
    191191                                        //     twice, or don't want to interfere with a model joined by CakePHP.
    192           "localKey" => "local_key",    // - The key to match in local table. If left out, "localModel.id" is substituted.
    193           "foreignKey"=>"foreign_key",  // - The key to match in foreign table. If left out, "joinModel.id" is substituted
     192          "localKey" => "local_key",    // - The key to match in local table. If left out, "id" is substituted.
     193          "foreignKey"=>"foreign_key",  // - The key to match in foreign table. If left out, "id" is substituted
    194194          "localModel" => "LocalModel", // - Usually left out, because the Ajax List's local model is specified in
    195                                         //     the setUpAjaxList() function. However, if you'd like to user a joined-in
     195                                        //     the setUpAjaxList() function. However, if you'd like to use a joined-in
    196196                                        //     list's column to join another table, user this variable to specify
    197 }}}
     197                                        //     that joined Model's name here.
     198}}}
     199
     200The joined in columns should be included in the $columns list, if you'd like to display them. The columns you're joining on (in local model) also need to be present in the $columns list, but may be of hidden-type if you prefer not to display them. Remember, all the columns that are referred to by Ajax List must be in the $columns list.
    198201
    199202