-
-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update organization help text (#11481)
* Update email helptext * Update organization help text Fixes readthedocs/readthedocs-corporate#213 * Add placeholders
- Loading branch information
1 parent
0c92505
commit bf02353
Showing
3 changed files
with
92 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,13 +41,15 @@ class Meta: | |
"name": _("Organization Name"), | ||
"email": _("Billing Email"), | ||
} | ||
|
||
# Don't use a URLField as a widget, the validation is too strict on FF | ||
url = forms.URLField( | ||
widget=forms.TextInput(attrs={"placeholder": "http://"}), | ||
label=_("Site URL"), | ||
required=False, | ||
) | ||
widgets = { | ||
"email": forms.EmailInput(attrs={"placeholder": "[email protected]"}), | ||
# Make description less prominent on the page, we don't want long descriptions | ||
"description": forms.TextInput( | ||
attrs={"placeholder": "Engineering docs for Example company"} | ||
), | ||
# Don't use a URLField as a widget, the validation is too strict on FF | ||
"url": forms.TextInput(attrs={"placeholder": "https://"}), | ||
} | ||
|
||
def __init__(self, *args, **kwargs): | ||
try: | ||
|
79 changes: 79 additions & 0 deletions
79
readthedocs/organizations/migrations/0013_update_naming.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
# Generated by Django 4.2.13 on 2024-07-17 22:41 | ||
|
||
from django.db import migrations, models | ||
from django_safemigrate import Safe | ||
|
||
|
||
class Migration(migrations.Migration): | ||
safe = Safe.always | ||
|
||
dependencies = [ | ||
("organizations", "0012_add_organization_never_disable"), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name="historicalorganization", | ||
name="description", | ||
field=models.TextField( | ||
blank=True, | ||
help_text="A short description shown on your profile page", | ||
null=True, | ||
verbose_name="Description", | ||
), | ||
), | ||
migrations.AlterField( | ||
model_name="historicalorganization", | ||
name="email", | ||
field=models.EmailField( | ||
blank=True, | ||
help_text="Best email address for billing related inquiries", | ||
max_length=255, | ||
null=True, | ||
verbose_name="Email", | ||
), | ||
), | ||
migrations.AlterField( | ||
model_name="historicalorganization", | ||
name="url", | ||
field=models.URLField( | ||
blank=True, | ||
help_text="The main website for your organization", | ||
max_length=255, | ||
null=True, | ||
verbose_name="Home Page", | ||
), | ||
), | ||
migrations.AlterField( | ||
model_name="organization", | ||
name="description", | ||
field=models.TextField( | ||
blank=True, | ||
help_text="A short description shown on your profile page", | ||
null=True, | ||
verbose_name="Description", | ||
), | ||
), | ||
migrations.AlterField( | ||
model_name="organization", | ||
name="email", | ||
field=models.EmailField( | ||
blank=True, | ||
help_text="Best email address for billing related inquiries", | ||
max_length=255, | ||
null=True, | ||
verbose_name="Email", | ||
), | ||
), | ||
migrations.AlterField( | ||
model_name="organization", | ||
name="url", | ||
field=models.URLField( | ||
blank=True, | ||
help_text="The main website for your organization", | ||
max_length=255, | ||
null=True, | ||
verbose_name="Home Page", | ||
), | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters