diff --git a/app/views/operator/jobs/_job.html.erb b/app/views/operator/jobs/_job.html.erb index e4c7ad7..85b6e3d 100644 --- a/app/views/operator/jobs/_job.html.erb +++ b/app/views/operator/jobs/_job.html.erb @@ -6,7 +6,7 @@

Operator ID: <% if job.operator %> - <%= job.operator_id %> - <%= job.operator.name %> (<%= job.operator.email %>) + <%= link_to_if allowed_to?(:show, job.operator, namespace: :Admin), "#{job.operatorr_id} - #{job.operator.name} (#{job.operator.email})", admin_user_path(job.operator) %> <% else %> - <% end %> @@ -14,18 +14,22 @@

Costumer ID: <% if job.costumer %> - <%= job.costumer_id %> - <%= job.costumer.name %> (<%= job.costumer.email %>) + <%= link_to_if allowed_to?(:show, job.costumer, namespace: :Admin), "#{job.costumer_id} - #{job.costumer.name} (#{job.costumer.email})", admin_user_path(job.costumer) %> <% else %> - <% end %>

- Betreiber: - <%= "#{job.operator_firstname} #{job.operator_lastname}" %> + Opertator: + <%= link_to_if job.operator && allowed_to?(:show, job.operator, namespace: :Admin), "#{job.operator_firstname} #{job.operator_lastname}", admin_users_path(job.operator) %> +

+

+ Erstellt durch Opertator: + <%= icon bool_icon(job.created_by_operator), class: "icon #{job.created_by_operator ? "text-green-600" : "text-red-600"}" %>

Auftraggeber: - <%= "#{job.costumer_firstname} #{job.costumer_lastname}" %> + <%= link_to_if job.costumer && !job.created_by_operator && allowed_to?(:show? , job.costumer, namespace: :Admin), "#{job.costumer_firstname} #{job.costumer_lastname}", admin_user_path(job.costumer) %>

Aktueller Status: