Fixed link_to if customer is not set

This commit is contained in:
2024-10-02 13:53:17 +02:00
parent 337ff9b9d9
commit c625d61c0d

View File

@@ -7,10 +7,10 @@
<% end %>
</td>
<td class="p-2 py-3">
<%= link_to_if job.customer_firstname, admin_user_path(job.customer), target: "_top" %>
<%= link_to_if job.customer, job.customer_firstname, ( job.customer ? admin_user_path(job.customer) : ""), target: "_top" %>
</td>
<td class="p-2 py-3">
<%= link_to_if job.customer_lastname, admin_user_path(job.customer), target: "_top" %>
<%= link_to_if job.customer, job.customer_lastname, ( job.customer ? admin_user_path(job.customer) : ""), target: "_top" %>
</td>
<td class="p-2 py-3">
<% if job.pdf.attached? %>