Changes between Version 25 and Version 26 of AjaxList


Ignore:
Timestamp:
2010-09-02T19:57:48Z (14 years ago)
Author:
Serge Okon
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • AjaxList

    v25 v26  
    106106  * ''map'' - this is a dictionary look-up type. It takes the column entry to be a key, and look it up in an associative array. This array is passes as a Column Type Parameter, following the column type. For example, the following is used in the users controller to translate entries like "A", "S", and "I" to "Admin", "Student", and "Instructor", respectively.
    107107   * {{{ array("User.role",       "Role",         "6em",    "map", array(  "A" => "Admin",  "I" => "Instructor", "S" => "Student")), }}}
    108    * The general format for this column is: {{{}}}
     108   * The general format for this column is: {{{array(<Model.column 1>, <Column Name 1>, <CSS width of column 1>, <column 1 type>, <lookUpDictionary>}}}
    109109   * An extra feature of the ''map'' is that the JS AjaxList client also creates a drop-down filter for it. In this way, the end-user can choose to selectively view the mapped types, or all the types at once. In the iPeer's users controller this is used to switch the view between Admin's, Instructors, and Students.
    110110   * If the column contents is not a valid key in the supplied dictionary, the entry is listed, and unknown keyword appears beside.