Commit 7d67097d by zhengxj

finish 修复订单渠道信息 on 20190313 by zhengxj

git-svn-id: svn://192.168.3.233/frms/code/car-service/trunk/car-service@18482 aeb6102e-e053-11e5-9fec-f9ebc45caf4b
1 parent 0a78454e
...@@ -85,7 +85,7 @@ public class OrderController extends BaseController { ...@@ -85,7 +85,7 @@ public class OrderController extends BaseController {
Map<String, Object> result = new HashMap<String, Object>(); Map<String, Object> result = new HashMap<String, Object>();
Page page = new Page(pageIndex, pageSize); Page page = new Page(pageIndex, pageSize);
// TODO 获取当前用户信息 根据用户角色筛选订单 // TODO 获取当前用户信息 根据用户角色筛选订单
int userId = UserUtils.getUserId(request); // int userId = UserUtils.getUserId(request);
// SysUser sysUser =orderService.getUser(UserUtils.getUserId(request)); // SysUser sysUser =orderService.getUser(UserUtils.getUserId(request));
SysOrderExample example = new SysOrderExample(); SysOrderExample example = new SysOrderExample();
......
...@@ -193,6 +193,7 @@ public class OrderServiceImpl implements IOrderService { ...@@ -193,6 +193,7 @@ public class OrderServiceImpl implements IOrderService {
// 订单渠道 如果当前用户是商户只能搜索当前商户的订单 // 订单渠道 如果当前用户是商户只能搜索当前商户的订单
if (oueryOrderReq.getOrderChannel() != null) { if (oueryOrderReq.getOrderChannel() != null) {
// criteria.andShopIdEqualTo(value)
criteria.andMerchantIdEqualTo(oueryOrderReq.getOrderChannel()); criteria.andMerchantIdEqualTo(oueryOrderReq.getOrderChannel());
} }
...@@ -372,10 +373,11 @@ public class OrderServiceImpl implements IOrderService { ...@@ -372,10 +373,11 @@ public class OrderServiceImpl implements IOrderService {
// 订单地址信息 // 订单地址信息
order.setArea(areaService.getAllChargeItems(order.getDistrict())); order.setArea(areaService.getAllChargeItems(order.getDistrict()));
// 渠道名称 // 渠道名称
if (order.getMerchantId() != null) { if (order.getShopId() != null) {
// SysMerchantExample sysMerchantExample = new SysMerchantExample(); SysMerchantExample sysMerchantExample = new SysMerchantExample();
// example.createCriteria().andIdEqualTo(order.getMerchantId()); sysMerchantExample.createCriteria().andUserIdEqualTo(order.getShopId());
order.setOrderChannel(sysUserDao.selectByPrimaryKey(order.getMerchantId()).getName()); // sysMerchantDao.selectByExample(sysMerchantExample);
order.setOrderChannel(sysMerchantDao.selectByExample(sysMerchantExample).get(0).getShopName());
} }
// 技工信息 // 技工信息
if (order.getMechanicId() != null) { if (order.getMechanicId() != null) {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!