Package com.centraview.common

Examples of com.centraview.common.ListPreference


      long start = 0L;
      if (logger.isDebugEnabled()) {
        start = System.currentTimeMillis();
      }
      int individualId = userObject.getIndividualID();
      ListPreference listPreference = userObject.getListPreference("EventAtendees");
      ListView view = listPreference.getListView(String.valueOf(listPreference.getDefaultView()));
      ValueListParameters listParameters = null;
      ValueListParameters requestListParameters = (ValueListParameters)request.getAttribute("listParameters");
      if (requestListParameters == null) // build up new Parameters
      {
        listParameters = new ValueListParameters(ValueListConstants.EVENTATTENDEE_LIST_TYPE, listPreference.getRecordsPerPage(), 1);
      } else { // paging or sorting or something, use the parameters from the
               // request.
        listParameters = requestListParameters;
      }
      if (listParameters.getSortColumn() == 0) {
        FieldDescriptor sortField = (FieldDescriptor)ValueListConstants.eventAttendeeViewMap.get(listPreference.getSortElement());
        listParameters.setSortColumn(sortField.getQueryIndex());
        if (listPreference.getsortOrder()) {
          listParameters.setSortDirection("ASC");
        } else {
          listParameters.setSortDirection("DESC");
        }
      }
View Full Code Here


      }
      else {
        strFolderId = userobjectd.getUserPref().getDefaultFolderID();
      }

      ListPreference listpreference= userobjectd.getListPreference("File");
      FileList displaylistSession=null;


      FileList DL = new FileList() ;
      CvFileFacade fileFacade = new CvFileFacade();
View Full Code Here

    // Check wheather the actionType is it Lookup or not
    String actionType = (String)request.getParameter("actionType");

    UserObject userObject = (UserObject)session.getAttribute("userobject");
    int individualId = userObject.getIndividualID();
    ListPreference listPreference = userObject.getListPreference("Expense");
    ListView view = listPreference.getListView(String.valueOf(listPreference.getDefaultView()));
    ValueListParameters listParameters = null;
    ValueListParameters requestListParameters = (ValueListParameters)request.getAttribute("listParameters");
    if (requestListParameters == null) // build up new Parameters
    {
      listParameters = new ValueListParameters(ValueListConstants.EXPENSES_LIST_TYPE, listPreference.getRecordsPerPage(), 1);
    } else { // paging or sorting or something, use the parameters from the
             // request.
      listParameters = requestListParameters;
    }
    if (listParameters.getSortColumn() == 0) {
      FieldDescriptor sortField = (FieldDescriptor)ValueListConstants.expensesViewMap.get(listPreference.getSortElement());
      listParameters.setSortColumn(sortField.getQueryIndex());
      if (listPreference.getsortOrder()) {
        listParameters.setSortDirection("ASC");
      } else {
        listParameters.setSortDirection("DESC");
      }
    }
View Full Code Here

    UserObject userObject = (UserObject)session.getAttribute("userobject");
    int individualID = userObject.getIndividualID(); // logged in user
    int entityID = userObject.getEntityId(); // logged in user's entityID
    ActionErrors allErrors = new ActionErrors();
    try {
      ListPreference listPrefs = userObject.getListPreference("USER");
      String filter = "SELECT a.UserID FROM user a, individual b, entity c where a.IndividualID = b.IndividualID and b.Entity = c.EntityID and c.EntityID = " + entityID;
      ValueListParameters listParameters = ActionUtil.valueListParametersSetUp(listPrefs, request, ValueListConstants.CUSTOMER_USER_LIST_TYPE, ValueListConstants.customerUserViewMap, false);
      listParameters.setFilter(filter);
      ValueList valueList = (ValueList)CVUtility.setupEJB("ValueList", "com.centraview.valuelist.ValueListHome", dataSource);
      ValueListVO listObject = valueList.getValueList(individualID, listParameters);
View Full Code Here

    GlobalMasterLists globalMasterLists = GlobalMasterLists.getGlobalMasterLists(dataSource);
    HashMap moduleList = new HashMap();
    if (globalMasterLists.get("moduleList") != null)
      moduleList = (HashMap)globalMasterLists.get("moduleList");
   
    ListPreference listPreference = userObject.getListPreference("Event");
    ListView view = listPreference.getListView(String.valueOf(listPreference.getDefaultView()));
   
    ValueListParameters listParameters = null;
    ValueListParameters requestListParameters = (ValueListParameters)request.getAttribute("listParameters");
    if (requestListParameters == null) { // build up new Parameters
      listParameters = new ValueListParameters(ValueListConstants.EVENT_LIST_TYPE, listPreference.getRecordsPerPage(), 1);
    } else { // paging or sorting or something, use the parameters from the request.
      listParameters = requestListParameters;
    }
    if (listParameters.getSortColumn() == 0) {
      FieldDescriptor sortField = (FieldDescriptor)ValueListConstants.eventViewMap.get(listPreference.getSortElement());
      listParameters.setSortColumn(sortField.getQueryIndex());
      if (listPreference.getsortOrder())
        listParameters.setSortDirection("ASC");
      else
        listParameters.setSortDirection("DESC");
    }
   
View Full Code Here

      session.removeAttribute("listErrorMessage");
    }
   
    UserObject userObject = (UserObject) session.getAttribute("userobject");
    int individualId = userObject.getIndividualID();
    ListPreference listPreference = userObject.getListPreference("Rule");
    ListView view = listPreference.getListView( String.valueOf(listPreference.getDefaultView()));
    ValueListParameters listParameters = null;
    ValueListParameters requestListParameters =  (ValueListParameters) request.getAttribute("listParameters");
    if (requestListParameters == null) // build up new Parameters
    {
      listParameters = new ValueListParameters( ValueListConstants.RULE_LIST_TYPE,listPreference.getRecordsPerPage(),1);
    } else { // paging or sorting or something, use the parameters from the request.
      listParameters = requestListParameters;
    }
    if (listParameters.getSortColumn() == 0)
    {
      FieldDescriptor sortField = (FieldDescriptor) ValueListConstants.ruleViewMap.get(listPreference.getSortElement());
      listParameters.setSortColumn(sortField.getQueryIndex());
      if (listPreference.getsortOrder()) {
        listParameters.setSortDirection("ASC");
      } else {
        listParameters.setSortDirection("DESC");
      }
    }
