Skip to content

Commit

Permalink
Merge branch 'develop' into axios-version
Browse files Browse the repository at this point in the history
Signed-off-by: Turiiya <[email protected]>
  • Loading branch information
ttytm authored Aug 23, 2024
2 parents 6e912e3 + 83cf4ff commit 77d1836
Show file tree
Hide file tree
Showing 128 changed files with 24,116 additions and 1,926 deletions.
4 changes: 3 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,6 @@ VITE_ROUTER=browser

VITE_HOSTED_SHOW_SMTP_SETTINGS=true

VITE_DISABLE_PREVENT_NAVIGATION_FEATURE=true
VITE_DISABLE_PREVENT_NAVIGATION_FEATURE=true

VITE_ENABLE_PEPPOL_STANDARD=true
125 changes: 96 additions & 29 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
"mitt": "^3.0.1",
"playwright": "^1.44.0",
"pretty-bytes": "^6.0.0",
"randexp": "^0.5.3",
"react": "^18.2.0",
"react-colorful": "^5.6.1",
"react-date-range": "^1.4.0",
Expand Down
6 changes: 4 additions & 2 deletions src/common/hooks/money/useFormatMoney.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ export function useFormatMoney() {
value: string | number,
countryId: string | undefined,
currencyId: string | undefined,
fractionDigits?: number
fractionDigits?: number,
showCurrencyCode?: boolean
) => {
const currentCountryId = countryId || company?.settings.country_id;
const currentCurrencyId =
Expand All @@ -39,7 +40,8 @@ export function useFormatMoney() {
currency,
country,
{
showCurrencyCode: company.settings.show_currency_code,
showCurrencyCode:
showCurrencyCode ?? company.settings.show_currency_code,
}
);
}
Expand Down
2 changes: 2 additions & 0 deletions src/common/interfaces/company.interface.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
* @license https://www.elastic.co/licensing/elastic-license
*/

import { EInvoiceType } from '$app/pages/settings';
import { BankAccount } from './bank-accounts';
import { Document } from './document.interface';

Expand Down Expand Up @@ -76,6 +77,7 @@ export interface Company {
smtp_password: string;
smtp_local_domain: string;
smtp_verify_peer: boolean;
e_invoice?: EInvoiceType;
}

export interface Settings {
Expand Down
7 changes: 7 additions & 0 deletions src/common/interfaces/credit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,11 @@
*
* @license https://www.elastic.co/licensing/elastic-license
*/
import { EInvoiceType } from '$app/pages/settings';
import { Client } from './client';
import { Activity } from './invoice';
import { InvoiceItem } from './invoice-item';
import { Payment } from './payment';

export interface Credit {
id: string;
Expand Down Expand Up @@ -76,4 +79,8 @@ export interface Credit {
invitations: any[];
documents: any[];
client?: Client;
e_invoice?: EInvoiceType;
activities?: Activity[];
payments?: Payment[];
reminder_schedule?: string;
}
2 changes: 2 additions & 0 deletions src/common/interfaces/expense.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
* @license https://www.elastic.co/licensing/elastic-license
*/

import { EInvoiceType } from '$app/pages/settings';
import { Client } from './client';
import { ExpenseCategory } from './expense-category';
import { Invoice } from './invoice';
Expand Down Expand Up @@ -65,4 +66,5 @@ export interface Expense {
vendor?: Vendor;
category?: ExpenseCategory;
invoice?: Invoice;
e_invoice?: EInvoiceType;
}
1 change: 1 addition & 0 deletions src/common/interfaces/invoice-activity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ export interface InvoiceActivity {
ip: string;
recurring_invoice?: Client;
payment?: Client;
credit?: Client;
payment_amount?: ActivityRecordBase;
}

Expand Down
2 changes: 2 additions & 0 deletions src/common/interfaces/invoice.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
*
* @license https://www.elastic.co/licensing/elastic-license
*/
import { EInvoiceType } from '$app/pages/settings';
import { Client } from './client';
import { InvoiceItem } from './invoice-item';
import { Payment } from './payment';
Expand Down Expand Up @@ -81,6 +82,7 @@ export interface Invoice {
activities?: Activity[];
payments?: Payment[];
reminder_schedule?: string;
e_invoice?: EInvoiceType;
}

export interface Activity {
Expand Down
33 changes: 33 additions & 0 deletions src/common/interfaces/purchase-order-activity.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
/**
* Invoice Ninja (https://invoiceninja.com).
*
* @link https://github.com/invoiceninja/invoiceninja source repository
*
* @copyright Copyright (c) 2022. Invoice Ninja LLC (https://invoiceninja.com)
*
* @license https://www.elastic.co/licensing/elastic-license
*/

import { ActivityRecordBase } from './activity-record';

export interface PurchaseOrderActivity {
user: Client;
invoice: Client;
contact: Client;
client: Client;
activity_type_id: number;
id: string;
hashed_id: string;
notes: string;
created_at: number;
ip: string;
recurring_invoice?: Client;
payment?: Client;
payment_amount?: ActivityRecordBase;
purchase_order?: ActivityRecordBase;
}

export interface Client {
label: string;
hashed_id: string;
}
5 changes: 5 additions & 0 deletions src/common/interfaces/purchase-order.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,9 @@
* @license https://www.elastic.co/licensing/elastic-license
*/

import { EInvoiceType } from '$app/pages/settings';
import { Expense } from './expense';
import { Activity } from './invoice';
import { InvoiceItem } from './invoice-item';
import { Vendor } from './vendor';

Expand Down Expand Up @@ -77,6 +79,9 @@ export interface PurchaseOrder {
documents: any[];
vendor?: Vendor;
expense?: Expense;
e_invoice?: EInvoiceType;
activities?: Activity[];
reminder_schedule?: string;
}

export interface Invitation {
Expand Down
Loading

0 comments on commit 77d1836

Please sign in to comment.