| | |
| | | import com.alibaba.fastjson.JSONObject; |
| | | import com.baomidou.mybatisplus.mapper.EntityWrapper; |
| | | import com.stylefeng.guns.core.common.constant.state.Order; |
| | | import com.stylefeng.guns.core.util.ToolUtil; |
| | | import com.stylefeng.guns.modular.specialTrain.model.OrderPrivateCar; |
| | | import com.stylefeng.guns.modular.specialTrain.server.IOrderPrivateCarService; |
| | | import com.stylefeng.guns.modular.system.dao.CarMapper; |
| | |
| | | jsonObject.put("RegisterDate", userInfo.getInsertTime());//注册日期YYYYMMDD |
| | | jsonObject.put("PassengerPhone", userInfo.getPhone());//乘客手机号 |
| | | jsonObject.put("PassengerName", userInfo.getNickName());//乘客称谓 |
| | | jsonObject.put("PassengerGender", userInfo.getSex() == 1 ? "男" : "女");//乘客性别 |
| | | jsonObject.put("PassengerGender", null != userInfo.getSex() && userInfo.getSex() == 1 ? "男" : "女");//乘客性别 |
| | | jsonObject.put("State", 0);//状态(0:有效,1:失效) |
| | | jsonObject.put("Flag", 1);//操作标识(1:新增,2:更新,3:删除) |
| | | jsonObject.put("UpdateTime", new Date()); |
| | |
| | | e.printStackTrace(); |
| | | } |
| | | Map<String, String> geocode = null; |
| | | if(ToolUtil.isNotEmpty(orderPrivateCar.getBoardingLon())){ |
| | | try { |
| | | geocode = gdMapGeocodingUtil.geocode(orderPrivateCar.getBoardingLon().toString(), |
| | | orderPrivateCar.getBoardingLat().toString()); |
| | | } catch (Exception e) { |
| | | e.printStackTrace(); |
| | | } |
| | | } |
| | | JSONObject jsonObject = new JSONObject(); |
| | | jsonObject.put("Address", Integer.valueOf(geocode.get("districtCode")));//上车地点行政区划代码 |
| | | jsonObject.put("Address", null != geocode ? Integer.valueOf(geocode.get("districtCode")) : "");//上车地点行政区划代码 |
| | | jsonObject.put("OrderId", orderPrivateCar.getOrderNum());//订单编号 |
| | | jsonObject.put("OrderTime", orderPrivateCar.getOrderNum());//订单时间YYYYMMDDhhmmss |
| | | jsonObject.put("CancelTime", query.getInsertTime());//订单撤销时间YYYYMMDDhhmmss |