admin 7 лет назад
Родитель
Сommit
3de7cc28ae
38 измененных файлов с 0 добавлено и 1618 удалено
  1. 0 42
      database/migrations/2017_12_29_134159_create_article_table.php
  2. 0 36
      database/migrations/2017_12_29_135722_create_config_table.php
  3. 0 36
      database/migrations/2017_12_29_135738_create_country_table.php
  4. 0 47
      database/migrations/2017_12_29_135751_create_coupon_table.php
  5. 0 39
      database/migrations/2017_12_29_135804_create_coupon_log_table.php
  6. 0 40
      database/migrations/2017_12_29_135816_create_email_log_table.php
  7. 0 47
      database/migrations/2017_12_29_135828_create_goods_table.php
  8. 0 41
      database/migrations/2017_12_29_135839_create_invite_table.php
  9. 0 38
      database/migrations/2017_12_29_135850_create_level_table.php
  10. 0 46
      database/migrations/2017_12_29_135900_create_order_table.php
  11. 0 44
      database/migrations/2017_12_29_135915_create_order_goods_table.php
  12. 0 42
      database/migrations/2017_12_29_135948_create_referral_apply_table.php
  13. 0 42
      database/migrations/2017_12_29_140008_create_referral_log_table.php
  14. 0 38
      database/migrations/2017_12_29_140026_create_ss_config_table.php
  15. 0 38
      database/migrations/2017_12_29_140038_create_ss_group_table.php
  16. 0 36
      database/migrations/2017_12_29_140049_create_ss_group_node_table.php
  17. 0 63
      database/migrations/2017_12_29_140101_create_ss_node_table.php
  18. 0 40
      database/migrations/2017_12_29_140111_create_ss_node_info_table.php
  19. 0 39
      database/migrations/2017_12_29_140125_create_ss_node_online_log_table.php
  20. 0 43
      database/migrations/2017_12_29_140140_create_ss_node_traffic_daily_table.php
  21. 0 43
      database/migrations/2017_12_29_140153_create_ss_node_traffic_hourly_table.php
  22. 0 39
      database/migrations/2017_12_29_140205_create_ticket_table.php
  23. 0 38
      database/migrations/2017_12_29_140216_create_ticket_reply_table.php
  24. 0 71
      database/migrations/2017_12_29_140229_create_user_table.php
  25. 0 43
      database/migrations/2017_12_29_140239_create_user_balance_log_table.php
  26. 0 42
      database/migrations/2017_12_29_140253_create_user_ban_log_table.php
  27. 0 42
      database/migrations/2017_12_29_140304_create_user_score_log_table.php
  28. 0 42
      database/migrations/2017_12_29_140319_create_user_subscribe_table.php
  29. 0 38
      database/migrations/2017_12_29_140330_create_user_subscribe_log_table.php
  30. 0 46
      database/migrations/2017_12_29_140345_create_user_traffic_daily_table.php
  31. 0 46
      database/migrations/2017_12_29_140357_create_user_traffic_hourly_table.php
  32. 0 45
      database/migrations/2017_12_29_140409_create_user_traffic_log_table.php
  33. 0 40
      database/migrations/2017_12_29_140422_create_verify_table.php
  34. 0 39
      database/migrations/2018_05_24_113606_create_goods_label_table.php
  35. 0 47
      database/migrations/2018_05_24_113645_create_payment_table.php
  36. 0 48
      database/migrations/2018_05_24_113657_create_payment_callback_table.php
  37. 0 36
      database/migrations/2018_05_24_113825_create_label_table.php
  38. 0 36
      database/migrations/2018_05_24_113851_create_user_label_table.php

+ 0 - 42
database/migrations/2017_12_29_134159_create_article_table.php

@@ -1,42 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateArticleTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('article', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('title', 100)->default('')->comment('标题');
-            $table->string('author', 50)->default('')->comment('作者');
-            $table->text('content')->nullable()->comment('内容');
-            $table->tinyInteger('type')->default('1')->comment('类型:1-文章、2-公告');
-            $table->tinyInteger('is_del')->default('0')->comment('是否删除');
-            $table->integer('sort')->default('0')->comment('排序');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('article');
-    }
-}

+ 0 - 36
database/migrations/2017_12_29_135722_create_config_table.php

@@ -1,36 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateConfigTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('config', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('name', 255)->default('')->comment('配置名');
-            $table->text('value')->nullable()->comment('配置值');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('config');
-    }
-}

