1 | @model HeuristicLab.Clients.Hive.WebJobManager.Models.BatchRunContainer
|
---|
2 | @{
|
---|
3 | int randombr = Model.randy.Next(50000);
|
---|
4 | var builder = "[";
|
---|
5 | foreach (var arr in Model.depth)
|
---|
6 | {
|
---|
7 | builder += "[" + String.Join(",", arr) + "],";
|
---|
8 | }
|
---|
9 | builder += "]";
|
---|
10 | }
|
---|
11 | <!-- Partial for displaying a small version of a batch file-->
|
---|
12 |
|
---|
13 | <p class="text-center">
|
---|
14 | <a class="btn btn-warning"
|
---|
15 | id="nameCarrier@(randombr)"
|
---|
16 | data-toggle="collapse"
|
---|
17 | href="#collapseExample@(randombr)"
|
---|
18 | aria-expanded="false"
|
---|
19 | aria-controls="collapseExample@(randombr)"
|
---|
20 | style="margin:10px;margin-bottom:0; box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
|
---|
21 | text-shadow:2px 2px black;">
|
---|
22 | @Model.batch.Name
|
---|
23 | </a>
|
---|
24 |
|
---|
25 | </p>
|
---|
26 | <div class="collapse"
|
---|
27 | id="collapseExample@(randombr)"
|
---|
28 | style="margin-left:10px;margin-right:10px;margin-top:-10px ">
|
---|
29 | <img src="~/img/accoladebatch.png"
|
---|
30 | style="width:100%" />
|
---|
31 |
|
---|
32 | <div class="panel panel-warning"
|
---|
33 | style="border-color:#f6cd94!important; border-width:2px!important;
|
---|
34 | box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
|
---|
35 | text-shadow:2px 2px black">
|
---|
36 | <div class="panel-heading text-center">
|
---|
37 | <p>
|
---|
38 | <input type="text"
|
---|
39 | class="form-control"
|
---|
40 | style="width:50%;display:initial; background-color:transparent;text-align:center;color:white"
|
---|
41 | onchange="changeName(@builder,this.value,@randombr)"
|
---|
42 | value="@Model.batch.Name" />
|
---|
43 | </p>
|
---|
44 | <p class="panel-title">
|
---|
45 | Repeats:
|
---|
46 | <input type="number"
|
---|
47 | class="form-control"
|
---|
48 | style="width:80px;display:initial; margin-bottom:5px"
|
---|
49 | min="1"
|
---|
50 | value="@Model.batch.Repetitions"
|
---|
51 | onchange="changeRepit(@builder,this.value,@randombr)" />
|
---|
52 | x
|
---|
53 | </p>
|
---|
54 | <p>
|
---|
55 |
|
---|
56 | Distribute child tasks
|
---|
57 | <input type="checkbox"
|
---|
58 | checked
|
---|
59 | data-toggle="toggle"
|
---|
60 | data-onstyle="warning"
|
---|
61 | onchange="toggleChild(@builder, @randombr)" />
|
---|
62 |
|
---|
63 |
|
---|
64 | </p>
|
---|
65 | <div class="btn-group"
|
---|
66 | style="text-shadow:none">
|
---|
67 |
|
---|
68 | <button type="button"
|
---|
69 | id="prior@(randombr)"
|
---|
70 | class="btn btn-info dropdown-toggle"
|
---|
71 | data-toggle="dropdown"
|
---|
72 | aria-haspopup="true"
|
---|
73 | aria-expanded="false">
|
---|
74 | Normal <span class="caret"></span>
|
---|
75 | </button>
|
---|
76 | <ul class="dropdown-menu">
|
---|
77 | <li><a onclick="changePriority(@builder,0,@randombr)">Low</a></li>
|
---|
78 | <li><a onclick="changePriority(@builder,1,@randombr)">Normal</a></li>
|
---|
79 | <li><a onclick="changePriority(@builder,2,@randombr)">Urgent</a></li>
|
---|
80 | <li><a onclick="changePriority(@builder,3,@randombr)">Critical</a></li>
|
---|
81 | </ul>
|
---|
82 | </div>
|
---|
83 | </div>
|
---|
84 | <div id="childs@(randombr)">
|
---|
85 | @if (Model.batch.Optimizer is HeuristicLab.Optimization.IAlgorithm)
|
---|
86 | {
|
---|
87 | @Html.Partial("OpenFilePartials/_AlgorithmSmall",
|
---|
88 | new HeuristicLab.Clients.Hive.WebJobManager.Models.AlgorithmContainer(
|
---|
89 | ((HeuristicLab.Optimization.IAlgorithm)Model.batch.Optimizer),
|
---|
90 | Model.depth.ToList(),
|
---|
91 | new int[] { 0, 0 },
|
---|
92 | Model.randy))
|
---|
93 |
|
---|
94 | }
|
---|
95 | else if (Model.batch.Optimizer is HeuristicLab.Optimization.BatchRun)
|
---|
96 | {
|
---|
97 | @Html.Partial("OpenFilePartials/_BatchRunSmall",
|
---|
98 | new HeuristicLab.Clients.Hive.WebJobManager.Models.BatchRunContainer(
|
---|
99 | ((HeuristicLab.Optimization.BatchRun)Model.batch.Optimizer),
|
---|
100 | Model.depth.ToList(),
|
---|
101 | new int[] { 0, 0 },
|
---|
102 | Model.randy)) ;
|
---|
103 |
|
---|
104 | }
|
---|
105 | else if (Model.batch.Optimizer is HeuristicLab.Optimization.Experiment)
|
---|
106 | {
|
---|
107 | @Html.Partial("OpenFilePartials/_ExperimentSmall",
|
---|
108 | new HeuristicLab.Clients.Hive.WebJobManager.Models.ExperimentContainer(
|
---|
109 | ((HeuristicLab.Optimization.Experiment)Model.batch.Optimizer),
|
---|
110 | Model.depth.ToList(),
|
---|
111 | new int[] { 0, 0 },
|
---|
112 | Model.randy)) ;
|
---|
113 |
|
---|
114 | }
|
---|
115 |
|
---|
116 | </div>
|
---|
117 | </div>
|
---|
118 | </div>
|
---|