Package com.hlcl.rql.as

Examples of com.hlcl.rql.as.Project


    String logonGuid = "0B1FBC04A6D94A45A6C5E2AC8915B698";
    String sessionKey = "C26CF959E1434E31B7F9DA89829369B4";
    String projectGuid = "73671509FA5C43ED8FC4171AD0298AD2";

    CmsClient client = new CmsClient(logonGuid);
    Project project = client.getProject(sessionKey, projectGuid);

    // delete a page
    Page currentPg = project.getPageById("4711");
    currentPg.delete();
    // now currentPg cannot be used anymore

    // delete ignoring references
    currentPg = project.getPageById("4712");
    currentPg.delete(true);
   
    // remove page from recycle bin
    currentPg.deleteFromRecycleBin();
    currentPg.deleteFromRecycleBinInCurrentLanguageVariant();
   
    // remove page from recycle bin for given language variants
    java.util.List<LanguageVariant> languageVariants = new ArrayList<LanguageVariant>();
    languageVariants.add(project.getLanguageVariantByRfcLanguageId("en"));
    languageVariants.add(project.getLanguageVariantByRfcLanguageId("zh"));
    currentPg.deleteFromRecycleBin(languageVariants);
   
    // restore page from recycle bin
    RecycleBin recycleBin = project.getRecycleBin();
    recycleBin.restorePageById("4711");
  }
View Full Code Here


    String logonGuid = "0B1FBC04A6D94A45A6C5E2AC8915B698";
    String sessionKey = "C26CF959E1434E31B7F9DA89829369B4";
    String projectGuid = "73671509FA5C43ED8FC4171AD0298AD2";

    CmsClient client = new CmsClient(logonGuid);
    Project project = client.getProject(sessionKey, projectGuid);
    ScriptParameters parms = project.getParameters("267761");
    String imageFragmentTmpltName = parms.get("imageFragmentTmpltName");
    String numberListTmpltElemName = parms.get("numberListTmpltElemName");
    String numberOfColumnsTmpltElemName = parms.get("numberOfColumnsTmpltElemName");
  }
View Full Code Here

    String logonGuid = "0B1FBC04A6D94A45A6C5E2AC8915B698";
    String sessionKey = "C26CF959E1434E31B7F9DA89829369B4";
    String projectGuid = "73671509FA5C43ED8FC4171AD0298AD2";

    CmsClient client = new CmsClient(logonGuid);
    Project project = client.getProject(sessionKey, projectGuid);

    UserGroup userGroup1 = project.getUserGroupByGuid("userGroupGuid");
    UserGroup userGroup2 = project.getUserGroupByName("userGroupName");

    // add users to user group
    User user = client.getUserByName("lejafr");
    userGroup1.addUser(user);
    userGroup1.addUsers(userGroup2);
View Full Code Here

    String logonGuid = "0B1FBC04A6D94A45A6C5E2AC8915B698";
    String sessionKey = "C26CF959E1434E31B7F9DA89829369B4";
    String projectGuid = "73671509FA5C43ED8FC4171AD0298AD2";

    CmsClient client = new CmsClient(logonGuid);
    Project project = client.getProject(sessionKey, projectGuid);
   
    // 1. step - prepare the page
    Page currentPg = project.getPageById("4711");
    currentPg.startSetElementValues();
   
    // 2. step
    // remember new page element values only
    currentPg.addSetOptionListValue("templateElementName", "value");
    currentPg.addSetStandardFieldDateValue("templateElementName", new ReddotDate());
    currentPg.addSetStandardFieldNumericValue("templateElementName", 20);
    currentPg.addSetStandardFieldTextValue("templateElementName", "text value");
    currentPg.addSetStandardFieldUserDefinedValue("templateElementName", "value");
   
    // 2. step
    // remember copied values
    //TODO needs post
    Page sourcePage = project.getPageById("4712");
    currentPg.addCopyOptionListValueFrom("templateElementName", sourcePage);
    currentPg.addCopyStandardFieldDateValueFrom("templateElementName", sourcePage);
    currentPg.addCopyStandardFieldNumericValueFrom("templateElementName", sourcePage);
    currentPg.addCopyStandardFieldTextValueFrom("templateElementName", sourcePage);
    currentPg.addCopyStandardFieldUserDefinedValueFrom("templateElementName", sourcePage);
