|
|
|
@ -15,9 +15,11 @@ exports.getPayments = (req, res, next) => {
|
|
|
|
|
error: (undefined === body || search_idx > -1) ? 'Error From Server!' : body.error
|
|
|
|
|
});
|
|
|
|
|
} else {
|
|
|
|
|
body.payments.forEach(payment => {
|
|
|
|
|
payment.creation_date_str = (undefined === payment.creation_date) ? '' : common.convertTimestampToDate(payment.creation_date);
|
|
|
|
|
});
|
|
|
|
|
if (undefined !== body.payments) {
|
|
|
|
|
body.payments.forEach(payment => {
|
|
|
|
|
payment.creation_date_str = (undefined === payment.creation_date) ? '' : common.convertTimestampToDate(payment.creation_date);
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
res.status(200).json(body.payments);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|