cancel
Showing results for 
Search instead for 
Did you mean: 

Backoffice advanced search mode by default

0 Kudos

Is there a way to display the Advanced Search widget for a particular type in advanced-search mode by default (including the search fields already visible)?

I am trying this:

 <context type="SomeType" component="advanced-search" merge-by="type" module="some-extension">
     <as:advanced-search disable-simple-search="true" disable-auto-search="true" xmlns:as="http://www.hybris.com/cockpitng/config/advancedsearch" xmlns="http://www.hybris.com/cockpitng/config/advancedsearch">
         <field-list>
             <field name="someAttribute" selected="true"/>
             <field editor="java.lang.Long" name="pk" selected="false"/>
         </field-list>
     </as:advanced-search>
 </context>

With that, the advanced search doesn't let enter a search text (which I understand as "simple-search" mode), which is at least something.
But I still have to click the "looking glass" button in order to expand the panel that contains the field someAttribute.
I think that, as we have explicitly indicated that we want advanced-search mode, these fields should be directly visible by default, shouldn't they? Any ideas?

Cheers,
Carlos

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member632755
Active Contributor
0 Kudos

Hi,

as you noticed the advanced search is activated but not expanded. I find it to be a functional bug and I will raise a ticket for the issue.

If you need to have the fix applied on your version or if a workaround is needed please get in touch with our support.

Cheers, Wojtek

Former Member
0 Kudos

Thanks Wojciech,

So in the case of enableNestedWidgetView it seems to be a bug. But while using displayInNonCollapsibleContainer the advanced search is expanded also search works fine. However I don't understand the reason behind the message on top as shown in above comment. Is it possible to remove that message?

Thanks, Sujitha

0 Kudos

thank you for your reply!
That would make the search fields visible for all types.
I was seeking more to a way to make the search fields visible for a particular type.

Cheers,
Carlos

Former Member
0 Kudos

, Since the setting is global and i guess "disable-simple-search="true" doesn't display the advance search dialog. The possible approach will be changing the setting run time extending the com.hybris.backoffice.widgets.advancedsearch.AdvancedSearchController and during initialize() , check for the TypeCode and change the settings using widgetInstanceManager, widgetInstanceManager.getWidgetSettings().put(AdvancedSearchController .Enable_Nested_Widget_View, Boolean.FALSE); Thanks Seb

Former Member
0 Kudos

, While making enableNestedWidgetView property false, the search doesn't work. Search results are not retrieved neither for autosearch nor on button click.

Actually, I want to make advanced search as default and expanded by default. above option didn't work. As well when enabled property displayInNonCollapsibleContainer there is a warning message display on top of search option.

Any idea on this?

Thanks, Sujitha