+ 0 - 36
database/migrations/2017_12_29_135738_create_country_table.php

@@ -1,36 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateCountryTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('country', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('country_name', 50)->default('')->comment('名称');
-            $table->string('country_code', 10)->default('')->comment('代码');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('country');
-    }
-}

+ 0 - 47
database/migrations/2017_12_29_135751_create_coupon_table.php

@@ -1,47 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateCouponTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('coupon', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('name', 50)->default('')->comment('优惠券名称');
-            $table->string('logo', 255)->default('')->comment('优惠券LOGO');
-            $table->char('sn', 8)->default('')->comment('优惠券码');
-            $table->tinyInteger('type')->default('1')->comment('类型:1-现金券、2-折扣券、3-充值券');
-            $table->tinyInteger('usage')->default('1')->comment('用途:1-仅限一次性使用、2-可重复使用');
-            $table->bigInteger('amount')->default('0')->comment('金额,单位分');
-            $table->decimal('discount', 10, 2)->default('0.00')->comment('折扣');
-            $table->integer('available_start')->default('0')->comment('有效期开始');
-            $table->integer('available_end')->default('0')->comment('有效期结束');
-            $table->tinyInteger('is_del')->default('0')->comment('是否已删除:0-未删除、1-已删除');
-            $table->tinyInteger('status')->default('1')->comment('状态:0-未使用、1-已使用、2-已失效');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('coupon');
-    }
-}

+ 0 - 39
database/migrations/2017_12_29_135804_create_coupon_log_table.php

@@ -1,39 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateCouponLogTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('coupon_log', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('coupon_id')->default('0')->comment('优惠券ID');
-            $table->integer('goods_id')->default('0')->comment('商品ID');
-            $table->integer('order_id')->default('0')->comment('订单ID');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('coupon_log');
-    }
-}

+ 0 - 40
database/migrations/2017_12_29_135816_create_email_log_table.php

@@ -1,40 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateEmailLogTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('email_log', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('接收者ID');
-            $table->string('title', 255)->default('')->comment('邮件标题');
-            $table->text('content')->nullable()->comment('邮件内容');
-            $table->tinyInteger('status')->default('1')->comment('状态:1-发送成功、2-发送失败');
-            $table->text('error')->nullable()->comment('发送失败抛出的异常信息');
-            $table->dateTime('created_at')->comment('创建时间');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('email_log');
-    }
-}

+ 0 - 47
database/migrations/2017_12_29_135828_create_goods_table.php

@@ -1,47 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateGoodsTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('goods', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('sku', 15)->default('')->comment('商品服务SKU');
-            $table->string('name', 100)->default('')->comment('商品名称');
-            $table->string('logo', 255)->default('')->comment('商品图片地址');
-            $table->bigInteger('traffic')->default('0')->comment('商品内含多少流量,单位Mib');
-            $table->integer('score')->default('0')->comment('商品价值多少积分');
-            $table->tinyInteger('type')->default('1')->comment('商品类型:1-流量包、2-套餐');
-            $table->integer('price')->default('0')->comment('商品售价,单位分');
-            $table->string('desc', 255)->default('')->nullable()->comment('商品描述');
-            $table->integer('days')->default('30')->comment('有效期');
-            $table->tinyInteger('is_del')->default('0')->comment('是否已删除:0-否、1-是');
-            $table->tinyInteger('status')->default('1')->comment('状态:0-下架、1-上架');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('goods');
-    }
-}

+ 0 - 41
database/migrations/2017_12_29_135839_create_invite_table.php

@@ -1,41 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateInviteTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('invite', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('uid')->default('0')->comment('邀请人ID');
-            $table->integer('fuid')->default('0')->comment('受邀人ID');
-            $table->char('code', 32)->default('')->comment('邀请码');
-            $table->tinyInteger('status')->default('0')->comment('邀请码状态:0-未使用、1-已使用、2-已过期');
-            $table->dateTime('dateline')->nullable()->comment('有效期至');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('invite');
-    }
-}

+ 0 - 38
database/migrations/2017_12_29_135850_create_level_table.php

@@ -1,38 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateLevelTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('level', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('level')->default('1')->comment('等级');
-            $table->string('level_name', 100)->default('')->comment('等级名称');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();;
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('level');
-    }
-}

+ 0 - 46
database/migrations/2017_12_29_135900_create_order_table.php

