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