We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I've detected some strange logic on generating index for HasOne relation. I have 2 entities:
class Item extends AbstractEntity { /** * @Cycle\Relation\HasOne( * target="ItemInfo ", * outerKey="item_id", * fkAction="CASCADE" * ) */ public ItemInfo $info; ... }
class ItemInfo extends AbstractEntity { /** * @Cycle\Relation\BelongsTo( * target="Item", * innerKey="item_id", * fkAction="CASCADE" * ) */ public Item $item; ... }
I am expecting from generated migration that index will be unique but the command prepares next description:
public function up() { $this->table('item_info') ... ->addIndex(["item_id"], [ 'name' => 'item_info_index_item_id_5e8d9e2681e26', 'unique' => false ]) ->addForeignKey(["item_id"], 'item', ["id"], [ 'name' => 'item_info_foreign_item_id_5e8d9e2681e33', 'delete' => 'CASCADE', 'update' => 'CASCADE' ]) ... ->create(); }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I've detected some strange logic on generating index for HasOne relation.
I have 2 entities:
I am expecting from generated migration that index will be unique but the command prepares next description:
The text was updated successfully, but these errors were encountered: