260 lines
12 KiB
PHP
260 lines
12 KiB
PHP
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8" />
|
|
<title>BB - Sign Client Login</title>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
<meta content="A fully featured admin theme which can be used to build CRM, CMS, etc." name="description" />
|
|
<meta content="Coderthemes" name="author" />
|
|
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
|
<!-- App favicon -->
|
|
<link rel="shortcut icon" href="<?= base_url()."public"; ?>/assets/images/favicon.ico">
|
|
|
|
<!-- App css -->
|
|
<link href="<?= base_url()."public"; ?>/assets/css/bootstrap-creative.min.css" rel="stylesheet" type="text/css" id="bs-default-stylesheet" />
|
|
<link href="<?= base_url()."public"; ?>/assets/css/app-creative.min.css" rel="stylesheet" type="text/css" id="app-default-stylesheet" />
|
|
|
|
<link href="<?= base_url()."public"; ?>/assets/css/bootstrap-creative-dark.min.css" rel="stylesheet" type="text/css" id="bs-dark-stylesheet" />
|
|
<link href="<?= base_url()."public"; ?>/assets/css/app-creative-dark.min.css" rel="stylesheet" type="text/css" id="app-dark-stylesheet" />
|
|
|
|
<!-- icons -->
|
|
<link href="<?= base_url()."public"; ?>/assets/css/icons.min.css" rel="stylesheet" type="text/css" />
|
|
<script src="https://cdn.jsdelivr.net/npm/toastr@2.1.4/toastr.min.js"></script>
|
|
<link href="https://cdn.jsdelivr.net/npm/toastr@2.1.4/build/toastr.min.css" rel="stylesheet">
|
|
<style>
|
|
.toast-warning {
|
|
color: black !important;
|
|
background-color: #edd179 !important; /* Set background color to a solid color */
|
|
opacity: 1 !important; /* Set opacity to 1 to remove transparency */
|
|
}
|
|
.toast-success {
|
|
color: black !important;
|
|
background-color: #2aa762 !important; /* Set background color to a solid color */
|
|
opacity: 1 !important; /* Set opacity to 1 to remove transparency */
|
|
}
|
|
.otp-input {
|
|
text-align: center;
|
|
letter-spacing: 0.5rem;
|
|
}
|
|
</style>
|
|
</head>
|
|
|
|
<body class="loading auth-fluid-pages pb-0">
|
|
|
|
<div class="auth-fluid">
|
|
<!-- Auth fluid right content -->
|
|
<div class="auth-fluid-right">
|
|
<div class="auth-user-testimonial">
|
|
<h3 class="mb-3 text-white">BB - Sign , </h3>
|
|
<p class="lead font-weight-normal"><i class="mdi mdi-format-quote-open"></i> Our File Verification Approved Service ensures that your documents meet all necessary standards and requirements for seamless processing. <i class="mdi mdi-format-quote-close"></i>
|
|
</p>
|
|
</div>
|
|
</div>
|
|
<!-- end Auth fluid right content -->
|
|
|
|
<!--Auth fluid left content -->
|
|
<div class="auth-fluid-form-box">
|
|
<div class="align-items-center d-flex h-100">
|
|
<div class="card-body">
|
|
|
|
<!-- Logo -->
|
|
<div class="auth-brand text-center text-lg-left">
|
|
<div class="auth-logo">
|
|
<a class="logo logo-dark text-center">
|
|
<span class="logo-lg">
|
|
<img src="<?= base_url()."public"; ?>/assets/images/login-logo.png" alt="" height="22" style="width: 200px;height: 85px;">
|
|
</span>
|
|
</a>
|
|
|
|
<a class="logo logo-light text-center">
|
|
<span class="logo-lg">
|
|
<img src="<?= base_url()."public"; ?>/assets/images/login-logo.png" alt="" height="22" style="width: 200px;height: 85px;">
|
|
</span>
|
|
</a>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
<!-- form -->
|
|
<form id="client_login_form" action="<?= base_url(); ?>" method="post">
|
|
|
|
<?php if(session()->getTempdata('error')):?>
|
|
<div class="alert alert-danger" >
|
|
<?= session()->getTempdata('error'); ?>
|
|
</div>
|
|
<?php endif;?>
|
|
|
|
<div class="form-group">
|
|
<div id="gst_error" style="margin-bottom: 4px;"></div>
|
|
<div id="otp_sent_success" style="margin-bottom: 4px;"></div>
|
|
<label for="gst_no">GST Number</label>
|
|
<input class="form-control" type="text" id="gst_no" name="gst_no" required placeholder="Enter your GST">
|
|
</div>
|
|
<!-- Preloader -->
|
|
<div class="loader-mask" style="display:none;">
|
|
<div class="loader" style="display:none;">
|
|
Please Wait <img src="<?= base_url() . "public" ?>/assets/images/simple_loader.gif" height="30" width="30" alt="Loading...">
|
|
</div>
|
|
</div>
|
|
<div class="form-group" id="otp_hide" style="display:none;">
|
|
<label for="otp">OTP</label>
|
|
<input type="text" name="otp" id="otp" class="form-control otp-input" maxlength="6" pattern="\d{6}">
|
|
</div>
|
|
|
|
<div class="form-group mb-3">
|
|
<!-- <div class="custom-control custom-checkbox">
|
|
<input type="checkbox" class="custom-control-input" id="checkbox-signin">
|
|
<label class="custom-control-label" for="checkbox-signin">Remember me</label>
|
|
</div> -->
|
|
</div>
|
|
<div class="form-group mb-0 text-center">
|
|
<button class="btn btn-primary btn-block" id="generate_otp_id" type="button">Generate OTP </button>
|
|
</div>
|
|
<div class="form-group mb-0 text-center" id="verify_otp_hide" style="display:none;">
|
|
<button class="btn btn-primary btn-block" id="verify_otp_id" type="button">Verify OTP</button>
|
|
</div>
|
|
|
|
<div class="form-group mb-0 text-center" id="resend_reenter_otp_hide" style="margin-top: 10px;display:none;">
|
|
<a href="#" id="reenter_pan">Re-Enter GST</a> |
|
|
<a href="#" id="resend_otp">Resend OTP</a>
|
|
</div>
|
|
|
|
</form>
|
|
<!-- end form-->
|
|
|
|
<!-- Footer-->
|
|
<!-- <footer class="footer footer-alt">
|
|
<p class="text-muted">Don't have an account? <a href="auth-register-2.html" class="text-primary ml-1"><b>Sign Up</b></a></p>
|
|
</footer> -->
|
|
|
|
</div> <!-- end .card-body -->
|
|
</div> <!-- end .align-items-center.d-flex.h-100-->
|
|
</div>
|
|
<!-- end auth-fluid-form-box-->
|
|
</div>
|
|
<!-- end auth-fluid-->
|
|
|
|
<!-- Vendor js -->
|
|
<script src="<?= base_url()."public"; ?>/assets/js/vendor.min.js"></script>
|
|
|
|
<!-- App js -->
|
|
<script src="<?= base_url()."public"; ?>/assets/js/app.min.js"></script>
|
|
|
|
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
|
|
|
|
|
|
<script>
|
|
|
|
$('#generate_otp_id').click(function (params) {
|
|
|
|
event.preventDefault(); // Prevent form submission
|
|
var gst_error = $('#gst_error')
|
|
$('.loader').fadeIn();
|
|
$('.loader-mask').fadeIn();
|
|
$.ajax({
|
|
url: '<?php echo base_url()."generate_otp"?>',
|
|
method: 'POST',
|
|
data: {
|
|
gst_no : $('#gst_no').val()
|
|
},
|
|
success: function(response) {
|
|
if(response){
|
|
gst_error.html('');
|
|
$('#generate_otp_id').hide();
|
|
$('#otp_hide').show();
|
|
$('#verify_otp_hide').show();
|
|
$('#gst_no').attr('readonly', true);
|
|
$('#resend_reenter_otp_hide').show();
|
|
|
|
}else{
|
|
gst_error.html('GST number mismatch. Please try again.');
|
|
gst_error.css('color','red');
|
|
}
|
|
$('.loader').fadeOut();
|
|
$('.loader-mask').fadeOut('slow');
|
|
},
|
|
error: function(xhr, status, error) {
|
|
// Handle any errors
|
|
|
|
$('.loader').fadeOut();
|
|
$('.loader-mask').fadeOut('slow');
|
|
console.error('Error generating OTP: ' + error);
|
|
}
|
|
});
|
|
|
|
})
|
|
|
|
|
|
$('#verify_otp_id').click(function (params) {
|
|
$.ajax({
|
|
url: '<?php echo base_url()."verify_otp_client"?>',
|
|
method: 'POST',
|
|
data: {
|
|
gst_no : $('#gst_no').val(),
|
|
otp : $('#otp').val()
|
|
},
|
|
success: function(response) {
|
|
if(response){
|
|
$('#client_login_form').submit();
|
|
}else{
|
|
|
|
|
|
$('#gst_error').html('OTP Mismatch. Please try again.').css('color','red');
|
|
$('#otp').val('');
|
|
}
|
|
|
|
},
|
|
error: function(xhr, status, error) {
|
|
// Handle any errors
|
|
console.error('Error generating OTP: ' + error);
|
|
}
|
|
});
|
|
|
|
})
|
|
|
|
$('#reenter_pan').click(function (params) {
|
|
window.location.reload();
|
|
})
|
|
|
|
$('#resend_otp').click(function (params) {
|
|
|
|
event.preventDefault(); // Prevent form submission
|
|
$('.loader').fadeIn();
|
|
$('.loader-mask').fadeIn();
|
|
$.ajax({
|
|
url: '<?php echo base_url()."generate_otp"?>',
|
|
method: 'POST',
|
|
data: {
|
|
gst_no : $('#gst_no').val()
|
|
},
|
|
success: function(response) {
|
|
if(response){
|
|
$('#gst_error').html('');
|
|
$('#generate_otp_id').hide();
|
|
$('#otp_hide').show();
|
|
$('#verify_otp_hide').show();
|
|
$('#otp_sent_success').html('OTP Sent Successfully').css('color','green');
|
|
}else{
|
|
|
|
|
|
}
|
|
$('.loader').fadeOut();
|
|
$('.loader-mask').fadeOut('slow');
|
|
},
|
|
error: function(xhr, status, error) {
|
|
// Handle any errors
|
|
|
|
$('.loader').fadeOut();
|
|
$('.loader-mask').fadeOut('slow');
|
|
console.error('Error generating OTP: ' + error);
|
|
}
|
|
});
|
|
|
|
})
|
|
|
|
</script>
|
|
|
|
|
|
</body>
|
|
</html>
|