protected void transactionDateRangeSelector() {
    dateRangeSelector = new SelectCombo(messages.date());

    ArrayList<String> dateRangeList = new ArrayList<String>();
    String[] dateRangeArray = {
      messages.all(),
      messages.thisWeek(),
      messages.thisMonth(),
      messages.lastWeek(),
      messages.lastMonth(),
      messages.thisFinancialYear(),
      messages.lastFinancialYear(),
      messages.thisFinancialQuarter(),
      messages.lastFinancialQuarter(),
      messages.financialYearToDate()
    };
    for (int i = 0; i < dateRangeArray.length; i++) {
      dateRangeList.add(dateRangeArray[i]);
    }
    dateRangeSelector.initCombo(dateRangeList);

    dateRangeSelector.setComboItem(messages.all());
    dateRangeSelector.addSelectionChangeHandler(
        new IAccounterComboSelectionChangeHandler<String>() {
          @Override
          public void selectedComboBoxItem(String selectItem) {
            dateRangeSelector.setComboItem(selectItem);
            if (dateRangeSelector.getValue() != null) {
              dateRangeChanged(selectItem);
              callRPC(0, getPageSize());
            }
          }
        });
  }
Пример #2
0
  private void viewTypeCombo() {
    if (activeInActiveSelect == null) {
      activeInActiveSelect = new SelectCombo(messages.show());

      List<String> activetypeList = new ArrayList<String>();
      activetypeList.add(messages.active());
      activetypeList.add(messages.inActive());
      activeInActiveSelect.initCombo(activetypeList);
      activeInActiveSelect.setComboItem(messages.active());
      activeInActiveSelect.addSelectionChangeHandler(
          new IAccounterComboSelectionChangeHandler<String>() {

            @Override
            public void selectedComboBoxItem(String selectItem) {
              if (activeInActiveSelect.getSelectedValue() != null) {
                if (activeInActiveSelect
                    .getSelectedValue()
                    .toString()
                    .equalsIgnoreCase(messages.active())) {
                  refreshActiveinActiveList(true);
                } else {
                  refreshActiveinActiveList(false);
                }
              }
            }
          });
    }
  }
 @Override
 public HashMap<String, Object> saveView() {
   HashMap<String, Object> map = new HashMap<String, Object>();
   map.put("activeInActive", activeInActiveSelect.getSelectedValue());
   map.put("currentView", trasactionViewSelect.getSelectedValue());
   map.put("transactionType", trasactionViewTypeSelect.getSelectedValue());
   map.put("dateRange", dateRangeSelector.getSelectedValue());
   map.put("selectedItem", selectedItem == null ? "" : selectedItem.getName());
   map.put("itemSelection", itemsListGrid.getSelection());
   return map;
 }
Пример #4
0
 @Override
 public HashMap<String, Object> saveView() {
   HashMap<String, Object> map = new HashMap<String, Object>();
   map.put("activeInActive", activeInActiveSelect.getSelectedValue());
   map.put("currentView", trasactionViewSelect.getSelectedValue());
   map.put("transactionType", trasactionViewTypeSelect.getSelectedValue());
   map.put("dateRange", dateRangeSelector.getSelectedValue());
   map.put("selectedCustomer", selectedCustomer == null ? "" : selectedCustomer.getName());
   PayeeList selection = custGrid.getSelection();
   map.put("payeeSelection", selection);
   return map;
 }
