title: How to make a slug field autocomplete in a form?
body: <p>Slug field works fine but now I wont it to autocoplete in the form in the site administration. The slug field is connected with the field naslov.
  I wont that text appear on the field slug when I write on the field naslov but with a hyphen and all lowercase.</p>
  
  <p>models.py</p>
  
  <pre><code>from django.db import models
  
  class Question(models.Model):
      naslov = models.CharField(max_length=200)
      slug = models.SlugField()
      opis = models.CharField(max_length=200)
      datum_objave = models.DateTimeField('date published')
      opsirnije_text = models.TextField(max_length=20000)
  
      def __str__(self):             
          return self.naslov
  
      def spremi(self):
          if not self.id:
              self.slug = slugify(self.naslov)
          super(test, self).save()
  
      def was_published_recently(self):
          return self.datum_objave &gt;= timezone.now() - datetime.timedelta(days=1)
  </code></pre>
  
  <p>admin.py</p>
  
  <pre><code>from django.contrib import admin
  
  from .models import Question
  
  
  class QuestionAdmin(admin.ModelAdmin):
     question_fields = {"slug": ("naslov",)}
  
  admin.site.register(Question, QuestionAdmin)
  </code></pre>