1 | @model HeuristicLab.Clients.Hive.WebJobManager.Models.BatchRunContainer
|
---|
2 | @{
|
---|
3 | int randombr = Model.randy.Next(5000);
|
---|
4 | var builder = "[";
|
---|
5 | foreach (var arr in Model.depth)
|
---|
6 | {
|
---|
7 | builder += "[" + String.Join(",", arr) + "],";
|
---|
8 | }
|
---|
9 | builder += "]";
|
---|
10 | }
|
---|
11 |
|
---|
12 |
|
---|
13 | <p class="text-center">
|
---|
14 | <a class="btn btn-warning"
|
---|
15 | data-toggle="collapse"
|
---|
16 | href="#collapseExample@(randombr)"
|
---|
17 | aria-expanded="false"
|
---|
18 | aria-controls="collapseExample@(randombr)">
|
---|
19 | @Model.batch.Name
|
---|
20 | </a>
|
---|
21 |
|
---|
22 | </p>
|
---|
23 | <div class="collapse"
|
---|
24 | id="collapseExample@(randombr)" style="margin-left:10px;margin-right:10px;margin-top:-10px ">
|
---|
25 | <img src="~/img/accoladebatch.png" style="width:100%" />
|
---|
26 | <div class="panel panel-warning" style="border-color:#f6cd94!important; border-width:2px!important">
|
---|
27 | <div class="panel-heading text-center">
|
---|
28 | <p class="panel-title">
|
---|
29 | Repeats @Model.batch.Repetitions X
|
---|
30 | </p>
|
---|
31 | <p>
|
---|
32 |
|
---|
33 |
|
---|
34 | <input type="checkbox" checked data-toggle="toggle" data-onstyle="warning"
|
---|
35 | onchange="toggleChild(@builder, @randombr)" />
|
---|
36 | Distribute child tasks
|
---|
37 |
|
---|
38 | </p>
|
---|
39 | <div class="btn-group">
|
---|
40 | <button type="button"
|
---|
41 | id="prior@(randombr)"
|
---|
42 | class="btn btn-info dropdown-toggle"
|
---|
43 | data-toggle="dropdown"
|
---|
44 | aria-haspopup="true" aria-expanded="false">
|
---|
45 | Normal <span class="caret"></span>
|
---|
46 | </button>
|
---|
47 | <ul class="dropdown-menu">
|
---|
48 | <li><a onclick="changePriority(@builder,0,@randombr)">Low</a></li>
|
---|
49 | <li><a onclick="changePriority(@builder,1,@randombr)">Normal</a></li>
|
---|
50 | <li><a onclick="changePriority(@builder,2,@randombr)">Urgent</a></li>
|
---|
51 | <li><a onclick="changePriority(@builder,3,@randombr)">Critical</a></li>
|
---|
52 | </ul>
|
---|
53 | </div>
|
---|
54 | </div>
|
---|
55 | <div id="childs@(randombr)">
|
---|
56 | @for (var k = 0; k < Model.batch.Repetitions; k++)
|
---|
57 | {
|
---|
58 | @if (Model.batch.Optimizer is HeuristicLab.Optimization.IAlgorithm)
|
---|
59 | {
|
---|
60 | @Html.Partial("OpenFilePartials/_AlgorithmSmall",
|
---|
61 | new HeuristicLab.Clients.Hive.WebJobManager.Models.AlgorithmContainer(
|
---|
62 | ((HeuristicLab.Optimization.IAlgorithm)Model.batch.Optimizer),
|
---|
63 | Model.depth.ToList(),
|
---|
64 | new int[] { 0, k },
|
---|
65 | Model.randy))
|
---|
66 |
|
---|
67 | }
|
---|
68 | else if (Model.batch.Optimizer is HeuristicLab.Optimization.BatchRun)
|
---|
69 | {
|
---|
70 | @Html.Partial("OpenFilePartials/_BatchRunSmall",
|
---|
71 | new HeuristicLab.Clients.Hive.WebJobManager.Models.BatchRunContainer(
|
---|
72 | ((HeuristicLab.Optimization.BatchRun)Model.batch.Optimizer),
|
---|
73 | Model.depth.ToList(),
|
---|
74 | new int[] { 0, k },
|
---|
75 | Model.randy)) ;
|
---|
76 |
|
---|
77 | }
|
---|
78 | else if (Model.batch.Optimizer is HeuristicLab.Optimization.Experiment)
|
---|
79 | {
|
---|
80 | @Html.Partial("OpenFilePartials/_ExperimentSmall",
|
---|
81 | new HeuristicLab.Clients.Hive.WebJobManager.Models.ExperimentContainer(
|
---|
82 | ((HeuristicLab.Optimization.Experiment)Model.batch.Optimizer),
|
---|
83 | Model.depth.ToList(),
|
---|
84 | new int[] { 0, k },
|
---|
85 | Model.randy)) ;
|
---|
86 |
|
---|
87 | }
|
---|
88 | }
|
---|
89 | </div>
|
---|
90 | </div>
|
---|
91 | </div>
|
---|