UserFapiaoSeeder.php 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?php
  2. namespace Database\Seeders\Frontend;
  3. use Database\Seeders\BaseSeeder;
  4. class UserFapiaoSeeder extends BaseSeeder
  5. {
  6. public function getColumnData()
  7. {
  8. return [
  9. 'user_id' => ['type' => 'uBigint', 'title' => '用户id', 'is_null' => 0],
  10. 'order_id' => ['type' => 'uBigint', 'title' => '订单id', 'is_null' => 0],
  11. 'company_name' => ['type' => 'string_60', 'title' => '公司抬头', 'is_null' => 0],
  12. 'taxpayer_number' => ['type' => 'string_30', 'title' => '纳税人识别号', 'is_null' => 0],
  13. 'email' => ['type' => 'string_30', 'title' => '邮箱', 'is_null' => 0],
  14. 'mobile' => ['type' => 'string_20', 'title' => '手机号', 'is_null' => 0],
  15. 'price' => ['type' => 'decimal', 'length' => 8, 'decimal' => 2, 'title' => '手机号', 'is_null' => 0],
  16. 'product_title' => ['type' => 'string_60', 'title' => '商品名称', 'is_null' => 0],
  17. 'file_path' => ['type' => 'string', 'title' => '发票文件路径', 'is_null' => 1],
  18. 'remark' => ['type' => 'string', 'title' => '备注', 'is_null' => 1],
  19. 'status' => ['type' => 'tinyint', 'default' => 0, 'title' => '0 申请中,未开票 1 已开票 2 已发送 3 发送失败'],
  20. ];
  21. }
  22. /**
  23. * 初始化内容
  24. */
  25. public function init()
  26. {
  27. }
  28. /**
  29. * Run the database seeds.
  30. *
  31. * @return void
  32. */
  33. public function run()
  34. {
  35. $this->schema = 'user_fapiao';
  36. $this->title = '用户发票表';
  37. $this->start();
  38. }
  39. }