Пример #5
0
 private int getTransactionStatusType() {
   if (trasactionViewTypeSelect.getSelectedValue() != null) {
     Set<Integer> keySet = transactiontypebyStatusMap.keySet();
     for (Integer integerKey : keySet) {
       String entrystring = transactiontypebyStatusMap.get(integerKey);
       if (trasactionViewTypeSelect.getSelectedValue().equals(entrystring)) {
         return integerKey;
       }
     }
   }
   return TransactionHistory.ALL_INVOICES;
 }
  @Override
  public void restoreView(HashMap<String, Object> map) {

    if (map == null || map.isEmpty()) {
      return;
    }
    String activeInactive = (String) map.get("activeInActive");
    activeInActiveSelect.setComboItem(activeInactive);
    if (activeInactive.equalsIgnoreCase(messages.active())) {
      refreshActiveinactiveList(true);
    } else {
      refreshActiveinactiveList(false);
    }

    String currentView = (String) map.get("currentView");
    trasactionViewSelect.setComboItem(currentView);
    if (currentView != null) {
      getMessagesList();
    }

    String transctionType = (String) map.get("transactionType");
    trasactionViewTypeSelect.setComboItem(transctionType);

    String dateRange1 = (String) map.get("dateRange");
    dateRangeSelector.setComboItem(dateRange1);
    if (dateRange1 != null) {
      dateRangeChanged(dateRange1);
    }
    ClientItem object = (ClientItem) map.get("itemSelection");
    itemsListGrid.setSelection(object);

    String customer = (String) map.get("selectedItem");

    if (customer != null && !(customer.isEmpty())) {
      selectedItem = getCompany().getItemByName(customer);
    }
    if (this.selectedItem != null) {
      itemsListGrid.setSelectedItem(selectedItem);

      selectedItem = Accounter.getCompany().getItem(selectedItem.getID());

      onItemSelected();
    } else {
      callRPC(0, getPageSize());
    }
  }
 private int getTransactionType() {
   String selectedValue = trasactionViewSelect.getSelectedValue();
   if (selectedValue.equalsIgnoreCase(messages.invoices())) {
     return ClientTransaction.TYPE_INVOICE;
   } else if (selectedValue.equalsIgnoreCase(messages.cashSales())) {
     return ClientTransaction.TYPE_CASH_SALES;
   } else if (selectedValue.equalsIgnoreCase(messages.payeeCreditNotes(Global.get().Customer()))) {
     return ClientTransaction.TYPE_CUSTOMER_CREDIT_MEMO;
   } else if (selectedValue.equalsIgnoreCase(messages.quotes())
       || selectedValue.equalsIgnoreCase(messages.credits())
       || selectedValue.equalsIgnoreCase(messages.Charges())) {
     return ClientTransaction.TYPE_ESTIMATE;
   } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.cashPurchases())) {
     return ClientTransaction.TYPE_CASH_PURCHASE;
   } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.bills())) {
     return ClientTransaction.TYPE_ENTER_BILL;
   } else if (trasactionViewSelect
       .getSelectedValue()
       .equalsIgnoreCase(messages.payeeCreditNotes(Global.get().Vendor()))) {
     return ClientTransaction.TYPE_VENDOR_CREDIT_MEMO;
   } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.expenses())) {
     return ClientTransaction.TYPE_EXPENSE;
   } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.salesOrders())) {
     return TransactionHistory.TYPE_SALES_ORDER;
   } else if (trasactionViewSelect
       .getSelectedValue()
       .equalsIgnoreCase(messages.purchaseOrders())) {
     return TransactionHistory.TYPE_PURCHASE_ORDER;
   }
   return 0;
 }
  private void transactionViewSelectCombo() {
    if (trasactionViewSelect == null) {
      trasactionViewSelect = new SelectCombo(messages.currentView());

      ArrayList<String> transactionTypeList = new ArrayList<String>();
      transactionTypeList.add(messages.allTransactions());
      for (String type : transactionTypes) {
        if (type.equalsIgnoreCase(messages.Charges())
            || type.equalsIgnoreCase(messages.credits())) {
          if (getPreferences().isDelayedchargesEnabled()) {
            transactionTypeList.add(type);
          } else {
            continue;
          }
        } else if (type.equalsIgnoreCase(messages.salesOrders())) {
          if (getPreferences().isSalesOrderEnabled()) {
            transactionTypeList.add(type);
          } else {
            continue;
          }
        } else if (type.equalsIgnoreCase(messages.purchaseOrders())) {
          if (getPreferences().isPurchaseOrderEnabled()) {
            transactionTypeList.add(type);
          } else {
            continue;
          }
        } else {
          transactionTypeList.add(type);
        }
      }
      trasactionViewSelect.initCombo(transactionTypeList);
      trasactionViewSelect.setComboItem(messages.allTransactions());
      trasactionViewSelect.addSelectionChangeHandler(
          new IAccounterComboSelectionChangeHandler<String>() {

            @Override
            public void selectedComboBoxItem(String selectItem) {
              if (trasactionViewSelect.getSelectedValue() != null) {
                getMessagesList();
                callRPC(0, 25);
              }
            }
          });
    }
  }
