<?php

namespace App;

use Illuminate\Database\Eloquent\Model;
use App\Traits\ModelTimeFormat;

class BillingModel extends Model
{
    use ModelTimeFormat;
    protected $fillable=[
        'carrier_id','province_id','city_id','unit_id','range_min','range_max','unit_price','initial_weight'
    ];

    public function carrier(){
        return $this->belongsTo('App\Carrier','carrier_id','id');
    }

    public  function province(){
        return $this->belongsTo('App\Province','province_id','id');
    }

    public  function city(){
        return $this->belongsTo('App\City','city_id','id');
    }

    public function unit(){
        return $this->belongsTo('App\Unit','unit_id','id');
    }
}
