|
|
@@ -135,7 +135,7 @@
|
|
|
|
|
|
</section>
|
|
|
|
|
|
- <div wire:ignore.self class="modal fade" id="rateModal" tabindex="-1" aria-labelledby="rateModalLabel" aria-hidden="true">
|
|
|
+ <div wire:ignore.self class="modal" id="rateModal" tabindex="-1" aria-labelledby="rateModalLabel" aria-hidden="true">
|
|
|
<div class="modal-dialog">
|
|
|
<div class="modal-content">
|
|
|
<div class="modal-header">
|
|
|
@@ -155,7 +155,7 @@
|
|
|
</div>
|
|
|
<div class="col-md-6">
|
|
|
<label for="price" class="form-label">Prezzo</label>
|
|
|
- <input class="form-control" type="text" id="price" placeholder="Costo mensile" wire:model="price" onkeyup="onlyNumberAmount(this)">
|
|
|
+ <input class="form-control" type="text" id="price" placeholder="Costo" wire:model="price" onkeyup="onlyNumberAmount(this)">
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="row mt-2">
|
|
|
@@ -163,27 +163,54 @@
|
|
|
<label for="date" class="form-label">Scadenza</label>
|
|
|
<input class="form-control @error('date') is-invalid @enderror" type="date" id="date" placeholder="Email" wire:model="date">
|
|
|
</div>
|
|
|
+ @if($type == '1')
|
|
|
+ <div class="col-md-6">
|
|
|
+ <label for="date" class="form-label">Mesi</label>
|
|
|
+ <select class="form-control" id="months" wire:model="months">
|
|
|
+ <option value="9">Settembre</option>
|
|
|
+ <option value="10">Ottobre</option>
|
|
|
+ <option value="11">Novembre</option>
|
|
|
+ <option value="12">Dicembre</option>
|
|
|
+ <option value="1">Gennaio</option>
|
|
|
+ <option value="2">Febbraio</option>
|
|
|
+ <option value="3">Marzo</option>
|
|
|
+ <option value="4">Aprile</option>
|
|
|
+ <option value="5">Maggio</option>
|
|
|
+ <option value="6">Giugno</option>
|
|
|
+ <option value="7">Luglio</option>
|
|
|
+ <option value="8">Agosto</option>
|
|
|
+ </select>
|
|
|
+ </div>
|
|
|
+ @endif
|
|
|
<div>
|
|
|
- <div class="row mt-2">
|
|
|
- <div class="col-md-12">
|
|
|
- <label for="months" class="form-label">Mesi</label><br>
|
|
|
- <input type="checkbox" value="1" class="chkMonth"> Gennaio
|
|
|
- <input type="checkbox" value="2" class="chkMonth"> Febbraio
|
|
|
- <input type="checkbox" value="3" class="chkMonth"> Marzo
|
|
|
- <input type="checkbox" value="4" class="chkMonth"> Aprile<br>
|
|
|
- <input type="checkbox" value="5" class="chkMonth"> Maggio
|
|
|
- <input type="checkbox" value="6" class="chkMonth"> Giugno
|
|
|
- <input type="checkbox" value="7" class="chkMonth"> Luglio
|
|
|
- <input type="checkbox" value="8" class="chkMonth"> Agosto<br>
|
|
|
- <input type="checkbox" value="9" class="chkMonth"> Settembre
|
|
|
- <input type="checkbox" value="10" class="chkMonth"> Ottobre
|
|
|
- <input type="checkbox" value="11" class="chkMonth"> Novembre
|
|
|
- <input type="checkbox" value="12" class="chkMonth"> Dicembre
|
|
|
+ @if($type > 1)
|
|
|
+ <div class="row mt-2">
|
|
|
+ <div class="col-md-12">
|
|
|
+ <label for="months" class="form-label">Seleziona {{$type}} Mesi</label><br>
|
|
|
+ <div class="row">
|
|
|
+ <div class="col-3"><input type="checkbox" value="9" class="chkMonth"> Settembre</div>
|
|
|
+ <div class="col-3"><input type="checkbox" value="10" class="chkMonth"> Ottobre</div>
|
|
|
+ <div class="col-3"><input type="checkbox" value="11" class="chkMonth"> Novembre</div>
|
|
|
+ <div class="col-3"><input type="checkbox" value="12" class="chkMonth"> Dicembre</div>
|
|
|
+ </div>
|
|
|
+ <div class="row">
|
|
|
+ <div class="col-3"><input type="checkbox" value="1" class="chkMonth"> Gennaio</div>
|
|
|
+ <div class="col-3"><input type="checkbox" value="2" class="chkMonth"> Febbraio</div>
|
|
|
+ <div class="col-3"><input type="checkbox" value="3" class="chkMonth"> Marzo</div>
|
|
|
+ <div class="col-3"><input type="checkbox" value="4" class="chkMonth"> Aprile</div>
|
|
|
+ </div>
|
|
|
+ <div class="row">
|
|
|
+ <div class="col-3"><input type="checkbox" value="5" class="chkMonth"> Maggio</div>
|
|
|
+ <div class="col-3"><input type="checkbox" value="6" class="chkMonth"> Giugno</div>
|
|
|
+ <div class="col-3"><input type="checkbox" value="7" class="chkMonth"> Luglio</div>
|
|
|
+ <div class="col-3"><input type="checkbox" value="8" class="chkMonth"> Agosto </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
- </div>
|
|
|
+ @endif
|
|
|
|
|
|
</div>
|
|
|
- <div class="modal-footer">
|
|
|
+ <div class="modal-footer mt-2">
|
|
|
<button class="btn--ui lightGrey" onclick="annulla()">annulla</a>
|
|
|
<button type="button" class="btn--ui btn-primary" wire:click.prevent="add()">Inserisci</button>
|
|
|
</div>
|
|
|
@@ -322,6 +349,18 @@
|
|
|
|
|
|
});
|
|
|
|
|
|
+ $('.monthsSelect').select2({
|
|
|
+
|
|
|
+ });
|
|
|
+ $('.monthsSelect').on('change', function (e) {
|
|
|
+ var data = $('.monthsSelect').select2("val");
|
|
|
+ @this.set('months', data);
|
|
|
+ setTimeout(function() {
|
|
|
+ $('.monthsSelect').select2({
|
|
|
+ });
|
|
|
+ }, 100);
|
|
|
+ });
|
|
|
+
|
|
|
} );
|
|
|
|
|
|
Livewire.on('close-popup', () => {
|