--- /dev/null
+from django.contrib import admin
+from xerxes.base.models import UserProfile
+
+class UserProfileAdmin(admin.ModelAdmin):
+ pass
+
+admin.site.register(UserProfile, UserProfileAdmin)
else:
return self.name
-# class Admin:
-# fields = (
-# (None, {'fields' : ('name', 'title')} ),
-# ('Registrations', {'fields' : ('slots',)} ),
-# )
-
class Registration(models.Model):
person = models.ForeignKey(User, edit_inline=models.STACKED, num_in_admin=3)
event = models.ForeignKey(Event, core=True)
--- /dev/null
+from django.contrib import admin
+from xerxes.influences.models import Character, Influence
+
+class CharacterAdmin(admin.ModelAdmin):
+ list_filter=('status', 'player')
+ search_fields=('name',)
+ list_display=('player', 'name', 'status')
+
+admin.site.register(Character, CharacterAdmin)
+
+class InfluenceAdmin(admin.ModelAdmin):
+ list_filter=('character', 'status', 'longterm')
+ search_fields=('character', 'summary', 'description', 'contact')
+ list_display=('character', 'contact', 'summary', 'longterm', 'status')
+
+admin.site.register(Influence, InfluenceAdmin)
+
def __str__(self):
return self.name
- class Admin:
- list_filter=('status', 'player')
- search_fields=('name')
- list_display=('player', 'name', 'status')
-
class Meta:
verbose_name = _("Character")
verbose_name_plural = _("Characters")
def __str__(self):
return self.summary
- class Admin:
- list_filter=('character', 'status', 'longterm')
- search_fields=('character', 'summary', 'description', 'contact')
- list_display=('character', 'contact', 'summary', 'longterm', 'status')
-
class Meta:
verbose_name = _("Influence")
verbose_name_plural = _("Influences")