| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677 |
- <div class="row">
- {{-- @if($is_edit)
- <div class="col-md-12 mb-4"></div>
- <div class="col-auto mb-4">
- <div class="form-group">
- <button class="btn btn-outline-primary text-uppercase btn-medium" type="button" wire:click="cancel()">Annulla</button>
- </div>
- </div>
- <div class="col-auto mb-4">
- <div class="form-group">
- <button class="btn btn-primary text-uppercase btn-medium" type="button" wire:click="save()">Salva</button>
- </div>
- </div>
- @else --}}
- <div class="col-md-12 col-xs-12">
- <div class="form-group text-end">
- <button class="btn btn-primary text-uppercase btn-medium" type="button" wire:click="add()">Aggiungi</button>
- </div>
- </div>
- <div class="col-md-12 col-xs-12">
- <table class="dataTable display" id="company-rates">
- <thead>
- <tr>
- <th>Gruppo</th>
- <th>Tariffa</th>
- <th>Tipo</th>
- <th>Descrizione</th>
- <th class="no-sort text-center dt-actions-th">Azioni</th>
- </tr>
- </thead>
- <tbody>
- {{-- @foreach($company_rates as $c)
- <tr>
- <td>{{$c->name}}</td>
- <td>{{$c->description}}</td>
- <td class="text-center dt-actions">
- <a class="dt-action" wire:click="edit({{$c->id}})"><i class="icli iconly-Edit-Square"></i></a>
- <a class="dt-action" {{--wire:click="delete({{$c->id}})" --/}}><i class="icli iconly-Delete"></i></a>
- </td>
- </tr>
- @endforeach --}}
- </tbody>
- </table>
- </div>
- {{-- @endif --}}
- </div>
- @push('scripts')
- <script>
- document.addEventListener("DOMContentLoaded", () => {
- let table_id = "#company-rates";
- let options = {
- paging: true,
- ordering: true,
- columnDefs: [
- {
- targets: 'no-sort',
- orderable: false,
- }
- ],
- language: {
- url: DT_languageIT,
- },
- };
- Livewire.on('update', () => {
- setTimeout(() => {
- loadDatatables("#company-rates", options);
- }, 10);
- });
- loadDatatables("#company-rates", options);
- });
- </script>
- @endpush
|