feat: apply credit note to invoice module

This commit is contained in:
Ahmed Bouhuolia
2025-05-04 01:32:08 +02:00
parent 1d53063e09
commit 4f6ad2b293
28 changed files with 633 additions and 707 deletions

View File

@@ -4,8 +4,9 @@ import { Model, mixin } from 'objection';
// import CustomViewBaseModel from './CustomViewBaseModel';
// import ModelSearchable from './ModelSearchable';
import { BaseModel } from '@/models/Model';
import { CreditNote } from '@/modules/CreditNotes/models/CreditNote';
export class RefundCreditNote extends BaseModel{
export class RefundCreditNote extends BaseModel {
date: Date;
referenceNo: string;
amount: number;
@@ -14,12 +15,14 @@ export class RefundCreditNote extends BaseModel{
fromAccountId: number;
description: string;
creditNoteId: number;
userId?: number;
branchId?: number;
createdAt?: Date | null;
creditNote!: CreditNote;
/**
* Table name.
*/