fix: typo; serial no doesn't have amc start date

This commit is contained in:
thefalconx33 2020-02-05 16:40:58 +05:30
parent c438a20b76
commit fcae88a514

View File

@ -193,7 +193,7 @@ class MaintenanceSchedule(TransactionBase):
if sr_details.amc_expiry_date and getdate(sr_details.amc_expiry_date) >= getdate(amc_start_date):
throw(_("Serial No {0} is under maintenance contract upto {1}")
.format(serial_no, sr_details.amc_start_date))
.format(serial_no, sr_details.amc_expiry_date))
if not sr_details.warehouse and sr_details.delivery_date and \
getdate(sr_details.delivery_date) >= getdate(amc_start_date):