yii\db\SchemaBuilderTrait::dateTime PHP 메소드

dateTime() 공개 메소드

Creates a datetime column.
부터: 2.0.6
public dateTime ( integer $precision = null ) : ColumnSchemaBuilder
$precision integer column value precision. First parameter passed to the column type, e.g. DATETIME(precision). This parameter will be ignored if not supported by the DBMS.
리턴 ColumnSchemaBuilder the column instance which can be further customized.
    public function dateTime($precision = null)
    {
        return $this->getDb()->getSchema()->createColumnSchemaBuilder(Schema::TYPE_DATETIME, $precision);
    }