diff --git a/awx/ui/static/js/controllers/Projects.js b/awx/ui/static/js/controllers/Projects.js index 6729032cc5..ae8b02a3c9 100644 --- a/awx/ui/static/js/controllers/Projects.js +++ b/awx/ui/static/js/controllers/Projects.js @@ -576,7 +576,7 @@ function ProjectsEdit($scope, $rootScope, $compile, $location, $log, $routeParam master[form.fields[fld].fields[i].name] = data[form.fields[fld].fields[i].name]; } } else { - if (data[fld]) { + if (data[fld] !== undefined) { $scope[fld] = data[fld]; master[fld] = data[fld]; } diff --git a/awx/ui/static/js/forms/Projects.js b/awx/ui/static/js/forms/Projects.js index 20fd460a35..28f3510a98 100644 --- a/awx/ui/static/js/forms/Projects.js +++ b/awx/ui/static/js/forms/Projects.js @@ -206,7 +206,25 @@ angular.module('ProjectFormDefinition', []) dataPlacement: 'right', labelClass: 'checkbox-options' }] - } + }, + scm_update_cache_timeout: { + label: 'Cache Timeout', + id: 'scm-cache-timeout', + type: 'number', + integer: true, + min: 0, + ngShow: "scm_update_on_launch", + spinner: true, + "default": '0', + addRequired: false, + editRequired: false, + awPopOver: '

Time in seconds to consider a project update current. During job runs and callbacks the task system will ' + + 'evaluate the timestamp of the latest project update. If it is older than Cache Timeout, the project update is not current, ' + + 'and a new update will be performed.', + dataTitle: 'Cache Timeout', + dataPlacement: 'right', + dataContainer: "body" + }, }, buttons: {