2018_07_31_073223_create_businesses_table.php 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <?php
  2. use Illuminate\Support\Facades\Schema;
  3. use Illuminate\Database\Schema\Blueprint;
  4. use Illuminate\Database\Migrations\Migration;
  5. class CreateBusinessesTable extends Migration
  6. {
  7. /**
  8. * Run the migrations.
  9. *
  10. * @return void
  11. */
  12. public function up()
  13. {
  14. Schema::create('businesses', function (Blueprint $table) {
  15. $table->increments('id');
  16. $table->integer('number')->comment('编号');
  17. $table->string('name')->comment('名称');
  18. $table->string('address')->comment('位置');
  19. $table->string('poi_name')->comment('POI名称');
  20. $table->string('poi_icon')->comment('POI图标');
  21. $table->string('poi_link_url')->comment('POI跳转链接');
  22. $table->string('poi_x_coord')->comment('POIY坐标');
  23. $table->string('poi_y_coord')->comment('POIX坐标');
  24. $table->time('star_time')->comment('开始时间');
  25. $table->time('end_time')->comment('结束时间');
  26. $table->float('price')->comment('人均价位');
  27. $table->text('shop_intro',280)->comment('商家简介');
  28. $table->text('shop_info',280)->comment('商家描述');
  29. $table->json('food_type')->comment('商家风格');
  30. $table->json('serve_facility')->comment('服务设施');
  31. $table->integer('hot_status')->comment('加入热点');
  32. $table->integer('hot_id')->comment('热点ID')->nullable();
  33. $table->integer('self_support')->comment('是否自营');
  34. $table->integer('business_status')->comment('营业状态');
  35. $table->json('pics')->comment('宣传照片');
  36. $table->integer('create_id')->comment('创建者ID');
  37. $table->integer('update_id')->comment('更新者ID');
  38. $table->timestamps();
  39. });
  40. }
  41. /**
  42. * Reverse the migrations.
  43. *
  44. * @return void
  45. */
  46. public function down()
  47. {
  48. Schema::dropIfExists('businesses');
  49. }
  50. }