public async Task <KindActionResult> PostWithoutImage([FromBody] string kindActionDescription)
        {
            var kindAction = new Core.DomainModels.KindAction
            {
                UserId      = this.GetCurrentUserId(),
                Description = kindActionDescription
            };

            if (!kindAction.ValidateObject())
            {
                return(new KindActionResult(OperationResultStatus.Error, "Validation error"));
            }

            var result = await _kindActionService.AddNewKindAction(kindAction);

            if (result.Status == OperationResultStatus.Success)
            {
                await _appCountersService.KindActionSubmited();
            }
            return(result);
        }
        public async Task <KindActionResult> Post()
        {
            var parsedContent = await FileUploadHelper.GetMultipartContent(Request, "KindActionDescription");

            if (parsedContent.ErrorType == MultipartDataError.FileDataEmpty)
            {
                return(new KindActionResult(OperationResultStatus.Error, "Attached file is empty"));
            }
            if (parsedContent.ErrorType == MultipartDataError.TextDataEmpty)
            {
                return(new KindActionResult(OperationResultStatus.Error, "Kind action description is empty"));
            }

            var kindAction = new Core.DomainModels.KindAction
            {
                UserId      = this.GetCurrentUserId(),
                Description = HttpUtility.UrlDecode(parsedContent.TextData)
            };

            if (!kindAction.ValidateObject())
            {
                return(new KindActionResult(OperationResultStatus.Error, "Validation error"));
            }


            var imagePath = await _imageService.SaveKindActionImage(parsedContent.FileData);

            kindAction.ImageUrl = imagePath;

            var result = await _kindActionService.AddNewKindAction(kindAction);

            if (result.Status == OperationResultStatus.Success)
            {
                await _appCountersService.KindActionSubmited();
            }
            return(result);
        }