<h2 class="pull-left">Tasks Remote</h2>
        <div class="col-sm-2">
            <br/>
            <input class="form-control" type="text" id="jobname" ng-model="jobname" />
        </div>

<div class="row">
    <br/>
    <div data-tabs>
        <div data-panel="Tasks">
            <div class="col-lg-4">
                <select class="form-control" size="20" multiple="multiple" ng-model="preselected.Tasks">
                    <option ng-repeat="e in options.Tasks" ng-dblclick="add('Tasks')">{{e}}</option>
                </select>
            </div>
            <div class="col-lg-1">
                <button class="btn btn-default" ng-click="add('Tasks')"><i class="glyphicon glyphicon-chevron-right"></i></button>
            </div>
            <div class="col-lg-7">
                <table class="table table-hover table-bordered">
                    <tr ng-repeat="e in selected.Tasks">
                        <td>
                            <button class="btn btn-default" ng-click="remove('Tasks',e)">
                                <i class="glyphicon glyphicon-trash"></i>
                            </button>
                        </td>
                        <td>{{e.Name}}</td>
                        <td>
                            <div class="checkbox">
                                <label><input type="checkbox" ng-model="e.komplett" /> komplett</label>
                            </div>
                        </td>
                        <td>
                            <div class="checkbox" ng-repeat="(i,b) in batchFilter(details.Tasks[e.Name].contents)" ng-hide="e.komplett">

                                <label><input type="checkbox" ng-model="e.Auswahl[i]" /> {{b}}</label>
                            </div>
                        </td>
                    </tr>
                </table>
            </div>
        </div>
        <div data-panel="GCStarter-Batch">
            <div class="col-lg-4">
                <select class="form-control" size="20" multiple="multiple" ng-model="preselected.Starter">
                    <option ng-repeat="e in options.Starter" ng-dblclick="add('Starter')">{{e}}</option>
                </select>
            </div>
            <div class="col-lg-1">
                <button class="btn btn-default" ng-click="add('Starter')"><i class="glyphicon glyphicon-chevron-right"></i></button>
            </div>
            <div class="col-lg-7">
                <table class="table table-hover table-bordered">
                    <tr ng-repeat="e in selected.Starter">
                        <td>
                            <button class="btn btn-default" ng-click="remove('Starter',e)">
                                <i class="glyphicon glyphicon-trash"></i>
                            </button>
                        </td>
                        <td>{{e.Name}}</td>
                    </tr>
                </table>
            </div>
        </div>
        <div data-panel="Impromptu">
            <div class="col-lg-4">
                <select class="form-control" size="20" multiple="multiple" ng-model="preselected.Impromptu">
                    <option ng-repeat="e in options.Impromptu" ng-dblclick="add('Impromptu')">{{e}}</option>
                </select>
            </div>
            <div class="col-lg-1">
                <button class="btn btn-default" ng-click="add('Impromptu')"><i class="glyphicon glyphicon-chevron-right"></i></button>
            </div>
            <div class="col-lg-7">
                <table class="table table-hover table-bordered">
                    <tr ng-repeat="e in selected.Impromptu">
                        <td>
                            <button class="btn btn-default" ng-click="remove('Impromptu',e)">
                                <i class="glyphicon glyphicon-trash"></i>
                            </button>
                        </td>
                        <td>{{e.Name}}<br/><div>({{details.Impromptu[e.Name].modified}})</div></td>
                        <td>
                            <div class="checkbox-inline">
                                <label><input type="checkbox" ng-model="e.iqd" /> IQD</label>
                            </div><br/>
                            <div ng-show="details.Impromptu[e.Name].iqd.newer">(aktuell)</div>
                            <div ng-hide="details.Impromptu[e.Name].iqd.newer">(veraltet, Stand: {{details.Impromptu[e.Name].iqd.modified}})</div>
                        </td>
                        <td>
                            <div class="checkbox-inline">
                                <label><input type="checkbox" ng-model="e.ims" /> IMS</label>
                            </div><br/>
                            <div>({{details.Impromptu[e.Name].ims.modified}})</div>
                        </td>
                        <td>
                            <div class="checkbox-inline">
                                <label><input type="checkbox" ng-model="e.csv" /> CSV</label>
                            </div><br/>
                            <div>({{details.Impromptu[e.Name].csv.modified}})</div>
                        </td>
                    </tr>
                </table>
            </div>
        </div>
        <div data-panel="Modelle">
            <div class="col-lg-4">
                <select class="form-control" size="20" multiple="multiple" ng-model="preselected.Transformer">
                    <option ng-repeat="e in options.Transformer" ng-dblclick="add('Transformer')">{{e}}</option>
                </select>
            </div>
            <div class="col-lg-1">
                <button class="btn btn-default" ng-click="add('Transformer')"><i class="glyphicon glyphicon-chevron-right"></i></button>
            </div>
            <div class="col-lg-7">
                <table class="table table-hover table-bordered">
                    <tr ng-repeat="e in selected.Transformer">
                        <td>
                            <button class="btn btn-default" ng-click="remove('Transformer',e)">
                                <i class="glyphicon glyphicon-trash"></i>
                            </button>
                        </td>
                        <td>{{e.Name}}<br/><div>({{details.Transformer[e.Name].modified}})</div></td>
                        <td>{{details.Transformer[e.Name].cube}} (Stand: {{details.Transformer[e.Name].mdc.modified}})</td>
                        <td>
                            <label class="checkbox-inline">Anzahl Versuche: <input type="text" ng-model="e.Anzahl" /></label>
                        </td>
                    </tr>
                </table>
            </div>
        </div>
        <div data-panel="Portal/Versand">
            <div class="col-lg-4">
                <select class="form-control" size="20" multiple="multiple" ng-model="preselected.Portal">
                    <option ng-repeat="e in options.Portal" ng-dblclick="add('Portal')">{{e}}</option>
                </select>
            </div>
            <div class="col-lg-1">
                <button class="btn btn-default" ng-click="add('Portal')"><i class="glyphicon glyphicon-chevron-right"></i></button>
            </div>
            <div class="col-lg-7">
                <table class="table table-hover table-bordered">
                    <tr ng-repeat="e in selected.Portal">
                        <td>
                            <button class="btn btn-default" ng-click="remove('Portal',e)">
                                <i class="glyphicon glyphicon-trash"></i>
                            </button>
                        </td>
                        <td>{{e.Name}}<br/><div>({{details.Portal[e.Name].modified}})</div></td>
                        <td>{{details.Portal[e.Name].type}}</td>
                        <td ng-show="details.Portal[e.Name].type=='Portal'">
                            <label>Benutzer:
                                <select class="form-control" ng-model="e.Benutzer" ng-options="u for u in details.Portal[e.Name].users"></select>
                            </label>
                        </td>
                        <td ng-show="details.Portal[e.Name].type=='Versand'">
                            <label>Empfänger:
                                <select class="form-control" ng-model="e.Benutzer" ng-options="u for u in details.Portal[e.Name].email"></select>
                            </label>
                        </td>
                        <td ng-show="details.Portal[e.Name].type=='Portal'">
                            <label>Struktur:
                                <select class="form-control" ng-model="e.Struktur" ng-options="u for u in details.Portal[e.Name].structure"></select>
                            </label>
                        </td>
                        <td>
                            <label>Cubes:
                                <select class="form-control" ng-model="e.Cubes" ng-options="u for u in details.Portal[e.Name].cube"></select>
                            </label>
                        </td>
                    </tr>
                </table>
            </div>
        </div>
        <div data-panel="Berichte">
            <div class="col-lg-4">
                <select class="form-control" size="20" multiple="multiple" ng-model="preselected.Powerplay">
                    <option ng-repeat="e in options.Powerplay" ng-dblclick="add('Powerplay')">{{e}}</option>
                </select>
            </div>
            <div class="col-lg-1">
                <button class="btn btn-default" ng-click="add('Powerplay')"><i class="glyphicon glyphicon-chevron-right"></i></button>
            </div>
            <div class="col-lg-7">
                <table class="table table-hover table-bordered">
                    <tr ng-repeat="e in selected.Powerplay">
                        <td>
                            <button class="btn btn-default" ng-click="remove('Powerplay',e)">
                                <i class="glyphicon glyphicon-trash"></i>
                            </button>
                        </td>
                        <td>{{e.Name}}<br/><div>({{details.Powerplay[e.Name].modified}})</div></td>
                        <td>
                            <div class="checkbox-inline">
                                <label><input type="checkbox" ng-model="e.ppx" /> PPX</label>
                            </div><br/>
                            <div>({{details.Powerplay[e.Name].ppx.modified}})</div>
                        </td>
                        <td>
                            <div class="checkbox-inline">
                                <label><input type="checkbox" ng-model="e.gif" /> GIF</label>
                            </div><br/>
                            <div>({{details.Powerplay[e.Name].gif.modified}})</div>
                        </td>
                        <td>
                            <div class="checkbox-inline">
                                <label><input type="checkbox" ng-model="e.pdf" /> PDF</label>
                            </div><br/>
                            <div>({{details.Powerplay[e.Name].pdf.modified}})</div>
                        </td>
                        <td>
                            <div class="checkbox-inline">
                                <label><input type="checkbox" ng-model="e.csv" /> CSV</label>
                            </div><br/>
                            <div>({{details.Powerplay[e.Name].csv.modified}})</div>
                        </td>
                        <td>
                            <div class="checkbox-inline">
                                <label><input type="checkbox" ng-model="e.xls" /> XLS</label>
                            </div><br/>
                            <div>({{details.Powerplay[e.Name].xls.modified}})</div>
                        </td>
                    </tr>
                </table>
            </div>
        </div>
        <!--
        <div data-panel="PC Visit">
            <div class="jumbotron">
                <div class="col-lg-6 col-lg-offset-3">

                    <div class="form-inline">
                        <label class="control-label" for="number">Verbindungsnummer:</label>
                        <input class="form-control" type="text" id="number" ng-model="pcvisit.Number" />
                        <button class="btn btn-default" ng-click="pcvisitConnect()"><i class="glyphicon glyphicon-ok-sign"></i></button>
                    </div>
                </div>
            </div>
        </div>
        -->
    </div>
