1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-13 22:54:25 +01:00
invoiceninja/app/Ninja/Presenters/ClientPresenter.php
2016-10-18 17:55:07 +03:00

27 lines
576 B
PHP

<?php namespace App\Ninja\Presenters;
class ClientPresenter extends EntityPresenter {
public function country()
{
return $this->entity->country ? $this->entity->country->name : '';
}
public function balance()
{
$client = $this->entity;
$account = $client->account;
return $account->formatMoney($client->balance, $client);
}
public function paid_to_date()
{
$client = $this->entity;
$account = $client->account;
return $account->formatMoney($client->paid_to_date, $client);
}
}