Customer id fix
This commit is contained in:
@@ -84,9 +84,10 @@ class EligibilityCheckService(BaseService):
|
|||||||
# eligible_offers = []
|
# eligible_offers = []
|
||||||
try:
|
try:
|
||||||
eligible_offers = OfferAnalysis.decide_offer(
|
eligible_offers = OfferAnalysis.decide_offer(
|
||||||
transaction_id=transaction_id,
|
transaction_id=transactionId,
|
||||||
rac_check=rac_check,
|
rac_check=rac_check,
|
||||||
validated_data=validated_data
|
validated_data=validated_data,
|
||||||
|
customer=customer
|
||||||
)
|
)
|
||||||
except ValueError as ve:
|
except ValueError as ve:
|
||||||
logger.error(str(ve))
|
logger.error(str(ve))
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
from app.models import Offer, TransactionOffer
|
from app.models import Offer, TransactionOffer
|
||||||
from app.models.loan import Loan
|
from app.models.loan import Loan
|
||||||
|
import random
|
||||||
import logging
|
import logging
|
||||||
logger = logging.getLogger(__name__)
|
logger = logging.getLogger(__name__)
|
||||||
|
|
||||||
@@ -37,11 +37,15 @@ class OfferAnalysis:
|
|||||||
return transaction_offer, offer, eligible_amount, original_transaction
|
return transaction_offer, offer, eligible_amount, original_transaction
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def decide_offer(transaction_id, rac_check, validated_data):
|
def decide_offer(transaction_id, rac_check, validated_data,customer):
|
||||||
# if we have active offers - we have to feed off it
|
# if we have active offers - we have to feed off it
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Do this if no active loan or registered offers
|
# Do this if no active loan or registered offers
|
||||||
offers = Offer.get_all_offers()
|
offers = Offer.get_all_offers()
|
||||||
eligible_offers = []
|
eligible_offers = []
|
||||||
|
|||||||
Reference in New Issue
Block a user