Forums

FORM VIEW in CV6 that contain a CF6 form : save ok, but doesn't retrieve data from DB

gix.vax 16 Apr, 2018
hi all

i hope this is not a crossposting,
the other thread is marked as answered then i think no one will answer me there.

by the way,
following this thread
http://www.chronoengine.com/forums/posts/t105191/cannot-save-record-edited-by-the-chronoforms-form-however-same-settings-for-ccv6-form-is-working
i'm able to open a CF6 form inside a form view in CC6 and save data
but my form have all the fields empty except the idfield (idimbarcazione)
then my record is saved empty except idimbarcazione or fields that i compile manually.
I think the array have only idimbarcazione inside but i can't understand why, if i use a test table it works (see below)

scenario:
i have a table view that show all my records (not filtered, all)
every row have a task button in every row that open a form view with a CF6 inside to show only the record of the row and a save button (that works)

taskbutton:
event : edit
url : idimbarcazione={var:Imbarcazioni_list.row.imbarcazioni_lista.idimbarcazione}

function
name: fn_imbarcazioni_dettaglio
model : imbarcazioni_dettaglio
where condition : imbarcazioni_dettaglio.idimbarcazione:{data:idimbarcazione}
(this function work with a TEST table view and show the row i need...see below)

TEST TABLE VIEW (used for test function)
data provider : {var:fn_imbarcazioni_dettaglio}
column list:
imbarcazioni_dettaglio.idimbarcazione:idimbarcazione
imbarcazioni_dettaglio.nomeimbarcazione:nomeimbarcazione
this work without problem

Event EDIT content:
{fn:fn_imbarcazioni_dettaglio}
{view:imbarcazioni_inserisci_cf6}

form view :
name : view imbarcazioni_inserisci_cf6
data provider : {var:fn_imbarcazioni_dettaglio}
event : save
content:
{view:campi_aggiuntivi} (are test fields)
{chronoform.section:cc_Imbarcazioni_inserisci/one} (my CF6 form to display and save data data)
{view:salva_imbarcazione} (this work without problem)

CF6Form have
default event : load
in load section:
name : one
data provider {data:}

in CF6 i tried in value of the fileds, things like this
{data:nomeimbarcazione}
or
{var:fn_imbarcazioni_dettaglio.imbarcazione_dettaglio.nomeimbarcazione}
or
{var:fn_imbarcazioni_dettaglio.row.imbarcazione_dettaglio.nomeimbarcazione}

nothing: only idimbarcazione have value whit {data:idimbarcazione}


P.S.
Debug mode doesn't work, maybe a limitation of a CF6 in CC6?
if yes, there are other limitation, for example: can i use read data inside cF6 and it works inside a form view in CC6 or is "cutted away"?

someone can help me?

thank you
Gianluca
gix.vax 16 Apr, 2018
Answer
ok, i understand reading this
https://www.chronoengine.com/forums/posts/t103622/populate-cfv6-form-with-ccv6-data?keywords=ccv6%20read%20data%20in%20cf6

in form view i must use
data provider : {var:fn_imbarcazioni_dettaglio.imbarcazioni_dettaglio}
AND NOT {var:fn_imbarcazioni_dettaglio}

in function i must use:
firt matching record

now my table test (based on the same function) stops to work but is a test table then ok
This topic is locked and no more replies can be posted.