uncloud pay cleanups
Signed-off-by: Nico Schottelius <nico@nico-notebook.schottelius.org>
This commit is contained in:
parent
c9be8cc50b
commit
9bf0a99f6a
5 changed files with 324 additions and 239 deletions
|
|
@ -14,7 +14,8 @@ from uncloud_pay.models import Bill, Order, BillRecord, BillingAddress
|
|||
|
||||
|
||||
class BillRecordInline(admin.TabularInline):
|
||||
model = Bill.bill_records.through
|
||||
# model = Bill.bill_records.through
|
||||
model = BillRecord
|
||||
|
||||
# AT some point in the future: expose REPLACED and orders that depend on us
|
||||
# class OrderInline(admin.TabularInline):
|
||||
|
|
@ -29,6 +30,10 @@ class BillAdmin(admin.ModelAdmin):
|
|||
# change_list_template = "uncloud_pay/change_list.html"
|
||||
|
||||
def get_urls(self):
|
||||
"""
|
||||
Create URLs for PDF view
|
||||
"""
|
||||
|
||||
info = "%s_%s" % (self.model._meta.app_label, self.model._meta.model_name)
|
||||
pat = lambda regex, fn: url(regex, self.admin_site.admin_view(fn), name='%s_%s' % (info, fn.__name__))
|
||||
|
||||
|
|
@ -77,7 +82,9 @@ class BillAdmin(admin.ModelAdmin):
|
|||
|
||||
|
||||
admin.site.register(Bill, BillAdmin)
|
||||
#admin.site.register(Order, OrderAdmin)
|
||||
admin.site.register(Order)
|
||||
admin.site.register(BillRecord)
|
||||
admin.site.register(BillingAddress)
|
||||
|
||||
|
||||
#admin.site.register(Order, OrderAdmin)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue