/var/www/vhosts/ihelp.ro/_OLD/vendor/robmorgan/phinx/src/Phinx/Db/Action
NameSizeModeActions
Action.php6790644editdlrm
AddColumn.php15400644editdlrm
AddForeignKey.php22700644editdlrm
AddIndex.php17560644editdlrm
ChangeColumn.php22270644editdlrm
ChangeComment.php8460644editdlrm
ChangePrimaryKey.php8940644editdlrm
CreateTable.php2020644editdlrm
DropForeignKey.php17560644editdlrm
DropIndex.php17790644editdlrm
DropTable.php2000644editdlrm
RemoveColumn.php13630644editdlrm
RenameColumn.php18120644editdlrm
RenameTable.php7980644editdlrm
Edit: /var/www/vhosts/ihelp.ro/_OLD/vendor/robmorgan/phinx/src/Phinx/Db/Action/AddForeignKey.php (2270B)
foreignKey = $fk; } /** * Creates a new AddForeignKey object after building the foreign key with * the passed attributes * * @param \Phinx\Db\Table\Table $table The table object to add the foreign key to * @param string|string[] $columns The columns for the foreign key * @param \Phinx\Db\Table\Table|string $referencedTable The table the foreign key references * @param string|string[] $referencedColumns The columns in the referenced table * @param array $options Extra options for the foreign key * @param string|null $name The name of the foreign key * * @return \Phinx\Db\Action\AddForeignKey */ public static function build(Table $table, $columns, $referencedTable, $referencedColumns = ['id'], array $options = [], $name = null) { if (is_string($referencedColumns)) { $referencedColumns = [$referencedColumns]; // str to array } if (is_string($referencedTable)) { $referencedTable = new Table($referencedTable); } $fk = new ForeignKey(); $fk->setReferencedTable($referencedTable) ->setColumns($columns) ->setReferencedColumns($referencedColumns) ->setOptions($options); if ($name !== null) { $fk->setConstraint($name); } return new static($table, $fk); } /** * Returns the foreign key to be added * * @return \Phinx\Db\Table\ForeignKey */ public function getForeignKey() { return $this->foreignKey; } }