StoreSyncLog.php 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889
  1. <?php
  2. /**
  3. * 厦门云联储网络科技有限公司
  4. * https://www.baokuaiyun.com
  5. * Copyright (c) 2023 爆块云 All rights reserved.
  6. */
  7. namespace app\models;
  8. use yii\db\ActiveRecord;
  9. use yii\behaviors\TimestampBehavior;
  10. /**
  11. * Class StoreSyncLog
  12. * @package app\modules\common\models
  13. *
  14. * @property integer $id
  15. * @property integer $from_store_id
  16. * @property string $to_store_ids
  17. * @property integer $status
  18. * @property string $created_at
  19. * @property string $updated_at
  20. * @property integer $result
  21. * @property integer $sync_id
  22. * @property string $goods_info
  23. * @property string $pintuan
  24. * @property string $bargain
  25. * @property string $diy
  26. * @property string $seckill
  27. * @property string $shareConfig
  28. * @property string $shareHolderConfig
  29. * @property string $videoGoods
  30. * @property string $integralStore
  31. * @property string $workerConfig
  32. * @property string $article
  33. * @property string $topic
  34. */
  35. class StoreSyncLog extends ActiveRecord
  36. {
  37. public static function tableName()
  38. {
  39. return '{{%store_sync_log}}';
  40. }
  41. public function behaviors()
  42. {
  43. return [
  44. [
  45. // 自动更新创建和更新时间
  46. 'class' => TimestampBehavior::class,
  47. 'value' => time()
  48. ]
  49. ];
  50. }
  51. public function rules()
  52. {
  53. return [
  54. [['from_store_id', 'status', 'result', 'sync_id'], 'integer'],
  55. [['to_store_ids', 'goods_info', 'pintuan', 'bargain', 'diy', 'seckill', 'shareConfig', 'shareHolderConfig', 'videoGoods', 'integralStore', 'workerConfig', 'article', 'topic'], 'string'],
  56. [['create_at', 'update_at'], 'safe'],
  57. ];
  58. }
  59. public function attributeLabels()
  60. {
  61. return [
  62. 'id' => 'ID',
  63. 'from_store_id' => '来源商城',
  64. 'to_store_ids' => '同步到商城,多个',
  65. 'status' => '状态, 0:等待执行,1:执行完成',
  66. 'create_at' => '创建时间',
  67. 'update_at' => '更新时间',
  68. 'result' => '0:排队中,1:执行成功, 2:执行失败',
  69. 'sync_id' => '任务id',
  70. 'goods_info' => '商品同步信息',
  71. 'pintuan' => '拼团信息',
  72. 'bargain' => '砍价信息',
  73. 'diy' => '装修信息',
  74. 'seckill' => '秒杀信息',
  75. 'shareConfig' => '分销信息',
  76. 'shareHolderConfig' => '股东信息',
  77. 'videoGoods' => '短视频信息',
  78. 'integralStore' => '积分商城信息',
  79. 'workerConfig' => '上门服务',
  80. 'article' => '文章',
  81. 'topic' => '专题',
  82. ];
  83. }
  84. }