138 lines
6.6 KiB
Plaintext
138 lines
6.6 KiB
Plaintext
@page "/selection"
|
|
|
|
@inject NavigationManager navigationManager
|
|
<head>
|
|
<!-- Document Title
|
|
============================================= -->
|
|
<title>Selection | TireTargets</title>
|
|
|
|
</head>
|
|
@if(!ShowWizard)
|
|
{
|
|
<div class="container">
|
|
<div class="row">
|
|
<div class="col-12 text-center mt-5">
|
|
<h4>Here are the locations associated with your account:</h4>
|
|
<div style="width:800px; margin:0 auto;">
|
|
<ul class="list-group list-group-horizontal-md">
|
|
<li class="list-group-item row w-25" style="text-align:center"><strong>ID</strong></li>
|
|
<li class="list-group-item row w-25" style="text-align:center"><strong>Location Name</strong></li>
|
|
<li class="list-group-item row w-25" style="text-align:center"><strong>Needs Selection</strong></li>
|
|
</ul>
|
|
@foreach (var current in locInfo)
|
|
{
|
|
<ul class="list-group list-group-horizontal-md">
|
|
<li class="list-group-item row w-25" style="text-align:center">@current.LocationID</li>
|
|
<li class="list-group-item row w-25" style="text-align:center">@current.LocationName</li>
|
|
<li class="list-group-item row w-25" style="text-align:center">@DoesLocIDNeedSelection(current.LocationID)</li>
|
|
<li class="list-group-item row" style="text-align:center"><input type="checkbox" @onchange="@((ChangeEventArgs c) => SelectLocation(current.LocationID))"></input></li>
|
|
</ul>
|
|
}
|
|
|
|
<TelerikButton OnClick="@ConfirmSelection">Modify Selected Locations</TelerikButton>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
|
}
|
|
else if(ShowWizard && !WizardComplete)
|
|
{
|
|
<div class="container">
|
|
<div class="row">
|
|
<div class="col-12">
|
|
<TelerikWizard OnFinish="@OnFinishHandler" Width="1440px" Height="900px">
|
|
<WizardSteps>
|
|
@*
|
|
Step 1 - Select Tire Offers
|
|
*@
|
|
<WizardStep Label="Tire Offers" Icon="@SvgIcon.Car">
|
|
<Content>
|
|
<h1>Please select your Tire Offer(s):</h1>
|
|
<TelerikButtonGroup SelectionMode="@ButtonGroupSelectionMode.Multiple">
|
|
<!-- Programatically add each valid offer to the list-->
|
|
@{
|
|
@for (int index = 0; index < availableTireOffers.Count; index++)
|
|
{
|
|
int temp = index;
|
|
<ButtonGroupToggleButton @bind-Selected="@selectedTireOffers[temp]"><img src=@availableTireOffers[temp].Item2 /></ButtonGroupToggleButton>
|
|
<p style="width:35px"></p>
|
|
@if (temp > 0 && temp % 2 == 0)
|
|
{
|
|
<br />
|
|
}
|
|
|
|
}
|
|
}
|
|
</TelerikButtonGroup>
|
|
</Content>
|
|
|
|
</WizardStep>
|
|
|
|
@*
|
|
Step 2 - Select Service Offers
|
|
*@
|
|
<WizardStep Label="Service Offers" Icon="@SvgIcon.GaugeRadial">
|
|
<Content>
|
|
<h1>Please select your Service Offer(s):</h1>
|
|
<TelerikButtonGroup SelectionMode="@ButtonGroupSelectionMode.Multiple">
|
|
<!-- Programatically add each valid offer to the list-->
|
|
@{
|
|
@for (int index = 0; index < availableServiceOffers.Count; index++)
|
|
{
|
|
int temp = index;
|
|
<ButtonGroupToggleButton @bind-Selected="@selectedServiceOffers[temp]"><img src=@availableServiceOffers[temp].Item2 /></ButtonGroupToggleButton>
|
|
<p style="width:35px"></p>
|
|
@if (temp > 0 && temp % 2 == 0)
|
|
{
|
|
<br />
|
|
}
|
|
|
|
}
|
|
}
|
|
</TelerikButtonGroup>
|
|
</Content>
|
|
</WizardStep>
|
|
|
|
@*
|
|
Step 3 - Confirm Order
|
|
*@
|
|
<WizardStep Label="Confirmation" Icon="@SvgIcon.TrackChangesAcceptAll">
|
|
<Content>
|
|
<h1>Here are your selected offers: </h1>
|
|
@{
|
|
@for (int index = 0; index < selectedTireOffers.Count; index++)
|
|
{
|
|
int temp = index;
|
|
@if (selectedTireOffers[index])
|
|
{
|
|
<img src="@availableTireOffers[temp].Item2" />
|
|
<br />
|
|
}
|
|
|
|
|
|
}
|
|
<br />
|
|
@for (int index = 0; index < selectedServiceOffers.Count; index++)
|
|
{
|
|
int temp = index;
|
|
@if (selectedServiceOffers[index])
|
|
{
|
|
<img src="@availableServiceOffers[temp].Item2" />
|
|
<br />
|
|
}
|
|
|
|
}
|
|
}
|
|
</Content>
|
|
</WizardStep>
|
|
</WizardSteps>
|
|
|
|
</TelerikWizard>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
} |