I have a form with several boxes for initials and date for each step completed. I would like for the date to autofill (current date) when the "initials"(completed by) field is completed.
Ex:
Step1 Completed by ____ On __/__/__
Step2 Completed by ____ On __/__/__
Step3 Completed by ____ On __/__/__
Different people are responsible for each step.
Something like:
Before
If step1 completed by = ""
After
If step1 completed by <>"" then step1 completed on = 'current date'
Any thoughts on how to accomplish this?
Conditional field fill - If/Then?
Re: Conditional field fill - If/Then?
Try using the tablename_before_update hook for this ... for example:
Code: Select all
if($data['step1_completed_by'] != ''){ $data['step1_date'] = date('Y-m-d'); }

- DataTalk is an innovative AppGini plugin based on ChatGPT that allows you to interact with your AppGini database using natural language questions, without writing any SQL. Check the demo video
- Check our other plugins and get a generous discount of up to 30% when buying 2 or more plugins.
- Need personalized consulting on your specific app and customizations? Book an online call with me here.