Server : Apache System : Linux 145.162.205.92.host.secureserver.net 5.14.0-611.45.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Apr 1 05:56:53 EDT 2026 x86_64 User : tradze ( 1001) PHP Version : 8.1.34 Disable Function : NONE Directory : /home/tradze/www/storage-old/framework/views/ |
<?php $__env->startSection('title'); ?>
<?php echo $page_title; ?>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('css_page'); ?>
<link href="<?php echo e(asset('/themes/admin/assets/global/plugins/datatables/plugins/bootstrap/dataTables.bootstrap.css')); ?>" rel="stylesheet">
<?php $__env->stopSection(); ?>
<?php $__env->startSection('content'); ?>
<!-- BEGIN PAGE HEADER-->
<div class="page-bar">
<ul class="page-breadcrumb">
<li>
<i class="fa fa-home"></i>
<a href="#">Home</a>
<i class="fa fa-angle-right"></i>
</li>
<li>
<a href="#"><?php echo e(trans('users::therapists.breadcrumbs_title')); ?></a>
<i class="fa fa-angle-right"></i>
</li>
<li>
<a href="#"><?php echo e(trans('users::therapists.page_title')); ?></a>
</li>
</ul>
</div>
<!-- END PAGE HEADER-->
<!--display messaged-->
<?php echo $__env->make('flash::message', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
<!--/ display messaged-->
<div class="row">
<div class="col-md-12">
<div class="portlet">
<div class="portlet-title">
<div class="caption">
<?php echo $page_title; ?>
</div>
<div class="actions">
<a href="<?php echo e(route('admin.users.providers.create')); ?>" class="btn blue btn-sm"><i class="fa fa-plus"></i> <?php echo e(trans('users::therapists.add')); ?></a>
</div>
</div>
<div class="portlet-body">
<!--filters-->
<?php echo Form::open(array('url' => route('admin.users.providers.search'), 'method' => 'post' ,'id'=>'search')); ?>
<div class="row">
<div class="col-md-12">
<div class="row">
<div class="col-md-6">
<?php echo Form::text('search_name', @($filters['search_name'])?:null, ['class'=>'form-control','placeholder'=>trans('users::clients.search_by_name')]); ?>
</div>
<div class="col-md-6">
<?php echo Form::text('search_phone', @($filters['search_phone'])?:null, ['class'=>'form-control','placeholder'=>trans('users::clients.search_by_phone')]); ?>
</div>
</div>
</div>
</div>
<div class="row margin-top-5"></div>
<div class="row" style="margin-top:5px;">
<div class="col-md-6">
<button id="searchProvider" class="btn blue-madison btn-sm col-md-12" name="search" value="search"><i class="icon-magnifier"></i> <?php echo e(strtoupper(trans('general.action_search'))); ?></button>
</div>
<div class="col-md-6">
<button class="btn btn-sm col-md-12" name="reset" value="reset"><i class="fa fa-times"></i> <?php echo e(strtoupper(trans('general.action_reset'))); ?></button>
</div>
</div>
<?php echo Form::close(); ?>
<div class="row" style="margin-top:5px;">
<div class="col-md-6">
<select name="rr_sortby" id="rr-sortby" class="form-control">
<!-- <option value="">Sort By :-</option> -->
<option selected value="all">All Rapid Response Accounts</option>
<option value="subscription">Only Active Subscriptions</option>
<option value="no_subscription">No Subscriptions/Unsubscribed</option>
<option value="active_verified_subscription">Active Verified Subscriptions</option>
<option value="unverified_service_documents">Unverified Service Documents</option>
<option value="expired_documents">Expired Documents</option>
<option value="deactivated_accounts">Deactivated Accounts</option>
</select>
</div>
<div class="col-md-6">
<!-- <label for="">Filter By Services</label> -->
<select name="service_id[]" class="form-control select2" multiple>
<?php $__currentLoopData = $services; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $key => $service): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
<option value="<?php echo e($key); ?>"><?php echo e($service); ?></option>
<?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
</select>
</div>
</div>
<hr/>
<!--end filters-->
<div class="container-fluid">
<div class="row">
<table class="table table-striped table-bordered table-hover" id="table">
<thead>
<tr class="heading">
<th width="2%"><?php echo e(trans('users::therapists.col_id')); ?></th>
<th width="25%"><?php echo e(trans('users::therapists.col_name')); ?></th>
<th width="3%" class="text-center"><i class="fa fa-info-circle"> </i></th>
<th width="15%">Subscription</th>
<th width="15%">Service Documents</th>
<th width="15%">Documents Verified</th>
<th width="15%"><?php echo e(trans('users::salon.col_status')); ?></th>
<th width="20%"><?php echo e(trans('users::therapists.col_actions')); ?></th>
</tr>
</thead>
</table>
</div>
</div>
</div>
</div>
</div>
</div>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('scripts_page_plugins'); ?>
<script src="<?php echo e(asset('/themes/admin/assets/global/scripts/datatable.js')); ?>" type="text/javascript"></script>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('scripts_page2'); ?>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('scripts_custom'); ?>
Demo.init();
<?php $__env->stopSection(); ?>
<?php $__env->startSection('scripts_custom2'); ?>
<script>
var tooltipTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]'))
var tooltipList = tooltipTriggerList.map(function (tooltipTriggerEl) {
return new bootstrap.Tooltip(tooltipTriggerEl)
})
const SORT_STORAGE_KEY = 'rr_users_sort_by';
const SERVICE_STORAGE_KEY = 'rr_users_service_filter';
$(document).ready(function()
{
var CSRF_TOKEN = '<?php echo e(csrf_token()); ?>';
$.ajaxSetup({
headers: {
'X-CSRF-TOKEN': CSRF_TOKEN
}
});
$(".select2").select2();
$(".select2filter").select2({
placeholder: 'Tag-uri'
});
$('.date-picker').datepicker({
orientation: "left",
autoclose: true,
format: 'yyyy-mm-dd',
});
var grid = new Datatable();
// Page length must match your DataTable pageLength
// var pageLength = 20;
// // Get saved page index from localStorage
// var savedPage = localStorage.getItem('therapist_table_page');
// var displayStart = 0;
// if (savedPage !== null) {
// displayStart = parseInt(savedPage) * pageLength; // calculate record offset
// }
var pageLength = 20;
var searchName = $('input[name="search_name"]').val() || '';
var searchPhone = $('input[name="search_phone"]').val() || '';
var key = 'therapist_table_page_' + searchName + '_' + searchPhone;
const savedSortBy = localStorage.getItem(SORT_STORAGE_KEY);
if (savedSortBy) {
$('#rr-sortby').val(savedSortBy);
}
// Restore service filter
const savedServices = localStorage.getItem(SERVICE_STORAGE_KEY);
if (savedServices) {
const services = JSON.parse(savedServices);
$('select[name="service_id[]"]').val(services).trigger('change');
}
var savedPage = localStorage.getItem(key);
var displayStart = 0;
if (savedPage !== null) {
displayStart = parseInt(savedPage) * pageLength;
}
grid.init({
src: $("#table"),
onSuccess: function (grid) {
// execute some code after table records loaded
},
onError: function (grid) {
// execute some code on network or other general error
},
onDataLoad: function(grid) {
// execute some code on ajax data load
},
loadingMessage: 'Loading...',
dataTable: { // here you can define a typical datatable settings from http://datatables.net/usage/options
// Uncomment below line("dom" parameter) to fix the dropdown overflow issue in the datatable cells. The default datatable layout
// setup uses scrollable div(table-scrollable) with overflow:auto to enable vertical scroll(see: assets/global/scripts/datatable.js).
// So when dropdowns used the scrollable div should be removed.
//"dom": "<'row'<'col-md-8 col-sm-12'pli><'col-md-4 col-sm-12'<'table-group-actions pull-right'>>r>t<'row'<'col-md-8 col-sm-12'pli><'col-md-4 col-sm-12'>>",
sDom: '"top"i',
"bStateSave": false, // save datatable state(pagination, sort, etc) in cookie.
columns: [
{ data: 'id', name: 'id' },
{ data: 'name', name: 'name' },
{
data: 'latest_int_note',
name: 'latest_int_note',
render: function (data, type, row) {
if (data && data.trim() !== '') {
return data
} else {
return '';
}
},
orderable: false,
searchable: false,
},
{ data: 'is_subscribed', name: 'subscription' },
{ data: 'is_doc_uploaded', name: 'service_document' },
{ data: 'is_doc_verified', name: 'service_document_verified' },
{ data: 'status', name: 'status' },
{ data: 'actions', name: 'actions' },
],
"lengthMenu": [
[10, 20, 50],
[10, 20, 50] // change per page values here
],
"pageLength": pageLength, // default record count per page
"displayStart": displayStart, // set the initial page index
"ajax": {
"url": '<?php echo route('admin.users.providers.data'); ?>', // ajax source
"data": function (d) {
d.sort_by = $('#rr-sortby').val();
d.service_id = $('select[name="service_id[]"]').val();
},
"beforeSend": function(){
$("#table ").find('tbody').html("<tr><td align='center' colspan='10' class='bold'><i class='fa fa-spinner fa-spin'></i> <?php echo e(trans('general.action_is_loading')); ?></td></tr>");
},
},
"bSort": false,
},
});
$('#rr-sortby').on('change', function () {
const value = $(this).val();
// Save to storage
localStorage.setItem(SORT_STORAGE_KEY, value);
// Reload table with new filter
$('#table').DataTable().ajax.reload(null, false);
});
$('select[name="service_id[]"]').on('change', function () {
const services = $(this).val() || [];
// Save to storage
localStorage.setItem(SERVICE_STORAGE_KEY, JSON.stringify(services));
// Reload datatable
$('#table').DataTable().ajax.reload(null, false);
});
// $('#table').on('page.dt', function () {
// var table = $('#table').DataTable();
// localStorage.setItem('therapist_table_page', table.page());
// })
$('#table').on('page.dt', function () {
var table = $('#table').DataTable();
// Save current page index along with search/filter state
var searchName = $('input[name="search_name"]').val() || '';
var searchPhone = $('input[name="search_phone"]').val() || '';
var key = 'therapist_table_page_' + searchName + '_' + searchPhone;
localStorage.setItem(key, table.page());
});
$( "#table tbody" ).sortable({
axis: 'y',
update: function (event, ui) {
var TableRows = $(this).find('tr');
var thIds = [];
$i=0;
$.each(TableRows, function (key,item) {
var thId = $(this).find('.idTh').val();
thIds[$i] = thId;
$i++;
})
console.log(thIds);
$.ajax({
data: {therapists:thIds},
type: 'POST',
url: "<?php echo e(route('admin.users.providers.sort')); ?>",
cache: false,
beforeSend: function () {},
dataType: "json",
}).done(function () {
$('#table').DataTable().ajax.reload();
});
}
}
);
$( "#table tbody" ).disableSelection();
});
function gridInit() {
}
// Handle click on info icon to navigate
$(document).on('click', '.info-icon-user-list', function() {
var id = $(this).data('id');
window.location.href = '/admin/users/therapists/internal-notes/' + id;
});
</script>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('admin.layouts.master', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /home/tradze/public_html/app/Modules/Users/Resources/Views/admin/therapists_index.blade.php ENDPATH**/ ?>