Пример #9
0
  private void transactionViewSelectCombo() {
    if (trasactionViewSelect == null) {
      trasactionViewSelect = new SelectCombo(messages.currentView());

      List<String> transactionTypeList = new ArrayList<String>();
      transactionTypeList.add(messages.allTransactions());
      transactionTypeList.add(messages.invoices());
      if (getPreferences().isDoyouwantEstimates()) {
        transactionTypeList.add(messages.quotes());
      }
      if (getCompany().getPreferences().isDelayedchargesEnabled()) {
        transactionTypeList.add(messages.Charges());
        transactionTypeList.add(messages.credits());
      }
      transactionTypeList.add(messages.cashSales());
      transactionTypeList.add(messages.receivedPayments());
      transactionTypeList.add(messages.CustomerCreditNotes());
      transactionTypeList.add(messages.customerRefunds(Global.get().Customer()));
      transactionTypeList.add(messages.cheques());
      if (getPreferences().isSalesOrderEnabled()) {
        transactionTypeList.add(messages.salesOrders());
      }
      trasactionViewSelect.initCombo(transactionTypeList);
      trasactionViewSelect.setComboItem(messages.allTransactions());
      trasactionViewSelect.addSelectionChangeHandler(
          new IAccounterComboSelectionChangeHandler<String>() {

            @Override
            public void selectedComboBoxItem(String selectItem) {
              if (trasactionViewSelect.getSelectedValue() != null) {
                getMessagesList();
                callRPC(0, getPageSize());
              }
            }
          });
    }
  }
Пример #10
0
  private void transactionViewTypeSelectCombo() {
    if (trasactionViewTypeSelect == null) {
      trasactionViewTypeSelect = new SelectCombo(messages.type());
      getMessagesList();
      trasactionViewTypeSelect.addSelectionChangeHandler(
          new IAccounterComboSelectionChangeHandler<String>() {

            @Override
            public void selectedComboBoxItem(String selectItem) {
              if (trasactionViewTypeSelect.getSelectedValue() != null) {
                callRPC(0, getPageSize());
              }
            }
          });
    }
  }
Пример #11
0
  private int getTransactionType() {
    String selectedValue = trasactionViewSelect.getSelectedValue();
    if (selectedValue.equalsIgnoreCase(messages.invoices())) {

      return TYPE_INVOICE;
    } else if (selectedValue.equalsIgnoreCase(messages.cashSales())) {
      return TYPE_CAHSSALE;
    } else if (selectedValue.equalsIgnoreCase(messages.receivedPayments())) {
      return TYPE_RECEIVE_PAYMENT;
    } else if (selectedValue.equalsIgnoreCase(messages.CustomerCreditNotes())) {
      return TYPE_CREDITNOTE;
    } else if (selectedValue.equalsIgnoreCase(messages.quotes())
        || selectedValue.equalsIgnoreCase(messages.credits())
        || selectedValue.equalsIgnoreCase(messages.Charges())) {
      return TYPE_ESTIMATE;
    } else if (selectedValue.equalsIgnoreCase(messages.customerRefunds(Global.get().Customer()))) {
      return TYPE_CUSTOMER_REFUND;
    } else if (selectedValue.equalsIgnoreCase(messages.cheques())) {
      return TYPE_WRITE_CHECK;
    } else if (selectedValue.equalsIgnoreCase(messages.salesOrders())) {
      return TYPE_SALES_ORDER;
    }
    return TYPE_ALL_TRANSACTION;
  }