@@ -1,46 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateOrderTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('order', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('oid');
-            $table->string('order_sn', 20)->default('')->comment('订单编号');
-            $table->integer('user_id')->default('0')->comment('操作人');
-            $table->integer('goods_id')->default('0')->comment('商品ID');
-            $table->integer('coupon_id')->default('0')->comment('优惠券ID');
-            $table->integer('origin_amount')->default('0')->comment('订单原始总价,单位分');
-            $table->integer('amount')->default('0')->comment('订单总价,单位分');
-            $table->dateTime('expire_at')->nullable()->comment('过期时间');
-            $table->tinyInteger('is_expire')->default('0')->comment('是否已过期:0-未过期、1-已过期');
-            $table->tinyInteger('pay_way')->default('1')->comment('支付方式:1-余额支付、2-有赞云支付');
-            $table->tinyInteger('status')->default('0')->comment('订单状态:-1-已关闭、0-待支付、1-已支付待确认、2-已完成');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('order');
-    }
-}

+ 0 - 44
database/migrations/2017_12_29_135915_create_order_goods_table.php

@@ -1,44 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateOrderGoodsTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('order_goods', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('oid')->default('0')->comment('订单ID');
-            $table->string('order_sn', 20)->default('')->comment('订单编号');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('goods_id')->default('0')->comment('商品ID');
-            $table->integer('num')->default('0')->comment('商品数量');
-            $table->integer('origin_price')->default('0')->comment('商品原价,单位分');
-            $table->integer('price')->default('0')->comment('商品实际价格,单位分');
-            $table->tinyInteger('is_expire')->default('0')->comment('是否已过期:0-未过期、1-已过期');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('order_goods');
-    }
-}

+ 0 - 42
database/migrations/2017_12_29_135948_create_referral_apply_table.php

@@ -1,42 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateReferralApplyTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('referral_apply', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('before')->default('0')->comment('操作前可提现金额,单位分');
-            $table->integer('after')->default('0')->comment('操作后可提现金额,单位分');
-            $table->integer('amount')->default('0')->comment('本次提现金额,单位分');
-            $table->string('link_logs', 255)->default('')->comment('关联返利日志ID,例如:1,3,4');
-            $table->tinyInteger('status')->default('0')->comment('状态:-1-驳回、0-待审核、1-审核通过待打款、2-已打款');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('referral_apply');
-    }
-}

+ 0 - 42
database/migrations/2017_12_29_140008_create_referral_log_table.php

@@ -1,42 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateReferralLogTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('referral_log', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('ref_user_id')->default('0')->comment('推广人ID');
-            $table->integer('order_id')->default('0')->comment('关联订单ID');
-            $table->integer('amount')->default('0')->comment('消费金额,单位分');
-            $table->integer('ref_amount')->default('0')->comment('返利金额');
-            $table->tinyInteger('status')->default('0')->comment('状态:0-未提现、1-审核中、2-已提现');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('referral_log');
-    }
-}

+ 0 - 38
database/migrations/2017_12_29_140026_create_ss_config_table.php

@@ -1,38 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateSsConfigTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ss_config', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('name', 50)->default('')->comment('配置名');
-            $table->tinyInteger('type')->default('1')->comment('类型:1-加密方式、2-协议、3-混淆');
-            $table->tinyInteger('is_default')->default('0')->comment('是否默认:0-不是、1-是');
-            $table->integer('sort')->default('0')->comment('排序:值越大排越前');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ss_config');
-    }
-}

+ 0 - 38
database/migrations/2017_12_29_140038_create_ss_group_table.php

@@ -1,38 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateSsGroupTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ss_group', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('name', 50)->default('')->comment('分组名称');
-            $table->tinyInteger('level')->default('1')->comment('分组级别');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ss_group');
-    }
-}

+ 0 - 36
database/migrations/2017_12_29_140049_create_ss_group_node_table.php

@@ -1,36 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateSsGroupNodeTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ss_group_node', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('group_id')->default('0')->comment('分组ID');
-            $table->integer('node_id')->default('0')->comment('节点ID');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ss_group_node');
-    }
-}

+ 0 - 63
database/migrations/2017_12_29_140101_create_ss_node_table.php

