@accounter/server 0.0.8-alpha-20251029233737-ec3a7806df63c8556b232ea893d0d3855d2c402a → 0.0.8-alpha-20251029234818-bb69914cb7aaa4859296baa4a256c251158fd15b
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +20 -26
- package/dist/green-invoice-graphql/src/mesh-artifacts/index.d.ts +1 -1
- package/dist/server/src/__generated__/types.d.ts +70 -18
- package/dist/server/src/__generated__/types.js.map +1 -1
- package/dist/server/src/modules/contracts/__generated__/contracts.types.d.ts +5 -0
- package/dist/server/src/modules/financial-entities/__generated__/admin-businesses.types.d.ts +57 -0
- package/dist/server/src/modules/financial-entities/__generated__/admin-businesses.types.js +0 -1
- package/dist/server/src/modules/financial-entities/__generated__/admin-businesses.types.js.map +1 -1
- package/dist/server/src/modules/financial-entities/__generated__/types.d.ts +33 -10
- package/dist/server/src/modules/financial-entities/__generated__/types.js.map +1 -1
- package/dist/server/src/modules/financial-entities/helpers/admin-businesses.helper.d.ts +31 -0
- package/dist/server/src/modules/financial-entities/helpers/admin-businesses.helper.js +27 -0
- package/dist/server/src/modules/financial-entities/helpers/admin-businesses.helper.js.map +1 -0
- package/dist/server/src/modules/financial-entities/providers/admin-businesses.provider.d.ts +2 -1
- package/dist/server/src/modules/financial-entities/providers/admin-businesses.provider.js +37 -0
- package/dist/server/src/modules/financial-entities/providers/admin-businesses.provider.js.map +1 -1
- package/dist/server/src/modules/financial-entities/resolvers/admin-businesses.resolver.js +46 -11
- package/dist/server/src/modules/financial-entities/resolvers/admin-businesses.resolver.js.map +1 -1
- package/dist/server/src/modules/financial-entities/typeDefs/admin-businesses.graphql.js +49 -16
- package/dist/server/src/modules/financial-entities/typeDefs/admin-businesses.graphql.js.map +1 -1
- package/dist/server/src/modules/financial-entities/types.d.ts +1 -1
- package/package.json +4 -4
- package/src/__generated__/types.ts +76 -18
- package/src/modules/contracts/__generated__/contracts.types.ts +5 -0
- package/src/modules/financial-entities/__generated__/admin-businesses.types.ts +60 -0
- package/src/modules/financial-entities/__generated__/types.ts +33 -10
- package/src/modules/financial-entities/helpers/admin-businesses.helper.ts +33 -0
- package/src/modules/financial-entities/providers/admin-businesses.provider.ts +44 -0
- package/src/modules/financial-entities/resolvers/admin-businesses.resolver.ts +53 -11
- package/src/modules/financial-entities/typeDefs/admin-businesses.graphql.ts +49 -16
- package/src/modules/financial-entities/types.ts +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @accounter/server
|
|
2
2
|
|
|
3
|
-
## 0.0.8-alpha-
|
|
3
|
+
## 0.0.8-alpha-20251029234818-bb69914cb7aaa4859296baa4a256c251158fd15b
|
|
4
4
|
|
|
5
5
|
### Patch Changes
|
|
6
6
|
|
|
@@ -212,25 +212,6 @@
|
|
|
212
212
|
- Updated dependency [`puppeteer@24.26.1` ↗︎](https://www.npmjs.com/package/puppeteer/v/24.26.1)
|
|
213
213
|
(from `24.26.0`, in `dependencies`)
|
|
214
214
|
|
|
215
|
-
- [#2638](https://github.com/Urigo/accounter-fullstack/pull/2638)
|
|
216
|
-
[`cad4ed9`](https://github.com/Urigo/accounter-fullstack/commit/cad4ed9a12ef09c22d0c55715ba1453a73aa0773)
|
|
217
|
-
Thanks [@renovate](https://github.com/apps/renovate)! - dependencies updates:
|
|
218
|
-
- Updated dependency [`dotenv-cli@11.0.0` ↗︎](https://www.npmjs.com/package/dotenv-cli/v/11.0.0)
|
|
219
|
-
(from `10.0.0`, in `dependencies`)
|
|
220
|
-
|
|
221
|
-
- [#2639](https://github.com/Urigo/accounter-fullstack/pull/2639)
|
|
222
|
-
[`0792f80`](https://github.com/Urigo/accounter-fullstack/commit/0792f80e6c83326e63066e3d51c65cf554cb0a6e)
|
|
223
|
-
Thanks [@renovate](https://github.com/apps/renovate)! - dependencies updates:
|
|
224
|
-
- Updated dependency [`puppeteer@24.27.0` ↗︎](https://www.npmjs.com/package/puppeteer/v/24.27.0)
|
|
225
|
-
(from `24.26.1`, in `dependencies`)
|
|
226
|
-
|
|
227
|
-
- [#2643](https://github.com/Urigo/accounter-fullstack/pull/2643)
|
|
228
|
-
[`485cec8`](https://github.com/Urigo/accounter-fullstack/commit/485cec843689ba4777711231b88d876f1eac7022)
|
|
229
|
-
Thanks [@renovate](https://github.com/apps/renovate)! - dependencies updates:
|
|
230
|
-
- Updated dependency
|
|
231
|
-
[`@envelop/generic-auth@10.0.1` ↗︎](https://www.npmjs.com/package/@envelop/generic-auth/v/10.0.1)
|
|
232
|
-
(from `10.0.0`, in `dependencies`)
|
|
233
|
-
|
|
234
215
|
- [#2631](https://github.com/Urigo/accounter-fullstack/pull/2631)
|
|
235
216
|
[`86c8b3e`](https://github.com/Urigo/accounter-fullstack/commit/86c8b3ebea4e3be0c0e99a108ec1cdad8b39e5d8)
|
|
236
217
|
Thanks [@gilgardosh](https://github.com/gilgardosh)! - - **Database Schema Update**: A new
|
|
@@ -469,6 +450,21 @@
|
|
|
469
450
|
streamline the process of adding new businesses, specifically by simplifying the handling of tax
|
|
470
451
|
category insertions.
|
|
471
452
|
|
|
453
|
+
- [#2645](https://github.com/Urigo/accounter-fullstack/pull/2645)
|
|
454
|
+
[`ffc4613`](https://github.com/Urigo/accounter-fullstack/commit/ffc4613763bf5c0bf8e169d8016cc996fed26819)
|
|
455
|
+
Thanks [@gilgardosh](https://github.com/gilgardosh)! - - **Database Schema Refactor**: The
|
|
456
|
+
`businesses_admin` table is updated to replace single-value fields for tax and social security
|
|
457
|
+
identifiers with array-based JSONB columns, allowing for multiple annual IDs and historical tax
|
|
458
|
+
rates.
|
|
459
|
+
- **GraphQL Schema Update**: The GraphQL `AdminBusiness` type and related input types
|
|
460
|
+
(`CreateAdminBusinessInput`, `UpdateAdminBusinessInput`) are modified to reflect the new array
|
|
461
|
+
structures, introducing `AnnualId` and `TaxAdvancesRate` types.
|
|
462
|
+
- **Frontend Form Overhaul**: The `admin-business-section.tsx` component is refactored to use
|
|
463
|
+
`react-hook-form`'s `useFieldArray` for dynamic management of annual IDs and tax rates,
|
|
464
|
+
providing a more flexible user interface.
|
|
465
|
+
- **Backend Logic Adaptation**: New Zod schemas and resolver logic are implemented on the server
|
|
466
|
+
to validate and process the updated array-based data for admin business updates.
|
|
467
|
+
|
|
472
468
|
- [#2640](https://github.com/Urigo/accounter-fullstack/pull/2640)
|
|
473
469
|
[`26618ff`](https://github.com/Urigo/accounter-fullstack/commit/26618ff2d4a47d63e16ecec59f39887f48df52cf)
|
|
474
470
|
Thanks [@gilgardosh](https://github.com/gilgardosh)! - - **Renaming and Restructuring**: Key
|
|
@@ -502,14 +498,12 @@
|
|
|
502
498
|
environment variables have been updated to use optional chaining (`?.`) to safely handle cases
|
|
503
499
|
where the configuration might be `undefined`.
|
|
504
500
|
- Updated dependencies
|
|
505
|
-
[[`
|
|
506
|
-
[`65e3c7f`](https://github.com/Urigo/accounter-fullstack/commit/65e3c7f01993eb4f41244a40feefefa08b31a4e6),
|
|
501
|
+
[[`65e3c7f`](https://github.com/Urigo/accounter-fullstack/commit/65e3c7f01993eb4f41244a40feefefa08b31a4e6),
|
|
507
502
|
[`65e3c7f`](https://github.com/Urigo/accounter-fullstack/commit/65e3c7f01993eb4f41244a40feefefa08b31a4e6),
|
|
508
503
|
[`65e3c7f`](https://github.com/Urigo/accounter-fullstack/commit/65e3c7f01993eb4f41244a40feefefa08b31a4e6)]:
|
|
509
|
-
- @accounter/
|
|
510
|
-
- @accounter/
|
|
511
|
-
- @accounter/
|
|
512
|
-
- @accounter/shaam6111-generator@0.1.4-alpha-20251029233737-ec3a7806df63c8556b232ea893d0d3855d2c402a
|
|
504
|
+
- @accounter/pcn874-generator@0.6.3-alpha-20251029234818-bb69914cb7aaa4859296baa4a256c251158fd15b
|
|
505
|
+
- @accounter/shaam-uniform-format-generator@0.2.2-alpha-20251029234818-bb69914cb7aaa4859296baa4a256c251158fd15b
|
|
506
|
+
- @accounter/shaam6111-generator@0.1.4-alpha-20251029234818-bb69914cb7aaa4859296baa4a256c251158fd15b
|
|
513
507
|
|
|
514
508
|
## 0.0.7
|
|
515
509
|
|
|
@@ -4,8 +4,8 @@ import type { GetMeshOptions } from '@graphql-mesh/runtime';
|
|
|
4
4
|
import type { YamlConfig } from '@graphql-mesh/types';
|
|
5
5
|
import { MeshHTTPHandler } from '@graphql-mesh/http';
|
|
6
6
|
import { type ExecuteMeshFn, type SubscribeMeshFn, type MeshContext as BaseMeshContext, type MeshInstance } from '@graphql-mesh/runtime';
|
|
7
|
-
import type { GreenInvoiceNewTypes } from './sources/GreenInvoiceNew/types';
|
|
8
7
|
import type { GreenInvoiceTypes } from './sources/GreenInvoice/types';
|
|
8
|
+
import type { GreenInvoiceNewTypes } from './sources/GreenInvoiceNew/types';
|
|
9
9
|
export type Maybe<T> = T | null;
|
|
10
10
|
export type InputMaybe<T> = Maybe<T>;
|
|
11
11
|
export type Exact<T extends {
|
|
@@ -193,11 +193,15 @@ export type AdminBusiness = {
|
|
|
193
193
|
readonly id: Scalars['UUID']['output'];
|
|
194
194
|
readonly name: Scalars['String']['output'];
|
|
195
195
|
readonly registrationDate: Scalars['TimelessDate']['output'];
|
|
196
|
-
|
|
197
|
-
readonly
|
|
198
|
-
readonly
|
|
199
|
-
|
|
200
|
-
readonly
|
|
196
|
+
/** Social Security Info */
|
|
197
|
+
readonly socialSecurityDeductionsId?: Maybe<Scalars['String']['output']>;
|
|
198
|
+
readonly socialSecurityEmployerIds: ReadonlyArray<AnnualId>;
|
|
199
|
+
/** Tax Advances Info */
|
|
200
|
+
readonly taxAdvancesAnnualIds: ReadonlyArray<AnnualId>;
|
|
201
|
+
readonly taxAdvancesRates: ReadonlyArray<TaxAdvancesRate>;
|
|
202
|
+
readonly withholdingTaxAnnualIds: ReadonlyArray<AnnualId>;
|
|
203
|
+
/** Withholding Tax Info */
|
|
204
|
+
readonly withholdingTaxCompanyId?: Maybe<Scalars['String']['output']>;
|
|
201
205
|
};
|
|
202
206
|
/** defines a tag / category for charge arrangement */
|
|
203
207
|
export type AdminContext = {
|
|
@@ -331,6 +335,17 @@ export type AdminContextInput = {
|
|
|
331
335
|
readonly zkufotExpensesTaxCategoryId?: InputMaybe<Scalars['UUID']['input']>;
|
|
332
336
|
readonly zkufotIncomeTaxCategoryId?: InputMaybe<Scalars['UUID']['input']>;
|
|
333
337
|
};
|
|
338
|
+
/** Represents an annual identifier for tax purposes. */
|
|
339
|
+
export type AnnualId = {
|
|
340
|
+
readonly __typename?: 'AnnualId';
|
|
341
|
+
readonly id: Scalars['String']['output'];
|
|
342
|
+
readonly year: Scalars['Int']['output'];
|
|
343
|
+
};
|
|
344
|
+
/** Input type representing an annual identifier for tax purposes. */
|
|
345
|
+
export type AnnualIdInput = {
|
|
346
|
+
readonly id: Scalars['String']['input'];
|
|
347
|
+
readonly year: Scalars['Int']['input'];
|
|
348
|
+
};
|
|
334
349
|
/** Audit opinion type enum (חוות דעת) */
|
|
335
350
|
export type AuditOpinionType =
|
|
336
351
|
/** Adverse opinion (שלילית) */
|
|
@@ -1107,12 +1122,12 @@ export type Country = {
|
|
|
1107
1122
|
/** Input type for creating a new admin business. */
|
|
1108
1123
|
export type CreateAdminBusinessInput = {
|
|
1109
1124
|
readonly businessId: Scalars['UUID']['input'];
|
|
1125
|
+
readonly companyTaxId: Scalars['String']['input'];
|
|
1110
1126
|
readonly registrationDate: Scalars['TimelessDate']['input'];
|
|
1111
1127
|
readonly socialSecurityEmployerId?: InputMaybe<Scalars['String']['input']>;
|
|
1112
|
-
readonly
|
|
1128
|
+
readonly taxAdvancesAnnualId?: InputMaybe<Scalars['String']['input']>;
|
|
1113
1129
|
readonly taxAdvancesRate?: InputMaybe<Scalars['Float']['input']>;
|
|
1114
|
-
readonly
|
|
1115
|
-
readonly withholdingTaxFileNumber?: InputMaybe<Scalars['String']['input']>;
|
|
1130
|
+
readonly withholdingTaxAnnualId?: InputMaybe<Scalars['String']['input']>;
|
|
1116
1131
|
};
|
|
1117
1132
|
/** input for creating a new contract */
|
|
1118
1133
|
export type CreateContractInput = {
|
|
@@ -3541,6 +3556,17 @@ export type Tag = {
|
|
|
3541
3556
|
export type TagInput = {
|
|
3542
3557
|
readonly id: Scalars['String']['input'];
|
|
3543
3558
|
};
|
|
3559
|
+
/** Represents the tax advance rate for a specific date. */
|
|
3560
|
+
export type TaxAdvancesRate = {
|
|
3561
|
+
readonly __typename?: 'TaxAdvancesRate';
|
|
3562
|
+
readonly date: Scalars['TimelessDate']['output'];
|
|
3563
|
+
readonly rate: Scalars['Float']['output'];
|
|
3564
|
+
};
|
|
3565
|
+
/** Input type representing the tax advance rate for a specific date. */
|
|
3566
|
+
export type TaxAdvancesRateInput = {
|
|
3567
|
+
readonly date: Scalars['TimelessDate']['input'];
|
|
3568
|
+
readonly rate: Scalars['Float']['input'];
|
|
3569
|
+
};
|
|
3544
3570
|
/** Tax category entity used for ledger records */
|
|
3545
3571
|
export type TaxCategory = FinancialEntity & {
|
|
3546
3572
|
readonly __typename?: 'TaxCategory';
|
|
@@ -3655,12 +3681,17 @@ export type Unprocessed = Document & Linkable & {
|
|
|
3655
3681
|
};
|
|
3656
3682
|
/** Input type for updating admin business details. */
|
|
3657
3683
|
export type UpdateAdminBusinessInput = {
|
|
3684
|
+
readonly governmentId?: InputMaybe<Scalars['String']['input']>;
|
|
3685
|
+
readonly name?: InputMaybe<Scalars['String']['input']>;
|
|
3658
3686
|
readonly registrationDate?: InputMaybe<Scalars['TimelessDate']['input']>;
|
|
3659
|
-
|
|
3660
|
-
readonly
|
|
3661
|
-
|
|
3662
|
-
readonly
|
|
3663
|
-
readonly
|
|
3687
|
+
/** Social Security Info */
|
|
3688
|
+
readonly socialSecurityEmployerIds?: InputMaybe<ReadonlyArray<AnnualIdInput>>;
|
|
3689
|
+
/** Tax Advances Info */
|
|
3690
|
+
readonly taxAdvancesAnnualIds?: InputMaybe<ReadonlyArray<AnnualIdInput>>;
|
|
3691
|
+
readonly taxAdvancesRates?: InputMaybe<ReadonlyArray<TaxAdvancesRateInput>>;
|
|
3692
|
+
readonly withholdingTaxAnnualIds?: InputMaybe<ReadonlyArray<AnnualIdInput>>;
|
|
3693
|
+
/** Withholding Tax Info */
|
|
3694
|
+
readonly withholdingTaxCompanyId?: InputMaybe<Scalars['String']['input']>;
|
|
3664
3695
|
};
|
|
3665
3696
|
/** input for updateBusiness */
|
|
3666
3697
|
export type UpdateBusinessInput = {
|
|
@@ -4092,6 +4123,8 @@ export type ResolversTypes = {
|
|
|
4092
4123
|
AdminBusiness: ResolverTypeWrapper<IGetAllAdminBusinessesResult>;
|
|
4093
4124
|
AdminContext: ResolverTypeWrapper<IGetAdminContextsResult>;
|
|
4094
4125
|
AdminContextInput: AdminContextInput;
|
|
4126
|
+
AnnualId: ResolverTypeWrapper<AnnualId>;
|
|
4127
|
+
AnnualIdInput: AnnualIdInput;
|
|
4095
4128
|
AuditOpinionType: AuditOpinionType;
|
|
4096
4129
|
BalanceTransactions: ResolverTypeWrapper<IGetNormalizedBalanceTransactionsResult>;
|
|
4097
4130
|
BankDeposit: ResolverTypeWrapper<Omit<BankDeposit, 'transactions'> & {
|
|
@@ -4361,6 +4394,8 @@ export type ResolversTypes = {
|
|
|
4361
4394
|
SuggestionsInput: SuggestionsInput;
|
|
4362
4395
|
Tag: ResolverTypeWrapper<IGetAllTagsResult>;
|
|
4363
4396
|
TagInput: TagInput;
|
|
4397
|
+
TaxAdvancesRate: ResolverTypeWrapper<TaxAdvancesRate>;
|
|
4398
|
+
TaxAdvancesRateInput: TaxAdvancesRateInput;
|
|
4364
4399
|
TaxCategory: ResolverTypeWrapper<IGetAllTaxCategoriesResult>;
|
|
4365
4400
|
TaxReport: ResolverTypeWrapper<Omit<TaxReport, 'reference' | 'report'> & {
|
|
4366
4401
|
reference: ReadonlyArray<ResolversTypes['TaxReportYear']>;
|
|
@@ -4459,6 +4494,8 @@ export type ResolversParentTypes = {
|
|
|
4459
4494
|
AdminBusiness: IGetAllAdminBusinessesResult;
|
|
4460
4495
|
AdminContext: IGetAdminContextsResult;
|
|
4461
4496
|
AdminContextInput: AdminContextInput;
|
|
4497
|
+
AnnualId: AnnualId;
|
|
4498
|
+
AnnualIdInput: AnnualIdInput;
|
|
4462
4499
|
BalanceTransactions: IGetNormalizedBalanceTransactionsResult;
|
|
4463
4500
|
BankDeposit: Omit<BankDeposit, 'transactions'> & {
|
|
4464
4501
|
transactions: ReadonlyArray<ResolversParentTypes['Transaction']>;
|
|
@@ -4693,6 +4730,8 @@ export type ResolversParentTypes = {
|
|
|
4693
4730
|
SuggestionsInput: SuggestionsInput;
|
|
4694
4731
|
Tag: IGetAllTagsResult;
|
|
4695
4732
|
TagInput: TagInput;
|
|
4733
|
+
TaxAdvancesRate: TaxAdvancesRate;
|
|
4734
|
+
TaxAdvancesRateInput: TaxAdvancesRateInput;
|
|
4696
4735
|
TaxCategory: IGetAllTaxCategoriesResult;
|
|
4697
4736
|
TaxReport: Omit<TaxReport, 'reference' | 'report'> & {
|
|
4698
4737
|
reference: ReadonlyArray<ResolversParentTypes['TaxReportYear']>;
|
|
@@ -4794,11 +4833,12 @@ export type AdminBusinessResolvers<ContextType = GraphQLModules.Context, ParentT
|
|
|
4794
4833
|
id?: Resolver<ResolversTypes['UUID'], ParentType, ContextType>;
|
|
4795
4834
|
name?: Resolver<ResolversTypes['String'], ParentType, ContextType>;
|
|
4796
4835
|
registrationDate?: Resolver<ResolversTypes['TimelessDate'], ParentType, ContextType>;
|
|
4797
|
-
|
|
4798
|
-
|
|
4799
|
-
|
|
4800
|
-
|
|
4801
|
-
|
|
4836
|
+
socialSecurityDeductionsId?: Resolver<Maybe<ResolversTypes['String']>, ParentType, ContextType>;
|
|
4837
|
+
socialSecurityEmployerIds?: Resolver<ReadonlyArray<ResolversTypes['AnnualId']>, ParentType, ContextType>;
|
|
4838
|
+
taxAdvancesAnnualIds?: Resolver<ReadonlyArray<ResolversTypes['AnnualId']>, ParentType, ContextType>;
|
|
4839
|
+
taxAdvancesRates?: Resolver<ReadonlyArray<ResolversTypes['TaxAdvancesRate']>, ParentType, ContextType>;
|
|
4840
|
+
withholdingTaxAnnualIds?: Resolver<ReadonlyArray<ResolversTypes['AnnualId']>, ParentType, ContextType>;
|
|
4841
|
+
withholdingTaxCompanyId?: Resolver<Maybe<ResolversTypes['String']>, ParentType, ContextType>;
|
|
4802
4842
|
__isTypeOf?: IsTypeOfResolverFn<ParentType, ContextType>;
|
|
4803
4843
|
};
|
|
4804
4844
|
export type AdminContextResolvers<ContextType = GraphQLModules.Context, ParentType extends ResolversParentTypes['AdminContext'] = ResolversParentTypes['AdminContext']> = {
|
|
@@ -4867,6 +4907,11 @@ export type AdminContextResolvers<ContextType = GraphQLModules.Context, ParentTy
|
|
|
4867
4907
|
zkufotIncomeTaxCategory?: Resolver<Maybe<ResolversTypes['TaxCategory']>, ParentType, ContextType>;
|
|
4868
4908
|
__isTypeOf?: IsTypeOfResolverFn<ParentType, ContextType>;
|
|
4869
4909
|
};
|
|
4910
|
+
export type AnnualIdResolvers<ContextType = GraphQLModules.Context, ParentType extends ResolversParentTypes['AnnualId'] = ResolversParentTypes['AnnualId']> = {
|
|
4911
|
+
id?: Resolver<ResolversTypes['String'], ParentType, ContextType>;
|
|
4912
|
+
year?: Resolver<ResolversTypes['Int'], ParentType, ContextType>;
|
|
4913
|
+
__isTypeOf?: IsTypeOfResolverFn<ParentType, ContextType>;
|
|
4914
|
+
};
|
|
4870
4915
|
export type BalanceTransactionsResolvers<ContextType = GraphQLModules.Context, ParentType extends ResolversParentTypes['BalanceTransactions'] = ResolversParentTypes['BalanceTransactions']> = {
|
|
4871
4916
|
amount?: Resolver<ResolversTypes['FinancialAmount'], ParentType, ContextType>;
|
|
4872
4917
|
amountUsd?: Resolver<ResolversTypes['FinancialAmount'], ParentType, ContextType>;
|
|
@@ -6661,6 +6706,11 @@ export type TagResolvers<ContextType = GraphQLModules.Context, ParentType extend
|
|
|
6661
6706
|
parent?: Resolver<Maybe<ResolversTypes['Tag']>, ParentType, ContextType>;
|
|
6662
6707
|
__isTypeOf?: IsTypeOfResolverFn<ParentType, ContextType>;
|
|
6663
6708
|
};
|
|
6709
|
+
export type TaxAdvancesRateResolvers<ContextType = GraphQLModules.Context, ParentType extends ResolversParentTypes['TaxAdvancesRate'] = ResolversParentTypes['TaxAdvancesRate']> = {
|
|
6710
|
+
date?: Resolver<ResolversTypes['TimelessDate'], ParentType, ContextType>;
|
|
6711
|
+
rate?: Resolver<ResolversTypes['Float'], ParentType, ContextType>;
|
|
6712
|
+
__isTypeOf?: IsTypeOfResolverFn<ParentType, ContextType>;
|
|
6713
|
+
};
|
|
6664
6714
|
export type TaxCategoryResolvers<ContextType = GraphQLModules.Context, ParentType extends ResolversParentTypes['TaxCategory'] = ResolversParentTypes['TaxCategory']> = {
|
|
6665
6715
|
createdAt?: Resolver<ResolversTypes['DateTime'], ParentType, ContextType>;
|
|
6666
6716
|
id?: Resolver<ResolversTypes['UUID'], ParentType, ContextType>;
|
|
@@ -6893,6 +6943,7 @@ export type YearlyLedgerReportFinancialEntityInfoResolvers<ContextType = GraphQL
|
|
|
6893
6943
|
export type Resolvers<ContextType = GraphQLModules.Context> = {
|
|
6894
6944
|
AdminBusiness?: AdminBusinessResolvers<ContextType>;
|
|
6895
6945
|
AdminContext?: AdminContextResolvers<ContextType>;
|
|
6946
|
+
AnnualId?: AnnualIdResolvers<ContextType>;
|
|
6896
6947
|
BalanceTransactions?: BalanceTransactionsResolvers<ContextType>;
|
|
6897
6948
|
BankDeposit?: BankDepositResolvers<ContextType>;
|
|
6898
6949
|
BankDepositCharge?: BankDepositChargeResolvers<ContextType>;
|
|
@@ -7038,6 +7089,7 @@ export type Resolvers<ContextType = GraphQLModules.Context> = {
|
|
|
7038
7089
|
Suggestions?: SuggestionsResolvers<ContextType>;
|
|
7039
7090
|
SuggestionsEmailListenerConfig?: SuggestionsEmailListenerConfigResolvers<ContextType>;
|
|
7040
7091
|
Tag?: TagResolvers<ContextType>;
|
|
7092
|
+
TaxAdvancesRate?: TaxAdvancesRateResolvers<ContextType>;
|
|
7041
7093
|
TaxCategory?: TaxCategoryResolvers<ContextType>;
|
|
7042
7094
|
TaxReport?: TaxReportResolvers<ContextType>;
|
|
7043
7095
|
TaxReportYear?: TaxReportYearResolvers<ContextType>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/__generated__/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAClD,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAClD,OAAO,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/__generated__/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAClD,OAAO,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAClD,OAAO,EAAE,oBAAoB,EAAE,MAAM,eAAe,CAAC;AAs3BrD,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAyX7B,OAAO,EAAE,QAAQ,EAAE,CAAC;AAuLpB,OAAO,EAAE,YAAY,EAAE,CAAC;AA2lCxB,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAw4D7B,OAAO,EAAE,oBAAoB,EAAE,CAAC"}
|
|
@@ -20,6 +20,7 @@ export interface IGetAllOpenContractsResult {
|
|
|
20
20
|
operations_count: string;
|
|
21
21
|
plan: string | null;
|
|
22
22
|
product: string | null;
|
|
23
|
+
purchase_order: string | null;
|
|
23
24
|
purchase_orders: stringArray;
|
|
24
25
|
remarks: string | null;
|
|
25
26
|
signed_agreement: string | null;
|
|
@@ -48,6 +49,7 @@ export interface IGetContractsByIdsResult {
|
|
|
48
49
|
operations_count: string;
|
|
49
50
|
plan: string | null;
|
|
50
51
|
product: string | null;
|
|
52
|
+
purchase_order: string | null;
|
|
51
53
|
purchase_orders: stringArray;
|
|
52
54
|
remarks: string | null;
|
|
53
55
|
signed_agreement: string | null;
|
|
@@ -76,6 +78,7 @@ export interface IGetContractsByClientIdsResult {
|
|
|
76
78
|
operations_count: string;
|
|
77
79
|
plan: string | null;
|
|
78
80
|
product: string | null;
|
|
81
|
+
purchase_order: string | null;
|
|
79
82
|
purchase_orders: stringArray;
|
|
80
83
|
remarks: string | null;
|
|
81
84
|
signed_agreement: string | null;
|
|
@@ -129,6 +132,7 @@ export interface IUpdateContractResult {
|
|
|
129
132
|
operations_count: string;
|
|
130
133
|
plan: string | null;
|
|
131
134
|
product: string | null;
|
|
135
|
+
purchase_order: string | null;
|
|
132
136
|
purchase_orders: stringArray;
|
|
133
137
|
remarks: string | null;
|
|
134
138
|
signed_agreement: string | null;
|
|
@@ -170,6 +174,7 @@ export interface IInsertContractResult {
|
|
|
170
174
|
operations_count: string;
|
|
171
175
|
plan: string | null;
|
|
172
176
|
product: string | null;
|
|
177
|
+
purchase_order: string | null;
|
|
173
178
|
purchase_orders: stringArray;
|
|
174
179
|
remarks: string | null;
|
|
175
180
|
signed_agreement: string | null;
|
package/dist/server/src/modules/financial-entities/__generated__/admin-businesses.types.d.ts
CHANGED
|
@@ -1,4 +1,9 @@
|
|
|
1
1
|
/** Types generated for queries found in "src/modules/financial-entities/providers/admin-businesses.provider.ts" */
|
|
2
|
+
export type DateOrString = Date | string;
|
|
3
|
+
export type Json = null | boolean | number | string | Json[] | {
|
|
4
|
+
[key: string]: Json;
|
|
5
|
+
};
|
|
6
|
+
export type JsonArray = (Json)[];
|
|
2
7
|
/** 'GetAdminBusinessesByIds' parameters type */
|
|
3
8
|
export interface IGetAdminBusinessesByIdsParams {
|
|
4
9
|
ids: readonly (string | null | void)[];
|
|
@@ -6,6 +11,9 @@ export interface IGetAdminBusinessesByIdsParams {
|
|
|
6
11
|
/** 'GetAdminBusinessesByIds' return type */
|
|
7
12
|
export interface IGetAdminBusinessesByIdsResult {
|
|
8
13
|
advance_tax_rate: number | null;
|
|
14
|
+
advance_tax_rates: JsonArray;
|
|
15
|
+
business_registration_start_date: Date | null;
|
|
16
|
+
company_tax_id: string | null;
|
|
9
17
|
id: string;
|
|
10
18
|
name: string;
|
|
11
19
|
nikuim: string | null;
|
|
@@ -13,6 +21,8 @@ export interface IGetAdminBusinessesByIdsResult {
|
|
|
13
21
|
pinkas_social_security_2021: string | null;
|
|
14
22
|
pinkas_social_security_2022: string | null;
|
|
15
23
|
registration_date: Date | null;
|
|
24
|
+
social_security_employer_ids: JsonArray;
|
|
25
|
+
tax_advances_ids: JsonArray;
|
|
16
26
|
tax_nikuim_pinkas_number: string | null;
|
|
17
27
|
tax_pinkas_number_2020: string | null;
|
|
18
28
|
tax_siduri_number_2021: string | null;
|
|
@@ -21,6 +31,7 @@ export interface IGetAdminBusinessesByIdsResult {
|
|
|
21
31
|
vat_number: string | null;
|
|
22
32
|
vat_report_cadence: number | null;
|
|
23
33
|
website_login_screenshot: string | null;
|
|
34
|
+
withholding_tax_annual_ids: JsonArray;
|
|
24
35
|
wizcloud_company_id: string | null;
|
|
25
36
|
wizcloud_token: string | null;
|
|
26
37
|
}
|
|
@@ -34,6 +45,9 @@ export type IGetAllAdminBusinessesParams = void;
|
|
|
34
45
|
/** 'GetAllAdminBusinesses' return type */
|
|
35
46
|
export interface IGetAllAdminBusinessesResult {
|
|
36
47
|
advance_tax_rate: number | null;
|
|
48
|
+
advance_tax_rates: JsonArray;
|
|
49
|
+
business_registration_start_date: Date | null;
|
|
50
|
+
company_tax_id: string | null;
|
|
37
51
|
id: string;
|
|
38
52
|
name: string;
|
|
39
53
|
nikuim: string | null;
|
|
@@ -41,6 +55,8 @@ export interface IGetAllAdminBusinessesResult {
|
|
|
41
55
|
pinkas_social_security_2021: string | null;
|
|
42
56
|
pinkas_social_security_2022: string | null;
|
|
43
57
|
registration_date: Date | null;
|
|
58
|
+
social_security_employer_ids: JsonArray;
|
|
59
|
+
tax_advances_ids: JsonArray;
|
|
44
60
|
tax_nikuim_pinkas_number: string | null;
|
|
45
61
|
tax_pinkas_number_2020: string | null;
|
|
46
62
|
tax_siduri_number_2021: string | null;
|
|
@@ -49,6 +65,7 @@ export interface IGetAllAdminBusinessesResult {
|
|
|
49
65
|
vat_number: string | null;
|
|
50
66
|
vat_report_cadence: number | null;
|
|
51
67
|
website_login_screenshot: string | null;
|
|
68
|
+
withholding_tax_annual_ids: JsonArray;
|
|
52
69
|
wizcloud_company_id: string | null;
|
|
53
70
|
wizcloud_token: string | null;
|
|
54
71
|
}
|
|
@@ -57,3 +74,43 @@ export interface IGetAllAdminBusinessesQuery {
|
|
|
57
74
|
params: IGetAllAdminBusinessesParams;
|
|
58
75
|
result: IGetAllAdminBusinessesResult;
|
|
59
76
|
}
|
|
77
|
+
/** 'UpdateAdminBusinesses' parameters type */
|
|
78
|
+
export interface IUpdateAdminBusinessesParams {
|
|
79
|
+
advanceTaxRates?: JsonArray | null | void;
|
|
80
|
+
businessRegistrationStartDate?: DateOrString | null | void;
|
|
81
|
+
companyTaxId?: string | null | void;
|
|
82
|
+
id?: string | null | void;
|
|
83
|
+
socialSecurityEmployerIds?: JsonArray | null | void;
|
|
84
|
+
taxAdvancesIds?: JsonArray | null | void;
|
|
85
|
+
withholdingTaxAnnualIds?: JsonArray | null | void;
|
|
86
|
+
}
|
|
87
|
+
/** 'UpdateAdminBusinesses' return type */
|
|
88
|
+
export interface IUpdateAdminBusinessesResult {
|
|
89
|
+
advance_tax_rate: number | null;
|
|
90
|
+
advance_tax_rates: JsonArray;
|
|
91
|
+
business_registration_start_date: Date | null;
|
|
92
|
+
company_tax_id: string | null;
|
|
93
|
+
id: string;
|
|
94
|
+
nikuim: string | null;
|
|
95
|
+
password: string | null;
|
|
96
|
+
pinkas_social_security_2021: string | null;
|
|
97
|
+
pinkas_social_security_2022: string | null;
|
|
98
|
+
registration_date: Date | null;
|
|
99
|
+
social_security_employer_ids: JsonArray;
|
|
100
|
+
tax_advances_ids: JsonArray;
|
|
101
|
+
tax_nikuim_pinkas_number: string | null;
|
|
102
|
+
tax_pinkas_number_2020: string | null;
|
|
103
|
+
tax_siduri_number_2021: string | null;
|
|
104
|
+
tax_siduri_number_2022: string | null;
|
|
105
|
+
username_vat_website: string | null;
|
|
106
|
+
vat_report_cadence: number | null;
|
|
107
|
+
website_login_screenshot: string | null;
|
|
108
|
+
withholding_tax_annual_ids: JsonArray;
|
|
109
|
+
wizcloud_company_id: string | null;
|
|
110
|
+
wizcloud_token: string | null;
|
|
111
|
+
}
|
|
112
|
+
/** 'UpdateAdminBusinesses' query type */
|
|
113
|
+
export interface IUpdateAdminBusinessesQuery {
|
|
114
|
+
params: IUpdateAdminBusinessesParams;
|
|
115
|
+
result: IUpdateAdminBusinessesResult;
|
|
116
|
+
}
|
package/dist/server/src/modules/financial-entities/__generated__/admin-businesses.types.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"admin-businesses.types.js","sourceRoot":"","sources":["../../../../../../src/modules/financial-entities/__generated__/admin-businesses.types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"admin-businesses.types.js","sourceRoot":"","sources":["../../../../../../src/modules/financial-entities/__generated__/admin-businesses.types.ts"],"names":[],"mappings":""}
|
|
@@ -4,7 +4,9 @@ export declare namespace FinancialEntitiesModule {
|
|
|
4
4
|
interface DefinedFields {
|
|
5
5
|
Query: 'adminBusiness' | 'allAdminBusinesses' | 'businessTransactionsSumFromLedgerRecords' | 'businessTransactionsFromLedgerRecords' | 'business' | 'businesses' | 'allBusinesses' | 'client' | 'allClients' | 'financialEntity' | 'allFinancialEntities' | 'taxCategories' | 'taxCategory' | 'taxCategoryByBusinessId';
|
|
6
6
|
Mutation: 'createAdminBusiness' | 'updateAdminBusiness' | 'deleteAdminBusiness' | 'updateBusiness' | 'insertNewBusiness' | 'mergeBusinesses' | 'batchGenerateBusinessesOutOfTransactions' | 'updateClient' | 'insertClient' | 'updateTaxCategory' | 'insertTaxCategory';
|
|
7
|
-
AdminBusiness: 'id' | 'name' | 'governmentId' | 'business' | '
|
|
7
|
+
AdminBusiness: 'id' | 'name' | 'governmentId' | 'registrationDate' | 'business' | 'taxAdvancesAnnualIds' | 'taxAdvancesRates' | 'withholdingTaxCompanyId' | 'withholdingTaxAnnualIds' | 'socialSecurityDeductionsId' | 'socialSecurityEmployerIds';
|
|
8
|
+
AnnualId: 'year' | 'id';
|
|
9
|
+
TaxAdvancesRate: 'date' | 'rate';
|
|
8
10
|
BusinessTransactionsSumFromLedgerRecordsSuccessfulResult: 'businessTransactionsSum';
|
|
9
11
|
BusinessTransactionSum: 'business' | 'credit' | 'debit' | 'total' | 'foreignCurrenciesSum';
|
|
10
12
|
ForeignCurrencySum: 'credit' | 'debit' | 'total' | 'currency';
|
|
@@ -48,8 +50,10 @@ export declare namespace FinancialEntitiesModule {
|
|
|
48
50
|
EmailAttachmentType: 'PDF' | 'PNG' | 'JPEG';
|
|
49
51
|
}
|
|
50
52
|
interface DefinedInputFields {
|
|
51
|
-
CreateAdminBusinessInput: 'businessId' | '
|
|
52
|
-
UpdateAdminBusinessInput: '
|
|
53
|
+
CreateAdminBusinessInput: 'businessId' | 'registrationDate' | 'companyTaxId' | 'taxAdvancesAnnualId' | 'taxAdvancesRate' | 'withholdingTaxAnnualId' | 'socialSecurityEmployerId';
|
|
54
|
+
UpdateAdminBusinessInput: 'name' | 'governmentId' | 'registrationDate' | 'taxAdvancesAnnualIds' | 'taxAdvancesRates' | 'withholdingTaxCompanyId' | 'withholdingTaxAnnualIds' | 'socialSecurityEmployerIds';
|
|
55
|
+
AnnualIdInput: 'year' | 'id';
|
|
56
|
+
TaxAdvancesRateInput: 'date' | 'rate';
|
|
53
57
|
BusinessTransactionsFilter: 'businessIDs' | 'ownerIds' | 'type' | 'fromDate' | 'toDate' | 'includeRevaluation';
|
|
54
58
|
UpdateBusinessInput: 'name' | 'sortCode' | 'country' | 'hebrewName' | 'address' | 'email' | 'website' | 'phoneNumber' | 'governmentId' | 'taxCategory' | 'exemptDealer' | 'suggestions' | 'optionalVAT' | 'isReceiptEnough' | 'isDocumentsOptional' | 'pcn874RecordType' | 'irsCode' | 'isActive';
|
|
55
59
|
InsertNewBusinessInput: 'name' | 'sortCode' | 'country' | 'hebrewName' | 'address' | 'email' | 'website' | 'phoneNumber' | 'governmentId' | 'taxCategory' | 'exemptDealer' | 'suggestions' | 'optionalVAT' | 'isReceiptEnough' | 'isDocumentsOptional' | 'pcn874RecordType' | 'irsCode' | 'isActive';
|
|
@@ -67,8 +71,12 @@ export declare namespace FinancialEntitiesModule {
|
|
|
67
71
|
export type Mutation = Pick<Types.Mutation, DefinedFields['Mutation']>;
|
|
68
72
|
export type CreateAdminBusinessInput = Pick<Types.CreateAdminBusinessInput, DefinedInputFields['CreateAdminBusinessInput']>;
|
|
69
73
|
export type UpdateAdminBusinessInput = Pick<Types.UpdateAdminBusinessInput, DefinedInputFields['UpdateAdminBusinessInput']>;
|
|
70
|
-
export type LtdFinancialEntity = Pick<Types.LtdFinancialEntity, DefinedFields['LtdFinancialEntity']>;
|
|
71
74
|
export type TimelessDate = Types.TimelessDate;
|
|
75
|
+
export type LtdFinancialEntity = Pick<Types.LtdFinancialEntity, DefinedFields['LtdFinancialEntity']>;
|
|
76
|
+
export type AnnualId = Pick<Types.AnnualId, DefinedFields['AnnualId']>;
|
|
77
|
+
export type TaxAdvancesRate = Pick<Types.TaxAdvancesRate, DefinedFields['TaxAdvancesRate']>;
|
|
78
|
+
export type AnnualIdInput = Pick<Types.AnnualIdInput, DefinedInputFields['AnnualIdInput']>;
|
|
79
|
+
export type TaxAdvancesRateInput = Pick<Types.TaxAdvancesRateInput, DefinedInputFields['TaxAdvancesRateInput']>;
|
|
72
80
|
export type BusinessTransactionsSumFromLedgerRecordsResult = Types.BusinessTransactionsSumFromLedgerRecordsResult;
|
|
73
81
|
export type BusinessTransactionsFilter = Pick<Types.BusinessTransactionsFilter, DefinedInputFields['BusinessTransactionsFilter']>;
|
|
74
82
|
export type BusinessTransactionsFromLedgerRecordsResult = Types.BusinessTransactionsFromLedgerRecordsResult;
|
|
@@ -135,6 +143,8 @@ export declare namespace FinancialEntitiesModule {
|
|
|
135
143
|
export type QueryResolvers = Pick<Types.QueryResolvers, DefinedFields['Query']>;
|
|
136
144
|
export type MutationResolvers = Pick<Types.MutationResolvers, DefinedFields['Mutation']>;
|
|
137
145
|
export type AdminBusinessResolvers = Pick<Types.AdminBusinessResolvers, DefinedFields['AdminBusiness']>;
|
|
146
|
+
export type AnnualIdResolvers = Pick<Types.AnnualIdResolvers, DefinedFields['AnnualId']>;
|
|
147
|
+
export type TaxAdvancesRateResolvers = Pick<Types.TaxAdvancesRateResolvers, DefinedFields['TaxAdvancesRate']>;
|
|
138
148
|
export type BusinessTransactionsSumFromLedgerRecordsSuccessfulResultResolvers = Pick<Types.BusinessTransactionsSumFromLedgerRecordsSuccessfulResultResolvers, DefinedFields['BusinessTransactionsSumFromLedgerRecordsSuccessfulResult'] | '__isTypeOf'>;
|
|
139
149
|
export type BusinessTransactionSumResolvers = Pick<Types.BusinessTransactionSumResolvers, DefinedFields['BusinessTransactionSum']>;
|
|
140
150
|
export type ForeignCurrencySumResolvers = Pick<Types.ForeignCurrencySumResolvers, DefinedFields['ForeignCurrencySum']>;
|
|
@@ -176,6 +186,8 @@ export declare namespace FinancialEntitiesModule {
|
|
|
176
186
|
Query?: QueryResolvers;
|
|
177
187
|
Mutation?: MutationResolvers;
|
|
178
188
|
AdminBusiness?: AdminBusinessResolvers;
|
|
189
|
+
AnnualId?: AnnualIdResolvers;
|
|
190
|
+
TaxAdvancesRate?: TaxAdvancesRateResolvers;
|
|
179
191
|
BusinessTransactionsSumFromLedgerRecordsSuccessfulResult?: BusinessTransactionsSumFromLedgerRecordsSuccessfulResultResolvers;
|
|
180
192
|
BusinessTransactionSum?: BusinessTransactionSumResolvers;
|
|
181
193
|
ForeignCurrencySum?: ForeignCurrencySumResolvers;
|
|
@@ -249,13 +261,24 @@ export declare namespace FinancialEntitiesModule {
|
|
|
249
261
|
id?: gm.Middleware[];
|
|
250
262
|
name?: gm.Middleware[];
|
|
251
263
|
governmentId?: gm.Middleware[];
|
|
252
|
-
business?: gm.Middleware[];
|
|
253
|
-
withholdingTaxBookNumber?: gm.Middleware[];
|
|
254
|
-
withholdingTaxFileNumber?: gm.Middleware[];
|
|
255
|
-
socialSecurityEmployerId?: gm.Middleware[];
|
|
256
|
-
taxAdvancesRate?: gm.Middleware[];
|
|
257
|
-
taxAdvancesId?: gm.Middleware[];
|
|
258
264
|
registrationDate?: gm.Middleware[];
|
|
265
|
+
business?: gm.Middleware[];
|
|
266
|
+
taxAdvancesAnnualIds?: gm.Middleware[];
|
|
267
|
+
taxAdvancesRates?: gm.Middleware[];
|
|
268
|
+
withholdingTaxCompanyId?: gm.Middleware[];
|
|
269
|
+
withholdingTaxAnnualIds?: gm.Middleware[];
|
|
270
|
+
socialSecurityDeductionsId?: gm.Middleware[];
|
|
271
|
+
socialSecurityEmployerIds?: gm.Middleware[];
|
|
272
|
+
};
|
|
273
|
+
AnnualId?: {
|
|
274
|
+
'*'?: gm.Middleware[];
|
|
275
|
+
year?: gm.Middleware[];
|
|
276
|
+
id?: gm.Middleware[];
|
|
277
|
+
};
|
|
278
|
+
TaxAdvancesRate?: {
|
|
279
|
+
'*'?: gm.Middleware[];
|
|
280
|
+
date?: gm.Middleware[];
|
|
281
|
+
rate?: gm.Middleware[];
|
|
259
282
|
};
|
|
260
283
|
LtdFinancialEntity?: {
|
|
261
284
|
'*'?: gm.Middleware[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../../../src/modules/financial-entities/__generated__/types.ts"],"names":[],"mappings":"AAEA,MAAM,KAAW,uBAAuB,
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../../../src/modules/financial-entities/__generated__/types.ts"],"names":[],"mappings":"AAEA,MAAM,KAAW,uBAAuB,CA2fvC;AA3fD,WAAiB,uBAAuB;IA4CrC,CAAC;IAKD,CAAC;IAiBD,CAAC;IA+JD,CAAC;IAyRD,CAAC;AACJ,CAAC,EA3fgB,uBAAuB,KAAvB,uBAAuB,QA2fvC"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const adminBusinessUpdateSchema: z.ZodObject<{
|
|
3
|
+
id: z.ZodUUID;
|
|
4
|
+
businessRegistrationStartDate: z.ZodOptional<z.ZodISODate>;
|
|
5
|
+
companyTaxId: z.ZodOptional<z.ZodString>;
|
|
6
|
+
advanceTaxRates: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
7
|
+
date: z.ZodISODate;
|
|
8
|
+
rate: z.ZodNumber;
|
|
9
|
+
}, z.core.$strict>>>;
|
|
10
|
+
taxAdvancesIds: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
11
|
+
year: z.ZodNumber;
|
|
12
|
+
id: z.ZodString;
|
|
13
|
+
}, z.core.$strict>>>;
|
|
14
|
+
socialSecurityEmployerIds: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
15
|
+
year: z.ZodNumber;
|
|
16
|
+
id: z.ZodString;
|
|
17
|
+
}, z.core.$strict>>>;
|
|
18
|
+
withholdingTaxAnnualIds: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
19
|
+
year: z.ZodNumber;
|
|
20
|
+
id: z.ZodString;
|
|
21
|
+
}, z.core.$strict>>>;
|
|
22
|
+
}, z.core.$strict>;
|
|
23
|
+
export type AdminBusinessUpdateSchema = z.infer<typeof adminBusinessUpdateSchema>;
|
|
24
|
+
export declare const yearlyIdsSchema: z.ZodArray<z.ZodObject<{
|
|
25
|
+
year: z.ZodNumber;
|
|
26
|
+
id: z.ZodString;
|
|
27
|
+
}, z.core.$strict>>;
|
|
28
|
+
export declare const taxAdvancesRatesSchema: z.ZodArray<z.ZodObject<{
|
|
29
|
+
date: z.ZodISODate;
|
|
30
|
+
rate: z.ZodNumber;
|
|
31
|
+
}, z.core.$strict>>;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
const yearlyIdSchema = z
|
|
3
|
+
.object({
|
|
4
|
+
year: z.number().min(2000).max(2100),
|
|
5
|
+
id: z.string().min(1, { message: 'ID is required' }),
|
|
6
|
+
})
|
|
7
|
+
.strict();
|
|
8
|
+
const taxAdvanceRateSchema = z
|
|
9
|
+
.object({
|
|
10
|
+
date: z.iso.date(),
|
|
11
|
+
rate: z.number().min(0).max(1),
|
|
12
|
+
})
|
|
13
|
+
.strict();
|
|
14
|
+
export const adminBusinessUpdateSchema = z
|
|
15
|
+
.object({
|
|
16
|
+
id: z.uuid(),
|
|
17
|
+
businessRegistrationStartDate: z.iso.date().optional(),
|
|
18
|
+
companyTaxId: z.string().optional(),
|
|
19
|
+
advanceTaxRates: z.array(taxAdvanceRateSchema).optional(),
|
|
20
|
+
taxAdvancesIds: z.array(yearlyIdSchema).optional(),
|
|
21
|
+
socialSecurityEmployerIds: z.array(yearlyIdSchema).optional(),
|
|
22
|
+
withholdingTaxAnnualIds: z.array(yearlyIdSchema).optional(),
|
|
23
|
+
})
|
|
24
|
+
.strict();
|
|
25
|
+
export const yearlyIdsSchema = z.array(yearlyIdSchema);
|
|
26
|
+
export const taxAdvancesRatesSchema = z.array(taxAdvanceRateSchema);
|
|
27
|
+
//# sourceMappingURL=admin-businesses.helper.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"admin-businesses.helper.js","sourceRoot":"","sources":["../../../../../../src/modules/financial-entities/helpers/admin-businesses.helper.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,MAAM,cAAc,GAAG,CAAC;KACrB,MAAM,CAAC;IACN,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC;IACpC,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,EAAE,EAAE,OAAO,EAAE,gBAAgB,EAAE,CAAC;CACrD,CAAC;KACD,MAAM,EAAE,CAAC;AAEZ,MAAM,oBAAoB,GAAG,CAAC;KAC3B,MAAM,CAAC;IACN,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,IAAI,EAAE;IAClB,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;CAC/B,CAAC;KACD,MAAM,EAAE,CAAC;AAEZ,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC;KACvC,MAAM,CAAC;IACN,EAAE,EAAE,CAAC,CAAC,IAAI,EAAE;IACZ,6BAA6B,EAAE,CAAC,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;IACtD,YAAY,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACnC,eAAe,EAAE,CAAC,CAAC,KAAK,CAAC,oBAAoB,CAAC,CAAC,QAAQ,EAAE;IACzD,cAAc,EAAE,CAAC,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,QAAQ,EAAE;IAClD,yBAAyB,EAAE,CAAC,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,QAAQ,EAAE;IAC7D,uBAAuB,EAAE,CAAC,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC,QAAQ,EAAE;CAC5D,CAAC;KACD,MAAM,EAAE,CAAC;AAIZ,MAAM,CAAC,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,cAAc,CAAC,CAAC;AAEvD,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,oBAAoB,CAAC,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import DataLoader from 'dataloader';
|
|
2
2
|
import { DBProvider } from '../../app-providers/db.provider.js';
|
|
3
|
-
import type { IGetAllAdminBusinessesResult } from '../types.js';
|
|
3
|
+
import type { IGetAllAdminBusinessesResult, IUpdateAdminBusinessesParams, IUpdateAdminBusinessesResult } from '../types.js';
|
|
4
4
|
export declare class AdminBusinessesProvider {
|
|
5
5
|
private dbProvider;
|
|
6
6
|
cache: {
|
|
@@ -16,5 +16,6 @@ export declare class AdminBusinessesProvider {
|
|
|
16
16
|
private batchAdminBusinessesByIds;
|
|
17
17
|
getAdminBusinessByIdLoader: DataLoader<string, import("../types.js").IGetAdminBusinessesByIdsResult | undefined, import("node-cache").Key | import("node-cache").Key[]>;
|
|
18
18
|
getAllAdminBusinesses(): Promise<IGetAllAdminBusinessesResult[]>;
|
|
19
|
+
updateAdminBusiness(params: IUpdateAdminBusinessesParams): Promise<IUpdateAdminBusinessesResult>;
|
|
19
20
|
clearCache(): void;
|
|
20
21
|
}
|