Class: Yoomoney::Models::Payment::PaymentMethod::PaymentMethodElectronicCertificate::Article

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/yoomoney/models/payment.rb

Defined Under Namespace

Classes: Certificate

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, #inspect, inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(articles: nil, electronic_certificate: nil) ⇒ Object



555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
# File 'lib/yoomoney/models/payment.rb', line 555

class Article < Yoomoney::Internal::Type::BaseModel
  # @!attribute article_number
  #
  #   @return [Integer]
  required :article_number, Integer

  # @!attribute certificates
  #
  #   @return [Array<Yoomoney::Models::Payment::PaymentMethod::PaymentMethodElectronicCertificate::Article::Certificate>]
  required :certificates,
           -> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::Payment::PaymentMethod::PaymentMethodElectronicCertificate::Article::Certificate] }

  # @!attribute tru_code
  #
  #   @return [String]
  required :tru_code, String

  # @!attribute article_code
  #
  #   @return [String, nil]
  optional :article_code, String

  # @!method initialize(article_number:, certificates:, tru_code:, article_code: nil)
  #   @param article_number [Integer]
  #   @param certificates [Array<Yoomoney::Models::Payment::PaymentMethod::PaymentMethodElectronicCertificate::Article::Certificate>]
  #   @param tru_code [String]
  #   @param article_code [String]

  class Certificate < Yoomoney::Internal::Type::BaseModel
    # @!attribute applied_compensation
    #
    #   @return [Yoomoney::Models::MonetaryAmount]
    required :applied_compensation, -> { Yoomoney::MonetaryAmount }

    # @!attribute available_compensation
    #
    #   @return [Yoomoney::Models::MonetaryAmount]
    required :available_compensation, -> { Yoomoney::MonetaryAmount }

    # @!attribute certificate_id
    #
    #   @return [String]
    required :certificate_id, String

    # @!attribute tru_quantity
    #
    #   @return [Integer]
    required :tru_quantity, Integer

    # @!method initialize(applied_compensation:, available_compensation:, certificate_id:, tru_quantity:)
    #   @param applied_compensation [Yoomoney::Models::MonetaryAmount]
    #   @param available_compensation [Yoomoney::Models::MonetaryAmount]
    #   @param certificate_id [String]
    #   @param tru_quantity [Integer]
  end
end

Instance Attribute Details

#article_codeString?

Returns:

  • (String, nil)


575
# File 'lib/yoomoney/models/payment.rb', line 575

optional :article_code, String

#article_numberInteger

Returns:

  • (Integer)


559
# File 'lib/yoomoney/models/payment.rb', line 559

required :article_number, Integer

#certificatesArray<Yoomoney::Models::Payment::PaymentMethod::PaymentMethodElectronicCertificate::Article::Certificate>



564
565
# File 'lib/yoomoney/models/payment.rb', line 564

required :certificates,
-> { Yoomoney::Internal::Type::ArrayOf[Yoomoney::Payment::PaymentMethod::PaymentMethodElectronicCertificate::Article::Certificate] }

#tru_codeString

Returns:

  • (String)


570
# File 'lib/yoomoney/models/payment.rb', line 570

required :tru_code, String