This should be a pretty quick angular tweak in the salesoverview.html and salesoverview.controller.js files. Basically you just need to show the fulfull button a bit earlier:
One thing you will probably also want to do is set the AlwaysApproveOrderCreation to true so that on each sale an order is generated even if the payment has not been created.
I change the views and controllers. Now the FullFill Button is working. But I got an undefined in the openFulfillShipmentDialog
TypeError: Cannot read property 'getUnShippedItems' of undefined
this line return undefined:
data.order = $scope.invoice.orders[0];
so the
data.order.getUnShippedItems()
crash.
The order creation would only fire if there are shippable items - so that may explain that.
I think your close - but I'd have to step through with the JS debugger to figure out exactly what is going on at this point. It would probably work to simply test if the orders array length is > 0 before hitting that line (or whatever for your circumstance). I can't think of anything database wise that would be impacted.
Hi, I restart this process. To be able to fulfill I need to have an order created because Invoice.Orders[0] cannot be null. For now, the only way for creating order (either if I set the AlwaysApproveOrderCreation=true) is to capture a payment. For example, 0.01$ then in the capture payment process something create the order. Then I can refund, make another payment, the order is always there and I can fulfill the order without complete payment.
I try to trace the capture payment process to see where/How the order is created and see if I can call this function manually in the loading process of the saleorder. But I can't find it.
If you don't want to authorize before considering something a "successful" order, you could replace the payment view with a confirm order view and simply use the CheckoutManager.PrepareInvoice(); and saved it.
Then in the back office you should be able to add a new payment to the invoice - assuming the payment provider has the feature. Example, PayPal redirect is not something that can be done via a back office payment.
Capturing funds after delivery.
It is possible to change the step the Merchello order go though? My client delivery in person (maple syrup farm) and collect the payment at the end
Normally the steps are:
What is the complexity of changing that in merchello?
In the same idea, where I can find some documentation on how to add a field in the checkout process and save it with the order?
This should be a pretty quick angular tweak in the
salesoverview.html
andsalesoverview.controller.js
files. Basically you just need to show the fulfull button a bit earlier:SalesOverview.html
https://github.com/Merchello/Merchello/blob/merchello-dev/src/Merchello.Web.UI.Client/src/views/sales/saleoverview.html#L40
SalesOverview.controller.js
https://github.com/Merchello/Merchello/blob/merchello-dev/src/Merchello.Web.UI.Client/src/views/sales/saleoverview.controller.js#L149
One thing you will probably also want to do is set the
AlwaysApproveOrderCreation
totrue
so that on each sale an order is generated even if the payment has not been created.https://github.com/Merchello/Merchello/blob/merchello-dev/src/Merchello.FastTrack.Ui/App_Plugins/Merchello/config/merchello.config#L10
Thanks for replying.
I change the views and controllers. Now the FullFill Button is working. But I got an undefined in the openFulfillShipmentDialog
TypeError: Cannot read property 'getUnShippedItems' of undefined this line return undefined: data.order = $scope.invoice.orders[0]; so the data.order.getUnShippedItems() crash.
I add the
Do you think I got something else to do? I think the setting not worked and Merchello do not create the order. If I paid, everything is working well.
The order creation would only fire if there are shippable items - so that may explain that.
I think your close - but I'd have to step through with the JS debugger to figure out exactly what is going on at this point. It would probably work to simply test if the orders array length is > 0 before hitting that line (or whatever for your circumstance). I can't think of anything database wise that would be impacted.
Hi, I restart this process. To be able to fulfill I need to have an order created because Invoice.Orders[0] cannot be null. For now, the only way for creating order (either if I set the AlwaysApproveOrderCreation=true) is to capture a payment. For example, 0.01$ then in the capture payment process something create the order. Then I can refund, make another payment, the order is always there and I can fulfill the order without complete payment.
I try to trace the capture payment process to see where/How the order is created and see if I can call this function manually in the loading process of the saleorder. But I can't find it.
Any idea?
The order is created via a builder: https://github.com/Merchello/Merchello/blob/merchello-dev/src/Merchello.Core/Models/InvoiceExtensions.cs#L404
Which is triggered in an event handler: https://github.com/Merchello/Merchello/blob/merchello-dev/src/Merchello.Core/Gateways/GatewayEvents.cs#L85
The events are emitted from the PaymentGatewayMethodBase class
Hi, But Can you only authorize and then capture after?
If you don't want to authorize before considering something a "successful" order, you could replace the payment view with a confirm order view and simply use the
CheckoutManager.PrepareInvoice();
and saved it.Then in the back office you should be able to add a new payment to the invoice - assuming the payment provider has the feature. Example, PayPal redirect is not something that can be done via a back office payment.
is working on a reply...