| Path : /var/www/html/backup/jewelry-pos/storage/framework/views/ |
|
B-Con CMD Config cPanel C-Rdp D-Log Info Jump Mass Ransom Symlink vHost Zone-H |
| Current File : //var/www/html/backup/jewelry-pos/storage/framework/views/c115f9b0c82c3bc1216ccecf7ecfc787.php |
<?php $__env->startSection('content'); ?>
<div class="col-lg-12">
<div class="card-body shadow-1">
<div class="row mt-2 mr-1">
<div class="col-xs-8 col-md-8 col-sm-8 col-xl-8 margin-tb">
<div class="row" style="width: 90%;">
<form method="GET" action="<?php echo e(route('reports.product-qty-history')); ?>" id="search-form" onsubmit="" style="display:flex;width: 100%;">
<div class="input-group mr-2 ml-2" style="width: 50%;">
<input type="text" class="form-control rounded-0"
placeholder="<?php echo e(__('message.select')); ?>" id="datepicker" name="date" readonly>
<input type="hidden" name="paginate" value="<?php echo e($paginate); ?>">
<input type="hidden" name="for_sale" value="<?php echo e($for_sale); ?>">
<div class="input-group-append">
<span class="input-group-text fs-xl">
<i class="fal fa-calendar text-info "></i>
</span>
</div>
</div>
<div class="input-group mr-2" style="width: 30%;">
<input type="text" class="form-control rounded-0"
placeholder="<?php echo e(__('message.search')); ?> ..." value="<?php echo e($q); ?>" name="q" id="search">
<div class="input-group-append">
<button type="submit" class="input-group-text fs-xl ">
<i class="fal fa-search text-success"></i>
</button>
</div>
</div>
<select onchange="this.form.submit()" name="in_out" id="in_out" class="form-control mr-2 ml-4" style="width: 20%;">
<option value="0" <?php if($in_out == 0): ?> selected <?php endif; ?>><?php echo e(__('message.all')); ?></option>
<option value="1" <?php if($in_out == 1): ?> selected <?php endif; ?>><?php echo e(__('message.in')); ?></option>
<option value="-1" <?php if($in_out == -1): ?> selected <?php endif; ?>><?php echo e(__('message.out')); ?></option>
</select>
</form>
</div>
</div>
<div class="col-md-4 col-xs-4 col-sm-4 col-xl-4 margin-tb mb-4">
<div class="row">
<div class="col-lg-8 margin-tb" style="display: flex;justify-content: start;align-items: center">
<a href="<?php echo e(route('reports.product-qty-history-print')); ?>?for_sale=<?php echo e($for_sale); ?>&start_date=<?php echo e($start_date); ?>&&end_date=<?php echo e($end_date); ?>&paginate=<?php echo e($paginate); ?>&in_out=<?php echo e($in_out); ?>&q=<?php echo e($q); ?>"
class="btn btn-info bg-info-800 float-right rounded-0" id="printBtn"
title="<?php echo e(__('message.print')); ?>" name="">
<i class="fal fa-print"></i>
<?php echo e(__('message.print')); ?>
</a>
<a href="<?php echo e(route('reports.product-qty-history-export')); ?>?for_sale=<?php echo e($for_sale); ?>&start_date=<?php echo e($start_date); ?>&end_date=<?php echo e($end_date); ?>&paginate=<?php echo e($paginate); ?>&in_out=<?php echo e($in_out); ?>&q=<?php echo e($q); ?>" class="btn btn-success bg-success-800 search-date ml-2" id="download-button" onclick="return clickdownload()">
<i class="fal fa-download"></i>
<?php echo e(__('message.export excel')); ?>
</a>
</div>
<div class="col-lg-4" style="display: flex;justify-content: end;align-items: center">
<a class="btn btn-sm btn-primary" href="<?php echo e(route('reports.product-qty-history-option')); ?>">
<i class="fal fa-arrow-left" aria-hidden="true"></i>
<?php echo e(__('message.go back')); ?>
</a>
</div>
</div>
</div>
</div>
<div class="panel-container show">
<div class="d-flex flex-column h-100">
<div class="h-auto">
<table id="example" class="table table-bordered table-hover table-striped w-100">
<thead class="bg-fusion-400 text-center">
<tr>
<th>#</th>
<th></th>
<th><?php echo e(__('message.grn')); ?></th>
<th><?php echo e(__('message.product category')); ?></th>
<th class="text-center"><?php echo e(__('message.product name')); ?></th>
<th class="text-center"><?php echo e(__('message.selling cost')); ?></th>
<?php if($for_sale == 0): ?>
<th><?php echo e(__('message.weight')); ?></th>
<th class="text-center"><?php echo e(__('message.weight before transaction')); ?></th>
<th class="text-center"><?php echo e(__('message.weight after transaction')); ?></th>
<?php else: ?>
<th><?php echo e(__('message.qty')); ?></th>
<th class="text-center"><?php echo e(__('message.qty before transaction')); ?></th>
<th class="text-center"><?php echo e(__('message.qty after transaction')); ?></th>
<?php endif; ?>
<th class="text-center"><?php echo e(__('message.note')); ?></th>
<th class="text-center"><?php echo e(__('message.user')); ?></th>
<th class="text-center"><?php echo e(__('message.created at')); ?></th>
<th class="text-center"><?php echo e(__('message.action')); ?></th>
</tr>
</thead>
<tbody>
<?php $__currentLoopData = $productQtyHistories; $__env->addLoop($__currentLoopData); foreach($__currentLoopData as $index => $productQtyHistory): $__env->incrementLoopIndices(); $loop = $__env->getLastLoop(); ?>
<tr class="text-center <?php if($productQtyHistory->qty<0||$productQtyHistory->weight<0): ?> inactive <?php endif; ?>">
<td>
<?php echo e($index+1); ?>
</td>
<td>
<?php if($for_sale==0): ?><input type="checkbox" class="form-check past_sale_checkbox" name="past_sale_id[]" value="<?php echo e($productQtyHistory->id); ?>"> <?php endif; ?>
</td>
<td>
<?php echo e($productQtyHistory->grn); ?>
</td>
<td>
<?php echo e($productQtyHistory->product->productCategory->name??''); ?>
</td>
<td>
<?php echo e($productQtyHistory->product->name??''); ?>
</td>
<td class="credit">
<?php echo e(number_format($productQtyHistory->product_cost??0 , 2)); ?> <?php echo e($currency_->currency_symbol); ?>
</td>
<?php if($for_sale == 0): ?>
<td class="credit">
<?php echo e(abs($productQtyHistory->weight)); ?>
</td>
<td class="credit transparent">
<?php echo e(number_format($productQtyHistory->weight_before_transaction , 2)); ?>
</td>
<td class="credit transparent">
<?php echo e(number_format($productQtyHistory->weight_after_transaction , 2)); ?>
</td>
<?php else: ?>
<td class="credit">
<?php echo e(abs($productQtyHistory->qty)); ?>
</td>
<td class="credit transparent">
<?php echo e(number_format($productQtyHistory->qty_before_transaction , 2)); ?>
</td>
<td class="credit transparent">
<?php echo e(number_format($productQtyHistory->qty_after_transaction , 2)); ?>
</td>
<?php endif; ?>
<td>
<?php echo e($productQtyHistory->note??''); ?>
</td>
<td>
<a href="<?php echo e(route('users.show' , $productQtyHistory->user_id)); ?>" class="text-dark">
<?php echo e($productQtyHistory->user->name??''); ?>
</a>
</td>
<td>
<?php echo e(date('d-m-Y H-i-s' , strtotime($productQtyHistory->created_at))); ?>
</td>
<td>
<?php
$ago = \Carbon\Carbon::parse($productQtyHistory->created_at)->diffForHumans();
$currentDate = \Carbon\Carbon::now();
$created_at = \Carbon\Carbon::parse($productQtyHistory->created_at)->addDays(1);
?>
<?php if($created_at->gt($currentDate)): ?>
<?php if (app(\Illuminate\Contracts\Auth\Access\Gate::class)->check('product-delete')): ?>
<form method="POST" action="<?php echo e(route('reports.product-qty-history-destroy' , $productQtyHistory->id)); ?>?start_date=<?php echo e($start_date); ?>&&end_date=<?php echo e($end_date); ?>&paginate=<?php echo e($paginate); ?>&in_out=<?php echo e($in_out); ?>&q=<?php echo e($q); ?>" style="display:inline">
<input name="_method" type="hidden" value="DELETE">
<?php echo e(csrf_field()); ?>
<button type="button" class="btn btn-xs btn-danger btn-delete">
<i class="fal fa-trash" style="color: #FFF;"></i>
</button>
</form>
<br>
<?php endif; ?>
<?php else: ?>
<span class="badge badge-pill badge-danger" title="<?php echo e($productQtyHistory->created_at); ?>" style="font-size: 10px">
<?php echo e(Carbon\Carbon::parse($productQtyHistory->created_at)->diffForHumans()); ?>
</span>
<?php endif; ?>
</td>
</tr>
<?php endforeach; $__env->popLoop(); $loop = $__env->getLastLoop(); ?>
</tbody>
</table>
<!-- datatable end -->
</div>
</div>
</div>
<!-- Pagination bootstrap-->
<?php if($productQtyHistories->hasPages()): ?>
<div class="d-flex m-2 p-2" style="justify-content: space-between;align-items: start;width: 20%">
<select id="paginate" class="form-select text-center rounded mr-2 mt-1" aria-label="Default select example" style="width: 90px;font-size: 12px;border: 1px solid rebeccapurple">
<option selected hidden="hidden"><?php echo e($paginate); ?></option>
<option value="25">25</option>
<option value="50">50</option>
<option value="100">100</option>
<option value="250">250</option>
<option value="500">500</option>
<option value="1000">1000</option>
</select>
<div class="">
<?php echo e($productQtyHistories->appends($_GET)->links()); ?>
</div>
</div>
<?php endif; ?>
</div>
</div>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('scripts'); ?>
<?php echo $__env->make('app.datepicker-js-config', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?>
<script>
document.getElementById('printBtn').addEventListener('click', function(e) {
e.preventDefault();
const selectedIds = Array.from(document.querySelectorAll('.past_sale_checkbox:checked'))
.map(checkbox => checkbox.value);
const baseUrl = "<?php echo e(route('reports.product-qty-history-print')); ?>";
const startDate = "<?php echo e($start_date); ?>";
const endDate = "<?php echo e($end_date); ?>";
const search = "<?php echo e($q); ?>";
const fixed_price = "<?php echo e($paginate); ?>";
const for_sale = "<?php echo e($for_sale); ?>";
const inOut = "<?php echo e($in_out); ?>";
const params = new URLSearchParams({
start_date: startDate,
end_date: endDate,
q: search,
fixed_price: fixed_price,
for_sale: for_sale,
in_out: inOut,
past_sale_ids: selectedIds.join(',')
});
// const finalUrl = `${baseUrl}?${params.toString()}`;
// Open print page in a new tab or same page
// window.open(finalUrl, '_blank');
window.location.href = `${baseUrl}?${params.toString()}`;
});
</script>
<script>
// date earchform strt_date to EndDate
$(document).ready(function() {
$(".ranges > ul > li").click(function() {
setTimeout(function() {
$('#search-form').submit();
}, 100);
});
$("#datepicker").on("change.dp" , function (){
$("#search-form").submit();
});
});
// date
var runDatePicker = function() {
// enable clear button
$('#datepicker').datepicker({
todayBtn: "linked",
clearBtn: true,
todayHighlight: true,
templates: controls
});
}
// end date
</script>
<script>
$('#btnBrow').click(function () {
$('#browFile').click();
});
$(document).ready(function() {
$("#js-nav-menu").removeClass('active');
$("#js-nav-menu li ul li").removeClass('active');
$("#menu_report_list").addClass('active open');
$("#collapse_report").addClass('collapse in');
$("#menu_expense_product_qty_history").addClass('active');
})
</script>
<?php $__env->stopSection(); ?>
<?php $__env->startSection('meta'); ?>
<title><?php echo e(__('message.product qty history')); ?> - <?php echo e($settings_->shop_name); ?></title>
<?php $__env->stopSection(); ?>
<?php echo $__env->make('layouts.admin-main', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /var/www/html/jewelry-pos/resources/views/report-product-transactions/index.blade.php ENDPATH**/ ?>