|
@@ -319,7 +319,7 @@ public class DataController {
|
|
|
listData.setInsuranceCompanyId(item.getCompanyId());
|
|
listData.setInsuranceCompanyId(item.getCompanyId());
|
|
|
Optional<OrderStatusData> first =
|
|
Optional<OrderStatusData> first =
|
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("3")).findFirst();
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("3")).findFirst();
|
|
|
- if (first == null) {
|
|
|
|
|
|
|
+ if (!first.isPresent()) {
|
|
|
listData.setJqPremium("0");
|
|
listData.setJqPremium("0");
|
|
|
listData.setSyPremium("0");
|
|
listData.setSyPremium("0");
|
|
|
listData.setTaxPremium("0");
|
|
listData.setTaxPremium("0");
|
|
@@ -333,35 +333,35 @@ public class DataController {
|
|
|
|
|
|
|
|
Optional<OrderStatusData> first1 =
|
|
Optional<OrderStatusData> first1 =
|
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("0")).findFirst();
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("0")).findFirst();
|
|
|
- if (first1 == null) {
|
|
|
|
|
|
|
+ if (!first1.isPresent()) {
|
|
|
listData.setQuoting("0");
|
|
listData.setQuoting("0");
|
|
|
} else {
|
|
} else {
|
|
|
listData.setQuoting(first1.get().getSumOrderNum().toString());
|
|
listData.setQuoting(first1.get().getSumOrderNum().toString());
|
|
|
}
|
|
}
|
|
|
Optional<OrderStatusData> first2 =
|
|
Optional<OrderStatusData> first2 =
|
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("1")).findFirst();
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("1")).findFirst();
|
|
|
- if (first2 == null) {
|
|
|
|
|
|
|
+ if (!first2.isPresent()) {
|
|
|
listData.setUninsured("0");
|
|
listData.setUninsured("0");
|
|
|
} else {
|
|
} else {
|
|
|
listData.setUninsured(first2.get().getSumOrderNum().toString());
|
|
listData.setUninsured(first2.get().getSumOrderNum().toString());
|
|
|
}
|
|
}
|
|
|
Optional<OrderStatusData> first3 =
|
|
Optional<OrderStatusData> first3 =
|
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("2")).findFirst();
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("2")).findFirst();
|
|
|
- if (first3 == null) {
|
|
|
|
|
|
|
+ if (!first3.isPresent()) {
|
|
|
listData.setUnderwrited("0");
|
|
listData.setUnderwrited("0");
|
|
|
} else {
|
|
} else {
|
|
|
listData.setUnderwrited(first3.get().getSumOrderNum().toString());
|
|
listData.setUnderwrited(first3.get().getSumOrderNum().toString());
|
|
|
}
|
|
}
|
|
|
Optional<OrderStatusData> first4 =
|
|
Optional<OrderStatusData> first4 =
|
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("3")).findFirst();
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("3")).findFirst();
|
|
|
- if (first4 == null) {
|
|
|
|
|
|
|
+ if (!first4.isPresent()) {
|
|
|
listData.setInsured("0");
|
|
listData.setInsured("0");
|
|
|
} else {
|
|
} else {
|
|
|
listData.setInsured(first4.get().getSumOrderNum().toString());
|
|
listData.setInsured(first4.get().getSumOrderNum().toString());
|
|
|
}
|
|
}
|
|
|
Optional<OrderStatusData> first5 =
|
|
Optional<OrderStatusData> first5 =
|
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("4")).findFirst();
|
|
item.getOrderStatusData().stream().filter(x -> x.getOrderStatusCode().equals("4")).findFirst();
|
|
|
- if (first5 == null) {
|
|
|
|
|
|
|
+ if (!first5.isPresent()) {
|
|
|
listData.setUnderwriteReturn("0");
|
|
listData.setUnderwriteReturn("0");
|
|
|
} else {
|
|
} else {
|
|
|
listData.setUnderwriteReturn(first5.get().getSumOrderNum().toString());
|
|
listData.setUnderwriteReturn(first5.get().getSumOrderNum().toString());
|