Commit f70b60c6 by 陈浩建

小白卡订单完成时,办理号码存入融合清单

parent 445dbc5c
......@@ -6,10 +6,7 @@ import com.baomidou.mybatisplus.mapper.EntityWrapper;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.winsun.auth.core.common.model.ResponseData;
import com.winsun.auth.core.shiro.ShiroUser;
import com.winsun.bean.Order;
import com.winsun.bean.OrderHistory;
import com.winsun.bean.SalesList;
import com.winsun.bean.SysUser;
import com.winsun.bean.*;
import com.winsun.mapper.*;
import com.winsun.outSideSystem.IntelligenceSendOrder;
import com.winsun.service.ISalesListService;
......@@ -60,6 +57,8 @@ public class OrderTask {
OrderTask.orderMapper = orderMapper;
}
@Autowired
private RhPhoneMapper rhPhoneMapper;
/**
* 定时器更新已送货订单
*/
......@@ -232,6 +231,8 @@ public class OrderTask {
dataMapping.put("order_status", "已完成");
dataMapping.put("update_time", new Date());
dataMapping.put("success_time", new Date());
// 小白卡订单完成时,办理号码存入融合清单供办理融合业务使用
insertRhPhone(order.getBusinessNumber());
// 存销售清单
insertCompleteOrder(order);
appMapper.inserOrderHis(order.getId(), "订单已完成"+Map.get("orderState").toString(), new Date(), "定时器查询");
......@@ -287,4 +288,20 @@ public class OrderTask {
e.printStackTrace();
}
}
// 新用户完成存融合清单
public void insertRhPhone(String data){
Wrapper<RhPhone> wrapper = new EntityWrapper<>();
wrapper.eq(StringUtils.isNotBlank(data), "phone",data);
List<RhPhone> list = rhPhoneMapper.selectList(wrapper);
if(list.size()==0){
RhPhone rhPhone = new RhPhone();
rhPhone.setPhone(data);
try {
rhPhoneMapper.insert(rhPhone);
}catch (Exception e){
e.printStackTrace();
}
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment