diff --git a/src/main/java/zw/qantra/tm/domain/workflows/handlers/erp/PurchaseInvoiceHandler.java b/src/main/java/zw/qantra/tm/domain/workflows/handlers/erp/PurchaseInvoiceHandler.java index 814b6eb..6952e2f 100644 --- a/src/main/java/zw/qantra/tm/domain/workflows/handlers/erp/PurchaseInvoiceHandler.java +++ b/src/main/java/zw/qantra/tm/domain/workflows/handlers/erp/PurchaseInvoiceHandler.java @@ -30,6 +30,8 @@ import java.math.RoundingMode; import java.nio.charset.StandardCharsets; import java.util.*; +import static java.time.OffsetDateTime.now; + @Service("purchaseInvoice") @RequiredArgsConstructor public class PurchaseInvoiceHandler implements HandlerInterface { @@ -139,8 +141,8 @@ public class PurchaseInvoiceHandler implements HandlerInterface { .doctype("Purchase Invoice") .supplier("Steward Bank") .company(erpnextCompany) - .postingDate(transaction.getCreatedAt().toLocalDate().toString()) - .dueDate(transaction.getCreatedAt().toLocalDate().plusDays(1).toString()) + .postingDate(now().toLocalDate().toString()) + .dueDate(now().toLocalDate().plusDays(1).toString()) .docstatus(1) .isReturn(0) .isPaid(0)