Skip to content

Commit

Permalink
Merge pull request #57 from heseya/MPT-2740
Browse files Browse the repository at this point in the history
productSets lang
  • Loading branch information
KrystianEscolaSoft authored Nov 26, 2024
2 parents afcfa66 + 0e41bc6 commit 7e6efed
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion src/store/generator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,9 @@ export const createVuexCRUD =
commit(DefaultVuexMutation.SetError, null)
commit(DefaultVuexMutation.SetLoading, true)
try {
const stringQuery = stringifyQuery(assign({}, queryParams.getOne || {}))
const stringQuery = stringifyQuery(
assign({}, queryParams.getOne || {}, queryParams.get || {}),
)
const { data } = await api.get<{ data: Item }>(`/${endpoint}/id:${id}${stringQuery}`)
// @ts-ignore type is correct, but TS is screaming
commit(DefaultVuexMutation.SetSelected, data.data)
Expand Down
2 changes: 1 addition & 1 deletion src/store/productSets.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,5 +54,5 @@ export const productSets = createVuexCRUD<ProductSet, ProductSetCreateDto, Produ
},
},
},
{ get: { ...PARAM, with_translations: false }, edit: PARAM, update: PARAM, add: PARAM },
{ get: PARAM, edit: PARAM, update: PARAM, add: PARAM },
)

0 comments on commit 7e6efed

Please sign in to comment.