Skip to content
New issue

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

Not Working with Old database enum values #197

Open
rsyscraft opened this issue Dec 5, 2019 · 1 comment
Open

Not Working with Old database enum values #197

rsyscraft opened this issue Dec 5, 2019 · 1 comment

Comments

@rsyscraft
Copy link

When I have generate migration from old db the migration is created successfully but the probem is it is convert enum value as string see below -

integer('id', true); $table->string('order_code'); $table->integer('user_id'); #Check status field not coming with enum values $table->string('status')->default('PENDING'); $table->string('cancelled_by'); $table->string('cancel_reason')->nullable(); $table->string('payment_mode'); $table->decimal('sub_total')->default(0.00); $table->decimal('tax')->default(0.00); $table->decimal('delivery_charge')->default(0.00); $table->decimal('discount_amt')->default(0.00); $table->decimal('total_amount', 10)->default(0.00); $table->decimal('merchant_pay', 10)->default(0.00); $table->decimal('comission', 10)->default(0.00)->comment('bikemango comission'); $table->string('payment_status')->default('PENDING'); $table->string('payment_id')->nullable(); $table->integer('discount_id')->default(0); $table->text('delivery_note', 65535)->nullable(); $table->text('order_title', 65535)->nullable(); $table->dateTime('schedule_at')->nullable(); $table->timestamps(); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::drop('fdl_orders'); } }
@abdulrehman25
Copy link

abdulrehman25 commented Feb 17, 2023

@rsyscraft here is fix for it [https://github.com//pull/209]
@Xethron if you can merge this PR then it will solve a lot of people's issue.
Thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants