当前位置: 首页>>代码示例>>PHP>>正文


PHP Schema::create方法代码示例

本文整理汇总了PHP中Schema::create方法的典型用法代码示例。如果您正苦于以下问题:PHP Schema::create方法的具体用法?PHP Schema::create怎么用?PHP Schema::create使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Schema的用法示例。


在下文中一共展示了Schema::create方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('information', function (Blueprint $table) {
         $table->increments('id');
         //ID
         $table->string('name');
         //İSİM
         $table->string('slug');
         //SLUG
         $table->text('content');
         //AÇIKLAMA
         $table->integer('tabs_id');
         //KATEGORİ ID
         $table->integer('sort_order');
         //SIRA
         $table->integer('status');
         //DURUMU
         $table->integer('viewed');
         //GORUNTULENME SAYISI
         $table->text('meta_title');
         //META BAŞLIK
         $table->text('meta_description');
         //META AÇIKLAMA
         $table->text('meta_keywords');
         //META A.KELİMELER
         $table->softDeletes();
         $table->timestamps();
     });
 }
开发者ID:ercancavusoglu,项目名称:laravel-ecommerce,代码行数:34,代码来源:2016_01_05_224454_create_information_table.php

示例2: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('users', function (Blueprint $table) {
         $table->increments('id');
         $table->string('name');
         $table->string('email')->unique();
         $table->string('header');
         $table->string('intro');
         $table->string('password');
         $table->integer('sex');
         $table->string('profession');
         $table->string('birthday');
         $table->string('skill_tags');
         $table->string('tool_tags');
         $table->string('city');
         $table->string('tel');
         $table->string('education');
         $table->string('workexps');
         $table->string('works');
         $table->string('job');
         $table->string('website');
         $table->integer('score');
         $table->rememberToken();
         $table->timestamps();
     });
 }
开发者ID:Panfen,项目名称:mango,代码行数:31,代码来源:2014_10_12_000000_create_users_table.php

示例3: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('corporation_killmail_detail', function (Blueprint $table) {
         $table->increments('id');
         $table->integer('killID');
         $table->integer('solarSystemID');
         $table->dateTime('killTime');
         $table->integer('moonID');
         // Victim Information
         $table->integer('characterID');
         $table->string('characterName');
         $table->integer('corporationID');
         $table->string('corporationName');
         $table->integer('allianceID')->nullable();
         $table->string('allianceName')->nullable();
         $table->integer('factionID')->nullable();
         $table->string('factionName')->nullable();
         $table->integer('damageTaken');
         $table->integer('shipTypeID');
         // Indexes
         $table->index('killID');
         $table->index('characterID');
         $table->timestamps();
     });
 }
开发者ID:boweiliu,项目名称:seat,代码行数:30,代码来源:2014_12_05_062934_CreateEveCorporationKillMailDetail.php

示例4: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('fields', function (Blueprint $table) {
         $table->increments('id');
         $table->timestamps();
     });
 }
开发者ID:JJacobi13,项目名称:jcAiBattle,代码行数:12,代码来源:2015_10_06_181923_create_fields_table.php

示例5: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('position', function (Blueprint $table) {
         $table->increments('position_id');
         $table->string('postion_name');
     });
 }
开发者ID:AlbertLabarento,项目名称:BRAMS-Project,代码行数:12,代码来源:2015_10_14_053843_create_position_table.php

示例6: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('user_zone', function ($table) {
         $table->string('user_id');
         $table->integer('zone_id');
     });
 }
开发者ID:atefth,项目名称:remote_access_system,代码行数:12,代码来源:2014_09_18_114007_create_user_zone_table.php

示例7: up

 public function up()
 {
     Schema::create('steam_games', function (Blueprint $table) {
         $table->integer('id')->primary()->unsigned();
         $table->string('name')->nullable();
         $table->integer('playtime_forever')->default('0');
         $table->integer('playtime_2weeks')->default('0');
         $table->boolean('has_community_visible_stats')->default(0);
         $table->string('image_icon_url')->nullable();
         $table->string('image_logo_url')->nullable();
         $table->string('Image_background')->nullable();
         $table->string('image_header')->nullable();
         $table->boolean('is_free')->default(0);
         $table->string('about_the_game')->nullable();
         $table->string('legal_notice')->nullable();
         $table->string('website')->nullable();
         $table->integer('meta_critic_score')->default('0');
         $table->string('meta_critic_url')->nullable();
         $table->string('screenshot_path_thumbnail')->nullable();
         $table->string('screenshot_path_full')->nullable();
         $table->string('movie_thumbnail')->nullable();
         $table->string('movie_full_url')->nullable();
         $table->string('movie_name')->nullable();
         $table->timestamp('schema_updated_at')->nullable();
         $table->timestamp('player_stats_updated_at')->nullable();
         $table->timestamp('game_updated_at')->nullable();
         $table->timestamp('description_updated_at')->nullable();
         $table->timestamps();
     });
 }
