• Toll-free  888-665-8637
  • International  +1 717-220-0012
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

[email protected]
#1 Posted : Monday, July 25, 2011 4:57:18 PM(UTC)
michael@smartz.com

Rank: Member

Joined: 6/9/2011(UTC)
Posts: 12

I've built a custom workflow that integrates with an order fulfillment company's API, which is responsible for shipping the order. When an order is placed it automatically creates an order using the API. A timer built into Global.asax periodically queries the API to check if any orders have been shipped. We would like to capture funds AFTER the order has shipped instead of when the order is placed. Is there a way to do this from within the workflow task? We are currently using Authorize.Net as the payment processor. BV version 5.

On a possibly related note: When I automatically update an order from within the custom workflow and set its status to "Shipped", the icon in the Order Manager gets updated. However, if I go into the order I always see something along the lines of "In Process / Paid / Unshipped". I've also tried updating each package / item in the order by setting them to shipped. This doesn't seem to fix the issue. The only way I can get the View Order page to correctly display that the order has shipped is by manually setting it to shipped in the Order Shipping page.
Aaron
#2 Posted : Tuesday, July 26, 2011 9:38:12 AM(UTC)
Aaron

Rank: Administration

Joined: 4/2/2004(UTC)
Posts: 2,393
United States
Location: Hummelstown, PA

Thanks: 6 times
Was thanked: 163 time(s) in 158 post(s)
Mike,

Yes, you should be able to capture the funds from a workflow.

Regarding the order status issue, I've seen this before and believe it is a bug. I don't recall how we resolved it, though. It looks like your options are to either submit this to BV as a bug or dig into the code and fix it.
Aaron Sherrick
BV Commerce
Toll-free 888-665-8637 - Int'l +1 717-220-0012
Steve95
#3 Posted : Tuesday, July 26, 2011 11:20:55 AM(UTC)
Steve95

Rank: Member

Joined: 4/29/2010(UTC)
Posts: 256

Thanks: 4 times
Was thanked: 11 time(s) in 10 post(s)
As Aaron as said you just need to move the workflow around a little bit and you should be able to achive your goal.


"On a possibly related note: When I automatically update an order from within the custom workflow and set its status to "Shipped", the icon in the Order Manager gets updated. However, if I go into the order I always see something along the lines of "In Process / Paid / Unshipped". I've also tried updating each package / item in the order by setting them to shipped. This doesn't seem to fix the issue. The only way I can get the View Order page to correctly display that the order has shipped is by manually setting it to shipped in the Order Shipping page."

I had the same problem. From memory if you check the shipping page of the order and then go back it updates?
[email protected]
#4 Posted : Tuesday, July 26, 2011 11:38:21 AM(UTC)
michael@smartz.com

Rank: Member

Joined: 6/9/2011(UTC)
Posts: 12

Aaron: Do you happen to know how to capture the funds? I would have assumed it would be somewhere in orderObject.Payments.<Call To Capture Funds>() . It would be preferable if I could also capture funds outside of the workflow (so that the timer can just call up some code).

Steve: The weird thing about this bug is that the Order Manager says shipped, the View Order page says UNshipped, but if I go into View Order and update something on the page (for example, change "In Process" to "Payment Pending" and then back to "In Process") the Order Manager will update to UNshipped.

Thank you both for all of your help!
Aaron
#5 Posted : Wednesday, July 27, 2011 7:58:37 AM(UTC)
Aaron

Rank: Administration

Joined: 4/2/2004(UTC)
Posts: 2,393
United States
Location: Hummelstown, PA

Thanks: 6 times
Was thanked: 163 time(s) in 158 post(s)
Originally Posted by: "MikeSmartz" Go to Quoted Post
Aaron: Do you happen to know how to capture the funds? I would have assumed it would be somewhere in orderObject.Payments.<Call To Capture Funds>() . It would be preferable if I could also capture funds outside of the workflow (so that the timer can just call up some code).


Not without digging into the code. You should be able to see how BV is doing normally and then just put that code into your workflow (or wherever else you need it).
Aaron Sherrick
BV Commerce
Toll-free 888-665-8637 - Int'l +1 717-220-0012
[email protected]
#6 Posted : Wednesday, July 27, 2011 6:02:21 PM(UTC)
michael@smartz.com

Rank: Member

Joined: 6/9/2011(UTC)
Posts: 12

I was able to find the code for this and get it working for my own purposes. The code was located in BVAdmin/Orders/Default.aspx.vb: CaptureOrder()

I'm still unable to get the Order View page to display the product as Shipped. After searching through the code it looks like it could be something along the lines of

Code:

Dim context As New BusinessRules.OrderTaskContext
context.Order = orderToUpdate
context.UserId = orderToUpdate.UserID
context.Inputs.Add("bvsoftware", "PreviousShippingStatus", previousShippingStatus.ToString())
BusinessRules.Workflow.RunByBvin(context, WebAppSettings.WorkflowIdShippingChanged)


but this didn't seem to work either.
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

©2024 Develisys. All rights reserved.
  • Toll-free  888-665-8637
  • International  +1 717-220-0012