@forwardslashns/taskit-validation-messages 1.1.0 → 1.2.0
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/dist/validation/features/account-category.validation-messages.d.ts +21 -0
- package/dist/validation/features/account-category.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/account-category.validation-messages.js +23 -0
- package/dist/validation/features/account-id.validation-messages.d.ts +26 -0
- package/dist/validation/features/account-id.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/account-id.validation-messages.js +28 -0
- package/dist/validation/features/address.validation-messages.d.ts +62 -0
- package/dist/validation/features/address.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/address.validation-messages.js +64 -0
- package/dist/validation/features/bank-and-credit-card.validation-messages.d.ts +19 -0
- package/dist/validation/features/bank-and-credit-card.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/bank-and-credit-card.validation-messages.js +21 -0
- package/dist/validation/features/bank.validation-messages.d.ts +7 -0
- package/dist/validation/features/bank.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/bank.validation-messages.js +9 -0
- package/dist/validation/features/business-activity.validation-messages.d.ts +21 -0
- package/dist/validation/features/business-activity.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/business-activity.validation-messages.js +23 -0
- package/dist/validation/features/client-relationship.validation-messages.d.ts +63 -0
- package/dist/validation/features/client-relationship.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/client-relationship.validation-messages.js +65 -0
- package/dist/validation/features/client.validation-messages.d.ts +387 -0
- package/dist/validation/features/client.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/client.validation-messages.js +389 -0
- package/dist/validation/features/commission-detail.validation-messages.d.ts +24 -0
- package/dist/validation/features/commission-detail.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/commission-detail.validation-messages.js +26 -0
- package/dist/validation/features/contact.validation-messages.d.ts +37 -0
- package/dist/validation/features/contact.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/contact.validation-messages.js +39 -0
- package/dist/validation/features/credit-card.validation-messages.d.ts +11 -0
- package/dist/validation/features/credit-card.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/credit-card.validation-messages.js +13 -0
- package/dist/validation/features/data-filter.validation-messages.d.ts +19 -0
- package/dist/validation/features/data-filter.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/data-filter.validation-messages.js +21 -0
- package/dist/validation/features/filing-category.validation-messages.d.ts +21 -0
- package/dist/validation/features/filing-category.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/filing-category.validation-messages.js +23 -0
- package/dist/validation/features/outside-provider.validation-messages.d.ts +13 -0
- package/dist/validation/features/outside-provider.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/outside-provider.validation-messages.js +15 -0
- package/dist/validation/features/role-and-permission.validation-messages.d.ts +32 -0
- package/dist/validation/features/role-and-permission.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/role-and-permission.validation-messages.js +34 -0
- package/dist/validation/features/state.validation-messages.d.ts +49 -0
- package/dist/validation/features/state.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/state.validation-messages.js +51 -0
- package/dist/validation/features/user-preference.validation-messages.d.ts +20 -0
- package/dist/validation/features/user-preference.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/user-preference.validation-messages.js +22 -0
- package/dist/validation/features/user.validation-messages.d.ts +48 -0
- package/dist/validation/features/user.validation-messages.d.ts.map +1 -0
- package/dist/validation/features/user.validation-messages.js +50 -0
- package/dist/validation/validation-messages.d.ts +1 -1
- package/dist/validation/validation-messages.d.ts.map +1 -1
- package/dist/validation/validation-messages.js +36 -866
- package/package.json +1 -1
- package/src/validation/features/account-category.validation-messages.ts +20 -0
- package/src/validation/features/account-id.validation-messages.ts +25 -0
- package/src/validation/features/address.validation-messages.ts +61 -0
- package/src/validation/features/bank-and-credit-card.validation-messages.ts +20 -0
- package/src/validation/features/bank.validation-messages.ts +6 -0
- package/src/validation/features/business-activity.validation-messages.ts +20 -0
- package/src/validation/features/client-relationship.validation-messages.ts +62 -0
- package/src/validation/features/client.validation-messages.ts +386 -0
- package/src/validation/features/commission-detail.validation-messages.ts +23 -0
- package/src/validation/features/contact.validation-messages.ts +36 -0
- package/src/validation/features/credit-card.validation-messages.ts +10 -0
- package/src/validation/features/data-filter.validation-messages.ts +18 -0
- package/src/validation/features/filing-category.validation-messages.ts +20 -0
- package/src/validation/features/outside-provider.validation-messages.ts +12 -0
- package/src/validation/features/role-and-permission.validation-messages.ts +31 -0
- package/src/validation/features/state.validation-messages.ts +48 -0
- package/src/validation/features/user-preference.validation-messages.ts +19 -0
- package/src/validation/features/user.validation-messages.ts +47 -0
- package/src/validation/validation-messages.ts +37 -868
package/package.json
CHANGED
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const ACCOUNT_CATEGORY = {
|
|
2
|
+
INVALID_REQUEST: {
|
|
3
|
+
message: 'Missing account category id in request',
|
|
4
|
+
affectedFields: [],
|
|
5
|
+
},
|
|
6
|
+
ID_DOES_NOT_EXIST: {
|
|
7
|
+
message: `Account category with id '{id}' does not exist`,
|
|
8
|
+
params: ['id'],
|
|
9
|
+
affectedFields: ['accountCategoryId'],
|
|
10
|
+
},
|
|
11
|
+
NAME_ALREADY_EXISTS: {
|
|
12
|
+
message: `Account category with the same name '{name}' already exists`,
|
|
13
|
+
params: ['name'],
|
|
14
|
+
affectedFields: ['name'],
|
|
15
|
+
},
|
|
16
|
+
OPTION_IN_USE: {
|
|
17
|
+
message: `This option is currently in use and cannot be deleted.`,
|
|
18
|
+
affectedFields: [],
|
|
19
|
+
},
|
|
20
|
+
} as const;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export const ACCOUNT_ID = {
|
|
2
|
+
INVALID_REQUEST: {
|
|
3
|
+
message: 'Missing account id identifier in request',
|
|
4
|
+
affectedFields: [],
|
|
5
|
+
},
|
|
6
|
+
ID_DOES_NOT_EXIST: {
|
|
7
|
+
message: `Account id with id '{id}' does not exist`,
|
|
8
|
+
params: ['id'],
|
|
9
|
+
affectedFields: ['accountId'],
|
|
10
|
+
},
|
|
11
|
+
NAME_ALREADY_EXISTS: {
|
|
12
|
+
message: `Account id with the same name '{name}' already exists`,
|
|
13
|
+
params: ['name'],
|
|
14
|
+
affectedFields: ['name'],
|
|
15
|
+
},
|
|
16
|
+
ACCOUNT_CATEGORY_ID_DOES_NOT_EXIST: {
|
|
17
|
+
message: `Account category with id '{id}' does not exist`,
|
|
18
|
+
params: ['id'],
|
|
19
|
+
affectedFields: ['accountCategoryId'],
|
|
20
|
+
},
|
|
21
|
+
OPTION_IN_USE: {
|
|
22
|
+
message: `This option is currently in use and cannot be deleted.`,
|
|
23
|
+
affectedFields: [],
|
|
24
|
+
},
|
|
25
|
+
} as const;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
export const ADDRESS = {
|
|
2
|
+
STATES_NOT_FOUND: {
|
|
3
|
+
message: 'States with ids {ids} do not exist',
|
|
4
|
+
params: ['ids'],
|
|
5
|
+
affectedFields: ['stateId'],
|
|
6
|
+
},
|
|
7
|
+
INVALID_STATE_TYPE: {
|
|
8
|
+
message: `States with ids {ids} are not of type 'State'`,
|
|
9
|
+
params: ['ids'],
|
|
10
|
+
affectedFields: ['stateId'],
|
|
11
|
+
},
|
|
12
|
+
CITIES_NOT_FOUND: {
|
|
13
|
+
message: `Cities with ids {ids} do not exist`,
|
|
14
|
+
params: ['ids'],
|
|
15
|
+
affectedFields: ['cityId'],
|
|
16
|
+
},
|
|
17
|
+
INVALID_CITY_TYPE: {
|
|
18
|
+
message: `Cities with ids {ids} are not of type 'City'`,
|
|
19
|
+
params: ['ids'],
|
|
20
|
+
affectedFields: ['cityId'],
|
|
21
|
+
},
|
|
22
|
+
ZIP_CODES_NOT_FOUND: {
|
|
23
|
+
message: `Zip codes with ids {ids} do not exist`,
|
|
24
|
+
params: ['ids'],
|
|
25
|
+
affectedFields: ['zipCode'],
|
|
26
|
+
},
|
|
27
|
+
CONTACT_ROLES_NOT_FOUND: {
|
|
28
|
+
message: `Contact roles with ids {ids} do not exist`,
|
|
29
|
+
params: ['ids'],
|
|
30
|
+
affectedFields: ['contactRoleId'],
|
|
31
|
+
},
|
|
32
|
+
CONTACT_TYPES_NOT_FOUND: {
|
|
33
|
+
message: `Contact types with ids {ids} do not exist`,
|
|
34
|
+
params: ['ids'],
|
|
35
|
+
affectedFields: ['contactTypeId'],
|
|
36
|
+
},
|
|
37
|
+
LEGAL_ADDRESS_MUST_BE_PROVIDED: {
|
|
38
|
+
message: `The client must have a legal address. Please set the address type to 'Legal'.`,
|
|
39
|
+
affectedFields: ['addresses'],
|
|
40
|
+
},
|
|
41
|
+
MULTIPLE_LEGAL_ADDRESSES_PROVIDED: {
|
|
42
|
+
message: `The client must have only one legal address. Please ensure only one address is set to 'Legal'.`,
|
|
43
|
+
affectedFields: ['addresses'],
|
|
44
|
+
},
|
|
45
|
+
BILLING_ADDRESS_MUST_BE_PROVIDED: {
|
|
46
|
+
message: `The client must have a billing address. Please set the address type to 'Billing'.`,
|
|
47
|
+
affectedFields: ['addresses'],
|
|
48
|
+
},
|
|
49
|
+
MULTIPLE_BILLING_ADDRESSES_PROVIDED: {
|
|
50
|
+
message: `The client must have only one billing address. Please ensure only one address is set to 'Billing'.`,
|
|
51
|
+
affectedFields: ['addresses'],
|
|
52
|
+
},
|
|
53
|
+
PRIMARY_ADDRESS_MUST_BE_PROVIDED: {
|
|
54
|
+
message: `The client must have a primary address. Please set the address type to 'Primary'.`,
|
|
55
|
+
affectedFields: ['addresses'],
|
|
56
|
+
},
|
|
57
|
+
MULTIPLE_PRIMARY_ADDRESSES_PROVIDED: {
|
|
58
|
+
message: `The client must have only one primary address. Please ensure only one address is set to 'Primary'.`,
|
|
59
|
+
affectedFields: ['addresses'],
|
|
60
|
+
},
|
|
61
|
+
} as const;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const BANK_AND_CREDIT_CARD = {
|
|
2
|
+
INVALID_ACCOUNT_NUMBER: {
|
|
3
|
+
message: 'Enter a valid account number.',
|
|
4
|
+
affectedFields: ['accountNumber'],
|
|
5
|
+
},
|
|
6
|
+
INVALID_DESCRIPTION: {
|
|
7
|
+
message:
|
|
8
|
+
'There is another payment method with the same description. Please ensure all payment methods have different descriptions.',
|
|
9
|
+
affectedFields: ['description'],
|
|
10
|
+
},
|
|
11
|
+
NO_DEFAULT_PAYMENT_METHOD: {
|
|
12
|
+
message: 'There must be at least one payment method marked as default. Please select a default payment method.',
|
|
13
|
+
affectedFields: ['paymentMethods'],
|
|
14
|
+
},
|
|
15
|
+
MULTIPLE_DEFAULT_PAYMENT_METHODS: {
|
|
16
|
+
message:
|
|
17
|
+
'There can only be one default payment method. Please ensure only one payment method is marked as default.',
|
|
18
|
+
affectedFields: ['paymentMethods'],
|
|
19
|
+
},
|
|
20
|
+
} as const;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const BUSINESS_ACTIVITY = {
|
|
2
|
+
INVALID_REQUEST: {
|
|
3
|
+
message: 'Missing business activity id in request.',
|
|
4
|
+
affectedFields: [],
|
|
5
|
+
},
|
|
6
|
+
ID_DOES_NOT_EXIST: {
|
|
7
|
+
message: `Business activity with id '{id}' does not exist.`,
|
|
8
|
+
params: ['id'],
|
|
9
|
+
affectedFields: ['businessActivityId'],
|
|
10
|
+
},
|
|
11
|
+
NAME_ALREADY_EXISTS: {
|
|
12
|
+
message: `Business activity with the same name '{name}' already exists.`,
|
|
13
|
+
params: ['name'],
|
|
14
|
+
affectedFields: ['name'],
|
|
15
|
+
},
|
|
16
|
+
OPTION_IN_USE: {
|
|
17
|
+
message: `This option is currently in use and cannot be deleted.`,
|
|
18
|
+
affectedFields: [],
|
|
19
|
+
},
|
|
20
|
+
} as const;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
export const CLIENT_RELATIONSHIP = {
|
|
2
|
+
CURRENT_CLIENT_CANNOT_BE_RELATED_TO_CURRENT_CLIENT: {
|
|
3
|
+
message: `A client cannot have a relationship with itself.`,
|
|
4
|
+
affectedFields: ['relatedClientId'],
|
|
5
|
+
},
|
|
6
|
+
INVALID_RELATIONSHIP_TYPE_FOR_ENTITY_TYPE: {
|
|
7
|
+
message: `{clientName} is a/an {entityType}, which can't have {relationshipType}s. Please update the relationship type.`,
|
|
8
|
+
params: ['clientName', 'entityType', 'relationshipType'],
|
|
9
|
+
affectedFields: ['relationshipTypeId'],
|
|
10
|
+
},
|
|
11
|
+
PARENT_RELATIONSHIP_REQUIRES_FILES_UNDER_PARENT: {
|
|
12
|
+
message: `A Parent relationship can only be added to an entity that files under parent. Please update the Sub/Parent status before adding a parent relationship, or choose a different relationship type.`,
|
|
13
|
+
affectedFields: ['relationshipTypeId', 'filingTypeId'],
|
|
14
|
+
},
|
|
15
|
+
STARTING_DATE_BEFORE_CLIENT_DATE_ESTABLISHED: {
|
|
16
|
+
message: `This relationship's start date cannot be before {clientName}'s date established, {clientDateEstablished}. Please adjust the dates to proceed.`,
|
|
17
|
+
params: ['clientName', 'clientDateEstablished'],
|
|
18
|
+
affectedFields: ['startingDate'],
|
|
19
|
+
},
|
|
20
|
+
STARTING_DATE_ON_OR_AFTER_CLIENT_CLOSE_DATE: {
|
|
21
|
+
message: `This relationship's start date cannot be on or after {clientName}'s close date, {clientCloseDate}. Please adjust the dates to proceed.`,
|
|
22
|
+
params: ['clientName', 'clientCloseDate'],
|
|
23
|
+
affectedFields: ['startingDate'],
|
|
24
|
+
},
|
|
25
|
+
STARTING_DATE_BEFORE_RELATED_CLIENT_DATE_ESTABLISHED: {
|
|
26
|
+
message: `This relationship's start date cannot be before {relatedClientName}'s date established, {relatedClientDateEstablished}. Please adjust the dates to proceed.`,
|
|
27
|
+
params: ['relatedClientName', 'relatedClientDateEstablished'],
|
|
28
|
+
affectedFields: ['startingDate'],
|
|
29
|
+
},
|
|
30
|
+
STARTING_DATE_ON_OR_AFTER_RELATED_CLIENT_CLOSE_DATE: {
|
|
31
|
+
message: `This relationship's start date cannot be on or after {relatedClientName}'s close date, {relatedClientCloseDate}. Please adjust the dates to proceed.`,
|
|
32
|
+
params: ['relatedClientName', 'relatedClientCloseDate'],
|
|
33
|
+
affectedFields: ['startingDate'],
|
|
34
|
+
},
|
|
35
|
+
ENDING_DATE_ON_OR_BEFORE_STARTING_DATE: {
|
|
36
|
+
message: `Please update the relationship ending date to be after the starting date, {startingDate}.`,
|
|
37
|
+
params: ['startingDate'],
|
|
38
|
+
affectedFields: ['endingDate'],
|
|
39
|
+
},
|
|
40
|
+
ENDING_DATE_AFTER_CLIENT_CLOSE_DATE: {
|
|
41
|
+
message: `Please update the relationship ending date to be on or before the client's close date, {clientCloseDate}.`,
|
|
42
|
+
params: ['clientCloseDate'],
|
|
43
|
+
affectedFields: ['endingDate'],
|
|
44
|
+
},
|
|
45
|
+
ENDING_DATE_AFTER_RELATED_CLIENT_CLOSE_DATE: {
|
|
46
|
+
message: `Please update the relationship ending date to be on or before {relatedClientName}'s close date, {relatedClientCloseDate}.`,
|
|
47
|
+
params: ['relatedClientName', 'relatedClientCloseDate'],
|
|
48
|
+
affectedFields: ['endingDate'],
|
|
49
|
+
},
|
|
50
|
+
MULTIPLE_ACTIVE_PARENT_RELATIONSHIPS: {
|
|
51
|
+
message: `All parent relationships besides the current one must have an ending date. Please add an ending date for any parent relationships that are no longer current, before adding this parent relationship.`,
|
|
52
|
+
affectedFields: ['endingDate'],
|
|
53
|
+
},
|
|
54
|
+
FINAL_REQUIRED_WHEN_ENDING_DATE_MATCHES_CLIENT_CLOSE_DATE: {
|
|
55
|
+
message: `The client has a close date that is the same as the relationship ending date, therefore the relationship must be marked as final. Please update the relationship's final status to 'Yes', or adjust the dates.`,
|
|
56
|
+
affectedFields: ['isFinal'],
|
|
57
|
+
},
|
|
58
|
+
FINAL_REQUIRED_WHEN_ENDING_DATE_MATCHES_RELATED_CLIENT_CLOSE_DATE: {
|
|
59
|
+
message: `The related client has a close date that is the same as the relationship ending date, therefore the relationship must be marked as final. Please update the relationship's final status to 'Yes', or adjust the dates.`,
|
|
60
|
+
affectedFields: ['isFinal'],
|
|
61
|
+
},
|
|
62
|
+
} as const;
|
|
@@ -0,0 +1,386 @@
|
|
|
1
|
+
export const CLIENT = {
|
|
2
|
+
INVALID_REQUEST: {
|
|
3
|
+
message: 'Missing client id in request',
|
|
4
|
+
affectedFields: [],
|
|
5
|
+
},
|
|
6
|
+
ID_DOES_NOT_EXIST: {
|
|
7
|
+
message: `Client with id '{id}' does not exist`,
|
|
8
|
+
params: ['id'],
|
|
9
|
+
affectedFields: ['clientId'],
|
|
10
|
+
},
|
|
11
|
+
ACCOUNT_ID_DOES_NOT_EXIST: {
|
|
12
|
+
message: `Account id with id '{id}' does not exist`,
|
|
13
|
+
params: ['id'],
|
|
14
|
+
affectedFields: ['accountId'],
|
|
15
|
+
},
|
|
16
|
+
FILING_CATEGORY_ID_DOES_NOT_EXIST: {
|
|
17
|
+
message: `Filing category with id '{id}' does not exist`,
|
|
18
|
+
params: ['id'],
|
|
19
|
+
affectedFields: ['filingCategoryId'],
|
|
20
|
+
},
|
|
21
|
+
FILING_TYPE_ID_DOES_NOT_EXIST: {
|
|
22
|
+
message: `Parent/Sub status with id '{id}' does not exist`,
|
|
23
|
+
params: ['id'],
|
|
24
|
+
affectedFields: ['filingTypeId'],
|
|
25
|
+
},
|
|
26
|
+
FILING_TYPE_PARENT_REQUIRED: {
|
|
27
|
+
message: `Parent needs to be specified for filing type 'Files under parent'`,
|
|
28
|
+
affectedFields: ['parentClientId'],
|
|
29
|
+
},
|
|
30
|
+
CURRENT_FILING_TYPE_PARENT_REQUIRED: {
|
|
31
|
+
message: `Parent needs to be specified for current filing type 'Files under parent'`,
|
|
32
|
+
affectedFields: ['parentClientId'],
|
|
33
|
+
},
|
|
34
|
+
STATE_ID_DOES_NOT_EXIST: {
|
|
35
|
+
message: `State with id '{id}' does not exist`,
|
|
36
|
+
params: ['id'],
|
|
37
|
+
affectedFields: ['stateId'],
|
|
38
|
+
},
|
|
39
|
+
BUSINESS_ACTIVITY_ID_DOES_NOT_EXIST: {
|
|
40
|
+
message: `Business activity with id '{id}' does not exist`,
|
|
41
|
+
params: ['id'],
|
|
42
|
+
affectedFields: ['businessActivityId'],
|
|
43
|
+
},
|
|
44
|
+
BILLING_TYPE_ID_DOES_NOT_EXIST: {
|
|
45
|
+
message: `Billing type with id '{id}' does not exist`,
|
|
46
|
+
params: ['id'],
|
|
47
|
+
affectedFields: ['billingTypeId'],
|
|
48
|
+
},
|
|
49
|
+
ENTITY_TYPE_ID_DOES_NOT_EXIST: {
|
|
50
|
+
message: `Entity type with id '{id}' does not exist`,
|
|
51
|
+
params: ['id'],
|
|
52
|
+
affectedFields: ['entityTypeId'],
|
|
53
|
+
},
|
|
54
|
+
CLIENT_WITH_SAME_FEDERAL_LEGAL_ID_EXISTS: {
|
|
55
|
+
message: `This ID is already in use. Please enter a different ID.`,
|
|
56
|
+
affectedFields: ['federalLegalId'],
|
|
57
|
+
},
|
|
58
|
+
INVALID_CLIENT_ACTIVITY_STATUS: {
|
|
59
|
+
message: `The 'Is active' field only applies to our clients. Please update the client type to 'Not our client' or update the 'Is active' status to 'Active'.`,
|
|
60
|
+
affectedFields: ['isActive', 'clientType'],
|
|
61
|
+
},
|
|
62
|
+
INVALID_FEDERAL_LEGAL_ID: {
|
|
63
|
+
message: `Enter a valid {legalIdType} (e.g. {legalIdValue})`,
|
|
64
|
+
params: ['legalIdType', 'legalIdValue'],
|
|
65
|
+
affectedFields: ['federalLegalId'],
|
|
66
|
+
},
|
|
67
|
+
NAME_ALREADY_EXISTS: {
|
|
68
|
+
message: `Client with the same name '{name}' already exists`,
|
|
69
|
+
params: ['name'],
|
|
70
|
+
affectedFields: ['name'],
|
|
71
|
+
},
|
|
72
|
+
NOT_ALIGNED_DATE_ESTABLISHED_ENTITY_TYPE_STARTING_DATE: {
|
|
73
|
+
message: `One or more entity types have a start date that is before the client's date established, {clientDateEstablished}. ({entityType} starting {entityTypeStartingDate}). Please update the entity type start dates to be on or after the client's date established, or update the client's date established.`,
|
|
74
|
+
params: ['clientDateEstablished', 'entityType', 'entityTypeStartingDate'],
|
|
75
|
+
affectedFields: ['dateEstablished', 'entityTypes'],
|
|
76
|
+
},
|
|
77
|
+
NOT_ALIGNED_DATE_ESTABLISHED_FILING_TYPE_STARTING_DATE: {
|
|
78
|
+
message: `The Parent/Sub status {filingType} starts on {filingTypeStartingDate} which is earlier than the client's date established, {clientDateEstablished}. Please adjust the start date of the Parent/Sub status or the client's date established.`,
|
|
79
|
+
params: ['clientDateEstablished', 'filingType', 'filingTypeStartingDate'],
|
|
80
|
+
affectedFields: ['dateEstablished', 'filingTypes'],
|
|
81
|
+
},
|
|
82
|
+
NOT_ALIGNED_DATE_ESTABLISHED_DOMESTIC_STATE_STARTING_DATE: {
|
|
83
|
+
message: `The state, {domesticState}, starts on {domesticStateStartingDate}, which is earlier than the client's date established, {clientDateEstablished}. Please adjust the start date of the state or the client's date established.`,
|
|
84
|
+
params: ['clientDateEstablished', 'domesticState', 'domesticStateStartingDate'],
|
|
85
|
+
affectedFields: ['dateEstablished', 'domesticStates'],
|
|
86
|
+
},
|
|
87
|
+
NOT_ALIGNED_DATE_ESTABLISHED_CLOSE_DATE: {
|
|
88
|
+
message: `Adjust the close date to be after the date established.`,
|
|
89
|
+
affectedFields: ['dateEstablished', 'closeDate'],
|
|
90
|
+
},
|
|
91
|
+
NOT_ALIGNED_CLOSE_DATE_ENTITY_TYPE_STARTING_DATE: {
|
|
92
|
+
message: `One or more entity types have start dates that are after the client's close date, {clientCloseDate}. {entityType} starting {entityTypeStartingDate}. Please update the entity type/s end date/s to be on or before the client's close date, or update the client's close date.`,
|
|
93
|
+
params: ['clientCloseDate', 'entityType', 'entityTypeStartingDate'],
|
|
94
|
+
affectedFields: ['closeDate', 'entityTypes'],
|
|
95
|
+
},
|
|
96
|
+
NOT_ALIGNED_CLOSE_DATE_FILING_TYPE_STARTING_DATE: {
|
|
97
|
+
message: `One or more Parent/Sub status have a start date which is after the client's close date of {clientCloseDate}. {filingType}, starting {filingTypeStartingDate}. Please update the start date to be earlier than the client's close date, or update the client's close date.`,
|
|
98
|
+
params: ['clientCloseDate', 'filingType', 'filingTypeStartingDate'],
|
|
99
|
+
affectedFields: ['closeDate', 'filingTypes'],
|
|
100
|
+
},
|
|
101
|
+
ENTITY_TYPE_STARTING_DATE_NOT_POPULATED: {
|
|
102
|
+
message: `Current Entity Type Starting Date cannot be Empty`,
|
|
103
|
+
affectedFields: ['entityTypeStartingDate'],
|
|
104
|
+
},
|
|
105
|
+
FILING_TYPE_STARTING_DATE_NOT_POPULATED: {
|
|
106
|
+
message: `Current Parent/Sub status Starting Date cannot be Empty`,
|
|
107
|
+
affectedFields: ['filingTypeStartingDate'],
|
|
108
|
+
},
|
|
109
|
+
DOMESTIC_STATE_STARTING_DATE_NOT_POPULATED: {
|
|
110
|
+
message: `Current Domestic State Starting Date cannot be Empty`,
|
|
111
|
+
affectedFields: ['domesticStateStartingDate'],
|
|
112
|
+
},
|
|
113
|
+
NOT_ALIGNED_ENTITY_TYPE_STARTING_ENDING_DATE: {
|
|
114
|
+
message: `Entity type starting date needs to be before the ending date`,
|
|
115
|
+
affectedFields: ['entityTypeStartingDate', 'entityTypeEndingDate'],
|
|
116
|
+
},
|
|
117
|
+
NOT_ALIGNED_FILING_TYPE_STARTING_ENDING_DATE: {
|
|
118
|
+
message: `Parent/Sub status starting date needs to be before the ending date`,
|
|
119
|
+
affectedFields: ['filingTypeStartingDate', 'filingTypeEndingDate'],
|
|
120
|
+
},
|
|
121
|
+
NOT_ALIGNED_CLOSE_DATE_DOMESTIC_STATE_STARTING_DATE: {
|
|
122
|
+
message: `One or more states have a start date which is after the client's close date of {clientCloseDate}. {domesticState} starting {domesticStateStartingDate}. Please update the state/s start date/s to be before the client's close date, or update the client's close date.`,
|
|
123
|
+
params: ['clientCloseDate', 'domesticState', 'domesticStateStartingDate'],
|
|
124
|
+
affectedFields: ['closeDate', 'domesticStates'],
|
|
125
|
+
},
|
|
126
|
+
CLIENT_COULD_NOT_BE_LOCKED_WITHOUT_ACCOUNT_ID: {
|
|
127
|
+
message: `Choose an Account ID`,
|
|
128
|
+
affectedFields: ['accountId'],
|
|
129
|
+
},
|
|
130
|
+
CLIENT_COULD_NOT_BE_LOCKED_WITHOUT_BUSINESS_ACTIVITY_ID: {
|
|
131
|
+
message: `Choose a Business Activity`,
|
|
132
|
+
affectedFields: ['businessActivityId'],
|
|
133
|
+
},
|
|
134
|
+
CLIENT_COULD_NOT_BE_LOCKED_WITHOUT_BILLING_TYPE_ID: {
|
|
135
|
+
message: `Choose a Billing Type`,
|
|
136
|
+
affectedFields: ['billingTypeId'],
|
|
137
|
+
},
|
|
138
|
+
CLIENT_COULD_NOT_BE_LOCKED_WITHOUT_FILING_CATEGORY_ID: {
|
|
139
|
+
message: `Choose a Filing Category`,
|
|
140
|
+
affectedFields: ['filingCategoryId'],
|
|
141
|
+
},
|
|
142
|
+
CLIENT_COULD_NOT_BE_LOCKED_WITHOUT_CONTACT: {
|
|
143
|
+
message: `Create a Contact - One contact needs to have been saved to this client`,
|
|
144
|
+
affectedFields: ['contacts'],
|
|
145
|
+
},
|
|
146
|
+
CLIENT_COULD_NOT_BE_LOCKED_WITHOUT_ADDRESS: {
|
|
147
|
+
message: `Create an Address - One address needs to have been saved to this client`,
|
|
148
|
+
affectedFields: ['addresses'],
|
|
149
|
+
},
|
|
150
|
+
CLIENT_COULD_NOT_BE_DELETED_CLIENT_RELATIONSHIP_EXIST: {
|
|
151
|
+
message: `This client cannot be deleted because it has client relationships associated`,
|
|
152
|
+
affectedFields: [],
|
|
153
|
+
},
|
|
154
|
+
CLIENT_COULD_NOT_BE_DELETED_CLIENT_PROJECT_TEMPLATES_EXIST: {
|
|
155
|
+
message: `This client cannot be deleted because it has client project templates associated`,
|
|
156
|
+
affectedFields: [],
|
|
157
|
+
},
|
|
158
|
+
CLIENT_COULD_NOT_BE_DELETED_ADDITIONAL_INFORMATION_EXIST: {
|
|
159
|
+
message: `This client cannot be deleted because it has additional information associated`,
|
|
160
|
+
affectedFields: [],
|
|
161
|
+
},
|
|
162
|
+
CLIENT_COULD_NOT_BE_DELETED_BANK_ACCOUNTS_EXIST: {
|
|
163
|
+
message: `This client cannot be deleted because it has bank accounts associated`,
|
|
164
|
+
affectedFields: [],
|
|
165
|
+
},
|
|
166
|
+
CLIENT_COULD_NOT_BE_DELETED_CREDIT_CARDS_EXIST: {
|
|
167
|
+
message: `This client cannot be deleted because it has credit cards associated`,
|
|
168
|
+
affectedFields: [],
|
|
169
|
+
},
|
|
170
|
+
CLIENT_COULD_NOT_BE_DELETED_WORKLOGS_EXIST: {
|
|
171
|
+
message: `This client cannot be deleted because it has worklogs associated`,
|
|
172
|
+
affectedFields: [],
|
|
173
|
+
},
|
|
174
|
+
CLIENT_COULD_NOT_BE_DELETED_INVOICES_EXIST: {
|
|
175
|
+
message: `This client cannot be deleted because it has invoices associated`,
|
|
176
|
+
affectedFields: [],
|
|
177
|
+
},
|
|
178
|
+
CLIENT_COULD_NOT_BE_DELETED_PAYMENTS_EXIST: {
|
|
179
|
+
message: `This client cannot be deleted because it has payments associated`,
|
|
180
|
+
affectedFields: [],
|
|
181
|
+
},
|
|
182
|
+
CLIENT_COULD_NOT_BE_DELETED_DOCUMENTS_EXIST: {
|
|
183
|
+
message: `This client cannot be deleted because it has documents associated`,
|
|
184
|
+
affectedFields: [],
|
|
185
|
+
},
|
|
186
|
+
CLIENT_COULD_NOT_BE_DELETED_JOURNALS_EXIST: {
|
|
187
|
+
message: `This client cannot be deleted because it has journals associated`,
|
|
188
|
+
affectedFields: [],
|
|
189
|
+
},
|
|
190
|
+
CLIENT_COULD_NOT_BE_DELETED_FUTURES_EXIST: {
|
|
191
|
+
message: `This client cannot be deleted because it has futures associated`,
|
|
192
|
+
affectedFields: [],
|
|
193
|
+
},
|
|
194
|
+
CLIENT_COULD_NOT_BE_DELETED_PROJECTS_EXIST: {
|
|
195
|
+
message: `This client cannot be deleted because it has projects associated`,
|
|
196
|
+
affectedFields: [],
|
|
197
|
+
},
|
|
198
|
+
CLIENT_COULD_NOT_BE_DELETED_TASKS_EXIST: {
|
|
199
|
+
message: `This client cannot be deleted because it has tasks associated`,
|
|
200
|
+
affectedFields: [],
|
|
201
|
+
},
|
|
202
|
+
CLIENT_COULD_NOT_BE_DELETED_ADDRESSES_EXIST: {
|
|
203
|
+
message: `This client cannot be deleted because it has addresses associated`,
|
|
204
|
+
affectedFields: [],
|
|
205
|
+
},
|
|
206
|
+
CLIENT_COULD_NOT_BE_DELETED_CONTACTS_EXIST: {
|
|
207
|
+
message: `This client cannot be deleted because it has contacts associated`,
|
|
208
|
+
affectedFields: [],
|
|
209
|
+
},
|
|
210
|
+
ENTITY_TYPES_IDS_DOES_NOT_EXIST: {
|
|
211
|
+
message: `Entity types with ids '{ids}' do not exist`,
|
|
212
|
+
params: ['ids'],
|
|
213
|
+
affectedFields: ['entityTypeId'],
|
|
214
|
+
},
|
|
215
|
+
AT_LEAST_ONE_ENTITY_TYPE_SHOULD_EXIST: {
|
|
216
|
+
message: `At least one entity type should exist`,
|
|
217
|
+
affectedFields: ['entityTypes'],
|
|
218
|
+
},
|
|
219
|
+
ENTITY_TYPES_STARTING_DATE_NOT_POPULATED: {
|
|
220
|
+
message: `Starting date for {entityType} cannot be empty`,
|
|
221
|
+
params: ['entityType'],
|
|
222
|
+
affectedFields: ['entityTypeStartingDate'],
|
|
223
|
+
},
|
|
224
|
+
NOT_ALIGNED_ENTITY_TYPES_STARTING_ENDING_DATE: {
|
|
225
|
+
message: `The ending date for {entityType} must be after its starting date`,
|
|
226
|
+
params: ['entityType'],
|
|
227
|
+
affectedFields: ['entityTypeStartingDate', 'entityTypeEndingDate'],
|
|
228
|
+
},
|
|
229
|
+
NOT_ALIGNED_DATE_ESTABLISHED_ENTITY_TYPES_STARTING_DATE: {
|
|
230
|
+
message: `Adjust the start date to be on or after the client's date established, {clientStartDate}.`,
|
|
231
|
+
params: ['clientStartDate'],
|
|
232
|
+
affectedFields: ['entityTypeStartingDate', 'dateEstablished'],
|
|
233
|
+
},
|
|
234
|
+
NOT_ALIGNED_CLOSE_DATE_ENTITY_TYPES_STARTING_DATE: {
|
|
235
|
+
message: `Adjust the start date to be before the client's close date, {clientCloseDate}.`,
|
|
236
|
+
params: ['clientCloseDate'],
|
|
237
|
+
affectedFields: ['entityTypeStartingDate', 'closeDate'],
|
|
238
|
+
},
|
|
239
|
+
ENTITY_TYPES_DATE_GAP_DETECTED: {
|
|
240
|
+
message: `There is a gap in the timeframes between {currentEntityType}, ending {currentEntityTypeEndDate}, and {nextEntityType}, starting {nextEntityTypeStartDate}. Please adjust the dates to fill this gap.`,
|
|
241
|
+
params: ['currentEntityType', 'currentEntityTypeEndDate', 'nextEntityType', 'nextEntityTypeStartDate'],
|
|
242
|
+
affectedFields: ['entityTypes'],
|
|
243
|
+
},
|
|
244
|
+
ENTITY_TYPES_CONSECUTIVE_DUPLICATES_DETECTED: {
|
|
245
|
+
message: `There are two entries for {entityType} with timeframes that immediately follow each other. {entityType} ending {firstPeriodEnd}, and {entityType} starting {secondPeriodStart}. Please update one entry to include the entire timeframe for {entityType}. `,
|
|
246
|
+
params: ['entityType', 'firstPeriodStart', 'firstPeriodEnd', 'secondPeriodStart'],
|
|
247
|
+
affectedFields: ['entityTypes'],
|
|
248
|
+
},
|
|
249
|
+
ENTITY_TYPE_EARLIEST_AND_DATE_ESTABLISHED_GAP_DETECTED: {
|
|
250
|
+
message: `There is a gap between the client's date established ({dateEstablished}) and the start of its first entity type ({earliestEntityType} starting {earliestEntityTypeStartDate}). There must be an entity type that begins on {dateEstablished}.`,
|
|
251
|
+
params: ['dateEstablished', 'earliestEntityType', 'earliestEntityTypeStartDate'],
|
|
252
|
+
affectedFields: ['entityTypes', 'dateEstablished'],
|
|
253
|
+
},
|
|
254
|
+
ENTITY_TYPES_DATES_OVERLAP: {
|
|
255
|
+
message: `The client already has {entityType} starting from {startDate2} to {endDate2}. Your current entity type overlaps with that time. Please adjust the dates so they don't overlap.`,
|
|
256
|
+
params: ['entityType', 'startDate1', 'endDate1', 'startDate2', 'endDate2'],
|
|
257
|
+
affectedFields: ['entityTypes'],
|
|
258
|
+
},
|
|
259
|
+
ALL_NON_LAST_ENTITY_TYPES_REQUIRE_ENDING_DATE: {
|
|
260
|
+
message: `Only the last entity type can be open without an end date. Add an ending date to the existing entity type before adding a start date for a new entity type.`,
|
|
261
|
+
affectedFields: ['entityTypeEndingDate'],
|
|
262
|
+
},
|
|
263
|
+
CURRENT_ENTITY_TYPE_CANNOT_HAVE_ENDING_DATE: {
|
|
264
|
+
message: `The current entity type cannot have an end date. Please remove the end date for this state.`,
|
|
265
|
+
affectedFields: ['entityTypeEndingDate'],
|
|
266
|
+
},
|
|
267
|
+
FILING_TYPES_IDS_DOES_NOT_EXIST: {
|
|
268
|
+
message: `Parent/Sub status with ids '{ids}' do not exist`,
|
|
269
|
+
params: ['ids'],
|
|
270
|
+
affectedFields: ['filingTypeId'],
|
|
271
|
+
},
|
|
272
|
+
AT_LEAST_ONE_FILING_TYPE_SHOULD_EXIST: {
|
|
273
|
+
message: `At least one Parent/Sub status should exist`,
|
|
274
|
+
affectedFields: ['filingTypes'],
|
|
275
|
+
},
|
|
276
|
+
FILING_TYPES_STARTING_DATE_NOT_POPULATED: {
|
|
277
|
+
message: `Starting date for {filingType} cannot be empty`,
|
|
278
|
+
params: ['filingType'],
|
|
279
|
+
affectedFields: ['filingTypeStartingDate'],
|
|
280
|
+
},
|
|
281
|
+
NOT_ALIGNED_FILING_TYPES_STARTING_ENDING_DATE: {
|
|
282
|
+
message: `The ending date for {filingType} must be after its starting date`,
|
|
283
|
+
params: ['filingType'],
|
|
284
|
+
affectedFields: ['filingTypeStartingDate', 'filingTypeEndingDate'],
|
|
285
|
+
},
|
|
286
|
+
NOT_ALIGNED_DATE_ESTABLISHED_FILING_TYPES_STARTING_DATE: {
|
|
287
|
+
message: `Adjust the start date to be on or after the client's date established, {clientStartDate}.`,
|
|
288
|
+
params: ['clientStartDate'],
|
|
289
|
+
affectedFields: ['filingTypeStartingDate', 'dateEstablished'],
|
|
290
|
+
},
|
|
291
|
+
NOT_ALIGNED_CLOSE_DATE_FILING_TYPES_STARTING_DATE: {
|
|
292
|
+
message: `Adjust the start date to be before the client's close date, {clientCloseDate}.`,
|
|
293
|
+
params: ['clientCloseDate'],
|
|
294
|
+
affectedFields: ['filingTypeStartingDate', 'closeDate'],
|
|
295
|
+
},
|
|
296
|
+
FILING_TYPES_DATE_GAP_DETECTED: {
|
|
297
|
+
message: `There is a gap in the timeframes between {currentFilingType}, ending {currentFilingTypeEndDate}, and {nextFilingType}, starting {nextFilingTypeStartDate}. Please adjust the dates to fill this gap.`,
|
|
298
|
+
params: ['currentFilingType', 'currentFilingTypeEndDate', 'nextFilingType', 'nextFilingTypeStartDate'],
|
|
299
|
+
affectedFields: ['filingTypes'],
|
|
300
|
+
},
|
|
301
|
+
FILING_TYPES_CONSECUTIVE_DUPLICATES_DETECTED: {
|
|
302
|
+
message: `There are two entries for {filingType} with timeframes that immediately follow each other. {filingType} ending {firstPeriodEnd}, and {filingType} starting {secondPeriodStart}. Please update one entry to include the entire timeframe for {filingType}. `,
|
|
303
|
+
params: ['filingType', 'firstPeriodStart', 'firstPeriodEnd', 'secondPeriodStart'],
|
|
304
|
+
affectedFields: ['filingTypes'],
|
|
305
|
+
},
|
|
306
|
+
FILING_TYPE_EARLIEST_AND_DATE_ESTABLISHED_GAP_DETECTED: {
|
|
307
|
+
message: `There is a gap between the client's date established ({dateEstablished}) and the start of its first Parent/Sub status ({earliestFilingType} starting {earliestFilingTypeStartDate}). There must be a Parent/Sub status that begins on {dateEstablished}.`,
|
|
308
|
+
params: ['dateEstablished', 'earliestFilingType', 'earliestFilingTypeStartDate'],
|
|
309
|
+
affectedFields: ['filingTypes', 'dateEstablished'],
|
|
310
|
+
},
|
|
311
|
+
FILING_TYPES_DATES_OVERLAP: {
|
|
312
|
+
message: `The client already has {filingType} starting from {startDate2} to {endDate2}. Your current entity type overlaps with that time. Please adjust the dates so they don't overlap.`,
|
|
313
|
+
params: ['filingType', 'startDate1', 'endDate1', 'startDate2', 'endDate2'],
|
|
314
|
+
affectedFields: ['filingTypes'],
|
|
315
|
+
},
|
|
316
|
+
ALL_NON_LAST_FILING_TYPES_REQUIRE_ENDING_DATE: {
|
|
317
|
+
message: `Only the last Parent/Sub status can be open without an end date. Add an ending date to the existing Parent/Sub status before adding a start date for a new Parent/Sub status.`,
|
|
318
|
+
affectedFields: ['filingTypeEndingDate'],
|
|
319
|
+
},
|
|
320
|
+
CURRENT_FILING_TYPE_CANNOT_HAVE_ENDING_DATE: {
|
|
321
|
+
message: `The current Parent/Sub status cannot have an end date. Please remove the end date for this state.`,
|
|
322
|
+
affectedFields: ['filingTypeEndingDate'],
|
|
323
|
+
},
|
|
324
|
+
STATES_IDS_DOES_NOT_EXIST: {
|
|
325
|
+
message: `States with ids '{ids}' do not exist`,
|
|
326
|
+
params: ['ids'],
|
|
327
|
+
affectedFields: ['stateId'],
|
|
328
|
+
},
|
|
329
|
+
RESIDENCE_TYPE_DOES_NOT_EXIST: {
|
|
330
|
+
message: `Residence type with ids '{ids}' does not exist`,
|
|
331
|
+
params: ['ids'],
|
|
332
|
+
affectedFields: ['residenceTypeId'],
|
|
333
|
+
},
|
|
334
|
+
AT_LEAST_ONE_DOMESTIC_STATE_SHOULD_EXIST: {
|
|
335
|
+
message: `At least one domestic state should exist`,
|
|
336
|
+
affectedFields: ['domesticStates'],
|
|
337
|
+
},
|
|
338
|
+
STATES_STARTING_DATE_NOT_POPULATED: {
|
|
339
|
+
message: `Starting date for {state} cannot be empty`,
|
|
340
|
+
params: ['state'],
|
|
341
|
+
affectedFields: ['stateStartingDate'],
|
|
342
|
+
},
|
|
343
|
+
NOT_ALIGNED_STATES_STARTING_ENDING_DATE: {
|
|
344
|
+
message: `The ending date for {state} must be after its starting date`,
|
|
345
|
+
params: ['state'],
|
|
346
|
+
affectedFields: ['stateStartingDate', 'stateEndingDate'],
|
|
347
|
+
},
|
|
348
|
+
NOT_ALIGNED_DATE_ESTABLISHED_STATES_STARTING_DATE: {
|
|
349
|
+
message: `Adjust the start date to be on or after the client's date established, {clientStartDate}.`,
|
|
350
|
+
params: ['clientStartDate'],
|
|
351
|
+
affectedFields: ['stateStartingDate', 'dateEstablished'],
|
|
352
|
+
},
|
|
353
|
+
NOT_ALIGNED_CLOSE_DATE_STATES_STARTING_DATE: {
|
|
354
|
+
message: `Adjust the start date to be before the client's close date, {clientCloseDate}.`,
|
|
355
|
+
params: ['clientCloseDate'],
|
|
356
|
+
affectedFields: ['stateStartingDate', 'closeDate'],
|
|
357
|
+
},
|
|
358
|
+
DOMESTIC_STATES_DATE_GAP_DETECTED: {
|
|
359
|
+
message: `There is a gap in the timeframes between {currentState}, ending {currentStateEndDate}, and {nextState}, starting {nextStateStartDate}. Please adjust the dates to fill this gap.`,
|
|
360
|
+
params: ['currentState', 'currentStateEndDate', 'nextState', 'nextStateStartDate'],
|
|
361
|
+
affectedFields: ['domesticStates'],
|
|
362
|
+
},
|
|
363
|
+
STATES_CONSECUTIVE_DUPLICATES_DETECTED: {
|
|
364
|
+
message: `There are two entries for {state} with timeframes that immediately follow each other. {state} ending {firstPeriodEnd}, and {state} starting {secondPeriodStart}. Please update one entry to include the entire timeframe for {state}. `,
|
|
365
|
+
params: ['state', 'firstPeriodStart', 'firstPeriodEnd', 'secondPeriodStart'],
|
|
366
|
+
affectedFields: ['domesticStates'],
|
|
367
|
+
},
|
|
368
|
+
DOMESTIC_STATE_EARLIEST_AND_DATE_ESTABLISHED_GAP_DETECTED: {
|
|
369
|
+
message: `There is a gap between the client's date established ({dateEstablished}) and the start of its first state ({earliestState} starting {earliestStateStartDate}). There must be a state that begins on {dateEstablished}.`,
|
|
370
|
+
params: ['dateEstablished', 'earliestState', 'earliestStateStartDate'],
|
|
371
|
+
affectedFields: ['domesticStates', 'dateEstablished'],
|
|
372
|
+
},
|
|
373
|
+
STATES_DATES_OVERLAP: {
|
|
374
|
+
message: `The client already has {state} starting from {startDate2} to {endDate2}. Your current entity type overlaps with that time. Please adjust the dates so they don't overlap.`,
|
|
375
|
+
params: ['state', 'startDate1', 'endDate1', 'startDate2', 'endDate2'],
|
|
376
|
+
affectedFields: ['domesticStates'],
|
|
377
|
+
},
|
|
378
|
+
ALL_NON_LAST_DOMESTIC_STATES_REQUIRE_ENDING_DATE: {
|
|
379
|
+
message: `Only the last domestic state can be open without an end date. Add an ending date to the existing state before adding a start date for a new state.`,
|
|
380
|
+
affectedFields: ['stateEndingDate'],
|
|
381
|
+
},
|
|
382
|
+
CURRENT_DOMESTIC_STATE_CANNOT_HAVE_ENDING_DATE: {
|
|
383
|
+
message: `The current domestic state cannot have an end date. Please remove the end date for this state.`,
|
|
384
|
+
affectedFields: ['stateEndingDate'],
|
|
385
|
+
},
|
|
386
|
+
} as const;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export const COMISSION_DETAIL = {
|
|
2
|
+
INVALID_REQUEST_IS_SUBJECT_TO_COMMISSION: {
|
|
3
|
+
message: 'If client is subject to commission, sales representative and commission rate must be provided.',
|
|
4
|
+
affectedFields: ['isSubjectToCommission', 'salesRepresentativeId', 'commissionRate'],
|
|
5
|
+
},
|
|
6
|
+
INVALID_REQUEST_IS_NOT_SUBJECT_TO_COMMISSION: {
|
|
7
|
+
message: 'If client is not subject to commission, sales representative and commission rate must not be provided.',
|
|
8
|
+
affectedFields: ['isSubjectToCommission', 'salesRepresentativeId', 'commissionRate'],
|
|
9
|
+
},
|
|
10
|
+
SALES_REPRESENTATIVE_DOES_NOT_EXIST: {
|
|
11
|
+
message: `Sales representative with id '{id}' does not exist`,
|
|
12
|
+
params: ['id'],
|
|
13
|
+
affectedFields: ['salesRepresentativeId'],
|
|
14
|
+
},
|
|
15
|
+
COMISSION_RATE_TOO_LOW: {
|
|
16
|
+
message: `Enter a commission value greater than 0.0`,
|
|
17
|
+
affectedFields: ['commissionRate'],
|
|
18
|
+
},
|
|
19
|
+
COMISSION_RATE_TOO_HIGH: {
|
|
20
|
+
message: `Enter a value less than 100%.`,
|
|
21
|
+
affectedFields: ['commissionRate'],
|
|
22
|
+
},
|
|
23
|
+
} as const;
|