@@ -1,63 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateSsNodeTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ss_node', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('name', 128)->default('')->comment('名称');
-            $table->integer('group_id')->default('0')->comment('所属分组');
-            $table->char('country_code', 5)->default('')->nullable()->comment('国家代码');
-            $table->string('server', 128)->default('')->nullable()->comment('服务器域名地址');
-            $table->string('ip', 15)->default('')->nullable()->comment('服务器IPV4地址');
-            $table->string('ipv6', 128)->default('')->nullable()->comment('服务器IPV6地址');
-            $table->string('desc', 255)->default('')->nullable()->comment('节点简单描述');
-            $table->string('method', 32)->default('aes-192-ctr')->comment('加密方式');
-            $table->string('protocol', 128)->default('auth_chain_a')->comment('协议');
-            $table->string('protocol_param', 128)->default('')->nullable()->comment('协议参数');
-            $table->string('obfs', 128)->default('tls1.2_ticket_auth')->comment('混淆');
-            $table->string('obfs_param', 128)->default('')->nullable()->comment('混淆参数');
-            $table->float('traffic_rate')->default('1.00')->comment('流量比率');
-            $table->integer('bandwidth')->default('100')->comment('出口带宽,单位M');
-            $table->bigInteger('traffic')->default('1000')->comment('每月可用流量,单位G');
-            $table->string('monitor_url', 255)->default('')->nullable()->comment('监控地址');
-            $table->tinyInteger('is_subscribe')->default('1')->nullable()->comment('是否允许用户订阅该节点:0-否、1-是');
-            $table->tinyInteger('compatible')->default('0')->nullable()->comment('兼容SS');
-            $table->tinyInteger('single')->default('0')->nullable()->comment('单端口多用户');
-            $table->tinyInteger('single_force')->default('0')->nullable()->comment('模式:0-兼容模式、1-严格模式');
-            $table->string('single_port', 50)->default('')->nullable()->comment('端口号,用,号分隔');
-            $table->string('single_passwd', 50)->default('')->nullable()->comment('密码');
-            $table->string('single_method', 50)->default('')->nullable()->comment('加密方式');
-            $table->string('single_protocol', 50)->default('')->nullable()->comment('协议');
-            $table->string('single_obfs', 50)->default('')->nullable()->comment('混淆');
-            $table->integer('sort')->default('0')->comment('排序值,值越大越靠前显示');
-            $table->tinyInteger('status')->default('1')->comment('状态:0-维护、1-正常');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ss_node');
-    }
-}

+ 0 - 40
database/migrations/2017_12_29_140111_create_ss_node_info_table.php

@@ -1,40 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateSsNodeInfoTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ss_node_info', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('node_id')->default('0')->comment('节点ID');
-            $table->float('uptime')->comment('更新时间');
-            $table->string('load', 32)->default('')->nullable()->comment('负载');
-            $table->integer('log_time')->default('0')->comment('记录时间');
-
-            $table->index('node_id');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ss_node_info');
-    }
-}

+ 0 - 39
database/migrations/2017_12_29_140125_create_ss_node_online_log_table.php

@@ -1,39 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateSsNodeOnlineLogTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ss_node_online_log', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('node_id')->default('0')->comment('节点ID');
-            $table->integer('online_user')->default('0')->comment('在线用户数');
-            $table->integer('log_time')->default('0')->comment('记录时间');
-
-            $table->index('node_id');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ss_node_online_log');
-    }
-}

+ 0 - 43
database/migrations/2017_12_29_140140_create_ss_node_traffic_daily_table.php

@@ -1,43 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateSsNodeTrafficDailyTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ss_node_traffic_daily', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('node_id')->default('0')->comment('节点ID');
-            $table->bigInteger('u')->default('0')->comment('上传流量');
-            $table->bigInteger('d')->default('0')->comment('下载流量');
-            $table->bigInteger('total')->default('0')->comment('总流量');
-            $table->string('traffic', 255)->default('')->comment('总流量(带单位)');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-
-            $table->index('node_id');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ss_node_traffic_daily');
-    }
-}

+ 0 - 43
database/migrations/2017_12_29_140153_create_ss_node_traffic_hourly_table.php

@@ -1,43 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateSsNodeTrafficHourlyTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ss_node_traffic_hourly', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('node_id')->default('0')->comment('节点ID');
-            $table->bigInteger('u')->default('0')->comment('上传流量');
-            $table->bigInteger('d')->default('0')->comment('下载流量');
-            $table->bigInteger('total')->default('0')->comment('总流量');
-            $table->string('traffic', 255)->default('')->comment('总流量(带单位)');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-
-            $table->index('node_id');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ss_node_traffic_hourly');
-    }
-}

