vendredi 7 juillet 2017

django admin multi-sort without clear checkbox

I want when user sort the displayed data without clear the already selected checkbox. At present, user selected one data with checkbox selected, when user sorted the data by click another column head, the selected checkbox was cleared. How can I avoid the checkbox from clear?

class statsdata(models.Model):
    timestamp = models.DateTimeField()
    Name = models.CharField(max_length = 30)
    val1 = models.FloatField()
    val2 = models.FloatField()
    val3 = models.FloatField()
class statsdataAdmin(admin.ModelAdmin):
    list_display = ('Name', 'val1', 'val2', 'val3')

Aucun commentaire:

Enregistrer un commentaire