Hide rows in Datagrid based on column value - react-admin

I have a Datagrid and one of the columns is inactive which is either null or contains a string with the date the row was set to inactive. Most of the rows in the Datagrid are null, but a few of the rows have a date in the inactive column. I'd like to hide the inactive records in the Datagrid, but not sure how to do this?

You could do it on List:
... <List filter={{inactive:false}}> <Datagrid> ... </Datagrid> </List> ...

Related

Building a conditional statement for a calculated field

I have a form with a subform inside with logistic purchase information in several fields. So one field is called PURCHASEid (with the purchase number), another combobox field is called PICKINGCODE and its values can be A, B or C. Then I have another fields called BOXES SUM and PALLETS NUMBER I would like It to work as follows:
When PICKINGCODE field value is A, PALLETS NUMBER value can be filled by typing a number.
When PICKINGCODE field value is B or C:
o PALLETS NUMBER value will be the 1/count of fields that have B value in PICKINGCODE field.
For example for PURCHASEid “4” and 2 records with “B” PICKINGCODE value, I would like to have “0,5” PALLETNUMBER value for both records
In the subform event Afterupdate I wrote:
If Me. PICKINGCODE.Value = "A" Then
Me. [PALLET NUMBER].Value = "*"
Else Me. [PALLETS NUMBER].Value = 1 / acAggregateCount([&PICKINGCODE])
But I know at least the last statement It’s wrong. Could you please help me to build it? I wrote acAggregateCount([&PALETPICKINGCOD]) to count records in a given purchase with the same PALETPICKINGCOD value of the record selected.
Thanks in advance

remove duplicate values from record by removing dropdown value after selection

I have one dropdown in my form .....
if we click dropdown and it shows vales like 1
2
3
4 etc
I select value (1) in dropdown and saved those values in table successfully.
i need to remove the selected value**(1)** from dropdown after saved those values in table ....
If we click the dropdown again....I need the below result.....
I need result like 2
3
4
value 1 have to remove from the dropdown...How?

Changing row color based on value in a table

I need to change the color of a row based on the value I have being stored in a table. I have a 1 row 1 column table that contains the average run time of any selected report based off its last 30 runs. I would like to color the row green if the report runs in a given proximity of this value and red otherwise. How would I go about writing the IIF for this in SSRS?
Your IIF code is going to look something like this to have a criteria to change the color of the fields.
IIF(Fields!RunTime.value < AllowableValue,"Green","Red")

How to customize the entries rows of Table Component in CDE PENTAHO?

I have 12 rows in my resultset which I am rendering in the table component in CDE Pentaho. By default 10 entries is shown and next 2 rows goes to next page and for two rows i need to use pagination. My question is how to make by default show rows customize and show 20 rows by default. I want all my rows seen at once in first page. No need of pagination or next to see remaining 2 rows.
Set 'Page length' in advanced properties of the table

DAX - selecting rows with partial match

I have a powerpivot table that contains 2 columns:
Column 1 contains strings.
Column 2 contains comma delimited strings.
I would like to be able to display all the rows from column 1 when rows from column 2 contains the selection from a filter or slicer. For example:
String Values
ABCD A,A,B
EFGH A,C
if A is selected I would display both rows, if B is selected I would display only row 1...etc.
I know I can split the records - but this is not practical for me - the above is only the top of the iceberg. VBA is out of the question since this will published in SharePoint. Anybody has an idea on how I could do that ? Thanks.
I found the solution in a blog from Javier Guillem:
http://javierguillen.wordpress.com/2012/02/10/simulating-an-approximate-match-vlookup-in-powerpivot/
If in my example the name of the table is "facts", I create a second unlinked table called dimRef that I populate with all possible values that I am interested to match: A,B,C,D...etc.
Then I define the measure M as:
M:=If ( Hasonevalue(facts[Values] ),
Calculate (
LASTNONBLANK (dimRef[String], 1 ),
Filter ( dimRef, SEARCH(dimRef[String],Values(facts[String]),1,0) > 0 )
)
)
I can then use the string column of the facts table and the measure in a pivot table and use dimRef as a selector. If filters the row as per the selection.
One small detail: the measure is not available in PowerView...Anybody knows why ?