This forum has moved to a new location and is in read-only mode. Please visit talk.octobercms.com to access the new location.

ribbsousa
ribbsousa

My fields.yaml

fields:
    lend_date:
        label: 'ribsousa.library::lang.lending.lend_date'
        oc.commentPosition: ''
        mode: datetime
        span: auto
        type: datepicker
        default:
        minDate:
        maxDate:

My model class

<?php namespace Ribsousa\Library\Models;

use Model;
use Carbon\Carbon;

/**
 * Model
 */
class Lending extends Model
{
 public function filterFields($fields, $context = null)
 {  
        $fields->lend_date->minDate = Carbon::now();
 }

It´s not work

1-1 of 1

You cannot edit posts or make replies: the forum has moved to talk.octobercms.com.