|
@@ 83-90 (lines=8) @@
|
| 80 |
|
'table' => $parser->getTableName(), |
| 81 |
|
'fields' => $this->getSchemaParser()->render(), |
| 82 |
|
]); |
| 83 |
|
} elseif ($parser->isAdd()) { |
| 84 |
|
return Stub::create('/migration/add.stub', [ |
| 85 |
|
'class' => $this->getClass(), |
| 86 |
|
'table' => $parser->getTableName(), |
| 87 |
|
'fields_up' => $this->getSchemaParser()->up(), |
| 88 |
|
'fields_down' => $this->getSchemaParser()->down(), |
| 89 |
|
]); |
| 90 |
|
} elseif ($parser->isDelete()) { |
| 91 |
|
return Stub::create('/migration/delete.stub', [ |
| 92 |
|
'class' => $this->getClass(), |
| 93 |
|
'table' => $parser->getTableName(), |
|
@@ 97-103 (lines=7) @@
|
| 94 |
|
'fields_down' => $this->getSchemaParser()->up(), |
| 95 |
|
'fields_up' => $this->getSchemaParser()->down(), |
| 96 |
|
]); |
| 97 |
|
} elseif ($parser->isDrop()) { |
| 98 |
|
return Stub::create('/migration/drop.stub', [ |
| 99 |
|
'class' => $this->getClass(), |
| 100 |
|
'table' => $parser->getTableName(), |
| 101 |
|
'fields' => $this->getSchemaParser()->render(), |
| 102 |
|
]); |
| 103 |
|
} |
| 104 |
|
|
| 105 |
|
return Stub::create('/migration/plain.stub', [ |
| 106 |
|
'class' => $this->getClass(), |