102 lines
4.4 KiB
PHP
102 lines
4.4 KiB
PHP
@extends('layouts/contentLayoutMaster')
|
|
|
|
@section('title', 'Add Transaction')
|
|
|
|
@section('vendor-style')
|
|
<!-- vendor css files -->
|
|
<link rel="stylesheet" href="{{ asset(mix('vendors/css/extensions/toastr.min.css')) }}">
|
|
<link rel="stylesheet" href="{{ asset(mix('vendors/css/forms/select/select2.min.css')) }}">
|
|
|
|
@endsection
|
|
|
|
@section('page-style')
|
|
<!-- Page css files -->
|
|
<link rel="stylesheet" href="{{ asset(mix('css/base/plugins/extensions/ext-component-toastr.css')) }}">
|
|
@endsection
|
|
|
|
@section('content')
|
|
<section id="dropzone-examples">
|
|
<form action="{{ route('transaction.store') }}" name="usersForm" method="post" enctype="multipart/form-data">
|
|
@csrf
|
|
<div class="row">
|
|
<div class="col-12">
|
|
<div class="card">
|
|
<div class="card-header">
|
|
<h4 class="card-title">Transaction Details</h4>
|
|
</div>
|
|
<div class="card-body">
|
|
<input type="hidden" name="course_id" value="{{$course_id}}">
|
|
<div class="row">
|
|
<div class="col-lg-6 col-sm-6 mb-1">
|
|
<label for="category" class="form-label">Select Type</label>
|
|
<select name="category"
|
|
class="form-select select2 @error('category') is-invalid @enderror"
|
|
id="category">
|
|
|
|
<option value="credit">Credit</option>
|
|
<option value="debit">Debit</option>
|
|
|
|
|
|
</select>
|
|
@error('category')
|
|
<span class="invalid-feedback" role="alert">
|
|
<strong>{{ $message }}</strong>
|
|
</span>
|
|
@enderror
|
|
</div>
|
|
<div class="col-lg-6 col-sm-6 mb-1">
|
|
<label for="amount" class="form-label">Amount</label>
|
|
<input
|
|
type="number"
|
|
id="amount"
|
|
class="form-control @error('amount') is-invalid @enderror"
|
|
name="amount"
|
|
value="{{ old('amount') }}"
|
|
required="required"
|
|
/>
|
|
@error('amount')
|
|
<span class="invalid-feedback" role="alert">
|
|
<strong>{{ $message }}</strong>
|
|
</span>
|
|
@enderror
|
|
</div>
|
|
</div>
|
|
<div class="row">
|
|
<div class="col-12">
|
|
<button type="submit" class="btn btn-primary me-1"
|
|
onclick="this.disabled=true;this.form.submit();">Submit
|
|
</button>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
</section>
|
|
@endsection
|
|
|
|
@section('vendor-script')
|
|
<script src="{{ asset(mix('vendors/js/forms/cleave/cleave.min.js'))}}"></script>
|
|
<script src="{{ asset(mix('vendors/js/extensions/toastr.min.js')) }}"></script>
|
|
<script src="{{ asset(mix('vendors/js/forms/select/select2.full.min.js')) }}"></script>
|
|
@endsection
|
|
|
|
@section('page-script')
|
|
<script src="{{ asset(mix('js/scripts/forms/form-input-mask.js')) }}"></script>
|
|
<script src="{{ asset(mix('js/scripts/forms/form-select2.js')) }}"></script>
|
|
|
|
<script>
|
|
$(document).ready(function () {
|
|
toastr.options.timeOut = 10000;
|
|
@if(session()->has('error'))
|
|
toastr.error('{{ session('error') }}');
|
|
@elseif(session()->has('success'))
|
|
toastr.success('{{ session('success') }}');
|
|
@endif
|
|
});
|
|
</script>
|
|
@endsection
|
|
|