FRentCarCost.php 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. <?php
  2. namespace app\modules\car\models;
  3. use Yii;
  4. /**
  5. * This is the model class for table "{{%f_rent_car_cost}}".
  6. *
  7. * @property int $id 序号
  8. * @property int $car_id 外键关联f_car_infor(car_id)
  9. * @property float|null $repair_costs 维修
  10. * @property float|null $insurance_costs 保险
  11. * @property float|null $year_check_costs 年检
  12. * @property int|null $year 年
  13. * @property int|null $month 月
  14. */
  15. class FRentCarCost extends \app\common\models\EActiveRecord
  16. {
  17. /**
  18. * {@inheritdoc}
  19. */
  20. public static function tableName()
  21. {
  22. return '{{%f_rent_car_cost}}';
  23. }
  24. /**
  25. * {@inheritdoc}
  26. */
  27. public function rules()
  28. {
  29. return [
  30. [['car_id'], 'required'],
  31. [['car_id', 'year', 'month'], 'integer'],
  32. [['repair_costs', 'insurance_costs', 'year_check_costs'], 'number'],
  33. ];
  34. }
  35. /**
  36. * {@inheritdoc}
  37. */
  38. public function attributeLabels()
  39. {
  40. return [
  41. 'id' => '序号',
  42. 'car_id' => '外键关联f_car_infor(car_id)',
  43. 'repair_costs' => '维修',
  44. 'insurance_costs' => '保险',
  45. 'year_check_costs' => '年检',
  46. 'year' => '年',
  47. 'month' => '月',
  48. ];
  49. }
  50. }