Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/EdgarJr30/proyecto-de-grado-cms/llms.txt

Use this file to discover all available pages before exploring further.

Overview

Reorder Policies automate inventory planning by defining minimum and maximum stock levels per part and warehouse. The system generates reorder suggestions when available stock falls below the reorder point.

Policy Structure

Each reorder policy defines:
FieldTypeDescription
part_idUUIDPart to manage
warehouse_idUUIDWarehouse location
min_qtynumberMinimum stock level (required)
max_qtynumberMaximum stock level (optional)
reorder_pointnumberTrigger level (optional, defaults to min_qty)
safety_stocknumberBuffer quantity (optional)
lead_time_daysnumberProcurement lead time (optional)
preferred_vendor_idUUIDPreferred supplier (optional)
Policies are unique per (part_id, warehouse_id) combination. Creating a duplicate updates the existing policy.

Accessing Reorder Policies

Navigate to Inventory > Políticas de reposición (/inventory/reorder) to manage policies.
Requires inventory:read to view. Creating/editing requires inventory:full_access.

Creating a Policy

1

Open Policy Dialog

Click Nueva política in the policies page.
2

Select Part

Choose the part to manage:
  • Filter by category for easier selection
  • Search by part code or name
3

Select Warehouse

Choose the warehouse location for this policy.
Each part can have different policies per warehouse. For example, critical parts may have higher minimums at main facility vs. remote sites.
4

Set Minimum Quantity

Enter the minimum stock level:
min_qty = Minimum acceptable stock before reorder
Consider:
  • Average daily/weekly usage
  • Lead time to replenish
  • Part criticality
  • Storage constraints
5

Set Maximum Quantity (Optional)

Enter the maximum stock level:
max_qty = Target stock after reorder
Leave blank if no upper limit needed.
6

Configure Reorder Point (Optional)

Set a different trigger than min_qty:
reorder_point = Trigger for reorder suggestion
Typically:
reorder_point = min_qty + (lead_time_usage)
If not set, system uses min_qty as trigger.
7

Add Safety Stock (Optional)

Buffer for demand variability:
safety_stock = Extra quantity to cover uncertainty
Consider:
  • Demand variability
  • Lead time reliability
  • Criticality
  • Cost of stockout
8

Enter Lead Time (Optional)

Days to receive after ordering:
lead_time_days = Procurement + delivery time
9

Select Preferred Vendor (Optional)

Choose default supplier for this part/warehouse.
10

Save Policy

Click Guardar to create or update the policy.

Policy Types

Minimum Quantity PolicySimplest policy:
min_qty = 10
max_qty = null
reorder_point = null (uses min)
Behavior:
  • Alert when available < 10
  • Suggest reorder to bring to min
  • No upper limit guidance
Best for: Low-value, non-critical parts

Reorder Quantity Calculation

When a suggestion is generated:
// If max_qty is defined:
order_qty = max_qty - available_qty

// If only min_qty:
order_qty = min_qty - available_qty

// With safety stock:
order_qty = max_qty - available_qty + safety_stock
Example:
Policy:
  min_qty = 10
  max_qty = 50
  reorder_point = 20
  safety_stock = 5

Current Stock:
  on_hand = 15
  reserved = 3
  available = 12

Trigger: available (12) < reorder_point (20) ✓

Suggested Order:
  order_qty = max_qty - available + safety_stock
  order_qty = 50 - 12 + 5
  order_qty = 43 units

Reorder Suggestions

View automated suggestions at Inventory > Políticas de reposiciónSugerencias button, which navigates to /inventory/reorder_suggestions.

Suggestion View (v_reorder_suggestions)

Shows parts that need reordering:
ColumnDescription
PartPart code and name
WarehouseStorage location
AvailableCurrent available quantity
Reorder PointTrigger level
Min/MaxMin and max quantities
Suggested QtyRecommended order amount
VendorPreferred supplier
Lead TimeDays to receive
Filtering:
  • By warehouse
  • By part category
  • By criticality
  • By vendor
Suggestions are calculated in real-time based on current available stock (on_hand - reserved).

Service Functions

Policy operations:
import {
  listReorderPolicies,
  upsertReorderPolicy,
  updateReorderPolicy,
  deleteReorderPolicy
} from '@/services/inventory/reorderPoliciesService';

// List policies for warehouse
const policies = await listReorderPolicies(warehouseId);

