@Subscribe public void defined(Defined event) { bus.publish( new ProjectDefinedMessage( event.getId(), event.getTitle(), event.getOwner(), event.getHoursRequired(), event.getDefinedAt())); }
public static List<Currency> getCurrenciesList() { Map<String, String> currencyCodes = Defined.getCurrenciesArray(); List<Currency> currencies = new ArrayList<>(); for (Map.Entry<String, String> currencyEntry : currencyCodes.entrySet()) { Currency currency = new Currency(); currency.setCode(currencyEntry.getKey()); currency.setName(currencyEntry.getValue()); currencies.add(currency); } return currencies; }
public static String getAppCurrency(Context context) { return Utils.getPreferences(context) .getString(PREF_CURRENCY_CODE, Defined.getDefaultCurrency()); }