qeai-sdk 2.0.0 → 2.0.1

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.
Files changed (219) hide show
  1. package/dist/constants/index.d.ts +14 -12
  2. package/dist/constants/index.js +16 -12
  3. package/dist/constants/product-commands.constant.d.ts +6 -0
  4. package/dist/constants/product-commands.constant.js +6 -0
  5. package/dist/constants/services-config.constant.d.ts +3 -0
  6. package/dist/constants/services-config.constant.js +1 -0
  7. package/dist/constants/translation-commands.constant.d.ts +35 -0
  8. package/dist/constants/translation-commands.constant.js +35 -0
  9. package/dist/dtos/auth/index.d.ts +2 -2
  10. package/dist/dtos/auth/index.js +2 -2
  11. package/dist/dtos/categories/index.d.ts +3 -3
  12. package/dist/dtos/categories/index.js +3 -3
  13. package/dist/dtos/categories/update-category.dto.d.ts +21 -4
  14. package/dist/dtos/categories/update-category.dto.js +39 -7
  15. package/dist/dtos/chain/create-chain.dto.d.ts +1 -1
  16. package/dist/dtos/chain/create-chain.dto.js +1 -1
  17. package/dist/dtos/chain/index.d.ts +3 -3
  18. package/dist/dtos/chain/index.js +3 -3
  19. package/dist/dtos/chain/update-chain.dto.d.ts +27 -3
  20. package/dist/dtos/chain/update-chain.dto.js +45 -4
  21. package/dist/dtos/common/index.d.ts +2 -1
  22. package/dist/dtos/common/index.js +2 -1
  23. package/dist/dtos/common/search-by-name.dto.d.ts +4 -0
  24. package/dist/dtos/common/search-by-name.dto.js +19 -0
  25. package/dist/dtos/index.d.ts +12 -12
  26. package/dist/dtos/index.js +12 -12
  27. package/dist/dtos/ingredients/index.d.ts +4 -4
  28. package/dist/dtos/ingredients/index.js +4 -4
  29. package/dist/dtos/ingredients/search-by-name.dto.d.ts +1 -1
  30. package/dist/dtos/ingredients/search-by-name.dto.js +1 -1
  31. package/dist/dtos/ingredients/update-ingredient.dto.d.ts +15 -3
  32. package/dist/dtos/ingredients/update-ingredient.dto.js +28 -4
  33. package/dist/dtos/orders/change-order-status.dto.d.ts +1 -1
  34. package/dist/dtos/orders/change-order-status.dto.js +1 -1
  35. package/dist/dtos/orders/create-order.dto.d.ts +2 -2
  36. package/dist/dtos/orders/create-order.dto.js +2 -2
  37. package/dist/dtos/orders/index.d.ts +5 -6
  38. package/dist/dtos/orders/index.js +5 -6
  39. package/dist/dtos/orders/order-pagination.dto.d.ts +2 -2
  40. package/dist/dtos/orders/order-pagination.dto.js +2 -2
  41. package/dist/dtos/payments/index.d.ts +3 -3
  42. package/dist/dtos/payments/index.js +3 -3
  43. package/dist/dtos/payments/payment-session.dto.d.ts +1 -1
  44. package/dist/dtos/payments/payment-session.dto.js +1 -1
  45. package/dist/dtos/products/create-product.dto.d.ts +1 -1
  46. package/dist/dtos/products/create-product.dto.js +1 -1
  47. package/dist/dtos/products/index.d.ts +4 -4
  48. package/dist/dtos/products/index.js +4 -4
  49. package/dist/dtos/products/submodules/index.d.ts +6 -6
  50. package/dist/dtos/products/submodules/index.js +6 -6
  51. package/dist/dtos/products/submodules/product-image/bulk-create-product-image.dto.d.ts +1 -1
  52. package/dist/dtos/products/submodules/product-image/bulk-create-product-image.dto.js +1 -1
  53. package/dist/dtos/products/submodules/product-image/index.d.ts +4 -4
  54. package/dist/dtos/products/submodules/product-image/index.js +4 -4
  55. package/dist/dtos/products/submodules/product-question/create-product-question.dto.d.ts +1 -1
  56. package/dist/dtos/products/submodules/product-question/create-product-question.dto.js +1 -1
  57. package/dist/dtos/products/submodules/product-question/find-by-product-id-and-type.dto.d.ts +1 -1
  58. package/dist/dtos/products/submodules/product-question/find-by-product-id-and-type.dto.js +1 -1
  59. package/dist/dtos/products/submodules/product-question/index.d.ts +4 -4
  60. package/dist/dtos/products/submodules/product-question/index.js +4 -4
  61. package/dist/dtos/products/submodules/product-question/replace-by-product-id.dto.d.ts +1 -1
  62. package/dist/dtos/products/submodules/product-question/replace-by-product-id.dto.js +1 -1
  63. package/dist/dtos/products/submodules/product-question/update-product-question.dto.d.ts +1 -1
  64. package/dist/dtos/products/submodules/product-question/update-product-question.dto.js +1 -1
  65. package/dist/dtos/products/submodules/product-recipe/index.d.ts +3 -3
  66. package/dist/dtos/products/submodules/product-recipe/index.js +3 -3
  67. package/dist/dtos/products/submodules/product-recipe/replace-by-product-id.dto.d.ts +1 -1
  68. package/dist/dtos/products/submodules/product-recipe/replace-by-product-id.dto.js +1 -1
  69. package/dist/dtos/products/submodules/product-schedule/index.d.ts +4 -4
  70. package/dist/dtos/products/submodules/product-schedule/index.js +4 -4
  71. package/dist/dtos/products/submodules/product-schedule/replace-by-product-id.dto.d.ts +1 -1
  72. package/dist/dtos/products/submodules/product-schedule/replace-by-product-id.dto.js +1 -1
  73. package/dist/dtos/products/submodules/product-size/index.d.ts +4 -4
  74. package/dist/dtos/products/submodules/product-size/index.js +4 -4
  75. package/dist/dtos/products/submodules/product-size/replace-by-product-id.dto.d.ts +1 -1
  76. package/dist/dtos/products/submodules/product-size/replace-by-product-id.dto.js +1 -1
  77. package/dist/dtos/products/submodules/product-tag/index.d.ts +4 -4
  78. package/dist/dtos/products/submodules/product-tag/index.js +4 -4
  79. package/dist/dtos/products/update-product.dto.d.ts +38 -3
  80. package/dist/dtos/products/update-product.dto.js +69 -4
  81. package/dist/dtos/questions/create-question.dto.d.ts +1 -1
  82. package/dist/dtos/questions/create-question.dto.js +1 -1
  83. package/dist/dtos/questions/index.d.ts +4 -4
  84. package/dist/dtos/questions/index.js +4 -4
  85. package/dist/dtos/questions/search-by-name.dto.d.ts +1 -1
  86. package/dist/dtos/questions/search-by-name.dto.js +1 -1
  87. package/dist/dtos/questions/update-question.dto.d.ts +38 -3
  88. package/dist/dtos/questions/update-question.dto.js +66 -4
  89. package/dist/dtos/restaurants/index.d.ts +3 -3
  90. package/dist/dtos/restaurants/index.js +3 -3
  91. package/dist/dtos/restaurants/update-restaurant.dto.d.ts +41 -3
  92. package/dist/dtos/restaurants/update-restaurant.dto.js +72 -4
  93. package/dist/dtos/tags/index.d.ts +4 -4
  94. package/dist/dtos/tags/index.js +4 -4
  95. package/dist/dtos/tags/search-by-name.dto.d.ts +1 -1
  96. package/dist/dtos/tags/search-by-name.dto.js +1 -1
  97. package/dist/dtos/tags/update-tag.dto.d.ts +8 -3
  98. package/dist/dtos/tags/update-tag.dto.js +17 -6
  99. package/dist/dtos/translations/create-translation.dto.d.ts +1 -1
  100. package/dist/dtos/translations/create-translation.dto.js +1 -1
  101. package/dist/dtos/translations/find-translations-by-entity.dto.d.ts +1 -1
  102. package/dist/dtos/translations/find-translations-by-entity.dto.js +1 -1
  103. package/dist/dtos/translations/index.d.ts +4 -4
  104. package/dist/dtos/translations/index.js +4 -4
  105. package/dist/dtos/translations/update-translation.dto.d.ts +32 -3
  106. package/dist/dtos/translations/update-translation.dto.js +64 -4
  107. package/dist/enums/index.d.ts +12 -12
  108. package/dist/enums/index.js +12 -12
  109. package/dist/index.d.ts +5 -5
  110. package/dist/index.js +5 -5
  111. package/dist/interfaces/auth/access-user.interface.d.ts +2 -2
  112. package/dist/interfaces/auth/account.interface.d.ts +1 -1
  113. package/dist/interfaces/auth/full-token.interface.d.ts +2 -2
  114. package/dist/interfaces/auth/index.d.ts +9 -9
  115. package/dist/interfaces/auth/index.js +9 -9
  116. package/dist/interfaces/auth/payload-jwt.interface.d.ts +2 -2
  117. package/dist/interfaces/auth/responses/auth-response.interface.d.ts +3 -3
  118. package/dist/interfaces/auth/responses/index.d.ts +2 -2
  119. package/dist/interfaces/auth/responses/index.js +2 -2
  120. package/dist/interfaces/auth/responses/refresh-token-response.interface.d.ts +2 -2
  121. package/dist/interfaces/auth/user.interface.d.ts +2 -2
  122. package/dist/interfaces/auth/validate-user.interface.d.ts +2 -2
  123. package/dist/interfaces/categories/categories-list-response.interface.d.ts +3 -3
  124. package/dist/interfaces/categories/category-response.interface.d.ts +2 -2
  125. package/dist/interfaces/categories/index.d.ts +3 -3
  126. package/dist/interfaces/categories/index.js +3 -3
  127. package/dist/interfaces/chains/chain-response.interface.d.ts +2 -2
  128. package/dist/interfaces/chains/chain.interface.d.ts +1 -1
  129. package/dist/interfaces/chains/chains-list-response.interface.d.ts +3 -3
  130. package/dist/interfaces/chains/index.d.ts +3 -3
  131. package/dist/interfaces/chains/index.js +3 -3
  132. package/dist/interfaces/common/api-error-response.interface.d.ts +2 -2
  133. package/dist/interfaces/common/api-response.interface.d.ts +3 -2
  134. package/dist/interfaces/common/index.d.ts +5 -5
  135. package/dist/interfaces/common/index.js +5 -5
  136. package/dist/interfaces/common/rpc-error.interface.d.ts +1 -1
  137. package/dist/interfaces/index.d.ts +12 -12
  138. package/dist/interfaces/index.js +12 -12
  139. package/dist/interfaces/ingredients/index.d.ts +3 -3
  140. package/dist/interfaces/ingredients/index.js +3 -3
  141. package/dist/interfaces/ingredients/ingredient-response.interface.d.ts +2 -2
  142. package/dist/interfaces/ingredients/ingredients-list-response.interface.d.ts +3 -3
  143. package/dist/interfaces/orders/index.d.ts +6 -6
  144. package/dist/interfaces/orders/index.js +6 -6
  145. package/dist/interfaces/orders/order-created.interface.d.ts +3 -3
  146. package/dist/interfaces/orders/order-with-products.interface.d.ts +2 -2
  147. package/dist/interfaces/orders/order.interface.d.ts +2 -2
  148. package/dist/interfaces/orders/responses/change-order-status-response.interface.d.ts +2 -2
  149. package/dist/interfaces/orders/responses/create-order-response.interface.d.ts +2 -2
  150. package/dist/interfaces/orders/responses/index.d.ts +4 -4
  151. package/dist/interfaces/orders/responses/index.js +4 -4
  152. package/dist/interfaces/orders/responses/order-with-products-response.interface.d.ts +2 -2
  153. package/dist/interfaces/orders/responses/orders-list-response.interface.d.ts +3 -3
  154. package/dist/interfaces/payments/audit-storage-strategy.interface.d.ts +1 -1
  155. package/dist/interfaces/payments/index.d.ts +9 -9
  156. package/dist/interfaces/payments/index.js +9 -9
  157. package/dist/interfaces/payments/payment-provider.interface.d.ts +2 -2
  158. package/dist/interfaces/payments/responses/payment-callback-response.interface.d.ts +1 -1
  159. package/dist/interfaces/products/index.d.ts +8 -8
  160. package/dist/interfaces/products/index.js +8 -8
  161. package/dist/interfaces/products/product-recipe.interface.d.ts +1 -1
  162. package/dist/interfaces/products/product-tag.interface.d.ts +1 -1
  163. package/dist/interfaces/products/product.interface.d.ts +3 -3
  164. package/dist/interfaces/products/response/complete-product-response.interface.d.ts +2 -2
  165. package/dist/interfaces/products/response/index.d.ts +6 -6
  166. package/dist/interfaces/products/response/index.js +6 -6
  167. package/dist/interfaces/products/response/product-response.interface.d.ts +2 -2
  168. package/dist/interfaces/products/response/products-list-response.interface.d.ts +3 -3
  169. package/dist/interfaces/products/response/simple-product-response.interface.d.ts +1 -1
  170. package/dist/interfaces/products/response/sub-resources/create-tag-response.interface.d.ts +2 -2
  171. package/dist/interfaces/products/response/sub-resources/delete-sub-resource-response.interface.d.ts +1 -1
  172. package/dist/interfaces/products/response/sub-resources/find-product-image-response.interface.d.ts +2 -2
  173. package/dist/interfaces/products/response/sub-resources/find-product-question-response.interface.d.ts +2 -2
  174. package/dist/interfaces/products/response/sub-resources/find-product-recipe-response.interface.d.ts +2 -2
  175. package/dist/interfaces/products/response/sub-resources/find-product-schedule-response.interface.d.ts +2 -2
  176. package/dist/interfaces/products/response/sub-resources/find-product-size-response.interface.d.ts +2 -2
  177. package/dist/interfaces/products/response/sub-resources/find-product-tag-response.interface.d.ts +2 -2
  178. package/dist/interfaces/products/response/sub-resources/find-sub-resource-response.interface.d.ts +1 -1
  179. package/dist/interfaces/products/response/sub-resources/index.d.ts +25 -25
  180. package/dist/interfaces/products/response/sub-resources/index.js +25 -25
  181. package/dist/interfaces/products/response/sub-resources/list-product-images-response.interface.d.ts +2 -2
  182. package/dist/interfaces/products/response/sub-resources/list-product-questions-response.interface.d.ts +2 -2
  183. package/dist/interfaces/products/response/sub-resources/list-product-recipes-response.interface.d.ts +2 -2
  184. package/dist/interfaces/products/response/sub-resources/list-product-schedules-response.interface.d.ts +2 -2
  185. package/dist/interfaces/products/response/sub-resources/list-product-sizes-response.interface.d.ts +2 -2
  186. package/dist/interfaces/products/response/sub-resources/list-sub-resource-response.interface.d.ts +1 -1
  187. package/dist/interfaces/products/response/sub-resources/product-schedule-availability.interface.d.ts +1 -1
  188. package/dist/interfaces/products/response/sub-resources/question-relationship.interface.d.ts +1 -1
  189. package/dist/interfaces/products/response/sub-resources/recipe-relationship.interface.d.ts +1 -1
  190. package/dist/interfaces/products/response/sub-resources/replace-sub-products-response.interface.d.ts +1 -1
  191. package/dist/interfaces/products/response/sub-resources/sub-resource-response.interface.d.ts +1 -1
  192. package/dist/interfaces/products/response/sub-resources/write-image-response.interface.d.ts +2 -2
  193. package/dist/interfaces/products/response/sub-resources/write-question-product-response.interface.d.ts +2 -2
  194. package/dist/interfaces/products/response/sub-resources/write-recipe-response.interface.d.ts +2 -2
  195. package/dist/interfaces/products/response/sub-resources/write-schedule-response.interface.d.ts +2 -2
  196. package/dist/interfaces/products/response/sub-resources/write-size-response.interface.d.ts +2 -2
  197. package/dist/interfaces/questions/index.d.ts +3 -3
  198. package/dist/interfaces/questions/index.js +3 -3
  199. package/dist/interfaces/questions/question-response.interface.d.ts +2 -2
  200. package/dist/interfaces/questions/questions-list-response.interface.d.ts +3 -3
  201. package/dist/interfaces/restaurants/index.d.ts +3 -3
  202. package/dist/interfaces/restaurants/index.js +3 -3
  203. package/dist/interfaces/restaurants/restaurant-response.interface.d.ts +2 -2
  204. package/dist/interfaces/restaurants/restaurants-list-response.interface.d.ts +3 -3
  205. package/dist/interfaces/tags/index.d.ts +3 -3
  206. package/dist/interfaces/tags/index.js +3 -3
  207. package/dist/interfaces/tags/tag-response.interface.d.ts +2 -2
  208. package/dist/interfaces/tags/tags-list-response.interface.d.ts +3 -3
  209. package/dist/interfaces/translations/index.d.ts +3 -3
  210. package/dist/interfaces/translations/index.js +3 -3
  211. package/dist/interfaces/translations/translation-response.interface.d.ts +2 -2
  212. package/dist/interfaces/translations/translations-list-response.interface.d.ts +2 -2
  213. package/dist/types/index.d.ts +1 -1
  214. package/dist/types/index.js +1 -1
  215. package/package.json +1 -1
  216. package/tsconfig.json +1 -2
  217. package/tsconfig.node.json +10 -9
  218. package/dist/dtos/orders/update-order.dto.d.ts +0 -13
  219. package/dist/dtos/orders/update-order.dto.js +0 -13
