Closed TiagoSilvaPereira closed 4 months ago
Sorry, I have the same issue. Is there any solution or tip to avoid it? Thanks!
Hi, me again I solve it coding the following in DatabaseForeignKey.php:38
$this->name = $foreignKey['name'] ?? $table . '_fk';
Please, anyone who could let comment if it is correct or not
Hi, me again I solve it coding the following in DatabaseForeignKey.php:38
$this->name = $foreignKey['name'] ?? $table . '_fk';
Please, anyone who could let comment if it is correct or not
I think this solution will not work correctly because it will produce the same index name for all foreign keys.
Yes, I forgot not to use the same names, just in case to have an approach of a possible solution
Sorry for late and thanks for the details.
The SQLite foreign key name is null, I have fixed this issue in v7.0.2
Sorry for late and thanks for the details.
The SQLite foreign key name is null, I have fixed this issue in
v7.0.2
Thank you very much, @kitloong. You rock!! Also, could you please add a monthly sponsorship option to support this project? It seems buy me a coffee is not working in my country
Hi @TiagoSilvaPereira , huge thank you for your kind words and support.
I'm excited to share that I have added a sponsor option through Github Sponsor at https://github.com/sponsors/kitloong.
There is absolutely no pressure to do so, your support in any form, be it through contributions, feedback, or even spreading the word, is invaluable.
@kitloong Thank you. Github Sponsors worked well. I'm using your package inside Vemto 2, an application for Laravel developers currently in Alpha. May I also offer you a Lifetime license as a thank you? Vemto currently has a lot of bugs, haha, but I'm sure you will find it useful
Thank you so much for your kind offer.
I'm glad to hear that my package could be part of Vemto 2. I'd be delighted to accept the license and am excited to explore how Vemto evolves.
Bugs are just part of the journey in software development 😎
I appreciate your generosity.
Awesome @kitloong , I'll send you an email from contact@vemto.app. Best regards!
Describe the bug I created a new Laravel 11 project with Jetstream + Teams, migrated the database to sqlite, then tried to run the package on this to recreate the migrations. By tying that, it fires the following exception:
Stack:
Terminal printscreen:
To Reproduce Steps to reproduce the behavior:
php artisan migrate:generate ...
Expected behavior The expected behavior is to generate the migrations without firing this exception
Details (please complete the following information):
Seems the problem happens in the following line of KitLoong\MigrationsGenerator\Database\Models\DatabaseForeignKey:
This is the data passed to the class constructor: