Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • James Brett 4 posts 73 karma points
    Feb 14, 2023 @ 08:27
    James Brett
    0

    Add initialized to payment status

    Vendr v1.8.6

    Hi

    When downloading the order you see order that are initialized which I'm assuming is orders where the user has gone to the payment provider but not completed the payment.

    enter image description here

    Can this payment status be added to the list so admins do not have to download the file.

    enter image description here

    Cheers James

  • Matt Brailsford 4125 posts 22223 karma points MVP 9x c-trib
    Feb 14, 2023 @ 09:06
    Matt Brailsford
    0

    Hi James,

    Initialized wouldn't be added to this list as an initialized order is not yet concidered finalized/closed and so wouldn't appear in the orders section yet.

    Initialized orders would be visible in the cart section until they are finalized.

    We could maybe add something to the carts status dropdown instead. I'll have to review what would be useful to have.

  • James Brett 4 posts 73 karma points
    Mar 07, 2023 @ 10:16
    James Brett
    0

    Hi Matt

    Thanks for taking a look at this, have you managed to come up with a solution?

    Cheers James

  • Matt Brailsford 4125 posts 22223 karma points MVP 9x c-trib
    Mar 07, 2023 @ 13:33
    Matt Brailsford
    0

    Hi James,

    Sorry, I've not been able to look into this just yet.

    As an interim, one thing you could do is actually to define your own advanced filter that appears behind the filter icon next to the search box on the list view.

    You could define a filter for something like "Begun Processing" that is defined something like this

    [AdvancedFilter("hasBegunProcessing", "Has Begun Processing", "Search for orders that have begun payment processing", Group = "Customer", EditorView = "boolean")]
    public class OrderHasBegunProcessingAdvancedFilter : OrderAdvancedFilterBase
    {
        public override bool CanApply(string value)
        {
            return !string.IsNullOrWhiteSpace(value) && value.InvariantEquals("true");
        }
    
        public override IQuerySpecification<OrderReadOnly> Apply(IQuerySpecification<OrderReadOnly> query, IOrderQuerySpecificationFactory @where, string value)
        {
            return query.And(where.HasPaymentStatus(PaymentStatus.Initialized));
        }
    }
    

    You can then register this within your startup script

    vendrBuilder.WithCartAdvancedFilters()
      .Add<OrderHasBegunProcessingAdvancedFilter>()
    

    With this in place you could at least perform an advanced search in the carts section that would provide a list of carts that have been initialized.

  • James Brett 4 posts 73 karma points
    Mar 16, 2023 @ 08:34
    James Brett
    0

    Hi Matt

    Many thanks for providing the code but we're using Umbraco 8 and Vendr 1.8.6 and the code supplied seems more like v10. Is there a solution for the setup we're using?

    Cheers James

  • Matt Brailsford 4125 posts 22223 karma points MVP 9x c-trib
    Mar 16, 2023 @ 08:49
    Matt Brailsford
    0

    Ahh sorry, unfortunately not. The advanced filter feature was added in 2.1.0 so you'd need to upgrade to at least that version.

Please Sign in or register to post replies

Write your reply to:

Draft