clean up api routes

This commit is contained in:
omair saleh
2020-12-07 10:44:35 +08:00
parent 2e4b5923e6
commit 5b7148d879
7 changed files with 40 additions and 19 deletions
@@ -20,7 +20,7 @@ class CreateCurrenciesTable extends Migration
$table->string('name')->nullable();
$table->string('short_code')->nullable();
$table->string('symbol')->nullable();
$table->float('selling', 20, 5)->nullable();
$table->decimal('selling', 20, 5)->nullable();
$table->timestamps();
$table->softDeletes();
});
@@ -17,7 +17,7 @@ class CreateCurrencyLogsTable extends Migration
$table->id();
$table->bigInteger('currency_id')->unsigned()->nullable();
$table->foreign('currency_id')->references('id')->on('currencies')->onDelete('cascade');
$table->float('selling', 20, 5)->nullable();
$table->decimal('selling', 20, 5)->nullable();
$table->bigInteger('created_by')->unsigned()->nullable();
$table->foreign('created_by')->references('id')->on('users')->onDelete('cascade');
$table->timestamps();
@@ -19,7 +19,7 @@ class CreateCompaniesWalletTable extends Migration
$table->bigInteger('company_id')->unsigned();
$table->string('code');
$table->bigInteger('currency_id')->unsigned();
$table->decimal('amount', 14, 5)->default(0.00);
$table->decimal('amount', 20, 5)->default(0.00);
$table->timestamps();
$table->foreign('company_id')->references('id')->on('companies')->onDelete('cascade');