Fixed sortable missing column issue..

This commit is contained in:
Cüneyt Şentürk 2023-11-29 18:13:57 +03:00
parent 8bae57e858
commit f076338b3f
6 changed files with 35 additions and 6 deletions

View File

@ -37,7 +37,7 @@ class Reconciliation extends Model
*
* @var array
*/
public $sortable = ['created_at', 'account_id', 'started_at', 'ended_at', 'closing_balance', 'reconciled'];
public $sortable = ['created_at', 'account_id', 'started_at', 'ended_at', 'opening_balance', 'closing_balance', 'reconciled'];
public function account()
{

View File

@ -73,7 +73,18 @@ class Transaction extends Model
*
* @var array
*/
public $sortable = ['type', 'number', 'paid_at', 'amount', 'category.name', 'account.name', 'customer.name', 'invoice.document_number'];
public $sortable = [
'paid_at',
'number',
'type',
'account.name',
'contact.name',
'category.name',
'document.document_number',
'amount',
'recurring.started_at',
'recurring.status',
];
/**
* Clonable relationships.

View File

@ -50,7 +50,7 @@ class Company extends Eloquent implements Ownable
*
* @var array
*/
public $sortable = ['id', 'name', 'domain', 'email', 'enabled', 'created_at', 'tax_number', 'country', 'currency'];
public $sortable = ['id', 'name', 'domain', 'email', 'phone', 'enabled', 'created_at', 'tax_number', 'country', 'currency'];
/**
* Fill the model with an array of attributes.

View File

@ -71,7 +71,15 @@ class Contact extends Model
*
* @var array
*/
public $sortable = ['name', 'email', 'phone', 'enabled'];
public $sortable = [
'name',
'tax_number',
'email',
'phone',
'country',
'currency_code',
'enabled'
];
/**
* @var array

View File

@ -78,7 +78,17 @@ class Document extends Model
/**
* @var array
*/
public $sortable = ['document_number', 'contact_name', 'amount', 'status', 'issued_at', 'due_at'];
public $sortable = [
'issued_at',
'due_at',
'status',
'contact_name',
'document_number',
'amount',
'recurring.started_at',
'category.name',
'recurring.status',
];
/**
* @var array

View File

@ -44,7 +44,7 @@
</x-table.th>
<x-table.th class="w-2/12">
<x-sortablelink column="type" title="{{ trans('currencies.rate') }}" />
<x-sortablelink column="rate" title="{{ trans('currencies.rate') }}" />
</x-table.th>
</x-table.tr>
</x-table.thead>