Each Audit Type has many Audit Items, they are accessible with the
method:
AuditType.audit_items
It is possible to expire audit items, this sets the expired column to 1.
They still need to be linked with the Audit Type though, so i can not
delete the foreign key.
When i call AuditType.audit_items i dont want the items that have been
expired to show, but i do not know how to do this. Any ideas on the
best way to do it??
if !(states & second_group).empty? && !(states & first_group).empty?
The reasoning is that, if states contains either the ‘open’ or the
‘analyzed’
entries, then its intersection with first_group (states & first_group)
won’t
be empty. The same for the second group.
I hope this helps
Stefano
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.