forgot page converted to vue form
This commit is contained in:
parent
d555d764d9
commit
d33e326c55
7
resources/assets/js/views/auth/forgot.js
vendored
7
resources/assets/js/views/auth/forgot.js
vendored
@ -11,16 +11,17 @@ import Vue from 'vue';
|
|||||||
import Global from './../../mixins/global';
|
import Global from './../../mixins/global';
|
||||||
|
|
||||||
import Form from './../../plugins/form';
|
import Form from './../../plugins/form';
|
||||||
import BulkAction from './../../plugins/bulk-action';
|
|
||||||
|
|
||||||
const app = new Vue({
|
const app = new Vue({
|
||||||
el: '#app',
|
el: '#app',
|
||||||
|
|
||||||
mixins: [
|
mixins: [
|
||||||
Global
|
Global
|
||||||
],
|
],
|
||||||
|
|
||||||
data: function () {
|
data: function () {
|
||||||
return {
|
return {
|
||||||
form: new Form('item')
|
form: new Form('forgot')
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
},
|
||||||
});
|
});
|
||||||
|
20
resources/assets/js/views/auth/login.js
vendored
20
resources/assets/js/views/auth/login.js
vendored
@ -15,30 +15,14 @@ import BulkAction from './../../plugins/bulk-action';
|
|||||||
|
|
||||||
const app = new Vue({
|
const app = new Vue({
|
||||||
el: '#app',
|
el: '#app',
|
||||||
|
|
||||||
mixins: [
|
mixins: [
|
||||||
Global
|
Global
|
||||||
],
|
],
|
||||||
|
|
||||||
data: function () {
|
data: function () {
|
||||||
return {
|
return {
|
||||||
form: new Form('login')
|
form: new Form('login')
|
||||||
}
|
}
|
||||||
},
|
|
||||||
watch:{
|
|
||||||
'form.response'(notify) {
|
|
||||||
/*
|
|
||||||
if (!notify.message) {
|
|
||||||
return {};
|
|
||||||
}
|
|
||||||
|
|
||||||
var type = (notify.success) ? 'success' : 'warning';
|
|
||||||
|
|
||||||
this.$notify({
|
|
||||||
message: notify.message,
|
|
||||||
timeout: 5000,
|
|
||||||
icon: 'ni ni-bell-55',
|
|
||||||
type
|
|
||||||
});
|
|
||||||
*/
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -1,28 +1,28 @@
|
|||||||
@extends('layouts.auth')
|
@extends('layouts.auth')
|
||||||
|
|
||||||
@section('title', trans('auth.reset_password'))
|
|
||||||
@section('message', trans('auth.reset_password'))
|
@section('message', trans('auth.reset_password'))
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<form role="form" method="POST" action="{{ url('auth/forgot') }}">
|
{!! Form::open([
|
||||||
{{ csrf_field() }}
|
'route' => 'forgot',
|
||||||
|
'id' => 'forgot',
|
||||||
|
'@submit.prevent' => 'onSubmit',
|
||||||
|
'@keydown' => 'form.errors.clear($event.target.name)',
|
||||||
|
'files' => true,
|
||||||
|
'role' => 'form',
|
||||||
|
'class' => 'form-loading-button',
|
||||||
|
'novalidate' => true
|
||||||
|
]) !!}
|
||||||
|
|
||||||
|
|
||||||
@stack('email_input_start')
|
@stack('email_input_start')
|
||||||
<div class="form-group has-feedback{{ $errors->has('email') ? ' has-error' : '' }}">
|
{{ Form::emailGroup('email', false, 'envelope', ['placeholder' => trans('general.email')], null, 'has-feedback', 'input-group-alternative') }}
|
||||||
<div class="input-group input-group-merge input-group-alternative">
|
|
||||||
<div class="input-group-prepend">
|
|
||||||
<span class="input-group-text"><i class="fa fa-envelope"></i></span>
|
|
||||||
</div>
|
|
||||||
<input class="form-control" placeholder="{{ trans('general.email') }}" name="email" type="email">
|
|
||||||
</div>
|
|
||||||
@if ($errors->has('email'))
|
|
||||||
<span class="help-block">
|
|
||||||
<strong>{{ $errors->first('email') }}</strong>
|
|
||||||
</span>
|
|
||||||
@endif
|
|
||||||
</div>
|
|
||||||
@stack('email_input_end')
|
@stack('email_input_end')
|
||||||
|
|
||||||
<button type="submit" class="btn btn-success float-right">{{ trans('general.send') }}</button>
|
<button type="submit" class="btn btn-success float-right">{{ trans('general.send') }}</button>
|
||||||
</form>
|
{!! Form::close() !!}
|
||||||
@endsection
|
@endsection
|
||||||
|
|
||||||
|
@push('scripts_start')
|
||||||
|
<script src="{{ asset('public/js/auth/forgot.js?v=' . version('short')) }}"></script>
|
||||||
|
@endpush
|
||||||
|
Loading…
x
Reference in New Issue
Block a user