示例#1
0
        public ClienteBE SelectId(int id)
        {
            var obj = new ClienteDao().SelectId <ClienteBE>(new { cli_id = id });
            ClienteEnderecoBLL _bll = new ClienteEnderecoBLL();
            ClienteContatoBLL  _con = new ClienteContatoBLL();

            obj.Endereco = _bll.Select(new GlobaisClienteEnderecoBE {
                cli_id = obj.cli_id
            });
            obj.Contato = _con.Select(new GlobaisClienteContatoBE {
                cli_id = obj.cli_id
            });
            return(obj);
        }
示例#2
0
        List <ClienteNotasContratoBE> CarregaEnderecosCliente(List <ClienteNotasContratoBE> obj)
        {
            ClienteEnderecoBLL _bll = new ClienteEnderecoBLL();
            ClienteContatoBLL  _con = new ClienteContatoBLL();

            foreach (var item in obj)
            {
                item.Endereco = _bll.Select(new GlobaisClienteEnderecoBE {
                    cli_id = item.cli_id
                });
                item.Contato = _con.Select(new GlobaisClienteContatoBE {
                    cli_id = item.cli_id
                });
            }
            return(obj);
        }
示例#3
0
        public ClienteBE SelectIdComServico(int id)
        {
            var obj = new ClienteDao().SelectId <ClienteBE>(new { cli_id = id });
            ClienteEnderecoBLL _bll = new ClienteEnderecoBLL();
            ClienteContatoBLL  _con = new ClienteContatoBLL();

            obj.Endereco = _bll.Select(new GlobaisClienteEnderecoBE {
                cli_id = obj.cli_id
            });
            obj.Contato = _con.Select(new GlobaisClienteContatoBE {
                cli_id = obj.cli_id
            });

            obj.Servicos = new ClienteServicosBLL().Select(new ClienteServicosBE {
                cli_id = obj.cli_id, log_ativo = true
            });
            return(obj);
        }