server/admin/static/views/sync.html

48 lines
2.7 KiB
HTML
Raw Normal View History

<div class="card mt-3 mb-5" ng-show="!config.wip && timeProgression && !displayDangerousActions">
<div class="card-header bg-secondary text-light">
<h3 class="mb-0">
Synchronisation
</h3>
</div>
<div class="card-body">
<div class="form-check">
<label class="custom-control custom-checkbox">
<input class="custom-control-input" type="checkbox" ng-model="displayDangerousActions">
<strong class="custom-control-label">Je sais ce que le challenge a démarré ET <span style="text-decoration: underline red;">j'ai réalisé une sauvegarde de la base de données il y a moins d'une minute</span> ET je sais que c'est <span style="text-decoration: underline yellow;">une très mauvaise idée de cocher cette case</span>, mais j'y suis obligé pour de bonnes raisons.</strong>
</label>
</div>
</div>
</div>
<div class="card mt-3 mb-5 text-light bg-dark" ng-show="config.wip || !timeProgression || displayDangerousActions">
<div class="card-body">
<dl class="row">
<dt class="col-2">Synchronisation</dt>
<dd class="col-10" title="{{ configro['sync-type'] }}" ng-bind="configro.sync"></dd>
<dt class="col-2" ng-if="configro['sync-id']">ID</dt>
<dd class="col-10" ng-if="configro['sync-id']">{{ configro['sync-id'] }}</dd>
</dl>
<div class="float-right" ng-if="configro.sync">
{{ syncProgress }}
</div>
<div ng-if="syncReport">
Dernier import&nbsp;: {{ syncReport._date[1] }}
</div>
<div class="text-left" ng-if="configro.sync">
<button ng-if="configro['sync-type'] === 'GitImporter'" type="button" class="btn btn-info" ng-click="baseSync()" ng-disabled="deepSyncInProgress"><span class="glyphicon glyphicon-repeat" aria-hidden="true"></span> Pull</button>
<div class="btn-group">
<button type="button" class="btn btn-secondary" ng-click="deepSync()" ng-disabled="deepSyncInProgress"><span class="glyphicon glyphicon-import" aria-hidden="true"></span> Synchronisation intégrale</button>
<button type="button" class="btn btn-secondary dropdown-toggle dropdown-toggle-split" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false" ng-disabled="deepSyncInProgress">
<span class="sr-only">Toggle Dropdown</span>
</button>
<div class="dropdown-menu" ng-controller="ThemesListController">
<a class="dropdown-item" ng-click="deepSync(theme)" ng-repeat="theme in themes" ng-bind="theme.name"></a>
</div>
</div>
<button type="button" class="btn btn-secondary" ng-click="speedyDeepSync()" ng-disabled="deepSyncInProgress"><span class="glyphicon glyphicon-import" aria-hidden="true"></span> Synchronisation sans fichiers</button>
<a href="check_import.html" class="btn btn-success" target="_self" ng-if="syncReport">Voir le rapport</a>
</div>
</div>
</div>