Answer the question
In order to leave comments, you need to log in
How to automatically assign a number to an "Order"?
Good afternoon.
There is a model:
class Order(models.Model):
'''Заказ'''
order_number = ???
date_added = models.DateTimeField(auto_now_add=True)
date_shipment = models.DateField()
def __str__(self):
return self.order_number
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question