[13860] | 1 |
|
---|
[13689] | 2 |
|
---|
[13739] | 3 | @model HeuristicLab.Clients.Hive.WebJobManager.ViewModels.FileOpeningViewModel
|
---|
[13689] | 4 |
|
---|
[13827] | 5 | <!-- Displays the contents of a file -->
|
---|
| 6 | <!-- Another body used for the side scroller menu-->
|
---|
[13735] | 7 | <body id="top"
|
---|
[13860] | 8 | class="row "
|
---|
[13733] | 9 | data-spy="scroll"
|
---|
| 10 | data-target="#scrolly"
|
---|
| 11 | data-offset-top="500"
|
---|
| 12 | onscroll="showScrolly()"
|
---|
| 13 | style="margin-bottom:500px;margin-left:1px;margin-right:1px;">
|
---|
[13739] | 14 | <div id="userId" style="display:none">@ViewBag.SessionId</div>
|
---|
[13827] | 15 | <!-- Main nav menu -->
|
---|
[13862] | 16 | @Html.Partial("Navbar", new HeuristicLab.Clients.Hive.WebJobManager.ViewModels.NavbarViewModel("Job", Model.User))
|
---|
[13733] | 17 |
|
---|
[13827] | 18 | <!-- Job menu-->
|
---|
[13733] | 19 | <ul class="nav nav-pills nav-justified">
|
---|
| 20 | <li role="presentation"
|
---|
| 21 | class="">
|
---|
| 22 | <a asp-controller="Job"
|
---|
| 23 | asp-action="Index">
|
---|
[13742] | 24 | <i class="fa fa-tasks"></i> Jobs
|
---|
[13733] | 25 | </a>
|
---|
| 26 | </li>
|
---|
| 27 | <li role="presentation"
|
---|
| 28 | class="active">
|
---|
| 29 | <a asp-controller="Job"
|
---|
| 30 | asp-action="Uploads">
|
---|
[13742] | 31 | <i class="fa fa-cloud"></i> Uploads
|
---|
[13733] | 32 | </a>
|
---|
| 33 | </li>
|
---|
[13689] | 34 | </ul>
|
---|
[13827] | 35 | <!-- Back button -->
|
---|
[13733] | 36 | <div class="row"
|
---|
| 37 | style="margin-left:20px">
|
---|
| 38 | <a class="btn btn-default"
|
---|
| 39 | asp-controller="Job"
|
---|
| 40 | asp-action="Uploads">
|
---|
| 41 | <i class="fa fa-angle-double-left"></i> Back to uploads
|
---|
| 42 | </a>
|
---|
| 43 | </div>
|
---|
[13847] | 44 | @Html.Partial("OpenFilePartials/_Help", Model)
|
---|
[13827] | 45 | <!-- Check model to select right partial, partial handles all subloading -->
|
---|
[13847] | 46 | <div class="col-sm-9">
|
---|
[13733] | 47 | @if (Model.SelectedAlgorithm != null)
|
---|
| 48 | {
|
---|
| 49 | @Html.Partial("OpenFilePartials/_Algorithm", Model);
|
---|
[13689] | 50 |
|
---|
[13733] | 51 | }
|
---|
| 52 | else if (Model.SelectedBatchRun != null)
|
---|
| 53 | {
|
---|
| 54 | @Html.Partial("OpenFilePartials/_BatchRun", Model);
|
---|
[13689] | 55 |
|
---|
[13733] | 56 | }
|
---|
| 57 | else if (Model.SelectedExperiment != null)
|
---|
| 58 | {
|
---|
| 59 | @Html.Partial("OpenFilePartials/_Experiment", Model);
|
---|
[13689] | 60 |
|
---|
[13733] | 61 | }
|
---|
[13827] | 62 | <!-- Main menu for job creation -->
|
---|
[13733] | 63 | <hr style="border-color:gray; margin-top:50px" />
|
---|
[13827] | 64 | <div class="row">
|
---|
| 65 | <div id="finish" class="col-sm-8"
|
---|
| 66 | style="text-align:center; border-right:1px solid">
|
---|
| 67 | <h2>
|
---|
| 68 | Hive job information
|
---|
| 69 | </h2>
|
---|
| 70 | <div class="row"
|
---|
| 71 | style="margin-bottom:20px">
|
---|
[13733] | 72 |
|
---|
[13827] | 73 | <div class="col-sm-6"
|
---|
| 74 | style="text-align:right">
|
---|
| 75 | <h5>Job name</h5>
|
---|
| 76 | </div>
|
---|
| 77 | <div class="col-sm-6"
|
---|
| 78 | style="text-align:left">
|
---|
| 79 | <div class="form-group">
|
---|
| 80 | <div class="input-group">
|
---|
| 81 | <input type="text"
|
---|
| 82 | class="form-control"
|
---|
| 83 | name="jname"
|
---|
| 84 | id="jname"
|
---|
| 85 | placeholder="Job name">
|
---|
| 86 | </div>
|
---|
[13733] | 87 | </div>
|
---|
| 88 | </div>
|
---|
| 89 | </div>
|
---|
[13827] | 90 | <div class="row"
|
---|
| 91 | style="margin-bottom:20px">
|
---|
| 92 | <div class="col-sm-6"
|
---|
| 93 | style="text-align:right">
|
---|
| 94 | <h5>
|
---|
| 95 | Resources (optional)
|
---|
| 96 | </h5>
|
---|
| 97 | </div>
|
---|
| 98 | <div class="col-sm-6"
|
---|
| 99 | style="text-align:left">
|
---|
| 100 | <div class="form-group">
|
---|
| 101 | <div class="input-group">
|
---|
| 102 | <input type="text"
|
---|
| 103 | class="form-control"
|
---|
| 104 | name="jresource"
|
---|
| 105 | id="jresource"
|
---|
| 106 | placeholder="(seperate with ;)">
|
---|
| 107 | </div>
|
---|
[13733] | 108 | </div>
|
---|
| 109 | </div>
|
---|
| 110 | </div>
|
---|
| 111 |
|
---|
[13827] | 112 | <div class="row">
|
---|
| 113 | <h5 class="col-sm-6"
|
---|
| 114 | style="text-align:right;margin-top:20px">
|
---|
| 115 | Set global job priority
|
---|
| 116 | </h5>
|
---|
| 117 | <div class="col-sm-6">
|
---|
| 118 | <div class="btn-group pull-left"
|
---|
| 119 | style="margin:10px; box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
|
---|
[13733] | 120 | text-shadow:2px 2px black;">
|
---|
[13827] | 121 | <button type="button"
|
---|
| 122 | id="prior"
|
---|
| 123 | class="btn btn-info dropdown-toggle"
|
---|
| 124 | data-toggle="dropdown"
|
---|
| 125 | aria-haspopup="true" aria-expanded="false">
|
---|
| 126 | Normal <span class="caret"></span>
|
---|
| 127 | </button>
|
---|
| 128 | <ul class="dropdown-menu"
|
---|
| 129 | style="text-shadow:none">
|
---|
| 130 | <li><a onclick="changePriority([],0,'')">Low</a></li>
|
---|
| 131 | <li><a onclick="changePriority([],1,'')">Normal</a></li>
|
---|
| 132 | <li><a onclick="changePriority([],2,'')">Urgent</a></li>
|
---|
| 133 | <li><a onclick="changePriority([],3,'')">Critical</a></li>
|
---|
| 134 | </ul>
|
---|
| 135 | </div>
|
---|
[13733] | 136 | </div>
|
---|
| 137 | </div>
|
---|
| 138 |
|
---|
[13827] | 139 | <!-- adding the job to hive and show progress bar -->
|
---|
| 140 | <a class="btn btn-lg btn-success"
|
---|
| 141 | id="fakehiveadd"
|
---|
| 142 | onclick="addtoHive()"
|
---|
| 143 | style="margin:10px; box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
|
---|
[13733] | 144 | text-shadow:2px 2px black;">
|
---|
[13827] | 145 | Add this job to Hive
|
---|
| 146 | </a>
|
---|
| 147 | <!-- HIDDEN BUTTON FOR ASP ACTION -->
|
---|
| 148 | <a class="btn btn-success "
|
---|
| 149 | id="realhiveadd"
|
---|
| 150 | asp-controller="Job"
|
---|
| 151 | asp-action="AddToHive"
|
---|
| 152 | style="display:none"></a>
|
---|
[13733] | 153 |
|
---|
[13827] | 154 | <!-- Progress-->
|
---|
[13844] | 155 |
|
---|
[13827] | 156 | <h4 id="result" style="display:none">Start uploading experiment...</h4>
|
---|
| 157 | <div class="progress" id="progdiv" style="display:none">
|
---|
[13733] | 158 |
|
---|
[13827] | 159 | <div class="progress-bar progress-bar-success progress-bar-striped active" role="progressbar"
|
---|
| 160 | id="progress"
|
---|
| 161 | aria-valuenow="0" aria-valuemin="0" aria-valuemax="100" style="width:10%">
|
---|
[13733] | 162 |
|
---|
[13827] | 163 | </div>
|
---|
[13733] | 164 | </div>
|
---|
| 165 | </div>
|
---|
[13827] | 166 | <div class="col-sm-4">
|
---|
[13841] | 167 | <h3 style="text-align:center">Save to file</h3>
|
---|
| 168 | <p style="text-align:center;font-style:italic">Changed parameters get saved but child distribution and task priority get lost in the process.</p>
|
---|
[13827] | 169 | <form asp-controller="Job"
|
---|
[13844] | 170 | asp-action="saveToFile"
|
---|
[13827] | 171 | method="post">
|
---|
[13847] | 172 | <div class="row">
|
---|
| 173 | <div class="col-sm-3"
|
---|
| 174 | style="text-align:right">
|
---|
| 175 | <h5>File name</h5>
|
---|
| 176 | </div>
|
---|
| 177 | <div class="col-sm-9"
|
---|
| 178 | style="text-align:left">
|
---|
| 179 | <div class="form-group">
|
---|
| 180 | <div class="input-group">
|
---|
| 181 | <input type="text"
|
---|
| 182 | class="form-control"
|
---|
| 183 | name="fname"
|
---|
| 184 | id="fname"
|
---|
| 185 | required
|
---|
| 186 | placeholder="File name">
|
---|
| 187 | </div>
|
---|
| 188 | </div>
|
---|
| 189 | </div>
|
---|
[13827] | 190 | </div>
|
---|
[13847] | 191 | <div class="row">
|
---|
| 192 | <div class="col-sm-3"
|
---|
| 193 | style="text-align:right">
|
---|
| 194 | <h5>Directory name</h5>
|
---|
| 195 | </div>
|
---|
| 196 | <div class="col-sm-9"
|
---|
| 197 | style="text-align:left">
|
---|
| 198 | <div class="form-group">
|
---|
| 199 | <div class="input-group">
|
---|
| 200 | <input type="text"
|
---|
| 201 | class="form-control"
|
---|
| 202 | name="dname"
|
---|
| 203 | id="dname"
|
---|
| 204 | required
|
---|
| 205 | placeholder="Directory name"
|
---|
| 206 | list="dirnames">
|
---|
| 207 | </div>
|
---|
| 208 | <datalist id="dirnames">
|
---|
| 209 | @if (!Model.directories.Contains(DateTime.Now.ToString("yyyy.MM.dd")))
|
---|
| 210 | {
|
---|
| 211 | <option value="@(DateTime.Now.ToString("yyyy.MM.dd"))">Creates new directory for today</option>
|
---|
| 212 | }
|
---|
| 213 | @foreach (var d in Model.directories)
|
---|
| 214 | {
|
---|
| 215 | <option value="@d"></option>
|
---|
| 216 | }
|
---|
| 217 | </datalist>
|
---|
[13827] | 218 | </div>
|
---|
| 219 | </div>
|
---|
| 220 | </div>
|
---|
[13844] | 221 | <button class="btn btn-success btn-block" type="submit"
|
---|
[13827] | 222 | style="margin:10px; box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
|
---|
| 223 | text-shadow:2px 2px black;">
|
---|
[13844] | 224 | Save to file
|
---|
| 225 | </button>
|
---|
[13827] | 226 | </form>
|
---|
| 227 | </div>
|
---|
[13733] | 228 | </div>
|
---|
| 229 |
|
---|
| 230 |
|
---|
| 231 | </div>
|
---|
[13827] | 232 | <!-- Side scrolling menu-->
|
---|
[13847] | 233 | <nav class="col-sm-2" id="scrolly">
|
---|
[13733] | 234 | <ul class="nav nav-pills nav-stacked"
|
---|
[13847] | 235 | style="position:fixed"
|
---|
[13733] | 236 | data-spy="affix"
|
---|
| 237 | data-offset-top="0">
|
---|
| 238 |
|
---|
[13735] | 239 | <li><a href="#top"><i class="fa fa-angle-up"></i> Top</a></li>
|
---|
[13733] | 240 | @if (Model.SelectedAlgorithm != null)
|
---|
[13827] | 241 | {//Algortihm loaded
|
---|
[13733] | 242 | <li><a href="#algorithm">Algorithm parameters</a></li>
|
---|
| 243 | <li><a href="#problem">Problem parameters</a></li>
|
---|
| 244 | }
|
---|
| 245 | else
|
---|
[13827] | 246 | {//batch run or experiment
|
---|
[13735] | 247 | <li><a id="ctasks" href="#tasks">Child tasks </a></li>
|
---|
[13740] | 248 | <li><a onclick="shower()" href="#tasks"><i class="fa fa-eye"></i> Show all tasks</a></li>
|
---|
| 249 | <li><a onclick="collapser()" href="#tasks"><i class="fa fa-eye-slash"></i> Hide all tasks</a></li>
|
---|
[13844] | 250 |
|
---|
[13733] | 251 | }
|
---|
[13834] | 252 | <li><a href="#finish"><i class="fa fa-flag-checkered"></i> Add to Hive or save to file</a></li>
|
---|
[13847] | 253 | <li style="position:fixed">
|
---|
[13871] | 254 | <div class="alert alert-success" id="success-alert" style="display:flex">
|
---|
[13844] | 255 | <span id="succText"></span>
|
---|
| 256 | </div>
|
---|
| 257 | <p id="logs">
|
---|
| 258 |
|
---|
| 259 | </p>
|
---|
| 260 | </li>
|
---|
[13733] | 261 | </ul>
|
---|
[13844] | 262 |
|
---|
[13733] | 263 | </nav>
|
---|
[13740] | 264 |
|
---|
[13754] | 265 | <script src="~/js/hubs/progresshubber.js"></script>
|
---|
[13844] | 266 |
|
---|
[13733] | 267 | <script>
|
---|
| 268 | showScrolly = function () {
|
---|
| 269 | document.getElementById("scrolly").style.display = "";
|
---|
| 270 |
|
---|
| 271 | }
|
---|
| 272 | $(function () {
|
---|
| 273 | $('nav > ul > li > a').click(function () {
|
---|
| 274 | if (location.pathname.replace(/^\//, '') == this.pathname.replace(/^\//, '') && location.hostname == this.hostname) {
|
---|
| 275 | var target = $(this.hash);
|
---|
| 276 | target = target.length ? target : $('[name=' + this.hash.slice(1) + ']');
|
---|
| 277 | if (target.length) {
|
---|
| 278 | $('html, body').animate({
|
---|
| 279 | scrollTop: target.offset().top
|
---|
[13841] | 280 | }, 700);
|
---|
[13733] | 281 | return false;
|
---|
| 282 | }
|
---|
| 283 | }
|
---|
| 284 | });
|
---|
[13735] | 285 | $('body').click(function () {
|
---|
[13844] | 286 | if ($("#ctasks").length > 0)
|
---|
[13735] | 287 | $("#ctasks").html("<i class='fa fa-sitemap'></i> Tasks (" + $('a[href^="#collapseExample"]').length + ")");
|
---|
| 288 | });
|
---|
| 289 | $('body').click();
|
---|
[13844] | 290 |
|
---|
[13733] | 291 | });
|
---|
[13735] | 292 | collapser = function () {
|
---|
[13847] | 293 | $('.collapse').not('#helperCol').collapse('hide');
|
---|
[13827] | 294 | //closes every collapse
|
---|
[13735] | 295 | }
|
---|
| 296 | shower = function () {
|
---|
[13847] | 297 | $('.collapse').not('#helperCol').collapse('show');
|
---|
| 298 |
|
---|
[13827] | 299 | //opens every collapse
|
---|
[13735] | 300 | }
|
---|
[13733] | 301 | </script>
|
---|
| 302 | </body>
|
---|
| 303 |
|
---|