wrong relationships

This commit is contained in:
denisdulici 2017-12-11 14:07:08 +03:00
parent ba7b6024ba
commit 66b1ee9c54
2 changed files with 0 additions and 15 deletions

View File

@ -59,16 +59,6 @@ class User extends Authenticatable
return $this->hasOne('App\Models\Income\Customer', 'user_id', 'id');
}
public function invoices()
{
return $this->hasMany('App\Models\Income\Invoice', 'customer_id', 'id');
}
public function revenues()
{
return $this->hasMany('App\Models\Income\Revenue', 'customer_id', 'id');
}
/**
* Always capitalize the name when we retrieve it
*/

View File

@ -53,11 +53,6 @@ class Invoice extends Model
*/
protected $cloneable_relations = ['items', 'totals'];
public function user()
{
return $this->belongsTo('App\Models\Auth\User', 'customer_id', 'id');
}
public function customer()
{
return $this->belongsTo('App\Models\Income\Customer');