Set Resolution Date to include Time

This commit is contained in:
Javier Wong 2016-03-31 18:27:36 +08:00
parent 45c6b550f0
commit 6487b525d0

View File

@ -5,7 +5,7 @@
from __future__ import unicode_literals from __future__ import unicode_literals
import frappe import frappe
from frappe import session, _ from frappe import session, _
from frappe.utils import today from frappe.utils import today, now_datetime
@ -21,7 +21,7 @@ class WarrantyClaim(TransactionBase):
if self.status=="Closed" and \ if self.status=="Closed" and \
frappe.db.get_value("Warranty Claim", self.name, "status")!="Closed": frappe.db.get_value("Warranty Claim", self.name, "status")!="Closed":
self.resolution_date = today() self.resolution_date = now_datetime()
def on_cancel(self): def on_cancel(self):
lst = frappe.db.sql("""select t1.name lst = frappe.db.sql("""select t1.name