Medication: {{ object.medication.generic_name }}
Brand Name: {{ object.medication.brand_name|default:"Not specified" }}
Strength: {{ object.medication.strength }}
Location: {{ object.location.name }}
Bin/Shelf: {{ object.bin_location|default:"Not specified" }}
Current Stock:
{{ object.current_stock }}
Total Value: ${{ object.total_value|floatformat:2 }}
Lot Number: {{ object.lot_number|default:"Not specified" }}
Expiration:
{% if object.expiration_date %}
{{ object.expiration_date|date:"M d, Y" }}
{% if object.is_expired %}(Expired){% elif object.expires_soon %}(Expires Soon){% endif %}
{% else %}
Not specified
{% endif %}
{% if object.medication.is_controlled %}
Controlled Substance
{% endif %}
{% if object.medication.is_high_alert %}
High Alert
{% endif %}
Potential Issues:
{% if object.current_stock > 0 %}
- {{ object.current_stock }} units in stock (value: ${{ object.total_value|floatformat:2 }})
{% endif %}
{% if object.pending_orders.exists %}
- {{ object.pending_orders.count }} pending order(s)
{% endif %}
{% if object.recent_transactions.exists %}
- {{ object.recent_transactions.count }} recent transaction(s)
{% endif %}
{% if object.medication.is_controlled %}
- Controlled substance requires special handling
{% endif %}
{% if object.medication.is_high_alert %}
- High alert medication
{% endif %}
{% if object.is_expired %}
- Expired medication
{% elif object.expires_soon %}
- Expires soon
{% endif %}
Related Records:
- Transactions: {{ object.transactions.count }}
- Purchase orders: {{ object.purchase_orders.count }}
- Dispensing records: {{ object.dispensing_records.count }}
- Stock counts: {{ object.stock_counts.count }}
{% if object.current_stock > 0 %}
Stock on Hand Warning
This inventory record shows {{ object.current_stock }} units in stock with a total value of ${{ object.total_value|floatformat:2 }}. Deleting this record may:
- Result in loss of inventory tracking for existing stock
- Affect financial reporting and asset valuation
- Disrupt dispensing and prescription fulfillment
- Impact reorder calculations and stock management
- Remove important audit trail information
Consider adjusting stock to zero or marking as inactive instead of deleting.
{% endif %}
{% if object.medication.is_controlled %}
Controlled Substance Warning
This inventory contains a controlled substance. Deletion must be properly documented for DEA compliance and audit purposes. All stock movements should be accounted for before deletion.
{% endif %}
{% if object.medication.is_high_alert %}
High Alert Medication Warning
This is a high alert medication that requires special safety protocols. Deletion may affect safety procedures and clinical guidelines.
{% endif %}
{% if object.is_expired %}
Expired Medication Notice
This medication is expired and should be properly disposed of according to pharmacy protocols before deleting the inventory record.
{% endif %}
{% if object.transactions.exists %}
Transaction History Warning
This inventory record has {{ object.transactions.count }} transaction(s). Deleting it will remove the transaction history and may affect audit trails and financial reporting.
{% endif %}
Instead of deleting this inventory record, consider these alternatives: