sgraypgh Posted January 23, 2023 Report Share Posted January 23, 2023 I have set the default ground handling fee to zero, as I use the Dispo Special version with Expenses. Unfortunately, they both still show up on the Pirep Finance page, but the default is just blank. Is there a way to not have the default version show up? Quote Link to comment Share on other sites More sharing options...
DisposableHero Posted January 24, 2023 Report Share Posted January 24, 2023 (edited) Exclude rows with 0 (zero) expense or income (for GH Cost, it will be expense, debit) while you are in the foreach loop. As this is mostly a "theming" issue, you can check below example from my theme and apply the change in your duplicate (or your own) theme. https://github.com/FatihKoz/DisposableTheme/blob/e7e635a8d62c9aee90370c4c52104dc0fabb0747/resources/views/layouts/Disposable_v3/pireps/show_finance.blade.php#L58-L64 @foreach($pirep->transactions->where('journal_id', $pirep->airline->journal->id) as $entry) @if($entry->credit == 0 && $entry->debit == 0) @continue @endif <tr> <td class="text-start">{{ $entry->memo }}</td> <td>@if($entry->credit){{ money($entry->credit, $units['currency']) }}@endif</td> <td>@if($entry->debit){{ money($entry->debit, $units['currency']) }}@endif</td> </tr> @endforeach https://laravel.com/docs/9.x/blade#loops Edited January 24, 2023 by DisposableHero Quote Link to comment Share on other sites More sharing options...
sgraypgh Posted January 24, 2023 Author Report Share Posted January 24, 2023 Perfect, thank you for the direction! Just amazed at the level of understanding you have with all of this stuff. Quote Link to comment Share on other sites More sharing options...
DisposableHero Posted January 24, 2023 Report Share Posted January 24, 2023 My pleasure I was a developer, many years ago (while I was a teenager and a youngster around my twenties).That "basic" knowledge comes from those nice years, rest is 2+ years experience with v7 and some refreshed skills for v7 addon/theme development (I needed them, no one was around, so I started developing again), nothing more Enjoy v7 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.