Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Biblia autoslug #15

Open
wants to merge 1 commit into from

1 participant

Nolan Brubaker
Nolan Brubaker

Use hidden input for slugs, which are automatically generated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Dec 06, 2011
Nolan Brubaker nrb Make slug input field hidde instead of manual. b74a179
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 4 additions and 1 deletion. Show diff stats Hide diff stats

  1. +4 1 biblion/forms.py
5 biblion/forms.py
@@ -16,6 +16,9 @@
16 16 class BiblionForm(forms.ModelForm):
17 17
18 18 contributors = forms.ModelMultipleChoiceField(queryset=User.objects.none())
  19 + slug = forms.CharField(
  20 + widget = forms.HiddenInput()
  21 + )
19 22
20 23 class Meta:
21 24 model = Biblion
@@ -59,7 +62,7 @@ class PostForm(forms.ModelForm):
59 62 widget = forms.TextInput(),
60 63 )
61 64 slug = forms.CharField(
62   - widget = forms.TextInput()
  65 + widget = forms.HiddenInput()
63 66 )
64 67 teaser = forms.CharField(
65 68 widget = forms.Textarea(),

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.