parent
76062f2752
commit
0aafde7b1d
|
|
@ -181,6 +181,7 @@ public class MID_UploadTPB extends SvrProcess{
|
||||||
tpbDetail.setAD_Org_ID(tpb.getAD_Org_ID());
|
tpbDetail.setAD_Org_ID(tpb.getAD_Org_ID());
|
||||||
|
|
||||||
int M_Product_ID =0;
|
int M_Product_ID =0;
|
||||||
|
int precision = tpbLine.getC_Currency().getStdPrecision();
|
||||||
BigDecimal Qty = Env.ZERO;
|
BigDecimal Qty = Env.ZERO;
|
||||||
int C_UOM_ID = 0;
|
int C_UOM_ID = 0;
|
||||||
BigDecimal PriceList = Env.ZERO;
|
BigDecimal PriceList = Env.ZERO;
|
||||||
|
|
@ -222,11 +223,11 @@ public class MID_UploadTPB extends SvrProcess{
|
||||||
}catch (Exception e) {
|
}catch (Exception e) {
|
||||||
Discount = Env.ZERO;
|
Discount = Env.ZERO;
|
||||||
}
|
}
|
||||||
PriceActual = PriceList.subtract(Discount.divide(Env.ONEHUNDRED, 2,BigDecimal.ROUND_DOWN).multiply(PriceList));
|
PriceActual = PriceList.subtract(Discount.divide(Env.ONEHUNDRED, precision,BigDecimal.ROUND_DOWN).multiply(PriceList));
|
||||||
}else if (AJU_DocType_Value.equals("40") || AJU_DocType_Value.equals("41")){
|
}else if (AJU_DocType_Value.equals("40") || AJU_DocType_Value.equals("41")){
|
||||||
Qty = new BigDecimal(rowBarang.getCell(16).getStringCellValue());
|
Qty = new BigDecimal(rowBarang.getCell(16).getStringCellValue());
|
||||||
PriceList = new BigDecimal(rowBarang.getCell(11).getStringCellValue());
|
PriceList = new BigDecimal(rowBarang.getCell(11).getStringCellValue());
|
||||||
PriceList = PriceList.divide(Qty,2,BigDecimal.ROUND_DOWN);
|
PriceList = PriceList.divide(Qty,precision,BigDecimal.ROUND_DOWN);
|
||||||
PriceActual = PriceList;
|
PriceActual = PriceList;
|
||||||
}else{
|
}else{
|
||||||
Qty = new BigDecimal(rowBarang.getCell(8).getStringCellValue());
|
Qty = new BigDecimal(rowBarang.getCell(8).getStringCellValue());
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue