From 0113e6dbb118d351de7c37fd7ff9bc47f4a6bd76 Mon Sep 17 00:00:00 2001 From: lutfi Date: Fri, 25 Oct 2024 05:39:27 +0700 Subject: [PATCH] update d_disburse --- application/modules/refundkmt/refundkmt.controller.js | 5 ++--- application/modules/refundkmt/refundkmt.model.js | 1 + 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/application/modules/refundkmt/refundkmt.controller.js b/application/modules/refundkmt/refundkmt.controller.js index 884e9b3..ec75bb9 100644 --- a/application/modules/refundkmt/refundkmt.controller.js +++ b/application/modules/refundkmt/refundkmt.controller.js @@ -129,8 +129,7 @@ const callbackOy = async (req, res) => { }; } - const unixTimeZero = Date.parse(last_updated_date); - const date_reimbursement = moment(unixTimeZero).format( + const date_reimbursement = moment(last_updated_date, 'DD-MM-YYYY HH:mm:ss').format( 'YYYY-MM-DD HH:mm:ss' ); @@ -142,7 +141,7 @@ const callbackOy = async (req, res) => { await model.updateReplacementComplete( checkRequest.i_card_replacement, checkRequest.c_request_no, - now + date_reimbursement ); /* diff --git a/application/modules/refundkmt/refundkmt.model.js b/application/modules/refundkmt/refundkmt.model.js index d5d0e54..858500f 100644 --- a/application/modules/refundkmt/refundkmt.model.js +++ b/application/modules/refundkmt/refundkmt.model.js @@ -42,6 +42,7 @@ const updateReplacementComplete = (i_replacement, request_no, date_disburse) => .update({ c_status: "A", c_status_name: "COMPLETED", + d_disburse: date_disburse, c_response_code: "000", c_response_message: "Success" });