</div>
<br/>
<div class="row">
    <div class="col-lg-6">

        <button class="btn btn-success" ng-click="runJob()"><i class="glyphicon glyphicon-play-circle"></i> Ausführen</button><br/>
        <div class="checkbox">
            <label><input type="checkbox" ng-model="statusmail" /> Fehlerbericht an Global Cube</label>
        </div>

<pre>
<span ng-repeat="e in selected.Tasks">{{e.toString()}}</span>
<span ng-repeat="e in selected.Starter">{{e.toString()}}</span>
<span ng-repeat="e in selected.Impromptu">{{e.toString()}}</span>
<span ng-repeat="e in selected.Transformer">{{e.toString()}}</span>
<span ng-repeat="e in selected.Portal">{{e.toString()}}</span>
<span ng-repeat="e in selected.Powerplay">{{e.toString()}}</span></pre>
    </div>

    <div class="col-lg-6">
        <pre class="{{style}}">{{protocol}}</pre>
        <span ng-show="style=='bg-warning'">
            <i class="glyphicon glyphicon-refresh spinning"></i> Läuft ...
        </span>
        <div class="form-inline">
            <label class="control-label" for="logfile">Logdatei:</label>
            <select class="form-control" id="logfile" ng-model="logfile" ng-change="refresh()">
                <option>{{jobname}}.log</option>
                <option ng-repeat="e in options.Logs">{{e}}</option>
                <option ng-repeat="e in options.Prot">Prot\{{e}}</option>
            </select>
            <button class=" btn btn-default" ng-click="stopAndTop()"><i class="glyphicon glyphicon-upload"></i> Nach oben</button>
        </div>
    </div>
</div>