This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.
jprevot
Having a validation event always jumps and runs the if that is inside even not coinciding
public function afterValidate()
{
if( $this->config_source=="AA")
{
$extra_days = $this->json_extras['extra_dia'];
$default_days = $this->json_extras['default_days'];
$total_days = $extra_days + $default_days;
$this->billing_date_from = Carbon::now();
$this->billing_date_to = Carbon::now()->addDay($total_days);
$this->enabled = true;
}
}
Last updated
1-2 of 2