* 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA *
***************************************************************************/
-class PLTableEditor
+class PLTableEditor
{
// the plat/al name of the page
public $pl;
$a['Value'] = $a['List'][0];
} else {
$a['Type'] = 'set';
- }
+ }
}
elseif (substr($a['Type'],0,5) == 'enum(') {
// get the list of options
}
// called before editing $entry
- private function prepare_edit(&$entry)
+ private function prepare_edit(&$entry)
{
foreach ($this->vars as $field => $descr) {
if ($descr['Type'] == 'set') {
}
return $entry;
}
-
+
// set whether the save button show redirect to list view or edit view
public function list_on_edit($var)
{
$this->vars[$name]['desc'] = $desc;
$this->vars[$name]['display'] = $display;
}
-
+
// add a join table, when deleting a row corresponding entries will be deleted in these tables
public function add_join_table($name,$joinid,$joindel,$joinextra="")
{
if ($joindel)
$this->jtables[$name] = array("joinid" => $joinid,"joinextra" => $joinextra?(" AND ".$joinextra):"");
}
-
+
// add a sort key
public function add_sort_field($key, $desc = false, $default = false)
{