| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184 |
- {% extends 'base.html' %}
- {% block body %}
- <form name="inputUtente" method="POST">
- <div class='form-control'>
- {% if "AMMINISTRATORE.CREA" in permesso %}
- <input type='submit' class="btn btn-primary" name='sceltanuovo' value='Nuovo Amministratore'>
- <button type='button' class="btn btn-primary" name='TastoCaricaIndici' data-bs-toggle='modal' data-bs-target='#CaricaIndiceModal'>Carica Lista Nuovi Amministratori</button>
- {% endif %}
- <input type='submit' class="btn btn-primary" name="indietro" value="Indietro">
- </div>
- <div class='form-control'>
- Numero di amministratori registrati {{ amministratorelistalen }}.
- </div>
- {% csrf_token %}
- <table class='table table-striped table-hover'>
- <thead class='thead-dark'>
- <tr>
- {% if "AMMINISTRATORE.EDIT" in permesso %}<th scope='col'>*</th>{% endif %}
- <th scope='col'>Login</th>
- <th scope='col'>Nome</th>
- <th scope='col'>Mail</th>
- {% if "AMMINISTRATORE.EDIT" in permesso %}
- <th scope='col'>Pin</th>
- {% endif %}
- </tr>
- </thead>
- <tbody>
- {% csrf_token %}
- {% for aa in amministratorelista %}
- <tr>
- {% if "AMMINISTRATORE.EDIT" in permesso %}
- <td> <button type='submit' class='btn btn-primary btn-block btn-lg mb-2 active' name='scelta' value='{{ aa.id }}' onchange="this.form.submit()">Edit</button></td>
- {% endif %}
- <td> {{ aa.login }} </td>
- <td> {{ aa.nome }} </td>
- <td> {{ aa.mail }} </td>
- {% if "AMMINISTRATORE.EDIT" in permesso %}
- <td> {{ aa.pin }} </td>
- {% endif %}
- </tr>
- {% endfor %}
- </tbody>
- </table>
- </form>
- {% if "AMMINISTRATORE.CREA" in permesso %}
- <!-- Modal -->
- <div class="modal fade" id="CaricaIndiceModal" tabindex="-1" role="dialog" aria-labelledby="CaricaIndiceLabel" aria-hidden="true">
- <div class="modal-dialog" role="document">
- <div class="modal-content">
- <form name='formCaricaIndice' method='POST' enctype='multipart/form-data'>
- {% csrf_token %}
- <div class="modal-header">
- <h5 class="modal-title" id="CaricaIndiceLabel">Carica Elenco Dipendenti</h5>
- <span aria-hidden="true">×</span>
- </button>
- </div>
- <div class="modal-body">
- Caricamento Lista Dipendenti<br>
- Formato File CSV - obbligatorio <br>
- Separatore: ',' - prima riga: "Nome colonna".</br>
- <table class='table table-striped table-hover'>
- <tbody>
- <tr>
- <td>Nome Cognome</td>
- <td>Codice Fiscale</td>
- <td>Data di Nascita</td>
- <td>Luogo di Nascita</td>
- <td/email</td>
- </tr>
- </tbody>
- </table><br>
- <label for='indice'>Elenco Dipendenti: </label>
- <input type='file' name='indice' id='indice' value='' accept='text/csv'>
- </div>
- <div class="modal-footer">
- <button type="submit" name="CaricaIndice" value='Carica Lista' class="btn btn-primary">Carica Lista Dipendenti</button>
- <button type="button" class="btn btn-primary" data-bs-dismiss="modal">Annulla</button>
- </div>
- </form>
- </div>
- </div>
- </div>
- </div>
- <!-- end modal -->
- {% endif %}
- {% endblock %}
- {% block bottom %}
- {% if "AMMINISTRATORE.CREA" in permesso %}
- <!-- Modal -->
- <div class="modal fade" id="CaricaIndiceModal" tabindex="-1" role="dialog" aria-labelledby="CaricaIndiceLabel"
- aria-hidden="true">
- <div class="modal-dialog" role="document">
- <div class="modal-content">
- <form name='formCaricaIndice' method='POST' enctype='multipart/form-data'>
- {% csrf_token %}
- <div class="modal-header">
- <h5 class="modal-title" id="CaricaIndiceLabel">Carica Elenco Dipendenti</h5>
- <span aria-hidden="true">×</span>
- </button>
- </div>
- <div class="modal-body">
- Caricamento Lista Dipendenti<br>
- Formato File CSV - obbligatorio <br>
- Separatore: ';' - prima riga: "Nome colonna".</br>
- <table class='table table-striped table-hover'>
- <tbody>
- <tr>
- <td>Identificativo SEDE</td>
- <td>Nome Sede</td>
- </tr>
- </tbody>
- </table><br>
- <label for='indice'>Elenco Amministratori: </label>
- <input type='file' name='indice' id='indice' value='' accept='text/csv'>
- </div>
- <div class="modal-footer">
- <button type="submit" name="CaricaIndice" value='Carica Lista' class="btn btn-primary">Carica Li
- sta Dipendenti</button>
- <button type="button" class="btn btn-primary" data-bs-dismiss="modal">Annulla</button>
- </div>
- </form>
- </div>
- </div>
- </div>
- </div>
- <!-- end modal -->
- {% endif %}
- <div><br><br></div>
- {% if listaok %}
- <table class='table table-striped table-hover'>
- <thead class='thead-dark'>
- <tr>
- <th scope='col'>Documento caricato con successo</th>
- </tr>
- </thead>
- <tbody>
- {% for l in listaok %}
- <tr>
- <td> {{ l }} </td>
- </tr>
- {% endfor %}
- </tbody>
- </table>
- {% endif %}
- <div><br><br></div>
- {% if listanotok %}
- <table class='table table-striped table-hover'>
- <thead class='thead-dark'>
- <tr>
- <th scope='col'>Documento non caricato perche già presente</th>
- </tr>
- </thead>
- <tbody>
- {% for l in listanotok %}
- <tr>
- <td> {{ l }} </td>
- </tr>
- {% endfor %}
- </tbody>
- </table>
- {% endif %}
- {% if listaok %}
- {% for i in listaok %}
- {{i }}
- {% endfor %}
- {% endif %}
- {% if listanotok %}
- {% for i in listanotok %}
- {{i }}
- {% endfor %}
- {% endif %}
- {% endblock %}
|