コード例 #1
0
    public static OfferInfoDbType getOfferInfoDbEntry(
        int companyId, int branchId, int offerId, OffersInfo offersInfo) {
      OfferInfoDbType dbEntry = new OfferInfoDbType();

      dbEntry.setId(getOfferInfoPrimaryKey(companyId, offerId));

      dbEntry.setType(offersInfo.getType());
      dbEntry.setDetails(offersInfo.getDetails());
      dbEntry.setBranchId(branchId);

      dbEntry.setStartTS(offersInfo.getStart());
      dbEntry.setEndTS(offersInfo.getEnd());

      dbEntry.setRecurrenceDay(offersInfo.getRecurrenceDay());
      dbEntry.setRecurrence(offersInfo.isRecurrence());
      dbEntry.setHourlyPush(offersInfo.isHourlyPush());
      dbEntry.setClientAppVisibility(offersInfo.isClientAppVisibility());

      return dbEntry;
    }