Add warning if no pricing data available

This commit is contained in:
Oliver Walters 2019-05-18 23:13:18 +10:00
parent 368193d397
commit ffda5a1b29

View File

@ -15,13 +15,13 @@ Calculate pricing information for {{ part }}.
<td><b>Quantity</b></td> <td><b>Quantity</b></td>
<td>{{ quantity }}</td> <td>{{ quantity }}</td>
</tr> </tr>
{% if buy_price %} {% if buy_price %}
<tr> <tr>
<td><b>Buy Cost</b></td> <td><b>Buy Cost</b></td>
<td>{{ buy_price }}</td> <td>{{ buy_price }}</td>
</tr> </tr>
{% endif %} {% endif %}
{% if bom_price %} {% if bom_price %}
<tr> <tr>
<td><b>BOM Cost</b></td> <td><b>BOM Cost</b></td>
<td>{{ bom_price }}</td> <td>{{ bom_price }}</td>
@ -33,9 +33,16 @@ Calculate pricing information for {{ part }}.
</td> </td>
</tr> </tr>
{% endif %} {% endif %}
{% endif %} {% endif %}
</table> </table>
{% if buy_price or bom_price %}
{% else %}
<div class='alert alert-danger alert-block'>
No pricing information is available for this part.
</div>
{% endif %}
<hr> <hr>
{% endblock %} {% endblock %}