{*******************************************************************************
Title: T2Ti ERP                                                                 
Description:  DTO  relacionado à tabela [AGENCIA_BANCO] 
                                                                                
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 2.0
*******************************************************************************}
unit AgenciaBancoDTO;

interface

uses

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

  SynCommons,
  mORMot,

  BancoDTO;

type
  [TEntity]
  [TTable('AGENCIA_BANCO')]
  TAGENCIA_BANCO = class(TSQLRecord)
  private
    FPK: Integer;
    FID_BANCO: Integer;
    FCODIGO: RawUTF8;
    FDIGITO: RawUTF8;
    FNOME: RawUTF8;
    FLOGRADOURO: RawUTF8;
    FNUMERO: RawUTF8;
    FCEP: RawUTF8;
    FBAIRRO: RawUTF8;
    FMUNICIPIO: RawUTF8;
    FUF: RawUTF8;
    FTELEFONE: RawUTF8;
    FGERENTE: RawUTF8;
    FCONTATO: RawUTF8;
    FOBSERVACAO: RawUTF8;

    //Transientes
    FBancoNome: RawUTF8;

    FBancoDTO: TBanco;

  public
    property BancoDTO: TBanco read FBancoDTO write FBancoDTO;

  published
    [TPK('ID', [ldGrid, ldLookup, ldComboBox])]
    [TGeneratedValue(sAuto)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property PK: Integer  read FPK write FPK;

    [TColumn('ID_BANCO', 'Id Banco', 80, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftZerosAEsquerda, taCenter)]
    property IdBanco: Integer  read FID_BANCO write FID_BANCO;

    [TColumn('CODIGO', 'Codigo', 80, [ldGrid, ldLookup, ldCombobox], False)]
    property Codigo: RawUTF8  read FCODIGO write FCODIGO;
    [TColumn('DIGITO', 'Digito', 8, [ldGrid, ldLookup, ldCombobox], False)]
    property Digito: RawUTF8  read FDIGITO write FDIGITO;
    [TColumn('NOME', 'Nome', 450, [ldGrid, ldLookup, ldCombobox], False)]
    property Nome: RawUTF8  read FNOME write FNOME;
    [TColumn('LOGRADOURO', 'Logradouro', 450, [ldGrid, ldLookup, ldCombobox], False)]
    property Logradouro: RawUTF8  read FLOGRADOURO write FLOGRADOURO;
    [TColumn('NUMERO', 'Numero', 80, [ldGrid, ldLookup, ldCombobox], False)]
    property Numero: RawUTF8  read FNUMERO write FNUMERO;
    [TColumn('CEP', 'Cep', 64, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftCep, taLeftJustify)]
    property Cep: RawUTF8  read FCEP write FCEP;
    [TColumn('BAIRRO', 'Bairro', 450, [ldGrid, ldLookup, ldCombobox], False)]
    property Bairro: RawUTF8  read FBAIRRO write FBAIRRO;
    [TColumn('MUNICIPIO', 'Municipio', 450, [ldGrid, ldLookup, ldCombobox], False)]
    property Municipio: RawUTF8  read FMUNICIPIO write FMUNICIPIO;
    [TColumn('UF', 'Uf', 16, [ldGrid, ldLookup, ldCombobox], False)]
    property Uf: RawUTF8  read FUF write FUF;
    [TColumn('TELEFONE', 'Telefone', 112, [ldGrid, ldLookup, ldCombobox], False)]
    [TFormatter(ftTelefone, taLeftJustify)]
    property Telefone: RawUTF8  read FTELEFONE write FTELEFONE;
    [TColumn('GERENTE', 'Gerente', 240, [ldGrid, ldLookup, ldCombobox], False)]
    property Gerente: RawUTF8  read FGERENTE write FGERENTE;
    [TColumn('CONTATO', 'Empresa Contato', 240, [ldGrid, ldLookup, ldCombobox], False)]
    property Contato: RawUTF8  read FCONTATO write FCONTATO;
    [TColumn('OBSERVACAO', 'Observacao', 450, [ldGrid, ldLookup, ldCombobox], False)]
    property Observacao: RawUTF8  read FOBSERVACAO write FOBSERVACAO;


  end;

implementation


end.
