Initial work at coercing activity feed into showing RAs

Also shows Asset/Supplier on the homepage feed.
This commit is contained in:
2020-05-29 15:39:45 +01:00
parent 0e2adf3f0d
commit 156e639bac
5 changed files with 19 additions and 9 deletions

View File

@@ -608,3 +608,6 @@ class RiskAssessment(models.Model):
suspended_structures = models.BooleanField(default=False, help_text="Are any structures (excluding projector screens and IWBs) being suspended from TEC's structures?")
# Blimey that was a lot of options
def __str__(self):
return "%i: %s" % (self.pk, self.event)

View File

@@ -1,4 +0,0 @@
{% load to_class_name from filters %}
{# pass in variable "object" to this template #}
<a title="{% if object.is_rig == False %}Non-rig{% elif object.dry_hire %}Dry Hire{% elif object.is_rig %}Rig{%else%}{{object|to_class_name}}{% endif %} | '{{object.name}}'" href="{{ object.get_absolute_url }}">{% if object.is_rig == False %}Non-rig{% elif object.dry_hire %}Dry Hire{% elif object.is_rig %}Rig{%else%}{{object|to_class_name}}{% endif %} | '{{ object.activity_feed_string|default:object.name }}'</a>

View File

@@ -9,7 +9,7 @@
{% endif %}
<!-- TODO show invoice stuff here -->
{% if event.risk_assessment_edit_url %}
{% if event.riskassessment %}
<span class="badge badge-success">RA: <i class="fas fa-check"></i></span>
{% else %}
<span class="badge badge-danger">RA: <i class="fas fa-times"></i></span>