RICADO Gen 4 API JS Client

RICADO Gen 4 API JS Client

Class

ShiftQualitySummaryController

Controller Class for Shift Quality Summaries

Constructor

new ShiftQualitySummaryController()

Source

Methods

static

create(siteId, createData) → {Promise.<ShiftQualitySummaryModel>}

Create a Shift Quality Summary [POST /packhouse/sites/{siteId}/shift-quality-summaries]

Parameters

  • siteId number

    The Site ID

  • createData ShiftQualitySummaryController.CreateData

    The Shift Quality Summary Create Data

Returns

  • Promise.<ShiftQualitySummaryModel>

Source

static

createComment(siteId, id, content) → {Promise.<ShiftQualitySummaryController.CommentItem>}

Create a Comment [POST /packhouse/sites/{siteId}/shift-quality-summaries/{id}/comments]

Create a Comment for a Shift Quality Summary

Parameters

  • siteId number

    The Site ID

  • id string

    The Shift Quality Summary ID

  • content string

    The Content of the New Comment

Returns

  • Promise.<ShiftQualitySummaryController.CommentItem>

Source

static

deleteOneComment(siteId, id, commentId) → {Promise.<boolean>}

Delete a Comment [DELETE /packhouse/sites/{siteId}/shift-quality-summaries/{id}/comments/{commentId}]

Delete a Comment for a Shift Quality Summary

Parameters

  • siteId number

    The Site ID

  • id string

    The Shift Quality Summary ID

  • commentId string

    The Comment ID

Returns

  • Promise.<boolean>

Source

static

getAll(siteId, queryParametersopt) → {Promise.<Array.<ShiftQualitySummaryModel>>}

List all Shift Quality Summaries [GET /packhouse/sites/{siteId}/shift-quality-summaries]

Parameters

  • siteId number

    The Site ID

  • queryParameters ShiftQualitySummaryController.GetAllQueryParameters <optional>

    The Optional Query Parameters

Returns

  • Promise.<Array.<ShiftQualitySummaryModel>>

Source

static

getComments(siteId, id) → {Promise.<Array.<ShiftQualitySummaryController.CommentItem>>}

Retrieve Comments [GET /packhouse/sites/{siteId}/shift-quality-summaries/{id}/comments]

Retrieves Comments for a Shift Quality Summary

Parameters

  • siteId number

    The Site ID

  • id string

    The Shift Quality Summary ID

Returns

  • Promise.<Array.<ShiftQualitySummaryController.CommentItem>>

Source

static

getOne(siteId, id) → {Promise.<ShiftQualitySummaryModel>}

Retrieve a Shift Quality Summary [GET /packhouse/sites/{siteId}/shift-quality-summaries/{id}]

Parameters

  • siteId number

    The Site ID

  • id string

    The Shift Quality Summary ID

Returns

  • Promise.<ShiftQualitySummaryModel>

Source

static

getOneComment(siteId, id, commentId) → {Promise.<ShiftQualitySummaryController.CommentItem>}

Retrieve a Comment [GET /packhouse/sites/{siteId}/shift-quality-summaries/{id}/comments/{commentId}]

Retrieves Comments for a Shift Quality Summary

Parameters

  • siteId number

    The Site ID

  • id string

    The Shift Quality Summary ID

  • commentId string

    The Comment ID

Returns

  • Promise.<ShiftQualitySummaryController.CommentItem>

Source

static

update(siteId, id, updateData) → {Promise.<ShiftQualitySummaryModel>}

Update a Shift Quality Summary [PATCH /packhouse/sites/{siteId}/shift-quality-summaries/{id}]

Parameters

  • siteId number

    The Site ID

  • id string

    The Shift Quality Summary ID

  • updateData ShiftQualitySummaryController.UpdateData

    The Shift Quality Summary Update Data

Returns

  • Promise.<ShiftQualitySummaryModel>

Source

static

updateOneComment(siteId, id, commentId, content) → {Promise.<ShiftQualitySummaryController.CommentItem>}

Update a Comment [PATCH /packhouse/sites/{siteId}/shift-quality-summaries/{id}/comments/{commentId}]

Update a Comment for a Shift Quality Summary

Parameters

  • siteId number

    The Site ID

  • id string

    The Shift Quality Summary ID

  • commentId string

    The Comment ID

  • content string

    The Updated Content for the Comment

Returns

  • Promise.<ShiftQualitySummaryController.CommentItem>

Source

Type Definitions

CommentItem

A CommentItem Type

Type

  • Object

