- fix update price hemat

This commit is contained in:
Muhammad Fadli 2023-08-30 17:33:34 +07:00
parent b9bc034492
commit fd5ee9655e

View File

@ -1573,10 +1573,18 @@ export class TransactionService {
if (callback['hrg'] != undefined || callback['hrg'] != 'undefined' || callback['hrg'] != null) {
console.log('mskcbhargahemat', 'msk')
dataProductHistoryPrice.price = callback['hrg'];
let numberAsString = callback['hrg'].toString();
let numberWithoutDecimal = numberAsString.replace('.', '');
let integerNumber = parseInt(numberWithoutDecimal);
dataProductHistoryPrice.price = integerNumber;
} else if (callback['data']['additional']['harga'] != undefined || callback['data']['additional']['harga'] != 'undefined' || callback['data']['additional']['harga'] != null) {
console.log('mskcbhargahemat1', 'msk')
dataProductHistoryPrice.price = parseInt(callback['data']['additional']['harga']);
let numberAsString = callback['data']['additional']['harga'].toString();
let numberWithoutDecimal = numberAsString.replace('.', '');
let integerNumber = parseInt(numberWithoutDecimal);
dataProductHistoryPrice.price = integerNumber;
}
} else if (supplier.code == 'Digiflazz') {
if (callback['sn']) {