Merge pull request #34 from tildetown/feature/enhanced-ticket-view
Better ticket admin viewingnew-signup-questions
commit
3c4eabd42e
|
@ -7,3 +7,7 @@ __pycache__
|
||||||
.viminfo
|
.viminfo
|
||||||
ttadmin/settings_live.py
|
ttadmin/settings_live.py
|
||||||
ttadmin/static
|
ttadmin/static
|
||||||
|
venv/
|
||||||
|
build/
|
||||||
|
dist/
|
||||||
|
|
||||||
|
|
|
@ -3,5 +3,7 @@ from .models import Ticket
|
||||||
|
|
||||||
@admin.register(Ticket)
|
@admin.register(Ticket)
|
||||||
class TicketAdmin(admin.ModelAdmin):
|
class TicketAdmin(admin.ModelAdmin):
|
||||||
list_display = ('issue_status', 'issue_type', 'name', 'email')
|
readonly_fields = ('submitted',)
|
||||||
fields = ('name', 'email', 'issue_status', 'issue_type', 'issue_text')
|
list_display = ('submitted', 'issue_status', 'issue_type', 'name', 'email')
|
||||||
|
list_filter = ('issue_status', 'issue_type')
|
||||||
|
fields = ('submitted', 'name', 'email', 'issue_status', 'issue_type', 'issue_text')
|
||||||
|
|
|
@ -0,0 +1,22 @@
|
||||||
|
# -*- coding: utf-8 -*-
|
||||||
|
# Generated by Django 1.10.2 on 2019-01-19 18:28
|
||||||
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
import django.utils.timezone
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('help', '0003_auto_20171110_2323'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AddField(
|
||||||
|
model_name='ticket',
|
||||||
|
name='submitted',
|
||||||
|
field=models.DateTimeField(auto_now_add=True, default=django.utils.timezone.now),
|
||||||
|
preserve_default=False,
|
||||||
|
),
|
||||||
|
]
|
|
@ -1,4 +1,4 @@
|
||||||
from django.db.models import Model, TextField, EmailField, CharField
|
from django.db.models import Model, TextField, EmailField, CharField, DateTimeField
|
||||||
|
|
||||||
ISSUE_TYPE_CHOICES = (
|
ISSUE_TYPE_CHOICES = (
|
||||||
('logging_in', 'help logging in'),
|
('logging_in', 'help logging in'),
|
||||||
|
@ -18,6 +18,7 @@ ISSUE_STATUS_CHOICES = (
|
||||||
|
|
||||||
|
|
||||||
class Ticket(Model):
|
class Ticket(Model):
|
||||||
|
submitted = DateTimeField(auto_now_add=True)
|
||||||
name = CharField(blank=False, null=False, max_length=100)
|
name = CharField(blank=False, null=False, max_length=100)
|
||||||
email = EmailField(blank=False, null=False)
|
email = EmailField(blank=False, null=False)
|
||||||
issue_type = CharField(choices=ISSUE_TYPE_CHOICES,
|
issue_type = CharField(choices=ISSUE_TYPE_CHOICES,
|
||||||
|
|
|
@ -0,0 +1,20 @@
|
||||||
|
# -*- coding: utf-8 -*-
|
||||||
|
# Generated by Django 1.10.2 on 2019-01-19 18:28
|
||||||
|
from __future__ import unicode_literals
|
||||||
|
|
||||||
|
from django.db import migrations, models
|
||||||
|
|
||||||
|
|
||||||
|
class Migration(migrations.Migration):
|
||||||
|
|
||||||
|
dependencies = [
|
||||||
|
('users', '0009_auto_20170114_0757'),
|
||||||
|
]
|
||||||
|
|
||||||
|
operations = [
|
||||||
|
migrations.AlterField(
|
||||||
|
model_name='pubkey',
|
||||||
|
name='key_type',
|
||||||
|
field=models.CharField(choices=[('ssh-rsa', 'ssh-rsa'), ('ssh-dss', 'ssh-dss'), ('ecdsa-sha2-nistp256', 'ecdsa-sha2-nistp256')], max_length=50),
|
||||||
|
),
|
||||||
|
]
|
Loading…
Reference in New Issue