directives: ssh-key-dialog -> trigger credentials
This commit is contained in:
parent
2236270741
commit
de3fa5f42d
6 changed files with 52 additions and 38 deletions
|
@ -1,10 +1,10 @@
|
|||
/**
|
||||
* An element which displays a dialog with the public SSH keycredentials for a trigger.
|
||||
*/
|
||||
angular.module('quay').directive('sshKeyDialog', function () {
|
||||
angular.module('quay').directive('triggerCredentialsDialog', function () {
|
||||
var directiveDefinitionObject = {
|
||||
priority: 0,
|
||||
templateUrl: '/static/directives/ssh-key-dialog.html',
|
||||
templateUrl: '/static/directives/trigger-credentials-dialog.html',
|
||||
replace: false,
|
||||
transclude: true,
|
||||
restrict: 'C',
|
||||
|
@ -15,10 +15,10 @@ angular.module('quay').directive('sshKeyDialog', function () {
|
|||
controller: function($scope, $element) {
|
||||
var show = function() {
|
||||
if (!$scope.trigger) {
|
||||
$('#sshkeymodal').modal('hide');
|
||||
$('#triggercredentialsmodal').modal('hide');
|
||||
return;
|
||||
}
|
||||
$('#sshkeymodal').modal({});
|
||||
$('#triggercredentialsmodal').modal({});
|
||||
};
|
||||
|
||||
$scope.$watch('trigger', show);
|
Reference in a new issue