我正在尝试重写一个有bean的backoffice类,但它是在一个web上下文中。
在我们的项目中,我们已经有了一个自定义的backoffice包,但是没有spring.xml。此外,该包中的其他类都没有任何bean。
更具体地说,我正在尝试重写这个类:hybris/bin/ext-backoffice/backoffice/web/webroot/WEB-INF/classes/com/hybris/backoffice/widgets/searchadapters/conditions/products/FlexibleSearchUncategorizedConditionAdapter.class。
我们的后台扩展如下所示:
├── backoffice <-- webroot
│ ├── resources
│ │ └── widgets
│ │ ├── projectbackofficeWidget
│ │ │ ├── definition.xml
│ │ │ ├── images
│ │ │ │ └── ...
│ │ │ ├── labels
│ │ │ │ └── ...
│ │ │ ├── projectbackofficewidget.scss
│ │ │ └── projectbackofficewidget.zul
│ │ └── actions
│ │ └── ...
│ ├── src
│ │ └── de
│ │ └── company
│ │ └── project
│ │ └── backoffice
│ │ ├── b2bcommerce
│ │ │ └── actions
│ │ │ └── ...
│ │ ├── editors
│ │ │ └── ...
│ │ ├── services
│ │ │ └── ...
│ │ └── widgets
│ │ ├── ...
│ │ └── searchadapters
│ │ └── myFlexibleSearchUncategorizedConditionAdapter.java
│ └── testsrc
│ └── ...
├── build.xml
├── buildcallbacks.xml
├── extensioninfo.xml
├── extensioninfo.xsd
├── gensrc
│ └── ...
├── platformhome.properties
├── project.properties
├── resources
│ ├── backoffice
│ │ └── projectbackoffice_bof.jar
│ ├── beans.xsd
│ ├── cockpitng
│ │ └── ...
│ ├── items.xsd
│ ├── projectbackoffice
│ │ ├── projectbackoffice-testclasses.xml
│ │ └── projectbackoffice-webtestclasses.xml
│ ├── projectbackoffice-backoffice-config.xml
│ ├── projectbackoffice-backoffice-labels
│ │ └── ...
│ ├── projectbackoffice-backoffice-spring.xml
│ ├── projectbackoffice-backoffice-widgets.xml
│ ├── projectbackoffice-beans.xml
│ ├── projectbackoffice-items.xml
│ ├── projectbackoffice-spring.xml
│ ├── projectbackoffice.build.number
│ └── localization
│ └── ...
├── src
│ └── de
│ └── company
│ └── project
│ └── backoffice
│ ├── projectbackofficeStandalone.java
│ ├── constants
│ │ └── projectbackofficeConstants.java
│ └── jalo
│ └── projectbackofficeManager.java
└── testsrc
└── ...我知道有一个spring.xml,但它不能与webroot中的类一起工作。在所有其他web扩展中,都有单独的文件用于此。
如何添加spring.xml以便可以覆盖OOTB bean?或者,我如何使用现有的spring.xml来实现这一点?
https://stackoverflow.com/questions/68115946
复制相似问题