1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-10 13:12:50 +01:00

Remove breadcrumbs (#3699)

* Remove breadcrumbs

* remove config
This commit is contained in:
Benjamin Beganović 2020-05-14 03:02:23 +02:00 committed by GitHub
parent 41ee143930
commit 14577fdfd0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
26 changed files with 7 additions and 265 deletions

View File

@ -26,7 +26,6 @@
"codedge/laravel-selfupdater": "~3.0",
"composer/composer": "^1.10",
"dacastro4/laravel-gmail": "^3.2",
"davejamesmiller/laravel-breadcrumbs": "5.x",
"doctrine/dbal": "^2.10",
"fideloper/proxy": "^4.0",
"fzaninotto/faker": "^1.4",

View File

@ -1,74 +0,0 @@
<?php
return [
/*
|--------------------------------------------------------------------------
| View Name
|--------------------------------------------------------------------------
|
| Choose a view to display when Breadcrumbs::render() is called.
| Built in templates are:
|
| - 'breadcrumbs::bootstrap4' - Bootstrap 4
| - 'breadcrumbs::bootstrap3' - Bootstrap 3
| - 'breadcrumbs::bootstrap2' - Bootstrap 2
| - 'breadcrumbs::bulma' - Bulma
| - 'breadcrumbs::foundation6' - Foundation 6
| - 'breadcrumbs::materialize' - Materialize
| - 'breadcrumbs::json-ld' - JSON-LD Structured Data
|
| Or a custom view, e.g. '_partials/breadcrumbs'.
|
*/
'view' => 'portal.ninja2020.components.breadcrumbs',
/*
|--------------------------------------------------------------------------
| Breadcrumbs File(s)
|--------------------------------------------------------------------------
|
| The file(s) where breadcrumbs are defined. e.g.
|
| - base_path('routes/breadcrumbs.php')
| - glob(base_path('breadcrumbs/*.php'))
|
*/
'files' => base_path('routes/breadcrumbs.php'),
/*
|--------------------------------------------------------------------------
| Exceptions
|--------------------------------------------------------------------------
|
| Determine when to throw an exception.
|
*/
// When route-bound breadcrumbs are used but the current route doesn't have a name (UnnamedRouteException)
'unnamed-route-exception' => true,
// When route-bound breadcrumbs are used and the matching breadcrumb doesn't exist (InvalidBreadcrumbException)
'missing-route-bound-breadcrumb-exception' => true,
// When a named breadcrumb is used but doesn't exist (InvalidBreadcrumbException)
'invalid-named-breadcrumb-exception' => true,
/*
|--------------------------------------------------------------------------
| Classes
|--------------------------------------------------------------------------
|
| Subclass the default classes for more advanced customisations.
|
*/
// Manager
'manager-class' => DaveJamesMiller\Breadcrumbs\BreadcrumbsManager::class,
// Generator
'generator-class' => DaveJamesMiller\Breadcrumbs\BreadcrumbsGenerator::class,
];

View File

@ -3,9 +3,6 @@
@section('body')
<main class="main" id="client_create">
<!-- Breadcrumb-->
{{ Breadcrumbs::render('clients.create') }}
<form @submit.prevent="onSubmit" @keydown="form.errors.clear($event.target.name)">
<div class="container-fluid">

View File

@ -4,9 +4,6 @@
<main class="main" id="client_edit">
<!-- Breadcrumb-->
{{ Breadcrumbs::render('clients.edit', $client) }}
<vue-toastr ref="toastr"></vue-toastr>
<div class="container-fluid">

View File

@ -10,9 +10,6 @@
@section('body')
@parent
<main class="main" >
<!-- Breadcrumb-->
{{ Breadcrumbs::render('clients') }}
<div class="container-fluid">
<div class="row">
<div class="col-md-12">

View File

@ -3,9 +3,6 @@
@section('body')
<main class="main" id="client_show">
<!-- Breadcrumb-->
{{ Breadcrumbs::render('clients.show', $client) }}
<vue-toastr ref="toastr"></vue-toastr>
<div class="container-fluid">

View File

@ -7,8 +7,6 @@
@section('body')
@parent
<main class="main" >
<!-- Breadcrumb-->
{{ Breadcrumbs::render('clients') }}
<div class="container-fluid" id="client_list">
<vue-toastr ref="toastr"></vue-toastr>

View File

@ -1,6 +1,4 @@
<main class="main">
<!-- Breadcrumb-->
{{ Breadcrumbs::render('dashboard') }}
<div class="container-fluid">
<div class="row">

View File

@ -2,8 +2,6 @@
@section('meta_title', ctrans('texts.credits'))
@section('header')
{{ Breadcrumbs::render('credits') }}
@if($errors->any())
<div class="alert alert-failure mb-4">
@foreach($errors->all() as $error)

View File

@ -1,10 +1,6 @@
@extends('portal.ninja2020.layout.app')
@section('meta_title', ctrans('texts.credit'))
@section('header')
{{ Breadcrumbs::render('credits.show', $credit) }}
@endsection
@section('body')
<div class="container mx-auto">
<div class="bg-white shadow overflow-hidden sm:rounded-lg">

View File

@ -2,8 +2,6 @@
@section('meta_title', ctrans('texts.dashboard'))
@section('header')
{{ Breadcrumbs::render('dashboard') }}
@if(!empty($client->getSetting('custom_message_dashboard')))
@component('portal.ninja2020.components.message')
{!! CustomMessage::client($client)

View File

@ -5,10 +5,6 @@
<meta name="stripe-publishable-key" content="{{ $gateway->getPublishableKey() }}">
@endpush
@section('header')
{{ Breadcrumbs::render('payment_methods.add_credit_card') }}
@endsection
@section('body')
<form action="{{ route('client.payment_methods.store') }}" method="post" id="server_response">
@csrf

View File

@ -7,10 +7,6 @@
<meta name="turbolinks-visit-control" content="reload">
@endpush
@section('header')
{{ Breadcrumbs::render('invoices.pay_now') }}
@endsection
@section('body')
<form action="{{ route('client.payments.response') }}" method="post" id="server-response">
@csrf

View File

@ -2,15 +2,14 @@
@section('meta_title', ctrans('texts.invoices'))
@section('header')
{{ Breadcrumbs::render('invoices') }}
@if($errors->any())
<div class="alert alert-failure mb-4">
@foreach($errors->all() as $error)
<p>{{ $error }}</p>
@endforeach
</div>
@endif
@if($errors->any())
<div class="alert alert-failure mb-4">
@foreach($errors->all() as $error)
<p>{{ $error }}</p>
@endforeach
</div>
@endif
<div class="bg-white shadow rounded mb-4" translate>
<div class="px-4 py-5 sm:p-6">

View File

@ -6,10 +6,6 @@
<script src="{{ asset('js/vendor/pdf.js/pdf.min.js') }}"></script>
@endpush
@section('header')
{{ Breadcrumbs::render('invoices.show', $invoice) }}
@endsection
@section('body')
@if($invoice->isPayable() && !empty($client->getSetting('custom_message_unpaid_invoice')))

View File

@ -2,7 +2,6 @@
@section('meta_title', ctrans('texts.payment_methods'))
@section('header')
{{ Breadcrumbs::render('payment_methods') }}
<div class="bg-white shadow rounded mb-4" translate>
<div class="px-4 py-5 sm:p-6">
<div class="sm:flex sm:items-start sm:justify-between">

View File

@ -1,10 +1,6 @@
@extends('portal.ninja2020.layout.app')
@section('meta_title', ucfirst($payment_method->gateway_type->name))
@section('header')
{{ Breadcrumbs::render('payment_methods.show', $payment_method) }}
@endsection
@section('body')
<div class="container mx-auto">
<div class="bg-white shadow overflow-hidden sm:rounded-lg">

View File

@ -2,7 +2,6 @@
@section('meta_title', ctrans('texts.payments'))
@section('header')
{{ Breadcrumbs::render('payments') }}
<div class="bg-white shadow rounded mb-4" translate>
<div class="px-4 py-5 sm:p-6">
<div class="sm:flex sm:items-start sm:justify-between">

View File

@ -1,10 +1,6 @@
@extends('portal.ninja2020.layout.app')
@section('meta_title', ctrans('texts.payment'))
@section('header')
{{ Breadcrumbs::render('payments.show', $payment) }}
@endsection
@section('body')
<div class="container mx-auto">
<div class="bg-white shadow overflow-hidden sm:rounded-lg">

View File

@ -6,10 +6,6 @@
<script src="https://cdn.jsdelivr.net/npm/signature_pad@2.3.2/dist/signature_pad.min.js"></script>
@endpush
@section('header')
{{ Breadcrumbs::render('quotes.approve') }}
@endsection
@section('body')
<form action="{{ route('client.quotes.bulk') }}" method="post" id="approve-form">
@csrf

View File

@ -2,8 +2,6 @@
@section('meta_title', ctrans('texts.quotes'))
@section('header')
{{ Breadcrumbs::render('quotes') }}
@if($errors->any())
<div class="alert alert-failure mb-4">
@foreach($errors->all() as $error)

View File

@ -6,10 +6,6 @@
<script src="{{ asset('js/vendor/pdf.js/pdf.min.js') }}"></script>
@endpush
@section('header')
{{ Breadcrumbs::render('quotes.show', $quote) }}
@endsection
@section('body')
@if(!$quote->isApproved() && !empty($client->getSetting('custom_message_unapproved_quote')))

View File

@ -1,9 +1,5 @@
@extends('portal.ninja2020.layout.app')
@section('header')
{{ Breadcrumbs::render('recurring_invoices.request_cancellation', $invoice) }}
@stop
@section('body')
<div class="container mx-auto">
<div class="bg-white shadow overflow-hidden rounded">

View File

@ -2,8 +2,6 @@
@section('meta_title', ctrans('texts.recurring_invoices'))
@section('header')
{{ Breadcrumbs::render('recurring_invoices') }}
<div class="bg-white shadow rounded mb-4" translate>
<div class="px-4 py-5 sm:p-6">
<div class="sm:flex sm:items-start sm:justify-between">

View File

@ -1,10 +1,6 @@
@extends('portal.ninja2020.layout.app')
@section('meta_title', ctrans('texts.recurring_invoice'))
@section('header')
{{ Breadcrumbs::render('recurring_invoices.show', $invoice) }}
@endsection
@section('body')
<div class="container mx-auto">
<div class="bg-white shadow overflow-hidden sm:rounded-lg">

View File

@ -1,116 +0,0 @@
<?php
// Dashboard
Breadcrumbs::for('dashboard', function ($trail) {
$trail->push(trans('texts.dashboard'), route('client.dashboard'));
});
// Invoices
Breadcrumbs::for('invoices', function ($trail) {
$trail->push(ctrans('texts.invoices'), route('client.invoices.index'));
});
// Invoices > Show invoice
Breadcrumbs::for('invoices.show', function ($trail, $invoice) {
$trail->parent('invoices');
$trail->push(sprintf('%s: %s', ctrans('texts.invoice'), $invoice->number), route('client.invoices.index', $invoice->hashed_id));
});
// Recurring invoices
Breadcrumbs::for('recurring_invoices', function ($trail) {
$trail->push(ctrans('texts.recurring_invoices'), route('client.recurring_invoices.index'));
});
// Recurring invoices > Show recurring invoice
Breadcrumbs::for('recurring_invoices.show', function ($trail, $invoice) {
$trail->parent('recurring_invoices');
$trail->push(sprintf('%s: %s', ctrans('texts.recurring_invoice'), $invoice->hashed_id), route('client.recurring_invoices.index', $invoice->hashed_id));
});
// Recurring invoices > Show recurring invoice
Breadcrumbs::for('recurring_invoices.request_cancellation', function ($trail, $invoice) {
$trail->parent('recurring_invoices.show', $invoice);
$trail->push(ctrans('texts.request_cancellation'), route('client.recurring_invoices.request_cancellation', $invoice->hashed_id));
});
// Payments
Breadcrumbs::for('payments', function ($trail) {
$trail->push(ctrans('texts.payments'), route('client.payments.index'));
});
// Payments > Show payment
Breadcrumbs::for('payments.show', function ($trail, $invoice) {
$trail->parent('payments');
$trail->push(sprintf('%s: %s', ctrans('texts.payment'), $invoice->hashed_id), route('client.payments.index', $invoice->hashed_id));
});
// Payment methods
Breadcrumbs::for('payment_methods', function ($trail) {
$trail->push(ctrans('texts.payment_methods'), route('client.payment_methods.index'));
});
// Payment methods > Show payment method
Breadcrumbs::for('payment_methods.show', function ($trail, $invoice) {
$trail->parent('payment_methods');
$trail->push(sprintf('%s: %s', ctrans('texts.payment_methods'), $invoice->hashed_id), route('client.payment_methods.index', $invoice->hashed_id));
});
// Payment methods > Create method
Breadcrumbs::for('payment_methods.add_credit_card', function ($trail) {
$trail->parent('payment_methods');
$trail->push(ctrans('texts.add_credit_card'));
});
// Quotes
Breadcrumbs::for('quotes', function ($trail) {
$trail->push(ctrans('texts.quotes'), route('client.quotes.index'));
});
// Quotes > Show quote
Breadcrumbs::for('quotes.show', function ($trail, $quote) {
$trail->parent('quotes');
$trail->push(sprintf('%s: %s', ctrans('texts.quotes'), $quote->hashed_id), route('client.quotes.index', $quote->hashed_id));
});
// Quotes > Approve
Breadcrumbs::for('quotes.approve', function ($trail) {
$trail->parent('quotes');
$trail->push(ctrans('texts.approve'));
});
// Quotes
Breadcrumbs::for('credits', function ($trail) {
$trail->push(ctrans('texts.credits'), route('client.credits.index'));
});
// Quotes > Show quote
Breadcrumbs::for('credits.show', function ($trail, $credit) {
$trail->parent('credits');
$trail->push(sprintf('%s: %s', ctrans('texts.credits'), $credit->hashed_id), route('client.credits.index', $credit->hashed_id));
});
// Invoices > Payment
Breadcrumbs::for('invoices.pay_now', function ($trail) {
$trail->parent('invoices');
$trail->push(ctrans('texts.pay_now'));
});
// Dashboard > Client
Breadcrumbs::for('clients', function ($trail) {
$trail->parent('dashboard');
$trail->push(trans('texts.clients'), route('clients.index'));
});
Breadcrumbs::for('clients.show', function ($trail, $client) {
$trail->parent('clients');
$trail->push($client->name, route('clients.show', $client));
});
Breadcrumbs::for('clients.edit', function ($trail, $client) {
$trail->parent('clients');
$trail->push($client->name, route('clients.edit', $client));
});
Breadcrumbs::for('clients.create', function ($trail) {
$trail->parent('clients');
});