Complete public search (#5)
- Bump version - Define nav between profile and continent/skills - Remove redundant code
This commit is contained in:
@@ -23,10 +23,13 @@
|
||||
<br>
|
||||
@if (SearchResults.Any())
|
||||
{
|
||||
<p>
|
||||
These profiles match your search criteria. To learn more about these people, join the merry band of human
|
||||
resources in the <a href="https://noagendashow.net" target="_blank">No Agenda</a> tribe!
|
||||
</p>
|
||||
<table class="table table-sm table-hover">
|
||||
<thead>
|
||||
<tr>
|
||||
<th scope="col">Profile</th>
|
||||
<th scope="col">Continent</th>
|
||||
<th scope="col" class="text-center">Region</th>
|
||||
<th scope="col" class="text-center">Remote?</th>
|
||||
@@ -37,12 +40,15 @@
|
||||
@foreach (var profile in SearchResults)
|
||||
{
|
||||
<tr>
|
||||
<td><a href="/profile/bio/@profile.CitizenId">View</a></td>
|
||||
<td class=@IsSeeking(profile)>@profile.DisplayName</td>
|
||||
<td class="text-center">@YesOrNo(profile.SeekingEmployment)</td>
|
||||
<td>@profile.Continent</td>
|
||||
<td>@profile.Region</td>
|
||||
<td class="text-center">@YesOrNo(profile.RemoteWork)</td>
|
||||
<td class="text-center">@YesOrNo(profile.FullTime)</td>
|
||||
<td><FullDate TheDate=@profile.LastUpdated /></td>
|
||||
<td>
|
||||
@foreach (var skill in profile.Skills)
|
||||
{
|
||||
@skill.Replace(" ()", "")<br>
|
||||
}
|
||||
</td>
|
||||
</tr>
|
||||
}
|
||||
</tbody>
|
||||
|
||||
@@ -39,7 +39,7 @@ namespace JobsJobsJobs.Client.Pages.Profiles
|
||||
/// <summary>
|
||||
/// The search results
|
||||
/// </summary>
|
||||
private IEnumerable<ProfileSearchResult> SearchResults { get; set; } = Enumerable.Empty<ProfileSearchResult>();
|
||||
private IEnumerable<PublicSearchResult> SearchResults { get; set; } = Enumerable.Empty<PublicSearchResult>();
|
||||
|
||||
protected override async Task OnInitializedAsync()
|
||||
{
|
||||
@@ -72,7 +72,7 @@ namespace JobsJobsJobs.Client.Pages.Profiles
|
||||
{
|
||||
var query = SearchQuery();
|
||||
query.Add("Searched", "True");
|
||||
nav.NavigateTo(QueryHelpers.AddQueryString("/profile/search", query));
|
||||
nav.NavigateTo(QueryHelpers.AddQueryString("/profile/seeking", query));
|
||||
await RetrieveProfiles();
|
||||
}
|
||||
|
||||
@@ -83,8 +83,8 @@ namespace JobsJobsJobs.Client.Pages.Profiles
|
||||
{
|
||||
Searching = true;
|
||||
|
||||
var searchResult = await ServerApi.RetrieveMany<ProfileSearchResult>(http,
|
||||
QueryHelpers.AddQueryString("profile/search", SearchQuery()));
|
||||
var searchResult = await ServerApi.RetrieveMany<PublicSearchResult>(http,
|
||||
QueryHelpers.AddQueryString("profile/public-search", SearchQuery()));
|
||||
|
||||
if (searchResult.IsOk)
|
||||
{
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
</div>
|
||||
|
||||
|
||||
@if (Profile.Skills.Length > 0)
|
||||
@if (Profile.Skills.Count > 0)
|
||||
{
|
||||
<hr>
|
||||
<h4>Skills</h4>
|
||||
|
||||
Reference in New Issue
Block a user