mercredi 17 mai 2017

Laravel 5.1 helping class is not working in my laravel application

My helping class code is here

use App\ReceivingItem;

class ReportReceivingsDetailed {

public static function receiving_detailed($receiving_id)
{
    $receivingitems = ReceivingItem::where('receiving_id', $receiving_id)->get();
    return $receivingitems;
}

My report page code

@extends('app')

@section('content')
<div class="container">
    <div class="row">
        <div class="col-md-10 col-md-offset-1">
            <div class="panel panel-default">
                <div class="panel-heading"> - </div>

                <div class="panel-body">
<div class="well well-sm">: </div>
<table class="table table-striped table-bordered">
    <thead>
        <tr>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td>&nbsp;</td>
        </tr>
    </thead>
    <tbody>
    @foreach($receivingReport as $value)
        <tr>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td></td>
            <td>
                <a class="btn btn-small btn-info" data-toggle="collapse" href="#detailedReceivings" aria-expanded="false" aria-controls="detailedReceivings"></a>
            </td>
        </tr>

            <tr class="collapse" id="detailedReceivings">
                <td colspan="9">
                    <table class="table">
                        <tr>
                            <td></td>
                            <td></td>
                            <td></td>
                            <td></td>
                        </tr>
                        @foreach(ReportReceivingsDetailed::receiving_detailed($value->id) as $receiving_detailed)
                        <tr>
                            <td></td>
                            <td></td>
                            <td></td>
                            <td></td>
                        </tr>
                        @endforeach
                    </table>
                </td>
            </tr>

    @endforeach
    </tbody>
</table>
                </div>
            </div>
        </div>
    </div>
</div>
@endsection

But it is showing the result enter image description here

Please help me to solve it. The application is in laravel 5.1



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire