use membership actions for PAYMAL create payment

This commit is contained in:
Thein Lin Kyaw
2020-05-29 21:42:27 +06:30
parent 3d7ae0433b
commit 72734c8bff
2 changed files with 3 additions and 5 deletions

View File

@@ -293,9 +293,8 @@ class SalePayment < ApplicationRecord
end
def self.create_payment(paypar_url,payment_type,membership_id,received_amount,sale_id)
# membership_actions_data = MembershipAction.find_by_membership_type("create_payment");
membership_actions_data = MembershipAction.find_by_membership_type("create_payment")
sale_data = Sale.find_by_sale_id(sale_id)
membership_actions_data = PaymentMethodSetting.find_by_payment_method(payment_type)
customer_data = Customer.find_by_customer_id(sale_data.customer_id)
if !membership_actions_data.nil?