@Override
  public Map<String, Object> insertSendMessage(Map<String, Object> map) {
    Map<String, Object> rmap = new HashMap<String, Object>();

    map.put("createTime", DateUtil.getNowDateStr());
    map.put("sendCode", DateUtil.getNowDateStr2() + RandomUtil.getRandom());
    //		Map<String,String> m=getExamineId((String)map.get("spr"));
    //		if(m==null ||m.size()==0){
    //			rmap.put("status", "N");
    //			rmap.put("msg", "未查询到审核人信息!");
    //			return rmap;
    //		}
    //		map.put("examine_id", m.get("examine_id"));
    //		map.put("phone_no",m.get("examine_phone"));
    int i = 0;
    // 判断推送信息是否重复
    String dxCode = "";
    try {
      dxCode = sendMessageDao.queryMessageCode((String) map.get("send_ms"));
    } catch (Exception e1) {
      log.error("查询dxCode出错:" + e1.getMessage());
      rmap.put("status", "N");
      rmap.put("msg", "保存推送信息出错!");
      return rmap;
    }
    if (null == dxCode || "".equals(dxCode)) {
      dxCode = UUID.randomUUID().toString().replaceAll("-", "");
    }
    map.put("dxCode", dxCode);
    try {
      map.put("status", "2");
      sendMessageDao.updateAfterSendMessageStatus(map);
      i = sendMessageDao.insertSendMessage(map);
    } catch (Exception e) {
      log.info("插入推送信息出错!" + e.getMessage());
    }
    if (1 != i) {
      rmap.put("status", "N");
      rmap.put("msg", "保存推送信息出错!");
      return rmap;
    }

    //		if(sendExamineRandomNo(map)){
    //			try {//创建成功  修改目前状态等于2的 保证 一个类型下 只有一个推送信息可用
    //				map.put("status", "2");
    //				sendMessageDao.updateAfterSendMessageStatus(map);
    //			} catch (Exception e) {
    //			}
    //			rmap.put("status","Y");
    //			rmap.put("sendCode",map.get("sendCode"));
    //			rmap.put("exName", m.get("examine_name"));
    //			rmap.put("exPhoneNo", m.get("examine_phone"));
    //		}else{
    //			rmap.put("status", "N");
    //			rmap.put("msg", "生成随机码出错,请重新提交");
    //		}
    rmap.put("status", "Y");
    rmap.put("msg", "保存推送信息成功!");
    return rmap;
  }
  @Override
  public String shortMessageCodeSend(Map<String, Object> map) {
    map.put("create_time", DateUtil.getNowDateStr());
    map.put("sendCode", DateUtil.getNowDateStr2() + RandomUtil.getRandom());
    String resultms = (String) map.get("sendCode");

    String isql = "短信表";
    try {
      String r = insertShortMessageCode(map);
      if (r.equals("N")) {
        resultms = "F";
      } else {
        map.put("status", "2"); // 插入成功,修改目前状态已经为2的数据
        sendMessageDao.updateAfterSendMessageStatus(map);
      }
      Connection con = DataBaseJdbc.getDB2Connection();
      if (con != null) {
        Statement stmt = con.createStatement();
        int i = stmt.executeUpdate(isql);
        if (i < 1) {
          resultms = "F";
        }
      } else {
        resultms = "F";
      }
    } catch (Exception e) {
      log.error("cc=" + e.getMessage());
      resultms = "E";
    }
    return resultms;
  }
 @Override
 public boolean addWebServiceSendMessage(Map<String, Object> map) throws Exception {
   sendMessageDao.updatAllSendMessageStatus(map.get("activeCode").toString());
   map.put("sendCode", DateUtil.getNowDateStr2() + RandomUtil.getRandom());
   map.put("createTime", DateUtil.getNowDateStr());
   int i = sendMessageDao.addWebServiceSendMessage(map);
   if (i > 0) {
     return true;
   } else {
     return false;
   }
 }