I want to integrate PayuMoney payment gateway to my rails application. And I want to redirect to payment gateway URL with post request, so I use HTTparty to redirect and POST request to payumoney URL.
My controller:
class ClientFeePaymentsController < ApplicationController
include HTTParty
def fee_payment
uri = URI('https://test.payu.in/_payment.php')
res = Net::HTTP.post_form(uri, 'key' => 'fddfh', 'salt' => '4364')
puts res.body
end
end
routes:
resources :client_fee_payments do
collection do
get :fee_payment
post :fee_payment
end
end
when i run this i got,
Missing template client_fee_payments/fee_payment, application/fee_payment with {:locale=>[:en], :formats=>[:html], :variants=>[], :handlers=>[:erb, :builder, :raw, :ruby, :coffee, :axlsx, :jbuilder]}.