a316fdf0892d7f424bd85e613db51a276e8c1609.php 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210
  1. <?php $__env->startSection('content'); ?>
  2. <section class="gry-bg py-5">
  3. <div class="profile">
  4. <div class="container">
  5. <div class="row">
  6. <div class="col-xxl-4 col-xl-5 col-lg-6 col-md-8 mx-auto">
  7. <div class="card">
  8. <div class="text-center pt-4">
  9. <h1 class="h4 fw-600">
  10. <?php echo e(translate('Login to your account.')); ?>
  11. </h1>
  12. </div>
  13. <div class="px-4 py-3 py-lg-4">
  14. <div class="">
  15. <form class="form-default" role="form" action="<?php echo e(route('login')); ?>" method="POST">
  16. <?php echo csrf_field(); ?>
  17. <?php if(addon_is_activated('otp_system') && env("DEMO_MODE") != "On"): ?>
  18. <div class="form-group phone-form-group mb-1">
  19. <input type="tel" id="phone-code" class="form-control<?php echo e($errors->has('phone') ? ' is-invalid' : ''); ?>" value="<?php echo e(old('phone')); ?>" placeholder="" name="phone" autocomplete="off">
  20. </div>
  21. <input type="hidden" name="country_code" value="">
  22. <div class="form-group email-form-group mb-1 d-none">
  23. <input type="email" class="form-control <?php echo e($errors->has('email') ? ' is-invalid' : ''); ?>" value="<?php echo e(old('email')); ?>" placeholder="<?php echo e(translate('Email')); ?>" name="email" id="email" autocomplete="off">
  24. <?php if($errors->has('email')): ?>
  25. <span class="invalid-feedback" role="alert">
  26. <strong><?php echo e($errors->first('email')); ?></strong>
  27. </span>
  28. <?php endif; ?>
  29. </div>
  30. <div class="form-group text-right">
  31. <button class="btn btn-link p-0 opacity-50 text-reset" type="button" onclick="toggleEmailPhone(this)"><?php echo e(translate('Use Email Instead')); ?></button>
  32. </div>
  33. <?php else: ?>
  34. <div class="form-group">
  35. <input type="email" class="form-control<?php echo e($errors->has('email') ? ' is-invalid' : ''); ?>" value="<?php echo e(old('email')); ?>" placeholder="<?php echo e(translate('Email')); ?>" name="email" id="email" autocomplete="off">
  36. <?php if($errors->has('email')): ?>
  37. <span class="invalid-feedback" role="alert">
  38. <strong><?php echo e($errors->first('email')); ?></strong>
  39. </span>
  40. <?php endif; ?>
  41. </div>
  42. <?php endif; ?>
  43. <div class="form-group">
  44. <input type="password" class="form-control <?php echo e($errors->has('password') ? ' is-invalid' : ''); ?>" placeholder="<?php echo e(translate('Password')); ?>" name="password" id="password">
  45. </div>
  46. <div class="row mb-2">
  47. <div class="col-6">
  48. <label class="aiz-checkbox">
  49. <input type="checkbox" name="remember" <?php echo e(old('remember') ? 'checked' : ''); ?>>
  50. <span class=opacity-60><?php echo e(translate('Remember Me')); ?></span>
  51. <span class="aiz-square-check"></span>
  52. </label>
  53. </div>
  54. <div class="col-6 text-right">
  55. <a href="<?php echo e(route('password.request')); ?>" class="text-reset opacity-60 fs-14"><?php echo e(translate('Forgot password?')); ?></a>
  56. </div>
  57. </div>
  58. <div class="mb-5">
  59. <button type="submit" class="btn btn-primary btn-block fw-600"><?php echo e(translate('Login')); ?></button>
  60. </div>
  61. </form>
  62. <?php if(env("DEMO_MODE") == "On"): ?>
  63. <div class="mb-5">
  64. <table class="table table-bordered mb-0">
  65. <tbody>
  66. <tr>
  67. <td><?php echo e(translate('Seller Account')); ?></td>
  68. <td>
  69. <button class="btn btn-info btn-sm" onclick="autoFillSeller()"><?php echo e(translate('Copy credentials')); ?></button>
  70. </td>
  71. </tr>
  72. <tr>
  73. <td><?php echo e(translate('Customer Account')); ?></td>
  74. <td>
  75. <button class="btn btn-info btn-sm" onclick="autoFillCustomer()"><?php echo e(translate('Copy credentials')); ?></button>
  76. </td>
  77. </tr>
  78. <tr>
  79. <td><?php echo e(translate('Delivery Boy Account')); ?></td>
  80. <td>
  81. <button class="btn btn-info btn-sm" onclick="autoFillDeliveryBoy()"><?php echo e(translate('Copy credentials')); ?></button>
  82. </td>
  83. </tr>
  84. </tbody>
  85. </table>
  86. </div>
  87. <?php endif; ?>
  88. <?php if(get_setting('google_login') == 1 || get_setting('facebook_login') == 1 || get_setting('twitter_login') == 1): ?>
  89. <div class="separator mb-3">
  90. <span class="bg-white px-3 opacity-60"><?php echo e(translate('Or Login With')); ?></span>
  91. </div>
  92. <ul class="list-inline social colored text-center mb-5">
  93. <?php if(get_setting('facebook_login') == 1): ?>
  94. <li class="list-inline-item">
  95. <a href="<?php echo e(route('social.login', ['provider' => 'facebook'])); ?>" class="facebook">
  96. <i class="lab la-facebook-f"></i>
  97. </a>
  98. </li>
  99. <?php endif; ?>
  100. <?php if(get_setting('google_login') == 1): ?>
  101. <li class="list-inline-item">
  102. <a href="<?php echo e(route('social.login', ['provider' => 'google'])); ?>" class="google">
  103. <i class="lab la-google"></i>
  104. </a>
  105. </li>
  106. <?php endif; ?>
  107. <?php if(get_setting('twitter_login') == 1): ?>
  108. <li class="list-inline-item">
  109. <a href="<?php echo e(route('social.login', ['provider' => 'twitter'])); ?>" class="twitter">
  110. <i class="lab la-twitter"></i>
  111. </a>
  112. </li>
  113. <?php endif; ?>
  114. </ul>
  115. <?php endif; ?>
  116. </div>
  117. <div class="text-center">
  118. <p class="text-muted mb-0"><?php echo e(translate('Dont have an account?')); ?></p>
  119. <a href="<?php echo e(route('user.registration')); ?>"><?php echo e(translate('Register Now')); ?></a>
  120. </div>
  121. </div>
  122. </div>
  123. </div>
  124. </div>
  125. </div>
  126. </div>
  127. </section>
  128. <?php $__env->stopSection(); ?>
  129. <?php $__env->startSection('script'); ?>
  130. <script type="text/javascript">
  131. var isPhoneShown = true,
  132. countryData = window.intlTelInputGlobals.getCountryData(),
  133. input = document.querySelector("#phone-code");
  134. for (var i = 0; i < countryData.length; i++) {
  135. var country = countryData[i];
  136. if(country.iso2 == 'bd'){
  137. country.dialCode = '88';
  138. }
  139. }
  140. var iti = intlTelInput(input, {
  141. separateDialCode: true,
  142. utilsScript: "<?php echo e(static_asset('assets/js/intlTelutils.js')); ?>?1590403638580",
  143. onlyCountries: <?php echo json_encode(\App\Models\Country::where('status', 1)->pluck('code')->toArray()) ?>,
  144. customPlaceholder: function(selectedCountryPlaceholder, selectedCountryData) {
  145. if(selectedCountryData.iso2 == 'bd'){
  146. return "01xxxxxxxxx";
  147. }
  148. return selectedCountryPlaceholder;
  149. }
  150. });
  151. var country = iti.getSelectedCountryData();
  152. $('input[name=country_code]').val(country.dialCode);
  153. input.addEventListener("countrychange", function(e) {
  154. // var currentMask = e.currentTarget.placeholder;
  155. var country = iti.getSelectedCountryData();
  156. $('input[name=country_code]').val(country.dialCode);
  157. });
  158. function toggleEmailPhone(el){
  159. if(isPhoneShown){
  160. $('.phone-form-group').addClass('d-none');
  161. $('.email-form-group').removeClass('d-none');
  162. $('input[name=phone]').val(null);
  163. isPhoneShown = false;
  164. $(el).html('<?php echo e(translate('Use Phone Instead')); ?>');
  165. }
  166. else{
  167. $('.phone-form-group').removeClass('d-none');
  168. $('.email-form-group').addClass('d-none');
  169. $('input[name=email]').val(null);
  170. isPhoneShown = true;
  171. $(el).html('<?php echo e(translate('Use Email Instead')); ?>');
  172. }
  173. }
  174. function autoFillSeller(){
  175. $('#email').val('seller@example.com');
  176. $('#password').val('123456');
  177. }
  178. function autoFillCustomer(){
  179. $('#email').val('customer@example.com');
  180. $('#password').val('123456');
  181. }
  182. function autoFillDeliveryBoy(){
  183. $('#email').val('deliveryboy@example.com');
  184. $('#password').val('123456');
  185. }
  186. </script>
  187. <?php $__env->stopSection(); ?>
  188. <?php echo $__env->make('frontend.layouts.app', \Illuminate\Support\Arr::except(get_defined_vars(), ['__data', '__path']))->render(); ?><?php /**PATH /Users/shaoguo/Desktop/公司资料/小梦/商城/ebayShop/resources/views/frontend/user_login.blade.php ENDPATH**/ ?>