When i navigate to Catalog -> Categories in Admin site all Categories appears in a table with Name and Url columns all i want to do is to add the Category id in a new column.
Actually i followed this documentation http://www.broadleafcommerce.com/docs/core/current/broadleaf-concepts/admin/admin-metadata-overrides and i used XML-based overrides method:
I added this to my applicationContext:
Code: Select all
<beans xmlns="http://www.springframework.org/schema/beans"
...
...
...
xmlns:mo="http://schema.broadleafcommerce.org/mo"
...
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.2.xsd
...
...
http://schema.broadleafcommerce.org/mo
http://schema.broadleafcommerce.org/mo/mo-3.0.xsd">
and i added this overrides as well in applicationContext:
Code: Select all
<mo:override id="blMetadataOverrides">
<mo:overrideItem ceilingEntity="org.broadleafcommerce.core.catalog.domain.Category">
<mo:field name="url">
<mo:property name="friendlyName" value="CategoryUrl" />
<mo:property name="prominent" value="false" />
<mo:property name="excluded" value="true" />
</mo:field>
<mo:field name="id">
<mo:property name="visibility" value="VISIBLE_ALL" />
<mo:property name="friendlyName" value="CategoryId" />
<mo:property name="prominent" value="true" />
<mo:property name="excluded" value="false" />
</mo:field>
</mo:overrideItem>
</mo:override>
The result is id field is not displayed as column in Category table but i was able to hide url column.
How can i do that displaying id column in Category table?
Thanks.