Esempio n. 1
0
    public void Write(string content)
    {
        IUndoableCommand command = new AddContentCommand(this.document, content);

        this.undoStack.Push(command);
        this.redoStack.Clear();

        command.Execute();
    }
Esempio n. 2
0
        public async Task <ActionResult <MediaContentDto> > Post(AddContentCommand command)
        {
            var result = await _mediator.Send(command);

            if (result == null)
            {
                return(BadRequest());
            }

            return(Ok());
        }
Esempio n. 3
0
 protected internal ProjectViewModel()
 {
     AddContent = new AddContentCommand(this);
 }
        public async Task <IActionResult> Post([FromBody] AddContentCommand command)
        {
            var result = await _mediator.Send(command);

            return(Ok(result));
        }