AddonsSmartFormTemplateUserBehavior.php 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. <?php
  2. namespace addons\SmartForm\common\models;
  3. use common\enums\StatusEnum;
  4. use common\models\mall\MallAddons;
  5. use common\models\user\User;
  6. use Yii;
  7. use yii\db\Exception;
  8. /**
  9. * This is the model class for table "{{%addons_smart_form_template_user_behavior}}".
  10. *
  11. * @property int $id
  12. * @property int $mall_id 商城ID
  13. * @property int|null $status 状态[-1:删除;0:禁用;1启用]
  14. * @property int $created_at 创建时间
  15. */
  16. class AddonsSmartFormTemplateUserBehavior extends \common\models\base\BaseActiveRecord
  17. {
  18. const ADDONS_NAME = 'SmartForm';
  19. /**
  20. * {@inheritdoc}
  21. */
  22. public static function tableName()
  23. {
  24. return '{{%addons_smart_form_template_user_behavior}}';
  25. }
  26. /**
  27. * {@inheritdoc}
  28. */
  29. public function rules()
  30. {
  31. return [
  32. [['smart_form_template_id','user_id','behavior_type'], 'required'],
  33. [['smart_form_template_id','user_id','behavior_type','is_submit','diy_page_id'], 'integer'],
  34. [['month_day'], 'string', 'max' => 10],
  35. ];
  36. }
  37. /**
  38. * {@inheritdoc}
  39. */
  40. public function attributeLabels()
  41. {
  42. return [
  43. 'id' => '主键' ,
  44. 'smart_form_template_id' => '智能装修表单管理id',
  45. 'user_id' => '用户id',
  46. 'diy_page_id' => '使用页面id',
  47. 'behavior_type' => '提交类型[0:访问;1:提交]',
  48. 'is_submit' => '访问类型是否已提交[0:否;1是]',
  49. 'month_day' => '访问年月日',
  50. 'created_at' => '添加时间',
  51. 'updated_at' => '添加时间',
  52. ];
  53. }
  54. }