示例#1
0
 public void AddLogo(LogoDto logoDto)
 {
     if (logoDto == null)
     {
         throw new Exception("LogoDto is null");
     }
     Logos.Add(logoDto);
 }
        public IResult UpdateLogo(LogoDto logoDto)
        {
            var generalInformation = _generalInformationDal.GetAll().SingleOrDefault();

            var generalInformationNew = Mapper.Map <LogoDto, GeneralInformation>(logoDto, generalInformation);

            _generalInformationDal.Update(generalInformationNew);

            return(new SuccessResult());
        }
示例#3
0
 public async Task UpsertLogo(LogoDto input)
 {
     try
     {
         var obj = input.MapTo <Logo>();
         if (input.Id == 0)
         {
             obj.IsDeleted    = false;
             obj.CreatedBy    = AbpSession.UserId;
             obj.DateCreated  = DateTime.Now;
             obj.DateModified = null;
         }
         else
         {
             obj.ModifiedBy   = AbpSession.UserId;
             obj.DateModified = DateTime.Now;
         }
         await _logoRepository.InsertOrUpdateAsync(obj);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
 public IResult InsertOrUpdate(LogoDto logoDto)
 {
     throw new NotImplementedException();
 }
示例#5
0
 public LogoViewModel(LogoDto output)
 {
     output.MapTo(this);
 }