src/BootstrapFormBuilder.php
public function datetime($name, $value = null, $options = [])
    {
        $value = $this->getValueAttribute($name, $value);

        $timeValue = $dateValue = null;
        if($value instanceof \DateTime)
        {
            $dateValue= $value->format('Y-m-d');
            $timeValue = $value->format('H:i');
        }

        return $this->date($name.'[date]', $dateValue, $options) . $this->time($name.'[time]', $timeValue, $options);
    }
public function datetime($name, $value = null, $options = [])
    {
        $value = $this->getValueAttribute($name, $value);

        $timeValue = $dateValue = null;
        if($value instanceof \DateTime)
        {
            $dateValue= $value->format('Y-m-d');
            $timeValue = $value->format('H:i');
        }

        return $this->date($name.'[date]', $dateValue, $options) . $this->time($name.'[time]', $timeValue, $options);
    }
public function datetime ( $ name , $ value = null , $ options = [ ] ) { $ value = $ this -> getValueAttribute ( $ name , $ value ) ; $ timeValue = $ dateValue = null ; if ( $ value instanceof \ DateTime ) { $ dateValue = $ value -> format ( 'Y-m-d' ) ; $ timeValue = $ value -> format ( 'H:i' ) ; } return $ this -> date ( $ name . '[date]' , $ dateValue , $ options ) . $ this -> time ( $ name . '[time]' , $ timeValue , $ options ) ; }
Create a date and a time input field.

@param  string $name
@param  string $value
@param  array  $options

@return string
Create a date and a time input field .