KGRKJGETMRETU895U-589TY5MIGM5JGB5SDFESFREWTGR54TY
Server : Apache/2.4.41 (Ubuntu)
System : Linux vmi1525618.contaboserver.net 5.4.0-105-generic #119-Ubuntu SMP Mon Mar 7 18:49:24 UTC 2022 x86_64
User : www-data ( 33)
PHP Version : 8.2.12
Disable Function : NONE
Directory :  /var/www/leadai/webmaster.leadai.co.in/resources/views/notificationsetting/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //var/www/leadai/webmaster.leadai.co.in/resources/views/notificationsetting/list.blade.php
@extends('layout')
@section('content')
    <!-- begin::main content -->
    <main class="main-content">
        <div class="container">
            <!-- begin::page header -->
            <div class="page-header">
                <h3 class="text-capitalize">Notification Setting</h3>
                <nav aria-label="breadcrumb">
                    <ol class="breadcrumb">
                        <li class="breadcrumb-item"><a href="{{ asset('dashboard') }}">Dashboard</a></li>
                        <li class="breadcrumb-item active" aria-current="page">Notification Setting</li>
                    </ol>
                </nav>
            </div>
            <!-- end::page header -->
            <div class="card">
                <?php if(Auth::user()->hasRole('webmaster') || Auth::user()->can('add-notificationsetting')){ ?>
                <div class="card-header">
                    <a href="{{ asset('add-notificationsetting') }}" class="btn btn-primary pull-left text-white">
                    <i class="fa fa-plus fa-lg pr-2"></i> Add
                    </a>
                </div>
                <?php } ?>
                <div class="card-body">
                    <table id="example1" class="table table-striped table-bordered">
                        <thead>
                            <tr>
                           
                             
                                <th>Admin Name</th>
                                
                                <th>ANDROID URL</th>
                                <th>ANDROID TOKEN</th>
                                <th>IOS URL</th>
                                <th>IOS TOKEN</th>
                                
                                <th>Created At</th>
                              
                                {{-- <th>Permission</th> --}}
                                <th>Action</th>
                            </tr>
                        </thead>
                        <tbody>
                            @if (!empty($notification_settings))
                                @foreach ($notification_settings as $notification_setting)
                                    <tr>
                                       
                                     
                                        <td>{{ $notification_setting->name }}</td>
                                      
                                        <td>{{ $notification_setting->android_url }}</td>
                                        <td>{{ $notification_setting->android_token	 }}</td>
                                        <td>{{ $notification_setting->ios_url }}</td>
                                        <td>{{ $notification_setting->ios_token }}</td>
                                    
                                 
                                        <td>{{ date("d-m-Y",strtotime($notification_setting->created_at)) }}</td>
																			<td>
																				 {{-- Add User --}}
																				 <?php if(Auth::user()->hasRole('webmaster') || Auth::user()->can('edit-notificationsetting')){ ?>
																					<a title="Edit User" class="btn btn-success text-white btn-square"
																							href="{{ asset('edit-notificationsetting/' . $notification_setting->id) }}"><i
																									class="fa fa-edit fa-lg text-white"></i></a>
																					<?php }?>

																					{{-- Delete user --}}
																					<?php if(Auth::user()->hasRole('webmaster') || Auth::user()->can('delete-notificationsetting')) { ?>
																					<a title="Delete User"
																							class="btn btn-danger text-white btn-square delete-confirm"
																							href="javascript:;"
																							link="{{ asset('delete-notificationsetting/' . $notification_setting->id) }}"
																							class="delete-confirm">
																							<i class="fa fa-trash fa-lg text-white"></i>
																					</a>
																					<?php }?>
																			</td>
                                    </tr>
                                @endforeach
                            @endif
                        </tbody>
                    </table>
                </div>
            </div>
        </div>
    </main>
    <!-- end::main content -->
@endsection
@push('footer-script')
    <!-- begin::dataTable -->
    <script src="{{ asset('public/admin/vendors/dataTable/jquery.dataTables.min.js') }}"></script>
    <script src="{{ asset('public/admin/vendors/dataTable/dataTables.bootstrap4.min.js') }}"></script>
    <script src="{{ asset('public/admin/vendors/dataTable/dataTables.responsive.min.js') }}"></script>
    <script src="{{ asset('public/admin/js/examples/datatable.js') }}"></script>
    <script>
        $(document).ready(function() {
            $('#adminuserstb').DataTable({
                responsive: false,
                "lengthMenu": [
                    [25, 50, 75, 100, -1],
                    [25, 50, 75, 100, "All"]
                ],
                'order': [],
                'columnDefs': [{
                    "targets": [1, 3, 4, 5, 6, 7],
                    "orderable": false
                }]
            });
        });

        /* webmaster user status change */
        $('.status-change').on('change', function(e) {
            e.preventDefault();
            $.ajaxSetup({
                headers: {
                    'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                }
            });
            let id = $(this).data('id');
            let ckb = $(this).is(':checked');
            // alert(ckb);

            $.ajax({
                url: "{{ asset('change-status') }}",
                type: "POST",
                dataType: "html",
                data: {
                    id: id,
                    ckb: ckb
                },

                success: function(result) {
                    if (result == '1') {
                        toastr.success('User Activated!');
                    } else {
                        toastr.warning('User Deactivated!');
                    }
                }
            });
        });
    </script>
    <!-- end::dataTable -->
@endpush

Anon7 - 2021