public async Task ExtendJobOrderAsync(ExtendJobOrderModel model) { var command = new ExtendJobOrderCommand( model.UserId, model.JobOrderId, model.NewDueDate, model.Price ); await Bus.Send(command); }
public async Task <IActionResult> Extend([FromBody] ExtendJobOrderModel model) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } await WorkerServices.ExtendJobOrderAsync(model); return(Ok()); }