@@ -1,4 +1,4 @@
1
- declare const UpdateProductDto_base: import("@nestjs/mapped-types").MappedType<Partial<unknown>>;
1
+ import { ProductStatus } from '../../enums/product-status.enum.js';
2
2
  /**
3
3
  * DTO for updating an existing product.
4
4
  *
@@ -8,7 +8,43 @@ declare const UpdateProductDto_base: import("@nestjs/mapped-types").MappedType<P
8
8
  *
9
9
  * @since 2.0.0
10
10
  */
11
- export declare class UpdateProductDto extends UpdateProductDto_base {
11
+ export declare class UpdateProductDto {
12
+ /**
13
+ * Product SKU (Stock Keeping Unit).
14
+ * Optional unique identifier for inventory management.
15
+ *
16
+ * @example "PROD-001"
17
+ */
18
+ sku?: string;
19
+ /**
20
+ * Product name.
21
+ * Must not be empty.
22
+ *
23
+ * @example "Big Mac"
24
+ */
25
+ name: string;
26
+ /**
27
+ * Product description.
28
+ * Optional detailed description of the product.
29
+ *
30
+ * @example "Two all-beef patties, special sauce, lettuce, cheese, pickles, onions on a sesame seed bun"
31
+ */
32
+ description?: string;
33
+ /**
34
+ * Product base price.
35
+ * Must be a number with maximum 4 decimal places and minimum value of 0.
36
+ *
37
+ * @example 5.99
38
+ */
39
+ basePrice: number;
40
+ /**
41
+ * Product status.
42
+ * Defaults to ACTIVE if not provided.
43
+ *
44
+ * @example ProductStatus.ACTIVE
45
+ * @default ProductStatus.ACTIVE
46
+ */
47
+ status?: ProductStatus;
12
48
  /**
13
49
  * Product ID to update.
14
50
  * Must be a valid UUID.
@@ -24,4 +60,3 @@ export declare class UpdateProductDto extends UpdateProductDto_base {
24
60
  */
25
61
  updatedBy?: string;
26
62
  }
27
- export {};
@@ -7,9 +7,9 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
7
7
  var __metadata = (this && this.__metadata) || function (k, v) {
8
8
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
9
  };
10
- import { PartialType } from '@nestjs/mapped-types';
11
- import { IsMongoId, IsString, IsUUID, IsOptional } from 'class-validator';
12
- import { CreateProductDto } from './create-product.dto';
10
+ import { IsMongoId, IsString, IsUUID, IsOptional, IsEnum, Min, IsNumber } from 'class-validator';
11
+ import { ProductStatus } from '../../enums/product-status.enum.js';
12
+ import { Type } from 'class-transformer';
13
13
  /**
14
14
  * DTO for updating an existing product.
15
15
  *
@@ -19,7 +19,43 @@ import { CreateProductDto } from './create-product.dto';
19
19
  *
20
20
  * @since 2.0.0
21
21
  */
22
- export class UpdateProductDto extends PartialType(CreateProductDto) {
22
+ export class UpdateProductDto {
23
+ /**
24
+ * Product SKU (Stock Keeping Unit).
25
+ * Optional unique identifier for inventory management.
26
+ *
27
+ * @example "PROD-001"
28
+ */
29
+ sku;
30
+ /**
31
+ * Product name.
32
+ * Must not be empty.
33
+ *
34
+ * @example "Big Mac"
35
+ */
36
+ name;
37
+ /**
38
+ * Product description.
39
+ * Optional detailed description of the product.
40
+ *
41
+ * @example "Two all-beef patties, special sauce, lettuce, cheese, pickles, onions on a sesame seed bun"
42
+ */
43
+ description;
44
+ /**
45
+ * Product base price.
46
+ * Must be a number with maximum 4 decimal places and minimum value of 0.
47
+ *
48
+ * @example 5.99
49
+ */
50
+ basePrice;
51
+ /**
52
+ * Product status.
53
+ * Defaults to ACTIVE if not provided.
54
+ *
55
+ * @example ProductStatus.ACTIVE
56
+ * @default ProductStatus.ACTIVE
57
+ */
58
+ status = ProductStatus.ACTIVE;
23
59
  /**
24
60
  * Product ID to update.
25
61
  * Must be a valid UUID.
@@ -35,6 +71,35 @@ export class UpdateProductDto extends PartialType(CreateProductDto) {
35
71
  */
36
72
  updatedBy;
37
73
  }
74
+ __decorate([
75
+ IsOptional(),
76
+ IsString(),
77
+ __metadata("design:type", String)
78
+ ], UpdateProductDto.prototype, "sku", void 0);
79
+ __decorate([
80
+ IsOptional(),
81
+ IsString(),
82
+ __metadata("design:type", String)
83
+ ], UpdateProductDto.prototype, "name", void 0);
84
+ __decorate([
85
+ IsOptional(),
86
+ IsString(),
87
+ __metadata("design:type", String)
88
+ ], UpdateProductDto.prototype, "description", void 0);
89
+ __decorate([
90
+ IsOptional(),
91
+ IsNumber({
92
+ maxDecimalPlaces: 4,
93
+ }, { message: 'Base price must be a number with maximum 4 decimal places' }),
94
+ Type(() => Number),
95
+ Min(0, { message: 'Base price must be greater than or equal to 0' }),
96
+ __metadata("design:type", Number)
97
+ ], UpdateProductDto.prototype, "basePrice", void 0);
98
+ __decorate([
99
+ IsOptional(),
100
+ IsEnum(ProductStatus, { message: 'Status must be ACTIVE, INACTIVE, or OUT_OF_STOCK' }),
101
+ __metadata("design:type", String)
102
+ ], UpdateProductDto.prototype, "status", void 0);
38
103
  __decorate([
39
104
  IsString(),
40
105
  IsUUID(),
@@ -1,4 +1,4 @@
1
- import { QuestionType } from '../../enums/question-type.enum';
1
+ import { QuestionType } from '../../enums/question-type.enum.js';
2
2
  /**
3
3
  * DTO for creating a new question.
4
4
  *
@@ -8,7 +8,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
8
8
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
9
  };
10
10
  import { IsString, IsNotEmpty, IsOptional, IsBoolean, IsInt, IsEnum, Min, IsMongoId } from 'class-validator';
11
- import { QuestionType } from '../../enums/question-type.enum';
11
+ import { QuestionType } from '../../enums/question-type.enum.js';
12
12
  /**
13
13
  * DTO for creating a new question.
14
14
  *
@@ -6,7 +6,7 @@
6
6
  *
7
7
  * @since 2.0.0
8
8
  */
9
- export * from './create-question.dto';
10
- export * from './update-question.dto';
11
- export * from './delete-question.dto';
12
- export * from './search-by-name.dto';
9
+ export * from './create-question.dto.js';
10
+ export * from './update-question.dto.js';
11
+ export * from './delete-question.dto.js';
12
+ export * from './search-by-name.dto.js';
@@ -6,7 +6,7 @@
6
6
  *
7
7
  * @since 2.0.0
8
8
  */
9
- export * from './create-question.dto';
10
- export * from './update-question.dto';
11
- export * from './delete-question.dto';
12
- export * from './search-by-name.dto';
9
+ export * from './create-question.dto.js';
10
+ export * from './update-question.dto.js';
11
+ export * from './delete-question.dto.js';
12
+ export * from './search-by-name.dto.js';
@@ -1,4 +1,4 @@
1
- import { PaginationDto } from '../common/pagination.dto';
1
+ import { PaginationDto } from '../common/pagination.dto.js';
2
2
  /**
3
3
  * DTO for searching questions by name.
4
4
  *
@@ -8,7 +8,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
8
8
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
9
  };
10
10
  import { IsString, IsNotEmpty } from 'class-validator';
11
- import { PaginationDto } from '../common/pagination.dto';
11
+ import { PaginationDto } from '../common/pagination.dto.js';
12
12
  /**
13
13
  * DTO for searching questions by name.
14
14
  *
@@ -1,4 +1,4 @@
1
- declare const UpdateQuestionDto_base: import("@nestjs/mapped-types").MappedType<Partial<unknown>>;
1
+ import { QuestionType } from '../../enums/question-type.enum.js';
2
2
  /**
3
3
  * DTO for updating an existing question.
4
4
  *
@@ -7,7 +7,43 @@ declare const UpdateQuestionDto_base: import("@nestjs/mapped-types").MappedType<
7
7
  *
8
8
  * @since 2.0.0
9
9
  */
10
- export declare class UpdateQuestionDto extends UpdateQuestionDto_base {
10
+ export declare class UpdateQuestionDto {
11
+ /**
12
+ * Question text/name.
13
+ * Must not be empty.
14
+ *
15
+ * @example "Would you like extra cheese?"
16
+ */
17
+ name: string;
18
+ /**
19
+ * Whether the question is required.
20
+ * Defaults to false if not provided.
21
+ *
22
+ * @example true
23
+ * @default false
24
+ */
25
+ required?: boolean;
26
+ /**
27
+ * Minimum value for numeric questions.
28
+ * Must be a non-negative integer if provided.
29
+ *
30
+ * @example 0
31
+ */
32
+ min?: number;
33
+ /**
34
+ * Maximum value for numeric questions.
35
+ * Must be a positive integer if provided.
36
+ *
37
+ * @example 10
38
+ */
39
+ max?: number;
40
+ /**
41
+ * Type of question.
42
+ * Must be a valid QuestionType enum value.
43
+ *
44
+ * @example QuestionType.SINGLE_CHOICE
45
+ */
46
+ type: QuestionType;
11
47
  /**
12
48
  * Question ID to update.
13
49
  * Must be a valid UUID.
@@ -23,4 +59,3 @@ export declare class UpdateQuestionDto extends UpdateQuestionDto_base {
23
59
  */
24
60
  updatedBy?: string;
25
61
  }
26
- export {};
@@ -7,9 +7,8 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
7
7
  var __metadata = (this && this.__metadata) || function (k, v) {
8
8
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
9
  };
10
- import { PartialType } from '@nestjs/mapped-types';
11
- import { IsString, IsOptional, IsMongoId, IsUUID } from 'class-validator';
12
- import { CreateQuestionDto } from './create-question.dto';
10
+ import { IsString, IsOptional, IsMongoId, IsUUID, IsEnum, IsInt, Min, IsBoolean } from 'class-validator';
11
+ import { QuestionType } from '../../enums/question-type.enum.js';
13
12
  /**
14
13
  * DTO for updating an existing question.
15
14
  *
@@ -18,7 +17,43 @@ import { CreateQuestionDto } from './create-question.dto';
18
17
  *
19
18
  * @since 2.0.0
20
19
  */
21
- export class UpdateQuestionDto extends PartialType(CreateQuestionDto) {
20
+ export class UpdateQuestionDto {
21
+ /**
22
+ * Question text/name.
23
+ * Must not be empty.
24
+ *
25
+ * @example "Would you like extra cheese?"
26
+ */
27
+ name;
28
+ /**
29
+ * Whether the question is required.
30
+ * Defaults to false if not provided.
31
+ *
32
+ * @example true
33
+ * @default false
34
+ */
35
+ required;
36
+ /**
37
+ * Minimum value for numeric questions.
38
+ * Must be a non-negative integer if provided.
39
+ *
40
+ * @example 0
41
+ */
42
+ min;
43
+ /**
44
+ * Maximum value for numeric questions.
45
+ * Must be a positive integer if provided.
46
+ *
47
+ * @example 10
48
+ */
49
+ max;
50
+ /**
51
+ * Type of question.
52
+ * Must be a valid QuestionType enum value.
53
+ *
54
+ * @example QuestionType.SINGLE_CHOICE
55
+ */
56
+ type;
22
57
  /**
23
58
  * Question ID to update.
24
59
  * Must be a valid UUID.
@@ -34,6 +69,33 @@ export class UpdateQuestionDto extends PartialType(CreateQuestionDto) {
34
69
  */
35
70
  updatedBy;
36
71
  }
72
+ __decorate([
73
+ IsString(),
74
+ IsOptional(),
75
+ __metadata("design:type", String)
76
+ ], UpdateQuestionDto.prototype, "name", void 0);
77
+ __decorate([
78
+ IsOptional(),
79
+ IsBoolean(),
80
+ __metadata("design:type", Boolean)
81
+ ], UpdateQuestionDto.prototype, "required", void 0);
82
+ __decorate([
83
+ IsOptional(),
84
+ IsInt({ message: 'Minimum value must be an integer' }),
85
+ Min(0, { message: 'Minimum value must be at least 0' }),
86
+ __metadata("design:type", Number)
87
+ ], UpdateQuestionDto.prototype, "min", void 0);
88
+ __decorate([
89
+ IsOptional(),
90
+ IsInt({ message: 'Maximum value must be an integer' }),
91
+ Min(1, { message: 'Maximum value must be at least 1' }),
92
+ __metadata("design:type", Number)
93
+ ], UpdateQuestionDto.prototype, "max", void 0);
94
+ __decorate([
95
+ IsOptional(),
96
+ IsEnum(QuestionType, { message: 'Question type must be a valid QuestionType' }),
97
+ __metadata("design:type", String)
98
+ ], UpdateQuestionDto.prototype, "type", void 0);
37
99
  __decorate([
38
100
  IsString(),
39
101
  IsUUID(),
@@ -6,6 +6,6 @@
6
6
  *
7
7
  * @since 2.0.0
8
8
  */
9
- export * from './create-restaurant.dto';
10
- export * from './update-restaurant.dto';
11
- export * from './delete-restaurant.dto';
9
+ export * from './create-restaurant.dto.js';
10
+ export * from './update-restaurant.dto.js';
11
+ export * from './delete-restaurant.dto.js';
@@ -6,6 +6,6 @@
6
6
  *
7
7
  * @since 2.0.0
8
8
  */
9
- export * from './create-restaurant.dto';
10
- export * from './update-restaurant.dto';
11
- export * from './delete-restaurant.dto';
9
+ export * from './create-restaurant.dto.js';
10
+ export * from './update-restaurant.dto.js';
11
+ export * from './delete-restaurant.dto.js';
@@ -1,4 +1,3 @@
1
- declare const UpdateRestaurantDto_base: import("@nestjs/mapped-types").MappedType<Partial<unknown>>;
2
1
  /**
3
2
  * DTO for updating an existing restaurant.
4
3
  *
@@ -7,7 +6,47 @@ declare const UpdateRestaurantDto_base: import("@nestjs/mapped-types").MappedTyp
7
6
  *
8
7
  * @since 2.0.0
9
8
  */
10
- export declare class UpdateRestaurantDto extends UpdateRestaurantDto_base {
9
+ export declare class UpdateRestaurantDto {
10
+ /**
11
+ * Chain ID that owns this restaurant.
12
+ * Must not be empty.
13
+ *
14
+ * @example "chain-uuid-123"
15
+ */
16
+ chainId: string;
17
+ /**
18
+ * Restaurant name.
19
+ * Must not be empty.
20
+ *
21
+ * @example "McDonald's Downtown"
22
+ */
23
+ name: string;
24
+ /**
25
+ * Optional restaurant address.
26
+ *
27
+ * @example "123 Main St, Downtown"
28
+ */
29
+ address?: string;
30
+ /**
31
+ * Optional restaurant phone number.
32
+ *
33
+ * @example "+1-555-0123"
34
+ */
35
+ phone?: string;
36
+ /**
37
+ * Optional restaurant timezone.
38
+ *
39
+ * @example "America/New_York"
40
+ */
41
+ timezone?: string;
42
+ /**
43
+ * Restaurant status (active/inactive).
44
+ * Defaults to true if not provided.
45
+ *
46
+ * @example true
47
+ * @default true
48
+ */
49
+ status?: boolean;
11
50
  /**
12
51
  * Restaurant ID to update.
13
52
  * Must be a valid UUID.
@@ -23,4 +62,3 @@ export declare class UpdateRestaurantDto extends UpdateRestaurantDto_base {
23
62
  */
24
63
  updatedBy?: string;
25
64
  }
26
- export {};
@@ -7,9 +7,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
7
7
  var __metadata = (this && this.__metadata) || function (k, v) {
8
8
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
9
  };
10
- import { PartialType } from '@nestjs/mapped-types';
11
- import { IsString, IsOptional, IsMongoId, IsUUID } from 'class-validator';
12
- import { CreateRestaurantDto } from './create-restaurant.dto';
10
+ import { IsString, IsOptional, IsMongoId, IsUUID, IsBoolean } from 'class-validator';
13
11
  /**
14
12
  * DTO for updating an existing restaurant.
15
13
  *
@@ -18,7 +16,47 @@ import { CreateRestaurantDto } from './create-restaurant.dto';
18
16
  *
19
17
  * @since 2.0.0
20
18
  */
21
- export class UpdateRestaurantDto extends PartialType(CreateRestaurantDto) {
19
+ export class UpdateRestaurantDto {
20
+ /**
21
+ * Chain ID that owns this restaurant.
22
+ * Must not be empty.
23
+ *
24
+ * @example "chain-uuid-123"
25
+ */
26
+ chainId;
27
+ /**
28
+ * Restaurant name.
29
+ * Must not be empty.
30
+ *
31
+ * @example "McDonald's Downtown"
32
+ */
33
+ name;
34
+ /**
35
+ * Optional restaurant address.
36
+ *
37
+ * @example "123 Main St, Downtown"
38
+ */
39
+ address;
40
+ /**
41
+ * Optional restaurant phone number.
42
+ *
43
+ * @example "+1-555-0123"
44
+ */
45
+ phone;
46
+ /**
47
+ * Optional restaurant timezone.
48
+ *
49
+ * @example "America/New_York"
50
+ */
51
+ timezone;
52
+ /**
53
+ * Restaurant status (active/inactive).
54
+ * Defaults to true if not provided.
55
+ *
56
+ * @example true
57
+ * @default true
58
+ */
59
+ status = true;
22
60
  /**
23
61
  * Restaurant ID to update.
24
62
  * Must be a valid UUID.
@@ -34,6 +72,36 @@ export class UpdateRestaurantDto extends PartialType(CreateRestaurantDto) {
34
72
  */
35
73
  updatedBy;
36
74
  }
75
+ __decorate([
76
+ IsOptional(),
77
+ IsString(),
78
+ __metadata("design:type", String)
79
+ ], UpdateRestaurantDto.prototype, "chainId", void 0);
80
+ __decorate([
81
+ IsOptional(),
82
+ IsString(),
83
+ __metadata("design:type", String)
84
+ ], UpdateRestaurantDto.prototype, "name", void 0);
85
+ __decorate([
86
+ IsOptional(),
87
+ IsString(),
88
+ __metadata("design:type", String)
89
+ ], UpdateRestaurantDto.prototype, "address", void 0);
90
+ __decorate([
91
+ IsOptional(),
92
+ IsString(),
93
+ __metadata("design:type", String)
94
+ ], UpdateRestaurantDto.prototype, "phone", void 0);
95
+ __decorate([
96
+ IsOptional(),
97
+ IsString(),
98
+ __metadata("design:type", String)
99
+ ], UpdateRestaurantDto.prototype, "timezone", void 0);
100
+ __decorate([
101
+ IsOptional(),
102
+ IsBoolean(),
103
+ __metadata("design:type", Boolean)
104
+ ], UpdateRestaurantDto.prototype, "status", void 0);
37
105
  __decorate([
38
106
  IsString(),
39
107
  IsUUID(),
@@ -6,7 +6,7 @@
6
6
  *
7
7
  * @since 2.0.0
8
8
  */
9
- export * from './create-tag.dto';
10
- export * from './update-tag.dto';
11
- export * from './delete-tag.dto';
12
- export * from './search-by-name.dto';
9
+ export * from './create-tag.dto.js';
10
+ export * from './update-tag.dto.js';
11
+ export * from './delete-tag.dto.js';
12
+ export * from './search-by-name.dto.js';
@@ -6,7 +6,7 @@
6
6
  *
7
7
  * @since 2.0.0
8
8
  */
9
- export * from './create-tag.dto';
10
- export * from './update-tag.dto';
11
- export * from './delete-tag.dto';
12
- export * from './search-by-name.dto';
9
+ export * from './create-tag.dto.js';
10
+ export * from './update-tag.dto.js';
11
+ export * from './delete-tag.dto.js';
12
+ export * from './search-by-name.dto.js';
@@ -1,4 +1,4 @@
1
- import { PaginationDto } from '../common/pagination.dto';
1
+ import { PaginationDto } from '../common/pagination.dto.js';
2
2
  /**
3
3
  * DTO for searching tags by name.
4
4
  *
@@ -8,7 +8,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
8
8
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
9
  };
10
10
  import { IsString, IsNotEmpty } from 'class-validator';
11
- import { PaginationDto } from '../common/pagination.dto';
11
+ import { PaginationDto } from '../common/pagination.dto.js';
12
12
  /**
13
13
  * DTO for searching tags by name.
14
14
  *
@@ -1,4 +1,3 @@
1
- declare const UpdateTagDto_base: import("@nestjs/mapped-types").MappedType<Partial<unknown>>;
2
1
  /**
3
2
  * DTO for updating an existing tag.
4
3
  *
@@ -7,7 +6,14 @@ declare const UpdateTagDto_base: import("@nestjs/mapped-types").MappedType<Parti
7
6
  *
8
7
  * @since 2.0.0
9
8
  */
10
- export declare class UpdateTagDto extends UpdateTagDto_base {
9
+ export declare class UpdateTagDto {
10
+ /**
11
+ * Name of the tag.
12
+ * Must not be empty and maximum length of 50 characters.
13
+ *
14
+ * @example "vegetarian"
15
+ */
16
+ name: string;
11
17
  /**
12
18
  * Tag ID to update.
13
19
  * Must be a valid UUID.
@@ -23,4 +29,3 @@ export declare class UpdateTagDto extends UpdateTagDto_base {
23
29
  */
24
30
  updatedBy?: string;
25
31
  }
26
- export {};
@@ -7,9 +7,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
7
7
  var __metadata = (this && this.__metadata) || function (k, v) {
8
8
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
9
  };
10
- import { PartialType } from '@nestjs/mapped-types';
11
- import { IsString, IsOptional, IsMongoId, IsUUID } from 'class-validator';
12
- import { CreateTagDto } from './create-tag.dto';
10
+ import { IsString, IsOptional, IsMongoId, IsUUID, MaxLength } from 'class-validator';
13
11
  /**
14
12
  * DTO for updating an existing tag.
15
13
  *
@@ -18,7 +16,14 @@ import { CreateTagDto } from './create-tag.dto';
18
16
  *
19
17
  * @since 2.0.0
20
18
  */
21
- export class UpdateTagDto extends PartialType(CreateTagDto) {
19
+ export class UpdateTagDto {
20
+ /**
21
+ * Name of the tag.
22
+ * Must not be empty and maximum length of 50 characters.
23
+ *
24
+ * @example "vegetarian"
25
+ */
26
+ name;
22
27
  /**
23
28
  * Tag ID to update.
24
29
  * Must be a valid UUID.
@@ -35,14 +40,20 @@ export class UpdateTagDto extends PartialType(CreateTagDto) {
35
40
  updatedBy;
36
41
  }
37
42
  __decorate([
43
+ IsOptional(),
38
44
  IsString(),
39
- IsUUID(),
45
+ MaxLength(50, { message: 'Tag name must be at most 50 characters' }),
46
+ __metadata("design:type", String)
47
+ ], UpdateTagDto.prototype, "name", void 0);
48
+ __decorate([
40
49
  IsOptional(),
50
+ IsString(),
51
+ IsUUID(),
41
52
  __metadata("design:type", String)
42
53
  ], UpdateTagDto.prototype, "id", void 0);
43
54
  __decorate([
55
+ IsOptional(),
44
56
  IsString(),
45
57
  IsMongoId(),
46
- IsOptional(),
47
58
  __metadata("design:type", String)
48
59
  ], UpdateTagDto.prototype, "updatedBy", void 0);
@@ -1,4 +1,4 @@
1
- import { LanguageCode } from '../../enums/language-code.enum';
1
+ import { LanguageCode } from '../../enums/language-code.enum.js';
2
2
  /**
3
3
  * DTO for creating a translation
4
4
  */
@@ -8,7 +8,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
8
8
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
9
9
  };
10
10
  import { IsString, IsOptional, IsEnum, IsUUID } from 'class-validator';
11
- import { LanguageCode } from '../../enums/language-code.enum';
11
+ import { LanguageCode } from '../../enums/language-code.enum.js';
12
12
  /**
13
13
  * DTO for creating a translation
14
14
  */
@@ -1,4 +1,4 @@
1
- import { TranslationEntityType } from '../../enums';
1
+ import { TranslationEntityType } from '../../enums/translation-entity-type.enum.js';
2
2
  /**
3
3
  * DTO for finding translations by entity
4
4
  */