+ 0 - 39
database/migrations/2017_12_29_140205_create_ticket_table.php

@@ -1,39 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateTicketTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ticket', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->string('title', 255)->default('')->comment('标题');
-            $table->text('content')->comment('内容');
-            $table->tinyInteger('status')->default('0')->comment('状态:0-待处理、1-已处理未关闭、2-已关闭');
-            $table->dateTime('created_at');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ticket');
-    }
-}

+ 0 - 38
database/migrations/2017_12_29_140216_create_ticket_reply_table.php

@@ -1,38 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateTicketReplyTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('ticket_reply', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('ticket_id')->default('0')->comment('工单ID');
-            $table->integer('user_id')->default('0')->comment('回复人ID');
-            $table->text('content')->comment('回复内容')->nullable();
-            $table->dateTime('created_at');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('ticket_reply');
-    }
-}

+ 0 - 71
database/migrations/2017_12_29_140229_create_user_table.php

@@ -1,71 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('username', 128)->default('')->comment('用户名');
-            $table->string('password', 64)->default('')->comment('密码');
-            $table->integer('port')->default('0')->comment('SS端口');
-            $table->string('passwd', 16)->default('')->comment('SS密码');
-            $table->bigInteger('transfer_enable')->default('1073741824000')->comment('可用流量,单位字节,默认1TiB');
-            $table->bigInteger('u')->default('0')->comment('已上传流量,单位字节');
-            $table->bigInteger('d')->default('0')->comment('已下载流量,单位字节');
-            $table->integer('t')->default('0')->comment('最后使用时间');
-            $table->tinyInteger('enable')->default('1')->comment('SS状态');
-            $table->string('method', 30)->default('aes-192-ctr')->nullable()->comment('加密方式');
-            $table->string('protocol', 30)->default('auth_chain_a')->comment('协议');
-            $table->string('protocol_param', 255)->default('')->nullable()->comment('协议参数');
-            $table->string('obfs', 30)->default('tls1.2_ticket_auth')->comment('混淆');
-            $table->string('obfs_param', 255)->default('')->nullable()->comment('混淆参数');
-            $table->integer('speed_limit_per_con')->default('204800')->comment('单连接限速,默认200M,单位KB');
-            $table->integer('speed_limit_per_user')->default('204800')->comment('单用户限速,默认200M,单位KB');
-            $table->tinyInteger('gender')->default('1')->comment('性别:0-女、1-男');
-            $table->string('wechat', 30)->default('')->nullable()->comment('微信');
-            $table->string('qq', 20)->default('')->nullable()->comment('QQ');
-            $table->tinyInteger('usage')->default('1')->comment('用途:1-手机、2-电脑、3-路由器、4-其他');
-            $table->tinyInteger('pay_way')->default('3')->comment('付费方式:0-免费、1-月付、2-半年付、3-年付');
-            $table->integer('balance')->default('0')->comment('余额,单位分');
-            $table->integer('score')->default('0')->comment('积分');
-            $table->date('enable_time')->nullable()->comment('开通日期');
-            $table->date('expire_time')->default('2099-01-01')->comment('过期时间');
-            $table->integer('ban_time')->default('0')->comment('封禁到期时间');
-            $table->text('remark')->nullable()->comment('备注');
-            $table->tinyInteger('level')->default('1')->comment('等级');
-            $table->tinyInteger('is_admin')->default('0')->comment('是否管理员:0-否、1-是');
-            $table->string('reg_ip', 20)->default('127.0.0.1')->comment('注册IP');
-            $table->integer('last_login')->default('0')->comment('最后一次登录时间');
-            $table->integer('referral_uid')->default('0')->comment('邀请人');
-            $table->tinyInteger('traffic_reset_day')->default('0')->comment('流量自动重置日,0表示不重置');
-            $table->tinyInteger('status')->default('0')->comment('状态:-1-禁用、0-未激活、1-正常');
-            $table->string('remember_token', 255)->default('')->nullable();
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user');
-    }
-}

+ 0 - 43
database/migrations/2017_12_29_140239_create_user_balance_log_table.php

