API aktiviert / Anpassungen + User Übersicht Gutschriften Umsätze
This commit is contained in:
parent
c02fffd883
commit
a4c76d06fa
27 changed files with 500 additions and 110 deletions
|
|
@ -92,13 +92,7 @@
|
|||
</div>
|
||||
<div class="col-md-3 mb-3">
|
||||
<div class="text-muted small">Über Shop</div>
|
||||
@if($shopping_user->shopping_order)
|
||||
@if($shopping_user->shopping_order->user_shop->user->isActive() && $shopping_user->shopping_order->user_shop->user->isActiveShop())
|
||||
<a href="{{$shopping_user->shopping_order->user_shop->getSubdomain(false)}}" class="badge badge-success" target="_blank">{{$shopping_user->shopping_order->user_shop->getSubdomain(false)}}</a>
|
||||
@else
|
||||
<span class="badge badge-danger" target="_blank">{{$shopping_user->shopping_order->user_shop->getSubdomain(false)}}</span>
|
||||
@endif
|
||||
@endif
|
||||
#
|
||||
</div>
|
||||
<div class="col-md-3 mb-3">
|
||||
<div class="text-muted small">ist Vertriebspartner</div>
|
||||
|
|
|
|||
|
|
@ -25,8 +25,6 @@
|
|||
<input type="hidden" name="action" value="{{$data['action']}}">
|
||||
<input type="hidden" name="id" value="{{$data['id']}}">
|
||||
|
||||
|
||||
|
||||
<div class="form-row">
|
||||
<div class="form-group col-12">
|
||||
<label for="status" class="form-label">{{ __('Status') }}*</label>
|
||||
|
|
@ -36,6 +34,12 @@
|
|||
|
||||
<table class="table user-view-table m-0">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>Betrag:</td>
|
||||
<td>
|
||||
{{ $value->getFormattedTotal()." €" }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Zahlungsart:</td>
|
||||
<td>
|
||||
|
|
|
|||
|
|
@ -214,8 +214,6 @@
|
|||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="modal fade" id="modals-credit">
|
||||
<div class="modal-dialog">
|
||||
|
|
|
|||
|
|
@ -15,7 +15,6 @@
|
|||
@endforeach
|
||||
</select>
|
||||
{!! Form::close() !!}
|
||||
|
||||
</div>
|
||||
|
||||
<div class="card-datatable table-responsive pt-0">
|
||||
|
|
|
|||
|
|
@ -88,9 +88,6 @@
|
|||
oTable.draw();
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
|
||||
/*$('#filter_user_status').on('change', function(){
|
||||
$('#form_filter_user_status').submit();
|
||||
});*/
|
||||
|
|
|
|||
|
|
@ -22,11 +22,14 @@
|
|||
<li class="sidenav-item Request::is('user/payment/paycredit') ? ' active' : '' }} {{ Request::is('user/payment/paycredit') ? ' active' : '' }}">
|
||||
<a href="{{ route('user_payment_paycredit') }}" class="sidenav-link"><i class="sidenav-icon ion ion-ios-cash"></i><div>{{ __('navigation.paycredit') }}</div></a>
|
||||
</li>
|
||||
{{--
|
||||
<li class="sidenav-item Request::is('user/payment/credit') ? ' active' : '' }} {{ Request::is('user/payment/credit') ? ' active' : '' }}">
|
||||
<a href="{{ route('user_payment_credit') }}" class="sidenav-link"><i class="sidenav-icon ion ion-md-cash"></i><div>{{ __('navigation.commissions') }}</div></a>
|
||||
<li class="sidenav-item Request::is('user/payment/credit') ? ' active' : '' }} {{ Request::is('user/payment/credit') ? ' active' : '' }}">
|
||||
<a href="{{ route('user_payment_credit') }}" class="sidenav-link"><i class="sidenav-icon ion ion-md-cash"></i><div>{{ __('navigation.credit') }}</div></a>
|
||||
</li>
|
||||
--}}
|
||||
|
||||
<li class="sidenav-item Request::is('user/payment/revenue') ? ' active' : '' }} {{ Request::is('user/payment/revenue') ? ' active' : '' }}">
|
||||
<a href="{{ route('user_payment_revenue') }}" class="sidenav-link"><i class="sidenav-icon ion ion-md-trending-up"></i><div>{{ __('navigation.revenue') }}</div></a>
|
||||
</li>
|
||||
|
||||
<li class="sidenav-item{{ Request::is('user/edit') ? ' active' : '' }}">
|
||||
<a href="{{ route('user_edit') }}" class="sidenav-link"><i class="sidenav-icon ion ion-ios-create"></i><div>{{ __('navigation.my_data') }}</div></a>
|
||||
</li>
|
||||
|
|
|
|||
|
|
@ -304,7 +304,7 @@
|
|||
<table>
|
||||
<tr>
|
||||
<td>
|
||||
{{ __('Datum') }}/{{ __('Leistungsdatum)') }}: {{ $credit_date }}
|
||||
{{ __('Datum') }}/{{ __('Leistungsdatum') }}: {{ $credit_date }}
|
||||
</td>
|
||||
</tr>
|
||||
@if($user->account->tax_number)
|
||||
|
|
|
|||
58
resources/views/user/payment/credit.blade.php
Normal file
58
resources/views/user/payment/credit.blade.php
Normal file
|
|
@ -0,0 +1,58 @@
|
|||
@extends('layouts.layout-2')
|
||||
|
||||
@section('content')
|
||||
<h4 class="font-weight-bold py-2 mb-2">
|
||||
{{ __('navigation.my_account') }} / {{ __('navigation.credit') }}
|
||||
</h4>
|
||||
|
||||
<div class="card">
|
||||
<div class="card-datatable table-responsive">
|
||||
<table class="datatables-style table table-striped table-bordered" id="datatable-user-credit">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>{{__('G.Nr.')}}</th>
|
||||
<th>{{__('Gutschrift')}}</th>
|
||||
<th>{{__('Betrag') }}</th>
|
||||
<th>{{__('Datum') }}</th>
|
||||
<th>{{__('Zahlung')}}</th>
|
||||
<th>{{__('aus Bestellung / Gutschrift')}}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
$( document ).ready(function() {
|
||||
var oTable = $('#datatable-user-credit').DataTable({
|
||||
"processing": true,
|
||||
"serverSide": true,
|
||||
ajax: {
|
||||
url: '{!! route( 'user_payment_credit_datatable') !!}',
|
||||
data: function(d) {
|
||||
//d.filter_sales_year = $('select[name=filter_sales_year]').val();
|
||||
}
|
||||
},
|
||||
"order": [[0, "desc" ]],
|
||||
"columns": [
|
||||
{ data: 'credit_number', name: 'credit_number' },
|
||||
{ data: 'credit', name: 'credit', orderable: false, searchable: false },
|
||||
{ data: 'total', name: 'total' },
|
||||
{ data: 'date', name: 'date' },
|
||||
{ data: 'status', name: 'status', searchable: false },
|
||||
{ data: 'user_margins', name: 'user_margins', orderable: false },
|
||||
],
|
||||
"bLengthChange": false,
|
||||
"iDisplayLength": 100,
|
||||
"language": {
|
||||
"url": "/js/German.json"
|
||||
}
|
||||
});
|
||||
/*$('#filter_sales_year').on('change', function(){
|
||||
oTable.draw();
|
||||
});
|
||||
*/
|
||||
});
|
||||
</script>
|
||||
@endsection
|
||||
|
|
@ -7,7 +7,7 @@
|
|||
|
||||
<div class="card">
|
||||
<div class="card-datatable table-responsive">
|
||||
<table class="datatables-style table table-striped table-bordered">
|
||||
<table class="datatables-style table table-striped table-bordered" id="datatable-user-pay-credit">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="width: 55%">Mitteilung</th>
|
||||
|
|
@ -18,30 +18,39 @@
|
|||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@if($user && $user->user_pay_credits)
|
||||
@foreach($user->user_pay_credits as $user_pay_credit)
|
||||
<tr>
|
||||
@if($user_pay_credit->status === 3)
|
||||
<th scope="row"> {!! nl2br($user_pay_credit->message) !!}</th>
|
||||
@else
|
||||
<th scope="row">{{ trans('payment.'.$user_pay_credit->message) }}
|
||||
@if($user_pay_credit->shopping_order_id)
|
||||
<a class="btn btn-outline-secondary btn-xs" href="{{ route('admin_sales_users_detail', [$user_pay_credit->shopping_order_id]) }}"><i class="ion ion-md-eye"></i></a>
|
||||
@endif
|
||||
</th>
|
||||
@endif
|
||||
<td><div class="no-line-break">{{ formatNumber($user_pay_credit->credit) }} €</div></td>
|
||||
<td><div class="no-line-break">{{ formatNumber($user_pay_credit->old_credit_total) }} €</div></td>
|
||||
<td><div class="no-line-break">{{ formatNumber($user_pay_credit->new_credit_total) }} €</div></td>
|
||||
<td><div class="no-line-break">{{ formatDate($user_pay_credit->created_at) }}</div></td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@endif
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<script>
|
||||
|
||||
$( document ).ready(function() {
|
||||
var oTable = $('#datatable-user-pay-credit').DataTable({
|
||||
"processing": true,
|
||||
"serverSide": true,
|
||||
ajax: {
|
||||
url: '{!! route( 'user_payment_paycredit_datatable') !!}',
|
||||
/*data: function(d) {
|
||||
d.filter_user_status = $('select[name=filter_user_status]').val();
|
||||
}*/
|
||||
},
|
||||
"order": [[4, "desc" ]],
|
||||
"columns": [
|
||||
{ data: 'message', name: 'message' },
|
||||
{ data: 'credit', name: 'credit' },
|
||||
{ data: 'old_credit_total', name: 'old_credit_total', orderable: false, searchable: false },
|
||||
{ data: 'new_credit_total', name: 'new_credit_total', orderable: false, searchable: false },
|
||||
{ data: 'created_at', name: 'created_at' },
|
||||
],
|
||||
"bLengthChange": false,
|
||||
"iDisplayLength": 100,
|
||||
"language": {
|
||||
"url": "/js/German.json"
|
||||
}
|
||||
});
|
||||
/*$('#filter_user_status').on('change', function(){
|
||||
oTable.draw();
|
||||
});*/
|
||||
});
|
||||
</script>
|
||||
@endsection
|
||||
|
|
|
|||
83
resources/views/user/payment/revenue.blade.php
Normal file
83
resources/views/user/payment/revenue.blade.php
Normal file
|
|
@ -0,0 +1,83 @@
|
|||
@extends('layouts.layout-2')
|
||||
|
||||
@section('content')
|
||||
<h4 class="font-weight-bold py-2 mb-2">
|
||||
{{ __('navigation.my_account') }} / {{ __('navigation.revenue') }}
|
||||
</h4>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-sm-6 mb-0 mt-2 mb-2">
|
||||
{!! Form::open(['url' => route('user_payment_revenue'), 'class' => 'form-horizontal', 'id'=>'form_filter_year']) !!}
|
||||
<label class="form-label" for="filter_year">Filter Jahr</label>
|
||||
<select class="custom-select" name="filter_year" id="filter_year">
|
||||
@foreach($years as $year)
|
||||
<option value="{{$year}}" @if($active_year == $year) selected @endif>{{$year}}</option>
|
||||
@endforeach
|
||||
</select>
|
||||
{!! Form::close() !!}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
@foreach ($months as $month)
|
||||
|
||||
@php($date = $active_year."-".$month."-01")
|
||||
<div class="card mb-4">
|
||||
<h6 class="card-header py-1 px-3">
|
||||
<div class="card-header-title"> {{ App\Services\HTMLHelper::getMonth($month) }} {{ $active_year }}</div>
|
||||
</h6>
|
||||
<div class="card-body">
|
||||
<table class="table table-striped table-bordered">
|
||||
<tr>
|
||||
<td class="text-left font-weight-semibold">{{__('Umsatz gesamt')}}:</td>
|
||||
<td class="text-right font-weight-bold">
|
||||
{!! \App\Services\UserMarign::getMontlyPrice($user, $date, true) !!} €*
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="text-left font-weight-semibold">{{__('Umsatz Staffelrabatt')}}:</td>
|
||||
<td class="text-right font-weight-bold">
|
||||
{!! \App\Services\UserMarign::getMontlyAmount($user, $date, true) !!} €*
|
||||
</td>
|
||||
</tr>
|
||||
{{-- <tr>
|
||||
<td class="text-left font-weight-semibold">{{__('Umsatz Zahlung offen')}}:</td>
|
||||
<td class="text-right font-weight-bold">
|
||||
{!! \App\Services\UserMarign::getMontlyPriceOpen($user, $date, true) !!} €*
|
||||
</td>
|
||||
</tr>
|
||||
--}}
|
||||
</table>
|
||||
{{--
|
||||
<h6>{{__('Provision')}}</h6>
|
||||
<table class="table table-striped table-bordered">
|
||||
<tr>
|
||||
<td class="text-left font-weight-semibold">{{__('Vertriebspartner Provision')}} pending:</td>
|
||||
<td class="text-right font-weight-bold">
|
||||
{!! \App\Services\UserMarign::getMontlyPartnerCommissionPending($user, $date, true) !!} €*
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="text-left font-weight-semibold">{{__('Vertriebspartner Provision')}} bestätigt:</td>
|
||||
<td class="text-right font-weight-bold">
|
||||
{!! \App\Services\UserMarign::getMontlyPartnerCommissionOpen($user, $date, true) !!} €*
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
--}}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
@endforeach
|
||||
|
||||
<script>
|
||||
$( document ).ready(function() {
|
||||
|
||||
$('#filter_year').on('change', function(){
|
||||
$('#form_filter_year').submit();
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@endsection
|
||||
Loading…
Add table
Add a link
Reference in a new issue