Пример #12
0
  private void getMessagesList() {
    transactiontypebyStatusMap = new HashMap<Integer, String>();
    String selectedValue = trasactionViewSelect.getSelectedValue();
    if (selectedValue.equalsIgnoreCase(messages.allTransactions())) {
      transactiontypebyStatusMap.put(
          TransactionHistory.ALL_TRANSACTIONS, messages.allTransactions());
    } else if (selectedValue.equalsIgnoreCase(messages.invoices())) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_INVOICES, messages.getallInvoices());
      transactiontypebyStatusMap.put(
          TransactionHistory.OPENED_INVOICES, messages.getOpendInvoices());
      transactiontypebyStatusMap.put(
          TransactionHistory.OVER_DUE_INVOICES, messages.overDueInvoices());
      if (Accounter.hasPermission(Features.DRAFTS)) {
        transactiontypebyStatusMap.put(
            TransactionHistory.DRAFT_INVOICES, messages.draftTransaction(messages.invoices()));
      }
    } else if (selectedValue.equalsIgnoreCase(messages.cashSales())) {
      transactiontypebyStatusMap.put(
          TransactionHistory.ALL_CASHSALES, messages.all() + " " + messages.cashSales());
      if (Accounter.hasPermission(Features.DRAFTS)) {
        transactiontypebyStatusMap.put(
            TransactionHistory.DRAFT_CASHSALES, messages.draftTransaction(messages.cashSales()));
      }

    } else if (selectedValue.equalsIgnoreCase(messages.quotes())) {

      transactiontypebyStatusMap.put(TransactionHistory.ALL_QUOTES, messages.allQuotes());
      if (Accounter.hasPermission(Features.DRAFTS)) {
        transactiontypebyStatusMap.put(
            TransactionHistory.DRAFT_QUOTES, messages.draftTransaction(messages.quotes()));
      }
    } else if (selectedValue.equalsIgnoreCase(messages.credits())) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_CREDITS, messages.allCredits());
      if (Accounter.hasPermission(Features.DRAFTS)) {
        transactiontypebyStatusMap.put(
            TransactionHistory.DRAFT_CREDITS, messages.draftTransaction(messages.credits()));
      }

    } else if (selectedValue.equalsIgnoreCase(messages.Charges())) {

      transactiontypebyStatusMap.put(TransactionHistory.ALL_CHARGES, messages.allCahrges());
      if (Accounter.hasPermission(Features.DRAFTS)) {
        transactiontypebyStatusMap.put(
            TransactionHistory.DRAFT_CHARGES, messages.draftTransaction(messages.Charges()));
      }

    } else if (selectedValue.equalsIgnoreCase(messages.receivedPayments())) {
      transactiontypebyStatusMap.put(
          TransactionHistory.ALL_RECEIVEDPAYMENTS,
          messages.all() + " " + messages.receivedPayments());
      transactiontypebyStatusMap.put(
          TransactionHistory.RECEV_PAY_BY_CASH, messages.receivedPaymentsbyCash());
      transactiontypebyStatusMap.put(
          TransactionHistory.RECEV_PAY_BY_CHEQUE, messages.receivedPaymentsbyCheque());
      transactiontypebyStatusMap.put(
          TransactionHistory.RECEV_PAY_BY_CREDITCARD, messages.receivedPaymentsbyCreditCard());
      transactiontypebyStatusMap.put(
          TransactionHistory.RECEV_PAY_BY_DIRECT_DEBIT, messages.receivedPaymentsbyDirectDebit());
      transactiontypebyStatusMap.put(
          TransactionHistory.RECEV_PAY_BY_MASTERCARD, messages.receivedPaymentsbyMastercard());
      transactiontypebyStatusMap.put(
          TransactionHistory.RECEV_PAY_BY_ONLINE, messages.receivedPaymentsbyOnlineBanking());
      transactiontypebyStatusMap.put(
          TransactionHistory.RECEV_PAY_BY_STANDING_ORDER,
          messages.receivedPaymentsbyStandingOrder());
      transactiontypebyStatusMap.put(
          TransactionHistory.RECEV_PAY_BY_MAESTRO, messages.receivedPaymentsbySwitchMaestro());

    } else if (selectedValue.equalsIgnoreCase(messages.CustomerCreditNotes())) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_CREDITMEMOS, messages.allCreditMemos());
      if (Accounter.hasPermission(Features.DRAFTS)) {
        transactiontypebyStatusMap.put(
            TransactionHistory.DRAFT_CREDITMEMOS, messages.draftTransaction(messages.creditNote()));
      }
      // transactiontypebyStatusMap.put(
      // TransactionHistory.OPEND_CREDITMEMOS,
      // messages.openCreditMemos());

    } else if (selectedValue.equalsIgnoreCase(messages.customerRefunds(Global.get().Customer()))) {
      transactiontypebyStatusMap.put(
          TransactionHistory.REFUNDS_BY_CREDITCARD, messages.refundsByCreditCard());
      transactiontypebyStatusMap.put(TransactionHistory.REFUNDS_BYCASH, messages.refundsByCash());
      transactiontypebyStatusMap.put(
          TransactionHistory.REFUNDS_BYCHEQUE, messages.refundsByCheck());

      transactiontypebyStatusMap.put(
          TransactionHistory.ALL_CUSTOMER_REFUNDS, messages.allCustomerRefunds());
      if (Accounter.hasPermission(Features.DRAFTS)) {
        transactiontypebyStatusMap.put(
            TransactionHistory.DRAFT_CUSTOMER_REFUNDS,
            messages.draftTransaction(messages.customerRefunds(Global.get().Customer())));
      }
    } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.cheques())) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_CHEQUES, messages.allcheques());
      if (Accounter.hasPermission(Features.DRAFTS)) {
        transactiontypebyStatusMap.put(
            TransactionHistory.DRAFT_CHEQUES, messages.draftTransaction(messages.cheques()));
      }
    } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.salesOrders())) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_SALES_ORDERS, messages.all());
      transactiontypebyStatusMap.put(
          TransactionHistory.COMPLETED_SALES_ORDERS, messages.completed());
      transactiontypebyStatusMap.put(TransactionHistory.OPEN_SALES_ORDERS, messages.open());
    }
    List<String> typeList = new ArrayList<String>(transactiontypebyStatusMap.values());
    Collections.sort(
        typeList,
        new Comparator<String>() {

          @Override
          public int compare(String entry1, String entry2) {
            return entry1.compareTo(entry2);
          }
        });
    trasactionViewTypeSelect.initCombo(typeList);
    trasactionViewTypeSelect.setComboItem(typeList.get(0));
  }
