Ejemplo n.º 1
0
 private void deletePreferedByCity() {
   preferenceDao
       .queryBuilder()
       .where(
           DBPreferenceDao.Properties.City.eq(city.toUpperCase()),
           DBPreferenceDao.Properties.Country.eq(country),
           DBPreferenceDao.Properties.State.eq(province))
       .buildDelete()
       .executeDeleteWithoutDetachingEntities();
 }
Ejemplo n.º 2
0
  private void loadSavedAttrList() {
    List<DBPreference> preferedCompanyInThisCity =
        preferenceDao
            .queryBuilder()
            .where(
                DBPreferenceDao.Properties.City.eq(city.toUpperCase()),
                DBPreferenceDao.Properties.Country.eq(country),
                DBPreferenceDao.Properties.State.eq(province))
            .list();

    if (preferedCompanyInThisCity.size() == 0) {
      preferedAttrList = "";
    } else {
      preferedAttrList = preferedCompanyInThisCity.get(0).getAttributeList();
    }
  }