Files
freeu-project/resources/views/Frontend/Pages/profile/huf.blade.php
Ritikesh yadav c661166e1d first commit
2024-03-28 14:52:40 +05:30

212 lines
12 KiB
PHP

@extends('Frontend.layouts.master')
@section('style')
<style>
.error {
color: red !important
}
label:before {
content: "*";
color: red
}
</style>
@endsection
@section('content')
<div>
<div class="kyc">
<div class="accounts">
<div class="acc-header container aos-init aos-animate" data-aos="fade-right">
<div>
<h2>HUF Accounts</h2>
<p>View all your HUF accounts details from one place</p>
</div>
</div>
</div>
<div class="container tab-form">
<div class="row">
<div class="col-md-12 acc-list">
<div class="card2 first-screen show ml-2">
<form id="huf_Form" method="POST" enctype="multipart/form-data">
@csrf
<div class="pi-details">
<h2>Complete your KYC</h2>
<div>
<h4>Personal Information</h4>
<p>Provide your personal information as per your Bank Account</p>
</div>
</div>
<div class="row form-sec">
<div class="col-md-6 mb-4">
<label>Name</label>
<input type="text" id="name" name="name" placeholder="Enter Name" onkeydown="return /^[a-zA-Z\s]+$/i.test(event.key)" class="iv-input form-control p-2">
</div>
<div class="col-md-6 mb-4">
<label>Mobile Number</label>
<input type="text" id="mobile_number" name="mobile_number" placeholder="Enter Mobile Number" minlength="10" maxlength="10" oninput="this.value = this.value.replace(/[^0-9.]/g, '').replace(/(\..*?)\..*/g, '$1');" class="iv-input form-control p-2">
</div>
<div class="col-md-6 mb-4">
<label>Email ID</label>
<input type="email" id="email" name="email" placeholder="Enter Email" class="iv-input form-control p-2">
</div>
<div class="col-md-6 mb-4">
<label>Date Of Birth</label>
<input type="date" id="dob" name="dob" placeholder="Enter Date Of Birth" class="iv-input form-control p-2" max="2006-01-11">
</div>
<div class="col-md-6 mb-4">
<label>Place Of Birth</label>
<input type="text" id="place_of_birth" name="place_of_birth" placeholder="Enter Place Of Birth" onkeydown="return /^[a-zA-Z\s]+$/i.test(event.key)" class="iv-input form-control p-2">
</div>
<div class="col-md-6 mb-4">
<label>Gross Annual Income</label>
<input type="text" id="gross_annual_income" name="gross_annual_income" placeholder="Enter Gross Annual Income" onkeydown="return /^[0-9]+$/i.test(event.key)" class="iv-input form-control p-2">
</div>
<div class="col-md-6 mb-4">
<label>Occupation / Business</label>
<input type="text" id="occupation" name="occupation" placeholder="Enter Occupation/Business" onkeydown="return /^[a-zA-Z\s]+$/i.test(event.key)" class="iv-input form-control p-2">
</div>
<div class="col-md-6 mb-4">
<label for="phone">Deed of declaration of HUF</label>
<input type="file" id="deed_of_declaration" name="deed_of_declaration" class="iv-input form-control p-2" accept="image/jpeg,image/png,image/jpg,application/pdf">
</div>
<div class="col-md-6 mb-4">
<label for="email">PAN Card - Karta and Members of HUF</label>
<input type="file" id="pan_card" name="pan_card[]" multiple="" class="iv-input form-control p-2" accept="image/jpeg,image/png,image/jpg,application/pdf">
</div>
<div class="col-md-6 mb-4">
<label for="">List of all members (Karta &amp; Co-parceners) of the HUF</label>
<input type="file" id="list_of_all_members" name="list_of_all_members" class="iv-input form-control p-2" accept="image/jpeg,image/png,image/jpg,application/pdf">
</div>
<div class="col-md-6 mb-4">
<label for="">Coparcenrs Aadhar/ Passport</label>
<input type="file" id="coparcenrs_aadhar_passport" name="coparcenrs_aadhar_passport[]" multiple="" class="acc-dropdown form-control p-2" accept="image/jpeg,image/png,image/jpg,application/pdf">
</div>
<div class="col-md-6 mb-4">
<label for="occ">Proof of Address of Karta of HUF (Any One) (Passport / Aadhar Card / Driving License / Voter ID)</label>
<input type="file" id="proof_of_address" name="proof_of_address" class="iv-input form-control p-2" accept="image/jpeg,image/png,image/jpg,application/pdf">
</div>
<div class="col-md-6 mb-4">
<label for="">Bank Statement / Bank Passbook in the name of HUF</label>
<input type="file" id="bank_statement" name="bank_statement" class="iv-input form-control p-2" accept="image/jpeg,image/png,image/jpg,application/pdf">
</div>
<div class="col-md-6 mb-4">
<label for="">Passport size photograph of Karta</label>
<input type="file" id="passport_size_photo" name="passport_size_photo" class="iv-input form-control p-2" accept="image/jpeg,image/png,image/jpg,application/pdf">
</div>
<div class="col-md-6 mb-4">
<label for="">Copy of CML</label>
<input type="file" id="copy_of_cml" name="copy_of_cml" class="iv-input form-control p-2" accept="image/jpeg,image/png,image/jpg,application/pdf">
</div>
<div class="col-md-6 mb-4">
<label for="">Cancelled Cheque</label>
<input type="file" id="cancelled_cheque" name="cancelled_cheque" class="iv-input form-control p-2" accept="image/jpeg,image/png,image/jpg,application/pdf">
</div>
</div>
<h5 class="text-center"><b class="text-danger">"Note: All documents uploaded should be self-attested"</b></h5>
<h5><i>"Please be advised that if additional documents or information are required, the
Jericho Alternatives team will promptly
contact you for further assistance."</i></h5>
<button type="submit" id="huf_submit" class="next-button">Submit</button>
</form>
</div>
</div>
</div>
</div>
</div>
</div>
@endsection
@section('scripts')
<script>
$(function() {
var dtToday = new Date();
var month = dtToday.getMonth() + 1; // jan=0; feb=1 .......
var day = dtToday.getDate();
var year = dtToday.getFullYear() - 18;
if (month < 10)
month = '0' + month.toString();
if (day < 10)
day = '0' + day.toString();
var minDate = year + '-' + month + '-' + day;
var maxDate = year + '-' + month + '-' + day;
$('#dob').attr('max', maxDate);
});
$(document).ready(function() {
$.validator.addMethod("ValidEmail", function(value) {
return /^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(value);
}, "Please enter valid email");
$('#huf_submit').click(function() {
$('#huf_Form').validate({
ignore: [],
debug: false,
rules: {
name: 'required',
mobile_number: 'required',
email: {
required: true,
ValidEmail: true,
},
dob: 'required',
place_of_birth: 'required',
gross_annual_income: 'required',
occupation: 'required',
deed_of_declaration: 'required',
'pan_card[]': 'required',
list_of_all_members: 'required',
'coparcenrs_aadhar_passport[]': 'required',
proof_of_address: 'required',
bank_statement: 'required',
passport_size_photo: 'required',
copy_of_cml: 'required',
cancelled_cheque: 'required',
},
messages: {
name: 'Name is required',
mobile_number: 'Mobile Number is required',
email: 'Email is required',
dob: 'Date Of Birth is required',
place_of_birth: 'Place Of Birth is required',
gross_annual_income: 'Gross Annual Income is required',
occupation: 'Occupation / Business is required',
deed_of_declaration: 'Deed Of Declaration is required',
'pan_card[]': 'Please upload at least 1 photo',
list_of_all_members: 'List of all members is required',
'coparcenrs_aadhar_passport[]': 'Please upload at least 1 photo',
proof_of_address: 'Proof Of Address is required',
bank_statement: 'Bank Statement is required',
passport_size_photo: 'Passport Size Photo is required',
copy_of_cml: 'Copy Of CML is required',
cancelled_cheque: 'Cancelled Cheque is required',
},
submitHandler: function(form) {
var formData = new FormData(form);
// $('#huf_submit').prop('disabled', true);
$.ajax({
url: "{{route('create-huf-kyc')}}",
type: 'POST',
data: formData,
dataType: 'json',
processData: false,
contentType: false,
success: function(result) {
if (result.status === 200) {
toastr.success(result.message);
setTimeout(() => {
location.replace("/kyc");
}, 1000);
}
},
error: function(jqXHR) {
$("#request_callback_btn").removeClass("d-none");
$("#loaderContactBtn").addClass("d-none");
warning(jqXHR.responseJSON);
},
})
}
})
})
});
</script>
@endsection