View Full Code Here

    UserObject userObject = (UserObject)session.getAttribute("userobject");
    int individualID = userObject.getIndividualID(); // logged in user
    int entityID = userObject.getEntityId(); // logged in user's entityID
    ActionErrors allErrors = new ActionErrors();
    try {
      ListPreference listPrefs = userObject.getListPreference("FAQ");
      String filter = "SELECT faq.faqid FROM faq WHERE publishToCustomerView='YES' and status='PUBLISH'";
      ValueListParameters listParameters = ActionUtil.valueListParametersSetUp(listPrefs, request, ValueListConstants.CUSTOMER_FAQ_LIST_TYPE, ValueListConstants.customerFaqViewMap, false);
      listParameters.setFilter(filter);
      ValueList valueList = (ValueList)CVUtility.setupEJB("ValueList", "com.centraview.valuelist.ValueListHome", dataSource);
      ValueListVO listObject = valueList.getValueList(individualID, listParameters);
View Full Code Here

      if (session.getAttribute("highlightmodule") != null)
        session.setAttribute("highlightmodule", "hr");

      com.centraview.common.UserObject  userobjectd = (com.centraview.common.UserObject)session.getAttribute( "userobject" );

      ListPreference listpreference= userobjectd.getListPreference("TimeSheet");

      DisplayList displaylistSession = ( DisplayList )session.getAttribute( "displaylist") ;

      // After performing the logic in the DeleteHanlder, we are generat a new request for the list
      // So we will not be carrying the old error. So that we will try to collect the error from the Session variable
      // Then destory it after getting the Session value
      if (session.getAttribute("listErrorMessage") != null)
      {
        ActionErrors allErrors = (ActionErrors) session.getAttribute("listErrorMessage");
        saveErrors(request, allErrors);
        session.removeAttribute("listErrorMessage");
      }//end of if (session.getAttribute("listErrorMessage") != null)
     
      DisplayList displaylist = ( DisplayList )request.getAttribute( "displaylist") ;
      TimeSheetList DL= null;
      ListGenerator lg = ListGenerator.getListGenerator(dataSource);
      if( displaylist == null  )
      {
        DL = ( TimeSheetList )lg.getTimeSheetList( userobjectd.getIndividualID() , 1,listpreference.getRecordsPerPage() , "" ,listpreference.getSortElement());
      }
      else//when display list is not null
      {
        String searchSession = displaylistSession.getSearchString();
        String searchrequest = displaylist.getSearchString();
View Full Code Here

      emailListForm.set("folderPathList", folderPathList);
    } catch (Exception e) {
      logger.error("[execute] Exception thrown.", e);
    }

    ListPreference listPreference = userObject.getListPreference("Email");
    ListView view = listPreference.getListView(String.valueOf(listPreference.getDefaultView()));
    ValueListParameters listParameters = null;
    ValueListParameters requestListParameters = (ValueListParameters)request
        .getAttribute("listParameters");

    if (requestListParameters == null) {
      // build up new Parameters
      listParameters = new ValueListParameters(ValueListConstants.EMAIL_LIST_TYPE, listPreference
          .getRecordsPerPage(), 1);
    } else {
      // paging or sorting or something, use the parameters from the request.
      listParameters = requestListParameters;
    }

    if (listParameters.getSortColumn() == 0) {
      FieldDescriptor sortField = (FieldDescriptor)ValueListConstants.emailViewMap
          .get(listPreference.getSortElement());
      listParameters.setSortColumn(sortField.getQueryIndex());

      if (listPreference.getsortOrder()) {
        listParameters.setSortDirection("ASC");
      } else {
        listParameters.setSortDirection("DESC");
      }
    }
View Full Code Here

    GlobalMasterLists globalMasterLists = GlobalMasterLists.getGlobalMasterLists(dataSource);
    HashMap moduleList = new HashMap();
    if (globalMasterLists.get("moduleList") != null)
      moduleList = (HashMap)globalMasterLists.get("moduleList");
   
    ListPreference listPreference = userObject.getListPreference("Note");
    ListView view = listPreference.getListView(String.valueOf(listPreference.getDefaultView()));
   
    ValueListParameters listParameters = null;
    ValueListParameters requestListParameters = (ValueListParameters)request.getAttribute("listParameters");
    if (requestListParameters == null) { // build up new Parameters
      listParameters = new ValueListParameters(ValueListConstants.NOTE_LIST_TYPE, listPreference.getRecordsPerPage(), 1);
    } else { // paging or sorting or something, use the parameters from the request.
      listParameters = requestListParameters;
    }
    if (listParameters.getSortColumn() == 0) {
      FieldDescriptor sortField = (FieldDescriptor)ValueListConstants.noteViewMap.get(listPreference.getSortElement());
      listParameters.setSortColumn(sortField.getQueryIndex());
      if (listPreference.getsortOrder())
        listParameters.setSortDirection("ASC");
      else
        listParameters.setSortDirection("DESC");
    }
   
View Full Code Here

TOP

Related Classes of com.centraview.common.ListPreference

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.