diff --git a/Deployment/24417-Referral_Points/FNA_GET_REWARD_POINTS.sql b/Deployment/24417-Referral_Points/FNA_GET_REWARD_POINTS.sql new file mode 100644 index 0000000..13b6a8f --- /dev/null +++ b/Deployment/24417-Referral_Points/FNA_GET_REWARD_POINTS.sql @@ -0,0 +1,18 @@ +SET ANSI_NULLS ON +GO +SET QUOTED_IDENTIFIER ON +GO + +CREATE FUNCTION [dbo].[FNA_GET_REWARD_POINTS]() +RETURNS @list TABLE (totalPoints INT, RegPoint INT, TranPoint INT) +AS +BEGIN + INSERT INTO @list (totalPoints, RegPoint, TranPoint) + SELECT + SUM(CASE WHEN PromotionType IN ('REGISTRATION', 'TRANSACTION') THEN Points ELSE 0 END) AS totalPoints, + SUM(CASE WHEN PromotionType = 'REGISTRATION' THEN Points ELSE 0 END) AS RegPoint, + SUM(CASE WHEN PromotionType = 'TRANSACTION' THEN Points ELSE 0 END) AS TranPoint + FROM TBL_PROMOTION_SETUP; + + RETURN; +END diff --git a/Deployment/24417-Referral_Points/mobile_proc_customerMaster.sql b/Deployment/24417-Referral_Points/mobile_proc_customerMaster.sql new file mode 100644 index 0000000..94fa695 Binary files /dev/null and b/Deployment/24417-Referral_Points/mobile_proc_customerMaster.sql differ diff --git a/Deployment/24417-Referral_Points/proc_InsertRewardPoints.sql b/Deployment/24417-Referral_Points/proc_InsertRewardPoints.sql new file mode 100644 index 0000000..c1c7460 Binary files /dev/null and b/Deployment/24417-Referral_Points/proc_InsertRewardPoints.sql differ diff --git a/Deployment/24417-Referral_Points/proc_online_remitance_core_customerSetup.sql b/Deployment/24417-Referral_Points/proc_online_remitance_core_customerSetup.sql new file mode 100644 index 0000000..6bbc1af Binary files /dev/null and b/Deployment/24417-Referral_Points/proc_online_remitance_core_customerSetup.sql differ