akaunting 3.0 (the last dance)

This commit is contained in:
Burak Civan
2022-06-01 10:15:55 +03:00
parent cead09f6d4
commit d9c0764572
3812 changed files with 126831 additions and 102949 deletions

View File

@ -45,7 +45,7 @@ class Tax extends Model
public function items()
{
return $this->hasMany('App\Models\Common\Item');
return $this->hasMany('App\Models\Common\ItemTax');
}
public function document_items()
@ -136,6 +136,33 @@ class Tax extends Model
return $title;
}
/**
* Get the line actions.
*
* @return array
*/
public function getLineActionsAttribute()
{
$actions = [];
$actions[] = [
'title' => trans('general.edit'),
'icon' => 'edit',
'url' => route('taxes.edit', $this->id),
'permission' => 'update-settings-taxes',
];
$actions[] = [
'type' => 'delete',
'icon' => 'delete',
'route' => 'taxes.destroy',
'permission' => 'delete-settings-taxes',
'model' => $this,
];
return $actions;
}
/**
* Create a new factory instance for the model.
*