示例#1
0
        protected void SetTemplate(EmailTypeEnum type)
        {
            var body = _repository.GetOne <EmailTemplate>(x => x.Language.Equals(Language) && x.EmailType.Equals(type));

            Subject    = body.Subject;
            FromAdress = new MailboxAddress(
                "Building-admin.com",
                body.Address
                );
            Template = body.Template;
        }
 public Service GetById(Guid id)
 {
     return(_repository.GetOne <Service>(x => x.Id.Equals(id)));
 }
示例#3
0
 public Apartment GetById(Guid id)
 {
     return(_repository.GetOne <Apartment>(x => x.Id.Equals(id)));
 }
 public Building GetByOwnerAndApartmentId(string owner, Guid apartamentId)
 {
     return(_repository.GetOne <Building>(x => x.Owner.Equals(owner) && x.Apartments.Contains(apartamentId) && x.IsActive));
 }
示例#5
0
 public Bill GetCurrentByBuilding(Building building)
 {
     return(_repository.GetOne <Bill>(b => b.End == null && building.Bills.Contains(b.Id)));
 }