public async Task <ActionResult <bool> > CreatePassword([FromBody] SetPasswordViewModel model)
        {
            if (!ModelState.IsValid)
            {
                NotifyModelStateErrors();
                return(ModelStateErrorResponseError());
            }

            model.Id = _systemUser.UserId;
            await _userAppService.CreatePassword(model);

            return(Ok());
        }
Exemplo n.º 2
0
        public async Task <ActionResult <DefaultResponse <bool> > > CreatePassword([FromBody] SetPasswordViewModel model)
        {
            if (!ModelState.IsValid)
            {
                NotifyModelStateErrors();
                return(Response(false));
            }

            model.Id = GetUserId();
            await _userAppService.CreatePassword(model);

            return(Response(true));
        }