mirror of
https://github.com/EDCD/coriolis.git
synced 2025-12-09 06:43:24 +00:00
46 lines
2.3 KiB
HTML
Executable File
46 lines
2.3 KiB
HTML
Executable File
<h2 translate="import"></h2>
|
|
<div ng-show="!processed">
|
|
<textarea class="cb json" ng-model="importString" ng-change="validateImport()" placeholder="{{'PHRASE_IMPORT' | translate}}"></textarea>
|
|
<button class="l cap" ng-click="process()" ng-disabled="!importValid" translate="proceed"></button>
|
|
<div class="l warning" style="margin-left:3em;">{{errorMsg}}</div>
|
|
</div>
|
|
|
|
<div ng-show="processed">
|
|
<table class="l" style="overflow:hidden;margin: 1em 0; width: 100%;">
|
|
<thead>
|
|
<tr>
|
|
<th style="text-align:left" translate="ship"></th>
|
|
<th style="text-align:left" translate="build name"></th>
|
|
<th translate="action"></th>
|
|
</tr>
|
|
</thead>
|
|
<tbody ng-repeat="(shipId,shipBuilds) in builds">
|
|
<tr class="cb" ng-repeat="(buildName, b) in shipBuilds">
|
|
<td>{{ships[shipId].properties.name}}</td>
|
|
<td><input type="text" ng-model="b.useName"/></td>
|
|
<td style="text-align:center" ng-class="{warning: hasBuild(shipId, b.useName) == true, disabled: b.useName == ''}">
|
|
<span ng-show="b.useName" translate="{{ hasBuild(shipId, b.useName)? 'overwrite' : 'create' }}"></span>
|
|
<span ng-show="b.useName == ''" translate="skip"></span>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<table class="l" style="overflow:hidden;margin: 1em 0; width: 100%;" ng-if="comparisons">
|
|
<thead><tr><th style="text-align:left" translate="comparison"></th><th translate="action"></th></tr></thead>
|
|
<tbody>
|
|
<tr class="cb" ng-repeat="(name, comparison) in comparisons">
|
|
<td><input type="text" ng-model="comparison.useName"/></td>
|
|
<td style="text-align:center" ng-class="{warning: hasComparison(comparison.useName) == true, disabled: comparison.useName == ''}">
|
|
<span ng-show="comparison.useName" translate="{{ hasComparison(comparison.useName)? 'overwrite' : 'create' }}"></span>
|
|
<span ng-show="comparison.useName == ''" translate="skip"></span>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
|
|
<button class="cl l" ng-click="import()"><svg class="icon"><use xlink:href="#download"></use></svg> {{'import' | translate}}</button>
|
|
<button class="l cap" style="margin-left: 2em;" ng-click="processed = false" ng-show="canEdit" translate="edit data"></button>
|
|
</div>
|
|
|
|
<button class="r dismiss cap" ng-click="dismiss()" translate="cancel"></button> |