Skip to content

Vendor Contracts

Vendor contracts record the commercial frame under which purchase orders may be raised against a supplier: value, period, renewal rules, and legal/commercial text. Waqti supports full CRUD for drafts, an approval gate, activation, operational use with purchase orders, and termination or deletion where policy allows.

Contract types

When creating or editing, contract type must be one of the configured types (labels are translated in the app):

  • Fixed price — agreed price for defined scope.
  • Time and materials — billed on effort and consumption.
  • Blanket — call-off or schedule against a ceiling.
  • Service — recurring or scoped services.
  • Maintenance — support and upkeep.
  • Lease — asset or facility lease style terms.

Creating a contract

Create opens a form backed by validation:

FieldRule
TitleRequired.
DescriptionOptional (up to 2000 characters).
VendorRequired; must be an existing active vendor.
Contract typeRequired; must match allowed keys.
Spend categoryOptional.
Department / ProjectOptional.
Start / end dateRequired; end must be after start.
Contract valueRequired, non-negative.
CurrencyRequired.
Payment termsOptional (up to 500 characters).
Auto renewBoolean; when used with renewal fields, defines rollover behavior.
Renewal period (months)Optional, 1–60.
Notice period (days)Optional, 1–365.
Min / max order amountOptional non-negative caps per PO against the contract.
Terms and conditionsOptional long text.
Delivery termsOptional (up to 1000 characters).
Warranty termsOptional (up to 1000 characters).
Internal notesOptional (up to 2000 characters).

On save, ContractService::createContract runs and you are redirected to the contract show page.

Lifecycle and statuses

StatusMeaning
draftEditable; not yet submitted for approval.
pending_approvalAwaiting approver action.
approvedCleared to activate when dates and rules are satisfied.
activeIn force; PO creation may be allowed subject to value and dates.
expiredPast end date or system-determined expiry.
terminatedEnded early with a recorded reason.
cancelledDiscarded or voided before full use.

Submit for approval

From draft, submit moves the contract to pending_approval via submitForApproval. Only drafts can be submitted; other states return an error.

Approve

Users with approval rights (per your policy) may approve when status is pending_approval. That transitions the record toward approved so it can be activated.

Activate

Activate is offered when status is approved. The service may enforce date and data rules; failures return a message. Successful activation moves the contract to active for operational PO linkage.

Editing

Edit and update are allowed only in draft or pending_approval. Active, expired, terminated, or cancelled contracts redirect with “cannot be edited.”

Terminate

Terminate requires a reason (required, up to 1000 characters). Use this for early exit, mutual exit, or force majeure documentation. Status becomes terminated when the service succeeds.

Purchase orders and utilization

The show page loads recent purchase orders linked to the contract and displays stats:

  • Count of POs and summed PO value
  • Utilization percentage against contract value
  • Remaining value
  • Days until expiry

Create PO from a contract is gated by canCreatePO() on the model (dates, status, and remaining value).

Deletion

Delete is permitted only for draft or cancelled contracts. If any purchase order references the contract, deletion is blocked with an explicit error. Successful deletion returns to the contract list.

Listing and filters

The index supports:

  • Search on contract number, title, or vendor name
  • Status, contract type, vendor
  • Expiring soon (within 30 days, via scope)
  • Sorting by configurable columns

Summary statistics include total contracts, active count, expiring soon, and summed active contract value.

Internal notes vs vendor-facing text

Keep internal notes for procurement and legal commentary. Put enforceable language in terms and conditions, delivery, warranty, and payment fields that vendors and auditors expect to see on outputs.

Built by M & L Technologies