| @@ 508-517 (lines=10) @@ | ||
| 505 | || $action instanceof ChangePrimaryKey |
|
| 506 | || $action instanceof ChangeComment; |
|
| 507 | }) |
|
| 508 | ->each(function ($action) { |
|
| 509 | $table = $action->getTable(); |
|
| 510 | $name = $table->getName(); |
|
| 511 | ||
| 512 | if (!isset($this->tableMoves[$name])) { |
|
| 513 | $this->tableMoves[$name] = new AlterTable($table); |
|
| 514 | } |
|
| 515 | ||
| 516 | $this->tableMoves[$name]->addAction($action); |
|
| 517 | }); |
|
| 518 | } |
|
| 519 | ||
| 520 | /** |
|
| @@ 538-547 (lines=10) @@ | ||
| 535 | // so we don't wan't them here too |
|
| 536 | return isset($this->tableCreates[$action->getTable()->getName()]); |
|
| 537 | }) |
|
| 538 | ->each(function ($action) { |
|
| 539 | $table = $action->getTable(); |
|
| 540 | $name = $table->getName(); |
|
| 541 | ||
| 542 | if (!isset($this->indexes[$name])) { |
|
| 543 | $this->indexes[$name] = new AlterTable($table); |
|
| 544 | } |
|
| 545 | ||
| 546 | $this->indexes[$name]->addAction($action); |
|
| 547 | }); |
|
| 548 | } |
|
| 549 | ||
| 550 | /** |
|
| @@ 563-572 (lines=10) @@ | ||
| 560 | return $action instanceof AddForeignKey |
|
| 561 | || $action instanceof DropForeignKey; |
|
| 562 | }) |
|
| 563 | ->each(function ($action) { |
|
| 564 | $table = $action->getTable(); |
|
| 565 | $name = $table->getName(); |
|
| 566 | ||
| 567 | if (!isset($this->constraints[$name])) { |
|
| 568 | $this->constraints[$name] = new AlterTable($table); |
|
| 569 | } |
|
| 570 | ||
| 571 | $this->constraints[$name]->addAction($action); |
|
| 572 | }); |
|
| 573 | } |
|
| 574 | } |
|
| 575 | ||