cancel
Showing results for 
Search instead for 
Did you mean: 

sap.fe v4 Multiple Views on List Report Tables

hschaefer123
Participant

Hi,

trying to use multiple view on list report, i ran into a SAP Fiori Tools bug and created an issue for it:

31626 / 2021 SAP Fiori Tools removes used code from manifest

Also, the SAPUI5 SDK links for this currently lacks of content (or issue?):

https://sapui5.hana.ondemand.com/#/topic/0d390fed360c4c58a0f0619338938de1

https://sapui5.hana.ondemand.com/#/topic/37aeed74e17a42caa2cba3123f0c15fc

but i got it running,using using a manifest.json like this

"views": {
  "showCounts": true,
  "paths": [{
    "key": "tab1",
    "annotationPath": "com.sap.vocabularies.UI.v1.SelectionVariant#Offer"
  }, {
    "key": "tab2",
    "annotationPath": "com.sap.vocabularies.UI.v1.SelectionVariant#All"
  }]
}...

Generelly i would like to do this without tabs using the SegmentButton, but currently the docu lacks how to do this.

My question and problem is, that the used filters in the SelectionVariant are removed from FilterBar

        SelectionVariant #Open                 : {
            Text          : '{i18n>OpenView}',
            SelectOptions : [{
                $Type        : 'UI.SelectOptionType',
                PropertyName : status_code,
                Ranges       : [{
                    $Type  : 'UI.SelectionRangeType',
                    Option : #LT,
                    Low    : 11,
                    Sign   : #I
                }]
            }]
        }

using something like this, the former available status_code filter with a valuehelp will not be shown anymore.

If i read the documentation right, this should not be the case. I would expect, that the filter in the filter bar will just use/show the applied filter.

Is this the intended behavior of the filter view, to remove used filters, a missuse from my side or maybe a bug.

I was also adding the **Sign** annotation to get rid ofd the tooling warning from the SAP Fiori Tools. All the SDK docus do not use it and i think **I** option will be the default. Maybe that needs to be addressed to the tooling.

This behavior is not only affecting ranges, using another view like

SelectionVariant #HighPrio             : {
            Text          : '{i18n>HighPriorityView}',
            SelectOptions : [{
                $Type        : 'UI.SelectOptionType',
                PropertyName : priority_code,
                Ranges       : [{
                    $Type  : 'UI.SelectionRangeType',
                    Option : #EQ,
                    Low    : 3,
                    Sign   : #I
                }]
            }]
        },

also the **priority_code** filter will be removed from FilterBar.

**Questions:**

1) If this behavior is intended, is it possible to use multiple views while still showing all SelectionFields on the ListReport FilterBar in MulipleTableMode?

2) How can i use SingleTableMode for this (or is this maybe currently not supported with SAPUI5 1.85.x)?

Best Regards

Holger

Accepted Solutions (1)

Accepted Solutions (1)

hschaefer123
Participant
0 Kudos

In the meantime, found a solution for the SingleTableMode using

"controlConfiguration": {
  "@com.sap.vocabularies.UI.v1.LineItem": {
    "tableSettings": {
      "quickVariantSelection": {
        "paths": [...]

instead views.path (thanks to the Service Modeler),

but still do not understand the rules, when and why a filter will be removed from FilterBar.

Answers (2)

Answers (2)

edepuiffe
Discoverer

Hi Holger,

The complete documentation on this topic will be available from Thursday (28 Jan) along with the 1.86 version of the SDK documentation.

Please contact me if you need further details on how and when to implement each case.

The behaviour of removing the tab filters from the filter tab is intended, to avoid to have different values that contradict the tab filters, and finally end up with no values in the table. The filters defined on your tabs should be sufficient for the end user, who shouldn't need to set additional filter on the same property.

Best Regards,
Estelle.

hschaefer123
Participant
0 Kudos

Hi Estelle,
thanks for the explanation!

Concerning the removing of filters, maybe this can be also explained inside

https://sapui5.hana.ondemand.com/#/topic/b6b59e4a4c3548cf83ff9c3b955d3ba3

In my case, i have a filter for ProjectStatus and wanted to start view with Section "Open Requests" (similar to worklist which is not avaialble for v4) and a second view "All Requests".

In this case, the ProjectStatus ValueHelp filter will be removed from FilterBar and i am no more able to filter on multiple ProjectStatus, which is important for the usability, so i can not use the multiple view features for this.

Even for my use case, using SelectionVariants as hard filters on view besides addtional custom filters for same property would make sense from my point of view (maybe configurable), in case of above scenario.

Best Regards
Holger

stefan_schreck
Participant
0 Kudos

Note that the issue mentioned at the beginning (31626 / 2021 SAP Fiori Tools removes used code from manifest) is solved meanwhile by the latest version of https://www.npmjs.com/package/@sap/ux-specification <8as confirmed by Holger).
So, if you face a similar problem (concerning the V4 views), please apply the new version to your app, by using npm install (check the Readme and the given versions at npmjs).

hschaefer123
Participant
0 Kudos

Hi Stefan,
thanks for the quick fix solution!

Makes the annoying loss of data gone.

Best Regards
Holger