Properties

  • id string

    The Comment ID

  • userAccount ShiftQualitySummaryController.UserAccount
  • content string <nullable>

    The Content of the Comment

  • createdTimestamp Date <nullable>

    When the Comment was Created

  • updatedTimestamp Date <nullable>

    When the Comment was last Updated

Source

CreateData

The Create Data for a Shift Quality Summary

Type

  • Object

Properties

  • packingLineId string

    The Packing Line ID this Quality Summary is associated with

  • shiftId string <optional>

    The Shift ID this Quality Summary is asssociated with

  • createdTimestamp Date <optional>

    When this Quality Summary was Created

  • publishTimestamp Date <optional>
    <nullable>

    When this Quality Summary was Published

  • qualityManagerUserId string

    The User ID of the Quality Manager for this Summary

  • qualityManagerName string

    The Name of the Quality Manager for this Summary

  • accuracyResults Array.<ShiftQualitySummaryController.AccuracyResult> <optional>

    An Array of Accuracy Results for this Summary

  • auditResults Array.<ShiftQualitySummaryController.AuditResult> <optional>

    An Array of Audit Results for this Summary

  • packrunResults Array.<ShiftQualitySummaryController.PackrunResult> <optional>

    An Array of Packrun Results for this Summary

  • satisfactionRating number <optional>
    <nullable>

    An Optional Rating between 1 and 10 on how Satisfied the Quality Manager was with this Shift

Source

GetAllQueryParameters

The Optional Query Parameters for the getAll Function

Type

  • Object

Properties

  • packingLineId string <optional>

    The Packing Line ID this Quality Summary is associated with

  • shiftId string <optional>

    The Shift ID this Quality Summary is asssociated with

  • publishTimestamp Date <optional>
    <nullable>

    When this Quality Summary was Published

  • qualityManagerUserId string <optional>

    The User ID of the Quality Manager for this Summary

  • qualityManagerName string <optional>

    The Name of the Quality Manager for this Summary

  • createdTimestampBegin Date <optional>

    Filter by the Timestamp when Quality Summaries were Created. Results Greater than or Equal to Timestamp

  • createdTimestampEnd Date <optional>

    Filter by the Timestamp when Quality Summaries were Created. Results Less than or Equal to Timestamp

  • updateTimestampBegin Date <optional>

    Filter by the Timestamp when Quality Summaries were last Updated. Results Greater than or Equal to Timestamp

  • updateTimestampEnd Date <optional>

    Filter by the Timestamp when Quality Summaries were last Updated. Results Less than or Equal to Timestamp

Source

PackrunResult

A PackrunResult Type

Type

  • Object

Properties

  • packrunId string

    The ID of the associated Packrun

  • packrunName string

    The Name of the associated Packrun

  • minorPackingDefects number

    The R600 Minor Defects Percentage

  • majorPackingDefects number

    The R600 Major Defects Percentage

  • softs number

    The R600 Softs Percentage

  • cuts number

    The R600 Cuts (e.g. Flesh Damage) Percentage

  • rots number

    The R600 Rots Percentage

  • softsLineAverageSampleSize number <nullable>

    The Softs Line Average Sample Size

  • softsLineAverageValue number <nullable>

    The Softs Line Average Value

  • exportFruitInClass2 number <nullable>

    The Percentage of Export (Class 1) Fruit found in Class 2

  • exportFruitInLocalMarket number <nullable>

    The Percentage of Export (Class 1) Fruit found in Local Market

  • exportFruitInWaste number <nullable>

    The Percentage of Export (Class 1) Fruit found in Waste

Source

UpdateData

The Update Data for a Shift Quality Summary

Type

  • Object

Properties

  • packingLineId string <optional>

    The Packing Line ID this Quality Summary is associated with

  • createdTimestamp Date <optional>

    When this Quality Summary was Created

  • publishTimestamp Date <optional>
    <nullable>

    When this Quality Summary was Published

  • qualityManagerUserId string <optional>

    The User ID of the Quality Manager for this Summary

  • qualityManagerName string <optional>

    The Name of the Quality Manager for this Summary

  • accuracyResults Array.<ShiftQualitySummaryController.AccuracyResult> <optional>

    An Array of Accuracy Results for this Summary

  • auditResults Array.<ShiftQualitySummaryController.AuditResult> <optional>

    An Array of Audit Results for this Summary

  • packrunResults Array.<ShiftQualitySummaryController.PackrunResult> <optional>

    An Array of Packrun Results for this Summary

  • satisfactionRating number <optional>
    <nullable>

    An Optional Rating between 1 and 10 on how Satisfied the Quality Manager was with this Shift

Source