mirror of
https://github.com/mohamadihsan/topuponline.git
synced 2026-12-06 16:26:26 +00:00
Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 9af6f4f823 | |||
| 5259fd89ef | |||
| 0e35368e22 | |||
| 0fdc901193 | |||
| c3a458313e |
@@ -746,7 +746,12 @@ const loadingBalanceRequest = async (req, res) => {
|
|||||||
`${uniqueCode} [ RESPONSE LOADING-BALANCE-REQUEST DEBUG Y ]: ${card_number}`
|
`${uniqueCode} [ RESPONSE LOADING-BALANCE-REQUEST DEBUG Y ]: ${card_number}`
|
||||||
);
|
);
|
||||||
|
|
||||||
if ((parseInt(lastFlag) <= parseInt(flag)) || (parseInt(lastFlag) == 255 && parseInt(flag) == 0)) {
|
// manipulasi last flag jika flag kartu sudah kembali ke 0
|
||||||
|
if (parseInt(lastFlag) == 255 && parseInt(flag) == 0) {
|
||||||
|
lastFlag = -1
|
||||||
|
}
|
||||||
|
|
||||||
|
if (parseInt(lastFlag) < parseInt(flag)) {
|
||||||
|
|
||||||
winston.logger.warn(
|
winston.logger.warn(
|
||||||
`${uniqueCode} [ RESPONSE LOADING-BALANCE-REQUEST DEBUG Z ]: ${card_number}`
|
`${uniqueCode} [ RESPONSE LOADING-BALANCE-REQUEST DEBUG Z ]: ${card_number}`
|
||||||
@@ -2142,7 +2147,7 @@ const loadingBalanceUpdate = async (param) => {
|
|||||||
|
|
||||||
// log info
|
// log info
|
||||||
winston.logger.info(
|
winston.logger.info(
|
||||||
`${uniqueCode} [ RESPONSE LOADING-BALANCE-INSERT ]: ${JSON.stringify(
|
`${uniqueCode} [ RESPONSE LOADING-BALANCE-UPDATE ]: ${JSON.stringify(
|
||||||
result
|
result
|
||||||
)}`
|
)}`
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -132,7 +132,7 @@ const getReservationPendingWithFlagCounter = (cardNumber, time, flag) => {
|
|||||||
)
|
)
|
||||||
.where('c_card_number', cardNumber)
|
.where('c_card_number', cardNumber)
|
||||||
.whereIn('c_status', ['P', 'I'])
|
.whereIn('c_status', ['P', 'I'])
|
||||||
.whereRaw('??::INT < ??', ['c_flag', parseInt(255)])
|
.whereRaw('??::INT <= ??', ['c_flag', parseInt(255)])
|
||||||
// .where("d_expired", ">=", time)
|
// .where("d_expired", ">=", time)
|
||||||
.where('c_flag', '!=', '-1');
|
.where('c_flag', '!=', '-1');
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
+2
-2
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "topuponline",
|
"name": "topuponline",
|
||||||
"version": "1.5.7",
|
"version": "1.6.0",
|
||||||
"description": "change file rotate log from 90 days to 60 days",
|
"description": "handling maximum flag 255",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "nodemon index",
|
"start": "nodemon index",
|
||||||
|
|||||||
Reference in New Issue
Block a user