login.blade.php 4.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. @extends('theme::layout.account')
  2. @section('seo_title')用户登录@endsection
  3. @section('content')
  4. <div class="header text-center">
  5. <h1>
  6. <a href="{{ route('website.index') }}" class="logo">
  7. <img src="{{ asset('/css/default/login-logo.png') }}" alt="{{ Setting()->get('website_name') }}">
  8. </a>
  9. </h1>
  10. <p class="description text-muted">{{ Setting()->get('register_title','欢迎加入矿山问答社区') }}</p>
  11. </div>
  12. <div class="col-md-6 col-md-offset-3 bg-white login-wrap">
  13. @if ( session('message') )
  14. <div class="alert @if(session('message_type')===1) alert-danger @else alert-success @endif alert-dismissible" role="alert">
  15. <button type="button" class="close" data-dismiss="alert" aria-label="Close"><span aria-hidden="true">&times;</span></button>
  16. {{ session('message') }}
  17. </div>
  18. @endif
  19. <h1 class="h4 text-center text-muted login-title">用户登录</h1>
  20. <form role="form" name="loginForm" action="{{ route('auth.user.login') }}" method="POST" >
  21. <input type="hidden" name="_token" value="{{ csrf_token() }}">
  22. <div class="form-group @if ($errors->first('email')) has-error @endif">
  23. <label class="required">用户名</label>
  24. <input type="text" class="form-control" name="email" required placeholder="" value="{{ old('email') }}">
  25. @if ($errors->first('email'))
  26. <span class="help-block">{{ $errors->first('email') }}</span>
  27. @endif
  28. </div>
  29. <div class="form-group @if ($errors->first('password')) has-error @endif">
  30. <label for="" class="required">密码</label>
  31. <input type="password" class="form-control" name="password" required placeholder="">
  32. @if ($errors->first('password'))
  33. <span class="help-block">{{ $errors->first('password') }}</span>
  34. @endif
  35. </div>
  36. @if(Setting()->get('code_login') == 1)
  37. @include('theme::layout.auth_captcha')
  38. @endif
  39. <div class="form-group clearfix">
  40. <div class="checkbox pull-left">
  41. <label><input name="remember" type="checkbox" value="1" checked> 记住登录状态</label>
  42. </div>
  43. <button type="submit" class="btn btn-primary pull-right pl20 pr20">登录</button>
  44. </div>
  45. @if(config('services.oauth_open'))
  46. <hr />
  47. <div class="widget-login mt-30">
  48. <p class="text-muted mt-5 mr-10 pull-left hidden-xs">快速登录</p>
  49. @if(config('services.weixin.open'))
  50. <a href="{{ route('auth.oauth.login',['type'=>'weixin']) }}" class="btn btn-default btn-sm btn-sn-weixin hidden-lg" ><span class="icon-sn-bg-weixin"></span> <strong class="visible-xs-inline">微信账号</strong></a>
  51. @endif
  52. @if(config('services.weixinweb.open'))
  53. <a href="{{ route('auth.oauth.login',['type'=>'weixinweb']) }}" class="btn btn-default btn-sm btn-sn-weixin hidden-xs" ><span class="icon-sn-bg-weixin"></span> <strong class="visible-xs-inline">微信扫码</strong></a>
  54. @endif
  55. @if(config('services.qq.open'))
  56. <a href="{{ route('auth.oauth.login',['type'=>'qq']) }}" class="btn btn-default btn-sm btn-sn-qq" ><span class="icon-sn-bg-qq"></span> <strong class="visible-xs-inline">QQ 账号</strong></a>
  57. @endif
  58. @if(config('services.weibo.open'))
  59. <a href="{{ route('auth.oauth.login',['type'=>'weibo']) }}" class="btn btn-default btn-sm btn-sn-weibo" ><span class="icon-sn-bg-weibo"></span> <strong class="visible-xs-inline">新浪微博账号</strong></a>
  60. @endif
  61. </div>
  62. @endif
  63. </form>
  64. </div>
  65. {{-- <div class="text-center col-md-12 login-link">--}}
  66. {{-- <a href="{{ route('auth.user.register') }}">注册新账号</a>--}}
  67. {{-- |--}}
  68. {{-- <a href="{{ route('website.index') }}">首页</a>--}}
  69. {{-- |--}}
  70. {{-- <a href="{{ route('auth.user.forgetPassword') }}">找回密码</a>--}}
  71. {{-- </div>--}}
  72. @endsection