| Server IP : 103.161.17.216 / Your IP : 216.73.216.1 Web Server : nginx/1.18.0 System : Linux tipsysaigoncharming 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64 User : www-data ( 33) PHP Version : 7.4.3-4ubuntu2.29 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /var/www/thammyviendd.com/resources/views/admin/product/ |
Upload File : |
@extends('admin_layout')
@section('admin_content')
<div class="table-agile-info">
<div class="panel panel-default">
<div class="panel-heading">
Liệt kê sản phẩm
<a class="btn btn-success" href="{{URL::to('/add-product')}}"> Thêm sản phẩm</a>
</div>
<div class="row w3-res-tb">
<div class="col-sm-5 m-b-xs">
<select class="input-sm form-control w-sm inline v-middle">
<option value="0">Bulk action</option>
<option value="1">Delete selected</option>
<option value="2">Bulk edit</option>
<option value="3">Export</option>
</select>
<button class="btn btn-sm btn-default">Apply</button>
</div>
<div class="col-sm-4">
</div>
<div class="col-sm-3">
<div class="input-group">
<input type="text" class="input-sm form-control" placeholder="Search">
<span class="input-group-btn">
<button class="btn btn-sm btn-default" type="button">Go!</button>
</span>
</div>
</div>
</div>
<div class="table-responsive">
<?php
$message = Session::get('message');if ($message) {
echo '<span class="text-alert">',$message,'</span>';
Session::put('message',null);
// code...
}
?>
<table class="table table-striped b-t b-light">
<thead>
<tr>
<th style="width:20px;">
<label class="i-checks m-b-none">
<input type="checkbox"><i></i>
</label>
</th>
<th>Tên sản phẩm </th>
<th>Giá sản phẩm </th>
<th> Thuộc tính</th>
<th> Thư viện Ảnh </th>
<th> Hình Ảnh </th>
<th>Quốc gia</th>
<th>Danh mục SP </th>
<th>Thương Hiệu </th>
<th> trạng thái </th>
<th> SP Hot</th>
<th> SP đặt biệt</th>
<th> SP ưa chượng</th>
<th style="width:10px;"></th>
</tr>
</thead>
<tbody>
@foreach($all_product as $key => $pro)
<tr>
<td><label class="i-checks m-b-none"><input type="checkbox" name="post[]"><i></i></label></td>
<td>{{$pro -> product_name}}</td>
<td>{{$pro -> product_price}}</td>
<td><a href="{{url('add-attr/'.$pro->product_id)}}">Thêm thuộc tính </td>
<td><a href="{{url('add-gallery/'.$pro->product_id)}}">Thêm Ảnh </td>
<td><img src="public/uploads/product/{{$pro -> product_image}}" height="100" with="150"></td>
<td>{{$pro -> country_name}}</td>
<td>{{$pro -> category_name}}</td>
<td>{{$pro -> brand_name}}</td>
<td><span class="text-ellipsis">
{{-- TRẠNG THÁI --}}
<?php
if($pro ->product_status==0){
?>
<a href="{{URL::to('/unactive-product/'.$pro->product_id)}}"> <span class="fa-thumb-styling fa fa-thumbs-down"> </span></a>
<?php
}
else {
?>
<a href="{{URL::to('/active-product/'.$pro->product_id)}}"> <span class="fa-thumb-styling fa fa-thumbs-up"> </span></a>
<?php
}
?>
</span></td>
{{-- SO HOT --}}
<td><span class="text-ellipsis">
<?php
if($pro ->product_hot==0){
?>
<a href="{{URL::to('/unactive-hot-product/'.$pro->product_id)}}"> <span class="fa-thumb-styling fa fa-thumbs-down"> </span></a>
<?php
}
else{
?>
<a href="{{URL::to('/active-hot-product/'.$pro->product_id)}}"> <span class="fa-thumb-styling fa fa-thumbs-up"> </span></a>
<?php
}
?>
</span></td>
{{-- ĐẶT BIỆT --}}
<td><span class="text-ellipsis">
<?php
if($pro ->product_spe==0){
?>
<a href="{{URL::to('/unactive-spe-product/'.$pro->product_id)}}"> <span class="fa-thumb-styling fa fa-thumbs-down"> </span></a>
<?php
}
else {
?>
<a href="{{URL::to('/active-spe-product/'.$pro->product_id)}}"> <span class="fa-thumb-styling fa fa-thumbs-up"> </span></a>
<?php
}
?>
</span></td>
{{-- ƯA CHUỘNG --}}
<td><span class="text-ellipsis">
<?php
if($pro ->product_like==0){
?>
<a href="{{URL::to('/unactive-like-product/'.$pro->product_id)}}"> <span class="fa-thumb-styling fa fa-thumbs-down"> </span></a>
<?php
}
else {
?>
<a href="{{URL::to('/active-like-product/'.$pro->product_id)}}"> <span class="fa-thumb-styling fa fa-thumbs-up"> </span></a>
<?php
}
?>
</span></td>
<td>
<a href="{{URL::to('/edit-product/'.$pro->product_id)}}" class="active styling edit" ui-toggle-class=""><i class="fa fa-pencil-square-o"></i></a>
<a onclick="return confirm('bạn có chắc muốn xóa không?')" href="{{URL::to('/delete-product/'.$pro->product_id)}}" class="active" ui-toggle-class=""> <i class="fa fa-times text-danger text"></i></a>
</td>
</tr>
@endforeach
</tbody>
</table>
</div>
<span style="float: right;">{!!$all_product->links('pagination::bootstrap-4') !!}</span>
{{--< footer class="panel-footer">
<div class="row">
<div class="col-sm-5 text-center">
<small class="text-muted inline m-t-sm m-b-sm">showing 20-30 of 50 items</small>
</div>
<div class="col-sm-7 text-right text-center-xs">
<ul class="pagination pagination-sm m-t-none m-b-none">
<li><a href=""><i class="fa fa-chevron-left"></i></a></li>
<li><a href="">1</a></li>
<li><a href="">2</a></li>
<li><a href="">3</a></li>
<li><a href="">4</a></li>
<li><a href=""><i class="fa fa-chevron-right"></i></a></li>
</ul>
</div>
</div> --}}
<tr>
<br>
<form action="{{url('/importproduct-csv')}}" method="POST" enctype="multipart/form-data">
@csrf
<input type="file" name="file" accept=".xlsx"><br>
<input type="submit" value="Import CSV" name="import_csv" class="btn btn-warning">
</form>
</br>
<br>
<form action="{{url('/exportproduct-csv')}}" method="POST">
@csrf
<input type="submit" value="Export CSV" name="export_csv" class="btn btn-success">
</form>
</tr>
</br>
</footer>
</div>
</div>
</section>
@endsection