status scheduled

This commit is contained in:
2025-07-24 11:32:13 -03:00
parent 5b84490d18
commit 75e170acbb

View File

@ -135,7 +135,8 @@ defmodule ApiWeb.IndexLive do
patientname: p.patientname, patientname: p.patientname,
status: sr.idstatus, status: sr.idstatus,
statusname: st.statusname, statusname: st.statusname,
studydescription: s.studydescription studydescription: s.studydescription,
study_status: s.status
}, },
order_by: [desc: s.studydate] order_by: [desc: s.studydate]
@ -350,16 +351,25 @@ defmodule ApiWeb.IndexLive do
<p class="text-[12px]">Informe</p> <p class="text-[12px]">Informe</p>
</a> </a>
<% end %> <% end %>
<%= if assigns.idstudyfield == true do %> <%= if study.study_status != "scheduled" do %>
<a href={open_viewer(study.idstudy, study.accession, @dni, assigns)} target="_blank" class="ml-2 flex items-center" style="flex-direction: column;"> <%= if assigns.idstudyfield == true do %>
<svg class="w-12 h-12 text-[#297177] hover:text-[#4d9aa2]" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="currentColor" viewBox="0 0 24 24"> <a href={open_viewer(study.idstudy, study.accession, @dni, assigns)} target="_blank" class="ml-2 flex items-center" style="flex-direction: column;">
<path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/> <svg class="w-12 h-12 text-[#297177] hover:text-[#4d9aa2]" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="currentColor" viewBox="0 0 24 24">
</svg> <path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/>
<p class="text-[12px]">Imágenes</p> </svg>
</a> <p class="text-[12px]">Imágenes</p>
</a>
<% else %>
<a href={open_viewer(study.idstudy, study.accession, @dni, assigns)} target="_blank" class="ml-2 flex items-center" style="flex-direction: column;">
<svg class="w-12 h-12 text-[#297177] hover:text-[#4d9aa2]" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="currentColor" viewBox="0 0 24 24">
<path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/>
</svg>
<p class="text-[12px]">Imágenes</p>
</a>
<% end %>
<% else %> <% else %>
<a href={open_viewer(study.idstudy, study.accession, @dni, assigns)} target="_blank" class="ml-2 flex items-center" style="flex-direction: column;"> <a disabled target="_blank"class="ml-2 flex items-center" style="flex-direction: column;">
<svg class="w-12 h-12 text-[#297177] hover:text-[#4d9aa2]" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="currentColor" viewBox="0 0 24 24"> <svg class="w-12 h-12" style="color: #c3c3c3;" aria-hidden="true" xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="currentColor" viewBox="0 0 24 24">
<path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/> <path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/>
</svg> </svg>
<p class="text-[12px]">Imágenes</p> <p class="text-[12px]">Imágenes</p>
@ -383,19 +393,28 @@ defmodule ApiWeb.IndexLive do
</div> </div>
</td> </td>
<td class="px-6 py-4 whitespace-nowrap hidden md:block md:table-cell"> <td class="px-6 py-4 whitespace-nowrap hidden md:block md:table-cell">
<%= if assigns.idstudyfield == true do %> <%= if study.study_status != "scheduled" do %>
<a href={open_viewer(study.idstudy, study.accession, @dni, assigns)} target="_blank"> <%= if assigns.idstudyfield == true do %>
<svg class="w-12 h-12 text-[#297177] hover:text-[#4d9aa2]" xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"> <a href={open_viewer(study.idstudy, study.accession, @dni, assigns)} target="_blank">
<path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/> <svg class="w-12 h-12 text-[#297177] hover:text-[#4d9aa2]" xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24">
</svg> <path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/>
</a> </svg>
<% else %> </a>
<a href={open_viewer(study.idstudy, study.accession, @dni, assigns)} target="_blank"> <% else %>
<svg class="w-12 h-12 text-[#297177] hover:text-[#4d9aa2]" xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"> <a href={open_viewer(study.idstudy, study.accession, @dni, assigns)} target="_blank">
<path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/> <svg class="w-12 h-12 text-[#297177] hover:text-[#4d9aa2]" xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24">
</svg> <path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/>
</a> </svg>
<% end %> </a>
<% end %>
<% else %>
<a disabled target="_blank">
<svg class="w-12 h-12" style="color: #c3c3c3;" xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24">
<path fill-rule="evenodd" d="M9 2.221V7H4.221a2 2 0 0 1 .365-.5L8.5 2.586A2 2 0 0 1 9 2.22ZM11 2v5a2 2 0 0 1-2 2H4v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V4a2 2 0 0 0-2-2h-7Zm.394 9.553a1 1 0 0 0-1.817.062l-2.5 6A1 1 0 0 0 8 19h8a1 1 0 0 0 .894-1.447l-2-4A1 1 0 0 0 13.2 13.4l-.53.706-1.276-2.553ZM13 9.5a1.5 1.5 0 1 1 3 0 1.5 1.5 0 0 1-3 0Z" clip-rule="evenodd"/>
</svg>
</a>
<% end %>
</td> </td>
</tr> </tr>
</tbody> </tbody>