Skip to content

Commit 7104e51

Browse files
Update verbose name + help text for JIRA password field
1 parent a6b411a commit 7104e51

3 files changed

Lines changed: 5 additions & 5 deletions

File tree

dojo/db_migrations/0001_squashed_0090_index_duplicate_finding.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -265,8 +265,8 @@ class Migration(migrations.Migration):
265265
fields=[
266266
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
267267
('url', models.URLField(help_text='For more information how to configure Jira, read the DefectDojo documentation.', max_length=2000, verbose_name='JIRA URL')),
268-
('username', models.CharField(max_length=2000)),
269-
('password', models.CharField(max_length=2000)),
268+
('username', models.CharField(help_text='Username or Email Address, see DefectDojo documentation for more information.', max_length=2000, verbose_name='Username/Email')),
269+
('password', models.CharField(help_text='Password, API Token, or Personal Access Token, see DefectDojo documentation for more information.', max_length=2000, verbose_name='Password/Token')),
270270
('default_issue_type', models.CharField(choices=[('Task', 'Task'), ('Story', 'Story'), ('Epic', 'Epic'), ('Spike', 'Spike'), ('Bug', 'Bug')], default='Bug', max_length=9)),
271271
('epic_name_id', models.IntegerField(help_text="To obtain the 'Epic name id' visit https://<YOUR JIRA URL>/rest/api/2/field and search for Epic Name. Copy the number out of cf[number] and paste it here.")),
272272
('open_status_key', models.IntegerField(help_text='Transition ID to Re-Open JIRA issues, visit https://<YOUR JIRA URL>/rest/api/latest/issue/<ANY VALID ISSUE KEY>/transitions?expand=transitions.fields to find the ID for your JIRA instance', verbose_name='Reopen Transition ID')),

dojo/forms.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2490,7 +2490,7 @@ class Meta:
24902490

24912491

24922492
class BaseJiraForm(forms.ModelForm):
2493-
password = forms.CharField(widget=forms.PasswordInput, required=True)
2493+
password = forms.CharField(widget=forms.PasswordInput, required=True, help_text=JIRA_Instance._meta.get_field("password").help_text, label=JIRA_Instance._meta.get_field("password").verbose_name)
24942494

24952495
def test_jira_connection(self):
24962496
import dojo.jira_link.helper as jira_helper

dojo/models.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3840,8 +3840,8 @@ def __str__(self):
38403840
class JIRA_Instance(models.Model):
38413841
configuration_name = models.CharField(max_length=2000, help_text=_("Enter a name to give to this configuration"), default="")
38423842
url = models.URLField(max_length=2000, verbose_name=_("JIRA URL"), help_text=_("For more information how to configure Jira, read the DefectDojo documentation."))
3843-
username = models.CharField(max_length=2000)
3844-
password = models.CharField(max_length=2000)
3843+
username = models.CharField(max_length=2000, verbose_name=_("Username/Email"), help_text=_("Username or Email Address, see DefectDojo documentation for more information."))
3844+
password = models.CharField(max_length=2000, verbose_name=_("Password/Token"), help_text=_("Password, API Token, or Personal Access Token, see DefectDojo documentation for more information."))
38453845

38463846
if hasattr(settings, "JIRA_ISSUE_TYPE_CHOICES_CONFIG"):
38473847
default_issue_type_choices = settings.JIRA_ISSUE_TYPE_CHOICES_CONFIG

0 commit comments

Comments
 (0)