One Hat Cyber Team
Your IP :
18.222.10.145
Server IP :
104.21.112.1
Server :
Linux agrigation-prod 5.15.0-67-generic #74-Ubuntu SMP Wed Feb 22 14:14:39 UTC 2023 x86_64
Server Software :
nginx/1.24.0
PHP Version :
7.4.33
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
home
/
forge
/
app.gftag.com
/
resources
/
views
/
stock
/
View File Name :
report.blade.php
@extends('layouts.master') @section('styles') <style> .edit,.delete{ border:none !important; margin:1em; } .edit{ color:#136BAF; } .delete{ color:red; } </style> <link rel="stylesheet" href="{{ asset('css/lib/datatables-net/datatables.min.css') }}"> <link rel="stylesheet" href="{{ asset('css/separate/vendor/datatables-net.min.css')}}"> <link rel="stylesheet" href="//code.jquery.com/ui/1.12.1/themes/base/jquery-ui.css"> @endsection @section('content') <div class="page-content"> <div class="container-fluid"> @if(session()->has('message')) <div class="alert alert-info alert-fill alert-close alert-dismissible fade in"> <strong>{{ session()->get('message') }}</strong> </div> @endif <div class="box-typical box-typical-padding"> <div class="filtering m-b"> <form action="{{route('stock-report')}}" method="GET"> <div class="row"> <div class="col-lg-3"> <fieldset class="form-group"> <label class="form-label semibold" for="exampleInputPassword1">Select Item</label> <select class="form-control" name="item" id="item"> <option value="All">All</option> @foreach($items as $item) <option value="{{$item->id}}" {{isset($request['item']) && $request['item'] == $item->id ? 'selected' : ''}}>{{$item->name}}</option> @endforeach </select> </fieldset> </div> <div class="col-lg-3"> <fieldset class="form-group"> <label class="form-label semibold" for="exampleInput">Start From</label> <div class='input-group date'> <input type="text" id="start_date" class="form-control" name="start_date" value="{{isset($request['start_date']) ? $request['start_date'] : ''}}"> <span class="input-group-addon"> <i class="font-icon font-icon-calend"></i> </span> </div> </fieldset> </div> <div class="col-lg-3"> <fieldset class="form-group"> <label class="form-label semibold" for="exampleInput">End From</label> <div class='input-group date'> <input type="text" id="end_date" class="form-control" name="end_date" value="{{isset($request['end_date']) ? $request['end_date'] : ''}}"> <span class="input-group-addon"> <i class="font-icon font-icon-calend"></i> </span> </div> </fieldset> </div> <div class="col-lg-3"> <div class="input-group-btn"> <label class="form-label semibold" for="exampleInput">Action</label> <button type="submit" id="fetch" class="btn btn-success mt-5 mr-5 p-x-1" style="margin-right: 5px;">Fetch</button> <a href="{{route('stock-report')}}" id="reset" class="btn btn-danger mt-5 mr-5 p-x-1">Reset</a> </div> </div> </div> <!--Select Columns Modal--> </form> </div> </div> <section class="card"> @if(count($stockItems) > 0) <button class="exportToExcel btn-sm btn-success m-y-1 m-r-2 float-right">Export</button> @endif <div class="card-block"> <table id="example" class="sales_report table2excel_with_colors display table table-striped table-bordered" cellspacing="0" width="100%"> <thead> <tr> <th>SL No</th> <th>Item</th> <th>Opening</th> <th>Adjustment(+)</th> <th>Adjustment(-)</th> <th>Purchase</th> <th>Sale</th> <th>Closing</th> </tr> </thead> <tbody> @php $i=1; @endphp @foreach($stockItems as $key => $stockItem) <tr> <td>{{$i}}</td> <td>{{$stockItem['name']}}</td> <td>{{$stockItem['opening']}}</td> <td>{{$stockItem['increase']}}</td> <td>{{$stockItem['decrease']}}</td> <td>{{$stockItem['transit']}}</td> <td>{{$stockItem['sale']}}</td> <td>{{($stockItem['opening'] + $stockItem['increase'] + $stockItem['transit']) - ($stockItem['decrease'] + $stockItem['sale'])}}</td> </tr> @php $i++; @endphp @endforeach </tbody> </table> </div> </section> </div> </div> @endsection @section('scripts') <script src="{{ asset('js/lib/datatables-net/datatables.min.js') }}"></script> <script src="{{ asset('js/jquery.table2excel.js') }}"></script> <script src="https://code.jquery.com/ui/1.11.1/jquery-ui.min.js"></script> <script> $( function() { $( "#start_date" ).datepicker({ dateFormat: "yy-mm-dd" }); $( "#end_date" ).datepicker({ dateFormat: "yy-mm-dd" }); }); </script> <script> $(function() { $(".exportToExcel").click(function(e){ var table = $('.sales_report'); if(table && table.length){ var preserveColors = (table.hasClass('table2excel_with_colors') ? true : false); $(table).table2excel({ exclude: ".noExl", name: "Excel Document Name", filename: "stock-report" + new Date().toISOString().replace(/[\-\:\.]/g, "") + ".xls", fileext: ".xls", exclude_img: true, exclude_links: true, exclude_inputs: true, preserveColors: preserveColors }); } }); }); </script> @endsection