Add queued checking for upload

This commit is contained in:
Loic GUEGAN 2016-05-08 18:54:15 +02:00
parent ddcabd3d9c
commit 39865ef592
2 changed files with 3 additions and 4 deletions

View file

@ -19,7 +19,6 @@ mainApp.controller('editImageCtrl', ['$scope', 'Image', 'Loading', 'Identity', '
});
$scope.data = {};
$scope.applyEdition = function (id) {
Image.updateImage($scope.data, function () {
$rootScope.$broadcast("updateImageEvent");

View file

@ -34,7 +34,7 @@
</fieldset>
</form>
<form action="../server/index.php" method="post">
<form action="../server/index.php" method="post" ng-if='image.status == "queued"'>
<input type="hidden" name="task" value="image" />
<input type="hidden" name="token" value="{{ getToken()}}" />
<input type="hidden" name="action" value="uploadImage" />
@ -43,8 +43,8 @@
<input type="hidden" name="file_name" value="cirros-0.3.4-x86_64-disk.img" />
<fieldset class="form-group">
<label class="control-label col-sm-2">Upload</label>
<input name="file" type="file" />
<input type="submit" value="Upload" />
<input name="file" type="file"/>
<input type="submit" value="Upload"/>
</fieldset>
</form>