@@ -1,43 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserBalanceLogTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user_balance_log', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('order_id')->default('0')->comment('订单ID');
-            $table->integer('before')->default('0')->comment('发生前余额,单位分');
-            $table->integer('after')->default('0')->comment('发生后金额,单位分');
-            $table->integer('amount')->default('0')->comment('发生金额,单位分');
-            $table->string('desc', 255)->default('')->nullable()->comment('操作描述');
-            $table->dateTime('created_at')->nullable()->comment('创建时间');
-
-            $table->index('user_id');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user_balance_log');
-    }
-}

+ 0 - 42
database/migrations/2017_12_29_140253_create_user_ban_log_table.php

@@ -1,42 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserBanLogTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user_ban_log', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('minutes')->default('0')->comment('封禁账号时长,单位分钟');
-            $table->string('desc', 255)->default('')->nullable()->comment('操作描述');
-            $table->tinyInteger('status')->default('0')->comment('状态:0-未处理、1-已处理');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-
-            $table->index('user_id');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user_ban_log');
-    }
-}

+ 0 - 42
database/migrations/2017_12_29_140304_create_user_score_log_table.php

@@ -1,42 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserScoreLogTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user_score_log', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('before')->default('0')->comment('发生前的积分值');
-            $table->integer('after')->default('0')->comment('发生后的积分值');
-            $table->integer('score')->default('0')->comment('发生值');
-            $table->string('desc', 50)->default('')->nullable()->comment('描述');
-            $table->dateTime('created_at');
-
-            $table->index('user_id');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user_score_log');
-    }
-}

+ 0 - 42
database/migrations/2017_12_29_140319_create_user_subscribe_table.php

@@ -1,42 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserSubscribeTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user_subscribe', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->char('code', 5)->default('')->nullable()->charset('utf8mb4')->collation('utf8mb4_bin')->comment('订阅地址唯一识别码');
-            $table->integer('times')->default('0')->comment('地址请求次数');
-            $table->tinyInteger('status')->default('1')->comment('状态:0-禁用、1-启用');
-            $table->integer('ban_time')->default('0')->comment('封禁时间');
-            $table->string('ban_desc', 50)->default('')->nullable()->comment('封禁理由');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user_subscribe');
-    }
-}

+ 0 - 38
database/migrations/2017_12_29_140330_create_user_subscribe_log_table.php

@@ -1,38 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserSubscribeLogTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user_subscribe_log', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('sid')->default('0')->comment('对应user_subscribe的id');
-            $table->string('request_ip', 20)->default('127.0.0.1')->nullable()->comment('请求IP');
-            $table->dateTime('request_time')->nullable()->comment('请求时间');
-            $table->text('request_header')->nullable()->comment('请求头部信息');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user_subscribe_log');
-    }
-}

+ 0 - 46
database/migrations/2017_12_29_140345_create_user_traffic_daily_table.php

@@ -1,46 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserTrafficDailyTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user_traffic_daily', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('node_id')->default('0')->comment('节点ID,0表示统计全部节点');
-            $table->bigInteger('u')->default('0')->comment('上传流量');
-            $table->bigInteger('d')->default('0')->comment('下载流量');
-            $table->bigInteger('total')->default('0')->comment('总流量');
-            $table->string('traffic', 255)->default('')->comment('总流量(带单位)');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-
-            $table->index('user_id');
-            $table->index('node_id');
-            $table->index(['user_id', 'node_id']);
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user_traffic_daily');
-    }
-}

+ 0 - 46
database/migrations/2017_12_29_140357_create_user_traffic_hourly_table.php

@@ -1,46 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserTrafficHourlyTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user_traffic_hourly', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('node_id')->default('0')->comment('节点ID,0表示统计全部节点');
-            $table->bigInteger('u')->default('0')->comment('上传流量');
-            $table->bigInteger('d')->default('0')->comment('下载流量');
-            $table->bigInteger('total')->default('0')->comment('总流量');
-            $table->string('traffic', 255)->default('')->comment('总流量(带单位)');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-
-            $table->index('user_id');
-            $table->index('node_id');
-            $table->index(['user_id', 'node_id']);
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user_traffic_hourly');
-    }
-}

+ 0 - 45
database/migrations/2017_12_29_140409_create_user_traffic_log_table.php

