WebAPI – How do I update the material consumption report?

WebAPI – How do I update the material consumption report?

 This method allows to change a material consumption.

The method to be used when changing the work order material consumption is:  POST /api/mytenant/myorganization/maintenance/workorderreportconsumptions/updateWorkOrderReportConsumptionInfo/{{companyKey}}/{{workOrderReportConsumptionIKey}}

The parameters in the method are:
  1. companyKey: company key
  2. workOrderKey: work order key
Json example to update a work order material consumption

  1. {
    "Description": "Consumption record",
    "Employee": "P00002",
    "Remarks": "General remarks",
    "WOConsumptionLines":
    [
    {
    "Date": "2019-09-05T11:31:17.477+00:00",
    "Description": "Consumption item one",
    "Quantity": "5",
    "Remarks": "Consumption remarks",
    "Employee": "PORTES",
    "Unit": "UN",
    "WareHouse": "WH1",
    "WorkOrderMaintenancePlan": "MP1",
    "WOMaintenancePlanTaskId": "45D98B07-9F8B-4C27-90E4-6243AEAEE300",
    "WOTaskId": null
    },
    {
    "Date": "2019-09-05T11:31:17.477+00:00",
    "Description": "Consumption item two",
    "Quantity": "3",
    "Remarks": "Consumption remarks",
    "Employee": "PORTES",
    "Unit": "UN",
    "WareHouse": null,
    "WorkOrderMaintenancePlan": null,
    "WOMaintenancePlanTaskId ": "69703AF8-49EB-4C0A-B0A4-49FBE25F7D61",
    "WOTaskId": "T000013"
    }
    ]
    }
This method allows to change a consumption report according to the parameters filled in
  1. Description: the consumption report description. This field is required.
  2. Employee: the employee key.
  3. Remarks: the observations.
  4. WOConsumptionLines: the consumption items. This field is required and each consumption line must have the following parameters:
    1. Date: consumption date
    2. Description: consumption description
    3. Quantity: item quantity. This field is required.
    4. Part: part key. This field is required.
    5. Unit: unit key.
    6. WareHouse: warehouse key
    7. Remarks: observations
    8. WorkOrderMaintenancePlan: the key of the WO maintenance plan.
    9. WOMaintenancePlanTaskId: the task identifier associated to the WO maintenance plan.
    10. WOTaskId: the task identifier for the WO additional work. This field cannot be used together with the maintenance plan or the maintenance plan task.
When a method is executed successfully, it returns a HttpStatusCode.OK.
    • Related Articles

    • WebAPI – How to update the misc costs report?

      This method allows you to change the misc cost of a work order. The method to be used for changing one other cost is: POST /api/mytenant/myorganization/maintenance/workorderreportmisccosts / ...
    • WebAPI – How do I update the labor report?

      This method allows you to change the labor record of a work order. The method to be used for changing the work order labor record is: POST /api/mytenant/myorganization/maintenance/workorderreportlabors/ ...
    • WebAPI – How do I update the task verification record?

      This method allows you to change the task verification record of a work order. The method to be used for changing the work order task verification record is: POST /api/mytenant/myorganization/maintenance/ ...
    • Webapi - Deleting a work order consumption report

       This method allows you to delete a work order consumption report.   The method used to delete a work order consumption report is:   DELETE  ...
    • Webapi - Creating a consumption report in a work order

      This method allows you to create a consumption report in a work order in a simplified way.   The method used to create a consumption report in a work order is:   POST {{url}}/api/{{tenant}}/{{organization}}/maintenance/workOrderReportConsumptions   ...