{*******************************************************************************
Title: T2Ti ERP                                                                 
Description:  DTO  relacionado à tabela [NFE_DETALHE_IMPOSTO_ISSQN] 
                                                                                
The MIT License                                                                 
                                                                                
Copyright: Copyright (C) 2017 T2Ti.COM                                          
                                                                                
Permission is hereby granted, free of charge, to any person                     
obtaining a copy of this software and associated documentation                  
files (the "Software"), to deal in the Software without                         
restriction, including without limitation the rights to use,                    
copy, modify, merge, publish, distribute, sublicense, and/or sell               
copies of the Software, and to permit persons to whom the                       
Software is furnished to do so, subject to the following                        
conditions:                                                                     
                                                                                
The above copyright notice and this permission notice shall be                  
included in all copies or substantial portions of the Software.                 
                                                                                
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,                 
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES                 
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND                        
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT                     
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,                    
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING                    
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR                   
OTHER DEALINGS IN THE SOFTWARE.                                                 
                                                                                
       The author may be contacted at:                                          
           t2ti.com@gmail.com                                                   
                                                                                
@author Albert Eije (t2ti.com@gmail.com)                    
@version 1.0                                                                    
*******************************************************************************}
unit NfeDetalheImpostoIssqnDTO;

interface

uses
  Atributos, Classes, Constantes, Generics.Collections, DB,

  SynCommons,
  mORMot;

type
  TNfe_Detalhe_Imposto_Issqn = class(TSQLRecord)
   
  private
    FPK: Integer;
    FID_NFE_DETALHE: Integer;
    FBASE_CALCULO_ISSQN: Double;
    FALIQUOTA_ISSQN: Double;
    FVALOR_ISSQN: Double;
    FMUNICIPIO_ISSQN: Integer;
    FITEM_LISTA_SERVICOS: Integer;
    FVALOR_DEDUCAO: Double;
    FVALOR_OUTRAS_RETENCOES: Double;
    FVALOR_DESCONTO_INCONDICIONADO: Double;
    FVALOR_DESCONTO_CONDICIONADO: Double;
    FVALOR_RETENCAO_ISS: Double;
    FINDICADOR_EXIGIBILIDADE_ISS: Integer;
    FCODIGO_SERVICO: RawUTF8;
    FMUNICIPIO_INCIDENCIA: Integer;
    FPAIS_SEVICO_PRESTADO: Integer;
    FNUMERO_PROCESSO: RawUTF8;
    FINDICADOR_INCENTIVO_FISCAL: Integer;

    //Usado no lado cliente para controlar quais registros serão persistidos
    FPersiste: RawUTF8;

  public
    [TId('ID')]
    [TGeneratedValue(sAuto)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property PK: Integer  read FPK write FPK;
  
    [TColumn('PERSISTE', 'Persiste', 60, [], True)]
    property Persiste: RawUTF8  read FPersiste write FPersiste;
  
  published
    [TColumn('ID_NFE_DETALHE', 'Id Nfe Detalhe', 80, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property IdNfeDetalhe: Integer  read FID_NFE_DETALHE write FID_NFE_DETALHE;
    [TColumn('BASE_CALCULO_ISSQN', 'Base Calculo Issqn', 168, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftFloatComSeparador, taRightJustify)]
    property BaseCalculoIssqn: Double  read FBASE_CALCULO_ISSQN write FBASE_CALCULO_ISSQN;
    [TColumn('ALIQUOTA_ISSQN', 'Aliquota Issqn', 168, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftFloatComSeparador, taRightJustify)]
    property AliquotaIssqn: Double  read FALIQUOTA_ISSQN write FALIQUOTA_ISSQN;
    [TColumn('VALOR_ISSQN', 'Valor Issqn', 168, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftFloatComSeparador, taRightJustify)]
    property ValorIssqn: Double  read FVALOR_ISSQN write FVALOR_ISSQN;
    [TColumn('MUNICIPIO_ISSQN', 'Municipio Issqn', 80, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property MunicipioIssqn: Integer  read FMUNICIPIO_ISSQN write FMUNICIPIO_ISSQN;
    [TColumn('ITEM_LISTA_SERVICOS', 'Item Lista Servicos', 80, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property ItemListaServicos: Integer  read FITEM_LISTA_SERVICOS write FITEM_LISTA_SERVICOS;
    [TColumn('VALOR_DEDUCAO', 'Valor Deducao', 168, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftFloatComSeparador, taRightJustify)]
    property ValorDeducao: Double  read FVALOR_DEDUCAO write FVALOR_DEDUCAO;
    [TColumn('VALOR_OUTRAS_RETENCOES', 'Valor Outras Retencoes', 168, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftFloatComSeparador, taRightJustify)]
    property ValorOutrasRetencoes: Double  read FVALOR_OUTRAS_RETENCOES write FVALOR_OUTRAS_RETENCOES;
    [TColumn('VALOR_DESCONTO_INCONDICIONADO', 'Valor Desconto Incondicionado', 168, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftFloatComSeparador, taRightJustify)]
    property ValorDescontoIncondicionado: Double  read FVALOR_DESCONTO_INCONDICIONADO write FVALOR_DESCONTO_INCONDICIONADO;
    [TColumn('VALOR_DESCONTO_CONDICIONADO', 'Valor Desconto Condicionado', 168, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftFloatComSeparador, taRightJustify)]
    property ValorDescontoCondicionado: Double  read FVALOR_DESCONTO_CONDICIONADO write FVALOR_DESCONTO_CONDICIONADO;
    [TColumn('VALOR_RETENCAO_ISS', 'Valor Retencao Iss', 168, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftFloatComSeparador, taRightJustify)]
    property ValorRetencaoIss: Double  read FVALOR_RETENCAO_ISS write FVALOR_RETENCAO_ISS;
    [TColumn('INDICADOR_EXIGIBILIDADE_ISS', 'Indicador Exigibilidade Iss', 80, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property IndicadorExigibilidadeIss: Integer  read FINDICADOR_EXIGIBILIDADE_ISS write FINDICADOR_EXIGIBILIDADE_ISS;
    [TColumn('CODIGO_SERVICO', 'Codigo Servico', 160, [ldGrid, ldLookup, ldCombobox], False)]
    property CodigoServico: RawUTF8  read FCODIGO_SERVICO write FCODIGO_SERVICO;
    [TColumn('MUNICIPIO_INCIDENCIA', 'Municipio Incidencia', 80, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property MunicipioIncidencia: Integer  read FMUNICIPIO_INCIDENCIA write FMUNICIPIO_INCIDENCIA;
    [TColumn('PAIS_SEVICO_PRESTADO', 'Pais Sevico Prestado', 80, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property PaisSevicoPrestado: Integer  read FPAIS_SEVICO_PRESTADO write FPAIS_SEVICO_PRESTADO;
    [TColumn('NUMERO_PROCESSO', 'Numero Processo', 240, [ldGrid, ldLookup, ldCombobox], False)]
    property NumeroProcesso: RawUTF8  read FNUMERO_PROCESSO write FNUMERO_PROCESSO;
    [TColumn('INDICADOR_INCENTIVO_FISCAL', 'Indicador Incentivo Fiscal', 80, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property IndicadorIncentivoFiscal: Integer  read FINDICADOR_INCENTIVO_FISCAL write FINDICADOR_INCENTIVO_FISCAL;


  end;

implementation


end.
