dashboard design
This commit is contained in:
@@ -4,10 +4,12 @@ import type {
|
||||
ShopPOResponse,
|
||||
InvoiceResponse,
|
||||
InvoiceStatus,
|
||||
PaymentStatus,
|
||||
PaymentResponse,
|
||||
PaymentMethod,
|
||||
EntryMode,
|
||||
ShopPOStatus,
|
||||
OutstandingPaymentsResponse,
|
||||
} from '@/types/api'
|
||||
|
||||
import type { PageParams } from './master'
|
||||
@@ -69,12 +71,16 @@ export interface InvoiceListParams extends PageParams {
|
||||
routeId?: string
|
||||
shopId?: string
|
||||
status?: InvoiceStatus
|
||||
paymentStatus?: PaymentStatus
|
||||
}
|
||||
|
||||
export const invoices = {
|
||||
list: (params?: InvoiceListParams) =>
|
||||
api.get<PaginatedResponse<InvoiceResponse>>('/invoices', { params }).then(r => r.data),
|
||||
|
||||
outstandingSummary: () =>
|
||||
api.get<OutstandingPaymentsResponse>('/invoices/outstanding-summary').then(r => r.data),
|
||||
|
||||
get: (id: string) =>
|
||||
api.get<InvoiceResponse>(`/invoices/${id}`).then(r => r.data),
|
||||
|
||||
|
||||
Reference in New Issue
Block a user