开发者ID:Bogstag,项目名称:bogstag.se,代码行数:30,代码来源:2016_02_20_000113_create_steam_games_table.php

示例8: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('layers', function (Blueprint $table) {
         $table->increments('id');
         $table->integer('order')->default(100);
         $table->string('name');
         $table->integer('map_id')->unsigned();
         $table->integer('source_id')->unsigned();
         $table->integer('minzoom')->default(1);
         $table->integer('maxzoom')->default(22);
         $table->boolean('interactive')->default(false);
         $table->string('type');
         $table->boolean('visible')->default(true);
         $table->integer('opacity')->default(10);
         $table->string('color');
         $table->string('outline-color');
         $table->integer('width');
         $table->integer('gap-width');
         $table->string('dasharray');
         $table->integer('radius');
         $table->integer('blur');
         $table->string('choropleth-source');
         $table->integer('clusters');
         $table->string('schema-color');
         $table->boolean('schema-reverse')->default(false);
         $table->integer('cluster-maxzoom')->default(15);
         $table->integer('cluster-radius')->default(20);
         $table->timestamps();
         $table->foreign('map_id')->references('id')->on('maps')->onDelete('cascade');
         $table->foreign('source_id')->references('id')->on('sources')->onDelete('cascade');
     });
 }
开发者ID:jaumesala,项目名称:opendata-maps,代码行数:37,代码来源:2016_03_27_183122_create_layers_table.php

示例9: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('txn_sales_order_deal', function (Blueprint $table) {
         $table->integer('so_detail_deal_id');
         $table->string('reference_num', 50)->index();
         $table->string('deal_code', 90)->index();
         $table->string('deal_description', 100)->index();
         $table->string('item_code', 20)->index();
         $table->string('uom_code', 20)->index();
         $table->integer('deal_order_qty');
         $table->integer('deal_served_qty');
         $table->integer('regular_order_qty');
         $table->integer('regular_served_qty');
         $table->string('trade_item_code', 20)->index();
         $table->string('trade_item_uom', 20)->index();
         $table->integer('trade_order_qty');
         $table->integer('trade_served_qty');
         $table->decimal('vat_order_amount');
         $table->decimal('vat_served_amount');
         $table->decimal('gross_order_amount');
         $table->decimal('gross_served_amount');
         $table->string('remarks', 160)->nullable();
         $table->string('status', 2);
         $table->string('modified_by', 50)->index();
         $table->dateTime('modified_date')->nullable();
         $table->dateTime('sfa_modified_date')->nullable();
         $table->dateTime('updated_at')->nullable();
         $table->integer('updated_by')->index()->default('0');
         $table->primary('so_detail_deal_id');
     });
 }
开发者ID:atudz,项目名称:SFAReport,代码行数:36,代码来源:2015_11_23_152432_txn_sales_order_deal.php

示例10: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('unit_types', function (Blueprint $table) {
         $table->increments('id');
         $table->integer('project_id')->unsigned();
         $table->string('name');
         $table->integer('building_area');
         $table->integer('land_area');
         $table->bigInteger('base_price');
         $table->bigInteger('added_facility_price');
         $table->bigInteger('added_area_price');
         $table->string('front_picture');
         $table->string('left_picture');
         $table->string('right_picture');
         $table->string('top_picture');
         $table->string('back_picture');
         $table->string('brochure_picture');
         //$table->integer('user_id')->unsigned();
         $table->integer('created_by');
         $table->integer('changed_by');
         $table->string('change_reason');
         $table->softDeletes();
         $table->timestamps();
     });
 }
开发者ID:syafdia,项目名称:PAS,代码行数:30,代码来源:2015_07_18_080042_create_unit_types_table.php

示例11: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('contact_user', function (Blueprint $table) {
         $table->bigInteger('user_id');
         $table->bigInteger('contact_id');
     });
 }
开发者ID:SenhorBardell,项目名称:yol,代码行数:12,代码来源:2015_05_28_120239_add_contacts_table.php