View Full Code Here

      String logonGuid="D0EF5D1C8FCB41CDAE1E6CF03C971A5D";
      String sessionKey="8A1A58AD2E694CE4A6E6615345F34244";
      String projectGuid="06BE79A1D9F549388F06F6B649E27152";

      CmsClient client = new CmsClient(logonGuid);
      Project project = client.getProject(sessionKey, projectGuid);

      Page currentPg = project.getPageById("908278");
      PageArrayList currentPages = currentPg.getListChildPages("content_pages_list");
      System.out.println("current= " + currentPages.collectHeadlines());
     
      // targets
      String[] targets = { "Sales Steering", "Allocation Management" };
View Full Code Here

    String logonGuid = "0B1FBC04A6D94A45A6C5E2AC8915B698";
    String sessionKey = "C26CF959E1434E31B7F9DA89829369B4";
    String projectGuid = "73671509FA5C43ED8FC4171AD0298AD2";

    CmsClient client = new CmsClient(logonGuid);
    Project project = client.getProject(sessionKey, projectGuid);

    ProjectVariant pv1 = project.getProjectVariantByGuid("project variant guid");
    ProjectVariant pv2 = project.getProjectVariantByName("project variant name");

    LanguageVariant lv1 = project.getLanguageVariantByGuid("language variant guid");
    LanguageVariant lv2 = project.getLanguageVariantByName("language variant name");
    LanguageVariant lv3 = project.getLanguageVariantByLanguage("3 letter language code");
    LanguageVariant lv4 = project.getLanguageVariantByRfcLanguageId("2 letter language code");
  }
View Full Code Here

    String logonGuid = "0B1FBC04A6D94A45A6C5E2AC8915B698";
    String sessionKey = "C26CF959E1434E31B7F9DA89829369B4";
    String projectGuid = "73671509FA5C43ED8FC4171AD0298AD2";

    CmsClient client = new CmsClient(logonGuid);
    Project project = client.getProject(sessionKey, projectGuid);

    PageArrayList allPagesSavedAsDraft = project.getAllPagesSavedAsDraft();
    PageArrayList allPagesWaitingForCorrection = project.getAllPagesWaitingForCorrection();
    PageArrayList allPagesWaitingForRelease = project.getAllPagesWaitingForRelease();
   
    User connectedUser = client.getConnectedUser();
    connectedUser.getPagesSavedAsDraft(project);
    connectedUser.getPagesWaitingForCorrection(project);
    connectedUser.getPagesWaitingForRelease(project);
View Full Code Here

    String logonGuid = "0B1FBC04A6D94A45A6C5E2AC8915B698";
    String sessionKey = "C26CF959E1434E31B7F9DA89829369B4";
    String projectGuid = "73671509FA5C43ED8FC4171AD0298AD2";

    CmsClient client = new CmsClient(logonGuid);
    Project project = client.getProject(sessionKey, projectGuid);

    Page currentPg = project.getPageById("1234");

    System.out.println(currentPg.getStandardFieldTextValue("column_1_header"));
    currentPg.setStandardFieldTextValue("column_1_header", "new header value");

    currentPg.getStandardFieldDateValue("column_updated");
View Full Code Here

    String logonGuid = "0904ABF0E43443D2881FE7481339650E";
    String sessionKey = "490EC675042F4C5A8A6DF1ED63ADD7A6";
    String projectGuid = "268F46EF5EB74A75824856D3DA1C6597";

    CmsClient client = new CmsClient(logonGuid);
    Project project = client.getProject(sessionKey, projectGuid);

    Template newTemplate = project.getTemplateByName("content_templates", "text_block");

    for (TemplateFolder folder : project.getAllTemplateFolders()) {
      for (Template template : folder.getTemplates()) {
        // skip not page templates
        if (!template.getName().endsWith("_page")) {
          continue;
        }
View Full Code Here

    String logonGuid = "0B1FBC04A6D94A45A6C5E2AC8915B698";
    String sessionKey = "C26CF959E1434E31B7F9DA89829369B4";
    String projectGuid = "73671509FA5C43ED8FC4171AD0298AD2";

    CmsClient client = new CmsClient(logonGuid);
    Project project = client.getProject(sessionKey, projectGuid);

    Page currentPg = project.getPageById("34009");
    currentPg.isInStateSavedAsDraft();
    currentPg.isInStateSavedAsDraftNew();
    currentPg.isInStateSavedAsDraftChanged();

    currentPg.isInStateWaitingForCorrection();
View Full Code Here

TOP

Related Classes of com.hlcl.rql.as.Project

Copyright © 2018 www.massapicom. 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.