| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426 |
- @extends('customer-service.layout.master')
- @section('ptitle','Customer Service')
- @section('page_title', 'Customers & Subscribers')
- @section('subpage', 'Graph & Summary Report')
- @section('img_profile', asset($user->StaffDetail->user_pic))
- @section('login_name', $user->StaffDetail->name )
- @section('last_login', $user->last_login_at )
-
- @section('content')
- <style>
- .ui-tabs .ui-tabs-nav li a { color: #636363 !important; }
- .ui-tabs .ui-tabs-nav li a:hover { color: #212121 !important; }
- .ui-tabs .ui-tabs-nav li.ui-tabs-active a { color: #2E6B9B !important; }
- .ui-widget-content a { color: #fff; }
- </style>
-
- <!-- <div class="widget grid12">
- <div class="whead"><h6>Search/Filter Submmition Form</h6></div>
- <div id="dyn1" class="responsive shownpars cuss">
- <div class="grid4">
- <div class="formRow">
- <div class="grid2"> </div>
- <div class="grid4"><label><b>Primary Number<small style="color: red"> * </small>: </b></label><input type="text" name="phone1" id="phone1" required=""></div>
- <div class="grid4"><label><b>Secondary Number : </b></label><input type="text" name="phone2" id="phone2"></div>
- <div class="grid2"> </div>
- </div>
- </div>
- <div class="grid4">
- <div class="formRow">
- <div class="grid2"> </div>
- <div class="grid4"><label><b>Primary Number<small style="color: red"> * </small>: </b></label><input type="text" name="phone1" id="phone1" required=""></div>
- <div class="grid4"><label><b>Secondary Number : </b></label><input type="text" name="phone2" id="phone2"></div>
- <div class="grid2"> </div>
- </div>
- </div>
- <div class="grid4">
- <div class="formRow">
- <div class="grid2"> </div>
- <div class="grid4"><label><b>Primary Number<small style="color: red"> * </small>: </b></label><input type="text" name="phone1" id="phone1" required=""></div>
- <div class="grid4"><label><b>Secondary Number : </b></label><input type="text" name="phone2" id="phone2"></div>
- <div class="grid2"> </div>
- </div>
- </div>
- </div>
- </div> -->
-
- <!-- Table dealer -->
- <div class="widget leftTabs tableTabs">
- <div class="whead"><h6>Subscriber's List ( Resident & Business )</h6></div>
- <div class="cuss shownpars">
- <div class="tabs">
- <ul>
- <li><a href="#recs">Rectifications <small style="color:#B35D7E">( {{ $rec }} )</small></a></li>
- <li><a href="#subs">Subscribers <small style="color:#B35D7E">( {{ $re }} )</small></a></li>
- <li><a href="#buss">Business <small style="color:#B35D7E">( {{ $bu }} )</small></a></li>
- </ul>
-
- <div id="recs">
- <table id="rectification" cellpadding="0" cellspacing="0" border="0" width="100%" class="dTable tMedia">
- <thead>
- <tr>
- <th>#</th>
- <th>Submittion</th>
- <th>Type App.</th>
- <th>Cust.Name</th>
- <th>Contact No.</th>
- <th>Unit No.</th>
- <th>Building</th>
- <th>Street</th>
- <th>Postcode</th>
- <th>City</th>
- <th width="30">PDF</th>
- <th width="30">W/O</th>
- <th width="30">Docket</th>
- </tr>
- </thead>
- </table>
- </div>
- <div id="subs">
- <table id="residential" cellpadding="0" cellspacing="0" border="0" width="100%" class="dTable tMedia">
- <thead>
- <tr>
- <th>#</th>
- <th>Submittion</th>
- <th>Type App.</th>
- <th>Cust.Name</th>
- <th>Contact No.</th>
- <th>Unit No.</th>
- <th>Building</th>
- <th>Street</th>
- <th>Postcode</th>
- <th>City</th>
- <th width="30">PDF</th>
- <th width="30">W/O</th>
- <th width="30">Docket</th>
- </tr>
- </thead>
- </table>
- </div>
- <div id="buss">
- <table id="business" cellpadding="0" cellspacing="0" border="0" width="100%" class="dTable tMedia">
- <thead>
- <tr>
- <th>#</th>
- <th>Submittion</th>
- <th>Type App.</th>
- <th>Cust.Name</th>
- <th>Contact No.</th>
- <th>Unit No.</th>
- <th>Building</th>
- <th>Street</th>
- <th>Postcode</th>
- <th>City</th>
- <th width="30">PDF</th>
- <th width="30">W/O</th>
- <th width="30">Docket</th>
- </tr>
- </thead>
- </table>
- </div>
- </div>
- </div>
- </div>
- @endsection
-
- @section('external_js')
- <script>
- $(document).ready(function(){
-
- var origin = window.location.origin;
-
- //===== Dynamic table toolbars =====//
-
- $('#dyn1 .tOptions').click(function () {
- $('#dyn .tablePars').slideToggle(200);
- });
-
- $('.tOptions').click(function () {
- $(this).toggleClass("act");
- });
-
- //======= Filter data table ========//
-
- var table1 = $('#rectification').DataTable({
- "bJQueryUI": false,
- "bAutoWidth": true,
- "bSort": false,
- "sPaginationType": "full_numbers",
- "sDom": '<"tablePars"fl>t<"tableFooter"ip>',
- "oLanguage": {
- "sLengthMenu": "<span class='showentries'>Show entries:</span> _MENU_"
- },
- "ordering": false,
- "serverSide": true,
- "processing": true,
- "ajax": "{{ url('/customer-service/get-all-rectification/null/null/null') }}",
- "columns": [
- { "data": "formT","name": "formT"},
- { "data": "submittion","name": "submittion"},
- { "data": "type","name": "type"},
- { "data": "name","name": "name"},
- { "data": "phone","name": "phone"},
- { "data": "unit","name": "unit"},
- { "data": "building","name": "building"},
- { "data": "street","name": "street"},
- { "data": "postcode", "name": "postcode"},
- { "data": "city","name": "city"},
- { "data": "action1","name": "action1"},
- { "data": "action2","name": "action2"},
- { "data": "action3","name": "action3"},
- ],
- "columnDefs": [
- {
- "render": function ( data, type, row ) {
- if (data.indexOf("New/") >= 0) {
- var split = data.split('/');
- return '<small class="label label-warning">'+split[0]+'</small> '+split[1];
- }else {
- return data;
- }
- },
- "targets": 0
- },
- {
- "render": function ( data, type, row ) {
- if (data.indexOf("D/") >= 0) {
- var split = data.split('/');
- return '<small class="label label-purple">'+split[0]+'</small> '+split[1];
- }else {
- return data;
- }
- },
- "targets": 3
- },
- {
- "render": function ( data, type, row ) {
- if (data.indexOf("R/") >= 0) {
- var split = data.split('/');
- var link = "{{ url('/customer-service/residential/generate-pdf') }}"+"/"+split[1];
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bPurple tipS" title="View Subscribers"><span class="iconb" data-icon=""></span></a>';
- }else if (data.indexOf("B/") >= 0){
- var split = data.split('/');
- var link = "{{ url('/customer-service/business/generate-pdf') }}"+"/"+split[1];
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bPurple tipS" title="View Subscribers"><span class="iconb" data-icon=""></span></a>';
- }
- },
- "targets": 10
- },
- {
- "render": function ( data, type, row ) {
- if (data != 'null') {
- var link = "{{ url('/customer-service/work-order/generate-pdf') }}"+"/"+data;
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bGold tipS" title="View W/O"><span class="iconb" data-icon=""></span></a>';
- }else {
- return '';
- }
- },
- "targets": 11
- },
- {
- "render": function ( data, type, row ) {
- if (data != 'null') {
- var link = "{{ url('/customer-service/docket/generate-pdf') }}"+"/"+data;
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bGreen tipS" title="View Docket PDF"><span class="iconb" data-icon=""></span></a>';
- }else {
- return '';
- }
- },
- "targets": 12
- }
- ],
- });
-
- var table2 = $('#residential').DataTable({
- "bJQueryUI": false,
- "bAutoWidth": true,
- "bSort": false,
- "sPaginationType": "full_numbers",
- "sDom": '<"tablePars"fl>t<"tableFooter"ip>',
- "oLanguage": {
- "sLengthMenu": "<span class='showentries'>Show entries:</span> _MENU_"
- },
- "ordering": false,
- "serverSide": true,
- "processing": true,
- "ajax": "{{ url('/customer-service/get-all-residential/null/null/null') }}",
- "columns": [
- { "data": "formT","name": "formT"},
- { "data": "submittion","name": "submittion"},
- { "data": "type","name": "type"},
- { "data": "name","name": "name"},
- { "data": "phone","name": "phone"},
- { "data": "unit","name": "unit"},
- { "data": "building","name": "building"},
- { "data": "street","name": "street"},
- { "data": "postcode", "name": "postcode"},
- { "data": "city","name": "city"},
- { "data": "action1","name": "action1"},
- { "data": "action2","name": "action2"},
- { "data": "action3","name": "action3"},
- ],
- "columnDefs": [
- {
- "render": function ( data, type, row ) {
- if (data.indexOf("New/") >= 0) {
- var split = data.split('/');
- return '<small class="label label-warning">'+split[0]+'</small> '+split[1];
- }else {
- return data;
- }
- },
- "targets": 0
- },
- {
- "render": function ( data, type, row ) {
- if (data.indexOf("D/") >= 0) {
- var split = data.split('/');
- return '<small class="label label-purple">'+split[0]+'</small> '+split[1];
- }else {
- return data;
- }
- },
- "targets": 3
- },
- {
- "render": function ( data, type, row ) {
- if (data.indexOf("R/") >= 0) {
- var split = data.split('/');
- var link = "{{ url('/customer-service/residential/generate-pdf') }}"+"/"+split[1];
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bPurple tipS" title="View Subscribers"><span class="iconb" data-icon=""></span></a>';
- }else if (data.indexOf("B/") >= 0){
- var link = "{{ url('/customer-service/business/generate-pdf') }}"+"/"+data;
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bPurple tipS" title="View Subscribers"><span class="iconb" data-icon=""></span></a>';
- }
- },
- "targets": 10
- },
- {
- "render": function ( data, type, row ) {
- if (data != 'null') {
- var link = "{{ url('/customer-service/work-order/generate-pdf') }}"+"/"+data;
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bGold tipS" title="View W/O"><span class="iconb" data-icon=""></span></a>';
- }else {
- return '';
- }
- },
- "targets": 11
- },
- {
- "render": function ( data, type, row ) {
- if (data != 'null') {
- var link = "{{ url('/customer-service/docket/generate-pdf') }}"+"/"+data;
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bGreen tipS" title="View Docket PDF"><span class="iconb" data-icon=""></span></a>';
- }else {
- return '';
- }
- },
- "targets": 12
- }
- ],
- });
-
- var table3 = $('#business').DataTable({
- "bJQueryUI": false,
- "bAutoWidth": true,
- "bSort": false,
- "sPaginationType": "full_numbers",
- "sDom": '<"tablePars"fl>t<"tableFooter"ip>',
- "oLanguage": {
- "sLengthMenu": "<span class='showentries'>Show entries:</span> _MENU_"
- },
- "ordering": false,
- "serverSide": true,
- "processing": true,
- "ajax": "{{ url('/customer-service/get-all-business/null/null/null') }}",
- "columns": [
- { "data": "formT","name": "formT"},
- { "data": "submittion","name": "submittion"},
- { "data": "type","name": "type"},
- { "data": "name","name": "name"},
- { "data": "phone","name": "phone"},
- { "data": "unit","name": "unit"},
- { "data": "building","name": "building"},
- { "data": "street","name": "street"},
- { "data": "postcode", "name": "postcode"},
- { "data": "city","name": "city"},
- { "data": "action1","name": "action1"},
- { "data": "action2","name": "action2"},
- { "data": "action3","name": "action3"},
- ],
- "columnDefs": [
- {
- "render": function ( data, type, row ) {
- if (data.indexOf("New/") >= 0) {
- var split = data.split('/');
- return '<small class="label label-warning">'+split[0]+'</small> '+split[1];
- }else {
- return data;
- }
- },
- "targets": 0
- },
- {
- "render": function ( data, type, row ) {
- if (data.indexOf("D/") >= 0) {
- var split = data.split('/');
- return '<small class="label label-purple">'+split[0]+'</small> '+split[1];
- }else {
- return data;
- }
- },
- "targets": 3
- },
- {
- "render": function ( data, type, row ) {
- if (data.indexOf("R/") >= 0) {
- var split = data.split('/');
- var link = "{{ url('/customer-service/residential/generate-pdf') }}"+"/"+split[1];
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bPurple tipS" title="View Subscribers"><span class="iconb" data-icon=""></span></a>';
- }else if (data.indexOf("B/") >= 0){
- var split = data.split('/');
- var link = "{{ url('/customer-service/business/generate-pdf') }}"+"/"+split[1];
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bPurple tipS" title="View Subscribers"><span class="iconb" data-icon=""></span></a>';
- }
- },
- "targets": 10
- },
- {
- "render": function ( data, type, row ) {
- if (data != 'null') {
- var link = "{{ url('/customer-service/work-order/generate-pdf') }}"+"/"+data;
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bGold tipS" title="View W/O"><span class="iconb" data-icon=""></span></a>';
- }else {
- return '';
- }
- },
- "targets": 11
- },
- {
- "render": function ( data, type, row ) {
- if (data != 'null') {
- var link = "{{ url('/customer-service/docket/generate-pdf') }}"+"/"+data;
- return '<a href="'+link+'" target="_blank" class="tablectrl_medium bGreen tipS" title="View Docket PDF"><span class="iconb" data-icon=""></span></a>';
- }else {
- return '';
- }
- },
- "targets": 12
- }
- ],
- });
-
- /*** Filter ***/
- $('#fbtype,#fbbuilding,#fbdealer').on('change', function() {
- var link1 = "{{ url('/customer-service/get-all-rectification') }}" +"/"+$('#fbtype').val()+"/"+$('#fbbuilding').val()+"/"+$('#fbdealer').val();
- table1.ajax.url( link1 ).load();
-
- var link2 = "{{ url('/customer-service/get-all-residential') }}" +"/"+$('#fbtype').val()+"/"+$('#fbbuilding').val()+"/"+$('#fbdealer').val();
- table2.ajax.url( link2 ).load();
-
- var link3 = "{{ url('/customer-service/get-all-business') }}" +"/"+$('#fbtype').val()+"/"+$('#fbbuilding').val()+"/"+$('#fbdealer').val();
- table2.ajax.url( link3 ).load();
- });
- });
- </script>
- @endsection
|