@nomalism-com/types 1.3.28 → 1.3.29

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/index.js CHANGED
@@ -2908,12 +2908,20 @@ var findWithPaginationQuery15 = joi10.object().keys(findWithPaginationQueryKeys1
2908
2908
  var interface_exports21 = {};
2909
2909
  __export(interface_exports21, {
2910
2910
  LowerName: () => LowerName35,
2911
+ ReasonForExemptionTypeEnum: () => ReasonForExemptionTypeEnum,
2911
2912
  Route: () => Route36,
2912
- UpperName: () => UpperName35
2913
+ UpperName: () => UpperName35,
2914
+ reasonForExemptionTypes: () => reasonForExemptionTypes
2913
2915
  });
2914
2916
  var Route36 = "reason_for_exemption";
2915
2917
  var UpperName35 = "ReasonForExemption";
2916
2918
  var LowerName35 = UpperName35[0].toLowerCase() + UpperName35.substring(1);
2919
+ var ReasonForExemptionTypeEnum = {
2920
+ product: "product",
2921
+ client: "client",
2922
+ tenant: "tenant"
2923
+ };
2924
+ var reasonForExemptionTypes = Object.keys(ReasonForExemptionTypeEnum);
2917
2925
 
2918
2926
  // src/modules/user/reasonForExemption/route.schema.ts
2919
2927
  var route_schema_exports40 = {};
@@ -2924,12 +2932,14 @@ __export(route_schema_exports40, {
2924
2932
  updateBody: () => updateBody27
2925
2933
  });
2926
2934
  var createBodyKeys29 = {
2935
+ type: joi10.string().valid(...reasonForExemptionTypes).required(),
2927
2936
  name: joi10.string().required(),
2928
2937
  description: joi10.string().required(),
2929
2938
  saft_code: joi10.string().required()
2930
2939
  };
2931
2940
  var createBody30 = joi10.object().keys(createBodyKeys29).messages(messages);
2932
2941
  var updateBodyKeys27 = {
2942
+ type: joi10.string().valid(...reasonForExemptionTypes).optional(),
2933
2943
  name: joi10.string().optional(),
2934
2944
  description: joi10.string().optional(),
2935
2945
  saft_code: joi10.string().optional()
@@ -4,6 +4,13 @@ export type Entity = ReasonForExemption;
4
4
  export declare const Route = "reason_for_exemption";
5
5
  export declare const UpperName = "ReasonForExemption";
6
6
  export declare const LowerName: string;
7
+ export declare const ReasonForExemptionTypeEnum: {
8
+ product: 'product';
9
+ client: 'client';
10
+ tenant: 'tenant';
11
+ };
12
+ export type IReasonForExemptionType = (typeof ReasonForExemptionTypeEnum)[keyof typeof ReasonForExemptionTypeEnum];
13
+ export declare const reasonForExemptionTypes: string[];
7
14
  type IFindDetailedResponse = Entity;
8
15
  export type IFindByIdResponse = Omit<IFindDetailedResponse, ''>;
9
16
  export type IFindRequest = Record<string, unknown>;
@@ -13,11 +20,13 @@ export interface IFindPaginatedRequest extends IFindRequest, IShared.IPagination
13
20
  export type IFindWithPaginationResponse = IShared.IPaginationResponse<Omit<IFindDetailedResponse, ''>>;
14
21
  export interface ICreateRequest {
15
22
  name: string;
23
+ type: IReasonForExemptionType;
16
24
  description: string;
17
25
  saft_code: string;
18
26
  }
19
27
  export interface IUpdateRequest {
20
28
  name?: string;
29
+ type?: IReasonForExemptionType;
21
30
  description?: string;
22
31
  saft_code?: string;
23
32
  }
@@ -1,4 +1,5 @@
1
1
  import { IPaymentMethodsSaftCodeEnum } from '../../modules/user/paymentMethods/interfaces';
2
+ import type { IReasonForExemptionType } from '../../modules/user/reasonForExemption/interface';
2
3
  /**
3
4
  * Model Users
4
5
  *
@@ -304,6 +305,7 @@ export type Swift = {
304
305
  */
305
306
  export type ReasonForExemption = {
306
307
  id: string;
308
+ type: IReasonForExemptionType;
307
309
  name: string;
308
310
  description: string;
309
311
  saft_code: string;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@nomalism-com/types",
3
3
  "description": "A nomalism package with all necessary types and validations for developing APIs",
4
- "version": "1.3.28",
4
+ "version": "1.3.29",
5
5
  "author": "Nomalism <it.nomalism@gmail.com> (https://nomalism.com/)",
6
6
  "license": "UNLICENSED",
7
7
  "type": "module",
@@ -28,8 +28,8 @@
28
28
  "devDependencies": {
29
29
  "@swc/core": "^1.15.11",
30
30
  "@types/node": "^24.10.13",
31
- "@typescript-eslint/eslint-plugin": "^8.55.0",
32
- "@typescript-eslint/parser": "^8.55.0",
31
+ "@typescript-eslint/eslint-plugin": "^8.56.0",
32
+ "@typescript-eslint/parser": "^8.56.0",
33
33
  "eslint": "^9.39.2",
34
34
  "eslint-config-prettier": "^10.1.8",
35
35
  "eslint-import-resolver-typescript": "^4.4.4",