added currency transformer to incomes/expenses api

This commit is contained in:
denisdulici
2018-02-09 16:18:56 +03:00
parent dc9b33a68f
commit e97731eed9
9 changed files with 144 additions and 64 deletions

View File

@ -27,6 +27,11 @@ class BillPayment extends Model
return $this->belongsTo('App\Models\Banking\Account');
}
public function currency()
{
return $this->belongsTo('App\Models\Setting\Currency', 'currency_code', 'code');
}
public function bill()
{
return $this->belongsTo('App\Models\Expense\Bill');