mirror of
				https://github.com/invoiceninja/invoiceninja.git
				synced 2025-10-31 15:57:33 -04:00 
			
		
		
		
	Added migration for payment types
This commit is contained in:
		
							parent
							
								
									8bb302b6f5
								
							
						
					
					
						commit
						f6e409cd40
					
				| @ -0,0 +1,52 @@ | ||||
| <?php | ||||
| 
 | ||||
| use App\Models\GatewayType; | ||||
| use App\Models\PaymentType; | ||||
| use Illuminate\Database\Migrations\Migration; | ||||
| use Illuminate\Database\Schema\Blueprint; | ||||
| use Illuminate\Support\Facades\Schema; | ||||
| 
 | ||||
| class AddIdealToPaymentTypes extends Migration | ||||
| { | ||||
|     /** | ||||
|      * Run the migrations. | ||||
|      * | ||||
|      * @return void | ||||
|      */ | ||||
|     public function up() | ||||
|     { | ||||
|         Schema::table('payment_types', function (Blueprint $table) { | ||||
|             $type = new PaymentType(); | ||||
|             $type2 = new PaymentType(); | ||||
|             $type3 = new PaymentType(); | ||||
|             $type4 = new PaymentType(); | ||||
|             $type5 = new PaymentType(); | ||||
| 
 | ||||
|             $type->id = 44; | ||||
|             $type->name = 'ACSS'; | ||||
|             $type->gateway_type_id = GatewayType::ACSS; | ||||
| 
 | ||||
|             $type2->id = 43; | ||||
|             $type2->name = 'BECS'; | ||||
|             $type2->gateway_type_id = GatewayType::BECS; | ||||
| 
 | ||||
|             $type3->id = 39; | ||||
|             $type3->name = 'GiroPay'; | ||||
|             $type3->gateway_type_id = GatewayType::GIROPAY; | ||||
| 
 | ||||
|             $type4->id = 40; | ||||
|             $type4->name = 'Przelewy24'; | ||||
|             $type4->gateway_type_id = GatewayType::PRZELEWY24; | ||||
| 
 | ||||
|             $type5->id = 41; | ||||
|             $type5->name = 'EPS'; | ||||
|             $type5->gateway_type_id = GatewayType::EPS; | ||||
| 
 | ||||
|             $type->save(); | ||||
|             $type2->save(); | ||||
|             $type3->save(); | ||||
|             $type4->save(); | ||||
|             $type5->save(); | ||||
|         }); | ||||
|     } | ||||
| } | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user