My beer compendium
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

64 lines
2.2 KiB

3 years ago
  1. @extends('layouts.app')
  2. @section('content')
  3. <div class="container">
  4. <div class="row justify-content-center">
  5. <div class="col-md-8">
  6. <div class="card">
  7. @include('inc.navbar')
  8. <div class="card-header"><a href="/home">Home</a> -> {{ __('Grain Bills') }}<span class="backlink"><a href="{{url()->previous()}}">Go Back</a></span></div>
  9. <div class="card-body">
  10. @if (Auth::user()->isAdmin())
  11. <button class="btn btn-primary btn-lg" data-toggle="modal" data-target="#addModal" type="button" name="button" >
  12. Add Adjunct
  13. </button>
  14. <hr />
  15. @endif
  16. <!-- This piece of code is for error messages display purposes -->
  17. @include('inc.messages')
  18. </div>
  19. </div>
  20. </div>
  21. </div>
  22. </div>
  23. <!-- this code if for the modal -->
  24. <div class="modal fade bg-primary text-dark" tabindex="-1" role="dialog" id="addModal">
  25. <div class="modal-dialog" role="document">
  26. <div class="modal-content">
  27. <div class="modal-header">
  28. <h5 class="modal-title">Add Grain Bill</h5>
  29. <button type="button" class="close" data-dismiss="modal" aria-label="Close" >
  30. <span aria-hidden="true">x</span>
  31. </button>
  32. </div>
  33. <div class="modal-body">
  34. <form class="" action="{{route('grainbills.store')}}" method="post">
  35. {{csrf_field()}}
  36. <div class="form-group">
  37. <label for="">Beer ID</label>
  38. <input type="text" class="form-control" name="beer_id">
  39. </div>
  40. <div class="form-group">
  41. <label for="">Grain ID</label>
  42. <input type="text" class="form-control" name="grain_id" >
  43. </div>
  44. <div class="form-group">
  45. <label for="">Amount</label>
  46. <input type="text" class="form-control" name="amount">
  47. </div>
  48. <div class="form-group">
  49. <label for="">% of Total Grain Bill</label>
  50. <input type="text" class="form-control" name="grain_bill">
  51. </div>
  52. <input type="submit" name="submit" value="Submit" class="btn btn-success">
  53. </form>
  54. </div>
  55. </div>
  56. </div>
  57. </div>
  58. @endsection