From eebdd13aa1a2d2515fb02f019aa3cae7000cd775 Mon Sep 17 00:00:00 2001 From: Matthew Jones Date: Tue, 6 Dec 2016 11:39:08 -0500 Subject: [PATCH 1/6] Updating schedules help text --- awx/main/models/schedules.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/awx/main/models/schedules.py b/awx/main/models/schedules.py index 786e788aa3..243201d377 100644 --- a/awx/main/models/schedules.py +++ b/awx/main/models/schedules.py @@ -10,6 +10,7 @@ import dateutil.rrule from django.db import models from django.db.models.query import QuerySet from django.utils.timezone import now, make_aware, get_default_timezone +from django.utils.translation import ugettext_lazy as _ # AWX from awx.main.models.base import * # noqa @@ -65,24 +66,29 @@ class Schedule(CommonModel): ) enabled = models.BooleanField( default=True, + help_text=_("Enables processing of this schedule by Tower") ) dtstart = models.DateTimeField( null=True, default=None, editable=False, + help_text=_("The first occurrence of the schedule occurs on or after this time") ) dtend = models.DateTimeField( null=True, default=None, editable=False, + help_text=_("The last occurrence of the schedule occurs before this time, aftewards the schedule expires") ) rrule = models.CharField( max_length=255, + help_text=_("A value representing the schedules iCal recurrence rule") ) next_run = models.DateTimeField( null=True, default=None, editable=False, + help_text=_("The next time that the scheduled action will run") ) extra_data = JSONField( blank=True, From d7ffdf7020f2b7d98d492c48ae9585782d52c4eb Mon Sep 17 00:00:00 2001 From: Matthew Jones Date: Tue, 6 Dec 2016 12:03:44 -0500 Subject: [PATCH 2/6] Updating project help text --- awx/main/models/projects.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/awx/main/models/projects.py b/awx/main/models/projects.py index 1b56ae72a3..2d045cee6f 100644 --- a/awx/main/models/projects.py +++ b/awx/main/models/projects.py @@ -78,12 +78,14 @@ class ProjectOptions(models.Model): blank=True, default='', verbose_name=_('SCM Type'), + help_text=_("Specifies the source control system used to store the project."), ) scm_url = models.CharField( max_length=1024, blank=True, default='', verbose_name=_('SCM URL'), + help_text=_("The location where the project is stored."), ) scm_branch = models.CharField( max_length=256, @@ -94,9 +96,11 @@ class ProjectOptions(models.Model): ) scm_clean = models.BooleanField( default=False, + help_text=_('Discard any local changes before syncing the project.'), ) scm_delete_on_update = models.BooleanField( default=False, + help_text=_('Delete the project before syncing.'), ) credential = models.ForeignKey( 'Credential', @@ -109,6 +113,7 @@ class ProjectOptions(models.Model): timeout = models.IntegerField( blank=True, default=0, + help_text=_("The amount of time to run before the task is canceled"), ) def clean_scm_type(self): @@ -221,10 +226,13 @@ class Project(UnifiedJobTemplate, ProjectOptions, ResourceMixin): ) scm_update_on_launch = models.BooleanField( default=False, + help_text=_('Update the project when a job is launched that uses the project.'), ) scm_update_cache_timeout = models.PositiveIntegerField( default=0, blank=True, + help_text=_('The number of seconds after the last project update ran that a new' + 'project update will be launched as a job dependency.'), ) scm_revision = models.CharField( From ebb0f06b17e34119eb9fe28920f1a9c33b331a87 Mon Sep 17 00:00:00 2001 From: Matthew Jones Date: Tue, 6 Dec 2016 12:12:08 -0500 Subject: [PATCH 3/6] Updating host field help text --- awx/main/models/inventory.py | 1 + 1 file changed, 1 insertion(+) diff --git a/awx/main/models/inventory.py b/awx/main/models/inventory.py index c16b89bcb2..e7183f356d 100644 --- a/awx/main/models/inventory.py +++ b/awx/main/models/inventory.py @@ -342,6 +342,7 @@ class Host(CommonModelNameNotUnique): max_length=1024, blank=True, default='', + help_text=_('The value used by the remote inventory source to uniquely identify the host'), ) variables = models.TextField( blank=True, From 51461a27dafabf8853df062fc4ca3d1edde33fda Mon Sep 17 00:00:00 2001 From: Matthew Jones Date: Tue, 6 Dec 2016 12:18:17 -0500 Subject: [PATCH 4/6] Adding help text to various job fields --- awx/main/models/unified_jobs.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/awx/main/models/unified_jobs.py b/awx/main/models/unified_jobs.py index 63c3e3196a..484831eacf 100644 --- a/awx/main/models/unified_jobs.py +++ b/awx/main/models/unified_jobs.py @@ -431,6 +431,7 @@ class UnifiedJob(PolymorphicModel, PasswordFieldsModel, CommonModelNameNotUnique blank=True, default='', editable=False, + help_text=_("The Tower node the job executed on."), ) notifications = models.ManyToManyField( 'Notification', @@ -456,16 +457,19 @@ class UnifiedJob(PolymorphicModel, PasswordFieldsModel, CommonModelNameNotUnique null=True, default=None, editable=False, + help_text=_("The date and time the job was queued for starting."), ) finished = models.DateTimeField( null=True, default=None, editable=False, + help_text=_("The date and time the job finished execution."), ) elapsed = models.DecimalField( max_digits=12, decimal_places=3, editable=False, + help_text=_("Elapsed time in seconds that the job ran."), ) job_args = models.TextField( blank=True, @@ -487,6 +491,7 @@ class UnifiedJob(PolymorphicModel, PasswordFieldsModel, CommonModelNameNotUnique blank=True, default='', editable=False, + help_text=_("A status field to indicate the state of the job if it wasn't able to run and capture stdout"), ) start_args = models.TextField( blank=True, From 6efeeeb0839ed908c895038883840e8a8b2b4de5 Mon Sep 17 00:00:00 2001 From: Matthew Jones Date: Tue, 6 Dec 2016 12:29:56 -0500 Subject: [PATCH 5/6] Adding missing period for timeout --- awx/main/models/projects.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/awx/main/models/projects.py b/awx/main/models/projects.py index 2d045cee6f..6c76143f40 100644 --- a/awx/main/models/projects.py +++ b/awx/main/models/projects.py @@ -113,7 +113,7 @@ class ProjectOptions(models.Model): timeout = models.IntegerField( blank=True, default=0, - help_text=_("The amount of time to run before the task is canceled"), + help_text=_("The amount of time to run before the task is canceled."), ) def clean_scm_type(self): From 71c600cad0be32c829fb5c758f1642bbd1bcfbce Mon Sep 17 00:00:00 2001 From: Matthew Jones Date: Tue, 6 Dec 2016 13:18:34 -0500 Subject: [PATCH 6/6] more missing punctuation --- awx/main/models/schedules.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/awx/main/models/schedules.py b/awx/main/models/schedules.py index 243201d377..21ecf49916 100644 --- a/awx/main/models/schedules.py +++ b/awx/main/models/schedules.py @@ -66,29 +66,29 @@ class Schedule(CommonModel): ) enabled = models.BooleanField( default=True, - help_text=_("Enables processing of this schedule by Tower") + help_text=_("Enables processing of this schedule by Tower.") ) dtstart = models.DateTimeField( null=True, default=None, editable=False, - help_text=_("The first occurrence of the schedule occurs on or after this time") + help_text=_("The first occurrence of the schedule occurs on or after this time.") ) dtend = models.DateTimeField( null=True, default=None, editable=False, - help_text=_("The last occurrence of the schedule occurs before this time, aftewards the schedule expires") + help_text=_("The last occurrence of the schedule occurs before this time, aftewards the schedule expires.") ) rrule = models.CharField( max_length=255, - help_text=_("A value representing the schedules iCal recurrence rule") + help_text=_("A value representing the schedules iCal recurrence rule.") ) next_run = models.DateTimeField( null=True, default=None, editable=False, - help_text=_("The next time that the scheduled action will run") + help_text=_("The next time that the scheduled action will run.") ) extra_data = JSONField( blank=True,