SoftwareBrothers / adminjs-sequelizejs

Sequelizejs adapter for AdminBro
MIT License
27 stars 34 forks source link

Array relations is not working #32

Closed themisir closed 4 years ago

themisir commented 4 years ago

I have 2 models which is related to each other.

Product.tsProductTranslation.ts
```js Product |-- Id: number |-- Price: number |-- Translations: Array ``` ```js ProductTranslation |-- LanguageId: string |-- ProductId: Product |-- Name: string ```

But I don't see translations array on create, edit or show page.

image

But when I check network traffic I see that there are already Translation fields responded from server.

image

I think the issue is related to sequelizejs adapter integration.

I want to achieve this structure:

image

wojtek-krysiak commented 4 years ago

I've just merged PR which adds arrays. You can try this out by installing latest versions of admin-bro-sequelize and admin-bro. Please let me know if that helped.

themisir commented 4 years ago

Thanks, I will check

wojtek-krysiak commented 4 years ago

it works so closing the issue

wojtek-krysiak commented 4 years ago

hmm - I am reading the docs and not necessarily it works. So arrays are handled but nested objects don't (in sequelize v5)

so let's leave this close but I will open another one for nested objects.

wojtek-krysiak commented 4 years ago

https://github.com/SoftwareBrothers/admin-bro-sequelizejs/issues/45

themisir commented 4 years ago

I'm sorry, I forgot about testing this. I had to write my own admin panel implementation since we needed more customizability and custom features. :/

wojtek-krysiak commented 4 years ago

I would love to hear about problems you had. Our goal is to create the best admin panel ever so every feedback is crucial. If you have couple of minutes you can hit me on AdminBro Slack Community: https://join.slack.com/t/adminbro/shared_invite/zt-czfb79t1-0U7pn_KCqd5Ts~lbJK0_RA and find me there