Reputation: 227
I have a DateTimeField() in my models.py. What I am trying to do is to update it, along with some other values in the model.
Everything else updates fine apart from my DateTimeField(). the error i get says that AttributeError: module 'datetime' has no attribute 'now'
anyone see where I am going wrong with m update?
sModel.objects.all().update(sPasses=pass_number_for_graph, sFails=fail_number_for_graph, sNds=p_number_for_graph, sTimestamp=datetime.now())
Upvotes: 0
Views: 64