no message

main
HUOJIN\92525 2024-12-18 13:34:30 +08:00
parent 817c3fc2e0
commit 6ee81c7ad9
3 changed files with 10 additions and 8 deletions

View File

@ -1365,11 +1365,9 @@ public Double initTaxMoney(Map map){
* *
*/ */
public void saveInvoicePay(List<Long> ids,String invoiceNo,Date issuingDate,String transferVoucher){ public void saveInvoicePay(List<Long> ids,String invoiceNo,Date issuingDate,String transferVoucher){
long invoiceId=0;
for(Long invoiceID :ids){ for(Long invoiceID :ids){
Invoice invoice=this.commonDao.load(Invoice.class, invoiceID); Invoice invoice=this.commonDao.load(Invoice.class, invoiceID);
invoiceId=invoiceID;
invoice.setIssuingDate(issuingDate); invoice.setIssuingDate(issuingDate);
invoice.setCashFee(invoice.getBillingFee()); invoice.setCashFee(invoice.getBillingFee());
invoice.setTransferVoucher(transferVoucher); invoice.setTransferVoucher(transferVoucher);
@ -1395,20 +1393,21 @@ public Double initTaxMoney(Map map){
invoice.setInvoiceState(FeeStatus.VERIFICATION); invoice.setInvoiceState(FeeStatus.VERIFICATION);
commonDao.store(invoice); commonDao.store(invoice);
}
//回写调度单上的支付状态 //回写调度单上的支付状态
if(invoiceId>0){ if(invoiceID>0){
List<Long> idss = commonDao.findByQuery("select f.billId from Fee f where f.applyBillDetail.invoice.id=:id and f.billObject='SHIPMENT' group by f.billId ", List<Long> idss = commonDao.findByQuery("select f.billId from Fee f where f.applyBillDetail.invoice.id=:id and f.billObject='SHIPMENT' group by f.billId ",
new String[] { "id"},new Object[] {invoiceId}); new String[] { "id"},new Object[] {invoiceID});
for(Long id :idss){ for(Long id :idss){
Shipment s =this.load(Shipment.class, id); Shipment s =this.load(Shipment.class, id);
s.setNeedSinglePrice(true);//已支付 s.setNeedSinglePrice(true);//已支付
commonDao.store(s); commonDao.store(s);
} }
} }
} }
}
public void saveInvoicePay(ApplyBillDetail ad,String invoiceNo,Date issuingDate,int taxRate,double ticketMat,double outTicketMat,double turnover,String payOrReceive){ public void saveInvoicePay(ApplyBillDetail ad,String invoiceNo,Date issuingDate,int taxRate,double ticketMat,double outTicketMat,double turnover,String payOrReceive){
ApplyBill a =commonDao.load(ApplyBill.class, ad.getApplyBill().getId()); ApplyBill a =commonDao.load(ApplyBill.class, ad.getApplyBill().getId());

View File

@ -321,10 +321,10 @@ public class DefaultBillFeeManager extends DefaultBaseManager implements BillFee
public void Refresh(Long BillFeeID){ public void Refresh(Long BillFeeID){
BillFee b = commonDao.load(BillFee.class,BillFeeID); BillFee b = commonDao.load(BillFee.class,BillFeeID);
List<Object> Objects1 = commonDao.findByQuery("select COALESCE(sum(f.totalFee),0) from Fee f " List<Object> Objects1 = commonDao.findByQuery("select COALESCE(sum(f.totalFee),0) from Fee f "
+ " where f.billFee.id =:id and f.feeName.name not in ('其他费','油卡费') ", + " where f.billFee.id =:id and f.feeName.name not in ('其他费','油卡费','预付款') ",
new String[] { "id"},new Object[] {BillFeeID}); new String[] { "id"},new Object[] {BillFeeID});
List<Object> Objects2 = commonDao.findByQuery("select COALESCE(sum(f.totalFee),0) from Fee f " List<Object> Objects2 = commonDao.findByQuery("select COALESCE(sum(f.totalFee),0) from Fee f "
+ " where f.billFee.id =:id and f.feeName.name in ('其他费','油卡费') ", + " where f.billFee.id =:id and f.feeName.name in ('其他费','油卡费','预付款') ",
new String[] { "id"},new Object[] {BillFeeID}); new String[] { "id"},new Object[] {BillFeeID});
b.setTotalFee((Double)Objects1.get(0)-(Double)Objects2.get(0)); b.setTotalFee((Double)Objects1.get(0)-(Double)Objects2.get(0));
commonDao.store(b); commonDao.store(b);

View File

@ -477,6 +477,9 @@ public class DefaultFeeManager extends DefaultBaseManager implements FeeManager
order.setFee9(s.getFee7()/Legss.size());//实际成本 order.setFee9(s.getFee7()/Legss.size());//实际成本
order.setProfit(DoubleUtils.format3Fraction(order.getReceivefee()-order.getFee9()));//利润 order.setProfit(DoubleUtils.format3Fraction(order.getReceivefee()-order.getFee9()));//利润
order.setFee5(s.getFee6()); order.setFee5(s.getFee6());
order.setDriverName(s.getDriverName());
order.setVehicleCode(s.getLicense());
order.setExpectLicense(s.getVehicleType().getName());
commonDao.store(order); commonDao.store(order);
} }
} }