Ejemplo n.º 1
0
  @Override
  public void execute(IParameterContext parameterContext) throws Exception {
    ArrayList<SaturnData> list = (ArrayList<SaturnData>) parameterContext.getParameterValue(0);
    SaturnData dingBao = null;
    SaturnData banPen = null;
    SaturnData shiGu = null;
    SaturnData yiBan = null;
    SaturnData shouBao = null;
    SaturnData baoXiu = null;
    if (list != null) {
      for (int i = 0; i < list.size(); i++) {
        SaturnData data = (SaturnData) list.get(i);
        if ("112001".equals(data.get("servtype"))) {
          dingBao = data;
        }
        if ("112002".equals(data.get("servtype"))) {
          banPen = data;
        }
        if ("112003".equals(data.get("servtype"))) {
          shiGu = data;
        }

        if ("112004".equals(data.get("servtype"))) {
          shouBao = data;
        }
        if ("112005".equals(data.get("servtype"))) {
          yiBan = data;
        }
        if ("112009".equals(data.get("servtype"))) {
          baoXiu = data;
        }
      }
      if (dingBao == null) {
        dingBao =
            SaturnDataManager.getInstance().createData("http://crm/coreModule/data::crm_servexp");
      }
      if (banPen == null) {
        banPen =
            SaturnDataManager.getInstance().createData("http://crm/coreModule/data::crm_servexp");
      }
      if (baoXiu == null) {
        baoXiu =
            SaturnDataManager.getInstance().createData("http://crm/coreModule/data::crm_servexp");
      }
      if (shouBao == null) {
        shouBao =
            SaturnDataManager.getInstance().createData("http://crm/coreModule/data::crm_servexp");
      }
      if (yiBan == null) {
        yiBan =
            SaturnDataManager.getInstance().createData("http://crm/coreModule/data::crm_servexp");
      }
      if (shiGu == null) {
        shiGu =
            SaturnDataManager.getInstance().createData("http://crm/coreModule/data::crm_servexp");
      }
    }

    parameterContext.setParameter(1, dingBao);
    parameterContext.setParameter(2, banPen);
    parameterContext.setParameter(3, shiGu);
    parameterContext.setParameter(4, shouBao);
    parameterContext.setParameter(5, yiBan);
    parameterContext.setParameter(6, baoXiu);
  }
Ejemplo n.º 2
0
  @Override
  public void execute(IParameterContext parameterContext) throws Exception {
    Connection conn = parameterContext.getConnection();
    carvin = (String) parameterContext.getParameterValue(2);
    carbrand = (String) parameterContext.getParameterValue(3);
    carseries = (String) parameterContext.getParameterValue(4);
    carmodel = (String) parameterContext.getParameterValue(5);
    cararea = (String) parameterContext.getParameterValue(6);
    cstmname = (String) parameterContext.getParameterValue(7);
    min_membjoindate = (String) parameterContext.getParameterValue(8);
    max_membjoindate = (String) parameterContext.getParameterValue(9);
    min_sumpoint = (String) parameterContext.getParameterValue(10);
    max_sumpoint = (String) parameterContext.getParameterValue(11);
    membcardid = (String) parameterContext.getParameterValue(12);
    membtype = (String) parameterContext.getParameterValue(13);
    startIndex = (String) parameterContext.getParameterValue(14);
    endIndex =
        ""
            + (Integer.parseInt(parameterContext.getParameterValue(15).toString())
                + 1
                - Integer.parseInt(startIndex));
    carlicenceno = (String) parameterContext.getParameterValue(16);
    carcardid = (String) parameterContext.getParameterValue(17);

    parameterContext.setParameter(0, getList(conn));
    parameterContext.setParameter(1, getCount(conn));
  }