<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="de" lang="de">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
- <link rel="stylesheet" href="style.css" type="text/css"/>
+ <link rel="stylesheet" href="<%=request.getContextPath()%>/style.css" type="text/css"/>
<title><%=PizzaServiceApplication.MAIN_TITLE%> - Bestellung anzeigen</title>
</head>
<h1><%=PizzaServiceApplication.MAIN_TITLE%> - Bestellung anzeigen</h1>
</div>
- <div id="menu">
- <jsp:include page="/static/menu.jsp" flush="true" />
- </div>
+ <jsp:include page="/static/menu.jsp" flush="true" />
<div id="content_outer">
<div id="content_title">
</div>
<div id="content">
- <form action="<%=request.getContextPath()%>/form_handler/order.jsp" accept-charset="utf-8" id="form" method="post">
+ <form action="<%=request.getContextPath()%>/form_handler/do_order.jsp" accept-charset="utf-8" id="form" method="post">
<table class="table">
<thead class="table_header">
<tr>
</thead>
<tbody class="table_body">
<%
- // Get iterator from products
- Iterator<Map.Entry<String, Product>> iterator = app.getProductsIterator();
-
- // Iterate over all
- while (iterator.hasNext()) {
- // Get entry
- Map.Entry<String, Product> entry = iterator.next();
-
- // Get product
- Product product = entry.getValue();
+ // "Walk" through all products and unmark them as ordered
+ for (final Product product : app.getUnmarkedProducts(session)) {
%>
<tr>
<td>
// Is it choosen and amount set?
if (app.isProductChoosen(product, request, session)) {
// Then mark it as choosen
- product.markAsChoosen();
- app.unmarkProductAsOrdered(product, session);
+ app.markProductAsChoosen(product, session);
}
}
%>
<tr>
<td colspan="5">
- <fieldset>
+ <fieldset id="personal_data">
<legend title="Bitte geben Sie Ihre Daten ein.">Bitte Ihre Daten eingeben:</legend>
<div class="data_row">
</div>
<div class="data_right">
- <select name="gender" id="gender" size="1" <%=app.getDisabledHtmlFromSession(request, session)%>>
- <%
- // "Walk" through all genders and output them
- for (final Gender gender : Gender.values()) {
- %>
- <option value="<%=gender.name()%>"<%
- // Get gender from bean
- Gender value= customer.getGender();
-
- // Test it
- if (value.equals(gender)) {
- // Output selected="selected"
- out.print("selected=\"selected\"");
- }
- %>><%=gender%></option>
- <%
- }
- %>
- </select>
+ <jsp:include page="/static/gender_selection_box.jsp" flush="true" />
</div>
- <div class="clear"></div>
+ <div class="clear"></div>
</div>
<div class="data_row">