Class: BrNfe::Person
- Inherits:
-
ActiveModelBase
- Object
- ActiveModelBase
- BrNfe::Person
- Includes:
- Association::HaveAddress
- Defined in:
- lib/br_nfe/person.rb
Direct Known Subclasses
BrNfe::Product::Destinatario, BrNfe::Product::Emitente, BrNfe::Product::Nfe::Transporte::Transportador, Service::Destinatario, Service::Emitente, Service::Intermediario
Instance Attribute Summary collapse
-
#codigo_regime_tributario ⇒ Object
CRT - Código de Regime Tributário 1=Simples Nacional; 2=Simples Nacional, excesso sublimite de receita bruta; 3=Regime Normal.
-
#cpf_cnpj ⇒ Object
Obrigatórios.
-
#email ⇒ Object
Returns the value of attribute email.
-
#incentivo_fiscal ⇒ Object
Returns the value of attribute incentivo_fiscal.
-
#inscricao_estadual ⇒ Object
Returns the value of attribute inscricao_estadual.
-
#inscricao_municipal ⇒ Object
Returns the value of attribute inscricao_municipal.
-
#inscricao_suframa ⇒ Object
Returns the value of attribute inscricao_suframa.
-
#natureza_operacao ⇒ Object
Returns the value of attribute natureza_operacao.
-
#nome_fantasia ⇒ Object
Não obrigatórios.
-
#razao_social ⇒ Object
Returns the value of attribute razao_social.
-
#regime_especial_tributacao ⇒ Object
Returns the value of attribute regime_especial_tributacao.
-
#telefone ⇒ Object
Returns the value of attribute telefone.
Attributes inherited from ActiveModelBase
Instance Method Summary collapse
Methods included from Association::HaveAddress
#endereco, #endereco=, #validar_endereco
Methods inherited from ActiveModelBase
#assign_attributes, #default_values, #initialize
Constructor Details
This class inherits a constructor from BrNfe::ActiveModelBase
Instance Attribute Details
#codigo_regime_tributario ⇒ Object
CRT - Código de Regime Tributário 1=Simples Nacional; 2=Simples Nacional, excesso sublimite de receita bruta; 3=Regime Normal.
40 41 42 |
# File 'lib/br_nfe/person.rb', line 40 def codigo_regime_tributario @codigo_regime_tributario end |
#cpf_cnpj ⇒ Object
Obrigatórios
18 19 20 |
# File 'lib/br_nfe/person.rb', line 18 def cpf_cnpj @cpf_cnpj end |
#email ⇒ Object
Returns the value of attribute email.
26 27 28 |
# File 'lib/br_nfe/person.rb', line 26 def email @email end |
#incentivo_fiscal ⇒ Object
Returns the value of attribute incentivo_fiscal.
33 34 35 |
# File 'lib/br_nfe/person.rb', line 33 def incentivo_fiscal @incentivo_fiscal end |
#inscricao_estadual ⇒ Object
Returns the value of attribute inscricao_estadual.
31 32 33 |
# File 'lib/br_nfe/person.rb', line 31 def inscricao_estadual @inscricao_estadual end |
#inscricao_municipal ⇒ Object
Returns the value of attribute inscricao_municipal.
30 31 32 |
# File 'lib/br_nfe/person.rb', line 30 def inscricao_municipal @inscricao_municipal end |
#inscricao_suframa ⇒ Object
Returns the value of attribute inscricao_suframa.
32 33 34 |
# File 'lib/br_nfe/person.rb', line 32 def inscricao_suframa @inscricao_suframa end |
#natureza_operacao ⇒ Object
Returns the value of attribute natureza_operacao.
29 30 31 |
# File 'lib/br_nfe/person.rb', line 29 def natureza_operacao @natureza_operacao end |
#nome_fantasia ⇒ Object
Não obrigatórios
24 25 26 |
# File 'lib/br_nfe/person.rb', line 24 def nome_fantasia @nome_fantasia end |
#razao_social ⇒ Object
Returns the value of attribute razao_social.
21 22 23 |
# File 'lib/br_nfe/person.rb', line 21 def @razao_social end |
#regime_especial_tributacao ⇒ Object
Returns the value of attribute regime_especial_tributacao.
28 29 30 |
# File 'lib/br_nfe/person.rb', line 28 def regime_especial_tributacao @regime_especial_tributacao end |
#telefone ⇒ Object
Returns the value of attribute telefone.
25 26 27 |
# File 'lib/br_nfe/person.rb', line 25 def telefone @telefone end |
Instance Method Details
#incentivo_fiscal? ⇒ Boolean
62 63 64 |
# File 'lib/br_nfe/person.rb', line 62 def incentivo_fiscal? convert_to_boolean(incentivo_fiscal) end |
#optante_simples_nacional? ⇒ Boolean
58 59 60 |
# File 'lib/br_nfe/person.rb', line 58 def optante_simples_nacional? "#{codigo_regime_tributario}".in?(['1','2']) end |