Mt4DepositLog.php 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071
  1. <?php
  2. namespace backend\models;
  3. use Yii;
  4. /**
  5. * This is the model class for table "crm_mt4_deposit_log".
  6. *
  7. * @property integer $id
  8. * @property integer $type
  9. * @property integer $mt4_id
  10. * @property string $order_id
  11. * @property string $mt4_order_id
  12. * @property string $usd_money
  13. * @property string $err_code
  14. * @property string $err_msg
  15. * @property integer $create_time
  16. */
  17. class Mt4DepositLog extends \yii\db\ActiveRecord
  18. {
  19. /**
  20. * @inheritdoc
  21. */
  22. public static function tableName()
  23. {
  24. return 'crm_mt4_deposit_log';
  25. }
  26. /**
  27. * @return \yii\db\Connection the database connection used by this AR class.
  28. */
  29. public static function getDb()
  30. {
  31. return Yii::$app->get('dbXcrm');
  32. }
  33. /**
  34. * @inheritdoc
  35. */
  36. public function rules()
  37. {
  38. return [
  39. [['type', 'mt4_id', 'create_time','log_id'], 'integer'],
  40. [['usd_money'], 'number'],
  41. [['create_time'], 'required'],
  42. [['order_id', 'mt4_order_id',], 'string', 'max' => 32],
  43. [['err_code'], 'string', 'max' => 16],
  44. [['err_msg'], 'string', 'max' => 255],
  45. ];
  46. }
  47. /**
  48. * @inheritdoc
  49. */
  50. public function attributeLabels()
  51. {
  52. return [
  53. 'id' => '自增ID',
  54. 'type' => '类型 1入金 2出金',
  55. 'mt4_id' => 'mt4 id',
  56. 'order_id' => '订单号',
  57. 'mt4_order_id' => 'mt4订单号',
  58. 'usd_money' => '操作金额 美元',
  59. 'err_code' => '错误码',
  60. 'err_msg' => '错误信息',
  61. 'create_time' => '创建时间',
  62. 'log_id'=> '出入金的id',
  63. ];
  64. }
  65. }