mirror of
				https://github.com/cp6/my-idlers.git
				synced 2025-11-04 08:09:09 +00:00 
			
		
		
		
	
		
			
	
	
		
			26 lines
		
	
	
	
		
			636 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
		
		
			
		
	
	
			26 lines
		
	
	
	
		
			636 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
| 
								 | 
							
								<?php
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								use Illuminate\Database\Migrations\Migration;
							 | 
						||
| 
								 | 
							
								use Illuminate\Database\Schema\Blueprint;
							 | 
						||
| 
								 | 
							
								use Illuminate\Support\Facades\Schema;
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								class CreateIPsTable extends Migration
							 | 
						||
| 
								 | 
							
								{
							 | 
						||
| 
								 | 
							
								    public function up()
							 | 
						||
| 
								 | 
							
								    {
							 | 
						||
| 
								 | 
							
								        Schema::create('ips', function (Blueprint $table) {
							 | 
						||
| 
								 | 
							
								            $table->char('id', 8)->unique();
							 | 
						||
| 
								 | 
							
								            $table->char('service_id', 8);
							 | 
						||
| 
								 | 
							
								            $table->string('address');
							 | 
						||
| 
								 | 
							
								            $table->tinyInteger('is_ipv4')->default(1);
							 | 
						||
| 
								 | 
							
								            $table->tinyInteger('active')->default(1);
							 | 
						||
| 
								 | 
							
								            $table->timestamps();
							 | 
						||
| 
								 | 
							
								        });
							 | 
						||
| 
								 | 
							
								    }
							 | 
						||
| 
								 | 
							
								
							 | 
						||
| 
								 | 
							
								    public function down()
							 | 
						||
| 
								 | 
							
								    {
							 | 
						||
| 
								 | 
							
								        Schema::dropIfExists('ips');
							 | 
						||
| 
								 | 
							
								    }
							 | 
						||
| 
								 | 
							
								}
							 |