Merge pull request #6685 from mabashian/5626-scm-type-error

Fixed scm type js error
This commit is contained in:
Michael Abashian
2017-06-22 12:26:50 -04:00
committed by GitHub
2 changed files with 74 additions and 75 deletions

View File

@@ -116,7 +116,6 @@ export default ['$scope', '$location', '$stateParams', 'GenerateForm',
$scope.pathRequired = ($scope.scm_type.value === 'manual') ? true : false; $scope.pathRequired = ($scope.scm_type.value === 'manual') ? true : false;
$scope.scmRequired = ($scope.scm_type.value !== 'manual') ? true : false; $scope.scmRequired = ($scope.scm_type.value !== 'manual') ? true : false;
$scope.scmBranchLabel = ($scope.scm_type.value === 'svn') ? 'Revision #' : 'SCM Branch'; $scope.scmBranchLabel = ($scope.scm_type.value === 'svn') ? 'Revision #' : 'SCM Branch';
}
// Dynamically update popover values // Dynamically update popover values
if ($scope.scm_type.value) { if ($scope.scm_type.value) {
@@ -157,7 +156,7 @@ export default ['$scope', '$location', '$stateParams', 'GenerateForm',
$scope.urlPopover = '<p> ' + i18n._('URL popover text') + '</p>'; $scope.urlPopover = '<p> ' + i18n._('URL popover text') + '</p>';
} }
} }
}
}; };
$scope.formCancel = function() { $scope.formCancel = function() {
$state.go('projects'); $state.go('projects');

View File

@@ -248,7 +248,6 @@ export default ['$scope', '$rootScope', '$stateParams', 'ProjectsForm', 'Rest',
$scope.pathRequired = ($scope.scm_type.value === 'manual') ? true : false; $scope.pathRequired = ($scope.scm_type.value === 'manual') ? true : false;
$scope.scmRequired = ($scope.scm_type.value !== 'manual') ? true : false; $scope.scmRequired = ($scope.scm_type.value !== 'manual') ? true : false;
$scope.scmBranchLabel = ($scope.scm_type.value === 'svn') ? i18n._('Revision #') : i18n._('SCM Branch'); $scope.scmBranchLabel = ($scope.scm_type.value === 'svn') ? i18n._('Revision #') : i18n._('SCM Branch');
}
// Dynamically update popover values // Dynamically update popover values
if ($scope.scm_type.value) { if ($scope.scm_type.value) {
@@ -287,6 +286,7 @@ export default ['$scope', '$rootScope', '$stateParams', 'ProjectsForm', 'Rest',
$scope.urlPopover = '<p> ' + i18n._('URL popover text'); $scope.urlPopover = '<p> ' + i18n._('URL popover text');
} }
} }
}
}; };
$scope.lookupCredential = function(){ $scope.lookupCredential = function(){