bms2相关修改;
This commit is contained in:
+4
-1
@@ -67,4 +67,7 @@ public class SKitem {
|
|||||||
|
|
||||||
@ApiModelProperty( "")
|
@ApiModelProperty( "")
|
||||||
private String def65;
|
private String def65;
|
||||||
}
|
|
||||||
|
@ApiModelProperty( "")
|
||||||
|
private String def75;
|
||||||
|
}
|
||||||
+18
@@ -474,6 +474,16 @@ public class BillManageImpl extends ServiceImpl<BillManageMapper, BillManage> im
|
|||||||
.map(BmsMakeOutInvoiceItem::getFeeType)
|
.map(BmsMakeOutInvoiceItem::getFeeType)
|
||||||
.filter(java.util.Objects::nonNull)
|
.filter(java.util.Objects::nonNull)
|
||||||
.collect(java.util.stream.Collectors.joining("、"));
|
.collect(java.util.stream.Collectors.joining("、"));
|
||||||
|
|
||||||
|
// 按 createTime 倒序排序并获取第一条记录
|
||||||
|
BmsMakeOutInvoiceItem firstItem = bmsMakeOutInvoiceItems.stream()
|
||||||
|
.sorted((a, b) -> {
|
||||||
|
if (a.getCreateTime() == null) return 1;
|
||||||
|
if (b.getCreateTime() == null) return -1;
|
||||||
|
return b.getCreateTime().compareTo(a.getCreateTime());
|
||||||
|
})
|
||||||
|
.findFirst()
|
||||||
|
.orElse(null);
|
||||||
String salesmanId = reconciliation.getSalesmanId();
|
String salesmanId = reconciliation.getSalesmanId();
|
||||||
String customerUserDept = billManageMapper.getCustomerUserDept(salesmanId);
|
String customerUserDept = billManageMapper.getCustomerUserDept(salesmanId);
|
||||||
String deptValue = billManageMapper.getDeptValue(customerUserDept);
|
String deptValue = billManageMapper.getDeptValue(customerUserDept);
|
||||||
@@ -517,6 +527,14 @@ public class BillManageImpl extends ServiceImpl<BillManageMapper, BillManage> im
|
|||||||
item.setScomment("业务部:"+appointShipper+feeTypes);
|
item.setScomment("业务部:"+appointShipper+feeTypes);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// 费用类别
|
||||||
|
String feeType = firstItem.getFeeType();
|
||||||
|
String serviceItemsCodeNc = billManageMapper.getServiceItemsCodeNc(feeType);
|
||||||
|
if (serviceItemsCodeNc != null && !serviceItemsCodeNc.isEmpty()) {
|
||||||
|
item.setDef75(serviceItemsCodeNc);
|
||||||
|
} else {
|
||||||
|
item.setDef75("T10");
|
||||||
|
}
|
||||||
item.setPk_currtype(settlementCurrencyNcCode);
|
item.setPk_currtype(settlementCurrencyNcCode);
|
||||||
item.setMoney_cr(String.valueOf(totalInvoiceValue));
|
item.setMoney_cr(String.valueOf(totalInvoiceValue));
|
||||||
item.setMoney_bal(String.valueOf(totalInvoiceValue));
|
item.setMoney_bal(String.valueOf(totalInvoiceValue));
|
||||||
|
|||||||
+18
@@ -1157,6 +1157,16 @@ public class ReconciliationImpl extends ServiceImpl<ReconciliationMapper, Reconc
|
|||||||
.map(TmsMakeOutInvoiceItem::getFeeType)
|
.map(TmsMakeOutInvoiceItem::getFeeType)
|
||||||
.filter(java.util.Objects::nonNull)
|
.filter(java.util.Objects::nonNull)
|
||||||
.collect(java.util.stream.Collectors.joining("、"));
|
.collect(java.util.stream.Collectors.joining("、"));
|
||||||
|
// 按 createTime 倒序排序并获取第一条记录
|
||||||
|
TmsMakeOutInvoiceItem firstItem = list.stream()
|
||||||
|
.sorted((a, b) -> {
|
||||||
|
if (a.getCreateTime() == null) return 1;
|
||||||
|
if (b.getCreateTime() == null) return -1;
|
||||||
|
return b.getCreateTime().compareTo(a.getCreateTime());
|
||||||
|
})
|
||||||
|
.findFirst()
|
||||||
|
.orElse(null);
|
||||||
|
|
||||||
String salesmanCodeNc=order.getSalesmanCodeNc();
|
String salesmanCodeNc=order.getSalesmanCodeNc();
|
||||||
String salesmanId = order.getSalesmanId();
|
String salesmanId = order.getSalesmanId();
|
||||||
String customerUserDept = reconciliationMapper.getCustomerUserDept(salesmanId);
|
String customerUserDept = reconciliationMapper.getCustomerUserDept(salesmanId);
|
||||||
@@ -1200,6 +1210,14 @@ public class ReconciliationImpl extends ServiceImpl<ReconciliationMapper, Reconc
|
|||||||
item.setScomment("业务部:"+appointShipper+feeTypes);
|
item.setScomment("业务部:"+appointShipper+feeTypes);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// 费用类别
|
||||||
|
String feeType = firstItem.getFeeType();
|
||||||
|
String serviceItemsCodeNc = reconciliationMapper.getServiceItemsCodeNc(feeType);
|
||||||
|
if (serviceItemsCodeNc != null && !serviceItemsCodeNc.isEmpty()) {
|
||||||
|
item.setDef75(serviceItemsCodeNc);
|
||||||
|
} else {
|
||||||
|
item.setDef75("T10");
|
||||||
|
}
|
||||||
item.setPk_currtype(settlementCurrencyNcCode);
|
item.setPk_currtype(settlementCurrencyNcCode);
|
||||||
item.setMoney_cr(String.valueOf(totalInvoiceValue));
|
item.setMoney_cr(String.valueOf(totalInvoiceValue));
|
||||||
item.setMoney_bal(String.valueOf(totalInvoiceValue));
|
item.setMoney_bal(String.valueOf(totalInvoiceValue));
|
||||||
|
|||||||
Reference in New Issue
Block a user