@erp-galoper/types 1.0.581 → 1.0.582

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 (2) hide show
  1. package/openapi.ts +357 -312
  2. package/package.json +1 -1
package/openapi.ts CHANGED
@@ -4328,6 +4328,8 @@ export interface paths {
4328
4328
  * - {"message": "You do not have access to this branch.", "code": "noBranchAccess}
4329
4329
  * - 404: {"message": "Branch does not exist", "code": "branchDoesNotExist"}
4330
4330
  * - 500: {"message": "An internal server error has occurred", "code": "serverError"}
4331
+ *
4332
+ * permission key: openingquantity : ['view']
4331
4333
  */
4332
4334
  get: operations["inventory_opening_stock_views_list_opening_quantity"];
4333
4335
  put?: never;
@@ -4335,15 +4337,25 @@ export interface paths {
4335
4337
  * Create Opening Quantity
4336
4338
  * @description Endpoint for creating Opening Quantity Document
4337
4339
  * Responses:
4338
- * - 201: {"message": "Opening Quantity created successfully.", "code": "openingQuantityCreated"}
4339
- * - 400: {"message": "An error occurred while creating the opening quantity document.", "code": "invalidData"}
4340
- * - 403: {"message": "You do not have permission to perform this action", "code": "permissionDenied"}
4341
- * - {"message": "You do not have access to this branch.", "code": "noBranchAccess"}
4342
- * - 404: {"message": "item Invalid pk "{item_id}" - object does not exist..", "code": "itemDoesNotExist"}
4343
- * - {"message": "warehouse Invalid pk "{warehouse_id}" - object does not exist..", "code": "warehouseDoesNotExist"}
4344
- * - 409: {"message": "The fields item, warehouse, branch must be unique together..", "code": "itemWarehouseBranchConflict"}
4345
- * - {"message": "The fields header, item must make a unique set..", "code": "headerItemConflict"}
4346
- * - 500: {"message": "An internal server error has occurred", "code": "serverError"}
4340
+ * - 201: OpeningQuantitySchema
4341
+ * - 400: "invalidData"
4342
+ * - item+warehouse+branch+unitOfMeasure+itemPackageConflict
4343
+ * - itemDoesNotExist
4344
+ * - quantityMismatch
4345
+ * - quantityRequired
4346
+ * - serialNumberQuantityMustBeOne
4347
+ * - expiryDateRequired
4348
+ * - inTrackByQuantityOneTrackingRequired
4349
+ * - numberOfSerialsRequired
4350
+ * - warehouseDoesNotExist
4351
+ * - branchDoesNotExist
4352
+ * - unitOfMeasureDoesNotExist
4353
+ * - itemPackageDoesNotExist
4354
+ * - 403: "permissionDenied"
4355
+ * - "noBranchAccess"
4356
+ * - 500: "serverError"
4357
+ *
4358
+ * permission key: openingquantity : ['add']
4347
4359
  */
4348
4360
  post: operations["inventory_opening_stock_views_create_opening_quantity"];
4349
4361
  delete?: never;
@@ -4352,7 +4364,7 @@ export interface paths {
4352
4364
  patch?: never;
4353
4365
  trace?: never;
4354
4366
  };
4355
- "/api/v1/inventory/opening_quantity/{headerId}/": {
4367
+ "/api/v1/inventory/opening_quantity/{id}/": {
4356
4368
  parameters: {
4357
4369
  query?: never;
4358
4370
  header?: never;
@@ -4360,85 +4372,46 @@ export interface paths {
4360
4372
  cookie?: never;
4361
4373
  };
4362
4374
  /**
4363
- * List Opening Quantity Details
4364
- * @description Endpoint for List Opening Quantity Details
4375
+ * Get Opening Quantity
4376
+ * @description Endpoint for retrieving Opening Quantity Document
4365
4377
  * Responses:
4366
- * - 200: OpeningQuantityDetailsListSchema
4367
- * - 400: {"message": "Error applying filter {error}", "code": "invalidFilterFormat"}
4368
- * - {"message": "Error applying pagination {error}", "code": "paginationError"}
4378
+ * - 200: OpeningQuantityHeaderSchema
4369
4379
  * - 403: {"message": "You do not have permission to perform this action", "code": "permissionDenied"}
4370
4380
  * - {"message": "You do not have access to this branch.", "code": "noBranchAccess"}
4371
- * - 404: {"message": "Opening Quantity Document does not exist", "code": "openingQuantityDoesNotExist"}
4372
- * - {"message": "Branch does not exist", "code": "branchDoesNotExist"}
4381
+ * - 404: {"message": "Opening Quantity Document not found.", "code": "openingQuantityDoesNotExist"}
4373
4382
  * - 500: {"message": "An internal server error has occurred", "code": "serverError"}
4383
+ *
4384
+ * permission key: openingquantity : ['view']
4374
4385
  */
4375
- get: operations["inventory_opening_stock_views_list_opening_quantity_details"];
4376
- put?: never;
4377
- post?: never;
4378
- delete?: never;
4379
- options?: never;
4380
- head?: never;
4386
+ get: operations["inventory_opening_stock_views_get_opening_quantity"];
4381
4387
  /**
4382
4388
  * Update Opening Quantity
4383
4389
  * @description Endpoint for updating Opening Quantity Document
4384
- * Responses:
4385
- * - 200: {"message": "Opening quantity details updated successfully.", "code": "openingQuantityUpdated"}
4386
- * - 400: {"message": "Failed to update/create opening quantity details due to error: {error}", "code": "invalidData"}
4387
- * - {"message": "No data to update", "code": "noChangesDetected"}
4388
- * - 403: {"message": "You do not have permission to perform this action", "code": "permissionDenied"}
4389
- * - {"message": "You do not have access to this branch.", "code": "noBranchAccess}
4390
- * - {"message": "Only draft Opening Quantity can be updated.", "code": "documentNotInDraftStatus"}
4391
- * - 404: {"message": "Opening Quantity Document not found.", "code": "notFound"}
4392
- * - {"message": "branch Invalid pk "{header.branch_id}" - object does not exist..", "code": "branchDoesNotExist"}
4393
- * - {"message": "item Invalid pk "{item_id}" - object does not exist..", "code": "itemDoesNotExist"}
4394
- * - {"message": "warehouse Invalid pk "{header.warehouse_id}" - object does not exist..", "code": "warehouseDoesNotExist"}
4395
- * - {"message": "Opening Quantity Invalid pk - object does not exist.. ", "code": "openingQuantityDoesNotExist"}
4396
- * -
4397
- * - 409: {"message": "The fields item, warehouse, branch must be unique together..", "code": "itemWarehouseBranchConflict"}
4398
- * - {"message": "The fields header, item must make a unique set..", "code": "headerItemConflict"}
4399
- * - 500: {"message": "An internal server error has occurred", "code": "serverError"}
4400
- */
4401
- patch: operations["inventory_opening_stock_views_update_opening_quantity"];
4402
- trace?: never;
4403
- };
4404
- "/api/v1/inventory/opening_quantity/{headerId}/reset-to-draft/": {
4405
- parameters: {
4406
- query?: never;
4407
- header?: never;
4408
- path?: never;
4409
- cookie?: never;
4410
- };
4411
- get?: never;
4412
- put?: never;
4413
- post?: never;
4414
- delete?: never;
4415
- options?: never;
4416
- head?: never;
4417
- /**
4418
- * Rest To Draft
4419
- * @description Endpoint for setting the status of an opening quantity document to draft
4420
- * Responses:
4421
- * - 200: {"message": "Opening Quantity status set to draft.", "code": "statusSetToDraft"}
4422
- * - 400: {"message": "Opening Quantity status is already draft.", "code": "statusAlreadyDraft"}
4423
- * - 403: {"message": "You do not have permission to perform this action", "code": "permissionDenied"}
4424
- * - 404: {"message": "Opening Quantity Document not found.", "code": "openingQuantityDoesNotExist"}
4425
- * - 500: {"message": "An internal server error has occurred", "code": "serverError"}
4390
+ * - 200: OpeningQuantitySchema
4391
+ * - 400:
4392
+ * - item+warehouse+branch+unitOfMeasure+itemPackageConflict
4393
+ * - itemDoesNotExist
4394
+ * - quantityMismatch
4395
+ * - quantityRequired
4396
+ * - serialNumberQuantityMustBeOne
4397
+ * - expiryDateRequired
4398
+ * - inTrackByQuantityOneTrackingRequired
4399
+ * - numberOfSerialsRequired
4400
+ * - warehouseDoesNotExist
4401
+ * - branchDoesNotExist
4402
+ * - unitOfMeasureDoesNotExist
4403
+ * - itemPackageDoesNotExist
4404
+ * - 403: "permissionDenied"
4405
+ * - "noBranchAccess"
4406
+ * - 404: "openingQuantityDoesNotExist"
4407
+ * - 500: "serverError"
4408
+ *
4409
+ * permission key: openingquantity : ['change']
4426
4410
  */
4427
- patch: operations["inventory_opening_stock_views_rest_to_draft"];
4428
- trace?: never;
4429
- };
4430
- "/api/v1/inventory/opening_quantity/header/{headerId}/": {
4431
- parameters: {
4432
- query?: never;
4433
- header?: never;
4434
- path?: never;
4435
- cookie?: never;
4436
- };
4437
- get?: never;
4438
- put?: never;
4411
+ put: operations["inventory_opening_stock_views_update_opening_quantity"];
4439
4412
  post?: never;
4440
4413
  /**
4441
- * Delete Opening Quantity Header
4414
+ * Delete Opening Quantity
4442
4415
  * @description Endpoint for deleting Opening Quantity Document
4443
4416
  * Responses:
4444
4417
  * - 204: None
@@ -4447,14 +4420,16 @@ export interface paths {
4447
4420
  * - 404: {"message": "branch Invalid pk - object does not exist..", "code": "branchDoesNotExist"}
4448
4421
  * - {"message": "Opening Quantity Invalid pk - object does not exist..", "code": "openingQuantityDoesNotExist"}
4449
4422
  * - 500: {"message": "An internal server error has occurred", "code": "serverError"}
4423
+ *
4424
+ * permission key: openingquantity : ['delete']
4450
4425
  */
4451
- delete: operations["inventory_opening_stock_views_delete_opening_quantity_header"];
4426
+ delete: operations["inventory_opening_stock_views_delete_opening_quantity"];
4452
4427
  options?: never;
4453
4428
  head?: never;
4454
4429
  patch?: never;
4455
4430
  trace?: never;
4456
4431
  };
4457
- "/api/v1/inventory/opening_quantity/detail/{detailId}/": {
4432
+ "/api/v1/inventory/opening_quantity/{id}/reset-to-draft/": {
4458
4433
  parameters: {
4459
4434
  query?: never;
4460
4435
  header?: never;
@@ -4463,21 +4438,20 @@ export interface paths {
4463
4438
  };
4464
4439
  get?: never;
4465
4440
  put?: never;
4466
- post?: never;
4467
4441
  /**
4468
- * Delete Opening Quantity Detail
4469
- * @description Endpoint for deleting Opening Quantity Detail
4442
+ * Reset To Draft
4443
+ * @description Endpoint for setting the status of an opening quantity document to draft
4470
4444
  * Responses:
4471
- * - 204: None
4445
+ * - 200: {"message": "Opening Quantity status set to draft.", "code": "statusSetToDraft"}
4446
+ * - 400: {"message": "Opening Quantity status is already draft.", "code": "statusAlreadyDraft"}
4472
4447
  * - 403: {"message": "You do not have permission to perform this action", "code": "permissionDenied"}
4473
- * - {"message": "You do not have access to this branch.", "code": "noBranchAccess"}
4474
- * - {"message": "Only draft Stock Adjustments can be updated.", "code": "documentNotInDraftStatus"}
4475
- * - 404: {"message": "branch Invalid pk - object does not exist..", "code": "branchDoesNotExist"}
4476
- * - {"message": "Opening Quantity Invalid pk - object does not exist..", "code": "openingQuantityDoesNotExist"}
4477
- * - {"message": "Opening Quantity Detail Invalid pk - object does not exist.. ", "code": "openingQuantityDetailDoesNotExist"}
4448
+ * - 404: {"message": "Opening Quantity Document not found.", "code": "openingQuantityDoesNotExist"}
4478
4449
  * - 500: {"message": "An internal server error has occurred", "code": "serverError"}
4450
+ *
4451
+ * permission key: openingquantity : ['change']
4479
4452
  */
4480
- delete: operations["inventory_opening_stock_views_delete_opening_quantity_detail"];
4453
+ post: operations["inventory_opening_stock_views_reset_to_draft"];
4454
+ delete?: never;
4481
4455
  options?: never;
4482
4456
  head?: never;
4483
4457
  patch?: never;
@@ -24615,24 +24589,110 @@ export interface components {
24615
24589
  */
24616
24590
  delete: components["schemas"]["DeleteStockAdjustmentDetailSchema"][];
24617
24591
  };
24618
- /** BranchOpeningQuantitySchema */
24619
- BranchOpeningQuantitySchema: {
24592
+ /** BatchSerialSummarySchema */
24593
+ BatchSerialSummarySchema: {
24594
+ /**
24595
+ * Id
24596
+ * Format: uuid
24597
+ */
24598
+ id: string;
24599
+ /**
24600
+ * Number
24601
+ * @description Serial number or batch number based on the tracking method
24602
+ */
24603
+ number?: string | null;
24604
+ /**
24605
+ * Quantity
24606
+ * @default 1
24607
+ */
24608
+ quantity: number | null;
24609
+ /**
24610
+ * Expirydate
24611
+ * @description Expiry date for the item if item has_expiry is true
24612
+ */
24613
+ expiryDate?: string | null;
24614
+ };
24615
+ /** ItemPackageSummarySchema */
24616
+ ItemPackageSummarySchema: {
24617
+ /**
24618
+ * Id
24619
+ * Format: uuid
24620
+ */
24621
+ id: string;
24622
+ /**
24623
+ * Barcode
24624
+ * @description Barcode of the item
24625
+ */
24626
+ barcode: string;
24627
+ /**
24628
+ * Quantity
24629
+ * @description Quantity of the item
24630
+ */
24631
+ quantity: number;
24632
+ /** @description Package of the item */
24633
+ package: components["schemas"]["PackageSummarySchema"];
24634
+ /** Returnable */
24635
+ returnable: boolean;
24636
+ };
24637
+ /** OpeningQuantityDetailsSchema */
24638
+ OpeningQuantityDetailsSchema: {
24639
+ /**
24640
+ * Datecreated
24641
+ * Format: date-time
24642
+ */
24643
+ dateCreated: string;
24644
+ /** Datemodified */
24645
+ dateModified: string | null;
24646
+ createdBy: components["schemas"]["RecordUserSchema"];
24647
+ modifiedBy: components["schemas"]["RecordUserSchema"] | null;
24620
24648
  /** Id */
24621
24649
  id: number;
24622
- /** Name */
24623
- name: string;
24650
+ item: components["schemas"]["ItemMinimalSchema"];
24651
+ /** @description Tracking method: serial_number, batch, or quantity */
24652
+ trackInventoryBy?: components["schemas"]["TrackingMethodChoices"] | null;
24653
+ unitOfMeasure: components["schemas"]["UnitOfMeasureSummaryInfo"];
24654
+ itemPackage: components["schemas"]["ItemPackageSummarySchema"] | null;
24655
+ /** Openingquantity */
24656
+ openingQuantity: number;
24657
+ /** Tracking */
24658
+ tracking: components["schemas"]["OpeningQuantityItemTrackingSchema"][];
24624
24659
  };
24625
- /** OpeningQuantityHeaderListSchema */
24626
- OpeningQuantityHeaderListSchema: {
24627
- info: components["schemas"]["PageInfoSchema"];
24660
+ /** OpeningQuantityItemTrackingSchema */
24661
+ OpeningQuantityItemTrackingSchema: {
24628
24662
  /**
24629
- * Results
24630
- * @default []
24663
+ * Id
24664
+ * Format: uuid
24631
24665
  */
24632
- results: components["schemas"]["OpeningQuantityHeaderSchema"][];
24666
+ id: string;
24667
+ /**
24668
+ * Number
24669
+ * @description Serial number or batch number based on the tracking method
24670
+ */
24671
+ number?: string | null;
24672
+ /**
24673
+ * Quantity
24674
+ * @description
24675
+ * - get track_inventory_by from item
24676
+ * - if tracked by serial number, quantity must be 1,
24677
+ * - if tracked by serial number, and there is item_package,
24678
+ * serial number must be match total number of units in the item_package.
24679
+ * example: if item_package has 10 units, and i have 3 packages, 30 serial numbers are required.
24680
+ * - if tracked by quantity, quantity must be equal to opening quantity,
24681
+ * - if tracked by batch, quantity can be any number but the sum of all quantities must be equal to opening quantity.
24682
+ *
24683
+ * @default 1
24684
+ */
24685
+ quantity: number;
24686
+ batch: components["schemas"]["BatchSerialSummarySchema"] | null;
24687
+ serial: components["schemas"]["BatchSerialSummarySchema"] | null;
24688
+ /**
24689
+ * Expiry Date
24690
+ * @description Expiry date for this tracking if applicable
24691
+ */
24692
+ expiry_date?: string | null;
24633
24693
  };
24634
- /** OpeningQuantityHeaderSchema */
24635
- OpeningQuantityHeaderSchema: {
24694
+ /** OpeningQuantitySchema */
24695
+ OpeningQuantitySchema: {
24636
24696
  /**
24637
24697
  * Datecreated
24638
24698
  * Format: date-time
@@ -24648,60 +24708,118 @@ export interface components {
24648
24708
  approvalStatus: components["schemas"]["ApprovalValueChoices"];
24649
24709
  /** Serialnumber */
24650
24710
  serialNumber: number;
24651
- warehouse: components["schemas"]["WarehouseOpeningQuantitySchema"];
24652
- branch: components["schemas"]["BranchOpeningQuantitySchema"];
24711
+ warehouse: components["schemas"]["WarehouseSummaryInfo"];
24712
+ branch: components["schemas"]["BranchSummaryInfo"];
24653
24713
  /** Description */
24654
24714
  description?: string | null;
24655
24715
  /** Candelete */
24656
24716
  canDelete: boolean;
24717
+ /**
24718
+ * Details
24719
+ * @default []
24720
+ */
24721
+ details: components["schemas"]["OpeningQuantityDetailsSchema"][];
24657
24722
  };
24658
- /** WarehouseOpeningQuantitySchema */
24659
- WarehouseOpeningQuantitySchema: {
24660
- /** Id */
24661
- id: number;
24662
- /** Name */
24663
- name: string;
24664
- };
24665
- /** CreateOpeningQuantityDetailSchema */
24666
- CreateOpeningQuantityDetailSchema: {
24667
- /** Index */
24668
- index?: number | null;
24669
- /** Item */
24723
+ /**
24724
+ * PackageCategory
24725
+ * @enum {string}
24726
+ */
24727
+ PackageCategory: "primary" | "secondary" | "tertiary" | "disposable" | "sustainable" | "retail" | "luxury" | "flexible" | "rigid" | "custom";
24728
+ /**
24729
+ * TrackingMethodChoices
24730
+ * @enum {string}
24731
+ */
24732
+ TrackingMethodChoices: "serial_number" | "batch" | "quantity";
24733
+ /** CreateOpeningQuantityItemSchema */
24734
+ CreateOpeningQuantityItemSchema: {
24735
+ /**
24736
+ * Item
24737
+ * @description
24738
+ * - get active items only
24739
+ *
24740
+ */
24670
24741
  item: number;
24671
- /** Openingquantity */
24742
+ /**
24743
+ * Itempackage
24744
+ * Format: uuid
24745
+ */
24746
+ itemPackage?: string;
24747
+ /**
24748
+ * Unitofmeasure
24749
+ * @description
24750
+ * - get the unit of measure from the item units of measure
24751
+ * - if item_package is provided, use the unit of measure from the item_package
24752
+ * - if item_package and unit_of_measure is not provided, the system will use the unit of measure from the itemPackage
24753
+ *
24754
+ */
24755
+ unitOfMeasure?: number;
24756
+ /**
24757
+ * Openingquantity
24758
+ * @description
24759
+ * - if there is item_package, opening_quantity will be the number of packages
24760
+ * - if there is no item_package, opening_quantity will be the number of units
24761
+ * - in case of item_package, show the opening quantity as units too
24762
+ * - to get the number of units, multiply opening_quantity by item_package.quantity
24763
+ *
24764
+ */
24672
24765
  openingQuantity: number;
24766
+ /** Tracking */
24767
+ tracking: components["schemas"]["CreateOpeningQuantityItemTrackingSchema"][];
24673
24768
  };
24674
- /** OpeningQuantityCreateSchema */
24675
- OpeningQuantityCreateSchema: {
24676
- /** Warehouse */
24769
+ /** CreateOpeningQuantityItemTrackingSchema */
24770
+ CreateOpeningQuantityItemTrackingSchema: {
24771
+ /**
24772
+ * Number
24773
+ * @description Serial number or batch number based on the tracking method
24774
+ */
24775
+ number?: string | null;
24776
+ /**
24777
+ * Quantity
24778
+ * @description
24779
+ * - get track_inventory_by from item
24780
+ * - if tracked by serial number, quantity must be 1,
24781
+ * - if tracked by quantity, quantity must be equal to opening quantity,
24782
+ * - if tracked by batch, quantity can be any number but the sum of all quantities must be equal to opening quantity.
24783
+ *
24784
+ * @default 1
24785
+ */
24786
+ quantity: number | null;
24787
+ /**
24788
+ * Expirydate
24789
+ * @description
24790
+ * - check if item has_expiry_date is True
24791
+ * - if True, expiry date is required
24792
+ * - if False, expiry date is not required and should not be visible in the UI
24793
+ *
24794
+ */
24795
+ expiryDate?: string | null;
24796
+ };
24797
+ /** CreateOpeningQuantitySchema */
24798
+ CreateOpeningQuantitySchema: {
24799
+ /**
24800
+ * Warehouse
24801
+ * @description
24802
+ * - get the warehouse from the user assigned warehouses
24803
+ *
24804
+ */
24677
24805
  warehouse: number;
24678
- /** Branch */
24679
- branch: number;
24680
- /** Details */
24681
- details: components["schemas"]["CreateOpeningQuantityDetailSchema"][];
24682
24806
  /** Description */
24683
24807
  description?: string | null;
24684
24808
  status: components["schemas"]["InternalStatusOnCreateValueChoices"];
24809
+ /** Details */
24810
+ details: components["schemas"]["CreateOpeningQuantityItemSchema"][];
24685
24811
  };
24686
- /** ItemOpeningQuantitySchema */
24687
- ItemOpeningQuantitySchema: {
24688
- /** Id */
24689
- id: number;
24690
- /** Name */
24691
- name: string;
24692
- };
24693
- /** OpeningQuantityDetailsListSchema */
24694
- OpeningQuantityDetailsListSchema: {
24812
+ /** OpeningQuantityHeaderListSchema */
24813
+ OpeningQuantityHeaderListSchema: {
24695
24814
  info: components["schemas"]["PageInfoSchema"];
24696
- header: components["schemas"]["OpeningQuantityHeaderSchema"];
24697
24815
  /**
24698
24816
  * Results
24699
24817
  * @default []
24700
24818
  */
24701
- results: components["schemas"]["OpeningQuantityDetailsSchema"][];
24819
+ results: components["schemas"]["OpeningQuantityHeaderSchema"][];
24702
24820
  };
24703
- /** OpeningQuantityDetailsSchema */
24704
- OpeningQuantityDetailsSchema: {
24821
+ /** OpeningQuantityHeaderSchema */
24822
+ OpeningQuantityHeaderSchema: {
24705
24823
  /**
24706
24824
  * Datecreated
24707
24825
  * Format: date-time
@@ -24713,56 +24831,97 @@ export interface components {
24713
24831
  modifiedBy: components["schemas"]["RecordUserSchema"] | null;
24714
24832
  /** Id */
24715
24833
  id: number;
24716
- item: components["schemas"]["ItemOpeningQuantitySchema"];
24717
- /** Openingquantity */
24718
- openingQuantity: number;
24719
- };
24720
- /** ChangeOpeningQuantitySchema */
24721
- ChangeOpeningQuantitySchema: {
24722
- /** Index */
24723
- index?: number | null;
24724
- /** Id */
24725
- id: number;
24726
- /** Item */
24727
- item?: number | null;
24728
- /** Openingquantity */
24729
- openingQuantity?: number | null;
24834
+ status: components["schemas"]["InternalStatusOnReturnValueChoices"];
24835
+ approvalStatus: components["schemas"]["ApprovalValueChoices"];
24836
+ /** Serialnumber */
24837
+ serialNumber: number;
24838
+ warehouse: components["schemas"]["WarehouseSummaryInfo"];
24839
+ branch: components["schemas"]["BranchSummaryInfo"];
24840
+ /** Description */
24841
+ description?: string | null;
24842
+ /** Candelete */
24843
+ canDelete: boolean;
24730
24844
  };
24731
- /** DeleteOpeningQuantityDetailSchema */
24732
- DeleteOpeningQuantityDetailSchema: {
24733
- /** Index */
24734
- index?: number | null;
24735
- /** Id */
24736
- id: number;
24845
+ /** UpdateOpeningQuantityItemTrackingSchema */
24846
+ UpdateOpeningQuantityItemTrackingSchema: {
24847
+ /**
24848
+ * Number
24849
+ * @description Serial number or batch number based on the tracking method
24850
+ */
24851
+ number?: string | null;
24852
+ /**
24853
+ * Quantity
24854
+ * @description
24855
+ * - get track_inventory_by from item
24856
+ * - if tracked by serial number, quantity must be 1,
24857
+ * - if tracked by quantity, quantity must be equal to opening quantity,
24858
+ * - if tracked by batch, quantity can be any number but the sum of all quantities must be equal to opening quantity.
24859
+ *
24860
+ * @default 1
24861
+ */
24862
+ quantity: number | null;
24863
+ /**
24864
+ * Expirydate
24865
+ * @description
24866
+ * - check if item has_expiry_date is True
24867
+ * - if True, expiry date is required
24868
+ * - if False, expiry date is not required and should not be visible in the UI
24869
+ *
24870
+ */
24871
+ expiryDate?: string | null;
24872
+ /**
24873
+ * Id
24874
+ * @description ID of the tracking (for update only)
24875
+ */
24876
+ id?: string | null;
24737
24877
  };
24738
- /** OpeningQuantityUpdateSchema */
24739
- OpeningQuantityUpdateSchema: {
24878
+ /** UpdateOpeningQuantitySchema */
24879
+ UpdateOpeningQuantitySchema: {
24740
24880
  /** Warehouse */
24741
- warehouse?: number | null;
24742
- /** Branch */
24743
- branch?: number | null;
24881
+ warehouse: number;
24744
24882
  /** Description */
24745
24883
  description?: string | null;
24746
24884
  status: components["schemas"]["InternalStatusOnCreateValueChoices"];
24747
- details?: components["schemas"]["UpdateOpeningQuantityDetailSchema"] | null;
24885
+ /** Details */
24886
+ details: components["schemas"]["updateOpeningQuantityItemSchema"][];
24748
24887
  };
24749
- /** UpdateOpeningQuantityDetailSchema */
24750
- UpdateOpeningQuantityDetailSchema: {
24888
+ /** updateOpeningQuantityItemSchema */
24889
+ updateOpeningQuantityItemSchema: {
24751
24890
  /**
24752
- * Add
24753
- * @default []
24891
+ * Item
24892
+ * @description
24893
+ * - get active items only
24894
+ *
24754
24895
  */
24755
- add: components["schemas"]["CreateOpeningQuantityDetailSchema"][];
24896
+ item: number;
24756
24897
  /**
24757
- * Update
24758
- * @default []
24898
+ * Itempackage
24899
+ * Format: uuid
24759
24900
  */
24760
- update: components["schemas"]["ChangeOpeningQuantitySchema"][];
24901
+ itemPackage?: string;
24761
24902
  /**
24762
- * Delete
24763
- * @default []
24903
+ * Unitofmeasure
24904
+ * @description
24905
+ * - get the unit of measure from the item units of measure
24906
+ * - if item_package is provided, use the unit of measure from the item_package
24907
+ * - if item_package and unit_of_measure is not provided, the system will use the unit of measure from the itemPackage
24908
+ *
24764
24909
  */
24765
- delete: components["schemas"]["DeleteOpeningQuantityDetailSchema"][];
24910
+ unitOfMeasure?: number;
24911
+ /**
24912
+ * Openingquantity
24913
+ * @description
24914
+ * - if there is item_package, opening_quantity will be the number of packages
24915
+ * - if there is no item_package, opening_quantity will be the number of units
24916
+ * - in case of item_package, show the opening quantity as units too
24917
+ * - to get the number of units, multiply opening_quantity by item_package.quantity
24918
+ *
24919
+ */
24920
+ openingQuantity: number;
24921
+ /** Tracking */
24922
+ tracking: components["schemas"]["UpdateOpeningQuantityItemTrackingSchema"][];
24923
+ /** Id */
24924
+ id?: number;
24766
24925
  };
24767
24926
  /** BranchInternalTransferSchema */
24768
24927
  BranchInternalTransferSchema: {
@@ -27053,7 +27212,7 @@ export interface components {
27053
27212
  /**
27054
27213
  * Id
27055
27214
  * Format: uuid
27056
- * @example 5c1b42c9-3d69-4631-89b2-f1953c1b793f
27215
+ * @example 895aee59-156c-40b8-b3bb-fba9b0a573e0
27057
27216
  */
27058
27217
  id: string;
27059
27218
  /**
@@ -31037,28 +31196,6 @@ export interface components {
31037
31196
  /** Name */
31038
31197
  name: string;
31039
31198
  };
31040
- /** ItemPackageSummarySchema */
31041
- ItemPackageSummarySchema: {
31042
- /**
31043
- * Id
31044
- * Format: uuid
31045
- */
31046
- id: string;
31047
- /**
31048
- * Barcode
31049
- * @description Barcode of the item
31050
- */
31051
- barcode: string;
31052
- /**
31053
- * Quantity
31054
- * @description Quantity of the item
31055
- */
31056
- quantity: number;
31057
- /** @description Package of the item */
31058
- package: components["schemas"]["PackageSummarySchema"];
31059
- /** Returnable */
31060
- returnable: boolean;
31061
- };
31062
31199
  /**
31063
31200
  * LinkedDocumentsSchema
31064
31201
  * @description Schema for individual linked documents.
@@ -31088,11 +31225,6 @@ export interface components {
31088
31225
  [key: string]: components["schemas"]["LinkedDocumentsSchema"];
31089
31226
  }[];
31090
31227
  };
31091
- /**
31092
- * PackageCategory
31093
- * @enum {string}
31094
- */
31095
- PackageCategory: "primary" | "secondary" | "tertiary" | "disposable" | "sustainable" | "retail" | "luxury" | "flexible" | "rigid" | "custom";
31096
31228
  /** ReasonSummaryInfo */
31097
31229
  ReasonSummaryInfo: {
31098
31230
  /** Id */
@@ -35321,7 +35453,7 @@ export interface components {
35321
35453
  quantity: number | null;
35322
35454
  /**
35323
35455
  * Expirydate
35324
- * @description Expiry date for the item if applicable
35456
+ * @description Expiry date for the item if item has expiry is true
35325
35457
  */
35326
35458
  expiryDate?: string | null;
35327
35459
  };
@@ -35420,11 +35552,6 @@ export interface components {
35420
35552
  /** Serialnumber */
35421
35553
  serialNumber: string;
35422
35554
  };
35423
- /**
35424
- * TrackingMethodChoices
35425
- * @enum {string}
35426
- */
35427
- TrackingMethodChoices: "serial_number" | "batch" | "quantity";
35428
35555
  /** CreateOrUpdateGoodsReceiptNoteItemTrackingSchema */
35429
35556
  CreateOrUpdateGoodsReceiptNoteItemTrackingSchema: {
35430
35557
  /**
@@ -55642,8 +55769,7 @@ export interface operations {
55642
55769
  page?: number;
55643
55770
  /** @description Page size */
55644
55771
  pageSize?: number;
55645
- /** @description Branch ID to filter by */
55646
- branchId?: number;
55772
+ search?: string | null;
55647
55773
  };
55648
55774
  header?: never;
55649
55775
  path?: never;
@@ -55707,7 +55833,7 @@ export interface operations {
55707
55833
  };
55708
55834
  requestBody: {
55709
55835
  content: {
55710
- "application/json": components["schemas"]["OpeningQuantityCreateSchema"];
55836
+ "application/json": components["schemas"]["CreateOpeningQuantitySchema"];
55711
55837
  };
55712
55838
  };
55713
55839
  responses: {
@@ -55717,7 +55843,7 @@ export interface operations {
55717
55843
  [name: string]: unknown;
55718
55844
  };
55719
55845
  content: {
55720
- "application/json": components["schemas"]["MessageWithCode"];
55846
+ "application/json": components["schemas"]["OpeningQuantitySchema"];
55721
55847
  };
55722
55848
  };
55723
55849
  /** @description Bad Request */
@@ -55747,15 +55873,6 @@ export interface operations {
55747
55873
  "application/json": components["schemas"]["MessageWithCode"];
55748
55874
  };
55749
55875
  };
55750
- /** @description Conflict */
55751
- 409: {
55752
- headers: {
55753
- [name: string]: unknown;
55754
- };
55755
- content: {
55756
- "application/json": components["schemas"]["MessageWithCode"];
55757
- };
55758
- };
55759
55876
  /** @description Internal Server Error */
55760
55877
  500: {
55761
55878
  headers: {
@@ -55767,19 +55884,12 @@ export interface operations {
55767
55884
  };
55768
55885
  };
55769
55886
  };
55770
- inventory_opening_stock_views_list_opening_quantity_details: {
55887
+ inventory_opening_stock_views_get_opening_quantity: {
55771
55888
  parameters: {
55772
- query?: {
55773
- /** @description Page number */
55774
- page?: number;
55775
- /** @description Page size */
55776
- pageSize?: number;
55777
- /** @description Branch ID to filter by */
55778
- branchId?: number;
55779
- };
55889
+ query?: never;
55780
55890
  header?: never;
55781
55891
  path: {
55782
- headerId: number;
55892
+ id: number;
55783
55893
  };
55784
55894
  cookie?: never;
55785
55895
  };
@@ -55791,16 +55901,7 @@ export interface operations {
55791
55901
  [name: string]: unknown;
55792
55902
  };
55793
55903
  content: {
55794
- "application/json": components["schemas"]["OpeningQuantityDetailsListSchema"];
55795
- };
55796
- };
55797
- /** @description Bad Request */
55798
- 400: {
55799
- headers: {
55800
- [name: string]: unknown;
55801
- };
55802
- content: {
55803
- "application/json": components["schemas"]["MessageWithCode"];
55904
+ "application/json": components["schemas"]["OpeningQuantitySchema"];
55804
55905
  };
55805
55906
  };
55806
55907
  /** @description Forbidden */
@@ -55837,13 +55938,13 @@ export interface operations {
55837
55938
  query?: never;
55838
55939
  header?: never;
55839
55940
  path: {
55840
- headerId: number;
55941
+ id: number;
55841
55942
  };
55842
55943
  cookie?: never;
55843
55944
  };
55844
55945
  requestBody: {
55845
55946
  content: {
55846
- "application/json": components["schemas"]["OpeningQuantityUpdateSchema"];
55947
+ "application/json": components["schemas"]["UpdateOpeningQuantitySchema"];
55847
55948
  };
55848
55949
  };
55849
55950
  responses: {
@@ -55853,7 +55954,7 @@ export interface operations {
55853
55954
  [name: string]: unknown;
55854
55955
  };
55855
55956
  content: {
55856
- "application/json": components["schemas"]["MessageWithCode"];
55957
+ "application/json": components["schemas"]["OpeningQuantitySchema"];
55857
55958
  };
55858
55959
  };
55859
55960
  /** @description Bad Request */
@@ -55883,15 +55984,6 @@ export interface operations {
55883
55984
  "application/json": components["schemas"]["MessageWithCode"];
55884
55985
  };
55885
55986
  };
55886
- /** @description Conflict */
55887
- 409: {
55888
- headers: {
55889
- [name: string]: unknown;
55890
- };
55891
- content: {
55892
- "application/json": components["schemas"]["MessageWithCode"];
55893
- };
55894
- };
55895
55987
  /** @description Internal Server Error */
55896
55988
  500: {
55897
55989
  headers: {
@@ -55903,34 +55995,23 @@ export interface operations {
55903
55995
  };
55904
55996
  };
55905
55997
  };
55906
- inventory_opening_stock_views_rest_to_draft: {
55998
+ inventory_opening_stock_views_delete_opening_quantity: {
55907
55999
  parameters: {
55908
56000
  query?: never;
55909
56001
  header?: never;
55910
56002
  path: {
55911
- headerId: number;
56003
+ id: number;
55912
56004
  };
55913
56005
  cookie?: never;
55914
56006
  };
55915
56007
  requestBody?: never;
55916
56008
  responses: {
55917
- /** @description OK */
55918
- 200: {
55919
- headers: {
55920
- [name: string]: unknown;
55921
- };
55922
- content: {
55923
- "application/json": components["schemas"]["MessageWithCode"];
55924
- };
55925
- };
55926
- /** @description Bad Request */
55927
- 400: {
56009
+ /** @description No Content */
56010
+ 204: {
55928
56011
  headers: {
55929
56012
  [name: string]: unknown;
55930
56013
  };
55931
- content: {
55932
- "application/json": components["schemas"]["MessageWithCode"];
55933
- };
56014
+ content?: never;
55934
56015
  };
55935
56016
  /** @description Forbidden */
55936
56017
  403: {
@@ -55961,44 +56042,28 @@ export interface operations {
55961
56042
  };
55962
56043
  };
55963
56044
  };
55964
- inventory_opening_stock_views_delete_opening_quantity_header: {
56045
+ inventory_opening_stock_views_reset_to_draft: {
55965
56046
  parameters: {
55966
56047
  query?: never;
55967
56048
  header?: never;
55968
56049
  path: {
55969
- headerId: number;
56050
+ id: number;
55970
56051
  };
55971
56052
  cookie?: never;
55972
56053
  };
55973
56054
  requestBody?: never;
55974
56055
  responses: {
55975
- /** @description No Content */
55976
- 204: {
55977
- headers: {
55978
- [name: string]: unknown;
55979
- };
55980
- content?: never;
55981
- };
55982
- /** @description Forbidden */
55983
- 403: {
55984
- headers: {
55985
- [name: string]: unknown;
55986
- };
55987
- content: {
55988
- "application/json": components["schemas"]["MessageWithCode"];
55989
- };
55990
- };
55991
- /** @description Not Found */
55992
- 404: {
56056
+ /** @description OK */
56057
+ 200: {
55993
56058
  headers: {
55994
56059
  [name: string]: unknown;
55995
56060
  };
55996
56061
  content: {
55997
- "application/json": components["schemas"]["MessageWithCode"];
56062
+ "application/json": components["schemas"]["OpeningQuantitySchema"];
55998
56063
  };
55999
56064
  };
56000
- /** @description Internal Server Error */
56001
- 500: {
56065
+ /** @description Bad Request */
56066
+ 400: {
56002
56067
  headers: {
56003
56068
  [name: string]: unknown;
56004
56069
  };
@@ -56006,26 +56071,6 @@ export interface operations {
56006
56071
  "application/json": components["schemas"]["MessageWithCode"];
56007
56072
  };
56008
56073
  };
56009
- };
56010
- };
56011
- inventory_opening_stock_views_delete_opening_quantity_detail: {
56012
- parameters: {
56013
- query?: never;
56014
- header?: never;
56015
- path: {
56016
- detailId: number;
56017
- };
56018
- cookie?: never;
56019
- };
56020
- requestBody?: never;
56021
- responses: {
56022
- /** @description No Content */
56023
- 204: {
56024
- headers: {
56025
- [name: string]: unknown;
56026
- };
56027
- content?: never;
56028
- };
56029
56074
  /** @description Forbidden */
56030
56075
  403: {
56031
56076
  headers: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@erp-galoper/types",
3
- "version": "1.0.581",
3
+ "version": "1.0.582",
4
4
  "main": "openapi.ts",
5
5
  "types": "openapi.ts",
6
6
  "files": ["openapi.ts"],