Valmik
Valmik

Reputation: 11

Broadleaf Commerce Admin Module Composite ID

Hi I am new to Broadleaf. I am using broadleaf version 3.0.5. I am working on the admin module of broadleaf commerce and I have a table which is consisting of composite key (which contains merchant_id and phone_number).

It does not contain any other field like "id".

In the grid broadleaf displays the "id" field which is blank because my table does not have this.

And it shows the link on the phone_number in the grid when I click on it, null is appended to the url and I get the blank page.

Please suggest me some solution to work with composite key situation.

Upvotes: 0

Views: 120

Answers (1)

phillipuniverse
phillipuniverse

Reputation: 2045

The Broadleaf admin does not currently work with composite primary keys. I would suggest making a separate column for a primary key (just a Long like the one in BLC_PRODUCT/ProductImpl) and then adding a UNIQUE CONSTRAINT on the 2 columns that you need it for.

Upvotes: 0

Related Questions