Issue 461#665
Conversation
| Route::post('api/set-search-radius', 'LocationSearchController@setSearchRadius'); | ||
| Route::post('api/add-suggestion', 'SuggestionController@addSuggestion'); | ||
| Route::get('suggestion-list/{location_id}','SuggestionController@showSuggestionList'); | ||
| Route::get('suggestion-detail/{suggestion_id}','SuggestionController@showSuggestionDetail'); |
| @section('content') | ||
| <div class="suggestion-list"> | ||
| <div class="text-center"> | ||
| <h1><a href="/location/management/my-locations">Suggesstions for {{ $name }}</a></h1> |
There was a problem hiding this comment.
Fix spelling. "Suggesstions" should be "Suggestions".
| <div class="suggestion-list"> | ||
| <div class="text-center"> | ||
| <h1><a href="/location/management/my-locations">Suggesstions for {{ $name }}</a></h1> | ||
| </div> |
| <div class="col-xs-4"> | ||
| <a href="/location/rating/{{ $location->id }}">{{ $location->name }}</a> | ||
| <div class="col-xs-3"> | ||
| <a href="/location-rating/{{ $location->id }}">{{ $location->name }}</a> |
There was a problem hiding this comment.
It looks like some rebasing mistakes were made here with route changes that got merged Tuesday. The new route for rating is "/location/rating/" instead of "/location-rating/" so your changes would break links in the My Locations page.
Test those other links on the "My Locations" list when you're done fixing.
| @section('content') | ||
| <div class="suggestion-detail"> | ||
| <div class="text-center"> | ||
| <h1>{{ $user_name }}'s <a href="/suggestion-list/{{ $suggestion->location_id }}">Suggesstion for {{ $location_name }}</a></h1> |
There was a problem hiding this comment.
Replace "Suggesstion" with "Suggestion" in suggestion_detail.blade.php.
| <div class="list-group"> | ||
| @foreach($suggestions as $suggestion) | ||
| <a href="/suggestion-detail/{{ $suggestion->id }}" class="list-group-item" title="Click to check details"> | ||
| <span class="username">Generated by: {{ $suggestion->user_name }}</span> |
There was a problem hiding this comment.
Instead of "Generated", use "Submitted". "Generated" sounds more like it was made by a machine.
| @import "_sign_in.scss"; | ||
| @import "_sign_up.scss"; | ||
| @import "_social_media_buttons.scss"; | ||
| @import "_suggestion_list.scss"; |
There was a problem hiding this comment.
I like that you followed the way the code was organized here by making files specific to each page.
| @@ -0,0 +1,28 @@ | |||
| @import "_placeholders.scss"; | |||
|
|
|||
| .suggestion-detail{ | |||
| @@ -0,0 +1,57 @@ | |||
| @extends('layouts.default') | |||
| @section('head-content') | |||
| <script src="/js/suggestion_detail.js"></script> | |||
There was a problem hiding this comment.
Swap the script elements for including suggestion_detail.js with jquery so $ is defined before you run suggestion_detail.js.
| $location = DB::table('location') | ||
| ->where('id','=',$suggestion->location_id) | ||
| ->get(['name','external_web_url','address','phone_number'])[0]; | ||
| $name = DB::table('user') |
There was a problem hiding this comment.
Just for your information, you can use the model classes to reference the tables instead of DB::table.
For example, "Location::find($location_id)"




Here are some screenshots.


