1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-09-20 16:31:33 +02:00
invoiceninja/app/models/Credit.php
Hillel Coren 9dd1b54d4a bug fixes
2013-12-31 11:43:39 +02:00

29 lines
391 B
PHP
Executable File

<?php
class Credit extends EntityModel
{
public function invoice()
{
return $this->belongsTo('Invoice');
}
public function client()
{
return $this->belongsTo('Client');
}
public function getName()
{
return $this->credit_number;
}
public function getEntityType()
{
return ENTITY_CREDIT;
}
}
Credit::created(function($credit)
{
Activity::createCredit($credit);
});