|
| 1 | +<x-app-layout> |
| 2 | + <x-slot name="header"> |
| 3 | + <h2 class="font-semibold text-xl text-gray-800 leading-tight"> |
| 4 | + {{ __('My Account') }} |
| 5 | + </h2> |
| 6 | + </x-slot> |
| 7 | + |
| 8 | + <div class="py-12"> |
| 9 | + <div class="max-w-7xl mx-auto sm:px-6 lg:px-8"> |
| 10 | + <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg"> |
| 11 | + <div class="px-6"> |
| 12 | + <h1 class="inline-block text-2xl sm:text-3xl font-extrabold text-slate-900 tracking-tight dark:text-slate-200 py-4 block sm:inline-block flex">{{ __('Account Info') }}</h1> |
| 13 | + @if ($errors->account->any()) |
| 14 | + <ul class="mt-3 list-none list-inside text-sm text-red-400"> |
| 15 | + @foreach ($errors->account->all() as $error) |
| 16 | + <li>{{ $error }}</li> |
| 17 | + @endforeach |
| 18 | + </ul> |
| 19 | + @endif |
| 20 | + @if(session()->has('account_message')) |
| 21 | + <div class="mb-8 text-green-400 font-bold"> |
| 22 | + {{ session()->get('account_message') }} |
| 23 | + </div> |
| 24 | + @endif |
| 25 | + </div> |
| 26 | + <div class="w-full px-6 py-4 bg-white overflow-hidden"> |
| 27 | + |
| 28 | + <form method="POST" action="{{ route('admin.account.info.store') }}"> |
| 29 | + @csrf |
| 30 | + |
| 31 | + <div class="py-2"> |
| 32 | + <label for="name" class="block font-medium text-sm text-gray-700{{$errors->account->has('name') ? ' text-red-400' : ''}}">{{ __('Name') }}</label> |
| 33 | + |
| 34 | + <input id="name" class="rounded-md shadow-sm border-gray-300 focus:border-indigo-300 focus:ring focus:ring-indigo-200 focus:ring-opacity-50 block mt-1 w-full{{$errors->account->has('name') ? ' border-red-400' : ''}}" |
| 35 | + type="text" |
| 36 | + name="name" |
| 37 | + value="{{ old('name', $user->name) }}" |
| 38 | + /> |
| 39 | + </div> |
| 40 | + |
| 41 | + <div class="py-2"> |
| 42 | + <label for="email" class="block font-medium text-sm text-gray-700{{$errors->account->has('email') ? ' text-red-400' : ''}}">{{ __('Email') }}</label> |
| 43 | + |
| 44 | + <input id="email" class="rounded-md shadow-sm border-gray-300 focus:border-indigo-300 focus:ring focus:ring-indigo-200 focus:ring-opacity-50 block mt-1 w-full{{$errors->account->has('email') ? ' border-red-400' : ''}}" |
| 45 | + type="email" |
| 46 | + name="email" |
| 47 | + value="{{ old('email', $user->email) }}" |
| 48 | + /> |
| 49 | + </div> |
| 50 | + |
| 51 | + <div class="flex justify-end mt-4"> |
| 52 | + <button type="submit" class="inline-flex items-center px-4 py-2 bg-gray-800 border border-transparent rounded-md font-semibold text-xs text-white uppercase tracking-widest hover:bg-gray-700 active:bg-gray-900 focus:outline-none focus:border-gray-900 focus:ring ring-gray-300 disabled:opacity-25 transition ease-in-out duration-150"> |
| 53 | + {{ __('Update') }} |
| 54 | + </button> |
| 55 | + </div> |
| 56 | + </form> |
| 57 | + </div> |
| 58 | + </div> |
| 59 | + </div> |
| 60 | + </div> |
| 61 | + <div class="py-3"> |
| 62 | + <div class="max-w-7xl mx-auto sm:px-6 lg:px-8"> |
| 63 | + <div class="bg-white overflow-hidden shadow-sm sm:rounded-lg"> |
| 64 | + <div class="px-6"> |
| 65 | + <h1 class="inline-block text-2xl sm:text-3xl font-extrabold text-slate-900 tracking-tight dark:text-slate-200 py-4 block sm:inline-block flex">{{ __('Change Password') }}</h1> |
| 66 | + @if ($errors->password->any()) |
| 67 | + <ul class="mt-3 list-none list-inside text-sm text-red-400"> |
| 68 | + @foreach ($errors->password->all() as $error) |
| 69 | + <li>{{ $error }}</li> |
| 70 | + @endforeach |
| 71 | + </ul> |
| 72 | + @endif |
| 73 | + @if(session()->has('password_message')) |
| 74 | + <div class="mb-8 text-green-400 font-bold"> |
| 75 | + {{ session()->get('password_message') }} |
| 76 | + </div> |
| 77 | + @endif |
| 78 | + </div> |
| 79 | + <div class="w-full px-6 py-4 bg-white overflow-hidden"> |
| 80 | + |
| 81 | + <form method="POST" action="{{ route('admin.account.password.store') }}"> |
| 82 | + @csrf |
| 83 | + |
| 84 | + <div class="py-2"> |
| 85 | + <label for="old_password" class="block font-medium text-sm text-gray-700{{$errors->password->has('old_password') ? ' text-red-400' : ''}}">{{ __('Old Password') }}</label> |
| 86 | + |
| 87 | + <input id="old_password" class="rounded-md shadow-sm border-gray-300 focus:border-indigo-300 focus:ring focus:ring-indigo-200 focus:ring-opacity-50 block mt-1 w-full{{$errors->password->has('old_password') ? ' border-red-400' : ''}}" |
| 88 | + type="password" |
| 89 | + name="old_password" |
| 90 | + /> |
| 91 | + </div> |
| 92 | + |
| 93 | + <div class="py-2"> |
| 94 | + <label for="new_password" class="block font-medium text-sm text-gray-700{{$errors->password->has('new_password') ? ' text-red-400' : ''}}">{{ __('New Password') }}</label> |
| 95 | + |
| 96 | + <input id="new_password" class="rounded-md shadow-sm border-gray-300 focus:border-indigo-300 focus:ring focus:ring-indigo-200 focus:ring-opacity-50 block mt-1 w-full{{$errors->password->has('new_password') ? ' border-red-400' : ''}}" |
| 97 | + type="password" |
| 98 | + name="new_password" |
| 99 | + /> |
| 100 | + </div> |
| 101 | + |
| 102 | + <div class="py-2"> |
| 103 | + <label for="confirm_password" class="block font-medium text-sm text-gray-700{{$errors->password->has('confirm_password') ? ' text-red-400' : ''}}">{{ __('Confirm password') }}</label> |
| 104 | + |
| 105 | + <input id="confirm_password" class="rounded-md shadow-sm border-gray-300 focus:border-indigo-300 focus:ring focus:ring-indigo-200 focus:ring-opacity-50 block mt-1 w-full{{$errors->password->has('confirm_password') ? ' border-red-400' : ''}}" |
| 106 | + type="password" |
| 107 | + name="confirm_password" |
| 108 | + /> |
| 109 | + </div> |
| 110 | + |
| 111 | + <div class="flex justify-end mt-4"> |
| 112 | + <button type='submit' class='inline-flex items-center px-4 py-2 bg-gray-800 border border-transparent rounded-md font-semibold text-xs text-white uppercase tracking-widest hover:bg-gray-700 active:bg-gray-900 focus:outline-none focus:border-gray-900 focus:ring ring-gray-300 disabled:opacity-25 transition ease-in-out duration-150'> |
| 113 | + {{ __('Change Password') }} |
| 114 | + </button> |
| 115 | + </div> |
| 116 | + </form> |
| 117 | + </div> |
| 118 | + </div> |
| 119 | + </div> |
| 120 | + </div> |
| 121 | +</x-app-layout> |
0 commit comments