|
- <?php
-
- namespace backend\modules\zzcs\models;
-
- use yii\db\ActiveRecord;
-
- /**
- * This is the model class for table "bus_expenses".
- *
- * @property integer $ID
- * @property integer $create_user_id
- * @property string $create_time
- * @property integer $update_user_id
- * @property string $update_time
- * @property integer $cancel_flag
- * @property integer $bus_id
- * @property integer $expense_subject_id
- * @property integer $expense_type
- * @property string $expense_price
- * @property string $receive_value
- * @property string $expense_destination
- * @property string $start_value
- * @property string $end_value
- */
- class BusExpenses extends ActiveRecord
- {
- /**
- * @inheritdoc
- */
- public static function tableName()
- {
- return 'bus_expenses';
- }
-
- /**
- * @inheritdoc
- */
- public function rules()
- {
- return [
- [['create_user_id', 'create_time', 'update_user_id', 'cancel_flag', 'expense_destination'], 'required'],
- [['create_user_id', 'update_user_id', 'cancel_flag', 'bus_id', 'expense_subject_id', 'expense_type'], 'integer'],
- [['update_time'], 'safe'],
- [['expense_price', 'start_value', 'end_value'], 'number'],
- [['create_time', 'receive_value', 'expense_destination'], 'string', 'max' => 255],
- ];
- }
-
- /**
- * @inheritdoc
- */
- public function attributeLabels()
- {
- return [
- 'ID' => 'ID',
- 'create_user_id' => 'Create User ID',
- 'create_time' => 'Create Time',
- 'update_user_id' => 'Update User ID',
- 'update_time' => 'Update Time',
- 'cancel_flag' => 'Cancel Flag',
- 'bus_id' => '车辆ID',
- 'expense_subject_id' => '支出科目(如:加油,充电) 对应dict_type.id 479加油 480 充电',
- 'expense_type' => '支出方式 对应dict_type.id',
- 'expense_price' => '支付金额',
- 'receive_value' => '量(如油量、电量)',
- 'expense_destination' => '支出去向',
- 'start_value' => '记录车辆节点开始时状态属性值(如:加油前里程数)',
- 'end_value' => '记录车辆节点开始时状态属性值',
- ];
- }
- }
|