// Create or update policy (upsert by part+warehouse)
const policy = await upsertReorderPolicy({
  part_id: partId,
  warehouse_id: warehouseId,
  min_qty: 10,
  max_qty: 50,
  reorder_point: 20,
  safety_stock: 5,
  lead_time_days: 7,
  preferred_vendor_id: vendorId
});

// Update existing policy
await updateReorderPolicy(policyId, {
  min_qty: 15,
  reorder_point: 25
});

// Delete policy
await deleteReorderPolicy(policyId);

Policy Planning Workflow

1

Analyze Historical Usage

Review past consumption:
  • Average daily/weekly usage
  • Usage variability (standard deviation)
  • Seasonal patterns
  • Trend analysis
2

Determine Lead Time

Research procurement time:
  • Vendor lead time
  • Approval process
  • Shipping time
  • Receiving/inspection time
total_lead_time = order_to_delivery_days
3

Calculate Safety Stock

Buffer for uncertainty:
safety_stock = Z × σ × √L

Where:
Z = Service level factor (1.65 for 95%, 2.33 for 99%)
σ = Standard deviation of daily demand
L = Lead time in days
Example:
Daily usage: 5 ± 2 units (σ = 2)
Lead time: 10 days
Service level: 95% (Z = 1.65)

safety_stock = 1.65 × 2 × √10
safety_stock = 1.65 × 2 × 3.16
safety_stock ≈ 10 units
4

Set Reorder Point

When to trigger order:
reorder_point = (avg_daily_usage × lead_time_days) + safety_stock
Example:
Average daily usage: 5 units
Lead time: 10 days
Safety stock: 10 units

reorder_point = (5 × 10) + 10
reorder_point = 60 units
5

Set Minimum Quantity

Absolute minimum acceptable:
min_qty = safety_stock (or slightly above)
6

Set Maximum Quantity

Consider:
  • Economic order quantity (EOQ)
  • Storage capacity
  • Shelf life
  • Capital constraints
max_qty = reorder_point + order_qty
7

Create Policy

Enter all calculated values into the system.
8

Monitor and Adjust

Review periodically:
  • Quarterly for standard parts
  • Monthly for critical parts
  • After major usage changes
  • After lead time changes

Economic Order Quantity (EOQ)

Optimal order quantity to minimize total cost:
EOQ = √((2 × D × S) / H)

Where:
D = Annual demand
S = Order cost per order
H = Holding cost per unit per year
Example:
Annual demand: 1,200 units
Order cost: $50 per order
Holding cost: $2 per unit per year

EOQ = √((2 × 1200 × 50) / 2)
EOQ = √(120,000 / 2)
EOQ = √60,000
EOQ = 245 units

Orders per year: 1200 / 245 ≈ 5 orders
Use EOQ to inform max_qty setting.

ABC Analysis

Prioritize policies by part value/importance:
High Value / High Importance~20% of parts, ~80% of valuePolicy:
  • Tight control
  • Lower safety stock (cost)
  • Frequent review
  • Accurate forecasting
  • Preferred vendors
Example:
Critical pump impeller:
min_qty = 2
max_qty = 5
reorder_point = 3
safety_stock = 1
lead_time_days = 14

Best Practices

Start Simple

Begin with min/max only:
  • Easier to understand
  • Less data required
  • Refine over time
  • Add complexity as needed

Use Historical Data

Base decisions on actual usage:
  • Review past 6-12 months
  • Account for seasonality
  • Identify trends
  • Validate with stakeholders

Regular Reviews

Schedule policy audits:
  • A items: Monthly
  • B items: Quarterly
  • C items: Annually
  • After major changes

Document Rationale

Record policy reasoning:
  • Calculation methods
  • Assumptions made
  • Data sources
  • Review dates

Integration with Procurement

Reorder suggestions drive procurement workflow:
1

Generate Suggestions

System calculates nightly or on-demand based on available stock.
2

Review Suggestions

Procurement team reviews list:
  • Verify quantities
  • Check budget
  • Confirm lead times
  • Consolidate orders
3

Create Purchase Orders

Generate POs:
  • Use preferred vendors
  • Combine parts from same supplier
  • Negotiate pricing
  • Submit orders
4

Track Orders

Monitor incoming:
  • Expected delivery dates
  • Track shipments
  • Prepare receiving
5

Receive Stock

Process RECEIPT documents:
  • Reference PO number
  • Verify quantities
  • Enter unit costs
  • Update stock

Stock Management

View current stock levels that trigger policies

Documents

Create receipts from purchase orders

Parts

Set part criticality and attributes

Warehouses

Manage locations for policies

Build docs developers (and LLMs) love