Esempio n. 1
0
        private YachtTourFileStreams GenerateForUpdate(YachtTourFileStreams entity)
        {
            var now    = DateTime.Now.Date;
            var userId = UserContextHelper.UserId;

            entity.LastModifiedBy   = userId;
            entity.LastModifiedDate = now;
            return(entity);
        }
Esempio n. 2
0
        private YachtTourFileStreams GenerateEntityForCreate(YachtTourFileStreamCreateModel model, int tourId)
        {
            var userId = UserContextHelper.UserId;
            var entity = new YachtTourFileStreams();

            entity = _mapper.Map <YachtTourFileStreamCreateModel, YachtTourFileStreams>(model, entity);

            entity.YachtTourFid     = tourId;
            entity.LastModifiedBy   = userId;
            entity.LastModifiedDate = DateTime.Now.Date;
            return(entity);
        }