Exemplo n.º 1
0
 public String addfield() {
   if ((this.infoItem != null) && (!"".equals(this.infoItem))) {
     String[] inf = this.infoItem.replace('.', ',').split(",");
     InfoItemBO ib = SysCacheTool.findInfoItem("", inf[1]);
     ib.setSetId(CodeUtil.interpertCode(CodeUtil.TYPE_INFOSET, inf[0]));
     ib.setItemSequence(String.valueOf(this.baseFields.size() + 1));
     this.baseFields.add(ib);
   }
   return null;
 }
Exemplo n.º 2
0
  public String getInitOrgEdit() {
    String act = super.getRequestParameter("act");
    if ("init".equals(act)) {
      try {
        this.orgchangebo =
            (OrgPersonTypeChangeBO)
                this.changeService.getObjByID(
                    OrgPersonTypeChangeBO.class, super.getUserInfo().getOrgId());
        if (this.orgchangebo == null) {
          this.orgchangebo = new OrgPersonTypeChangeBO();
          this.orgchangebo.setOrgID(super.getUserInfo().getOrgId());
          this.changeService.saveObj(this.orgchangebo);
        } else {
          if (this.orgchangebo.getWageItem() != null
              && !"".equals(this.orgchangebo.getWageItem())) {
            this.baseFields = new ArrayList();
            String[] fs = this.orgchangebo.getWageItem().split(",");
            for (int i = 0; i < fs.length; i++) {
              InfoItemBO ib = SysCacheTool.findInfoItem("", fs[i]);
              ib.setItemSequence(String.valueOf(i + 1));
              ib.setSetId(CodeUtil.interpertCode(CodeUtil.TYPE_INFOSET, ib.getSetId()));
              if (!this.baseFields.contains(ib)) {
                this.baseFields.add(ib);
              }
            }
          }
        }
        this.orgchangebo.setOrgName(
            CodeUtil.interpertCode(CodeUtil.TYPE_ORG, this.orgchangebo.getOrgID()));
      } catch (SysException e) {
        e.printStackTrace();
      }
    }

    return initOrgEdit;
  }