Discount.php 441 B

123456789101112131415161718192021
  1. <?php
  2. namespace Braintree;
  3. class Discount extends Modification
  4. {
  5. public static function factory($attributes)
  6. {
  7. $instance = new self();
  8. $instance->_initialize($attributes);
  9. return $instance;
  10. }
  11. // static methods redirecting to gateway
  12. public static function all()
  13. {
  14. return Configuration::gateway()->discount()->all();
  15. }
  16. }
  17. class_alias('Braintree\Discount', 'Braintree_Discount');