Commit ae720584 by yuanlin

提交包活干检修安装拆除审核驳回 finished by yuanlin

git-svn-id: svn://192.168.3.233/frms/code/car-service/trunk/car-service@26617 aeb6102e-e053-11e5-9fec-f9ebc45caf4b
1 parent d799744f
......@@ -1413,13 +1413,15 @@ public class OrderServiceImpl implements IOrderService {
for(SysOrder order : orderList){
String installDeviceType = dictionaryDataMapper.getDictValueByKey(order.getInstallDeviceType());
order.setInstallDeviceTypeName(installDeviceType);
SysOrderRepairExample exam = new SysOrderRepairExample();
exam.createCriteria().andOrderIdEqualTo(order.getId());
List<SysOrderRepair> subOrders = orderRepairDao.selectByExample(exam);
SysOrderRepair sysOrderRepair = new SysOrderRepair();
sysOrderRepair.setSubOrderId(order.getId());
List<SysOrderRepair> subOrders = orderRepairDao.getOrderRepairList(sysOrderRepair);
if (subOrders != null) {
for(SysOrderRepair orderRepair : subOrders){
if((byte)BizConstants.ORDER_REPAIR_ADD == orderRepair.getAfterSaleType()){
order.setIfAddDevice((byte)BizConstants.ORDER_ADD_DEVICE_IS);
}else{
order.setIfAddDevice((byte)BizConstants.ORDER_ADD_DEVICE_NOT);
}
}
}else{
......@@ -1512,14 +1514,23 @@ public class OrderServiceImpl implements IOrderService {
subOrderNumber = subOrders.size();
order.setSubOrderCount(subOrderNumber);
order.setOrderRepair(subOrders);
for(SysOrderRepair orderRepair : subOrders){
}
SysOrderRepair sysOrderRepair = new SysOrderRepair();
sysOrderRepair.setSubOrderId(order.getId());
List<SysOrderRepair> temps = orderRepairDao.getOrderRepairList(sysOrderRepair);
if(CollectionUtils.isEmpty(temps)){
order.setIfAddDevice((byte)BizConstants.ORDER_ADD_DEVICE_NOT);
}else{
for(SysOrderRepair orderRepair : temps){
if((byte)BizConstants.ORDER_REPAIR_ADD == orderRepair.getAfterSaleType()){
order.setIfAddDevice((byte)BizConstants.ORDER_ADD_DEVICE_IS);
}else{
order.setIfAddDevice((byte)BizConstants.ORDER_ADD_DEVICE_NOT);
}
}
}else{
order.setIfAddDevice((byte)BizConstants.ORDER_ADD_DEVICE_NOT);
}
// 订单地址信息
if (null != order.getDistrict() && order.getDistrict() > 0) {
order.setArea(areaService.getAllChargeItems(order.getDistrict()));
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!