예제 #1
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <Sex> request, CancellationToken cancellationToken)
        {
            var sexToDelete = await _context.Sexs.FindAsync(request.Id);

            sexToDelete.IsDelete = true;
            _context.Update(sexToDelete);
            await _context.SaveChangesAsync();

            return(Unit.Value);
        }
예제 #2
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <ReferenceType> request, CancellationToken cancellationToken)
        {
            var referenceType = await _context.ReferenceTypes.FindAsync(request.Id);

            referenceType.IsDelete = true;

            _context.Update(referenceType);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
예제 #3
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <Language> request, CancellationToken cancellationToken)
        {
            var language = await _context.Languages.FindAsync(request.Id);

            language.IsDelete = true;

            _context.Update(language);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
        public async Task <Unit> Handle(DeleteProfilOptionCommand <LegalCustody> request, CancellationToken cancellationToken)
        {
            var legalCustodies = await _context.LegalCustodies.FindAsync(request.Id);

            legalCustodies.IsDelete = true;

            _context.Update(legalCustodies);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
예제 #5
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <HeardOfUsFrom> request, CancellationToken cancellationToken)
        {
            var heardOfUs = await _context.HeardOfUsFroms.FindAsync(request.Id);

            heardOfUs.IsDelete = true;

            _context.Update(heardOfUs);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
예제 #6
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <Schooling> request, CancellationToken cancellationToken)
        {
            var schooling = await _context.Schoolings.FindAsync(request.Id);

            schooling.IsDelete = true;

            _context.Update(schooling);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
예제 #7
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <SocialService> request, CancellationToken cancellationToken)
        {
            var socialService = await _context.SocialServices.FindAsync(request.Id);

            socialService.IsDelete = true;

            _context.Update(socialService);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
        public async Task <Unit> Handle(DeleteProfilOptionCommand <CitizenStatus> request, CancellationToken cancellationToken)
        {
            var citizenStatus = await _context.Set <CitizenStatus>().FindAsync(request.Id);

            citizenStatus.IsDelete = true;

            _context.Update(citizenStatus);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
예제 #9
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <Parent> request, CancellationToken cancellationToken)
        {
            var parent = await _context.Parents.FindAsync(request.Id);

            parent.IsDelete = true;

            _context.Update(parent);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
        public async Task <Unit> Handle(DeleteProfilOptionCommand <MaritalStatus> request, CancellationToken cancellationToken)
        {
            var maritalStatus = await _context.MaritalStatuses.FindAsync(request.Id);

            maritalStatus.IsDelete = true;

            _context.Update(maritalStatus);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
예제 #11
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <VolunteeringType> request, CancellationToken cancellationToken)
        {
            var volonteeringType = await _context.VolunteeringTypes.FindAsync(request.Id);

            volonteeringType.IsDelete = true;

            _context.Update(volonteeringType);
            await _context.SaveChangesAsync();

            return(Unit.Value);
        }
예제 #12
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <SkillToDevelop> request, CancellationToken cancellationToken)
        {
            var skill = await _context.SkillToDevelops.FindAsync(request.Id);

            skill.IsDelete = true;

            _context.Update(skill);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
예제 #13
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <YearlyIncome> request, CancellationToken cancellationToken)
        {
            var yearlyIncome = await _context.FindAsync <YearlyIncome>(request.Id);

            yearlyIncome.IsDelete = true;

            _context.Update(yearlyIncome);
            await _context.SaveChangesAsync(cancellationToken);

            return(Unit.Value);
        }
예제 #14
0
        public async Task <Unit> Handle(DeleteProfilOptionCommand <ChildrenAgeBracket> request, CancellationToken cancellationToken)
        {
            await request.Handle(_context, cancellationToken);

            return(Unit.Value);
        }
        public async Task <Unit> Handle(DeleteProfilOptionCommand <Availability> request, CancellationToken cancellationToken)
        {
            await request.Handle(_context, cancellationToken);

            return(Unit.Value);
        }