From 2daea2c10a3e7a83b3c4c6c2753fa30599a0f28b Mon Sep 17 00:00:00 2001 From: chris Date: Tue, 26 Nov 2024 08:03:05 +0100 Subject: [PATCH] Create migration and model for taxrates. --- app/Models/Taxrate.php | 11 +++++++ ...024_11_26_063625_create_taxrates_table.php | 33 +++++++++++++++++++ 2 files changed, 44 insertions(+) create mode 100644 app/Models/Taxrate.php create mode 100644 database/migrations/2024_11_26_063625_create_taxrates_table.php diff --git a/app/Models/Taxrate.php b/app/Models/Taxrate.php new file mode 100644 index 0000000..68ef24c --- /dev/null +++ b/app/Models/Taxrate.php @@ -0,0 +1,11 @@ +id(); + + $table->string('name'); + $table->decimal('rate', 8, 2)->default(0); + $table->boolean('active')->default(false); + + $table->timestamps(); + $table->softDeletes(); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + Schema::dropIfExists('taxrates'); + } +};