import { CustomerInfoDTO } from '@generated/swagger/crm-api';
import {
  DBHOrderItemListItemDTO,
  OrderDTO,
  OrderItemProcessingStatusValue,
  OrderItemSubsetTaskListItemDTO,
  ReceiptDTO,
} from '@generated/swagger/oms-api';

export interface PickupShelfDetailsState {
  fetchingOrder?: boolean;
  order?: OrderDTO;

  fetchingOrderItems?: boolean;
  orderItems?: DBHOrderItemListItemDTO[];

  receipts?: ReceiptDTO[];
  fetchingReceipts?: boolean;

  displayedOrderItemProcessingStatus?: OrderItemProcessingStatusValue;
  displayedCompartmentCode?: string;
  displayedCompartmentInfo?: string;
  displayedOrderItemSubsetId?: number;

  fetchingCustomer?: boolean;
  customer?: CustomerInfoDTO;

  fetchPartial?: boolean;
  disableHeaderStatusDropdown?: boolean;
  previousSelectedOrderItemSubsetId?: number;
  selectedOrderItemIds?: number[];
  selectedOrderItemQuantity?: Record<number, number>;
  selectedCompartmentInfo?: string;

  fetchingOrderItemSubsetTasks: { [orderItemSubsetId: number]: boolean };
  orderItemSubsetTasks: { [orderItemSubsetId: number]: OrderItemSubsetTaskListItemDTO[] };
  orderItemSubsetLoading?: boolean;

  coverOrderItems?: DBHOrderItemListItemDTO[];
  fetchingCoverOrderItems?: boolean;
}
