create user from customer page
This commit is contained in:
parent
3894872d33
commit
971a86abf4
@ -55,7 +55,7 @@ class Customers extends Controller
|
|||||||
flash($message)->error();
|
flash($message)->error();
|
||||||
|
|
||||||
return redirect()->back()->withInput($request->except('create_user'))->withErrors(
|
return redirect()->back()->withInput($request->except('create_user'))->withErrors(
|
||||||
['email' => trans('customer.error.email')]
|
['email' => trans('customers.error.email')]
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -129,7 +129,7 @@ class Customers extends Controller
|
|||||||
flash($message)->error();
|
flash($message)->error();
|
||||||
|
|
||||||
return redirect()->back()->withInput($request->except('create_user'))->withErrors(
|
return redirect()->back()->withInput($request->except('create_user'))->withErrors(
|
||||||
['email' => trans('customer.error.email')]
|
['email' => trans('customers.error.email')]
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
4
public/css/app.css
vendored
4
public/css/app.css
vendored
@ -453,6 +453,10 @@ ul.add-new.nav.navbar-nav.pull-left {
|
|||||||
overflow-x: visible;
|
overflow-x: visible;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.margin-top {
|
||||||
|
margin-top: 20px;
|
||||||
|
}
|
||||||
|
|
||||||
@media only screen and (max-width : 768px) {
|
@media only screen and (max-width : 768px) {
|
||||||
.main-header .add-new.nav.navbar-nav i {
|
.main-header .add-new.nav.navbar-nav i {
|
||||||
margin-top: 3px;
|
margin-top: 3px;
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
<?php
|
|
||||||
|
|
||||||
return [
|
|
||||||
'all' => 'All Customers',
|
|
||||||
|
|
||||||
'error' => [
|
|
||||||
'email' => 'The email has already been taken.'
|
|
||||||
]
|
|
||||||
];
|
|
11
resources/lang/en-GB/customers.php
Normal file
11
resources/lang/en-GB/customers.php
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
return [
|
||||||
|
|
||||||
|
'allow_login' => 'Allow Login?',
|
||||||
|
'user_created' => 'User Created',
|
||||||
|
|
||||||
|
'error' => [
|
||||||
|
'email' => 'The email has already been taken.'
|
||||||
|
]
|
||||||
|
];
|
@ -83,8 +83,6 @@ return [
|
|||||||
'search' => 'Search',
|
'search' => 'Search',
|
||||||
'search_placeholder' => 'Type to search..',
|
'search_placeholder' => 'Type to search..',
|
||||||
'filter' => 'Filter',
|
'filter' => 'Filter',
|
||||||
'create_user' => 'Create User',
|
|
||||||
'created_user' => 'Created User',
|
|
||||||
'help' => 'Help',
|
'help' => 'Help',
|
||||||
'all' => 'All',
|
'all' => 'All',
|
||||||
'all_type' => 'All :type',
|
'all_type' => 'All :type',
|
||||||
|
@ -24,18 +24,13 @@
|
|||||||
|
|
||||||
{{ Form::radioGroup('enabled', trans('general.enabled')) }}
|
{{ Form::radioGroup('enabled', trans('general.enabled')) }}
|
||||||
|
|
||||||
<div class="form-group col-md-12">
|
<div class="form-group col-md-12 margin-top">
|
||||||
{!! Form::label('create_user', trans('general.create_user'), ['class' => 'control-label']) !!}
|
<strong>{{ trans('customers.allow_login') }}</strong> {{ Form::checkbox('create_user', '1', null, ['id' => 'create_user']) }}
|
||||||
<br/>
|
|
||||||
<div class="col-md-12">
|
|
||||||
{{ Form::checkbox('create_user', '1') }} {{ trans('general.create_user') }}
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
{{ Form::passwordGroup('password', trans('auth.password.current'), 'key', [], null, 'col-md-6 password hidden') }}
|
{{ Form::passwordGroup('password', trans('auth.password.current'), 'key', [], null, 'col-md-6 password hidden') }}
|
||||||
|
|
||||||
{{ Form::passwordGroup('password_confirmation', trans('auth.password.current_confirm'), 'key', [], null, 'col-md-6 password hidden') }}
|
{{ Form::passwordGroup('password_confirmation', trans('auth.password.current_confirm'), 'key', [], null, 'col-md-6 password hidden') }}
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<!-- /.box-body -->
|
<!-- /.box-body -->
|
||||||
|
|
||||||
|
@ -28,17 +28,13 @@
|
|||||||
|
|
||||||
{{ Form::radioGroup('enabled', trans('general.enabled')) }}
|
{{ Form::radioGroup('enabled', trans('general.enabled')) }}
|
||||||
|
|
||||||
<div class="form-group col-md-12">
|
<div class="form-group col-md-12 margin-top">
|
||||||
{!! Form::label('create_user', trans('general.create_user'), ['class' => 'control-label']) !!}
|
|
||||||
<br/>
|
|
||||||
<div class="col-md-12">
|
|
||||||
@if ($customer->user_id)
|
@if ($customer->user_id)
|
||||||
{{ Form::checkbox('create_user', '1', 1, array('disabled')) }} {{ trans('general.created_user') }}
|
<strong>{{ trans('customers.user_created') }}</strong> {{ Form::checkbox('create_user', '1', 1, ['id' => 'create_user', 'disabled' => 'disabled']) }}
|
||||||
@else
|
@else
|
||||||
{{ Form::checkbox('create_user', '1') }} {{ trans('general.create_user') }}
|
<strong>{{ trans('customers.allow_login') }}</strong> {{ Form::checkbox('create_user', '1', null, ['id' => 'create_user']) }}
|
||||||
@endif
|
@endif
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
||||||
{{ Form::passwordGroup('password', trans('auth.password.current'), 'key', [], null, 'col-md-6 password hidden') }}
|
{{ Form::passwordGroup('password', trans('auth.password.current'), 'key', [], null, 'col-md-6 password hidden') }}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user