import { ZoneWorksheetOverview } from './zone-worksheet-overview'
import { ZoneWorksheetOverviewList } from './zone-worksheet-overview-list'
import { ZonePickingWorksheet } from './zone-picking-worksheet'

export const Query = `
  zoneWorksheetOverview(releaseGoods: [String!]!): ZoneWorksheetOverviewList @transaction
  zonePickingWorksheet(name: String!, locationSortingRules: [Sorting!], filter: String): ZonePickingWorksheet @transaction
`

export const Mutation = `
  generateWorksheetZonePicking(releaseGoods: [String!]): Worksheet @transaction
  activateWorksheetZonePicking(name: String!): Worksheet @transaction
  activateBulkWorksheetZonePicking(names: [String!]): Worksheet @transaction
  scanProductZonePicking(worksheetId: String!, cartonId: String!, productBarcode: String, binNo: String!, pickingQty: Float): Boolean @transaction
  assignSorter(releaseGoodId: [String]!, userId: String): Boolean @transaction
  completeZonePicking(worksheetId: String!): Boolean @transaction
  completeZonePickingPartially(worksheetId: String!): Boolean @transaction
  getZonePickingTask: ZonePickingWorksheet @privilege(category: "worksheet_control", privilege: "mutation") @transaction
`

export const Types = [ZoneWorksheetOverview, ZoneWorksheetOverviewList, ZonePickingWorksheet]
