Commit 3988014fe4c61baf487d2ff68e241b5f6e140461

Authored by Hayk Nazaryan
1 parent b2d6fbf843
Exists in master

fix upload images

Showing 1 changed file with 1 additions and 1 deletions Inline Diff

resources/views/employers/cabinet45.blade.php
1 @extends('layout.frontend', ['title' => 'Кабинет работодателя - РекаМоре']) 1 @extends('layout.frontend', ['title' => 'Кабинет работодателя - РекаМоре'])
2 2
3 @section('scripts') 3 @section('scripts')
4 <script src="https://cdn.ckeditor.com/ckeditor5/23.0.0/classic/ckeditor.js"></script> 4 <script src="https://cdn.ckeditor.com/ckeditor5/23.0.0/classic/ckeditor.js"></script>
5 <script> 5 <script>
6 ClassicEditor 6 ClassicEditor
7 .create( document.querySelector( '#text' ) ) 7 .create( document.querySelector( '#text' ) )
8 .catch( error => { 8 .catch( error => {
9 console.error( error ); 9 console.error( error );
10 } ); 10 } );
11 </script> 11 </script>
12 @endsection 12 @endsection
13 @section('content') 13 @section('content')
14 <section class="cabinet"> 14 <section class="cabinet">
15 <div class="container"> 15 <div class="container">
16 <ul class="breadcrumbs cabinet__breadcrumbs"> 16 <ul class="breadcrumbs cabinet__breadcrumbs">
17 <li><a href="{{ route('index') }}">Главная</a></li> 17 <li><a href="{{ route('index') }}">Главная</a></li>
18 <li><b>Личный кабинет</b></li> 18 <li><b>Личный кабинет</b></li>
19 </ul> 19 </ul>
20 <div class="cabinet__wrapper"> 20 <div class="cabinet__wrapper">
21 <div class="cabinet__side"> 21 <div class="cabinet__side">
22 <div class="cabinet__side-toper"> 22 <div class="cabinet__side-toper">
23 @include('employers.emblema') 23 @include('employers.emblema')
24 </div> 24 </div>
25 25
26 @include('employers.menu', ['item' => 1]) 26 @include('employers.menu', ['item' => 1])
27 27
28 </div> 28 </div>
29 <div class="cabinet__body"> 29 <div class="cabinet__body">
30 @include('messages_error') 30 @include('messages_error')
31 31
32 <form action="{{ route('employer.cabinet_save', ['Employer' => $Employer[0]->id]) }}" method="POST" enctype="multipart/form-data"> 32 <form action="{{ route('employer.cabinet_save', ['Employer' => $Employer[0]->id]) }}" method="POST" enctype="multipart/form-data">
33 @csrf 33 @csrf
34 <div class="cabinet__body-item"> 34 <div class="cabinet__body-item">
35 <div class="cabinet__descr"> 35 <div class="cabinet__descr">
36 <h2 class="title cabinet__title">Мой профиль</h2> 36 <h2 class="title cabinet__title">Мой профиль</h2>
37 <p class="cabinet__text">Все поля обязательны для заполнения *</p> 37 <p class="cabinet__text">Все поля обязательны для заполнения *</p>
38 </div> 38 </div>
39 <div class="cabinet__avatar"> 39 <div class="cabinet__avatar">
40 <div class="cabinet__avatar-pic"> 40 <div class="cabinet__avatar-pic">
41 @if (!empty($Employer[0]->logo)) 41 @if (!empty($Employer[0]->logo))
42 <img src="{{ asset(Storage::url($Employer[0]->logo)) }}" width="150" alt="{{ $Employer[0]->name_company }}"> 42 <img src="{{ asset(Storage::url($Employer[0]->logo)) }}" width="150" alt="{{ $Employer[0]->name_company }}">
43 @else 43 @else
44 <img src="{{ asset('images/logo_emp.png') }}" width="150" alt="{{ $Employer[0]->name_company }}"/> 44 <img src="{{ asset('images/logo_emp.png') }}" width="150" alt="{{ $Employer[0]->name_company }}"/>
45 @endif 45 @endif
46 </div> 46 </div>
47 <div class="cabinet__avatar-form"> 47 <div class="cabinet__avatar-form">
48 <label class="file"> 48 <label class="file">
49 <span class="file__input"> 49 <span class="file__input">
50 <input type="file" name="logo"> 50 <input type="file" name="logo" accept=".svg, .jpg, .png или .jpeg" capture="camera">
51 <span class="button"> 51 <span class="button">
52 <svg> 52 <svg>
53 <use xlink:href="{{ asset('images/sprite.svg#plus') }}"></use> 53 <use xlink:href="{{ asset('images/sprite.svg#plus') }}"></use>
54 </svg> 54 </svg>
55 Загрузить 55 Загрузить
56 </span> 56 </span>
57 </span> 57 </span>
58 </label> 58 </label>
59 <p class="cabinet__text">Загрузите логотип в формате .svg, .jpg, .png или .jpeg</p> 59 <p class="cabinet__text">Загрузите логотип в формате .svg, .jpg, .png или .jpeg</p>
60 </div> 60 </div>
61 </div> 61 </div>
62 <div class="cabinet__inputs"> 62 <div class="cabinet__inputs">
63 <div class="cabinet__inputs-item form-group"> 63 <div class="cabinet__inputs-item form-group">
64 <label class="form-group__label">Название судоходной компании</label> 64 <label class="form-group__label">Название судоходной компании</label>
65 <div class="form-group__item"> 65 <div class="form-group__item">
66 <input type="text" class="input" name="name_company" id="name_company" placeholder="ООО Река Море" value="{{ old('name_company') ?? $Employer[0]->name_company ?? '' }}" required> 66 <input type="text" class="input" name="name_company" id="name_company" placeholder="ООО Река Море" value="{{ old('name_company') ?? $Employer[0]->name_company ?? '' }}" required>
67 @error('name_company') 67 @error('name_company')
68 <span class="text-xs text-red-600"> 68 <span class="text-xs text-red-600">
69 {{ $message }} 69 {{ $message }}
70 </span> 70 </span>
71 @enderror 71 @enderror
72 </div> 72 </div>
73 </div> 73 </div>
74 <div class="cabinet__inputs-item form-group"> 74 <div class="cabinet__inputs-item form-group">
75 <label class="form-group__label">Электронная почта</label> 75 <label class="form-group__label">Электронная почта</label>
76 <div class="form-group__item"> 76 <div class="form-group__item">
77 <input type="email" name="email" class="input" placeholder="info@rekamore.su" value="{{ old('email') ?? $Employer[0]->email ?? '' }}" required> 77 <input type="email" name="email" class="input" placeholder="info@rekamore.su" value="{{ old('email') ?? $Employer[0]->email ?? '' }}" required>
78 @error('email') 78 @error('email')
79 <span class="text-xs text-red-600"> 79 <span class="text-xs text-red-600">
80 {{ $message }} 80 {{ $message }}
81 </span> 81 </span>
82 @enderror 82 @enderror
83 </div> 83 </div>
84 </div> 84 </div>
85 85
86 <div class="cabinet__inputs-item form-group"> 86 <div class="cabinet__inputs-item form-group">
87 <label class="form-group__label">Электронная почта (alt)</label> 87 <label class="form-group__label">Электронная почта (alt)</label>
88 <div class="form-group__item"> 88 <div class="form-group__item">
89 <input type="email" name="email_2" class="input" placeholder="info@rekamore.su" value="{{ old('email_2') ?? $Employer[0]->email_2 ?? '' }}"> 89 <input type="email" name="email_2" class="input" placeholder="info@rekamore.su" value="{{ old('email_2') ?? $Employer[0]->email_2 ?? '' }}">
90 @error('email') 90 @error('email')
91 <span class="text-xs text-red-600"> 91 <span class="text-xs text-red-600">
92 {{ $message }} 92 {{ $message }}
93 </span> 93 </span>
94 @enderror 94 @enderror
95 </div> 95 </div>
96 </div> 96 </div>
97 97
98 <div class="cabinet__inputs-item form-group"> 98 <div class="cabinet__inputs-item form-group">
99 <label class="form-group__label">Номер телефона</label> 99 <label class="form-group__label">Номер телефона</label>
100 <div class="form-group__item"> 100 <div class="form-group__item">
101 <input type="tel" name="telephone" class="input" placeholder="+7 (___) ___-__-__" value="{{ old('telephone') ?? $Employer[0]->telephone ?? '' }}" required> 101 <input type="tel" name="telephone" class="input" placeholder="+7 (___) ___-__-__" value="{{ old('telephone') ?? $Employer[0]->telephone ?? '' }}" required>
102 @error('telephone') 102 @error('telephone')
103 <span class="text-xs text-red-600"> 103 <span class="text-xs text-red-600">
104 {{ $message }} 104 {{ $message }}
105 </span> 105 </span>
106 @enderror 106 @enderror
107 </div> 107 </div>
108 </div> 108 </div>
109 109
110 <div class="cabinet__inputs-item form-group"> 110 <div class="cabinet__inputs-item form-group">
111 <label class="form-group__label">Номер телефона (alt)</label> 111 <label class="form-group__label">Номер телефона (alt)</label>
112 <div class="form-group__item"> 112 <div class="form-group__item">
113 <input type="tel" name="telephone_2" class="input" placeholder="+7 (___) ___-__-__" value="{{ old('telephone_2') ?? $Employer[0]->telephone_2 ?? '' }}"> 113 <input type="tel" name="telephone_2" class="input" placeholder="+7 (___) ___-__-__" value="{{ old('telephone_2') ?? $Employer[0]->telephone_2 ?? '' }}">
114 @error('telephone') 114 @error('telephone')
115 <span class="text-xs text-red-600"> 115 <span class="text-xs text-red-600">
116 {{ $message }} 116 {{ $message }}
117 </span> 117 </span>
118 @enderror 118 @enderror
119 </div> 119 </div>
120 </div> 120 </div>
121 121
122 <div class="cabinet__inputs-item form-group"> 122 <div class="cabinet__inputs-item form-group">
123 <label class="form-group__label">Адрес компании</label> 123 <label class="form-group__label">Адрес компании</label>
124 <div class="form-group__item"> 124 <div class="form-group__item">
125 <input type="text" name="address" class="input" value="{{ old('address') ?? $Employer[0]->address ?? '' }}" placeholder="692904, Приморский край, г. Находка, ул. Портовая 3А, 5 этаж"> 125 <input type="text" name="address" class="input" value="{{ old('address') ?? $Employer[0]->address ?? '' }}" placeholder="692904, Приморский край, г. Находка, ул. Портовая 3А, 5 этаж">
126 @error('address') 126 @error('address')
127 <span class="text-xs text-red-600"> 127 <span class="text-xs text-red-600">
128 {{ $message }} 128 {{ $message }}
129 </span> 129 </span>
130 @enderror 130 @enderror
131 </div> 131 </div>
132 </div> 132 </div>
133 <div class="cabinet__inputs-item cabinet__inputs-item_fullwidth form-group"> 133 <div class="cabinet__inputs-item cabinet__inputs-item_fullwidth form-group">
134 <label class="form-group__label">Ссылка на сайт</label> 134 <label class="form-group__label">Ссылка на сайт</label>
135 <div class="form-group__item"> 135 <div class="form-group__item">
136 <input type="url" name="site" class="input" value="{{ old('site') ?? $Employer[0]->site ?? '' }}" placeholder="https://rekamore.su"> 136 <input type="url" name="site" class="input" value="{{ old('site') ?? $Employer[0]->site ?? '' }}" placeholder="https://rekamore.su">
137 @error('site') 137 @error('site')
138 <span class="text-xs text-red-600"> 138 <span class="text-xs text-red-600">
139 {{ $message }} 139 {{ $message }}
140 </span> 140 </span>
141 @enderror 141 @enderror
142 </div> 142 </div>
143 </div> 143 </div>
144 144
145 <div class="cabinet__inputs-item cabinet__inputs-item_fullwidth form-group"> 145 <div class="cabinet__inputs-item cabinet__inputs-item_fullwidth form-group">
146 <label class="form-group__label">О компании</label> 146 <label class="form-group__label">О компании</label>
147 <div class="form-group__item"> 147 <div class="form-group__item">
148 148
149 <textarea name="text" id="txtarea" class="textarea ckeditor">{{ old('text') ?? $Employer[0]->text ?? '' }}</textarea> 149 <textarea name="text" id="txtarea" class="textarea ckeditor">{{ old('text') ?? $Employer[0]->text ?? '' }}</textarea>
150 @error('text') 150 @error('text')
151 <span class="text-xs text-red-600"> 151 <span class="text-xs text-red-600">
152 {{ $message }} 152 {{ $message }}
153 </span> 153 </span>
154 @enderror 154 @enderror
155 </div> 155 </div>
156 </div> 156 </div>
157 </div> 157 </div>
158 </div><br> 158 </div><br>
159 <button type="submit" class="button cabinet__submit">Сохранить изменения</button> 159 <button type="submit" class="button cabinet__submit">Сохранить изменения</button>
160 </form> 160 </form>
161 161
162 </div> 162 </div>
163 </div> 163 </div>
164 </div> 164 </div>
165 165
166 </section> 166 </section>
167 </div> 167 </div>
168 <!-- END TOP WRAPPER --> 168 <!-- END TOP WRAPPER -->
169 <script src="//cdn.ckeditor.com/4.14.0/standard/ckeditor.js"></script> 169 <script src="//cdn.ckeditor.com/4.14.0/standard/ckeditor.js"></script>
170 <script> 170 <script>
171 CKEDITOR.replace('txtarea'); 171 CKEDITOR.replace('txtarea');
172 //CKEDITOR.replace( 'text', { 172 //CKEDITOR.replace( 'text', {
173 // filebrowserUploadUrl: "{{route('ckeditor.image-upload', ['_token' => csrf_token() ])}}", 173 // filebrowserUploadUrl: "{{route('ckeditor.image-upload', ['_token' => csrf_token() ])}}",
174 // filebrowserImageUploadUrl: "{{ route('ckeditor.image-upload', ['_token' => csrf_token() ])}}", 174 // filebrowserImageUploadUrl: "{{ route('ckeditor.image-upload', ['_token' => csrf_token() ])}}",
175 // filebrowserUploadMethod: 'form' 175 // filebrowserUploadMethod: 'form'
176 // }); 176 // });
177 </script> 177 </script>
178 178
179 @endsection 179 @endsection
180 180