Hybris辅助服务模块

Hybris辅助服务模块

本文介绍了SAP Hybris辅助服务模块(ASM)-无法生成组件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经在本地主机上成功安装并测试了ASM(我们使用Hybris 1811).然后,我想在我们的开发服务器上传输它(实际上只是在localextensions.xml中进行了更改并重新生成了extensionsinfo.xml),因此在我的店面的extensionsinfo.xml中,有一个注册的插件,如下所示:

I've installed and tested ASM on my localhost successfully (we use Hybris 1811). Then I wanted to transfer it on our dev server (actually it was only changes in localextensions.xml and regenerated extensionsinfo.xml), so in extensionsinfo.xml of my storefront there is the addon registrated like this:

<requires-extension name="assistedservicestorefront "/>

但是它不会在视图中生成文件:

But it doesn't generate files in views:

[DefaultCMSComponentRendererRegistry] Error processing component tag. currentComponent [AssistedServiceComponentModel (8796814312508@2)] exception:
File [&#47;WEB-INF&#47;views&#47;responsive&#47;cms&#47;assistedservicecomponent.jsp] not found

我已经导入了与安装ASM手册中相同的.impex文件(来自help.hybris.com)和本地主机上的.impex文件(包含组件和Jsp的cms-content.impex).

I've imported the same .impex file as in the manual for installing ASM (from help.hybris.com) and as on the localhost (cms-content.impex to include component and Jsp).

即使我在HAC中运行更新,我仍然尝试同步内容目录.我在HAC中检查了扩展名,它包含与本地计算机上相同的ASM扩展名:assistedservicefacadesassistedserviceservicesassistedservicestorefront.当我检查后台时,具有该ID的组件确实存在,并且位于在线目录中.

Even though I run update in HAC, I tried to sync content catalog. I checked extensions in HAC, it contains same ASM extensions as on my local machine: assistedservicefacades, assistedserviceservices, assistedservicestorefront.When I checked the backoffice, the component with that ID is really there and it's in online catalog.

如何使这些文件生成?还是应该以我的自定义视图以某种方式覆盖它们?但是我认为这将是一个糟糕的方法.

How do I make those files to generate? Or should I somehow override them with my custom views? But I think it would be bad approach.

更新:我还试图将此条目添加到店面的project.properties中:

UPDATE: I also tried to add this entry to project.properties of my storefront:

sikob2cstorefront.additionalWebSpringConfigs.assistedservicestorefront=classpath\:/assistedservicestorefront/web/spring/assistedservicestorefront-web-spring.xml

但随后出现加载bean的错误:

but then I got the error loading beans:

Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'defaultStorefrontTenantDefaultFilterChainList': Post-processing of FactoryBean's singleton object failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'AssistedservicestorefrontFilterListMergeDirective' defined in class path resource [assistedservicestorefront/web/spring/assistedservicestorefront-web-spring.xml]: Cannot resolve reference to bean 'assistedServiceFilter' while setting add; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'assistedServiceFilter' defined in class path resource [assistedservicestorefront/web/spring/assistedservicestorefront-web-spring.xml]: Cannot resolve reference to bean 'assistedServicePathRestrictionEvaluator' while setting bean property 'assistedServicePathRestrictionEvaluator'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No bean named 'assistedServicePathRestrictionEvaluator' available

推荐答案

# Install assistedservicestorefront
# Replace Mystorefront with your storefront extension name
ant addoninstall -Daddonnames="assistedservicestorefront" -DaddonStorefront.yacceleratorstorefront="Mystorefront"

我认为您错过了安装Assistantservicestorefront附加组件,或者如果已经安装,请检查服务器上是否进行了以下更改.

I think you have missed installing the assistedservicestorefront addon or if you've already installed then check whether below changes have taken place on your server.

  • 将辅助服务店面添加到店面扩展的extensioninfo.xml中

  • Adds assistedservicestorefront into extensioninfo.xml of your storefront extension

喜欢<requires-extension name="assistedservicestorefront "/>

在辅助服务店面内的 project.properties.template 中生成一个新的 project.properties 文件,该文件具有以下条目.

Generate a new project.properties file from project.properties.template inside assistedservicestorefront, which has following entries.

在以下属性中,用店面扩展名替换 yacceleratorstorefront .

Replace yacceleratorstorefront with your storefront extension name in the below property.

#Specifies the location of the spring context file added automatically to the global platform application context.
assistedservicestorefront.application-context=assistedservicestorefront-spring.xml

yacceleratorstorefront.additionalWebSpringConfigs.assistedservicestorefront=classpath:/assistedservicestorefront/web/spring/assistedservicestorefront-web-spring.xml


assistedservicestorefront.javascript.paths.mobile=/responsive/common/js/assistedservicestorefront.js;/responsive/common/js/jquery.tablesorter.pager.js;/responsive/common/js/jquery.tablesorter.min.js;/responsive/common/js/Chart.min.js;/responsive/common/js/asm.storefinder.js
assistedservicestorefront.javascript.paths.responsive=/responsive/common/js/assistedservicestorefront.js;/responsive/common/js/jquery.tablesorter.pager.js;/responsive/common/js/jquery.tablesorter.min.js;/responsive/common/js/Chart.min.js;/responsive/common/js/asm.storefinder.js

assistedservicestorefront.css.paths.mobile=/responsive/common/css/assistedservicestorefront.css;/responsive/common/css/storeFinder.css;/responsive/common/css/customer360.css
assistedservicestorefront.css.paths.responsive=/responsive/common/css/assistedservicestorefront.css;/responsive/common/css/storeFinder.css;/responsive/common/css/customer360.css

assistedservicestorefront.redirect.customer_and_cart=/cart
assistedservicestorefront.redirect.customer_only=/my-account
assistedservicestorefront.redirect.error=/
assistedservicestorefront.redirect.order=/my-account/order/%s

assistedservicestorefront.deeplink.link=/assisted-service/emulate

cscokpit.assistedservice.deeplink=true
assistedservicestorefront.profile.cookie.name=profile.tracking.pause

#AIF AJAX call timeout in milliseconds
assistedservicestorefront.aif.timeout=7000

因此,如果您不想在每个环境中都运行addoninstall命令,则可以手动进行这两个更改.您可以引用插件中生成的project.properties文件,并将所有这些属性复制到店面的project.properties或local.properteis文件中,然后提交更改.

So if you don't want to run addoninstall command in each environment then you can manually do these two changes. You can refer to the generated project.properties file inside your addon and copy all those properties to your storefront's project.properties or local.properteis file and commit the changes.

这篇关于SAP Hybris辅助服务模块(ASM)-无法生成组件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-13 11:38