Copied to clipboard

Flag this post as spam?

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


  • MOthman 27 posts 89 karma points
    Jan 17, 2018 @ 16:08
    MOthman
    0

    worldpay paymentform.cshtml partial view not showing

    I'm almost done with creating WorldPay payment provider plugin for an ecommerce site I'm working on. However, I ran into an issue (I'm sure it is simple) that I struggle now to solve.

    I have WorldPay plugin project which has all necessary classes (i.e. provider, methods, controller, etc.). And I created a PaymentForm.cshtml file to capture worldpay customer details.

    In WorldPayCheckoutPaymentGatewayMethod I added the attribute[GatewayMethodUi("WorldPay.WorldPay")] to the class, and the same for WorldPayPaymentController and for WorldPayPaymentController.PaymentForm method too.

    The controller got the attribute [PluginController("MerchelloWorldPay")] and in FastTrackUi I created the area MerchelloWorldPay. Under MerchelloWorldPay I have the necessary js files as well as dialogs folder and WorldPayment folder with PaymentForm.cshtml file.

    I could add worldpay as a payment gateway with no issues, display it under payment methods option during the checkout process, but not able to show PaymentForm.

    Note WorldPayPaymentController inherits from CheckoutPaymentControllerBase

    and WorldPayCheckoutPaymentGatewayMethod inherits from RedirectPaymentMethodBase

    Any advise?

  • MOthman 27 posts 89 karma points
    Jan 23, 2018 @ 16:02
    MOthman
    1

    Sorted. It maybe is obvious but it took me few days to figure it out. If you are building such plugin like me, in Merchello FastTrack.Ui project there is ResolvePayment.cshtml file which checks Alias property of GatewayMethodUiAttribute model in a switch statement - You will need to add your GatewayMethodUi alias there and link html.Action to your paymentform. Time for testing my worldpay plugin :)

Please Sign in or register to post replies

Write your reply to:

Draft