mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-09-21 00:41:34 +02:00
Fixes for client portal data tables
This commit is contained in:
parent
19f2475fb1
commit
915abf3d41
@ -17,7 +17,7 @@ class CreditsTable extends Component
|
|||||||
public function render()
|
public function render()
|
||||||
{
|
{
|
||||||
$query = Credit::query()
|
$query = Credit::query()
|
||||||
->where('company_id', auth('contact')->user()->company->id)
|
->where('client_id', auth('contact')->user()->client->id)
|
||||||
->orderBy($this->sort_field, $this->sort_asc ? 'asc' : 'desc')
|
->orderBy($this->sort_field, $this->sort_asc ? 'asc' : 'desc')
|
||||||
->paginate($this->per_page);
|
->paginate($this->per_page);
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@ class PaymentMethodsTable extends Component
|
|||||||
{
|
{
|
||||||
$query = ClientGatewayToken::query()
|
$query = ClientGatewayToken::query()
|
||||||
->with('gateway_type')
|
->with('gateway_type')
|
||||||
->where('company_id', auth('contact')->user()->company->id)
|
|
||||||
->where('client_id', $this->client->id)
|
->where('client_id', $this->client->id)
|
||||||
->orderBy($this->sort_field, $this->sort_asc ? 'asc' : 'desc')
|
->orderBy($this->sort_field, $this->sort_asc ? 'asc' : 'desc')
|
||||||
->paginate($this->per_page);
|
->paginate($this->per_page);
|
||||||
|
@ -24,7 +24,7 @@ class PaymentsTable extends Component
|
|||||||
{
|
{
|
||||||
$query = Payment::query()
|
$query = Payment::query()
|
||||||
->with('type', 'client')
|
->with('type', 'client')
|
||||||
->where('company_id', auth('contact')->user()->company->id)
|
->where('client_id', auth('contact')->user()->client->id)
|
||||||
->orderBy($this->sort_field, $this->sort_asc ? 'asc' : 'desc')
|
->orderBy($this->sort_field, $this->sort_asc ? 'asc' : 'desc')
|
||||||
->paginate($this->per_page);
|
->paginate($this->per_page);
|
||||||
|
|
||||||
|
@ -46,7 +46,7 @@ class QuotesTable extends Component
|
|||||||
}
|
}
|
||||||
|
|
||||||
$query = $query
|
$query = $query
|
||||||
->where('company_id', auth('contact')->user()->company->id)
|
->where('client_id', auth('contact')->user()->client->id)
|
||||||
->paginate($this->per_page);
|
->paginate($this->per_page);
|
||||||
|
|
||||||
return render('components.livewire.quotes-table', [
|
return render('components.livewire.quotes-table', [
|
||||||
|
@ -18,7 +18,7 @@ class RecurringInvoicesTable extends Component
|
|||||||
$query = RecurringInvoice::query();
|
$query = RecurringInvoice::query();
|
||||||
|
|
||||||
$query = $query
|
$query = $query
|
||||||
->where('company_id', auth('contact')->user()->company->id)
|
->where('client_id', auth('contact')->user()->client->id)
|
||||||
->whereIn('status_id', [RecurringInvoice::STATUS_PENDING, RecurringInvoice::STATUS_ACTIVE, RecurringInvoice::STATUS_COMPLETED])
|
->whereIn('status_id', [RecurringInvoice::STATUS_PENDING, RecurringInvoice::STATUS_ACTIVE, RecurringInvoice::STATUS_COMPLETED])
|
||||||
->orderBy('status_id', 'asc')
|
->orderBy('status_id', 'asc')
|
||||||
->with('client')
|
->with('client')
|
||||||
|
Loading…
Reference in New Issue
Block a user