我试图在运行时根据用户更改窗口小部件配置。我想用不同的促销子类型填充集合浏览器(这是我的要求的自定义类型)。对于某些用户,他们应该只看到某些促销类型,并且能够添加/删除这些类型。
<widget id="custombackoffice-search-init"
widgetDefinitionId="com.hybris.cockpitng.widgets.common.propextractor"
template="false" slotId="cockpitWidgetChildrenInvisible">
<setting key="expression">'Promotion'</setting>
<setting key="socketDataType_$T" type="String">java.lang.String</setting>
</widget>
<widget-connection sourceWidgetId="custombackoffice-search-init" outputId="genericOutput"
targetWidgetId="custombackoffice-collectionBrowser-fulltextsearch" inputId="type"/>
<widget-connection sourceWidgetId="custombackoffice-collectionBrowser-fulltextsearch" outputId="searchData"
targetWidgetId="custombackoffice-collectionBrowser-advancedsearchengine" inputId="searchData"/>
<widget-connection sourceWidgetId="custombackoffice-collectionBrowser-fulltextsearch" outputId="searchContextChanged"
targetWidgetId="custombackoffice-collectionBrowser-advancedsearchengine" inputId="changeSearchContext"/>
<widget-connection sourceWidgetId="custombackoffice-collectionBrowser-advancedsearchengine" outputId="pageable"
targetWidgetId="custombackoffice-collectionBrowser-browser" inputId="pageable"/>
是否可以将类型'Promotion'
配置为在运行时具有不同的子类型,或者为每个用户预先配置不同的配置。我知道我可以使用searchRestrictions限制数据,但是仅使用搜索限制会影响* backoffice-listviewactions。仅当用户对配置的类型(例如, “促销”。