diff --git a/endpoints/api.py b/endpoints/api.py
index 4c2f1ce6f..6e5304ac2 100644
--- a/endpoints/api.py
+++ b/endpoints/api.py
@@ -1469,7 +1469,7 @@ def manually_start_build_trigger(namespace, repository, trigger_uuid):
handler = BuildTrigger.get_trigger_for_service(trigger.service.name)
existing_config_dict = json.loads(trigger.config)
- if handler.is_active(existing_config_dict):
+ if not handler.is_active(existing_config_dict):
abort(400)
return
diff --git a/static/directives/trigger-description.html b/static/directives/trigger-description.html
index 39ce38003..7cb1a5731 100644
--- a/static/directives/trigger-description.html
+++ b/static/directives/trigger-description.html
@@ -4,11 +4,18 @@
Push to GitHub repository {{ trigger.config.build_source }}
+
Unknown
diff --git a/static/js/app.js b/static/js/app.js
index 7aa0ae460..6b484c41a 100644
--- a/static/js/app.js
+++ b/static/js/app.js
@@ -132,9 +132,7 @@ quayApp = angular.module('quay', ['ngRoute', 'chieffancypants.loadingBar', 'angu
var source = $sanitize(UtilService.textToSafeHtml(config['build_source']));
var desc = ' Push to Github Repository ';
desc += '' + source + '';
- if (config['subdir']) {
- desc += '
Dockerfile folder: ' + UtilService.textToSafeHtml(config['subdir']);
- }
+ desc += '
Dockerfile folder: //' + UtilService.textToSafeHtml(config['subdir']);
return desc;
default:
diff --git a/static/js/controllers.js b/static/js/controllers.js
index 22dd24d06..5df6a3f95 100644
--- a/static/js/controllers.js
+++ b/static/js/controllers.js
@@ -1470,6 +1470,30 @@ function RepoAdminCtrl($scope, Restangular, ApiService, KeyService, $routeParams
$scope.currentSetupTrigger = null;
};
+ $scope.startTrigger = function(trigger) {
+ var params = {
+ 'repository': namespace + '/' + name,
+ 'trigger_uuid': trigger.id
+ };
+
+ ApiService.manuallyStartBuildTrigger(null, params).then(function(resp) {
+ window.console.log(resp);
+ var url = '/repository/' + namespace + '/' + name + '/build?current=' + resp['id'];
+ document.location = url;
+ }, function(resp) {
+ bootbox.dialog({
+ "message": resp['message'] || 'The build could not be started',
+ "title": "Could not start build",
+ "buttons": {
+ "close": {
+ "label": "Close",
+ "className": "btn-primary"
+ }
+ }
+ });
+ });
+ };
+
$scope.deleteTrigger = function(trigger) {
var params = {
'repository': namespace + '/' + name,
diff --git a/static/partials/repo-admin.html b/static/partials/repo-admin.html
index 58e9618b5..e1cbed845 100644
--- a/static/partials/repo-admin.html
+++ b/static/partials/repo-admin.html
@@ -262,6 +262,7 @@