no message
parent
0546bdfb17
commit
495cbc4744
|
|
@ -4060,16 +4060,30 @@ public class DefaultCustomsOrderManager extends DefaultBaseManager implements Cu
|
|||
|
||||
@Override
|
||||
public void totalFee(List<Long> ids) {
|
||||
DecimalFormat df =new DecimalFormat("#0.00");
|
||||
double feeMenoy=0;
|
||||
double actualMoney=0;
|
||||
StringBuffer mBuffer1 = new StringBuffer();
|
||||
|
||||
// 使用 BigDecimal 初始化金额变量
|
||||
|
||||
BigDecimal feeMenoys = BigDecimal.ZERO; // 应收
|
||||
BigDecimal actualMoneys = BigDecimal.ZERO; // 实收
|
||||
|
||||
|
||||
|
||||
for(Long id:ids){
|
||||
Fee fee=commonDao.load(Fee.class, id);
|
||||
feeMenoy+=fee.getFeeMenoy();
|
||||
actualMoney+=fee.getActualMoney();
|
||||
BigDecimal feeMenoy = new BigDecimal(fee.getFeeMenoy()).setScale(2, RoundingMode.HALF_UP);
|
||||
feeMenoys = feeMenoys.add(feeMenoy);
|
||||
BigDecimal actualMoney = new BigDecimal(fee.getFeeMenoy()).setScale(2, RoundingMode.HALF_UP);
|
||||
actualMoneys = actualMoneys.add(actualMoney);
|
||||
}
|
||||
double wsMoney=feeMenoy-actualMoney;
|
||||
throw new BusinessException("合计:"+"应付金额:"+df.format(feeMenoy)+" ; "+" 实付金额:"+df.format(actualMoney)+" ; "+" 未付金额:"+df.format(wsMoney));
|
||||
|
||||
|
||||
// 格式化金额为保留两位小数
|
||||
String msg = mBuffer1
|
||||
.append("合计:"+"应付金额:").append(feeMenoys).append(" ; ")
|
||||
.append("实付金额:").append(actualMoneys).append(" ; ")
|
||||
.append("未付金额:").append(feeMenoys.subtract(actualMoneys)).append(" ; ").toString();
|
||||
throw new BusinessException(msg);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
@ -4125,7 +4139,6 @@ public class DefaultCustomsOrderManager extends DefaultBaseManager implements Cu
|
|||
BigDecimal issuingMoneys = BigDecimal.ZERO; // 开票金额
|
||||
BigDecimal noTaxMoneys = BigDecimal.ZERO; // 未税金额
|
||||
BigDecimal taxAmounts = BigDecimal.ZERO; // 税额
|
||||
|
||||
for (Long id : ids) {
|
||||
BillFee bf = commonDao.load(BillFee.class, id);
|
||||
|
||||
|
|
|
|||
|
|
@ -552,7 +552,7 @@ public class DefaultMasterBolManager extends DefaultBaseManager implements Maste
|
|||
//logManager.bolShipResponse(bol);
|
||||
}
|
||||
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
private void pickShip2(PickTicket pt) {
|
||||
|
||||
List<TaskLog> taskLogs = commonDao.findByQuery("FROM TaskLog log WHERE log.movedQuantity>log.shipQuantity and log.task.pickTicketDetail.pickTicket.id = " + pt.getId());
|
||||
|
|
@ -562,9 +562,7 @@ public class DefaultMasterBolManager extends DefaultBaseManager implements Maste
|
|||
PickTicketDetail detail = log.getTask().getPickTicketDetail();
|
||||
//扣减发货单及其明细BOL数量、包箱数量,增加发货单及其明细的发运数量
|
||||
detail.ship(shipQuantity*log.getPackageUnit().getConvertFigure());
|
||||
detail.setStorageDate(log.getStorageDate());
|
||||
commonDao.store(detail);
|
||||
|
||||
//扣减库存
|
||||
inventoryManager.ship(pt.getDock().getId(),
|
||||
log.getItemKey(),
|
||||
shipQuantity,
|
||||
|
|
@ -578,7 +576,6 @@ public class DefaultMasterBolManager extends DefaultBaseManager implements Maste
|
|||
pt.getBillType());
|
||||
detail.setStorageDate(log.getStorageDate());
|
||||
|
||||
|
||||
Location destLocation=this.load(Location.class, 10720L);//10720
|
||||
Warehouse warehouse=this.load(Warehouse.class, 1000L);//非保仓库
|
||||
//非保中转库位;目标库位
|
||||
|
|
|
|||
Loading…
Reference in New Issue