Commit b9947904064f062818c36dfdc57b29b1c5ef9491

Authored by Андрей Ларионов
1 parent a873cda1eb

Коммит по вакансиям

Showing 2 changed files with 2 additions and 2 deletions Inline Diff

resources/views/employers/ajax/list_vacancy.blade.php
1 @if ($vacancy_list->count()) 1 @if ($vacancy_list->count())
2 <div class="table__scroll"> 2 <div class="table__scroll">
3 <div class="table__body table__body_min-width"> 3 <div class="table__body table__body_min-width">
4 <table> 4 <table>
5 <thead> 5 <thead>
6 <tr> 6 <tr>
7 <th>№</th> 7 <th>№</th>
8 <th>Название</th> 8 <th>Название</th>
9 <th>Дата добавления<br>/&nbsp;обновления</th> 9 <th>Дата добавления<br>/&nbsp;обновления</th>
10 <th style="display:none">Должности</th> 10 <th style="display:none">Должности</th>
11 <th>Статус</th> 11 <th>Статус</th>
12 <th>Действия</th> 12 <th>Действия</th>
13 </tr> 13 </tr>
14 </thead> 14 </thead>
15 <tbody> 15 <tbody>
16 @foreach($vacancy_list as $it) 16 @foreach($vacancy_list as $it)
17 <tr> 17 <tr>
18 <td>{{ $it->id }}</td> 18 <td>{{ $it->id }}</td>
19 <td>{{ $it->name }}</td> 19 <td>{{ $it->name }}</td>
20 <td>{{ date('d.m.Y H:i:s', strtotime($it->created_at)) }} <br>/ {{ date('d.m.Y H:i:s', strtotime($it->updated_at)) }}</td> 20 <td>{{ date('d.m.Y', strtotime($it->created_at)) }} <br>/ {{ date('d.m.Y', strtotime($it->updated_at)) }}</td>
21 <td style="display:none"> <a href="{{ route('employer.add_job_in_vac', ['ad_employer' => $it->id]) }}" class="button">Добавить</a> 21 <td style="display:none"> <a href="{{ route('employer.add_job_in_vac', ['ad_employer' => $it->id]) }}" class="button">Добавить</a>
22 22
23 @if ($it->jobs->count()) 23 @if ($it->jobs->count())
24 @foreach ($it->jobs as $key => $it_um) 24 @foreach ($it->jobs as $key => $it_um)
25 <p>@if (isset($it->jobs_code[$key])) 25 <p>@if (isset($it->jobs_code[$key]))
26 <a href="{{ route('employer.edit_job_in_vac', ['ad_job' => $it->jobs_code[$key]->id, 'ad_employer' => $it->id, 'job_title_id' => $it_um->id]) }}" style="text-decoration: underline">{{$it_um->name}}</a> 26 <a href="{{ route('employer.edit_job_in_vac', ['ad_job' => $it->jobs_code[$key]->id, 'ad_employer' => $it->id, 'job_title_id' => $it_um->id]) }}" style="text-decoration: underline">{{$it_um->name}}</a>
27 <a href="{{ route('employer.delete_job_in_vac', ['ad_job' => $it->jobs_code[$key]->id]) }}" style="text-decoration: underline">(Del)</a> 27 <a href="{{ route('employer.delete_job_in_vac', ['ad_job' => $it->jobs_code[$key]->id]) }}" style="text-decoration: underline">(Del)</a>
28 @endif 28 @endif
29 </p> 29 </p>
30 @endforeach 30 @endforeach
31 @else 31 @else
32 Нет связанных <br> с вакансией должностей 32 Нет связанных <br> с вакансией должностей
33 @endif 33 @endif
34 </td> 34 </td>
35 <td> 35 <td>
36 @if ($it->active_is) 36 @if ($it->active_is)
37 <span class="table__status green"><i></i>Опубликовано</span> 37 <span class="table__status green"><i></i>Опубликовано</span>
38 @else 38 @else
39 <span class="table__status"><i></i>Не опубликовано</span> 39 <span class="table__status"><i></i>Не опубликовано</span>
40 @endif 40 @endif
41 </td> 41 </td>
42 <td> 42 <td>
43 <span class="table__controls"> 43 <span class="table__controls">
44 <a class="table__controls-item up-it" href="{{ route('employer.vacancy_up', ['ad_employer' => $it->id]) }}"> 44 <a class="table__controls-item up-it" href="{{ route('employer.vacancy_up', ['ad_employer' => $it->id]) }}">
45 <svg> 45 <svg>
46 <use xlink:href="{{ asset('images/sprite.svg#arrow-radius') }}"></use> 46 <use xlink:href="{{ asset('images/sprite.svg#arrow-radius') }}"></use>
47 </svg> 47 </svg>
48 </a> 48 </a>
49 <a href="{{ route('employer.vacancy_edit', ['ad_employer' => $it->id]) }}" class="table__controls-item"> 49 <a href="{{ route('employer.vacancy_edit', ['ad_employer' => $it->id]) }}" class="table__controls-item">
50 <svg> 50 <svg>
51 <use xlink:href="{{ asset('images/sprite.svg#pencil') }}"></use> 51 <use xlink:href="{{ asset('images/sprite.svg#pencil') }}"></use>
52 </svg> 52 </svg>
53 </a> 53 </a>
54 <a class="table__controls-item" href="{{ route('employer.vacancy_delete', ['ad_employer' => $it->id]) }}"> 54 <a class="table__controls-item" href="{{ route('employer.vacancy_delete', ['ad_employer' => $it->id]) }}">
55 <svg> 55 <svg>
56 <use xlink:href="{{ asset('images/sprite.svg#cross') }}"></use> 56 <use xlink:href="{{ asset('images/sprite.svg#cross') }}"></use>
57 </svg> 57 </svg>
58 </a> 58 </a>
59 @if ($it->active_is) 59 @if ($it->active_is)
60 <a href="{{ route('employer.vacancy_eye', ['ad_employer' => $it->id, 'status' => 0]) }}" class="table__controls-item"> 60 <a href="{{ route('employer.vacancy_eye', ['ad_employer' => $it->id, 'status' => 0]) }}" class="table__controls-item">
61 <svg> 61 <svg>
62 <use xlink:href="{{ asset('images/sprite.svg#eye') }}"></use> 62 <use xlink:href="{{ asset('images/sprite.svg#eye') }}"></use>
63 </svg> 63 </svg>
64 </a> 64 </a>
65 @else 65 @else
66 <a href="{{ route('employer.vacancy_eye', ['ad_employer' => $it->id, 'status' => 1]) }}" class="table__controls-item"> 66 <a href="{{ route('employer.vacancy_eye', ['ad_employer' => $it->id, 'status' => 1]) }}" class="table__controls-item">
67 <svg> 67 <svg>
68 <use xlink:href="{{ asset('images/sprite.svg#eye-3') }}"></use> 68 <use xlink:href="{{ asset('images/sprite.svg#eye-3') }}"></use>
69 </svg> 69 </svg>
70 </a> 70 </a>
71 @endif 71 @endif
72 72
73 <!--<button type="button" class="table__controls-item"> 73 <!--<button type="button" class="table__controls-item">
74 <svg> 74 <svg>
75 <use xlink:href=" asset('images/sprite.svg#tg') }}"></use> 75 <use xlink:href=" asset('images/sprite.svg#tg') }}"></use>
76 </svg> 76 </svg>
77 </button> 77 </button>
78 --> 78 -->
79 </span> 79 </span>
80 </td> 80 </td>
81 </tr> 81 </tr>
82 @endforeach 82 @endforeach
83 </tbody> 83 </tbody>
84 </table> 84 </table>
85 </div><br> 85 </div><br>
86 {{ $vacancy_list->appends($_GET)->links('paginate') }} 86 {{ $vacancy_list->appends($_GET)->links('paginate') }}
87 </div> 87 </div>
88 @else 88 @else
89 89
90 <div class="notify"> 90 <div class="notify">
91 <svg> 91 <svg>
92 <use xlink:href="{{ asset('images/sprite.svg#i') }}"></use> 92 <use xlink:href="{{ asset('images/sprite.svg#i') }}"></use>
93 </svg> 93 </svg>
94 <span>Вы ещё не разместили ни одной вакансии</span> 94 <span>Вы ещё не разместили ни одной вакансии</span>
95 </div> 95 </div>
96 @endif 96 @endif
97 97
resources/views/employers/list_vacancy.blade.php
1 @extends('layout.frontend', ['title' => 'Список вакансий - РекаМоре']) 1 @extends('layout.frontend', ['title' => 'Список вакансий - РекаМоре'])
2 2
3 @section('scripts') 3 @section('scripts')
4 <script> 4 <script>
5 console.log('Test system'); 5 console.log('Test system');
6 $(document).on('change', '#sort_ajax', function() { 6 $(document).on('change', '#sort_ajax', function() {
7 var this_ = $(this); 7 var this_ = $(this);
8 var val_ = this_.val(); 8 var val_ = this_.val();
9 console.log('sort items '+val_); 9 console.log('sort items '+val_);
10 10
11 $.ajax({ 11 $.ajax({
12 type: "GET", 12 type: "GET",
13 url: "{{ route('employer.vacancy_list') }}", 13 url: "{{ route('employer.vacancy_list') }}",
14 data: "sort="+val_, 14 data: "sort="+val_,
15 success: function (data) { 15 success: function (data) {
16 console.log('Выбор сортировки'); 16 console.log('Выбор сортировки');
17 console.log(data); 17 console.log(data);
18 history.pushState({}, '', "{{ route('employer.vacancy_list') }}?sort="+val_+"@if (isset($_GET['page']))&page={{ $_GET['page'] }}@endif"); 18 history.pushState({}, '', "{{ route('employer.vacancy_list') }}?sort="+val_+"@if (isset($_GET['page']))&page={{ $_GET['page'] }}@endif");
19 $('#main_ockar').html(data); 19 $('#main_ockar').html(data);
20 }, 20 },
21 headers: { 21 headers: {
22 'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content') 22 'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
23 }, 23 },
24 error: function (data) { 24 error: function (data) {
25 data = JSON.stringify(data); 25 data = JSON.stringify(data);
26 console.log('Error: ' + data); 26 console.log('Error: ' + data);
27 } 27 }
28 }); 28 });
29 }); 29 });
30 </script> 30 </script>
31 @endsection 31 @endsection
32 32
33 @section('content') 33 @section('content')
34 <section class="cabinet"> 34 <section class="cabinet">
35 <div class="container"> 35 <div class="container">
36 <ul class="breadcrumbs cabinet__breadcrumbs"> 36 <ul class="breadcrumbs cabinet__breadcrumbs">
37 <li><a href="{{ route('index') }}">Главная</a></li> 37 <li><a href="{{ route('index') }}">Главная</a></li>
38 <li><b>Личный кабинет</b></li> 38 <li><b>Личный кабинет</b></li>
39 </ul> 39 </ul>
40 <div class="cabinet__wrapper"> 40 <div class="cabinet__wrapper">
41 <div class="cabinet__side"> 41 <div class="cabinet__side">
42 <div class="cabinet__side-toper"> 42 <div class="cabinet__side-toper">
43 43
44 @include('employers.emblema') 44 @include('employers.emblema')
45 45
46 </div> 46 </div>
47 47
48 @include('employers.menu', ['item' => 3]) 48 @include('employers.menu', ['item' => 3])
49 </div> 49 </div>
50 <div class="cabinet__body"> 50 <div class="cabinet__body">
51 <div class="cabinet__body-item"> 51 <div class="cabinet__body-item">
52 <h2 class="title cabinet__title">Мои вакансии</h2> 52 <h2 class="title cabinet__title">Мои вакансии</h2>
53 </div> 53 </div>
54 <div class="cabinet__body-item"> 54 <div class="cabinet__body-item">
55 <div class="cabinet__filters"> 55 <div class="cabinet__filters">
56 <div class="cabinet__filters-item"> 56 <div class="cabinet__filters-item">
57 <form class="search"> 57 <form class="search">
58 <input type="search" class="input" placeholder="Поиск&hellip;" required> 58 <input type="search" class="input" placeholder="Поиск&hellip;" required>
59 <button type="submit" class="button">Найти</button> 59 <button type="submit" class="button">Найти</button>
60 <span> 60 <span>
61 <svg> 61 <svg>
62 <use xlink:href="{{ asset('images/sprite.svg#search') }}"></use> 62 <use xlink:href="{{ asset('images/sprite.svg#search') }}"></use>
63 </svg> 63 </svg>
64 </span> 64 </span>
65 </form> 65 </form>
66 </div> 66 </div>
67 <div class="cabinet__filters-item"> 67 <div class="cabinet__filters-item">
68 <div class="select"> 68 <div class="select">
69 <select class="js-select2" id="sort_ajax" name="sort_ajax"> 69 <select class="js-select2" id="sort_ajax" name="sort_ajax">
70 <option value="default">Сортировка (по умолчанию)</option> 70 <option value="default">Сортировка (по умолчанию)</option>
71 <option value="name_up">По имени (возрастание)</option> 71 <option value="name_up">По имени (возрастание)</option>
72 <option value="name_down">По имени (убывание)</option> 72 <option value="name_down">По имени (убывание)</option>
73 <option value="created_at_up">По дате (возрастание)</option> 73 <option value="created_at_up">По дате (возрастание)</option>
74 <option value="created_at_down">По дате (убывание)</option> 74 <option value="created_at_down">По дате (убывание)</option>
75 </select> 75 </select>
76 </div> 76 </div>
77 </div> 77 </div>
78 </div> 78 </div>
79 79
80 <div class="table table_spoiler" id="main_ockar" name="main_oskar"> 80 <div class="table table_spoiler" id="main_ockar" name="main_oskar">
81 @if ($vacancy_list->count()) 81 @if ($vacancy_list->count())
82 <div class="table__scroll"> 82 <div class="table__scroll">
83 <div class="table__body table__body_min-width"> 83 <div class="table__body table__body_min-width">
84 <table> 84 <table>
85 <thead> 85 <thead>
86 <tr> 86 <tr>
87 <th>№</th> 87 <th>№</th>
88 <th>Название</th> 88 <th>Название</th>
89 <th>Дата добавления<br>/&nbsp;обновления</th> 89 <th>Дата добавления<br>/&nbsp;обновления</th>
90 <th style="display:none">Должности</th> 90 <th style="display:none">Должности</th>
91 <th>Статус</th> 91 <th>Статус</th>
92 <th>Действия</th> 92 <th>Действия</th>
93 </tr> 93 </tr>
94 </thead> 94 </thead>
95 <tbody> 95 <tbody>
96 @foreach($vacancy_list as $it) 96 @foreach($vacancy_list as $it)
97 <tr> 97 <tr>
98 <td>{{ $it->id }}</td> 98 <td>{{ $it->id }}</td>
99 <td>{{ $it->name }}</td> 99 <td>{{ $it->name }}</td>
100 <td>{{ date('d.m.Y H:i:s', strtotime($it->created_at)) }} <br>/ {{ date('d.m.Y H:i:s', strtotime($it->updated_at)) }}</td> 100 <td>{{ date('d.m.Y', strtotime($it->created_at)) }} <br>/ {{ date('d.m.Y', strtotime($it->updated_at)) }}</td>
101 <td style="display:none"> <a href="{{ route('employer.add_job_in_vac', ['ad_employer' => $it->id]) }}" class="button">Добавить</a> 101 <td style="display:none"> <a href="{{ route('employer.add_job_in_vac', ['ad_employer' => $it->id]) }}" class="button">Добавить</a>
102 102
103 @if ($it->jobs->count()) 103 @if ($it->jobs->count())
104 @foreach ($it->jobs as $key => $it_um) 104 @foreach ($it->jobs as $key => $it_um)
105 <p>@if (isset($it->jobs_code[$key])) 105 <p>@if (isset($it->jobs_code[$key]))
106 <a href="{{ route('employer.edit_job_in_vac', ['ad_job' => $it->jobs_code[$key]->id, 'ad_employer' => $it->id, 'job_title_id' => $it_um->id]) }}" style="text-decoration: underline">{{$it_um->name}}</a> 106 <a href="{{ route('employer.edit_job_in_vac', ['ad_job' => $it->jobs_code[$key]->id, 'ad_employer' => $it->id, 'job_title_id' => $it_um->id]) }}" style="text-decoration: underline">{{$it_um->name}}</a>
107 <a href="{{ route('employer.delete_job_in_vac', ['ad_job' => $it->jobs_code[$key]->id]) }}" style="text-decoration: underline">(Del)</a> 107 <a href="{{ route('employer.delete_job_in_vac', ['ad_job' => $it->jobs_code[$key]->id]) }}" style="text-decoration: underline">(Del)</a>
108 @endif 108 @endif
109 </p> 109 </p>
110 @endforeach 110 @endforeach
111 @else 111 @else
112 Нет связанных <br> с вакансией должностей 112 Нет связанных <br> с вакансией должностей
113 @endif 113 @endif
114 </td> 114 </td>
115 <td> 115 <td>
116 @if ($it->active_is) 116 @if ($it->active_is)
117 <span class="table__status green"><i></i>Опубликовано</span> 117 <span class="table__status green"><i></i>Опубликовано</span>
118 @else 118 @else
119 <span class="table__status"><i></i>Не опубликовано</span> 119 <span class="table__status"><i></i>Не опубликовано</span>
120 @endif 120 @endif
121 </td> 121 </td>
122 <td> 122 <td>
123 <span class="table__controls"> 123 <span class="table__controls">
124 <a class="table__controls-item up-it" href="{{ route('employer.vacancy_up', ['ad_employer' => $it->id]) }}"> 124 <a class="table__controls-item up-it" href="{{ route('employer.vacancy_up', ['ad_employer' => $it->id]) }}">
125 <svg> 125 <svg>
126 <use xlink:href="{{ asset('images/sprite.svg#arrow-radius') }}"></use> 126 <use xlink:href="{{ asset('images/sprite.svg#arrow-radius') }}"></use>
127 </svg> 127 </svg>
128 </a> 128 </a>
129 <a href="{{ route('employer.vacancy_edit', ['ad_employer' => $it->id]) }}" class="table__controls-item"> 129 <a href="{{ route('employer.vacancy_edit', ['ad_employer' => $it->id]) }}" class="table__controls-item">
130 <svg> 130 <svg>
131 <use xlink:href="{{ asset('images/sprite.svg#pencil') }}"></use> 131 <use xlink:href="{{ asset('images/sprite.svg#pencil') }}"></use>
132 </svg> 132 </svg>
133 </a> 133 </a>
134 <a class="table__controls-item" href="{{ route('employer.vacancy_delete', ['ad_employer' => $it->id]) }}"> 134 <a class="table__controls-item" href="{{ route('employer.vacancy_delete', ['ad_employer' => $it->id]) }}">
135 <svg> 135 <svg>
136 <use xlink:href="{{ asset('images/sprite.svg#cross') }}"></use> 136 <use xlink:href="{{ asset('images/sprite.svg#cross') }}"></use>
137 </svg> 137 </svg>
138 </a> 138 </a>
139 @if ($it->active_is) 139 @if ($it->active_is)
140 <a href="{{ route('employer.vacancy_eye', ['ad_employer' => $it->id, 'status' => 0]) }}" class="table__controls-item"> 140 <a href="{{ route('employer.vacancy_eye', ['ad_employer' => $it->id, 'status' => 0]) }}" class="table__controls-item">
141 <svg> 141 <svg>
142 <use xlink:href="{{ asset('images/sprite.svg#eye') }}"></use> 142 <use xlink:href="{{ asset('images/sprite.svg#eye') }}"></use>
143 </svg> 143 </svg>
144 </a> 144 </a>
145 @else 145 @else
146 <a href="{{ route('employer.vacancy_eye', ['ad_employer' => $it->id, 'status' => 1]) }}" class="table__controls-item"> 146 <a href="{{ route('employer.vacancy_eye', ['ad_employer' => $it->id, 'status' => 1]) }}" class="table__controls-item">
147 <svg> 147 <svg>
148 <use xlink:href="{{ asset('images/sprite.svg#eye-3') }}"></use> 148 <use xlink:href="{{ asset('images/sprite.svg#eye-3') }}"></use>
149 </svg> 149 </svg>
150 </a> 150 </a>
151 @endif 151 @endif
152 @if ($Employer->social_is == 1) 152 @if ($Employer->social_is == 1)
153 <a href="https://telegram.me/share/url?url={{ route('vacancie', ['vacancy' => $it->id]) }}&text={{ $it->text }}" class="table__controls-item"> 153 <a href="https://telegram.me/share/url?url={{ route('vacancie', ['vacancy' => $it->id]) }}&text={{ $it->text }}" class="table__controls-item">
154 <svg> 154 <svg>
155 <use xlink:href="{{ asset('images/sprite.svg#tg') }}"></use> 155 <use xlink:href="{{ asset('images/sprite.svg#tg') }}"></use>
156 </svg> 156 </svg>
157 </a> 157 </a>
158 @endif 158 @endif
159 <!--<a class="btn_telegram_share table__controls-item" href="https://telegram.me/share/url?url=ВАШ_URL&text={{ $it->name }}"> 159 <!--<a class="btn_telegram_share table__controls-item" href="https://telegram.me/share/url?url=ВАШ_URL&text={{ $it->name }}">
160 <svg> 160 <svg>
161 <use xlink:href=" asset('images/sprite.svg#arrow-radius') }}"></use> 161 <use xlink:href=" asset('images/sprite.svg#arrow-radius') }}"></use>
162 </svg> 162 </svg>
163 </a>--> 163 </a>-->
164 164
165 <!--<button type="button" class="table__controls-item"> 165 <!--<button type="button" class="table__controls-item">
166 <svg> 166 <svg>
167 <use xlink:href=" asset('images/sprite.svg#tg') }}"></use> 167 <use xlink:href=" asset('images/sprite.svg#tg') }}"></use>
168 </svg> 168 </svg>
169 </button> 169 </button>
170 --> 170 -->
171 </span> 171 </span>
172 </td> 172 </td>
173 </tr> 173 </tr>
174 @endforeach 174 @endforeach
175 </tbody> 175 </tbody>
176 </table> 176 </table>
177 </div><br> 177 </div><br>
178 {{ $vacancy_list->appends($_GET)->links('paginate') }} 178 {{ $vacancy_list->appends($_GET)->links('paginate') }}
179 </div> 179 </div>
180 180
181 181
182 @else 182 @else
183 183
184 <div class="notify"> 184 <div class="notify">
185 <svg> 185 <svg>
186 <use xlink:href="{{ asset('images/sprite.svg#i') }}"></use> 186 <use xlink:href="{{ asset('images/sprite.svg#i') }}"></use>
187 </svg> 187 </svg>
188 <span>Вы ещё не разместили ни одной вакансии</span> 188 <span>Вы ещё не разместили ни одной вакансии</span>
189 </div> 189 </div>
190 @endif 190 @endif
191 </div> 191 </div>
192 </div> 192 </div>
193 </div> 193 </div>
194 </div> 194 </div>
195 </div> 195 </div>
196 </section> 196 </section>
197 </div> 197 </div>
198 @endsection 198 @endsection
199 199