Skip to main content
Recent Posts
6
General Discussion / Filtro non visualizza i campi
Last post by daninet -
Salve a tutti.
Ho impostato un filtro in una pagina..  se controllo la query i valori di sono si carica il combo ma non si vedono i valori.

Hello everyone.
I set a filter on a page.. if you check the query the values ​​of are loads the combo but you don't see the values.
7
Questions / Re: trigger
Last post by daninet -
after insert - tabella prenotazioni

$table_data = array(
    "status" => "OCC",
    "postazione_id" => $rec_id
);
$db->where("id", $rec_id);
$bool = $db->update("postazioni", $table_data);

se inserisco questo codice ho error 500
8
Questions / Re: trigger
Last post by daninet -
Il trigger fa questo su after insert della tabella prenotazioni
UPDATE postazioni
SET postazioni.status='OCC'
WHERE postazioni.id = new.postazione_id "

questo è su page events ma non so come impostarlo

$table_data = array(
    "fieldname" => "value",
    "fieldname2" => "value2"
);
$db->where("table_id", $rec_id);
$bool = $db->update("tablename", $table_data);
9
General Discussion / Query page_id
Last post by giulio -
Good morning,
I'm inserting a custom sql query to create a drop-down menu in the form of an add page, but even though the query is correct, when I start the page it doesn't work, it seems like it doesn't recognize the $page_id variable.

The query without $page_id filter (works correctly and returns me all records):

"SELECT DISTINCT dr.id_distinta, dr.id_fase AS value, caf.codice AS label FROM line_list dr JOIN cfg_anagrafica_fasi caf ON dr.id_fase = caf.id"

The query with $page_id filter doesn't work:

"SELECT DISTINCT dr.id_distinta, dr.id_fase AS value, caf.codice AS label FROM line_list dr JOIN cfg_anagrafica_fasi caf ON dr.id_fase = caf.id WHERE dr.id_distinta = $page_id"

I can't understand the error

Thanks for the help