Laravel 架构生成器时间戳 *with* 时区
Laravel Schema Builder timestamp *with* timezone
我正在尝试使用 Laravel 架构生成器将 timestamp with time zone
列添加到我的 PostgreSQL 数据库 table。
Schema Builder 提供函数 $table->timestamps()
,它生成列 created_at
和 updated_at
作为 timestamp without time zone
。如何添加时间戳 和 时区?除了 Laravel doc 之外还有其他文档吗?
从本次提交开始,使用 Postgres 时现在可以使用 timestampsTz
函数 - https://github.com/laravel/framework/commit/1afb3d164dedc305d7ecead87262bef6d9218885
我正在尝试使用 Laravel 架构生成器将 timestamp with time zone
列添加到我的 PostgreSQL 数据库 table。
Schema Builder 提供函数 $table->timestamps()
,它生成列 created_at
和 updated_at
作为 timestamp without time zone
。如何添加时间戳 和 时区?除了 Laravel doc 之外还有其他文档吗?
从本次提交开始,使用 Postgres 时现在可以使用 timestampsTz
函数 - https://github.com/laravel/framework/commit/1afb3d164dedc305d7ecead87262bef6d9218885