New grid - Filter the display

Hi,

I’m a functional guy trying to figure out how to create a new grid.
I managed to copy/change the grid for detailed lines of invoices.

I would like to filter the display to only show the invoices with status « ventilated ». I have no need to cancelled and draft invoices in my new grid.

I tried many things but nothing worked :frowning:
My last try is expr= « invoice.statusSelect : 2 »

That’s my code below, what should I change please?

Thanks very much for your help.

1 « J'aime »

Hi
See the attached iages one show grid to display only archived Leave Requests
Other image show the action, see « domain » :
(self.statusSelect = 3 OR self.statusSelect = 4) and self.archived = true

Show only for status 3 and 4 and archived only

Let me now if it works


1 « J'aime »

I came to reply but you already did, you so cool @fabiobottan

1 « J'aime »

Hey lads,

Thanks for your help but I still can’t make it work…
I want to filter all invoices lines where invoice status = 3 (« validated »).

I have the following dashlet in a dashboard:

And then I tried to follow your advices. I created a view:

And an action:

This is the invoiceLine model:

And the invoice model :

What am I missing please? Hopefully it’s a quick one for you.

Thanks

Vincent

1 « J'aime »

Hi Vincent
The only thing looks wrong to me is the domain condition should be
self.status = 3
Or you are filtering the wrong model
Also check
invoice-line-menu-grid should be invoice-line-menu-grid2 for the action

self.invoiceLine.status → looks wrong you are using invoiceLine as model so « self » is the actual invoice line

Hello,

In you action-view, the title is wrong in xml « action-customer-invoice-line-menu » instead of « action-customer-invoice-line-menu2 » that is called in the dashlet.

The domain self.invoice.statusSlect = 3 seems good.

Regards

1 « J'aime »

Hi,
Thanks again for your help.
I couldn’t change the action name so I created a new action 3.

That’s the dashlet:

That’s the action:

I tried with capital « I » or small « I » in self.invoice.statusSelect but it still doesn’t work :frowning:

The invoice lines grid is still not filtering the status 3.

@fabiobottan the status is on the invoice model, not on the invoice-line model that’s why I used self.invoice.statusSelect =3

Thanks

Vincent

Hello,

I just create the same case and it works fine with the same action-view.

So, I think the dashlet doesn’t call the right view. Can you share the way you use to define your dashlet.

Regards

Hi,

I went to dashboard builder:

image

Then I chose an app builder, a name and a tile:

Then I created this dashlet:

That’s my app builder:

Thanks very much again

Vincent