Andrew Wallo 5 months ago
parent
commit
1782273d18
1 changed files with 2 additions and 12 deletions
  1. 2
    12
      app/Enums/Accounting/DocumentType.php

+ 2
- 12
app/Enums/Accounting/DocumentType.php View File

13
     case Bill = 'bill';
13
     case Bill = 'bill';
14
     case Estimate = 'estimate';
14
     case Estimate = 'estimate';
15
     case RecurringInvoice = 'recurring_invoice';
15
     case RecurringInvoice = 'recurring_invoice';
16
-    case CreditNote = 'credit_note';
17
 
16
 
18
     public const DEFAULT = self::Invoice->value;
17
     public const DEFAULT = self::Invoice->value;
19
 
18
 
22
         return match ($this) {
21
         return match ($this) {
23
             self::Invoice, self::Bill, self::Estimate => $this->name,
22
             self::Invoice, self::Bill, self::Estimate => $this->name,
24
             self::RecurringInvoice => 'Recurring Invoice',
23
             self::RecurringInvoice => 'Recurring Invoice',
25
-            self::CreditNote => 'Credit Note',
26
         };
24
         };
27
     }
25
     }
28
 
26
 
43
     public function getTaxKey(): string
41
     public function getTaxKey(): string
44
     {
42
     {
45
         return match ($this) {
43
         return match ($this) {
46
-            self::Invoice, self::RecurringInvoice, self::Estimate, self::CreditNote => 'salesTaxes',
44
+            self::Invoice, self::RecurringInvoice, self::Estimate => 'salesTaxes',
47
             self::Bill => 'purchaseTaxes',
45
             self::Bill => 'purchaseTaxes',
48
         };
46
         };
49
     }
47
     }
51
     public function getDiscountKey(): string
49
     public function getDiscountKey(): string
52
     {
50
     {
53
         return match ($this) {
51
         return match ($this) {
54
-            self::Invoice, self::RecurringInvoice, self::Estimate, self::CreditNote => 'salesDiscounts',
52
+            self::Invoice, self::RecurringInvoice, self::Estimate => 'salesDiscounts',
55
             self::Bill => 'purchaseDiscounts',
53
             self::Bill => 'purchaseDiscounts',
56
         };
54
         };
57
     }
55
     }
67
                 dueDate: 'Payment Due',
65
                 dueDate: 'Payment Due',
68
                 amountDue: 'Amount Due',
66
                 amountDue: 'Amount Due',
69
             ),
67
             ),
70
-            self::CreditNote => new DocumentLabelDTO(
71
-                title: self::CreditNote->getLabel(),
72
-                number: 'Credit Note Number',
73
-                referenceNumber: 'P.O/S.O Number',
74
-                date: 'Credit Note Date',
75
-                dueDate: 'Payment Due',
76
-                amountDue: 'Amount Due',
77
-            ),
78
             self::RecurringInvoice => new DocumentLabelDTO(
68
             self::RecurringInvoice => new DocumentLabelDTO(
79
                 title: self::RecurringInvoice->getLabel(),
69
                 title: self::RecurringInvoice->getLabel(),
80
                 number: 'Invoice Number',
70
                 number: 'Invoice Number',

Loading…
Cancel
Save