From 3b60ad95d4555d36eb6d510bcfcd9cdffe90cfc7 Mon Sep 17 00:00:00 2001 From: Etienne Marais Date: Wed, 13 Feb 2019 15:44:25 +0200 Subject: [PATCH] Added a remove operation to each access code. Cannot remove from the frontend if the code has been used --- resources/views/ManageEvent/DiscountCodes.blade.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/resources/views/ManageEvent/DiscountCodes.blade.php b/resources/views/ManageEvent/DiscountCodes.blade.php index 8e653d12..f0dafa7e 100644 --- a/resources/views/ManageEvent/DiscountCodes.blade.php +++ b/resources/views/ManageEvent/DiscountCodes.blade.php @@ -40,12 +40,13 @@
@if($event->access_codes->count())
- +
- + + @@ -54,6 +55,9 @@ + @if ($discountCode->usage_count === 0) {{-- Can only remove if haven't been used before--}} + + @endif @endforeach
@lang("DiscountCodes.discount_codes_code")@lang("DiscountCodes.discount_codes_code") @lang("DiscountCodes.discount_codes_usage_count") @lang("DiscountCodes.discount_codes_created_at")
{{ $discountCode->code }} {{ $discountCode->usage_count }} {{ $discountCode->created_at }}Remove