示例12: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('users', function (Blueprint $table) {
         $table->increments('id');
         $table->string('firstName')->nullable();
         $table->string('lastName')->nullable();
         $table->string('username');
         $table->string('cne')->unique()->nullable();
         $table->string('cin')->unique()->nullable();
         $table->string('email')->unique();
         $table->string('level')->nullable();
         $table->string('about')->nullable();
         $table->string('photo')->default('noavatar.jpg');
         $table->string('gender')->nullable();
         $table->date('birthdate')->nullable();
         $table->string('notify_email')->default(0);
         $table->string('role');
         $table->string('facebook')->nullable();
         $table->string('linkedin')->nullable();
         $table->string('twitter')->nullable();
         $table->string('password', 60);
         $table->string('confirmation_code')->nullable();
         $table->string('confirmed')->default(0);
         $table->rememberToken();
         $table->timestamps();
     });
 }
开发者ID:otsaan,项目名称:e-blog,代码行数:32,代码来源:2014_10_12_000000_create_users_table.php

示例13: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('enfermetats', function (Blueprint $table) {
         $table->increments('id');
         //id usuari
         $table->string('nom')->unique();
         //nom de l'especie
         $table->boolean('cientific');
         //indica si el nom que te es cientific o no
         $table->string('simptomes');
         //simptomes de l'enfermetat
         $table->string('descripcio');
         //descripcio de l'enfermetat
         $table->json('imatges');
         //imatges de l'enfermetat
         $table->date('enfermetat_inici');
         //inici epcoca enfermetat
         $table->date('enfermetat_fi');
         //fi epoca enfermetat
         $table->boolean('ministeri');
         //censat pel ministeri
         $table->integer('patogen_id')->unsigned();
         //classe d'agent patogen que crea l'enfermetat
         $table->foreign('patogen_id')->references('id')->on('patogens');
         $table->timestamps();
     });
 }
开发者ID:vi1004t,项目名称:pfg,代码行数:32,代码来源:2015_07_04_162031_create_enfermetats_table.php

示例14: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('marriages', function (Blueprint $table) {
         $table->bigIncrements('id');
         $table->integer('parish_id')->index()->unsigned();
         $table->foreign('parish_id')->references('id')->on('parishes')->onDelete('cascade')->onUpdate('cascade');
         $table->date('date_of_marriage');
         $table->string('name_of_bride', 64);
         $table->string('status_of_bride', 16)->nullable();
         $table->string('age_of_bride', 4)->nullable();
         $table->string('origin_of_bride', 64)->nullable();
         $table->string('residence_of_bride', 128)->nullable();
         $table->string('father_of_bride', 64)->nullable();
         $table->string('mother_of_bride', 64)->nullable();
         $table->string('name_of_groom', 64);
         $table->string('status_of_groom', 16)->nullable();
         $table->string('age_of_groom', 4)->nullable();
         $table->string('origin_of_groom', 64)->nullable();
         $table->string('residence_of_groom', 128)->nullable();
         $table->string('father_of_groom', 64)->nullable();
         $table->string('mother_of_groom', 64)->nullable();
         $table->string('minister', 64);
         $table->string('witnesses', 256)->nullable();
         $table->string('remarks', 256)->nullable();
         $table->string('book_no', 4);
         $table->string('page_no', 4);
         $table->string('line_no', 4);
         $table->string('document', 128)->nullable();
         $table->timestamps();
     });
 }
开发者ID:rdrubis,项目名称:books-of-register,代码行数:36,代码来源:2014_10_15_052422_create_marriages_table.php

示例15: up

 /**
  * Run the migrations.
  *
  * @return void
  */
 public function up()
 {
     Schema::create('qualification_training_ojt', function ($table) {
         //Training/Workshop
         $table->increments('id');
         $table->integer('emp_id');
         $table->string('category');
         //training
         $table->string('type_of_training');
         $table->string('training_course');
         $table->string('subject');
         //ojt
         $table->string('training_task');
         //workshop
         $table->string('topic');
         $table->string('major_area');
         $table->string('instructor');
         $table->string('institute');
         $table->string('location');
         $table->string('proof');
         $table->string('pdf');
         $table->string('certification');
         $table->string('duration');
         $table->string('verify', 10);
         $table->timestamps();
     });
 }
开发者ID:strangerAshik,项目名称:AIMS,代码行数:32,代码来源:2015_02_11_193321_qualification_training_ojt.php


注:本文中的Schema::create方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。