Jump to content


Populating add form with existing record

GCEnt addform

  • Please log in to reply
1 reply to this topic

#1 rkrajnik

rkrajnik

    Advanced Member

  • Members
  • PipPipPip
  • 34 posts

Posted 27 June 2020 - 05:51 PM

I've add a call to SetActionButton() to include an "add" option for that row.  I'd like populate all data/fields from grid row to the new add form, allow changes and then "Save" as normal.  My SetActionButton() is:

$crud->setActionButton('Add a Visit''fa fa-user'function ($row) {
            return 'controller#add' . $row->_id;
        }, true);

 

That allows the "Add a Visit" option for the row but if selected flashes a blank screen and returns to the original grid without prompting the user for data changes, etc.
 

Hoping this is simple and I'm just overlooking something obvious.

 

Thanks in advance.

 



#2 rkrajnik

rkrajnik

    Advanced Member

  • Members
  • PipPipPip
  • 34 posts

Posted 03 July 2020 - 12:29 PM

setClone() does enough of the work, issue closed.






0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users