Feature: Open bill using bill number
This commit is contained in:
@ -50,6 +50,14 @@ export class VoucherService {
|
||||
) as Observable<Bill>;
|
||||
}
|
||||
|
||||
getFromBill(billId: string): Observable<Bill> {
|
||||
return this.http
|
||||
.get<Bill>(`${url}/from-bill/${billId}`)
|
||||
.pipe(
|
||||
catchError(this.log.handleError(serviceName, `getFromBill billId=${billId}`)),
|
||||
) as Observable<Bill>;
|
||||
}
|
||||
|
||||
save(
|
||||
voucher: Bill,
|
||||
voucherType: VoucherType,
|
||||
@ -179,8 +187,8 @@ export class VoucherService {
|
||||
) as Observable<boolean>;
|
||||
}
|
||||
|
||||
splitBill(id: string, inventoriesToMove: string[], table: Table) {
|
||||
const options = { params: new HttpParams().set('u', 'true') };
|
||||
splitBill(id: string, inventoriesToMove: string[], table: Table, updateTable: boolean) {
|
||||
const options = { params: new HttpParams().set('u', updateTable.toString()) };
|
||||
return this.http
|
||||
.post<boolean>(
|
||||
`${urlSplitBill}/${id}`,
|
||||
|
||||
Reference in New Issue
Block a user