restaurant_form.blade.php_1 33 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737
  1. @extends('layouts.app')
  2. @section('css')
  3. @endsection
  4. @section('content')
  5. <link href="{!! env('APP_ASSETS') !!}vendor_components/spectrum/spectrum.css" rel="stylesheet">
  6. <link href="{!! env('APP_ASSETS') !!}vendor_components/select2/dist/css/select2.min.css" rel="stylesheet">
  7. <style>
  8. .alert {
  9. display: none;
  10. }
  11. .border-red {
  12. border: 1px solid #F00 !important;
  13. }
  14. .tab-pane{}
  15. .container-full,.content-wrapper{
  16. background-color: transparent !important;
  17. }
  18. #image-preview {
  19. width: 700px;
  20. border-radius: 20px;
  21. height: 341px;
  22. position: relative;
  23. overflow: hidden;
  24. background-color: #f9f9f9;
  25. color: #ecf0f1;
  26. background-position: center !important;
  27. background-size: cover !important;
  28. }
  29. #image-preview input {
  30. line-height: 200px;
  31. font-size: 200px;
  32. position: absolute;
  33. opacity: 0;
  34. z-index: 10;
  35. }
  36. #image-preview label {
  37. position: absolute;
  38. z-index: 5;
  39. opacity: 0.8;
  40. cursor: pointer;
  41. background-color: #bdc3c7;
  42. width: 200px;
  43. height: 50px;
  44. font-size: 20px;
  45. line-height: 50px;
  46. text-transform: uppercase;
  47. top: 0;
  48. left: 0;
  49. right: 0;
  50. bottom: 0;
  51. margin: auto;
  52. text-align: center;
  53. }
  54. .form-control, .form-select {
  55. height: 46px !important;
  56. border-color: #E4E6EB !important;
  57. border-radius: 7px !important;
  58. }
  59. .select2-container--default .select2-selection--single{
  60. height: 40px !important;
  61. border-color: #E4E6EB !important;
  62. border-radius: 7px !important;
  63. padding: 9px 12px;
  64. }
  65. </style>
  66. <div class="content-wrapper">
  67. <div class="container-full">
  68. <section class="content">
  69. @if(isset($restaurant))
  70. <h3 style="margin-left: 10px">{!! $restaurant->name !!}</h3>
  71. @endif
  72. <form id="restaurant-form" method="POST" action="{!! env('APP_URL') !!}restaurant/save"
  73. enctype="multipart/form-data">
  74. @csrf
  75. <input type="hidden" name="id" value="{!! isset($restaurant)?$restaurant->id:'' !!}"/>
  76. <div class="row">
  77. <div class="col-xl-9">
  78. <div class="card mb-4">
  79. <div class="card-body">
  80. @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
  81. <div class="row mb-4">
  82. <div class="col-sm-12">
  83. <p style="font-size: 14px">Cover Image</p>
  84. <div id="image-preview" @if(isset($restaurant) && isset($restaurant->home_images) && !empty($restaurant->home_images->file_name)) style="background: url({!! $restaurant->home_images->file_name !!})" @endif>
  85. <label for="image-upload" id="image-label">Choose File</label>
  86. <input type="file" name="home_image" id="image-upload" />
  87. </div>
  88. </div>
  89. </div>
  90. @endif
  91. <div class="row">
  92. <div class="col-sm-4 col-md-6">
  93. <div class="form-group">
  94. <label>Name (English)</label>
  95. <input type="text" class="form-control" placeholder="" name="name"
  96. value="{!! isset($restaurant)?$restaurant->name:'' !!}" required>
  97. </div>
  98. </div>
  99. </div>
  100. <div class="row">
  101. <div class="col-sm-4 col-md-6">
  102. <div class="form-group">
  103. <label>Name (Arabic)</label>
  104. <input type="text" class="form-control" placeholder="" name="arabic_name"
  105. value="{!! isset($restaurant)?$restaurant->arabic_name:'' !!}" required>
  106. </div>
  107. </div>
  108. </div>
  109. @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
  110. <div class="row">
  111. <div class="col-sm-4 col-md-6">
  112. <div class="form-group">
  113. <label>Address</label>
  114. <textarea class="form-control" placeholder="" name="address"
  115. required>{!! isset($restaurant)?$restaurant->address:'' !!}</textarea>
  116. </div>
  117. </div>
  118. </div>
  119. @endif
  120. <div class="row">
  121. @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
  122. <!-- <div class="col-sm-3 col-md-3">
  123. <div class="form-group">
  124. <label>Email</label>
  125. <input type="text" class="form-control" placeholder="" name="email"
  126. value="{!! isset($restaurant)?$restaurant->email:'' !!}">
  127. </div>
  128. </div>
  129. <div class="col-sm-3 col-md-3">
  130. <div class="form-group">
  131. <label>Phone number</label>
  132. <input type="text" class="form-control" placeholder="" name="phone_number"
  133. required value="{!! isset($restaurant)?$restaurant->phone_number:'' !!}">
  134. </div>
  135. </div> -->
  136. @endif
  137. @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
  138. @if(isset($restaurant) && $restaurant->allow_whatsapp_notifications=="1")
  139. <div class="col-sm-3 col-md-3">
  140. <div class="form-group">
  141. <label>Whatsapp number (For order notification)</label>
  142. <input type="text" class="form-control" placeholder="" name="whatsapp_number_notification"
  143. required
  144. value="{!! isset($restaurant)?$restaurant->whatsapp_number_notification:'' !!}">
  145. <!-- <p class="text-danger">In order to receive notifications on whatsapp kindly register here from mobile , <a href="https://meemapp.net/dmenu/order/meemnotif" target="_blank">https://meemapp.net/dmenu/order/meemnotif</a></p> -->
  146. </div>
  147. </div>
  148. @endif
  149. @endif
  150. </div>
  151. @php
  152. $countries = \App\Countries::whereNull('deleted_at')->get();
  153. @endphp
  154. @if(\Illuminate\Support\Facades\Auth::user()->role=="administrator")
  155. <div class="row">
  156. <div class="col-sm-3 col-md-3">
  157. <div class="form-group">
  158. <label>Country</label>
  159. <select class="form-select" required name="country_id">
  160. <option value="">Select Country</option>
  161. @if(isset($countries) && $countries->count() > 0)
  162. @foreach($countries as $country)
  163. <option value="{!! $country->id !!}" @if(isset($restaurant) && $restaurant->country_id==$country->id) selected @endif>{!! $country->country_name !!}</option>
  164. @endforeach
  165. @endif
  166. </select>
  167. </div>
  168. </div>
  169. <!-- <div class="col-sm-3 col-md-3">
  170. <div class="form-group">
  171. <label>City</label>
  172. <select class="form-select" required name="city">
  173. <option value="">Select City</option>
  174. </select>
  175. </div>
  176. </div> -->
  177. <!-- <div class="col-sm-3 col-md-3">
  178. <div class="form-group">
  179. <label>Place</label>
  180. <select class="form-select" required name="place">
  181. <option value="">Select place</option>
  182. </select>
  183. </div>
  184. </div> -->
  185. </div>
  186. @endif
  187. @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
  188. <div class="row">
  189. <div class="col-sm-2 col-md-2">
  190. <div class="form-group">
  191. <label>Default Color for Order</label><br />
  192. <input type="text" class="form-control" placeholder="" value="{!! isset($restaurant)?$restaurant->default_color:'' !!}" name="default_color" id="color">
  193. </div>
  194. </div>
  195. <div class="col-sm-12 col-md-6">
  196. <select name="time_zone" class="form-control" required>
  197. <option value="">Choose TimeZone</option>
  198. @if(isset($time_zones) && $time_zones->count() > 0)
  199. @foreach($time_zones as $timezone)
  200. <option value="{!! $timezone->timezone !!}" @if(isset($restaurant) && $restaurant->time_zone==$timezone->timezone) selected @endif>{!! $timezone->timezone !!}</option>
  201. @endforeach
  202. @endif
  203. </select>
  204. </div>
  205. </div>
  206. @endif
  207. @php
  208. $resto_metas = \App\RestoMetaDefs::where('parent_meta_def_id',0)->get();
  209. $existing_resto_meta = [];
  210. if(isset($restaurant))
  211. $existing_resto_meta = \App\RestoMetas::where('bussiness_id',$restaurant->id)->pluck('meta_def_id')->toArray();
  212. $existing_resto_meta = isset($existing_resto_meta )?$existing_resto_meta:[];
  213. $existing_resto_meta_value = null;
  214. if(isset($restaurant))
  215. $existing_resto_meta_value = \App\RestoMetas::where('bussiness_id',$restaurant->id)->get();
  216. $v = [];
  217. if(isset($existing_resto_meta_value) && $existing_resto_meta_value->count() > 0){
  218. foreach($existing_resto_meta_value as $value){
  219. $v[$value->meta_def_id] = $value->meta_val;
  220. }
  221. }
  222. @endphp
  223. @if(isset($resto_metas) && $resto_metas->count() > 0)
  224. @foreach($resto_metas as $meta)
  225. @if($meta->for_role==\Illuminate\Support\Facades\Auth::user()->role)
  226. @if(($meta->meta_def_name=="DISPLAY_TAX_INFO" || $meta->meta_def_name=="TERM_AND_CONDITIONS" ) && $restaurant->countries->country_name=="Iraq" ) @continue @endif
  227. <div class="row">
  228. <div class="col-md-12">
  229. <div class="form-group">
  230. <label>{!! str_replace('_',' ',$meta->meta_def_name) !!}</label>
  231. @if(isset($meta->childern) && $meta->childern->count() > 0)
  232. <select class="form-control" name="resto_meta[]" @if($meta->is_required=="Yes") required @endif>
  233. @foreach($meta->childern as $childern)
  234. <option value="{!! $childern->meta_def_id !!}" @if(in_array($childern->meta_def_id,$existing_resto_meta)) selected @endif>{!! $childern->meta_def_name !!}</option>
  235. @endforeach
  236. </select>
  237. @else
  238. <input type="hidden" name="resto_meta[]" value="{!! $meta->meta_def_id !!}">
  239. <input type="text" class="form-control" name="resto_meta_value[{!! $meta->meta_def_id !!}]" @if(isset($restaurant) && isset($v[$meta->meta_def_id])) value="{!! $v[$meta->meta_def_id] !!}" @endif @if($meta->is_required=="Yes") required @endif placeholder="{!! $meta->meta_def_desc !!}">
  240. @endif
  241. </div>
  242. </div>
  243. </div>
  244. @endif
  245. @endforeach
  246. @endif
  247. </div>
  248. </div>
  249. <div class="card card-body mb-4">
  250. @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
  251. <div class="row">
  252. <div class="col-sm-4 col-md-6">
  253. <div class="form-group">
  254. <label>Logo</label>
  255. <input type="file" class="form-control" placeholder=""
  256. accept="image/x-png,image/jpeg" name="logo">
  257. <span class="text-danger m-1">Note* Please use jpg or png images</span>
  258. </div>
  259. @if(isset($restaurant) && isset($restaurant->photos))
  260. <div class="col-2">
  261. <img src="{!! $restaurant->photos->file_name !!}"
  262. class="img-fluid mb-2" alt="{!! $restaurant->name !!}">
  263. </div>
  264. @endif
  265. </div>
  266. </div>
  267. @endif
  268. @if(\Illuminate\Support\Facades\Auth::user()->role=="restaurant")
  269. @if(isset($restaurant))
  270. <div class="row mb-4">
  271. <div class="col-md-3">
  272. <div class="text-center">
  273. <p class="mt-4"><a href="{!! env('QRCODE_HOST_ORDER') !!}d/{!! $restaurant->resto_unique_name !!}" target="_blank">{!! env('QRCODE_HOST_ORDER') !!}d/{!! $restaurant->resto_unique_name !!}</a></p>
  274. </div>
  275. </div>
  276. </div>
  277. @endif
  278. @endif
  279. <div class="row">
  280. <div class="col-sm-4 col-md-6">
  281. @if(\Illuminate\Support\Facades\Auth::User()->role=="administrator")
  282. <div class="form-group">
  283. <div class="custom-control custom-checkbox">
  284. <input class="custom-control-input" id="active"
  285. @if(isset($restaurant) && $restaurant->active=="1") checked
  286. @endif name="active" type="checkbox"/>
  287. <label class="custom-control-label" for="active">Active</label>
  288. </div>
  289. </div>
  290. @endif
  291. @if(\Illuminate\Support\Facades\Auth::User()->role=="administrator")
  292. <div class="form-group">
  293. <div class="custom-control custom-checkbox">
  294. <input class="custom-control-input" id="allow_whatsapp_notifications"
  295. @if(isset($restaurant) && $restaurant->allow_whatsapp_notifications=="1") checked
  296. @endif name="allow_whatsapp_notifications" type="checkbox"/>
  297. <label class="custom-control-label" for="allow_whatsapp_notifications">Allow whatsapp notifications</label>
  298. </div>
  299. </div>
  300. @endif
  301. </div>
  302. </div>
  303. </div>
  304. <div class="row">
  305. <div class="col-sm-12">
  306. <div class="card card-body mb-4">
  307. <div class="row">
  308. <div class="col-sm-12">
  309. <a href="#!" class="btn btn-primary save"><i class="feather-save mr-1"></i> Save</a>
  310. <!-- @if( isset($restaurant))
  311. <a href="#!" class="btn btn-primary upload-gallery"><i
  312. class="feather-image mr-1"></i> Upload Gallery</a>
  313. @endif -->
  314. </div>
  315. </div>
  316. <div class="row mt-2">
  317. <div class="col-md-12">
  318. <div class="alert alert-success success"></div>
  319. <div class="alert alert-danger error"></div>
  320. </div>
  321. </div>
  322. </div>
  323. </div>
  324. </div>
  325. </div>
  326. </div>
  327. </form>
  328. </section>
  329. </div>
  330. </div>
  331. @if( isset($restaurant))
  332. <div class="modal" id="upload-gallery" tabindex="-1" role="dialog">
  333. <div class="modal-dialog modal-lg" role="document">
  334. <div class="modal-content">
  335. <div class="modal-header">
  336. <h5 class="modal-title">Resto Gallery</h5>
  337. <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  338. <span aria-hidden="true">&times;</span>
  339. </button>
  340. </div>
  341. <div class="modal-body">
  342. <div class="row">
  343. <div class="col-sm-12 col-md-12">
  344. <div class="form-group">
  345. <label>Gallery</label>
  346. <div class="dropzone dz-clickable" id="gallery">
  347. <div class="dz-default dz-message" data-dz-message="">
  348. <span>Drop files here to upload</span>
  349. </div>
  350. </div>
  351. </div>
  352. </div>
  353. </div>
  354. </div>
  355. <div class="modal-footer">
  356. <button type="button" class="btn btn-primary upload">Upload</button>
  357. <button type="button" class="btn btn-secondary" data-dismiss="modal">Close</button>
  358. </div>
  359. </div>
  360. </div>
  361. </div>
  362. @endif
  363. @endsection
  364. @section('js')
  365. <script src="{!! env('APP_ASSETS') !!}vendor_components/spectrum/spectrum.js"></script>
  366. <script src="{!! env('APP_ASSETS') !!}vendor_components/select2/dist/js/select2.min.js"></script>
  367. <script>
  368. $(function () {
  369. $("select[name=time_zone]").select2();
  370. $("#color").spectrum({
  371. preferredFormat: "hex",
  372. color: "{!! isset($restaurant->default_color)?$restaurant->default_color:"#F00" !!}",
  373. showInput: true,
  374. });
  375. $.uploadPreview({
  376. input_field: "#image-upload", // Default: .image-upload
  377. preview_box: "#image-preview", // Default: .image-preview
  378. label_field: "#image-label", // Default: .image-label
  379. label_default: "Choose File", // Default: Choose File
  380. label_selected: "Change File", // Default: Change File
  381. no_label: true ,
  382. success_callback: function() {
  383. }// Default: false
  384. });
  385. $("body").on("click",".delete-delivery-fee",function () {
  386. var id = $(this).data('id');
  387. var _this = $(this);
  388. $.ajax({
  389. url:"{!! env('APP_URL') !!}delete/save/delivery/fee/"+id,
  390. success:function () {
  391. //_this.parents('tr').remove();
  392. location.reload();
  393. }
  394. });
  395. });
  396. $("body").on("change","select[name=country_id]",function () {
  397. var id = $(this).val();
  398. $("select[name=city_id]").html('');
  399. $.ajax({
  400. url:"{!! env('APP_URL') !!}get/city/by/country/"+id,
  401. success:function (response) {
  402. response = $.parseJSON(response);
  403. var str = "";
  404. $.each(response,function (i,v) {
  405. str+='<option value="'+v.id+'">'+v.name+'</option>'
  406. });
  407. $("select[name=city]").append(str);
  408. @if(isset($restaurant))
  409. $( "select[name=city]" ).val("{!! $restaurant->city !!}");
  410. @endif
  411. }
  412. });
  413. });
  414. setTimeout(function () {
  415. $("body").on("change","select[name=city]",function () {
  416. var id = $(this).val();
  417. $("select[name=place]").html('');
  418. $.ajax({
  419. url:"{!! env('APP_URL') !!}get/place/by/city/"+id,
  420. success:function (response) {
  421. response = $.parseJSON(response);
  422. var str = '<option value="">Choose Place</option>';
  423. $.each(response,function (i,v) {
  424. str+='<option value="'+v.id+'">'+v.place_name+'</option>'
  425. });
  426. $("select[name=place]").append(str);
  427. @if(isset($restaurant))
  428. $( "select[name=place]" ).val("{!! $restaurant->place !!}");
  429. @endif
  430. }
  431. });
  432. });
  433. },1000);
  434. @if(isset($restaurant))
  435. $( "select[name=country_id]" ).trigger( "change" );
  436. setTimeout(function () {
  437. $("select[name=city]").trigger("change");
  438. },1000);
  439. $("body").on("click", ".map-category-resto", function () {
  440. var categories = $(".default-category");
  441. var price_array = [];
  442. var category_array = [];
  443. var price = $(".default-price");
  444. $.each(categories, function () {
  445. category_array.push($(this).val());
  446. });
  447. $.each(price, function () {
  448. price_array.push($(this).val());
  449. });
  450. $.ajax({
  451. url: "{!! env('APP_URL') !!}map/category/resto",
  452. type: "POST",
  453. data: {
  454. price: price_array,
  455. categories: category_array,
  456. resto_id: "{!! $restaurant->id !!}",
  457. "_token": "{!! csrf_token() !!}"
  458. },
  459. success: function (response) {
  460. }
  461. });
  462. });
  463. @endif
  464. $("#choose-categories").select2().on("change", function () {
  465. var data = ($('#choose-categories').select2('data'));
  466. if (data) {
  467. var str = "";
  468. $.each(data, function (i, v) {
  469. str += "<tr>";
  470. str += "<td>" + v.text + "</td>";
  471. str += '<td><input type="hidden" name="category[]" class="default-category" value="' + v.id + '" /><input type="text" class="form-control default-price" name="price[]" /> </td>';
  472. str += "</tr>"
  473. });
  474. $("#table-default-price tbody").html(str);
  475. }
  476. });
  477. $("body").on("click", ".edit-fee", function () {
  478. var id = $(this).data('id');
  479. });
  480. $("body").on("click", ".save-delivery-fee", function () {
  481. $(this).parents('.tab-pane').find("form").ajaxForm(function (response) {
  482. response = $.parseJSON(response);
  483. if (response) {
  484. if (response.type == "success") {
  485. $('#delivery-fee-modal .alert.success').html(response.message);
  486. $('#delivery-fee-modal .alert.success').show();
  487. setTimeout(function () {
  488. location.reload();
  489. }, 2000)
  490. } else {
  491. $('#special-offers .alert.error').html(response.message);
  492. $('#special-offers .alert.error').show();
  493. }
  494. }
  495. }).submit();
  496. });
  497. $("body").on("click", ".add-delivery-fee", function () {
  498. $("#delivery-fee-modal").modal();
  499. });
  500. $("body").on("change", ".country_id", function () {
  501. var _this = $(this);
  502. var code = $(this).val();
  503. _this.parents('.delivery-fee-item').find('.city').html('');
  504. $.ajax({
  505. url: "{!! env('APP_URL') !!}get/cities/by/country/" + code,
  506. success: function (response) {
  507. response = $.parseJSON(response);
  508. var str = '<option value="">Choose City</option>';
  509. _this.parents('.delivery-fee-item').find(".city").html(str);
  510. if (response) {
  511. $.each(response, function (i, v) {
  512. str += '<option value="' + v.city + '">' + v.city + '</option>';
  513. });
  514. _this.parents('.delivery-fee-item').find(".city").html(str);
  515. }
  516. }
  517. });
  518. });
  519. $("body").on("change", ".city", function () {
  520. var name = $(this).val();
  521. var _this = $(this);
  522. $.ajax({
  523. url: "{!! env('APP_URL') !!}get/places/by/city/" + name,
  524. success: function (response) {
  525. response = $.parseJSON(response);
  526. var str = '<option value="">Choose place</option>';
  527. _this.parents('.delivery-fee-item').find(".place").html(str);
  528. if (response) {
  529. $.each(response, function (i, v) {
  530. str += '<option value="' + v.city_unique_id + '" data-category="' + v.category + '">' + v.city_name + '</option>';
  531. });
  532. _this.parents('.delivery-fee-item').find(".place").html(str);
  533. }
  534. }
  535. });
  536. });
  537. $("body").on("change", ".make_active", function () {
  538. var value = $(this).val();
  539. var resto_id = $(this).data('resto-id');
  540. if ($(this).is(":checked")) {
  541. $.ajax({
  542. url: "{!! env('APP_URL') !!}offer/make/active",
  543. type: "POST",
  544. data: {
  545. id: value,
  546. resto_id: resto_id,
  547. "_token": "{!! csrf_token() !!}"
  548. },
  549. success: function (response) {
  550. }
  551. });
  552. }
  553. });
  554. $("body").on('click', '.save', function () {
  555. if ($("#restaurant-form").valid()) {
  556. $("#restaurant-form").ajaxForm(function (response) {
  557. response = $.parseJSON(response);
  558. if (response) {
  559. if (response.type == "success") {
  560. $('#restaurant-form .alert.success').html(response.message);
  561. $('#restaurant-form .alert.success').show();
  562. setTimeout(function () {
  563. @if(\Illuminate\Support\Facades\Auth::user()->role=="administrator" )
  564. window.location = '{!! env('APP_URL') !!}businesses';
  565. @else
  566. location.reload();
  567. @endif
  568. }, 2000)
  569. } else {
  570. $('#restaurant-form .alert.error').html(response.message);
  571. $('#restaurant-form .alert.error').show();
  572. }
  573. }
  574. }).submit();
  575. }
  576. });
  577. })
  578. </script>
  579. @endsection