mixxorz / django-service-objects

Service objects for Django

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

How to use it with nested models for creation ?

isasiluispy opened this issue · comments

class Sale(models.model):
invoice_number = models.CharField(....)

class SaleItem(models.Model):
sale = models.ForeignKey(Sale)
....

How can i use a service for creating a sale with its respective items ? I'll much appreciate the way you would do it.