Пример #13
0
  private void getMessagesList() {
    String selectedValue = trasactionViewSelect.getSelectedValue();
    transactiontypebyStatusMap = new HashMap<Integer, String>();
    if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.allTransactions())) {
      transactiontypebyStatusMap.put(
          TransactionHistory.ALL_TRANSACTIONS, messages.allTransactions());
    } else if (selectedValue.equalsIgnoreCase(messages.quotes())) {

      transactiontypebyStatusMap.put(TransactionHistory.ALL_QUOTES, messages.allQuotes());
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_QUOTES, messages.draftTransaction(messages.quotes()));

    } else if (selectedValue.equalsIgnoreCase(messages.Charges())) {

      transactiontypebyStatusMap.put(TransactionHistory.ALL_CHARGES, messages.allCahrges());
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_CHARGES, messages.draftTransaction(messages.Charges()));

    } else if (selectedValue.equalsIgnoreCase(messages.credits())) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_CREDITS, messages.allCredits());
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_CREDITS, messages.draftTransaction(messages.credits()));

    } else if (selectedValue.equalsIgnoreCase(messages.invoices())) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_INVOICES, messages.getallInvoices());
      transactiontypebyStatusMap.put(
          TransactionHistory.OPENED_INVOICES, messages.getOpendInvoices());
      transactiontypebyStatusMap.put(
          TransactionHistory.OVER_DUE_INVOICES, messages.overDueInvoices());
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_INVOICES, messages.draftTransaction(messages.invoices()));
    } else if (selectedValue.equalsIgnoreCase(messages.cashSales())) {
      transactiontypebyStatusMap.put(
          TransactionHistory.ALL_CASHSALES, messages.all() + " " + messages.cashSales());
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_CASHSALES, messages.draftTransaction(messages.cashSales()));

    } else if (selectedValue.equalsIgnoreCase(messages.payeeCreditNotes(Global.get().Customer()))) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_CREDITMEMOS, messages.allCreditMemos());
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_CREDITMEMOS, messages.draftTransaction(messages.creditNote()));
      // transactiontypebyStatusMap.put(
      // TransactionHistory.OPEND_CREDITMEMOS,
      // messages.openCreditMemos());

    } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.cashPurchases())) {
      transactiontypebyStatusMap.put(
          TransactionHistory.ALL_CASH_PURCHASES, messages.allCashPurchases());
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_CASH_PURCHASES,
          messages.draftTransaction(messages.cashPurchases()));

    } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.bills())) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_BILLS, messages.allBills());
      transactiontypebyStatusMap.put(
          TransactionHistory.OPEND_BILLS, messages.all() + " " + messages.openedBills());
      transactiontypebyStatusMap.put(
          TransactionHistory.OVERDUE_BILLS, messages.all() + " " + messages.overDueBills());
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_BILLS, messages.draftTransaction(messages.bills()));

    } else if (trasactionViewSelect
        .getSelectedValue()
        .equalsIgnoreCase(messages.payeeCreditNotes(Global.get().Vendor()))) {
      transactiontypebyStatusMap.put(
          TransactionHistory.ALL_VENDOR_CREDITNOTES,
          messages.all() + " " + messages.payeeCreditNotes(Global.get().Vendor()));
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_VENDOR_CREDITNOTES,
          messages.draftTransaction(messages.payeeCreditNotes(Global.get().Vendor())));

    } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.expenses())) {
      transactiontypebyStatusMap.put(TransactionHistory.ALL_EXPENSES, messages.allExpenses());
      transactiontypebyStatusMap.put(
          TransactionHistory.CREDIT_CARD_EXPENSES, messages.creditCardExpenses());
      transactiontypebyStatusMap.put(TransactionHistory.CASH_EXPENSES, messages.cashExpenses());
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_CREDIT_CARD_EXPENSES,
          messages.draftTransaction(messages.creditCardExpenses()));
      transactiontypebyStatusMap.put(
          TransactionHistory.DRAFT_CASH_EXPENSES,
          messages.draftTransaction(messages.cashExpenses()));

    } else if (trasactionViewSelect.getSelectedValue().equalsIgnoreCase(messages.salesOrders())) {

      transactiontypebyStatusMap.put(TransactionHistory.ALL_SALES_ORDERS, messages.all());
      transactiontypebyStatusMap.put(TransactionHistory.DRAFT_SALES_ORDERS, messages.drafts());

    } else if (trasactionViewSelect
        .getSelectedValue()
        .equalsIgnoreCase(messages.purchaseOrders())) {

      transactiontypebyStatusMap.put(TransactionHistory.ALL_PURCHASE_ORDERS, messages.all());
      transactiontypebyStatusMap.put(TransactionHistory.DRAFT_PURCHASE_ORDERS, messages.drafts());
    }
    List<String> typeList = new ArrayList<String>(transactiontypebyStatusMap.values());
    Collections.sort(
        typeList,
        new Comparator<String>() {

          @Override
          public int compare(String entry1, String entry2) {
            return entry1.compareTo(entry2);
          }
        });
    trasactionViewTypeSelect.initCombo(typeList);
    trasactionViewTypeSelect.setComboItem(typeList.get(0));
  }