- Timestamp:
- 05/27/11 19:09:49 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/WebApplication/MVC2/HLWebOKBAdminPlugin/Views/Algorithm/Detail.aspx
r6304 r6317 4 4 <%@ Import Namespace="HLWebOKBAdminPlugin.OKBAdministrationService" %> 5 5 <asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server"> 6 6 Detail 7 7 </asp:Content> 8 8 <asp:Content ID="Content3" runat="server" ContentPlaceHolderID="SubMenuContent"> 9 9 <% Html.RenderAction("Menu", "Admin"); %> 10 10 </asp:Content> 11 11 <asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server"> 12 <% using(Html.BeginForm("SaveChanges", "Algorithm")) %>13 14 15 16 12 <% using (Html.BeginForm("SaveChanges", "Algorithm")) %> 13 <% { %> 14 <h2> 15 Detail</h2> 16 <% 17 17 18 19 20 21 18 // The Model will be filled via the Controller 19 // Maybe we can use here the Problem instead 20 // of the ProblemModel. But this must be changed 21 // in the Controller too! 22 22 23 Algorithm p = ((AlgorithmModel)Model).Algorithm; 24 %> 25 26 <div class="hl-menuButtons"> 27 <%: Html.ActionLink("Back to Index", "Index", null, new { @class = "hl-button-text-back" })%> 28 </div> 29 30 <table class="hl-table"> 31 <tr> 32 <th> 33 Id: 34 </th> 35 <td> 36 <%: Html.Label(p.Id.ToString())%> 37 </td> 38 <%: Html.Hidden("AlgorithmId", p.Id.ToString(), p.Id.ToString())%> 39 </tr> 40 <tr> 41 <th> 42 Name: 43 </th> 44 <td> 45 <%: Html.TextBox("AlgorithmName", p.Name, p.Name)%> 46 </td> 47 </tr> 48 <tr> 49 <th> 50 Description: 51 </th> 52 <td> 53 <%: Html.TextBox("AlgorithmDescription", p.Description, p.Description)%> 54 </td> 55 </tr> 56 <tr> 57 <th> 58 DataTypeName: 59 </th> 60 <td> 61 <%: Html.TextBox("AlgorithmDataTypeName", p.DataTypeName, p.DataTypeName)%> 62 </td> 63 </tr> 64 <tr> 65 <th> 66 Algorith Class: 67 </th> 68 <td> 69 <select name="AlgorithmClassId"> 70 <% foreach(AlgorithmClass pc in ((AlgorithmModel)Model).AlgorithmClasses) { %> 71 <% if(p.AlgorithmClassId == pc.Id) { %> 72 <option selected="selected" value="<%=pc.Id%>"><%=pc.Name%></option> 73 <% } else { %> 74 <option value="<%=pc.Id%>"><%=pc.Name%></option> 75 <% } %> 76 <% } %> 77 </select> 78 </td> 79 </tr> 80 <tr> 81 <th> 82 Platform: 83 </th> 84 <td> 85 <select name="PlatformId"> 86 <% foreach(Platform pc in ((AlgorithmModel)Model).Platforms) { %> 87 <% if(p.PlatformId == pc.Id) { %> 88 <option selected="selected" value="<%=pc.Id%>"><%=pc.Name%></option> 89 <% } else { %> 90 <option value="<%=pc.Id%>"><%=pc.Name%></option> 91 <% } %> 92 <% } %> 93 </select> 94 </td> 95 </tr> 96 <tr> 97 <th> 98 Action: 99 </th> 100 <td> 101 <input type="submit" value="save" /> 102 </td> 103 </tr> 104 </table> 105 106 <% } %> 107 108 <% using (Html.BeginForm("UploadFile", "Algorithm", FormMethod.Post, new { enctype = "multipart/form-data" })) 109 {%><br /> 110 <% Algorithm p = ((AlgorithmModel)Model).Algorithm; %> 111 <table class="hl-table"> 112 <tr> 113 <th> 114 File: 115 </th> 116 <td> 117 <%: Html.Hidden("AlgorithmId", p.Id.ToString(), p.Id.ToString())%> 118 <input type="file" name="files" id="file2" size="25" /> 119 </td> 120 </tr> 121 <tr> 122 <th> 123 Action: 124 </th> 125 <td> 126 <input type="submit" value="Upload file" /> 127 </td> 128 </tr> 129 </table> 130 131 <% } %> 132 133 23 Algorithm p = ((AlgorithmModel)Model).Algorithm; 24 %> 25 <div class="hl-menuButtons"> 26 <%: Html.ActionLink("Back to Index", "Index", null, new { @class = "hl-button-text-back" })%> 27 </div> 28 <table class="hl-table"> 29 <tr> 30 <th> 31 Id: 32 </th> 33 <td> 34 <%: Html.Label(p.Id.ToString())%> 35 </td> 36 <%: Html.Hidden("AlgorithmId", p.Id.ToString(), p.Id.ToString())%> 37 </tr> 38 <tr> 39 <th> 40 Name: 41 </th> 42 <td> 43 <%: Html.TextBox("AlgorithmName", p.Name, p.Name)%> 44 </td> 45 </tr> 46 <tr> 47 <th> 48 Description: 49 </th> 50 <td> 51 <%: Html.TextBox("AlgorithmDescription", p.Description, p.Description)%> 52 </td> 53 </tr> 54 <tr> 55 <th> 56 DataTypeName: 57 </th> 58 <td> 59 <%: Html.TextBox("AlgorithmDataTypeName", p.DataTypeName, p.DataTypeName)%> 60 </td> 61 </tr> 62 <tr> 63 <th> 64 Algorith Class: 65 </th> 66 <td> 67 <select name="AlgorithmClassId"> 68 <% foreach (AlgorithmClass pc in ((AlgorithmModel)Model).AlgorithmClasses) { %> 69 <% if (p.AlgorithmClassId == pc.Id) { %> 70 <option selected="selected" value="<%=pc.Id%>"> 71 <%=pc.Name%></option> 72 <% } else { %> 73 <option value="<%=pc.Id%>"> 74 <%=pc.Name%></option> 75 <% } %> 76 <% } %> 77 </select> 78 </td> 79 </tr> 80 <tr> 81 <th> 82 Platform: 83 </th> 84 <td> 85 <select name="PlatformId"> 86 <% foreach (Platform pc in ((AlgorithmModel)Model).Platforms) { %> 87 <% if (p.PlatformId == pc.Id) { %> 88 <option selected="selected" value="<%=pc.Id%>"> 89 <%=pc.Name%></option> 90 <% } else { %> 91 <option value="<%=pc.Id%>"> 92 <%=pc.Name%></option> 93 <% } %> 94 <% } %> 95 </select> 96 </td> 97 </tr> 98 <tr> 99 <th> 100 Action: 101 </th> 102 <td> 103 <input type="submit" value="save" /> 104 </td> 105 </tr> 106 </table> 107 <% } %> 108 <% using (Html.BeginForm("UploadFile", "Algorithm", FormMethod.Post, new { enctype = "multipart/form-data" })) {%><br /> 109 <% Algorithm p = ((AlgorithmModel)Model).Algorithm; %> 110 <table class="hl-table"> 111 <tr> 112 <th> 113 File: 114 </th> 115 <td> 116 <%: Html.Hidden("AlgorithmId", p.Id.ToString(), p.Id.ToString())%> 117 <input type="file" name="files" id="file2" size="25" /> 118 </td> 119 </tr> 120 <tr> 121 <th> 122 Action: 123 </th> 124 <td> 125 <input type="submit" value="Upload file" /> 126 </td> 127 </tr> 128 </table> 129 <% } %> 134 130 </asp:Content>
Note: See TracChangeset
for help on using the changeset viewer.