Changed the for-product route to for-sku to reduce ambiguity

This commit is contained in:
2026-01-29 16:23:07 +00:00
parent c65517b377
commit b79af6e1c6
2 changed files with 3 additions and 3 deletions

View File

@ -190,7 +190,7 @@ def show_list(
return modifier_categories
@router.get("/for-product/{sku_id}")
@router.get("/for-sku/{sku_id}")
def for_product(
sku_id: uuid.UUID,
date_: date = Depends(effective_date),

View File

@ -32,9 +32,9 @@ export class ModifierCategoryService {
.pipe(catchError(this.log.handleError(serviceName, 'list'))) as Observable<ModifierCategory[]>;
}
listForSku(id: string): Observable<ModifierCategory[]> {
listForSku(sku_id: string): Observable<ModifierCategory[]> {
return this.http
.get<ModifierCategory[]>(`${url}/for-product/${id}`)
.get<ModifierCategory[]>(`${url}/for-sku/${sku_id}`)
.pipe(catchError(this.log.handleError(serviceName, 'listForSku'))) as Observable<ModifierCategory[]>;
}