Stock handling units

Изменить статус физической складской единицы

Changed on

Выведенную из оборота единицу вернуть нельзя; вывод из оборота требует нулевого остатка.

patch/api/v1/stock/handling-units/{id}/status

Request

  • Base URL
    https://erp.akeda.ru
  • Auth
    • HTTP bearer
    • or API key in header X-Api-Key
    • or OAuth 2
      Authorization codehttps://erp.akeda.ru/oauth2/authorize
      Token URLhttps://erp.akeda.ru/oauth2/token
      Scopesakeda:delegate
    • or HTTP bearer

Path parameters

id, string uuid required

Headers

X-Tenant, string required

Slug выбранного кабинета; кабинет не является юрлицом

Request body

StockHandlingUnitStatusPatch required
status, 'active' | 'blocked' | 'retired' required

Статус, который оператор назначает физической единице руками

Response

Единица с новым статусом

StockHandlingUnit required
id, string uuid required
batch_id, string uuid required
business_id, string uuid
company_id, string uuid required

Нулевой UUID — единица без юрлица

company_name, string required
product_id, string uuid required
product_sku, string required
product_name, string required
base_unit, string required
source_document_id, string uuid required
source_document_number, string required
source_document_status, 'draft' | 'posted' | 'cancelled' required
source_line_id, string uuid required
code, string required
initial_base_qty, string required
remaining_base_qty, string required

Остаток на месте единицы, из движений регистра stock. Хвост на складе «в пути» перемещения с приёмкой сюда не входит, пока у единицы есть обычный остаток

is_remnant, boolean required

Остаток меньше порога обрезка у единицы товара: вычисляется по остатку всей единицы вместе с хвостом в пути, а не хранится

reserved_base_qty, string required

Считается из движений регистра stock_reserved

amount, string required

Стоимость остатка на месте единицы, из движений регистра stock; хвост в пути не входит, как и в remaining_base_qty

status, 'active' | 'blocked' | 'retired' required

Статус, который оператор назначает физической единице руками

state, 'pending' | 'sealed' | 'opened' | 'empty' | 'cancelled' | 'blocked' | 'retired' | 'location_conflict' required

Вычисленное состояние единицы; выводится из статуса, документа-основания и остатков регистра

warehouse_id, string uuid nullable
warehouse_name, string required
custom, object required
received_at, string date-time required
created_at, string date-time required
updated_at, string date-time required

Changes

    • info

      added the optional property field to the response with the status

    • info

      added the optional property field to the response with the status

    • info

      added the optional property field to the response with the status

    7 more changes in this revision