API · v1 · estable
CODEMETA OSDeveloper Center
ES
Abrir la consola
Entidad · project_positions

Project Position Schema

ID del esquema
project_position
Colección
project_positions
Permisos
  • Leerproject_position_view
  • Crearproject_position_create
  • Modificarproject_position_edit
  • Eliminarproject_position_delete
Relaciones

Campos

Project Position Schema

project_positions4 permisos

ADR 0310 — optional billing/grouping layer between a project and its tasks; carries the billing model and aggregates the effort of its tasks.

projectIduuidopcional→ project

Owning project UUID.

subProjectIduuidopcional→ project

ADR 1128 Nachtrag „Zuordnung statt Umzug“ — Unterprojekt, das diese Position bearbeitet. Die Position, ihre Aufgaben und Leistungen bleiben im Auftragsprojekt (`projectId`, Abrechnung unverändert); das Unterprojekt zeigt sie nur und seine Leitung arbeitet darin. Geschützt: nur POST /projects/:id/positions/sub-project setzt oder leert es. ABSENT/null = nur Auftragsprojekt, kein Backfill.

solo lecturaadmite null
positionNumberintegeropcional

Position number carried over from the sales order (display / ordering).

≥ 0admite null
sortOrderintegeropcional

Manual sort order within the project (drag & drop).

≥ 0admite null
titlestringobligatorio

Position title.

1–200 caracteres
generatedTitlestringopcional

ADR 1018 — title materialise_order last generated from the order line. While `title` still equals it, nobody renamed the position and the title follows a renamed weclapp line; null on rows created before the field (the history CREATE entry is used instead).

solo lecturaadmite null
descriptionstringopcional

Position description.

máx. 4000 caracteresadmite null
statusstringobligatorio

Position lifecycle status.

OPENDONECANCELLED
billingModelstringobligatorio

flat_rate = fixed price, bookings are a profitability metric only (never hard-blocked). time_and_material = billed by actual bookings; an optional cap lives on the task (limitMode).

flat_ratetime_and_material
plannedMinutesintegeropcional

Planned effort in minutes (Soll).

≥ 0admite null
plannedAmountstringopcional

Planned / sold net amount in EUR (Soll), decimal string.

Patrónadmite null
plannedAmountCurrencystringopcional

ISO 4217 currency for plannedAmount (default EUR when null).

Patrónadmite null
quantitystringopcional

Sold quantity carried over from the order item (decimal string).

Patrónadmite null
unitPricestringopcional

Unit price carried over from the order item (decimal string).

Patrónadmite null
netAmountstringopcional

Net amount carried over from the order item (decimal string).

Patrónadmite null
orderItemSnapshotobjectopcional

Frozen copy of the sold order line, written ONCE when the position is created from a sales order (order intake / order import) and never refreshed. quantity/unitPrice/netAmount above follow the order on every intake run; this snapshot keeps the sold terms visible for the price check even after the line was edited or deleted in weclapp. Server-managed (protected).

solo lecturaadmite null
quantitystringopcional
Patrónadmite null
unitNamestringopcional
máx. 100 caracteresadmite null
unitPricestringopcional
Patrónadmite null
discountPercentstringopcional
Patrónadmite null
netAmountstringopcional
Patrónadmite null
weclappItemIdstringopcional
máx. 64 caracteresadmite null
consumedMinutesintegeropcional

Sum of loggedMinutes of the tasks under this position (cached rollup). ADR 0924: rounded working time.

≥ 0solo lecturaadmite null
consumedRealMinutesintegeropcional

ADR 0924: the same bookings as consumedMinutes summed as NET working time (cached rollup) — the "(real)" part of the display.

≥ 0solo lecturaadmite null
consumedAmountstringopcional

Sum of consumedAmount of the tasks under this position (cached rollup, EUR).

Patrónsolo lecturaadmite null
articleIduuidopcional

Optional linked article UUID.

admite null
salesOrderIduuidopcional

Sales order this position was materialised from (order-import path).

solo lecturaadmite null
salesOrderItemIdstringopcional

ID of the orderItem inside the linked sales_order (matches salesOrder.orderItems[].id).

solo lecturaadmite null
salesOrderItemSourcestringopcional

Origin of the linked sales-order item — internal or weclapp.

internalweclappnull
solo lecturaadmite null
weclappBillingModestringopcional

ADR 0634 — wie diese Position im weclapp-Auftrag abgerechnet wird. `position` (Default, auch bei null) = die Auftragsposition bleibt stehen und wird bebucht/fakturiert wie verkauft; `replace` = die Auftragsposition ist eine Nicht-DL-Platzhalterposition und wird beim Abrechnungsabschluss durch die gerenderten Buchungspositionen ERSETZT. Vorbelegt aus der Intake-Regel (`position.weclappBilling`), danach im Projektabrechnungs-Dialog änderbar; ein Re-Import überschreibt den Wert bewusst NICHT.

positionreplacenull
admite null
billedAtdatetimeopcional

When this flat-rate position was put on a Leistungsnachweis (per-project billing run). Null = not billed yet.

solo lecturaadmite null
performanceRecordIduuidopcional

Leistungsnachweis this position was billed on. Server-managed.

solo lecturaadmite null
invoiceIduuidopcional

Invoice this position was billed on. Server-managed.

solo lecturaadmite null

Endpoints estándar

Este recurso sigue el contrato CRUD genérico de la plataforma. Lea las convenciones sobre paginación, idempotencia, bloqueo optimista y auditoría. Los endpoints principales:

  • GET /api/v1/project_positions — Lista, paginada y filtrable
  • GET /api/v1/project_positions/<id> — Una entidad
  • POST /api/v1/project_positions — Crear
  • PATCH /api/v1/project_positions/<id> — Actualización parcial
  • DELETE /api/v1/project_positions/<id> — Eliminación lógica
  • GET /api/v1/project_positions/<id>/timeline — Auditoría y actividades

Búsqueda