<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl" %> <%@ Import Namespace="Portoa.Web.Util" %>
<% using (Html.BeginForm(Model.ActionName, Model.ControllerName)) { %> <%= Html.HiddenFor(model => model.QuoteId, new { id = "quote-id" })%>

<%= Html.Label("Game", "GameId") %>
<%= Html.DropDownListFor(model => model.GameId, Model.GetGameList()) %> Create new game

Create new game

<%= Html.Label("Name", "GameName") %>
<%= Html.TextBox("GameName") %>

<%= Html.Label("Website", "GameWebsite") %> (link to Wikipedia page or something)
<%= Html.TextBox("GameWebsite") %>

Regions
<%= Model.MakeRegionTable() %>

Systems
<%= Model.MakeSystemTable(Html) %> Create new system
Create new system

<%= Html.Label("Name", "SystemName") %>
<%= Html.TextBox("SystemName") %>

<%= Html.Label("Abbreviation", "SystemAbbreviation") %>
<%= Html.TextBox("SystemAbbreviation")%>

<%= Html.Label("Release Date", "SystemReleaseDate") %>
<%= Html.TextBox("SystemReleaseDate", null) %>

<%= Html.Button("Create System", new { id = "create-system-submit" })%> <%= Html.Button("Cancel", new { id = "create-system-cancel" })%>
Publishers
<%= Model.MakePublisherTable(Html) %> Create new publisher
Create new publisher

<%= Html.Label("Name", "PublisherName") %>
<%= Html.TextBox("PublisherName") %>

<%= Html.Label("Website", "PublisherWebsite") %>
<%= Html.TextBox("PublisherWebsite") %>

<%= Html.Button("Create Publisher", new { id = "create-publisher-submit" })%> <%= Html.Button("Cancel", new { id = "create-publisher-cancel" })%>
<%= Html.Button("Create Game", new { id = "create-game-submit" })%> <%= Html.Button("Cancel", new { id = "create-game-cancel" })%>

<%= Html.LabelFor(model => model.QuoteText) %>
<%= Html.TextAreaFor(model => model.QuoteText) %>

<%= Html.LabelFor(model => model.CategoryIds) %>

<%= Model.MakeCategoryTable(Html) %> Create new category
<% if (Model.QuoteId > 0) { %>
<% foreach (var flag in Model.Flags) { %>

Flagged as <%: flag.Type %> on <%= flag.Created %> by <%: flag.User.Username ?? flag.User.IpAddress %>.

<%: flag.Comment %>

dismiss

<% } %>
<% } %>
<%= Html.Submit(Model.QuoteId > 0 ? "Save" : "Submit Quote") %> <% } %>