Skip to content

Commit 8955b42

Browse files
committed
Merge branch 'laravel-5.1' into 1.3
2 parents f299ba8 + 1af4ed6 commit 8955b42

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+1878
-10
lines changed

.travis.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
language: php
22

33
php:
4-
- 5.4
54
- 5.5
65
- 5.6
76

app/Authentication/AuthenticationServiceProvider.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,8 @@ public function boot()
7171
require __DIR__ . "/validators.php";
7272
// package routes
7373
require __DIR__ . '/../Http/routes.php';
74+
// other bootstrap commands
75+
require __DIR__ . '/bootstrap.php';
7476

7577
$this->registerCommands();
7678

app/Authentication/Controllers/UserController.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ public function editProfile()
183183
{
184184
$user_profile = new UserProfile(["user_id" => $user_id]);
185185
}
186-
$custom_profile_repo = App::make('custom_profile_repository', $user_profile->id);
186+
$custom_profile_repo = App::make('custom_profile_repository', [$user_profile->id]);
187187

188188
return View::make('laravel-authentication-acl::admin.user.profile')->with([
189189
'user_profile' => $user_profile,
@@ -215,7 +215,7 @@ public function editOwnProfile()
215215
{
216216
$logged_user = $this->auth->getLoggedUser();
217217

218-
$custom_profile_repo = App::make('custom_profile_repository', $logged_user->user_profile()->first()->id);
218+
$custom_profile_repo = App::make('custom_profile_repository', [$logged_user->user_profile()->first()->id]);
219219

220220
return View::make('laravel-authentication-acl::admin.user.self-profile')
221221
->with([

app/Authentication/Services/UserProfileService.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
* @author jacopo beschi jacopo@jacopobeschi.com
77
*/
88
use App;
9-
use Illuminate\Database\Eloquent\ModelNotFoundException;
109
use Illuminate\Support\MessageBag;
1110
use LaravelAcl\Authentication\Exceptions\PermissionException;
1211
use LaravelAcl\Authentication\Validators\UserProfileUserValidator;
@@ -123,7 +122,7 @@ public function getErrors()
123122
*/
124123
protected function saveCustomProfileFields($input, $user_profile)
125124
{
126-
$custom_profile_repository = App::make('custom_profile_repository', $user_profile->id);
125+
$custom_profile_repository = App::make('custom_profile_repository', [$user_profile->id]);
127126
foreach($input as $input_key => $value)
128127
{
129128
if(($profile_field_type_id_position = $this->isCustomFieldKey($input_key)) !== false)

app/Authentication/bootstrap.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
<?php
2+
// increase max nesting level
3+
ini_set('xdebug.max_nesting_level', 250);

bootstrap/autoload.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,9 @@
2727
|
2828
*/
2929

30-
$compiledPath = __DIR__.'/../storage/framework/compiled.php';
30+
//$compiledPath = __DIR__.'/../storage/framework/compiled.php';
31+
// Laravel 5.1 upgrade
32+
$compiledPath = __DIR__.'/cache/compiled.php';
3133

3234
if (file_exists($compiledPath))
3335
{

bootstrap/cache/.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
*
2+
!.gitignore

config/app.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,9 @@
136136
'Illuminate\Validation\ValidationServiceProvider',
137137
'Illuminate\View\ViewServiceProvider',
138138

139+
// Laravel 5.1 upgrade
140+
//'Illuminate\Broadcasting\BroadcastServiceProvider',
141+
139142
/*
140143
* Application Service Providers...
141144
*/

docs/index.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ a simple admin panel with an ACL using Laravel framework.
1818
To install this software you need:
1919

2020
* Laravel framework 5.*
21-
* Php 5.4+
21+
* Php 5.5+
2222
* GD Library or Imagick
2323
* Enable Fileinfo extension(may be needed for windows users) <a href="http://php.net/manual/en/fileinfo.installation.php">how to enable it</a>
2424

@@ -48,7 +48,7 @@ To install authentication follow this steps:
4848
4949
6. Now you need to install the application, to do that run the command: `php artisan authentication:install`.
5050
51-
Congratulations! You have succesfully installed Laravel Authentication ACL package!
51+
Congratulations! You have successfully installed Laravel Authentication ACL package!
5252
5353
Here is the main application links:
5454
@@ -59,7 +59,7 @@ To install authentication follow this steps:
5959
* http://url_of_your_application/user/logout the logout page
6060
6161
### Note on sending emails ###
62-
Keep in mind this software will send various notification emails, dont't forget to edit your _laravel config/mail.php_ file aswell.
62+
Keep in mind this software will send various notification emails, don't forget to edit your _laravel config/mail.php_ file aswell.
6363
6464
## <a name="configuration">Configuration</a> ##
6565
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
@extends('laravel-authentication-acl::admin.layouts.baseauth')
2+
@section('title')
3+
Admin login
4+
@stop
5+
@section('container')
6+
<div class="row centered-form">
7+
<div class="col-xs-12 col-sm-8 col-md-4 col-sm-offset-2 col-md-offset-4">
8+
<div class="panel panel-info">
9+
<div class="panel-heading">
10+
<h3 class="panel-title bariol-thin">Login to {!!Config::get('acl_base.app_name')!!}</h3>
11+
</div>
12+
<?php $message = Session::get('message'); ?>
13+
@if( isset($message) )
14+
<div class="alert alert-success">{{$message}}</div>
15+
@endif
16+
@if($errors && ! $errors->isEmpty() )
17+
@foreach($errors->all() as $error)
18+
<div class="alert alert-danger">{{$error}}</div>
19+
@endforeach
20+
@endif
21+
<div class="panel-body">
22+
{!! Form::open(array('url' => URL::route("user.login.process"), 'method' => 'post') ) !!}
23+
<div class="row">
24+
<div class="col-xs-12 col-sm-12 col-md-12">
25+
<div class="form-group">
26+
<div class="input-group">
27+
<span class="input-group-addon"><i class="fa fa-envelope"></i></span>
28+
{!! Form::email('email', '', ['id' => 'email', 'class' => 'form-control', 'placeholder' => 'Email address', 'required', 'autocomplete' => 'off']) !!}
29+
</div>
30+
</div>
31+
</div>
32+
</div>
33+
<div class="row">
34+
<div class="col-xs-12 col-sm-12 col-md-12">
35+
<div class="form-group">
36+
<div class="input-group">
37+
<span class="input-group-addon"><i class="fa fa-lock"></i></span>
38+
{!! Form::password('password', ['id' => 'password', 'class' => 'form-control', 'placeholder' => 'Password', 'required', 'autocomplete' => 'off']) !!}
39+
</div>
40+
</div>
41+
</div>
42+
</div>
43+
{!! Form::label('remember','Remember me') !!}
44+
{!! Form::checkbox('remember') !!}
45+
<input type="submit" value="Login" class="btn btn-info btn-block">
46+
{!! Form::close() !!}
47+
<div class="row">
48+
<div class="col-xs-12 col-sm-12 col-md-12 margin-top-10">
49+
{!! link_to_route('user.reminder.process','Forgot password?') !!}
50+
</div>
51+
</div>
52+
</div>
53+
</div>
54+
</div>
55+
</div>
56+
@stop

0 commit comments

Comments
 (0)