Examples of BOInstance


Examples of com.exedosoft.plat.bo.BOInstance

    // ///处理第二服务(统计用)
    DOService secondService = gridModel.getSecondService();
    if (secondService != null) {
      List secondResult = secondService.invokeSelect();
      if (secondResult.size() > 0) {
        BOInstance statistics = (BOInstance) secondResult.get(0);
        data.put("statistics", statistics.getMap());
        StringBuilder sb = new StringBuilder();
        List<DOFormModel> listFm = gridModel
            .getStatisticOutGridFormLinks();
        if (listFm != null && listFm.size() > 0) {
          for (Iterator<DOFormModel> it = listFm.iterator(); it
View Full Code Here

Examples of com.exedosoft.plat.bo.BOInstance

  @Override
  public String excute() throws ExedoException {
   
    DOBO bo = DOBO.getDOBOByName("do_bo");
    BOInstance instance = bo.getCorrInstance();
    if(instance==null){
      this.setEchoValue(I18n.instance().get("没有数据!"));
      return NO_FORWARD;
    }
   
View Full Code Here

Examples of com.exedosoft.plat.bo.BOInstance

    }else{
      data.put("formlinks", gridModel.getNormalGridFormLinks());
    }
   
    if (list.size() > 0) {
      BOInstance ins = (BOInstance) list.get(0);
      data.put("data", ins);
    }
    data.put("contextPath", DOGlobals.PRE_FULL_FOLDER);
    return data;
  }
View Full Code Here

Examples of com.exedosoft.plat.bo.BOInstance

      DOBO boForm = DOBO.getDOBOByName("do_ui_formmodel");
      DOBO boFormLink = DOBO.getDOBOByName("DO_UI_FormLinks");
      DOBO boFormTarget = DOBO.getDOBOByName("DO_UI_FormTargets");

      // /还要复制子面板连接(子面板内部不复制)
      BOInstance biPane = boPane.getCorrInstance();
      DOPaneModel pm = DOPaneModel.getPaneModelByID(biPane.getUid());

      DOGridModel gm = pm.getGridModel();
      // //如果连接的是表格:::::暂时只实现这个
      if (gm != null) {

        // /////保存GridModel
        BOInstance biGrid = boGrid.getInstance(gm.getObjUid());
        biGrid.putValue("objuid", null);
        biGrid.putValue("name", biGrid.getValue("name") + "_copy");
        biGrid.putValue("l10n", biGrid.getValue("l10n") + "_copy");
        BOInstance newBiGrid = boGrid.getDInsertService().invokeUpdate(
            biGrid);

        // //保存GridModel

        // /保存面板
        biPane.putValue("objuid", null);
        biPane.putValue("name", biPane.getValue("name") + "_copy");
        biPane.putValue("l10n", biPane.getValue("l10n") + "_copy");
        biPane.putValue("linkuid", newBiGrid.getUid());       
        boPane.getDInsertService().invokeUpdate(biPane);
        // /保存面板

        List<DOFormModel> fms = gm.getAllGridFormLinks();
        Map<DOFormModel,BOInstance> map = new HashMap<DOFormModel,BOInstance>();
        for (Iterator<DOFormModel> it = fms.iterator(); it.hasNext();) {
          DOFormModel aFm = it.next();
          // ///保存FormModel
          BOInstance biForm = boForm.getInstance(aFm.getObjUid());
          biForm.putValue("objuid", null);
          biForm.putValue("gridModelUid", newBiGrid.getUid());
         
          DOService fmInsert = boForm.getDInsertService();
         
          if("en".equals(DOGlobals.getValue("lang.local"))){
            fmInsert = DOService.getService("DO_UI_FormModel_Insert_EN");
          }
         
          BOInstance newBiForm = fmInsert.invokeUpdate(biForm);
         
          map.put(aFm, newBiForm);
          // //保存FormModel
          for(Iterator<DOFormTarget> itTargetGrid = aFm.getTargetGridModels().iterator();itTargetGrid.hasNext(); ){
            DOFormTarget aFt = itTargetGrid.next();
            BOInstance biFt = boFormTarget.getInstance(aFt.getObjUid());
            biFt.putValue("objuid", null);
            biFt.putValue("formUid", newBiForm.getUid());
            boFormTarget.getDInsertService().invokeUpdate(biFt);           
          }
        }

        /////linkForms 需要单独处理
        for (Iterator<DOFormModel> it = fms.iterator(); it.hasNext();) {
          DOFormModel aFm = it.next();
          BOInstance newBiForm = map.get(aFm);
          // //FormModel linkForms
          for(Iterator<DOFormModel> itLinkForms = aFm.getLinkForms().iterator(); itLinkForms.hasNext();){
            DOFormModel linkForm = itLinkForms.next();
            BOInstance newLinkBiForm = new BOInstance();
            if(map.get(linkForm)!=null){
              newLinkBiForm = map.get(linkForm);
            }else{
              newLinkBiForm = boForm.getInstance(linkForm.getObjUid());
            }
            // 
            Map<String,String> paras = new HashMap<String,String>();
            paras.put("formuid", newBiForm.getUid());
            paras.put("linkformuid", newLinkBiForm.getUid());
            boFormLink.getDInsertService().invokeUpdate(paras);
          }

        }
View Full Code Here

Examples of com.exedosoft.plat.bo.BOInstance

   */

  public String excute() {
   
    DOBO bo = DOBO.getDOBOByName("do_bo");
    BOInstance instance = bo.getCorrInstance();
    if(instance==null){
      this.setEchoValue(I18n.instance().get("没有数据!"));

      return NO_FORWARD;
    }
    GeneUIMain gum = new GeneUIMain(instance.getValue("sqlStr"));
    gum.geneConfig();
   
    this.setEchoValue(I18n.instance().get("初始化成功!"));
    return DEFAULT_FORWARD;
  }
View Full Code Here

Examples of com.exedosoft.plat.bo.BOInstance

      t.begin();
      DOBO boForm = DOBO.getDOBOByName("do_ui_formmodel");
      DOBO boFormTarget = DOBO.getDOBOByName("DO_UI_FormTargets");
      DOBO boFormLink = DOBO.getDOBOByName("DO_UI_FormLinks");
      for(int i = 0; i < checks.length ; i++){
        BOInstance biForm = boForm.getInstance(checks[i]);
        DOFormModel aFm = DOFormModel.getFormModelByID(biForm.getUid());
       
        biForm.putValue("objuid", null);
        biForm.putValue("gridModelUid", gridModelUid);
        BOInstance newBiForm = copyService.invokeUpdate(biForm);
        // //保存FormModel
        for(Iterator<DOFormTarget> itTargetGrid = aFm.getTargetGridModels().iterator();itTargetGrid.hasNext(); ){
          DOFormTarget aFt = itTargetGrid.next();
          BOInstance biFt = boFormTarget.getInstance(aFt.getObjUid());
          biFt.putValue("objuid", null);
          biFt.putValue("formUid", newBiForm.getUid());
          boFormTarget.getDInsertService().invokeUpdate(biFt);           
        }

          // //FormModel linkForms
        for(Iterator<DOFormModel> itLinkForms = aFm.getLinkForms().iterator(); itLinkForms.hasNext();){
View Full Code Here

Examples of com.exedosoft.plat.bo.BOInstance

      return NO_FORWARD;
    }

    StringBuilder sb = new StringBuilder("<export>");
    DOBO bo = DOBO.getDOBOByName("multi_appshare");
    BOInstance appShare = bo.getCorrInstance();

    DOService insertInstallRecord = DOService
        .getService("multi_appshareinstall_install");

    Transaction t = insertInstallRecord.currentTransaction();
    t.begin();

    try {
      TenancyValues tv = (TenancyValues) DOGlobals.getInstance()
          .getSessoinContext().getTenancyValues();
     
      if(tv.getTenant().getUid().equals(appShare.getValue("auth_tenant_id"))){
        this.setEchoValue(I18n.instance().get("应用已经存在!"));

        return this.NO_FORWARD;
      }

      Map paras = new HashMap();
      paras.put("use_tenant_id", tv.getTenant().getUid());
      paras.put("use_tenant_name", tv.getTenant().getValue("l10n"));
      insertInstallRecord.invokeUpdate(paras);

      URL url = DODataSource.class.getResource("/globals.xml");
      String s = url.getPath();
      String s2 = s;
      s = s.substring(0, s2.toLowerCase().indexOf("web-inf"));

      StringBuffer fileName = new StringBuffer(s).append("appshare/")
          .append(appShare.getValue("xml_path"));

      DOImport imp = new DOImport();
      imp.importXml("", fileName.toString());
    } catch (Exception e) {
View Full Code Here

Examples of com.exedosoft.plat.bo.BOInstance

   
    try {
      this.service.beginBatch();
      DOBO boParaService = DOBO.getDOBOByName("DO_Parameter_Service");
      for(int i = 0; i < checks.length ; i++){
        BOInstance bi = boParaService.getInstance(checks[i]);
        bi.putValue("objuid", null);
        bi.putValue("serviceUid", serviceUid);
        this.service.addBatch(bi);     
      }
      this.service.endBatch();
    } catch (Exception e) {
      // TODO Auto-generated catch block
View Full Code Here

Examples of com.exedosoft.plat.bo.BOInstance

   */
  private static final long serialVersionUID = 1L;

  public String excute() {

    BOInstance form = DOGlobals.getInstance().getSessoinContext()
        .getFormInstance();

    String tableName = form.getValue("tableName");
    String[] colNames = form.getValueArray("col_name");
    String[] dbtypes = form.getValueArray("dbtype");
    String[] dbsizes = form.getValueArray("dbsize");

    StringBuffer sb = new StringBuffer("create table ");
    sb.append(tableName).append(" (");
    for (int i = 0; i < colNames.length; i++) {

View Full Code Here

Examples of com.exedosoft.plat.bo.BOInstance

   
    String[] selects =  DOGlobals.getInstance().getServletContext().getRequest().getParameterValues("checkinstance");
    List lSelects = Arrays.asList(selects);
    List selectedList = new ArrayList();
    for (Iterator it = list.iterator(); it.hasNext();) {
      BOInstance ins = (BOInstance) it.next();
      if(lSelects.contains(ins.getUid())){
        selectedList.add(ins);
      }
    }
    data.put("model", gm);
    data.put("data", selectedList);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.