コード例 #1
0
        } else {
            $criteria->add(EventNotificationTemplatePeer::PARTNER_ID, PartnerPeer::GLOBAL_PARTNER);
        }
        return EventNotificationTemplatePeer::doSelect($criteria, $con);
    }
    /**
     * Retrieve event notification templates according to systemName
     * @param string $systemName
     * @param int $excludeId
     * @param PropelPDO $con
     * @return array<EventNotificationTemplate>
     */
    public static function retrieveBySystemName($systemName, $excludeId = null, PropelPDO $con = null)
    {
        $criteria = new Criteria(EventNotificationTemplatePeer::DATABASE_NAME);
        $criteria->add(EventNotificationTemplatePeer::STATUS, EventNotificationTemplateStatus::ACTIVE);
        $criteria->add(EventNotificationTemplatePeer::SYSTEM_NAME, $systemName);
        if ($excludeId) {
            $criteria->add(EventNotificationTemplatePeer::ID, $excludeId, Criteria::NOT_EQUAL);
        }
        $criteria->add(EventNotificationTemplatePeer::PARTNER_ID, kCurrentContext::getCurrentPartnerId());
        return EventNotificationTemplatePeer::doSelect($criteria);
    }
    public static function getCacheInvalidationKeys()
    {
        return array(array("eventNotificationTemplate:partnerId=%s", self::PARTNER_ID));
    }
}
// EventNotificationTemplatePeer
EventNotificationTemplatePeer::buildTableMap();