@react-pakistan/util-functions 1.25.0 → 1.25.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.
@@ -25,7 +25,7 @@ export interface UpdateProductArgs {
25
25
  currency: string;
26
26
  description?: string;
27
27
  id: string;
28
- image?: string;
28
+ images?: string[];
29
29
  include?: any;
30
30
  name: string;
31
31
  prisma: PrismaClient;
@@ -55,7 +55,7 @@ export declare const unitProductById: ({ id, includeProductCategory, includeQuot
55
55
  * @param {UpdateProductArgs} args - Object containing prisma client, product data, and optional query parameters
56
56
  * @returns {Promise<ProductBE>} Created or updated product
57
57
  */
58
- export declare const updateProduct: ({ buyPrice, currency, description, id, image, name, prisma, productCategoryId, quantity, ref, salePrice, }: UpdateProductArgs) => Promise<ProductBE>;
58
+ export declare const updateProduct: ({ buyPrice, currency, description, id, images, name, prisma, productCategoryId, quantity, ref, salePrice, }: UpdateProductArgs) => Promise<ProductBE>;
59
59
  /**
60
60
  * Deletes a product by ID
61
61
  * @param {DeleteProductArgs} args - Object containing prisma client, product ID, and optional query parameters
@@ -180,7 +180,7 @@ exports.unitProductById = unitProductById;
180
180
  */
181
181
  var updateProduct = function (_a) { return __awaiter(void 0, [_a], void 0, function (_b) {
182
182
  var productData, where, product;
183
- var buyPrice = _b.buyPrice, currency = _b.currency, description = _b.description, id = _b.id, image = _b.image, name = _b.name, prisma = _b.prisma, productCategoryId = _b.productCategoryId, quantity = _b.quantity, ref = _b.ref, salePrice = _b.salePrice;
183
+ var buyPrice = _b.buyPrice, currency = _b.currency, description = _b.description, id = _b.id, images = _b.images, name = _b.name, prisma = _b.prisma, productCategoryId = _b.productCategoryId, quantity = _b.quantity, ref = _b.ref, salePrice = _b.salePrice;
184
184
  return __generator(this, function (_c) {
185
185
  switch (_c.label) {
186
186
  case 0:
@@ -199,7 +199,7 @@ var updateProduct = function (_a) { return __awaiter(void 0, [_a], void 0, funct
199
199
  buyPrice: buyPrice,
200
200
  currency: currency,
201
201
  description: description || null,
202
- image: image || null,
202
+ images: images || null,
203
203
  name: name,
204
204
  productCategoryId: productCategoryId,
205
205
  quantity: quantity,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@react-pakistan/util-functions",
3
- "version": "1.25.0",
3
+ "version": "1.25.1",
4
4
  "description": "A library of all util functions",
5
5
  "main": "index.js",
6
6
  "scripts": {