Skip to content

Commit

Permalink
修改时间戳的字段名,与框架的相同
Browse files Browse the repository at this point in the history
  • Loading branch information
yunwuxin committed May 18, 2016
1 parent 8d8a15b commit e1b9f3e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions phinx/src/Phinx/Db/Table.php
Original file line number Diff line number Diff line change
Expand Up @@ -559,11 +559,11 @@ public function hasForeignKey($columns, $constraint = null)
*/
public function addTimestamps()
{
$this->addColumn('created_at', 'timestamp', array(
$this->addColumn('create_time', 'timestamp', array(
'default' => 'CURRENT_TIMESTAMP',
'update' => ''
))
->addColumn('updated_at', 'timestamp', array(
->addColumn('update_time', 'timestamp', array(
'null' => true,
'default' => null
));
Expand Down

0 comments on commit e1b9f3e

Please sign in to comment.