Feature: Sale Category also shows the products in it to make it easier to check for errors.

This commit is contained in:
2021-08-06 08:23:36 +05:30
parent 0b3ec5da16
commit 2f440a4127
8 changed files with 260 additions and 96 deletions

View File

@ -30,6 +30,15 @@ export class ProductService {
.pipe(catchError(this.log.handleError(serviceName, 'list'))) as Observable<Product[]>;
}
listOfSaleCategory(id: string): Observable<Product[]> {
const options = { params: new HttpParams().set('sc', id) };
return this.http
.get<Product[]>(`${url}/query`, options)
.pipe(catchError(this.log.handleError(serviceName, 'listOfSaleCategory'))) as Observable<
Product[]
>;
}
listIsActiveOfCategory(id: string): Observable<Product[]> {
const options = { params: new HttpParams().set('mc', id) };
return this.http