refactor: stats missing and new tab
This commit is contained in:
parent
453252c4be
commit
448d9156f9
6 changed files with 55 additions and 54 deletions
|
|
@ -26,7 +26,7 @@ export async function getDebitNoteList(params?: {
|
|||
page?: number;
|
||||
pageSize?: number;
|
||||
query?: string;
|
||||
deebitNoteStatus?: Status;
|
||||
status?: Status;
|
||||
includeRegisteredBranch?: boolean;
|
||||
}) {
|
||||
const res = await api.get<PaginationResult<Data>>(`/${ENDPOINT}`, {
|
||||
|
|
@ -66,12 +66,11 @@ export const useDebitNote = defineStore('debit-note-store', () => {
|
|||
const page = ref<number>(1);
|
||||
const pageMax = ref<number>(1);
|
||||
const pageSize = ref<number>(30);
|
||||
const stats = ref<Record<Status, number>>({
|
||||
[Status.Pending]: 0,
|
||||
[Status.Expire]: 0,
|
||||
[Status.Payment]: 0,
|
||||
[Status.Receipt]: 0,
|
||||
[Status.Succeed]: 0,
|
||||
const stats = ref<Record<string, number>>({
|
||||
['issued']: 0,
|
||||
['paymentPending']: 0,
|
||||
['paymentSuccess']: 0,
|
||||
['processComplete']: 0,
|
||||
});
|
||||
|
||||
return {
|
||||
|
|
|
|||
|
|
@ -86,9 +86,9 @@ export type DebitNote = {
|
|||
};
|
||||
|
||||
export enum DebitNoteStatus {
|
||||
Pending = 'Pending',
|
||||
Expire = 'Expire',
|
||||
Payment = 'Payment',
|
||||
Receipt = 'Receipt',
|
||||
Succeed = 'Succeed',
|
||||
Issued = 'Issued',
|
||||
Expired = 'Expired',
|
||||
PaymentPending = 'PaymentPending',
|
||||
PaymentSuccess = 'PaymentSuccess',
|
||||
ProcessComplete = 'ProcessComplete',
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue