Free cookie consent management tool by TermsFeed Policy Generator

source: branches/OaaS/HeuristicLab.Services.Optimization.Web/Views/Job/Index.cshtml @ 14586

Last change on this file since 14586 was 9350, checked in by fschoepp, 12 years ago

#1888:

  • Added input parameters to the run class. They will be populated by the back-end and returned to the web pages which renders them.
  • Added a ParameterMapper class which converts HL specific model classes to OaaS independent classes. The conversion gets delegated to IParameterHandler which have to be implemented manually and registered for a certain Type before. All parameters which can be converted to IStringConvertible, IStringConvertibleMatrix, IString* will be converted into a OaaS-StringValue instance.
  • Added IParameterHandlers for PathTSPTour and PermutationType (required for TSP).
  • AlgorithmConverter now makes sure that the id of a run is unique. (All runs of a RunList will be shown now.)
  • Web pages are capable of rendering both the results of a run and their input parameters (added a accordion to wrap their content).
  • Renamed "Traveling Salesman Problem" to "Genetic Algorithm - TSP".
  • Changed js-files to render both input and result parameters of a Run.
File size: 3.8 KB
Line 
1@section customHeader {
2    <script type='text/javascript' src='@Url.Content("~/Content/job.model.js")'></script>
3    <script type='text/javascript' src='@Url.Content("~/Content/job.view.js")'></script>
4    <script type='text/javascript' src='@Url.Content("~/Content/job.controller.js")'></script>
5    <script type='text/javascript' src='@Url.Content("~/Content/moment.min.js")'></script>
6}
7
8@{
9    ViewBag.Title = "Jobs";
10}
11
12<script type="text/template" id="loadingTemplate">
13    <span><%= text %> <img src="@Url.Content("~/Content/ajax-loader.gif")" alt="Loading animation" class="hugeLoading" /> </span>
14</script>
15
16<script type="text/template" id="jobRowTemplate">
17<tr data-jobId="<%= Id%>">
18  <td><%= Id%></td>
19  <td>
20    <%= moment(DateCreated).format('YYYY-MM-DD HH:mm:ss') %>
21  </td>
22  <td><%= Name%></td>
23  <td><%= Resource%></td> 
24  <td>
25  <% if (Loading) { %>
26    <img src="@Url.Content("~/Content/ajax-loader.gif")" alt="Loading animation" class="loader" />
27  <% }%>
28  <% if (State == 0) { %>   
29  <span>Waiting...</span>
30  <% } else if (State == 1) { %>
31  <span>Calculating...</span>
32  <% } else if (State == 2) { %>
33  <img src="@Url.Content("~/Content/warning-2.png")" alt="Loading animation" class="loader" />
34  <span>Aborted</span>
35  <% } else if (State == 3) { %>
36  <img src="@Url.Content("~/Content/warning-2.png")" alt="Loading animation" class="loader" />
37  <span>Failed</span>
38  <% } else { %>
39  <img src="@Url.Content("~/Content/ok-2.png")" alt="Loading animation" class="loader" />
40  <span>Finished</span>
41  <% } %> 
42  </td>
43  <td><button type="button" data-id="<%= Id %>" data-name="DeleteButton" >Delete</Button></td>
44</tr>
45</script>
46
47<script type="text/template" id="jobHeaderTemplate">
48<thead>
49<tr>
50  <th>Id</th>
51  <th>Created</th>
52  <th>Name</th>
53  <th>Resource</th>
54  <th>State</th>
55  <td>Delete</td>
56</tr>
57</thead>
58</script>
59
60<script type="text/template" id="runTemplate">
61  <div class="accordion">
62    <h3>Results</h3>
63    <div>
64    <table>
65        <thead>
66        <tr>
67            <td>Key</td>
68            <td>Value</td>
69        </tr>
70        </thead>
71        <tbody class="results">
72        </tbody>
73    </table>
74    </div>
75    <h3>Inputs</h3>
76    <div>
77    <table>
78        <thead>
79        <tr>
80            <td>Key</td>
81            <td>Value</td>
82        </tr>
83        </thead>
84        <tbody class="inputs">
85        </tbody>
86    </table>
87    </div>
88</div>
89</script>
90
91<script type="text/template" id="runcollection_template">
92<div>
93  <span>Plot:
94    <select class="plotType"> 
95      <option>Boxplot</option>
96      <option>Bubblechart</option>
97      <option>Datatable</option>
98    </select>
99  </span>
100  <span class="choice">
101    <span>X: <select class="x"></select></span>
102    <span>Y: <select class="y"></select></span>
103  </span>
104 
105  <span class="bubble">
106    Bubble Size: <select class="bubbleSize"><option>Constant</option></select> <div class="bubbleSlider"></div>
107  </span>
108
109  <span class="datatable">
110    DataTable: <select class="datatableOptions"></select>
111    DataRow: <select class="datatableRow"></select>   
112  </span>
113  <div class="resizer" style="width: 600px">
114    <div class="plot" id="tmp">         
115    </div> 
116  </div>
117</div>
118</script>
119
120
121<script type='text/javascript'>
122$(document).ready(function () {
123    var ctrl = new OAAS_CONTROLLER.JobPageController();
124    ctrl.create();
125  });
126
127</script>
128<noscript>
129<p>
130  Please activate JavaScript to view this page correctly!
131</p>
132</noscript>
133
134<h1>Job overview</h1>
135<div id='jobOverview' style='overflow: auto; height: 450px' class='bigImage'>
136    <p>Loading jobs... Please be patient...</p>
137    <img src="@Url.Content("~/Content/ajax-loader.gif")" alt="Loading animation" class="hugeLoading" />
138</div>
139
140
141<h1>Job results</h1>
142<div id='jobDetails'></div>
143<div id='tmp'>
144</div>
Note: See TracBrowser for help on using the repository browser.