Compare commits

...

79 Commits

Author SHA1 Message Date
ihsan 5ff0cae4d6 Merge branch 'develop_v1.4.8' of https://github.com/mohamadihsan/topuponline into develop_v1.4.9 2024-01-24 19:11:39 +07:00
lutfi c80b12ba53 update 2024-01-24 12:57:14 +07:00
ihsan 30c32ca293 Merge branch 'develop_v1.4.8' 2024-01-03 05:34:11 +07:00
lutfi 4d47090994 update generate cash-in 2024-01-02 19:09:30 +07:00
ihsan 3fefaed395 Merge branch 'develop_v1.4.8' 2023-12-28 19:19:39 +07:00
lutfi b1be54d5ba update generate cash-in 2023-12-28 14:19:37 +07:00
ihsan 536d1a5c94 Merge branch 'develop_v1.4.8' 2023-12-24 00:17:38 +07:00
ihsan 5d8369edd8 disable log login partner 2023-12-24 00:17:20 +07:00
lutfi 3c26dd6e23 update generate cash-in 2023-12-20 14:27:11 +07:00
ihsan 0baf1332b6 Merge branch 'develop_v1.4.8' 2023-11-25 17:25:30 +07:00
ihsan 5aca4559c2 update 2023-11-25 17:25:10 +07:00
ihsan 21a45058f0 Merge branch 'develop_v1.4.8' 2023-11-25 17:20:02 +07:00
ihsan edc70c3e6b update 2023-11-25 17:19:39 +07:00
ihsan 4bb2facddb Merge branch 'develop_v1.4.8' 2023-11-24 18:22:40 +07:00
ihsan 466c18fe21 update 2023-11-24 18:22:21 +07:00
ihsan ed11c6ccc4 Merge branch 'develop_v1.4.8' 2023-11-24 17:52:45 +07:00
ihsan 3515b5459f update 2023-11-24 17:52:28 +07:00
ihsan e4cf444b83 Merge branch 'develop_v1.4.8' 2023-11-24 16:11:27 +07:00
ihsan ddf01d2246 update 2023-11-24 16:11:10 +07:00
ihsan 1fb0913eb5 update 2023-11-24 16:03:14 +07:00
ihsan 293602bed2 Merge branch 'develop_v1.4.8' 2023-11-24 14:39:51 +07:00
ihsan 87461a4a14 update 2023-11-24 14:39:26 +07:00
ihsan fbcae2e596 update 2023-11-24 14:38:57 +07:00
ihsan c7f816a449 Merge branch 'develop_v1.4.8' 2023-11-24 14:32:05 +07:00
ihsan eeab7627ae update 2023-11-24 14:30:59 +07:00
ihsan 9052668cbc Merge branch 'develop_v1.4.8' 2023-11-24 14:17:43 +07:00
ihsan f615e9207f update 2023-11-24 14:17:26 +07:00
ihsan 1ba983e745 Merge branch 'develop_v1.4.8' 2023-11-24 14:14:50 +07:00
ihsan 8f254758dd update 2023-11-24 14:14:28 +07:00
ihsan e7c4388956 Merge branch 'develop_v1.4.8' 2023-11-24 13:37:57 +07:00
ihsan 3d31e6f6a5 update 2023-11-24 13:37:23 +07:00
ihsan 1b3991c82f Merge branch 'develop_v1.4.8' 2023-11-24 13:31:09 +07:00
ihsan 38edd07d65 update 2023-11-24 13:30:08 +07:00
ihsan fff4915078 Merge branch 'develop_v1.4.8' 2023-11-24 13:05:36 +07:00
ihsan 820f833844 update 2023-11-24 13:05:20 +07:00
ihsan 1bd85ba888 Merge branch 'develop_v1.4.8' 2023-11-24 12:54:07 +07:00
ihsan cab77e8872 update 2023-11-24 12:52:30 +07:00
ihsan 7b52cebeb7 Merge branch 'develop_v1.4.8' 2023-11-24 10:44:26 +07:00
ihsan 4c3496e9f2 update 2023-11-24 10:43:59 +07:00
ihsan 529d6d7ffc Merge branch 'develop_v1.4.8' 2023-11-06 19:56:39 +07:00
ihsan 5ca30fbfc4 update bugs 2023-11-06 19:56:17 +07:00
ihsan d3729ab906 Merge branch 'develop_v1.4.8' 2023-11-06 19:50:50 +07:00
ihsan 95bfc120c5 update bugs 2023-11-06 19:50:36 +07:00
ihsan 9e98533ffb Merge branch 'develop_v1.4.8' 2023-11-06 19:47:09 +07:00
ihsan 0ab80c0ac4 update bugs 2023-11-06 19:46:45 +07:00
ihsan ef274a483c Merge branch 'develop_v1.4.8' 2023-11-06 19:41:36 +07:00
ihsan d129ad7a2f compare partner token and partner request 2023-11-06 19:41:05 +07:00
ihsan 1f127807d3 Merge branch 'develop_v1.4.7' 2023-11-03 15:50:35 +07:00
ihsan 1014e4374a Merge branch 'develop_v1.4.6' 2023-11-01 16:49:35 +07:00
ihsan 88c3b9bc4a Merge branch 'develop_v1.4.6' 2023-10-20 11:08:13 +07:00
ihsan ffa6830734 Merge branch 'develop_v1.4.6' 2023-10-18 11:18:52 +07:00
ihsan 5a63ca6ea1 Merge branch 'develop_v1.4.5' 2023-10-04 23:24:16 +07:00
ihsan b942d114ad Merge branch 'develop_v1.4.4' 2023-09-28 13:09:43 +07:00
ihsan 7c66ebe702 Merge branch 'develop_v1.4.4' 2023-09-25 18:22:56 +07:00
ihsan 6b0d67ee60 Merge branch 'develop_v1.4.3' 2023-09-17 14:56:11 +07:00
ihsan 7805bc902b Merge branch 'develop_v1.4.2' 2023-09-04 09:23:44 +07:00
ihsan 95f4a03e81 Merge branch 'develop_v1.4.2' 2023-09-01 14:36:51 +07:00
ihsan 4c7230ba6b Merge branch 'develop_v1.4.2' 2023-09-01 14:29:17 +07:00
ihsan 1b2eff69b4 Merge branch 'develop_v1.4.2' 2023-08-31 23:50:15 +07:00
ihsan e3ab361b24 Merge branch 'develop_v1.4.2' 2023-08-31 23:41:02 +07:00
ihsan 14026e8bf0 Merge branch 'develop_v1.4.2' 2023-08-31 23:34:19 +07:00
ihsan 3c1fc92d59 Merge branch 'develop_v1.4.2' 2023-08-31 23:26:16 +07:00
ihsan a333ddb58f Merge branch 'develop_v1.4.2' 2023-08-31 22:43:41 +07:00
ihsan f2c5d65ec0 Merge branch 'develop_v1.4.2' 2023-08-31 22:37:11 +07:00
ihsan bcb9225466 Merge branch 'develop_v1.4.2' 2023-08-31 22:22:41 +07:00
ihsan 90dfdc8857 Merge branch 'develop_v1.4.2' 2023-08-31 22:19:23 +07:00
ihsan 476235440c Merge branch 'develop_v1.4.2' 2023-08-31 22:13:41 +07:00
ihsan 04885f22d6 Merge branch 'develop_v1.4.2' 2023-08-31 21:44:48 +07:00
ihsan 3b68ab9ab3 Merge branch 'develop_v1.4.1' 2023-08-30 12:38:55 +07:00
ihsan a3a4772f77 Merge branch 'develop_v1.4.1' 2023-08-29 19:04:37 +07:00
ihsan 6ef43923e1 Merge branch 'develop_v1.4.1' 2023-08-29 18:40:36 +07:00
ihsan 47af9992be update 2023-08-25 10:39:10 +07:00
ihsan ede3aacef3 Merge branch 'develop_v1.4.1' 2023-07-27 19:14:30 +07:00
ihsan a6b17139bf Merge branch 'develop_v1.4.1' 2023-07-26 16:15:53 +07:00
ihsan 7a7f18701d Merge branch 'develop_v1.4.1' 2023-07-26 16:09:33 +07:00
ihsan e34434f96c Merge branch 'develop_v1.4.0' 2023-07-12 13:30:21 +07:00
ihsan 9cbc467904 Merge remote-tracking branch 'origin/develop_v1.4.0' 2023-07-12 13:19:05 +07:00
ihsan 0a5e82dbbb Merge remote-tracking branch 'origin/develop_v1.4.0' 2023-07-12 13:17:25 +07:00
ihsan 6c7131c944 Merge branch 'develop_v1.3.8' 2023-07-03 13:05:51 +07:00
8 changed files with 555 additions and 194 deletions
+16 -16
View File
@@ -1,8 +1,8 @@
const moment = require("moment"); const moment = require('moment');
const winston = require("winston"); const winston = require('winston');
const loki = require("winston-loki"); const loki = require('winston-loki');
require("winston-daily-rotate-file"); require('winston-daily-rotate-file');
require("dotenv").config(); require('dotenv').config();
const { combine, timestamp, printf, colorize, align, json } = winston.format; const { combine, timestamp, printf, colorize, align, json } = winston.format;
let lokiUrl = process.env.LOKI_URL; let lokiUrl = process.env.LOKI_URL;
@@ -18,32 +18,32 @@ var log;
const fileRotateTransport = new winston.transports.DailyRotateFile({ const fileRotateTransport = new winston.transports.DailyRotateFile({
filename: `./lokiLog/%DATE%-onlinetopup.log`, filename: `./lokiLog/%DATE%-onlinetopup.log`,
datePattern: "YYYY-MM-DD", datePattern: 'YYYY-MM-DD',
maxFiles: "1d", maxFiles: '1d',
}); });
if ( if (
process.env.NODE_ENV == "production" || process.env.NODE_ENV == 'production' ||
process.env.NODE_ENV == "PRODUCTION" process.env.NODE_ENV == 'PRODUCTION'
) { ) {
log = winston.createLogger({ log = winston.createLogger({
levels: logLevels, levels: logLevels,
level: process.env.LOG_LEVEL || "info", level: process.env.LOG_LEVEL || 'info',
exitOnError: false, exitOnError: false,
// format: combine(timestamp(), json()), // format: combine(timestamp(), json()),
format: combine( format: combine(
// colorize({ all: true }), // colorize({ all: true }),
timestamp({ timestamp({
format: "YYYY-MM-DD HH:mm:ss.SSS", format: 'YYYY-MM-DD HH:mm:ss.SSS',
}), }),
align(), align(),
printf((info) => `[${info.timestamp}] ${info.level}: ${info.message}`) printf((info) => `[${info.timestamp}] ${info.level}: ${info.message}`)
), ),
defaultMeta: { service: "topuponline" }, defaultMeta: { service: 'topuponline' },
transports: [ transports: [
new loki({ new loki({
host: lokiUrl, host: lokiUrl,
labels: { app: "topuponline" }, labels: { app: 'topuponline' },
json: true, json: true,
format: json(), format: json(),
replaceTimestamp: true, replaceTimestamp: true,
@@ -59,7 +59,7 @@ if (
transports: [ transports: [
new loki({ new loki({
host: lokiUrl, host: lokiUrl,
labels: { app: "topuponline" }, labels: { app: 'topuponline' },
handleExceptions: true, handleExceptions: true,
handleRejections: true, handleRejections: true,
clearOnError: true, clearOnError: true,
@@ -75,14 +75,14 @@ if (
}); });
} }
if (process.env.NODE_ENV != "testing" && process.env.NODE_ENV != "TESTING") { if (process.env.NODE_ENV != 'testing' && process.env.NODE_ENV != 'TESTING') {
log.add( log.add(
new winston.transports.Console({ new winston.transports.Console({
// format: winston.format.cli(), // format: winston.format.cli(),
format: combine( format: combine(
colorize({ all: true }), colorize({ all: true }),
timestamp({ timestamp({
format: "YYYY-MM-DD HH:mm:ss.SSS", format: 'YYYY-MM-DD HH:mm:ss.SSS',
}), }),
align(), align(),
printf((info) => `[${info.timestamp}] ${info.level}: ${info.message}`) printf((info) => `[${info.timestamp}] ${info.level}: ${info.message}`)
+21 -17
View File
@@ -75,10 +75,14 @@ const loginPartnerUser = async (req, res, next) => {
let { email, password } = req.body; let { email, password } = req.body;
// log info // log info
winston.logger.info( // winston.logger.info(
`${uniqueCode} [ REQUEST LOGIN-PARTNER-USER ]: ${JSON.stringify({ // `${uniqueCode} [ REQUEST LOGIN-PARTNER-USER ]: ${JSON.stringify({
email: email, // email: email,
})}` // })}`
// );
console.log(
`${uniqueCode} [ REQUEST LOGIN-PARTNER-USER ]: ${JSON.stringify(result)}`
); );
// validate // validate
@@ -201,9 +205,9 @@ const loginPartnerUser = async (req, res, next) => {
}; };
// log info // log info
winston.logger.info( // winston.logger.info(
`${uniqueCode} [ RESPONSE LOGIN-PARTNER-USER ]: ${JSON.stringify(result)}` // `${uniqueCode} [ RESPONSE LOGIN-PARTNER-USER ]: ${JSON.stringify(result)}`
); // );
return res.status(200).json(result); return res.status(200).json(result);
} catch (error) { } catch (error) {
@@ -705,11 +709,11 @@ const refreshTokenPartnerUser = async (req, res) => {
let refresh_token = req.header('refresh_token'); let refresh_token = req.header('refresh_token');
// log info // log info
winston.logger.info( // winston.logger.info(
`${uniqueCode} [ REQUEST REFRESH-TOKEN-PARTNER-USER ]: ${JSON.stringify( // `${uniqueCode} [ REQUEST REFRESH-TOKEN-PARTNER-USER ]: ${JSON.stringify(
req.body // req.body
)}` // )}`
); // );
// validate // validate
let err = validationResult(req); let err = validationResult(req);
@@ -837,11 +841,11 @@ const refreshTokenPartnerUser = async (req, res) => {
}; };
// log info // log info
winston.logger.info( // winston.logger.info(
`${uniqueCode} [ RESPONSE REFRESH-TOKEN-PARTNER-USER ]: ${JSON.stringify( // `${uniqueCode} [ RESPONSE REFRESH-TOKEN-PARTNER-USER ]: ${JSON.stringify(
result // result
)}` // )}`
); // );
return res.status(200).json(result); return res.status(200).json(result);
} catch (error) { } catch (error) {
+208 -129
View File
@@ -1,11 +1,11 @@
const { param, body, validationResult } = require("express-validator"); const { param, body, validationResult } = require('express-validator');
const helper = require("../../helpers/helper"); const helper = require('../../helpers/helper');
const winston = require("../../helpers/winston.logger"); const winston = require('../../helpers/winston.logger');
const model = require("./cahsin.model"); const model = require('./cahsin.model');
const moment = require("moment"); const moment = require('moment');
const knex = require("../../../infrastructure/database/knex"); const knex = require('../../../infrastructure/database/knex');
moment.locale("id"); moment.locale('id');
var result = {}; var result = {};
var uniqueCode; var uniqueCode;
@@ -13,14 +13,32 @@ var uniqueCode;
// VALIDATION // VALIDATION
const validate = (method) => { const validate = (method) => {
switch (method) { switch (method) {
case "generateInvoice": case 'generateInvoice':
return [ return [
body('trx_date').notEmpty().withMessage('trx_date is required!').isISO8601().withMessage('invalid trx_date format YYYY-MM-DD !').escape().trim(), body('trx_date')
body('repost').notEmpty().withMessage('repost is required!').isBoolean().withMessage('repost must boolean!').escape().trim(), .notEmpty()
.withMessage('trx_date is required!')
.isISO8601()
.withMessage('invalid trx_date format YYYY-MM-DD !')
.escape()
.trim(),
body('repost')
.notEmpty()
.withMessage('repost is required!')
.isBoolean()
.withMessage('repost must boolean!')
.escape()
.trim(),
]; ];
case "postingInvoice": case 'postingInvoice':
return [ return [
body('trx_date').notEmpty().withMessage('trx_date is required!').isISO8601().withMessage('invalid trx_date format YYYY-MM-DD !').escape().trim(), body('trx_date')
.notEmpty()
.withMessage('trx_date is required!')
.isISO8601()
.withMessage('invalid trx_date format YYYY-MM-DD !')
.escape()
.trim(),
]; ];
default: default:
break; break;
@@ -29,7 +47,6 @@ const validate = (method) => {
// POSTING INVOICE // POSTING INVOICE
const apiGenerateCahsIn = async (req, res) => { const apiGenerateCahsIn = async (req, res) => {
try { try {
// generate unique code // generate unique code
uniqueCode = helper.getUniqueCode(); uniqueCode = helper.getUniqueCode();
@@ -44,7 +61,7 @@ const apiGenerateCahsIn = async (req, res) => {
const err = validationResult(req, res); const err = validationResult(req, res);
if (!err.isEmpty()) { if (!err.isEmpty()) {
result = { result = {
code: "400", code: '400',
message: err.errors[0].msg, message: err.errors[0].msg,
data: {}, data: {},
}; };
@@ -57,16 +74,15 @@ const apiGenerateCahsIn = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
const cashIn = await _generateCashIn(uniqueCode) const cashIn = await _generateCashIn(uniqueCode);
result = { result = {
code: "200", code: '200',
message: "Succes posting", message: 'Succes posting',
data: cashIn data: cashIn,
}; };
return res.status(200).json(result); return res.status(200).json(result);
} catch (error) { } catch (error) {
// create log // create log
winston.logger.error( winston.logger.error(
@@ -74,23 +90,22 @@ const apiGenerateCahsIn = async (req, res) => {
); );
return res.status(200).json({ return res.status(200).json({
code: "500", code: '500',
message: message:
process.env.NODE_ENV != "production" process.env.NODE_ENV != 'production'
? error.message ? error.message
: "500 internal server error - backend server.", : '500 internal server error - backend server.',
data: {}, data: {},
}); });
} }
}; };
// RETRY POSTING INVOICE // RETRY POSTING INVOICE
const apiPostingCahsIn = async (req, res) => { const apiPostingCahsIn = async (req, res) => {
try { try {
// generate unique code // generate unique code
uniqueCode = helper.getUniqueCode() uniqueCode = helper.getUniqueCode();
let { body } = req let { body } = req;
// log info // log info
winston.logger.info( winston.logger.info(
`${uniqueCode} REQUEST posting cash in : ${JSON.stringify(req.body)}` `${uniqueCode} REQUEST posting cash in : ${JSON.stringify(req.body)}`
@@ -100,32 +115,33 @@ const apiPostingCahsIn = async (req, res) => {
const err = validationResult(req, res); const err = validationResult(req, res);
if (!err.isEmpty()) { if (!err.isEmpty()) {
result = { result = {
code: "400", code: '400',
message: err.errors[0].msg, message: err.errors[0].msg,
data: {}, data: {},
}; };
// log warn // log warn
winston.logger.warn( winston.logger.warn(
`${uniqueCode} RESPONSE generate posting cash in : ${JSON.stringify(result)}` `${uniqueCode} RESPONSE generate posting cash in : ${JSON.stringify(
result
)}`
); );
return res.status(200).json(result); return res.status(200).json(result);
} }
// return uniqueCode // return uniqueCode
winston.logger.info(`SCHEDULER-RETRY-${uniqueCode} RE-TRY POSTING CAHS IN`) winston.logger.info(`SCHEDULER-RETRY-${uniqueCode} RE-TRY POSTING CAHS IN`);
const invoice = await _postingCashIn(uniqueCode) const invoice = await _postingCashIn(uniqueCode);
result = { result = {
code: "200", code: '200',
message: "Succes", message: 'Succes',
data: invoice, data: invoice,
} };
return res.status(200).json(result); return res.status(200).json(result);
} catch (error) { } catch (error) {
// create log // create log
winston.logger.error( winston.logger.error(
@@ -133,151 +149,214 @@ const apiPostingCahsIn = async (req, res) => {
); );
return res.status(200).json({ return res.status(200).json({
code: "500", code: '500',
message: message:
process.env.NODE_ENV != "production" process.env.NODE_ENV != 'production'
? error.message ? error.message
: "500 internal server error - backend server.", : '500 internal server error - backend server.',
data: {}, data: {},
}); });
} }
} };
const _generateCashIn = async (uniqueCode) => { const _generateCashIn = async (uniqueCode) => {
let partnerRecon = await model.getPartnerRecon(knex);
let partnerRecon = await model.getPartnerRecon(knex)
// return partnerRecon // return partnerRecon
winston.logger.info(`SCHEDULER-FB70-${uniqueCode} getPartner Recon cash in : ${JSON.stringify(partnerRecon)}`) winston.logger.info(
`SCHEDULER-FB70-${uniqueCode} getPartner Recon cash in : ${JSON.stringify(
partnerRecon
)}`
);
for (const item of partnerRecon) { for (const item of partnerRecon) {
let reserve = [] let reserve = [];
let code = "" let code = '';
await knex.transaction(async trx => { await knex.transaction(async (trx) => {
code = await model.generateCode(trx, item.c_partner_code, moment().format("YYMMDD")) code = await model.generateCode(
winston.logger.info(`SCHEDULER-FB70-${uniqueCode} generate cash in : ${code}`) trx,
item.c_partner_code,
moment().format('YYMMDD')
);
winston.logger.info(
`SCHEDULER-FB70-${uniqueCode} generate cash in : ${code}`
);
// Insert cahs in // Cash-in
const dataCahsIn = { let dataCahsIn = {
c_partner_code : item.c_partner_code, c_partner_code: item.c_partner_code,
c_partner_name : item.c_partner_name, c_partner_name: item.c_partner_name,
c_cash_in_no : code, c_cash_in_no: code,
c_in_period : item.c_in_period, c_in_period: item.c_in_period,
d_credit : item.d_payment, d_credit: item.d_payment,
c_invoice_no : item.c_invoice_no, c_invoice_no: item.c_invoice_no,
i_amount : item.amount i_amount: item.amount,
};
winston.logger.info(
`SCHEDULER-FB70-${uniqueCode} INSERT CASH-IN ${code} DATA : ${JSON.stringify(
dataCahsIn
)}`
);
// CASH-IN DETAIL
let data = [];
const reserv = await model.getReserve(
trx,
item.c_partner_code,
item.d_payment,
item.c_invoice_no
);
//TOTAL AMOUNT CASH-IN
let cashInAmount = 0;
for (const itemCI of reserv) {
cashInAmount += parseInt(itemCI.i_reservation_amount);
} }
dataCahsIn.i_amount = cashInAmount;
winston.logger.info(`SCHEDULER-FB70-${uniqueCode} INSERT CASH-IN ${code} DATA : ${JSON.stringify(dataCahsIn)}`) //INSERT CASH-IN
const cashIn = await model.insertCashIn(trx, dataCahsIn) const cashIn = await model.insertCashIn(trx, dataCahsIn);
winston.logger.info(
`SCHEDULER-FB70-${uniqueCode} INSERT CASH-IN HISTORY ${code} DATA : ${JSON.stringify(
dataCahsIn
)}`
);
const paymentyHistory = await model.writePaynentHistory(
dataCahsIn,
'SUCCESSFULLY',
0,
trx
);
winston.logger.info(`SCHEDULER-FB70-${uniqueCode} INSERT CASH-IN HISTORY ${code} DATA : ${JSON.stringify(dataCahsIn)}`)
const paymentyHistory = await model.writePaynentHistory(dataCahsIn, "SUCCESSFULLY", 0, trx)
// Insert cahs in detail
let data = []
const reserv = await model.getReserve(trx, item.c_partner_code, item.d_payment, item.c_invoice_no)
for (const detail of reserv) { for (const detail of reserv) {
data.push({ // data.push({
i_cash_in : cashIn.i_cash_in, // i_cash_in: cashIn.i_cash_in,
c_reservation_no : detail.c_reservation_no, // c_reservation_no: detail.c_reservation_no,
m_amount : detail.i_reservation_amount, // m_amount: detail.i_reservation_amount,
c_payment_recon_no : detail.c_payment_recon_no, // c_payment_recon_no: detail.c_payment_recon_no,
d_payment : detail.d_payment, // d_payment: detail.d_payment,
d_payment_recon : detail.d_payment_recon, // d_payment_recon: detail.d_payment_recon,
c_load_balance_no : detail.c_load_balance_no // c_load_balance_no: detail.c_load_balance_no,
}) // });
let temp = {
let reserveNo = detail.c_reservation_no i_cash_in: cashIn.i_cash_in,
c_reservation_no: detail.c_reservation_no,
m_amount: detail.i_reservation_amount,
c_payment_recon_no: detail.c_payment_recon_no,
d_payment: detail.d_payment,
d_payment_recon: detail.d_payment_recon,
c_load_balance_no: detail.c_load_balance_no,
};
let reserveNo = detail.c_reservation_no;
let dataReserve = { let dataReserve = {
c_cash_in_no : cashIn.c_cash_in_no, c_cash_in_no: cashIn.c_cash_in_no,
d_credit : cashIn.d_credit, d_credit: cashIn.d_credit,
c_in_period : cashIn.c_in_period, c_in_period: cashIn.c_in_period,
};
await model.updateIntoReserve(trx, dataReserve, reserveNo);
await model.insertCashInDetail(trx, temp);
} }
await model.updateIntoReserve(trx, dataReserve, reserveNo) await wait(5000);
winston.logger.info(
} `SCHEDULER-FB70-${uniqueCode} INSERT CASH-IN TO RESERVE ${code} DATA : ${JSON.stringify(
await wait(5000) dataCahsIn
winston.logger.info(`SCHEDULER-FB70-${uniqueCode} INSERT CASH-IN TO RESERVE ${code} DATA : ${JSON.stringify(dataCahsIn)}`) )}`
await model.insertCashInDetail(trx, data) );
// await model.insertCashInDetail(trx, data);
// await model.insertPostingEt(code, item, trx) // await model.insertPostingEt(code, item, trx)
});
})
} }
return partnerRecon return partnerRecon;
};
}
const _postingCashIn = async (uniqueCode) => { const _postingCashIn = async (uniqueCode) => {
let data = [] let data = [];
let postingEt = await model.getPostingEt(knex) let postingEt = await model.getPostingEt(knex);
for (const item of postingEt) { for (const item of postingEt) {
await knex.transaction(async trx => { await knex.transaction(async (trx) => {
winston.logger.info(
winston.logger.info(`SCHEDULER-RETRY-${uniqueCode} GET POSTING ET : ${JSON.stringify(item)}`) `SCHEDULER-RETRY-${uniqueCode} GET POSTING ET : ${JSON.stringify(item)}`
);
let xmlHeader = { let xmlHeader = {
doc_header_text : item.doc_header_text ? item.doc_header_text : "", doc_header_text: item.doc_header_text ? item.doc_header_text : '',
ba: item.ba ? item.ba : "", ba: item.ba ? item.ba : '',
doc_date : item.doc_date ? item.doc_date : "", doc_date: item.doc_date ? item.doc_date : '',
posting_date : item.posting_date ? item.posting_date : "", posting_date: item.posting_date ? item.posting_date : '',
fisc_year : item.fiscal_year ? item.fiscal_year : "", fisc_year: item.fiscal_year ? item.fiscal_year : '',
fisc_period : item.fis_period ? item.fis_period: "", fisc_period: item.fis_period ? item.fis_period : '',
doc_type: item.doc_type ? item.doc_type : "", doc_type: item.doc_type ? item.doc_type : '',
c_invoice_no : item.reference ? item.reference : "" c_invoice_no: item.reference ? item.reference : '',
} };
let xmlItem = ['S', 'H'].map(key => { let xmlItem = ['S', 'H'].map((key) => {
return { return {
c_account_code_topup : key == 'S' ? item.customer : "", c_account_code_topup: key == 'S' ? item.customer : '',
c_account_topup : key == 'H' ? item.account : "", c_account_topup: key == 'H' ? item.account : '',
ba : item.ba, ba: item.ba,
amount : item.amount, amount: item.amount,
posting_date : item.posting_date, posting_date: item.posting_date,
c_invoice_no : item.reference, c_invoice_no: item.reference,
item_text :key == 'S' ? item.text1 : item.text2, item_text: key == 'S' ? item.text1 : item.text2,
de_cre : key de_cre: key,
} };
}); });
let xmlRequest = helper.generateXMLRequest('ZFMCMS_FI_001', xmlHeader, xmlItem) let xmlRequest = helper.generateXMLRequest(
console.log(xmlRequest) 'ZFMCMS_FI_001',
winston.logger.info(`SCHEDULER-RETRY-${uniqueCode} REQUEST posting ${item.reference} to SAP : ${xmlRequest}`); xmlHeader,
xmlItem
);
console.log(xmlRequest);
winston.logger.info(
`SCHEDULER-RETRY-${uniqueCode} REQUEST posting ${item.reference} to SAP : ${xmlRequest}`
);
const url = 'http://piqas.kereta-api.co.id:51500/XISOAPAdapter/MessageServlet?senderParty=&senderService=KCI_ETICKETING_2&receiverParty=&receiverService=&interface=SI_KCI_CMS_FI01&interfaceNamespace=urn:Posting_ETicketing_2' const url =
'http://piqas.kereta-api.co.id:51500/XISOAPAdapter/MessageServlet?senderParty=&senderService=KCI_ETICKETING_2&receiverParty=&receiverService=&interface=SI_KCI_CMS_FI01&interfaceNamespace=urn:Posting_ETicketing_2';
const response = await helper.postingSAP(url, xmlRequest) const response = await helper.postingSAP(url, xmlRequest);
winston.logger.info(`SCHEDULER-RETRY-${uniqueCode} RESPONSE posting ${item.reference} to SAP : ${JSON.stringify(response)}`); winston.logger.info(
`SCHEDULER-RETRY-${uniqueCode} RESPONSE posting ${
item.reference
} to SAP : ${JSON.stringify(response)}`
);
const resSAP = helper.getXMLData(response) const resSAP = helper.getXMLData(response);
winston.logger.info(`SCHEDULER-RETRY-${uniqueCode} TRANSACTION 2`); winston.logger.info(`SCHEDULER-RETRY-${uniqueCode} TRANSACTION 2`);
// UPDATE CMS // UPDATE CMS
winston.logger.info(`SCHEDULER-RETRY-${uniqueCode} SET resposn FB70 to CMS : ${JSON.stringify(resSAP)}`) winston.logger.info(
`SCHEDULER-RETRY-${uniqueCode} SET resposn FB70 to CMS : ${JSON.stringify(
resSAP
)}`
);
const cms = await model.setReturnSAP(item.no_dok, resSAP, trx) const cms = await model.setReturnSAP(item.no_dok, resSAP, trx);
winston.logger.info(`SCHEDULER-RETRY-${uniqueCode} RESULT CMS : ${JSON.stringify(cms)}`) winston.logger.info(
`SCHEDULER-RETRY-${uniqueCode} RESULT CMS : ${JSON.stringify(cms)}`
}) );
});
} }
return postingEt return postingEt;
};
}
function wait(milliseconds) { function wait(milliseconds) {
return new Promise(resolve => setTimeout(resolve, milliseconds)); return new Promise((resolve) => setTimeout(resolve, milliseconds));
} }
module.exports = { module.exports = {
validate, validate,
apiGenerateCahsIn, apiGenerateCahsIn,
apiPostingCahsIn, apiPostingCahsIn,
_postingCashIn, _postingCashIn,
_generateCashIn _generateCashIn,
}; };
+75 -7
View File
@@ -305,6 +305,65 @@ const getReserve = async (trx, code, date, invoice) => {
}; };
const getPartnerRecon = async (trx) => { const getPartnerRecon = async (trx) => {
// const res = await trx
// .select([
// 'tdpr.c_partner_code',
// 'tdrb.c_partner_name',
// 'tdi.c_invoice_no',
// 'tdi.d_invoice_date',
// trx.raw("to_char(tdpr.d_payment, 'YYYY-MM-DD') AS d_payment"),
// trx.raw('SUM(tdrb.i_reservation_amount) AS amount'),
// 'tmp.c_account_topup',
// 'tmp.c_account_code_topup',
// 'i_company',
// 'i_holding',
// trx.raw(`CASE
// WHEN to_char(tdpr.d_payment, 'MM') >= to_char(tdi.d_invoice_date, 'MM')
// THEN 'IP'
// ELSE
// 'OP'
// END c_in_period`),
// ])
// .from('trx.t_d_reservation_balance AS tdrb')
// .leftJoin('trx.t_d_load_balance as tdlb', function () {
// this.on('tdrb.c_load_balance_no', '=', 'tdlb.c_load_balance_no');
// })
// .leftJoin('payment.t_d_invoice as tdi', function () {
// this.on('tdi.c_invoice_no', '=', 'tdlb.c_invoice_no').orOn(
// 'tdi.c_invoice_no',
// '=',
// 'tdrb.c_invoice_no'
// );
// })
// .leftJoin('payment.t_d_payment_recon as tdpr', function () {
// this.on('tdpr.c_reservation_no', '=', 'tdrb.c_reservation_no');
// })
// .leftJoin('public.t_m_partner as tmp', function () {
// this.on('tmp.i_partner', '=', 'tdrb.i_partner');
// })
// .where('tdrb.c_status', '=', 'A')
// .where('tdi.c_status', '!=', 'X')
// .where('tdpr.c_status', '=', 'S')
// .whereNotNull('tdi.c_return_sap')
// .whereNotNull('tdrb.c_load_balance_no')
// .whereRaw(
// `tdrb.c_reservation_no in (SELECT c_reservation_no FROM payment.t_d_payment_recon where c_status = 'S' ) AND tdrb.c_reservation_no NOT IN (SELECT c_reservation_no FROM payment.t_d_cash_in_detail WHERE b_reversal IS NOT TRUE)`
// )
// .groupBy([
// 'tdpr.c_partner_code',
// 'tdrb.c_partner_name',
// 'tdi.c_invoice_no',
// 'tdi.d_invoice_date',
// 'tdpr.d_payment',
// 'tmp.c_account_topup',
// 'tmp.c_account_code_topup',
// 'tdi.i_company',
// 'i_holding',
// ])
// .limit(1);
// .toSql()
const res = await trx const res = await trx
.select([ .select([
'tdpr.c_partner_code', 'tdpr.c_partner_code',
@@ -312,13 +371,14 @@ const getPartnerRecon = async (trx) => {
'tdi.c_invoice_no', 'tdi.c_invoice_no',
'tdi.d_invoice_date', 'tdi.d_invoice_date',
trx.raw("to_char(tdpr.d_payment, 'YYYY-MM-DD') AS d_payment"), trx.raw("to_char(tdpr.d_payment, 'YYYY-MM-DD') AS d_payment"),
trx.raw('SUM(tdrb.i_reservation_amount) AS amount'), trx.raw('coalesce(SUM(tdrb.i_reservation_amount),0) AS amount'),
// trx.raw('coalesce(SUM(tdcid.m_amount),0) AS amount_cash_in'),
'tmp.c_account_topup', 'tmp.c_account_topup',
'tmp.c_account_code_topup', 'tmp.c_account_code_topup',
'i_company', 'i_company',
'i_holding', 'i_holding',
trx.raw(`CASE trx.raw(`CASE
WHEN to_char(tdpr.d_payment, 'MM') >= to_char(tdi.d_invoice_date, 'MM') WHEN to_char(tdpr.d_payment, 'YYYYMM') >= to_char(tdi.d_invoice_date, 'YYYYMM')
THEN 'IP' THEN 'IP'
ELSE ELSE
'OP' 'OP'
@@ -341,15 +401,16 @@ const getPartnerRecon = async (trx) => {
.leftJoin('public.t_m_partner as tmp', function () { .leftJoin('public.t_m_partner as tmp', function () {
this.on('tmp.i_partner', '=', 'tdrb.i_partner'); this.on('tmp.i_partner', '=', 'tdrb.i_partner');
}) })
// .leftJoin('payment.t_d_cash_in_detail as tdcid', function () {
// this.on('tdcid.c_reservation_no', '=', 'tdrb.c_reservation_no');
// })
.where('tdrb.c_status', '=', 'A') .where('tdrb.c_status', '=', 'A')
.where('tdi.c_status', '!=', 'X') .where('tdi.c_status', '!=', 'X')
.where('tdpr.c_status', '=', 'S') .where('tdpr.c_status', '=', 'S')
.whereNotNull('tdi.c_return_sap') .whereNotNull('tdi.c_return_sap')
.whereNotNull('tdrb.c_load_balance_no') .whereNotNull('tdrb.c_load_balance_no')
.whereRaw( .whereNull('tdrb.c_cash_in_no')
`tdrb.c_reservation_no in (SELECT c_reservation_no FROM payment.t_d_payment_recon where c_status = 'S' ) AND tdrb.c_reservation_no NOT IN (SELECT c_reservation_no FROM payment.t_d_cash_in_detail WHERE b_reversal IS NOT TRUE)`
)
.groupBy([ .groupBy([
'tdpr.c_partner_code', 'tdpr.c_partner_code',
'tdrb.c_partner_name', 'tdrb.c_partner_name',
@@ -361,7 +422,9 @@ const getPartnerRecon = async (trx) => {
'tdi.i_company', 'tdi.i_company',
'i_holding', 'i_holding',
]); ]);
// .toSql() // .havingRaw(
// 'coalesce(SUM(tdrb.i_reservation_amount),0) > coalesce(SUM(tdcid.m_amount),0)'
// );
return res; return res;
}; };
@@ -391,9 +454,14 @@ const generateCode = async (trx, c_partner_code, d_payment_recon) => {
const insertCashInDetail = async (trx, data) => { const insertCashInDetail = async (trx, data) => {
let result = []; let result = [];
if (data.length > 0) { // if (data.length > 0) {
// result = await trx('payment.t_d_cash_in_detail').insert(data, ['*']);
// }
if (data) {
result = await trx('payment.t_d_cash_in_detail').insert(data, ['*']); result = await trx('payment.t_d_cash_in_detail').insert(data, ['*']);
} }
return result; return result;
}; };
@@ -530,6 +530,16 @@ const loadingBalanceRequest = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// get parameter setting pengecekkan nomor kartu dengan card product di CMS // get parameter setting pengecekkan nomor kartu dengan card product di CMS
let getCheckByCardProductStatusValue = let getCheckByCardProductStatusValue =
await model.getCheckByCardProductStatusValue(); await model.getCheckByCardProductStatusValue();
@@ -1251,6 +1261,16 @@ const loadingBalanceInsert = async (req, param) => {
return result; return result;
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log warn // log warn
// winston.logger.warn( // winston.logger.warn(
// `${uniqueCode} [ PROCESSING LOADING-BALANCE-INSERT ]: checking reservation status...` // `${uniqueCode} [ PROCESSING LOADING-BALANCE-INSERT ]: checking reservation status...`
@@ -1761,6 +1781,16 @@ const loadingBalanceUpdate = async (param) => {
return result; return result;
} }
// if (getPartner.i_partner != req.partner_id_token) {
// result = {
// code: '412',
// message: 'partner is not match',
// data: {},
// };
// return res.status(200).json(result);
// }
let data = { let data = {
d_load_balance: now, d_load_balance: now,
c_ref_no: ref_no, c_ref_no: ref_no,
@@ -119,6 +119,9 @@ const checkReservation = async (req, res) => {
`${uniqueCode} [ REQUEST RESERVATION-CHECK ]: ${JSON.stringify(req.body)}` `${uniqueCode} [ REQUEST RESERVATION-CHECK ]: ${JSON.stringify(req.body)}`
); );
// trim card number
card_number = card_number.trim();
// check validator // check validator
let err = validationResult(req, res); let err = validationResult(req, res);
if (!err.isEmpty()) { if (!err.isEmpty()) {
@@ -209,6 +212,16 @@ const checkReservation = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log debug // log debug
// lakukan pencarian ke table reservasion, apakah nomor kartu yang di request masih mempunyai transaksi reservasi saldo yang status nya masih pending atau in progress // lakukan pencarian ke table reservasion, apakah nomor kartu yang di request masih mempunyai transaksi reservasi saldo yang status nya masih pending atau in progress
// winston.logger.debug( // winston.logger.debug(
@@ -288,6 +301,9 @@ const reservationValidate = async (req, res) => {
)}` )}`
); );
// trim card number
card_number = card_number.trim();
// check validator // check validator
let err = validationResult(req, res); let err = validationResult(req, res);
if (!err.isEmpty()) { if (!err.isEmpty()) {
@@ -388,6 +404,16 @@ const reservationValidate = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log debug // log debug
// get settingan dari parameter apakah nomor kartu yang di request harus di cek dengan data card product CMS atau tidak // get settingan dari parameter apakah nomor kartu yang di request harus di cek dengan data card product CMS atau tidak
// winston.logger.debug( // winston.logger.debug(
@@ -708,6 +734,9 @@ const reservationValidateV2 = async (req, res) => {
)}` )}`
); );
// trim card number
// card_number = card_number.trim();
// check validator // check validator
let err = validationResult(req, res); let err = validationResult(req, res);
if (!err.isEmpty()) { if (!err.isEmpty()) {
@@ -808,6 +837,16 @@ const reservationValidateV2 = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log debug // log debug
// get settingan dari parameter apakah nomor kartu yang di request harus di cek dengan data card product CMS atau tidak // get settingan dari parameter apakah nomor kartu yang di request harus di cek dengan data card product CMS atau tidak
// winston.logger.debug( // winston.logger.debug(
@@ -1179,6 +1218,9 @@ const reservation = async (req, res) => {
`${uniqueCode} [ REQUEST RESERVATION ]: ${JSON.stringify(req.body)}` `${uniqueCode} [ REQUEST RESERVATION ]: ${JSON.stringify(req.body)}`
); );
// trim card number
card_number = card_number.trim();
// check validator // check validator
let err = validationResult(req, res); let err = validationResult(req, res);
if (!err.isEmpty()) { if (!err.isEmpty()) {
@@ -1269,6 +1311,16 @@ const reservation = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log debug // log debug
// get settingan dari parameter apakah nomor kartu yang di request harus di cek dengan data card product CMS atau tidak // get settingan dari parameter apakah nomor kartu yang di request harus di cek dengan data card product CMS atau tidak
// winston.logger.debug( // winston.logger.debug(
@@ -1829,6 +1881,9 @@ const reservationV2 = async (req, res) => {
`${uniqueCode} [ REQUEST RESERVATION-V2 ]: ${JSON.stringify(req.body)}` `${uniqueCode} [ REQUEST RESERVATION-V2 ]: ${JSON.stringify(req.body)}`
); );
// trim card number
// card_number = card_number.trim();
// check validator // check validator
let err = validationResult(req, res); let err = validationResult(req, res);
if (!err.isEmpty()) { if (!err.isEmpty()) {
@@ -2057,6 +2112,16 @@ const reservationV2 = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log debug // log debug
// get settingan dari parameter apakah nomor kartu yang di request harus di cek dengan data card product CMS atau tidak // get settingan dari parameter apakah nomor kartu yang di request harus di cek dengan data card product CMS atau tidak
// winston.logger.debug( // winston.logger.debug(
@@ -2697,6 +2762,16 @@ const cancelReservationValidate = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log debug // log debug
// proses pengecekkan status reservation number yang di request // proses pengecekkan status reservation number yang di request
// winston.logger.debug( // winston.logger.debug(
@@ -2882,6 +2957,16 @@ const cancelReservation = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log debug // log debug
// proses pengecekkan status reservation number yang di request // proses pengecekkan status reservation number yang di request
// winston.logger.debug( // winston.logger.debug(
@@ -3358,6 +3443,16 @@ const cancelReservationValidateV2 = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
let getReservationCanBeCanceled; let getReservationCanBeCanceled;
// jika cancelation reservation dilakukan dengan menggunakan ref no // jika cancelation reservation dilakukan dengan menggunakan ref no
@@ -3776,6 +3871,16 @@ const cancelReservationV2 = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log debug // log debug
// proses pengecekkan status reservation number yang di request // proses pengecekkan status reservation number yang di request
// winston.logger.debug( // winston.logger.debug(
@@ -4022,6 +4127,16 @@ const cancelReservationV2_1 = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// log debug // log debug
// proses pengecekkan status reservation number yang di request // proses pengecekkan status reservation number yang di request
// winston.logger.debug( // winston.logger.debug(
@@ -4279,6 +4394,16 @@ const getFeeSharing = async (req, res) => {
return res.status(200).json(result); return res.status(200).json(result);
} }
if (getPartner.i_partner != req.partner_id_token) {
result = {
code: '412',
message: 'partner is not match',
data: {},
};
return res.status(200).json(result);
}
// set default issuer fee // set default issuer fee
let issuerFee = 0; let issuerFee = 0;
let channelFee = 0; let channelFee = 0;
@@ -4333,6 +4458,51 @@ const getFeeSharing = async (req, res) => {
} }
}; };
const decrpytRequest = async (req, res) => {
try {
// generate unique code
// unique code ini digunakan untuk keperluan log agar mudah untuk dibaca
let uniqueCode = await helper.getUniqueCode();
let result = {};
let { reservation_data } = req.body;
// log info
winston.logger.info(
`${uniqueCode} [ REQUEST DECRYPT ]: ${JSON.stringify(req.body)}`
);
reservationData = helper.decryptText(reservation_data);
// parsing data to json format
parseData = JSON.parse(reservationData);
result = {
code: '00',
message: 'decrypted successfully.',
data: parseData,
};
// log warn
winston.logger.info(
`${uniqueCode} [ RESPONSE DECRYPT ]: ${JSON.stringify(result)}`
);
return res.status(200).json(result);
} catch (error) {
result = {
code: '500',
message: 'decrypted failed.',
data: {},
};
// log warn
winston.logger.error(
`${uniqueCode} [ RESPONSE DECRYPT ]: ${JSON.stringify(result)}`
);
return res.status(200).json(result);
}
};
module.exports = { module.exports = {
validate, validate,
checkReservation, checkReservation,
@@ -4349,4 +4519,5 @@ module.exports = {
cancelReservationV2, cancelReservationV2,
cancelReservationV2_1, cancelReservationV2_1,
getFeeSharing, getFeeSharing,
decrpytRequest,
}; };
@@ -98,6 +98,12 @@ router.post(
controller.getFeeSharing controller.getFeeSharing
); );
router.post(
'/reservation/decrypt',
auth.authenticateToken,
controller.decrpytRequest
);
// router.post( // router.post(
// '/reservation/cancel/v2.1', // '/reservation/cancel/v2.1',
// auth.authenticateToken, // auth.authenticateToken,
+3
View File
@@ -42,6 +42,9 @@ DB_PORT_POOLING=5432
DB_USER_POOLING=postgres DB_USER_POOLING=postgres
DB_PASSWORD_POOLING=inhc0mmute_cms DB_PASSWORD_POOLING=inhc0mmute_cms
# ==================================== LOKI =====================================
LOKI_URL=http://10.20.14.30:3100
# ==================================== LOKI ===================================== # ==================================== LOKI =====================================
LOKI_URL=http://localhost:3100 LOKI_URL=http://localhost:3100