@@ -1,45 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserTrafficLogTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user_traffic_log', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('u')->default('0')->comment('上传流量');
-            $table->integer('d')->default('0')->comment('下载流量');
-            $table->integer('node_id')->default('0')->comment('节点ID');
-            $table->float('rate')->default('1.0')->comment('流量比例');
-            $table->string('traffic', 32)->default('')->comment('产生流量');
-            $table->integer('log_time')->default('0')->comment('记录时间');
-
-            $table->index('user_id');
-            $table->index('node_id');
-            $table->index(['user_id', 'node_id']);
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user_traffic_log');
-    }
-}

+ 0 - 40
database/migrations/2017_12_29_140422_create_verify_table.php

@@ -1,40 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateVerifyTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('verify', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->string('username', 50)->default('')->comment('用户名');
-            $table->string('token', 32)->default('')->comment('校验token');
-            $table->tinyInteger('status')->default('0')->comment('状态:0-未使用、1-已使用、2-已失效');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('verify');
-    }
-}

+ 0 - 39
database/migrations/2018_05_24_113606_create_goods_label_table.php

@@ -1,39 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateGoodsLabelTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('goods_label', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('goods_id')->default('0')->comment('商品ID');
-            $table->integer('label_id')->default('0')->comment('标签ID');
-
-            $table->index('goods_id');
-            $table->index('label_id');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('goods_label');
-    }
-}

+ 0 - 47
database/migrations/2018_05_24_113645_create_payment_table.php

@@ -1,47 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreatePaymentTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('payment', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->char('sn', 50)->default('')->comment('订单唯一码');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('oid')->default('0')->comment('本地订单ID');
-            $table->string('order_sn', 50)->default('0')->comment('本地订单长ID');
-            $table->tinyInteger('pay_way')->default('1')->comment('支付方式:1-微信、2-支付宝');
-            $table->integer('amount')->default('0')->comment('金额,单位分');
-            $table->integer('qr_id')->default('0')->comment('有赞生成的支付单ID');
-            $table->string('qr_url', 255)->default('')->comment('有赞生成的支付二维码URL');
-            $table->text('qr_code')->nullable()->comment('有赞生成的支付二维码图片base64');
-            $table->string('qr_local_url', 255)->nullable()->comment('支付二维码的本地存储URL');
-            $table->tinyInteger('status')->default('0')->comment('状态:-1-支付失败、0-等待支付、1-支付成功');
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('payment');
-    }
-}

+ 0 - 48
database/migrations/2018_05_24_113657_create_payment_callback_table.php

@@ -1,48 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreatePaymentCallbackTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('payment_callback', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('client_id', 50)->nullable();
-            $table->string('yz_id', 50)->nullable();
-            $table->string('kdt_id', 50)->nullable();
-            $table->string('kdt_name', 50)->nullable();
-            $table->tinyInteger('mode')->nullable();
-            $table->text('msg')->nullable();
-            $table->integer('sendCount')->default('0');
-            $table->string('sign', 32)->default('1');
-            $table->string('status', 30)->default('0');
-            $table->tinyInteger('test')->default('0');
-            $table->string('type', 50)->default('');
-            $table->string('version', 50)->nullable();
-            $table->dateTime('created_at')->nullable();
-            $table->dateTime('updated_at')->nullable();
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('payment_callback');
-    }
-}

+ 0 - 36
database/migrations/2018_05_24_113825_create_label_table.php

@@ -1,36 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateLabelTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('label', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->string('name', 255)->default('')->comment('名称');
-            $table->integer('sort')->default('0')->comment('排序值');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('label');
-    }
-}

+ 0 - 36
database/migrations/2018_05_24_113851_create_user_label_table.php

@@ -1,36 +0,0 @@
-<?php
-
-use Illuminate\Support\Facades\Schema;
-use Illuminate\Database\Schema\Blueprint;
-use Illuminate\Database\Migrations\Migration;
-
-class CreateUserLabelTable extends Migration
-{
-    /**
-     * Run the migrations.
-     *
-     * @return void
-     */
-    public function up()
-    {
-        Schema::create('user_label', function (Blueprint $table) {
-            $table->engine = 'InnoDB';
-            $table->charset = 'utf8mb4';
-            $table->collation = 'utf8mb4_unicode_ci';
-
-            $table->increments('id');
-            $table->integer('user_id')->default('0')->comment('用户ID');
-            $table->integer('label_id')->default('0')->comment('标签ID');
-        });
-    }
-
-    /**
-     * Reverse the migrations.
-     *
-     * @return void
-     */
-    public function down()
-    {
-        Schema::dropIfExists('user_label');
-    }
-}