Hybris插件安装概念 [英] Hybris addons install concept

查看:122
本文介绍了Hybris插件安装概念的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何使用默认Hybris addon的最佳方法是什么?我们希望在项目中使用一些非常不错的插件功能,但是当然不完全是它们的方式.那么修改它们的最佳实践是什么?

How is the best way to work with a default Hybris addon? There are some really nice addon features we want to use in our projects, but of course not exactly the way they are. So what is the best practice to modify them?

是否可以将插件复制到自己的项目中,然后将其作为自己的插件处理? (因此,将其放在自定义"文件夹下,并根据需要对其进行修改)

Is it the way to copy the addon into the own project and then handle it as an own addon? (So put it under the 'custom' folder and modify it as needed)

推荐答案

使用Hybris中的默认插件的最佳方法是什么?

How is the best way to work with a default addon from hybris?

附加组件用于扩展Hybris平台功能,而无需 更改其源代码,它们是标准扩展,所以, 我认为最好的方法是创建自己的插件,因此您可以保留自己的 独立于Hybris业务逻辑的代码,并为将来的发展模块化. 通常,SAP Hybris建议在不修改代码的情况下对其代码进行扩展.

Addons are used to extend Hybris platform functionalities without changing its source code, they are standard extensions, So, I think that the best way is to create your own addon, so you keep your code independent of Hybris business logic and modular for future evolution. In general SAP Hybris recommends the extension of its code without modifying it.

在扩展程序上安装插件会发生什么?

What exactly happens by installing an addon on an extension?

执行以下命令:

ant addoninstall -Daddonnames="myAddOn" -DaddonStorefront.yacceleratorstorefront="myStorefront"

ant addoninstall将:

ant addoninstall will :

  • 根据需要将myAddOn添加到extensioninfo.xml中 对于myStorefront扩展
  • 将myAddOn添加到myStorefront的addons.less中
  • 从myAddOn内的project.properties.template生成新的project.properties文件.
  • 配置myAddOn Web Spring配置 将myAddOn-web-spring.xml转换为myStorefront.additionalWebSpringConfigs
  • Add myAddOn into extensioninfo.xml as required for myStorefront extension
  • Add myAddOn to addons.less for myStorefront
  • Generate a new project.properties file from the project.properties.template inside myAddOn.
  • Configure the myAddOn web spring configuration myAddOn-web-spring.xml into myStorefront.additionalWebSpringConfigs

当需要卸载插件时,是否需要使用卸载 命令?

When need to uninstall an addon, does it need to use the uninstall command?

是的,您需要执行ant addonuninstall才能回滚第二个响应中列出的操作.

Yes, you need to execute ant addonuninstall in order to rollback the actions listed in the second response.

这篇关于Hybris插件安装概念的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