- fix when response is PLN Quota with user name using space

This commit is contained in:
Fadli 2022-11-16 23:53:03 +07:00
parent 33aca34917
commit a819f08dad

View File

@ -1481,6 +1481,7 @@ export class TransactionService {
dataTransaction.seri_number = callback['sn'];
console.log('msksn1', dataTransaction.seri_number);
} else {
console.log('entnewsn', 'msk');
const response = callback['message'];
const responseBaru = response.split(' ');
@ -1492,6 +1493,7 @@ export class TransactionService {
const index = response.indexOf(s);
const subIndex = index + s.length;
const newRes = response.substring(subIndex);
console.log('newres1', newRes);
if (newRes.includes(' .')) {
const splitRes = newRes.split(' .')
const serialNumber = splitRes[0];