Seeders for new currencieS

This commit is contained in:
David Bomba 2023-08-09 08:59:32 +10:00
parent 4c1f53804e
commit 9765b5eb4d

View File

@ -16,6 +16,37 @@ return new class extends Migration
Schema::table('purchase_order_invitations', function (Blueprint $table) {
$table->text('signature_ip')->nullable();
});
$xag = \App\Models\Currency::find(116);
if(!$xag) {
$xag = new \App\Models\Currency();
$xag->id = 115;
$xag->code = 'XAG';
$xag->name = 'Silver Troy Ounce';
$xag->symbol = 'XAG';
$xag->thousand_separator = ',';
$xag->decimal_separator = '.';
$xag->precision = 2;
$xag->save();
}
$xau = \App\Models\Currency::find(117);
if(!$xau) {
$xau = new \App\Models\Currency();
$xau->id = 117;
$xau->code = 'XAU';
$xau->name = 'Gold Troy Ounce';
$xau->symbol = 'XAU';
$xau->thousand_separator = ',';
$xau->decimal_separator = '.';
$xau->precision = 3;
$xau->save();
}
}
/**