Ngiler SH3LL 360
Home
Information
Create File
Create Folder
:
/
home
/
tbf
/
cursbackend
/
database
/
seeds
/
Information Server
MySQL :
OFF
Perl :
OFF
CURL :
ON
WGET :
OFF
PKEXEC :
OFF
Directive
Local Value
IP Address
89.40.16.97
System
Linux server.atelieruldeit.ro 3.10.0-1160.el7.x86_64 #1 SMP Mon Oct 19 16:18:59 UTC 2020 x86_64
User
tbf
PHP Version
7.3.33
Software
Apache
Doc root
Writable
close
Edit File :
PackageSeeder.php
| Size :
3.11
KB
Copy
<?php use Illuminate\Database\Seeder; use App\Models\Package; use App\Models\Voucher; use Illuminate\Support\Arr; class PackageSeeder extends Seeder { /** * Run the database seeds. * * @return void */ public function run() { $packages = [ [ 'id' => 1, 'name' => 'Startup', 'short_description' => "Pachet destinat companiilor care au maxim 6 angajati si vor sa setez maxim 10 obiective.", 'token' => '33e71c8436036b299a0dabfb55a28058', 'user_limit' => 6, 'objective_limit' => 10, 'results_limit' => 0, 'euro_plan_id' => 'price_1HItrVAxm7VV9cXuzJmXOCPT', 'price_in_euro' => '199', 'ron_plan_id' => 'price_1HItplAxm7VV9cXufoy5Z7BU', 'price_in_ron' => '963', 'interval' => 'month', 'interval_numbers' => 1, 'euro_prefix' => "EUR", 'ron_prefix' => "RON" ], [ 'id' => 2, 'name' => 'Professional', 'short_description' => "Pachet destinat companiilor care au maxim 100 angajati", 'token' => '33e71c8436036b299a0dabfb534a28058', 'user_limit' => 0, 'objective_limit' => 0, 'results_limit' => 0, 'euro_plan_id' => 'price_1HIttcAxm7VV9cXuqR916Z0c', 'price_in_euro' => '499', 'ron_plan_id' => 'price_1HItszAxm7VV9cXuSJNxybKL', 'price_in_ron' => '2415' , 'interval' => 'month', 'interval_numbers' => 1, 'euro_prefix' => "EUR", 'ron_prefix' => "RON" ], [ 'id' => 3, 'name' => 'Free', 'short_description' => "Pachet gratis", 'token' => '33e71c8436036b299a0dabfb534a28x58', 'user_limit' => 0, 'objective_limit' => 0, 'results_limit' => 0, 'euro_plan_id' => 'price_1HItv7Axm7VV9cXuBKMhPWaU', 'price_in_euro' => '0', 'ron_plan_id' => 'price_1HItukAxm7VV9cXucAJXK6Fr', 'price_in_ron' => '0' , 'interval' => 'month', 'interval_numbers' => 1, 'euro_prefix' => "EUR", 'ron_prefix' => "RON", 'display_for_subscription' => false ] ]; foreach($packages as $item){ Package::updateOrCreate( [ 'id' => $item['id'] ], Arr::except($item, ['id']) ); } Voucher::updateOrCreate( [ 'id' => 1 ], [ 'name' => 'WEBINAR100', 'stripe_dc_id_sr' => 'Sv7wtqVl', 'stripe_dc_id_se' => 'bXjoTJs8', 'stripe_dc_id_pr' => 'eDMVDO5f', 'stripe_dc_id_pe' => '9WzbHbFz' ] ); } }
Back