@extends('backend.layouts.master') @section('section-title', 'OwnerShip') @section('page-title', 'OwnerShip List') @if (check_permission('ownership.store')) @section('action-button') Add Owner @endsection @endif @push('css') @endpush @section('content')
{{--
@php $custommer = App\Models\Customer::get(); @endphp
Reset Print
--}}
@forelse($ownerships as $data) @php $deposit = App\Models\BankTransaction::where('owner_id',$data->id)->where('pay_type','ownpay')->sum('amount'); $withdraw = App\Models\BankTransaction::where('owner_id',$data->id)->where('pay_type','ownwith')->sum('amount'); $balance = $deposit - $withdraw; @endphp {{-- edit modal --}} @csrf @method('PUT') {{-- delete modal --}} {{-- @csrf @method('DELETE') --}} @empty @endforelse
#SL Name Phone Email Deposit Withdraw Balance Action
{{ $loop->index + 1 }} {{ $data->name }} {{ $data->phone }} {{ ($data->email == Null)?'NULL':$data->email; }} {{ $deposit }} {{ $withdraw }} {{ $balance }}
No Data Available
{{-- Add Modal --}}
@csrf @foreach ($bank_accounts as $bank) @endforeach {{-- --}}
@endsection