コード例 #1
0
ファイル: PageBean.java プロジェクト: hilltop919/hilltop
 public PageBean clone(AbsContainerConfigBean parent) {
   PageBean pbNew = (PageBean) super.clone(parent);
   if (this.lstRelateReports != null) {
     pbNew.setLstRelateReports(new ArrayList<ReportBean>());
   }
   if (this.mRelateReports != null) {
     pbNew.setMRelateReports(new HashMap<ReportBean, ReportBean>());
   }
   return pbNew;
 }
コード例 #2
0
ファイル: PageType.java プロジェクト: qxo/wabacus
 public void displayOnPage(AbsComponentTag displayTag) {
   if (!rrequest.checkPermission(pagebean.getId(), null, null, Consts.PERMISSION_TYPE_DISPLAY)) {
     wresponse.println("&nbsp;");
     return;
   }
   wresponse.println(showStartWebResources());
   wresponse.println(
       "<span id=\"WX_CONTENT_"
           + pagebean.getGuid()
           + "\">"); // 顶层<page/>的内容必须用<span/>完整括住,这样更新页面时才能更新整个页面内容
   wresponse.println(showContainerStartPart());
   wresponse.println(showContainerTableTag());
   if (rrequest.checkPermission(
       pagebean.getId(), Consts.DATA_PART, null, Consts.PERMISSION_TYPE_DISPLAY)) {
     IComponentType childObjTmp;
     for (String childIdTmp : lstChildrenIds) {
       wresponse.println("<tr>");
       childObjTmp = this.mChildren.get(childIdTmp);
       showChildObj(childObjTmp, null);
       wresponse.println("</tr>");
     }
   }
   String backbutton = showBackButtonInPage();
   if (!backbutton.trim().equals("")) {
     wresponse.println("<tr><td align=\"center\">");
     wresponse.println(backbutton);
     wresponse.println("</td></tr>");
   }
   wresponse.println("</table>");
   wresponse.println(showContainerEndPart());
   wresponse.println(
       "<div id=\"wx_titletree_container\" style=\"display:none;\" class=\"titletree_container\">");
   wresponse.println("<div id=\"titletree_container_inner\" class=\"titletree_container_inner\">");
   wresponse.println(
       "<div id=\"tree\" class=\"bbit-tree\"><div class=\"bbit-tree-bwrap\"><div class=\"bbit-tree-body\" id=\"wx_titletree_content\">");
   wresponse.println("</div></div></div></div>");
   wresponse.println(
       "<div id=\"wx_titletree_buttoncontainer\" style=\"padding-top: 3px;padding-bottom:5px;text-align:center\"></div>");
   wresponse.println("</div>");
   wresponse.println("<div id=\"LOADING_IMG_ID\" class=\"cls-loading-img\"></div>");
   if (pagebean.getLstPrintBeans() != null) {
     for (AbsPrintProviderConfigBean ppcbeanTmp : pagebean.getLstPrintBeans()) {
       ppcbeanTmp.initPrint(rrequest);
     }
   }
   wresponse.println("</span>");
   wresponse.println(showEndWebResources());
 }
コード例 #3
0
ファイル: PageType.java プロジェクト: qxo/wabacus
 public List<ReportBean> initDisplayOnPage() {
   this.lstCsses = ComponentAssistant.getInstance().initDisplayCss(rrequest);
   this.lstJavascripts = new UniqueArrayList<JavascriptFileBean>();
   this.lstJavascripts.addAll(pagebean.getLstSystemJavascriptFiles());
   String js = rrequest.getStringAttribute("JS", "");
   if (!js.equals("")) {
     js = Tools.htmlEncode(js);
     List<String> lstJsTmp = Tools.parseStringToList(js, ",", false);
     for (String jsTmp : lstJsTmp) {
       if (jsTmp == null || jsTmp.trim().equals("")) continue;
       if (!jsTmp.trim().startsWith(Config.webroot)
           && !jsTmp.trim().toLowerCase().startsWith("http://")) {
         jsTmp = Tools.replaceAll(Config.webroot + "/" + jsTmp, "//", "/");
       }
       this.lstJavascripts.add(new JavascriptFileBean(jsTmp, 0));
     }
   } else if (pagebean.getLstMyJavascriptFiles() != null) {
     this.lstJavascripts.addAll(pagebean.getLstMyJavascriptFiles());
   }
   return super.initDisplayOnPage();
 }