12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788 |
- @extends('layouts.admin.app_iframe')
- @section('plug-css')
- {{-- bootstrap-table --}}
- <link href="{{ asset('js/bootstrap-table/dist/bootstrap-table.css') }}" rel="stylesheet">
- <link href="https://jqueryvalidation.org/files/demo/site-demos.css" rel="stylesheet">
- @endsection
- @section('content')
- <div style="margin-top: 10px;" id="headlines-app">
- <div style="text-align: center;margin-top: 5px;margin-bottom: 10px;font-size: 20px;">
- 密码修改
- </div>
- <el-form action="{{route('admin.auth.password.save')}}" method="post" id="form-create">
- <!-- title -->
- <ui-input-text label="邮箱:" name="email" @if($user->email != 'admin@admin.com') disabled="disabled" @endif value="{{$user->email}}" placeholder="邮箱" maxlength="250" tips="第一次允许修改默认邮箱"></ui-input-text>
- <!-- f_title -->
- <ui-input-text label="登录密码" name="password" value="" placeholder="登录密码" minlength="6" maxlength="12" tips="登录密码"></ui-input-text>
- <ui-submit></ui-submit>
- </el-form>
- </div>
- @endsection
- {{-- 插件引入js --}}
- @section('plug-js')
- {{-- jv 验证 --}}
- <script src="{{ asset('js/jquery-validation1.16/dist/jquery.validate.min.js') }}"></script>
- <script src="{{ asset('js/jquery-validation1.16/dist/additional-methods.min.js') }}"></script>
- <script src="{{ asset('js/jquery-validation1.16/src/localization/messages_zh.js') }}"></script>
- @endsection
- {{-- javaScript --}}
- @section('scripts')
- <script type="application/javascript">
- $(function () {
- // 注意:Vue组件一定放在jQuery.validator前面验证
- new Vue({
- el: '#headlines-app',
- data :function () {
- return {
- };
- }
- });
- jQuery.validator.setDefaults({
- debug: false, // 调试模式true不会提交,false允许提交
- success: "success", // 匹配成功的class样式名称
- errorElement: 'div' // 兼容el标签时使用(兼容el Vue组件label.error标签问题)
- });
- //> 前台数据验证 验证需要设置window.form全局变量
- window.form = $('#form-create').validate({
- rules: {
- title: {
- required: true,
- maxlength: 250,
- normalizer: function ( value ) {
- return $.trim(value);
- }
- },
- f_title: {
- required: true,
- maxlength: 250,
- normalizer: function ( value ) {
- return $.trim(value);
- }
- },
- link: {
- required: true,
- maxlength: 255,
- normalizer: function ( value ) {
- return $.trim(value);
- }
- },
- show: {
- required: true
- },
- sort: {
- required: true,
- normalizer: function ( value ) {
- return $.trim(value);
- }
- }
- }
- });
- // 编辑保存变量
- window.formDatum = $('form').serialize();
- });
- </script>
- @include('layouts.admin.form_script')
- @endsection
|