/// <summary>
        /// Execute the default clear order action
        /// </summary>
        /// <param name="order">
        /// The <see cref="Order"/> entity
        /// </param>
        /// <param name="delete">
        /// Whether the order should be deleted
        /// </param>
        /// <returns>
        /// Asynchronous <see cref="Task"/> operation of the action
        /// </returns>
        public async Task ExecuteAsync(Order order, bool delete)
        {
            var itemIds = (await itemStore.FindByOrderIdAsync(order.Id)).Select(i => i.Id).ToList();

            foreach (var id in itemIds)
            {
                await itemStore.DeleteAsync(id);
            }

            if (delete)
            {
                await orderStore.DeleteAsync(order.Id);
            }
        }
 public async Task <IActionResult> Delete(string id)
 {
     return(Ok(await orderStore.DeleteAsync(id)));
 }