index.blade.php 1.84 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11
@extends('adminlte::layouts.app')

@section('htmlheader_title')
	{{ trans('adminlte_lang::message.home') }}
@endsection

@section('contentheader_title')
	<center>Beli Barang</center>
@endsection

@section('main-content')
Yonatan Parapat committed
12 13 14 15 16 17 18 19 20
    <form action="{{url('/list')}}">
                    <div class="form-group">
                    <label style="margin: 20px 20px 0;font-size: 15px">Search by Username</label>
                    <input type="text" name="search" placeholder="Nama Barang" id="search" class="form-control" style="font-size: 15px;color:white;background-color:rgba(0,0,0,0.4)"/>
                    </div>
                    <button type="submit" id="button-filter" class="btn btn-danger pull-right" style="margin-right: 20px">
                    <i class="fa fa-search"></i> Search
                    </button>
                </form>
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
<table class="table table-striped">
    <thead>
    	<tr>
            <th>Nama Barang</th>
            <th>Stock</th>
            <th>Harga</th>
            <th>Kategori</th>
            <th>Gambar</th>
        	<th>Action</th>
        </tr>
    </thead>
                            
        <tbody>
            @foreach($barangs as $barang)
	            <tr>
Yonatan Parapat committed
36 37
	                <td>{{$barang->nama_barang}}</td>
	                <td>{{$barang->stock}}</td>
38 39
	                <td>{{$barang->harga}}</td>
	                <td>{{$barang->kategori}}</td>
Yonatan Parapat committed
40
	                <td><img src="{{ asset('image/'. $barang->gambar) }}" style="height: 50px; width: 50px; "></td>
41
	                <td>
Yonatan Parapat committed
42
						<a href="{{ url('/createPembelian', $barang->id) }}" type="submit" button type="button" class="btn btn-warning">Beli</a>
43 44 45 46 47
						<!-- <a href="{{ url('/delete', $barang->id) }}"  <onclick="return confirm('Yakin mau hapus data ini sob?')" class="btn btn-warning">Delete</a> -->
	            	</tr>
    		@endforeach
    </tbody>
</table>
48
@endsection