}
// Form
- echo '<form class="db edit form-table" method="post" action="'.$form_action.'">'.NB_EOL;
+ echo '<form class="db edit '.($add ? 'add ' : '' ).'form-table" method="post" action="'.$form_action.'">'.NB_EOL;
echo '<div class="fields">'.NB_EOL;
if ($add or $row) {
if (!$nosql) $this->create_temporary();
list($sql,$where,$limit,$select_count) = $this->rows_sql($opt);
+ $fct_rows_prepare = null;
if ($nosql) {
$sql = empty($this->sql) ? $this->name : $this->sql;
} elseif ($action == 'edit') {
return $this->html_edit();
+ } elseif ($action == 'add') {
+ return $this->html_edit(null,'?',true);
+
} elseif ($this->p('table')) {
# NB 17.03.16 } else {
$this->pdef('limit','20');