- @number?.tn
+ @number?.tn
+
+
+
+ Local Routing #
+
+ @number?.lrn
@number?.LastPorted
+
+ @number?.LIDBName
+ -
+ @number?.spid
+ @number?.lec
+ -
+ @number?.lectype
+
-
+
@number?.LIDBName
+
+ -
+ @number?.spid
+ @number?.lec
+ -
+ @number?.lectype
+
-
+
@number?.lrn
-
+
@number?.spid
- -
@number?.lec
-
@number?.lectype
@@ -132,7 +152,7 @@
-
+
-
Not Portable
+ Not Portable
-
+
@if (Model?.NotPortable is not null)
{
@@ -184,10 +204,9 @@
if (Model != null && Model?.Portable != null && Model.Portable.Any())
{
-
-
+
-
Local Numbers
+ Local Numbers
-
-
+
+
@@ -238,7 +257,6 @@
LEC
All Info
-
@if (Model?.Portable is not null)
@@ -330,7 +348,6 @@
-
}
if (Model != null && Model?.Wireless != null && Model.Wireless.Any())
@@ -339,7 +356,7 @@
-
Wireless Numbers
+
Wireless Numbers
These wireless phone numbers can be ported to our network!
-
-
+
+
@@ -478,7 +495,7 @@
-
+
@if (Model?.Portable is not null && Model.Portable.Any())
{
@Model.Portable.Count() Local Numbers
diff --git a/NumberSearch.Mvc/Views/Search/Index.cshtml b/NumberSearch.Mvc/Views/Search/Index.cshtml
index 29814cec..815c32e1 100644
--- a/NumberSearch.Mvc/Views/Search/Index.cshtml
+++ b/NumberSearch.Mvc/Views/Search/Index.cshtml
@@ -36,13 +36,13 @@
-
+
🌎 To search by area code, enter the area code and press search.
💼 To bring your number with you, enter the 10 digit number and press search.
-
🛠️ For advanced search, use * to pad your search, for example ***word to search for a number containing word, but exclude the area code.
+
🛠️ For advanced search, use * to pad your search, for example ***word to search for a number containing word, but exclude the area code.
@@ -69,21 +69,23 @@
@{
if (!string.IsNullOrWhiteSpace(Model?.Message))
{
-
-
- @if (string.IsNullOrWhiteSpace(Model?.AlertType))
- {
-
- @Model?.Message
-
- }
- else
- {
- var alertType = Model?.AlertType ?? "alert-danger";
-
- @Model?.Message
-
- }
+
+
+
+ @if (string.IsNullOrWhiteSpace(Model?.AlertType))
+ {
+
+ @Model?.Message
+
+ }
+ else
+ {
+ var alertType = Model?.AlertType ?? "alert-danger";
+
+ @Model?.Message
+
+ }
+
}
@@ -93,340 +95,355 @@
var pageResultsCount = Model.Page * 50;
var total = $"{Model?.NumberOfResults} available numbers found!";
-
-
- @if (Model?.CleanQuery is not null && Model?.Query is not null && Model.CleanQuery.Length == 10 && Model.Query.Length == 3)
- {
-
- Area code @Model.CleanQuery.Substring(0, 3) detected.
+
+
+
+
+ @if (Model?.CleanQuery is not null && Model?.Query is not null && Model.CleanQuery.Length == 10 && Model.Query.Length == 3)
+ {
+
+ Area code @Model.CleanQuery.Substring(0, 3) detected.
+
+ }
+
+ @total
+
- }
-
- @total
-
- @if (Model?.View == "Location")
- {
-
Filter by City
-
- @if (Model?.Cities is not null)
- {
- foreach (var city in Model.Cities)
- {
- if (city == Model?.City)
+ if (Model?.NumberOfResults > pageResultsCount)
{
-
+ var nextPage = Model.Page + 1;
+ if (string.IsNullOrWhiteSpace(Model?.City))
+ {
+
Next
+ }
+ else
+ {
+
Next
+ }
}
else
{
-
@city
+
Next
}
}
- }
-
- }
-
-
-
- @if (Model?.PhoneNumbers is not null)
+
+
+ @if (Model?.View == "Location")
+ {
+
+
Filter by City
+ @if (Model?.Cities is not null)
{
- var match = string.Empty;
- if (Model.CleanQuery != null && Model.CleanQuery.Contains('*'))
+ foreach (var city in Model.Cities)
{
- match = Model.CleanQuery.Substring(0, Model.CleanQuery.IndexOf('*'));
- }
- else
- {
- match = Model.CleanQuery;
+ if (city == Model?.City)
+ {
+
+ }
+ else
+ {
+
@city
+ }
}
-
- foreach (var item in Model.PhoneNumbers)
+ }
+
+ }
+
+
+
+ @if (Model?.PhoneNumbers is not null)
{
- var location = $"{item?.City ?? "Unknown City"}, {item?.State ?? "Unknown State"}";
- var formattedNumber = $"({item?.NPA}) {item?.NXX}-{item?.XXXX.ToString("0000")}";
- var number = item?.DialedNumber;
-
- if (number?.Contains(match!) ?? false)
+ var match = string.Empty;
+ if (Model.CleanQuery != null && Model.CleanQuery.Contains('*'))
{
- var start = item?.DialedNumber.IndexOf(match!) ?? 0;
- var stop = Model?.CleanQuery?.Length ?? 0;
- var beginning = item?.DialedNumber.Substring(0, start);
- var middle = (start == 0) && (stop == 10) ? Model?.CleanQuery : Model?.Query;
- var end = item?.DialedNumber.Substring(start + stop);
- number = $"{beginning}{middle} {end}";
+ match = Model.CleanQuery.Substring(0, Model.CleanQuery.IndexOf('*'));
}
-
- if (alreadyInCart is not null && item?.DialedNumber is not null && alreadyInCart.TryGetValue(item.DialedNumber, out var _))
+ else
{
-
-
- @{
- if (item.NumberType == "Standard")
- {
- Standard
- }
- else if (item.NumberType == "Premium")
- {
- Premium
- }
- else if (item.NumberType == "Executive")
- {
- Executive
- }
- else if (item.NumberType == "Tollfree")
- {
- Tollfree
- }
- }
-
- @formattedNumber
- @Html.Raw(number)
- @location
-
- @{
- if (item.Purchased)
- {
-
- Already Purchased
-
- }
- else if (alreadyInCart.TryGetValue(item.DialedNumber, out var _))
- {
-
-
- Remove
-
- }
- else
- {
-
-
- Add to Cart
-
- }
- }
-
-
+ match = Model.CleanQuery;
}
- else
+
+ foreach (var item in Model.PhoneNumbers)
{
-
-
- @{
- if (item?.NumberType == "Standard")
- {
- Standard
- }
- else if (item?.NumberType == "Premium")
- {
- Premium
- }
- else if (item?.NumberType == "Executive")
- {
- Executive
- }
- else if (item?.NumberType == "Tollfree")
- {
- Tollfree
+ var location = $"{item?.City ?? "Unknown City"}, {item?.State ?? "Unknown State"}";
+ var formattedNumber = $"({item?.NPA}) {item?.NXX}-{item?.XXXX.ToString("0000")}";
+ var number = item?.DialedNumber;
+
+ if (number?.Contains(match!) ?? false)
+ {
+ var start = item?.DialedNumber.IndexOf(match!) ?? 0;
+ var stop = Model?.CleanQuery?.Length ?? 0;
+ var beginning = item?.DialedNumber.Substring(0, start);
+ var middle = (start == 0) && (stop == 10) ? Model?.CleanQuery : Model?.Query;
+ var end = item?.DialedNumber.Substring(start + stop);
+ number = $"{beginning}{middle} {end}";
+ }
+
+ if (alreadyInCart is not null && item?.DialedNumber is not null && alreadyInCart.TryGetValue(item.DialedNumber, out var _))
+ {
+
+
+ @{
+ if (item.NumberType == "Standard")
+ {
+ Standard
+ }
+ else if (item.NumberType == "Premium")
+ {
+ Premium
+ }
+ else if (item.NumberType == "Executive")
+ {
+ Executive
+ }
+ else if (item.NumberType == "Tollfree")
+ {
+ Tollfree
+ }
}
- }
-
- @formattedNumber
- @Html.Raw(number)
- @location
-
- @{
- if (item is not null && item.Purchased)
- {
-
- Already Purchased
-
+
+ @formattedNumber
+ @Html.Raw(number)
+ @location
+
+ @{
+ if (item.Purchased)
+ {
+
+ Already Purchased
+
+ }
+ else if (alreadyInCart.TryGetValue(item.DialedNumber, out var _))
+ {
+
+
+ Remove
+
+ }
+ else
+ {
+
+
+ Add to Cart
+
+ }
}
- else if (alreadyInCart is not null && item?.DialedNumber is not null && alreadyInCart.TryGetValue(item.DialedNumber, out var _))
- {
-
-
- Remove
-
+
+
+ }
+ else
+ {
+
+
+ @{
+ if (item?.NumberType == "Standard")
+ {
+ Standard
+ }
+ else if (item?.NumberType == "Premium")
+ {
+ Premium
+ }
+ else if (item?.NumberType == "Executive")
+ {
+ Executive
+ }
+ else if (item?.NumberType == "Tollfree")
+ {
+ Tollfree
+ }
}
- else
- {
-
-
- Add to Cart
-
+
+ @formattedNumber
+ @Html.Raw(number)
+ @location
+
+ @{
+ if (item is not null && item.Purchased)
+ {
+
+ Already Purchased
+
+ }
+ else if (alreadyInCart is not null && item?.DialedNumber is not null && alreadyInCart.TryGetValue(item.DialedNumber, out var _))
+ {
+
+
+ Remove
+
+ }
+ else
+ {
+
+
+ Add to Cart
+
+ }
}
- }
-
-
+
+
+ }
}
}
- }
-
-
-
-
+
+
+
-
-
+
+
+
+
}
else if (Model != null && Model?.PhoneNumbers?.Count() == 0)
{
-
-
-
- No available numbers found!
+
+
+
+
+ No available numbers found!
+
diff --git a/NumberSearch.Mvc/Views/Shared/_Layout.cshtml b/NumberSearch.Mvc/Views/Shared/_Layout.cshtml
index 165095a4..17f814ed 100644
--- a/NumberSearch.Mvc/Views/Shared/_Layout.cshtml
+++ b/NumberSearch.Mvc/Views/Shared/_Layout.cshtml
@@ -129,10 +129,10 @@
@RenderBody()
-