Ejuidatetimepicker Default Value


I am using ejuidatetimepicker extension and in my view I have a field like this:

	<div class="row">

		<?php echo $form->labelEx($model,'activation_date'); ?>






                        'hourGrid' => 4,

                        'minuteGrid' => 15,

                        'timeFormat' => 'hh:mm:ss',





		<?php echo $form->error($model,'activation_date'); ?>


My question is how can I have a default text (says "now") displayed in the field and if the user did not manually select using the picker then the value will be cdbexpression now saved in database. Similarly, I have an expiration field like the above and I would like a default text (says "never") and if nothing picked then the value will be NULL. Both of my fields have datatype timestamp in the model.

Thank you for any advice/help!


above the EJuiDateTimePicker component check whetehr attribute is null. if null assign vlaue is now today date :)

That is true and I knew that. The problem is end-user who use this app doesn’t hence if I can put “now” on the textfield that would improve usability. Thank you! Anyone can help?