ResendQYAudit.php 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. <?php
  2. namespace common\models;
  3. use Yii;
  4. use common\libs\logging\operate\valueType\Config as ValueTypeConfig;
  5. /**
  6. * This is the model class for table "{{%RESEND_QY_AUDIT}}".
  7. *
  8. * @property string $ID
  9. * @property string $USER_ID 会员ID
  10. * @property string $RESEND_ID 补发表ID
  11. * @property string $SHOULD_BONUS 应发金额
  12. * @property string $RESEND_BONUS 补发金额
  13. * @property int $PERIOD_NUM 补发期数
  14. * @property int $AUDIT_STATUS 审核状态
  15. * @property string $RESEND_ADMIN_ID 补发管理员ID
  16. * @property string $AUDIT_ADMIN_ID 审核管理员ID
  17. * @property string $RESEND_REMARK 补发备注
  18. * @property string $AUDIT_REMARK 审核备注
  19. * @property int $CREATED_AT 创建时间
  20. * @property int $AUDITED_AT 审核时间
  21. */
  22. class ResendQYAudit extends \common\components\ActiveRecord
  23. {
  24. /**
  25. * {@inheritdoc}
  26. */
  27. public static function tableName()
  28. {
  29. return '{{%RESEND_QY_AUDIT}}';
  30. }
  31. /**
  32. * {@inheritdoc}
  33. */
  34. public function rules()
  35. {
  36. return [
  37. [['USER_ID', 'RESEND_ID', 'PERIOD_NUM', 'RESEND_ADMIN_ID', 'CREATED_AT'], 'required'],
  38. [['SHOULD_BONUS', 'RESEND_BONUS'], 'number'],
  39. [['PERIOD_NUM', 'AUDIT_STATUS', 'CREATED_AT', 'AUDITED_AT'], 'integer'],
  40. [['ID', 'USER_ID', 'RESEND_ID', 'RESEND_ADMIN_ID', 'AUDIT_ADMIN_ID'], 'string', 'max' => 32],
  41. [['RESEND_REMARK', 'AUDIT_REMARK'], 'string', 'max' => 4000],
  42. [['ID'], 'unique'],
  43. ];
  44. }
  45. /**
  46. * {@inheritdoc}
  47. */
  48. public function attributeLabels()
  49. {
  50. return [
  51. 'ID' => 'ID',
  52. 'USER_ID' => '会员ID',
  53. 'RESEND_ID' => '补发表ID',
  54. 'SHOULD_BONUS' => '应发金额',
  55. 'RESEND_BONUS' => '补发金额',
  56. 'PERIOD_NUM' => '补发期数',
  57. 'AUDIT_STATUS' => '审核状态',
  58. 'RESEND_ADMIN_ID' => '补发管理员ID',
  59. 'AUDIT_ADMIN_ID' => '审核管理员ID',
  60. 'RESEND_REMARK' => '补发备注',
  61. 'AUDIT_REMARK' => '审核备注',
  62. 'CREATED_AT' => '创建时间',
  63. 'AUDITED_AT' => '审核时间',
  64. ];
  65. }
  66. /**
  67. * 操作日志记录条件
  68. * @return array
  69. */
  70. public function attrLabelsWithLogType(){
  71. return [
  72. 'USER_ID' => '会员ID',
  73. 'SHOULD_BONUS' => '应发金额',
  74. 'RESEND_BONUS' => '补发金额',
  75. 'PERIOD_NUM' => '补发期数',
  76. 'AUDIT_STATUS' => [
  77. 'label' => '审核状态',
  78. 'type' => ValueTypeConfig::AUDIT_STATUS_TYPE,
  79. ],
  80. ];
  81. }
  82. }