{% extends "base.html" %} {% block title %}{{ device.name }} — Battery Tracker{% endblock %} {% block content %} {% if device.parent %}
| Slots | {{ device.installed_count() }} / {{ device.battery_slots }} used |
| Type | {{ device.device_type }} |
| Battery Size | {{ device.battery_size }} |
| Warning | ⚠ Mixed brands installed |
| Location | {{ device.location }} |
| Notes | {{ device.notes }} |
| Part of | {{ device.parent.name }} |
| HA Live % | {% if ha_live_pct is not none %} {% if ha_live_pct < 20 %} ⚠ {{ ha_live_pct }}% {% else %} {{ ha_live_pct }}% {% endif %} {% else %} — {% endif %} |
No sub-components. Batteries are tracked at the device level.
{% endif %} + Add Sub-component{{ free_slots }} slot(s) free{% if device.battery_size %} — showing {{ device.battery_size }} batteries only{% endif %}
| Label | Brand | {% if ha_enabled %}Bat % | {% endif %}Last Charged | Notes | Actions |
|---|---|---|---|---|---|
| {{ b.label }} | {{ b.brand }} | {% if ha_enabled %}{% if b.battery_percentage is not none %} {% if b.battery_percentage < 20 %} ⚠ {{ b.battery_percentage }}% {% else %}{{ b.battery_percentage }}%{% endif %} {% else %}—{% endif %} | {% endif %}{{ b.charge_logs[-1].charged_date if b.charge_logs else '—' }} | {{ b.notes or '—' }} |
No batteries installed.
{% endif %} {% if installed %} {% endif %}No compatible batteries available.
{% endif %}No logbook entries yet.
{% endif %}Deleting this device will unassign all installed batteries and mark them available. {% if device.has_children() %} Sub-components ({{ device.children|map(attribute='name')|join(', ') }}) will become independent devices. {% endif %}