在 Hybris 5.3 的现有类型中添加新属性未显示在 HMC 和 HAC 中

Adding New attribute in a existing type in Hybris 5.3 is not showing in HMC and HAC

我在一个现有类型中添加了一个新属性。我的属性在模型 class 和 jalo classes 中可用。 但是当我签入 HMC 时,它没有在管理选项卡中显示该属性。 以及类型的 XML 配置在 HMC 中没有该属性。

我完成的步骤: 在 items.xml 中添加了我的属性,其中其他属性也较早添加。 在此之后我让 运行 ant clean all 并检查了模型 class 并且属性在模型 class.

使用下面的代码在 items.xml 中添加我的属性:

<itemtype code="Customer" autocreate="false" generate="false">
            <attributes>
<attribute qualifier="OosFlag" type="java.lang.Boolean">
                    <description>OosFlag</description>
                    <defaultvalue>Boolean.TRUE</defaultvalue>
                    <modifiers read="true" write="true" search="true" optional="false"/>
                    <persistence type="property"/>
                </attribute>
            </attributes>
            </itemtype>

您需要更新数据库中的类型系统。这意味着您需要在管理控制台中进行更新。

生成的类只是模板。重要的一点是数据库中的内容。

P.S。您应该始终以小​​写字母开头您的属性。