1 | @model HeuristicLab.Services.Optimization.Web.Models.OrderModel
|
---|
2 | @using HeuristicLab.Services.Optimization.Web.Helpers
|
---|
3 | <h2>Save your Order</h2>
|
---|
4 | <p>Following items will be purchased</p>
|
---|
5 | <table>
|
---|
6 | <thead>
|
---|
7 | <tr>
|
---|
8 | <th>Product name:</th><th>Price per Unit:</th><th>Quantity:</th><th>Total Price:</th>
|
---|
9 | </tr>
|
---|
10 | </thead>
|
---|
11 | <tbody>
|
---|
12 | @foreach (var product in Model.ProductQuantities.Keys) {
|
---|
13 | <tr>
|
---|
14 | <td>@Model.Products[product].Name</td>
|
---|
15 | <td>@Model.Products[product].Price Euro</td>
|
---|
16 | <td>@Model.ProductQuantities[product]</td>
|
---|
17 | <td>@Model.ProductSum(product) Euro</td>
|
---|
18 | </tr>
|
---|
19 | }
|
---|
20 | </tbody>
|
---|
21 | </table>
|
---|
22 | <p>Resulting in total costs of @Model.TotalSum() Euro.</p>
|
---|
23 |
|
---|
24 |
|
---|
25 |
|
---|
26 | @if (Model.User.PaymentInformation == null || Model.User.PaymentInformation.Count == 0) {
|
---|
27 | <h2>You didn't specify any payment information yet. Please click @Html.ActionLink("here", "Payment") to enter the information.</h2>
|
---|
28 | }
|
---|
29 | else {
|
---|
30 | <h2>Choose one of your payment options:</h2>
|
---|
31 | foreach (var pi in Model.User.PaymentInformation) {
|
---|
32 | <p>
|
---|
33 | @Html.Label("PaymentInformationId", string.Format("{0} ({1})", pi.PaymentMethod, pi.CardNumber))
|
---|
34 | @Html.RadioButton("PaymentInformationId", pi.PaymentInformationId)
|
---|
35 | </p>
|
---|
36 | }
|
---|
37 | <h3>Or add payment information by clicking @Html.ActionLink("here", "Payment").</h3>
|
---|
38 |
|
---|
39 | using (Html.BeginForm("SaveOrder", "Order")) {
|
---|
40 | <h2>How often would you like to be billed?</h2>
|
---|
41 | <p>
|
---|
42 | @Html.RadioButtonForEnum(m => m.BillingPeriod)
|
---|
43 | </p>
|
---|
44 | <h2>Would you like to pay upfront or at the end of the period?</h2>
|
---|
45 | <p>
|
---|
46 | @Html.RadioButtonForEnum(m => m.BillingType)
|
---|
47 | </p>
|
---|
48 | <p>
|
---|
49 | <input type="submit" value="Save order" />
|
---|
50 | </p>
|
---|
51 | }
|
---|
52 | } |
---|