azienda.welcome.html 3.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586
  1. {% extends 'base.html' %}
  2. {% block body %}
  3. <div class='form-outline mb-3 text-center btn-primary h3'>
  4. {% if not azienda %}
  5. Attenzione, Selezionare una azienda dal pannello superiore!
  6. {% else %}
  7. <form name="azienda" method="POST">
  8. {% csrf_token %}
  9. <button type="submit" class='btn btn-primary' name="utenti" value="{{ azienda.id }}">Utenti</button>
  10. <button type='submit' class="btn btn-primary" name="documenti" value='{{ azienda.id }}'>Documenti</button>
  11. {% if listaAttivitaxAzienda %}
  12. <button type 'submit' class='btn btn-primary' name="xx" value='{{ azienda.id }}'>Attività proprie</button>
  13. {% else %}
  14. <button type='submit' class='btn btn-primary' name="attivita" value='{{ azienda.id }}'>Tutte le Attività</button>
  15. {% endif %}
  16. <button type='submit' class='btn btn-primary' name='comunicazioni' value='{{ azienda.id }}'>Comunicazioni</button>
  17. <button type='submit' class='btn btn-primary' name='parazienda' value='{{ azienda.id }}'>Par.Azienda</button>
  18. <button type='submit' class='btn btn-primary' name='parsede' value='{{ sede.id }}'>Par.Sede</button>
  19. </form>
  20. {% endif %}
  21. </div>
  22. {% endblock %}
  23. {% block bodybottom %}
  24. <div><br><br></div>
  25. <div class='form-outline mb-3 text-center btn-primary h3'>
  26. {% if listaAttivitaxAzienda %}
  27. Elenco di tutte le attività registrate per l'azienda ...
  28. {% else %}
  29. Elenco attivita' registrate sul proprio account
  30. {% endif %}
  31. </div>
  32. <div>
  33. {% if listaAttivitaxAzienda %}
  34. <table class='table table-striped table-hover'>
  35. <thead class='thead-dark'>
  36. <tr>
  37. <th scope='col'>Data</th>
  38. <th scope='col'>Causale</th>
  39. <th scope='col'>Utente</th>
  40. <th scope='col'>Amministratore</th>
  41. <th scope='col'>documento</th>
  42. </tr>
  43. </thead>
  44. <tbody>
  45. {% for attivita in listaAttivitaxAzienda %}
  46. <tr>
  47. <td> {{ attivita.data | date:'d/m/Y H:i' }} </td>
  48. <td> {{ attivita.causale.nome }} </td>
  49. <td> {{ attivita.utente.nome }} </td>
  50. <td> {{ attivita.amministratore.username }}</td>
  51. <td> {{ attivita.documento.documento }}</td>
  52. </tr>
  53. {% endfor %}
  54. </tbody>
  55. </table>
  56. {% else %}
  57. <table class='table table-striped table-hover'>
  58. <thead class='thead-dark'>
  59. <tr>
  60. <th scope='col'>Data</th>
  61. <th scope='col'>Causale</th>
  62. <th scope='col'>Utente</th>
  63. <th scope='col'>Amministratore</th>
  64. <th scope='col'>documento</th>
  65. </tr>
  66. </thead>
  67. <tbody>
  68. {% for attivita in listaAttivitaxAmministrazione %}
  69. <tr>
  70. <td> {{ attivita.data | date:'d/m/Y H:i' }} </td>
  71. <td> {{ attivita.causale.nome }} </td>
  72. <td> {{ attivita.utente.nome }} </td>
  73. <td> {{ attivita.amministratore.nome }}</td>
  74. <td> {{ attivita.documento.documento }}</td>
  75. </tr>
  76. {% endfor %}
  77. </tbody>
  78. </table>
  79. {% endif %}
  80. </div>
  81. {% endblock %}