2015-03-29 14:37:42 +02:00
|
|
|
@extends('master')
|
|
|
|
|
2016-08-02 15:22:02 +02:00
|
|
|
@section('head')
|
2015-03-29 14:37:42 +02:00
|
|
|
|
2016-08-02 15:22:02 +02:00
|
|
|
<link href="{{ asset('css/bootstrap.min.css') }}" rel="stylesheet" type="text/css"/>
|
2016-08-22 15:45:34 +02:00
|
|
|
<link href="{{ asset('css/style.min.css') }}" rel="stylesheet" type="text/css"/>
|
2015-03-29 14:37:42 +02:00
|
|
|
|
|
|
|
<style type="text/css">
|
|
|
|
body {
|
|
|
|
padding-top: 40px;
|
|
|
|
padding-bottom: 40px;
|
|
|
|
}
|
|
|
|
.modal-header {
|
|
|
|
border-top-left-radius: 3px;
|
|
|
|
border-top-right-radius: 3px;
|
|
|
|
}
|
|
|
|
.modal-header h4 {
|
|
|
|
margin:0;
|
|
|
|
}
|
|
|
|
.modal-header img {
|
2016-08-02 15:22:02 +02:00
|
|
|
float: left;
|
2015-03-29 14:37:42 +02:00
|
|
|
margin-right: 20px;
|
|
|
|
}
|
|
|
|
.form-signin {
|
|
|
|
max-width: 400px;
|
|
|
|
margin: 0 auto;
|
|
|
|
background: #fff;
|
|
|
|
}
|
|
|
|
p.link a {
|
|
|
|
font-size: 11px;
|
|
|
|
}
|
|
|
|
.form-signin .inner {
|
|
|
|
padding: 20px;
|
|
|
|
border-bottom-right-radius: 3px;
|
|
|
|
border-bottom-left-radius: 3px;
|
|
|
|
border-left: 1px solid #ddd;
|
|
|
|
border-right: 1px solid #ddd;
|
|
|
|
border-bottom: 1px solid #ddd;
|
|
|
|
}
|
|
|
|
.form-signin .checkbox {
|
|
|
|
font-weight: normal;
|
|
|
|
}
|
|
|
|
.form-signin .form-control {
|
|
|
|
margin-bottom: 17px !important;
|
|
|
|
}
|
|
|
|
.form-signin .form-control:focus {
|
|
|
|
z-index: 2;
|
|
|
|
}
|
|
|
|
|
2015-05-08 10:21:29 +02:00
|
|
|
.modal-header a:link,
|
|
|
|
.modal-header a:visited,
|
|
|
|
.modal-header a:hover,
|
|
|
|
.modal-header a:active {
|
|
|
|
text-decoration: none;
|
|
|
|
color: white;
|
|
|
|
}
|
|
|
|
|
2015-03-29 14:37:42 +02:00
|
|
|
</style>
|
|
|
|
|
|
|
|
@endsection
|
|
|
|
|
|
|
|
@section('body')
|
|
|
|
<div class="container">
|
|
|
|
|
2015-09-29 20:19:18 +02:00
|
|
|
@include('partials.warn_session', ['redirectTo' => '/login'])
|
2015-03-29 14:37:42 +02:00
|
|
|
|
2015-09-29 20:19:18 +02:00
|
|
|
{!! Former::open('login')
|
|
|
|
->rules(['email' => 'required|email', 'password' => 'required'])
|
2015-10-11 16:41:09 +02:00
|
|
|
->addClass('form-signin') !!}
|
2015-03-31 20:50:58 +02:00
|
|
|
{{ Former::populateField('remember', 'true') }}
|
|
|
|
|
2015-03-29 14:37:42 +02:00
|
|
|
<div class="modal-header">
|
2015-05-08 10:21:29 +02:00
|
|
|
<a href="{{ NINJA_WEB_URL }}" target="_blank">
|
2016-08-02 15:22:02 +02:00
|
|
|
<img src="{{ asset('images/icon-login.png') }}" />
|
2015-05-08 10:21:29 +02:00
|
|
|
<h4>Invoice Ninja | {{ trans('texts.account_login') }}</h4>
|
|
|
|
</a>
|
2016-08-02 15:22:02 +02:00
|
|
|
</div>
|
2015-03-29 14:37:42 +02:00
|
|
|
<div class="inner">
|
|
|
|
<p>
|
|
|
|
{!! Former::text('email')->placeholder(trans('texts.email_address'))->raw() !!}
|
|
|
|
{!! Former::password('password')->placeholder(trans('texts.password'))->raw() !!}
|
2015-03-31 20:50:58 +02:00
|
|
|
{!! Former::hidden('remember')->raw() !!}
|
2015-03-29 14:37:42 +02:00
|
|
|
</p>
|
|
|
|
|
2015-10-11 16:41:09 +02:00
|
|
|
<p>{!! Button::success(trans('texts.login'))
|
|
|
|
->withAttributes(['id' => 'loginButton'])
|
|
|
|
->large()->submit()->block() !!}</p>
|
2015-06-16 21:35:35 +02:00
|
|
|
|
2015-07-30 16:44:47 +02:00
|
|
|
@if (Input::get('new_company') && Utils::allowNewAccounts())
|
2015-11-03 12:20:49 +01:00
|
|
|
{!! Former::hidden('link_accounts')->value('true') !!}
|
2015-06-16 21:35:35 +02:00
|
|
|
<center><p>- {{ trans('texts.or') }} -</p></center>
|
2015-10-11 16:41:09 +02:00
|
|
|
<p>{!! Button::primary(trans('texts.new_company'))->asLinkTo(URL::to('/invoice_now?new_company=true&sign_up=true'))->large()->submit()->block() !!}</p><br/>
|
2015-11-01 19:21:11 +01:00
|
|
|
@elseif (Utils::isOAuthEnabled())
|
2015-10-11 16:41:09 +02:00
|
|
|
<center><p>- {{ trans('texts.or') }} -</p></center>
|
2015-10-18 09:30:28 +02:00
|
|
|
<div class="row">
|
|
|
|
@foreach (App\Services\AuthService::$providers as $provider)
|
|
|
|
<div class="col-md-6">
|
2015-11-01 19:21:11 +01:00
|
|
|
<a href="{{ URL::to('auth/' . $provider) }}" class="btn btn-primary btn-block social-login-button" id="{{ strtolower($provider) }}LoginButton">
|
|
|
|
<i class="fa fa-{{ strtolower($provider) }}"></i>
|
|
|
|
{{ $provider }}
|
|
|
|
</a><br/>
|
|
|
|
</div>
|
2015-10-18 09:30:28 +02:00
|
|
|
@endforeach
|
|
|
|
</div>
|
2015-06-16 21:35:35 +02:00
|
|
|
@endif
|
|
|
|
|
2015-03-29 14:37:42 +02:00
|
|
|
<p class="link">
|
2016-09-20 13:56:36 +02:00
|
|
|
{!! link_to('/recover_password', trans('texts.recover_password'), ['class' => 'pull-left']) !!}
|
2015-04-16 19:12:56 +02:00
|
|
|
{!! link_to(NINJA_WEB_URL.'/knowledgebase/', trans('texts.knowledge_base'), ['target' => '_blank', 'class' => 'pull-right']) !!}
|
2015-03-29 14:37:42 +02:00
|
|
|
</p>
|
2016-09-20 13:56:36 +02:00
|
|
|
|
2015-03-29 14:37:42 +02:00
|
|
|
@if (count($errors->all()))
|
|
|
|
<div class="alert alert-danger">
|
|
|
|
@foreach ($errors->all() as $error)
|
|
|
|
<li>{{ $error }}</li>
|
|
|
|
@endforeach
|
|
|
|
</div>
|
2015-10-11 16:41:09 +02:00
|
|
|
@endif
|
2015-03-29 14:37:42 +02:00
|
|
|
|
|
|
|
@if (Session::has('warning'))
|
2016-08-02 15:22:02 +02:00
|
|
|
<div class="alert alert-warning">{!! Session::get('warning') !!}</div>
|
2015-03-29 14:37:42 +02:00
|
|
|
@endif
|
|
|
|
|
|
|
|
@if (Session::has('message'))
|
2016-08-02 15:22:02 +02:00
|
|
|
<div class="alert alert-info">{!! Session::get('message') !!}</div>
|
2015-03-29 14:37:42 +02:00
|
|
|
@endif
|
|
|
|
|
|
|
|
@if (Session::has('error'))
|
2016-08-02 15:22:02 +02:00
|
|
|
<div class="alert alert-danger"><li>{!! Session::get('error') !!}</li></div>
|
2015-03-29 14:37:42 +02:00
|
|
|
@endif
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
{!! Former::close() !!}
|
|
|
|
|
|
|
|
<p/>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
2015-05-09 20:25:16 +02:00
|
|
|
|
|
|
|
<script type="text/javascript">
|
|
|
|
$(function() {
|
|
|
|
if ($('#email').val()) {
|
|
|
|
$('#password').focus();
|
|
|
|
} else {
|
|
|
|
$('#email').focus();
|
|
|
|
}
|
2015-10-11 16:41:09 +02:00
|
|
|
|
2015-10-18 09:30:28 +02:00
|
|
|
/*
|
2015-10-11 16:41:09 +02:00
|
|
|
var authProvider = localStorage.getItem('auth_provider');
|
|
|
|
if (authProvider) {
|
|
|
|
$('#' + authProvider + 'LoginButton').removeClass('btn-primary').addClass('btn-success');
|
|
|
|
}
|
2015-10-18 09:30:28 +02:00
|
|
|
*/
|
2015-05-09 20:25:16 +02:00
|
|
|
})
|
2015-10-11 16:41:09 +02:00
|
|
|
|
2015-05-09 20:25:16 +02:00
|
|
|
</script>
|
|
|
|
|
2016-08-02 15:22:02 +02:00
|
|
|
@endsection
|