Commit 5c0d96b385e710afc384001cfb13b61509ccb5ac
1 parent
ce1c575fe6
Exists in
master
rajorpay comment
Showing
1 changed file
with
65 additions
and
57 deletions
Show diff stats
script.js
... | ... | @@ -733,6 +733,12 @@ |
733 | 733 | headers: {} |
734 | 734 | }).then(function mySuccess(result) { |
735 | 735 | console.log("rslt",result) |
736 | + result.data = $sce.trustAsHtml(result.data); | |
737 | + console.log(result.data) | |
738 | + // { | |
739 | + // results[i].content = $sce.trustAsHtml(response.data.data[i].content); | |
740 | + // } | |
741 | + //$scope.languages = results; | |
736 | 742 | }); |
737 | 743 | } |
738 | 744 | |
... | ... | @@ -811,70 +817,72 @@ |
811 | 817 | data: data, |
812 | 818 | headers: {} |
813 | 819 | }).then(function mySuccess(paymentResult) { |
814 | - $scope.paymentResult = paymentResult; | |
820 | + $scope.paymentResult = paymentResult; | |
821 | + $location.path("/confirmation") | |
815 | 822 | }, function myError(error) { |
816 | 823 | }); |
817 | 824 | } |
818 | - var i = 0; | |
819 | - $scope.payingAmnt = $scope.payingAmnt * 100; | |
820 | - var options = { | |
821 | - //"key": "rzp_test_YwHsVFiDIQ2WUQ", | |
822 | - "key": "rzp_live_mkmCb4FkstuWaS", | |
823 | - "amount": $scope.payingAmnt, | |
824 | - | |
825 | - "name": "Startup Jalsa", | |
826 | - "description":"amount", | |
827 | - "currency": "INR", | |
828 | - "status": "done", | |
829 | - | |
830 | - "prefill": { | |
831 | - "email": $scope.detail.email, | |
832 | - "contact": $scope.detail.phone | |
833 | - }, | |
834 | - | |
835 | - "theme": { | |
836 | - "color": "#2196f3 ", | |
837 | - "image_padding":"NO" | |
838 | - }, | |
839 | - "modal": { | |
840 | - "ondismiss": function(){ | |
841 | - } | |
842 | - }, | |
843 | - "handler": function (response){ | |
844 | - createPayment(response); | |
845 | - } | |
846 | - }; | |
847 | - var rzp1 = new Razorpay(options); | |
848 | - rzp1.open(); | |
849 | - $scope.paymentResponse = {}; | |
850 | - function createPayment(response){ | |
851 | - console.log("response12333333",response) | |
852 | - $scope.paymentResponse.razorPaymentId = response.razorpay_payment_id; | |
853 | - $scope.paymentResponse.razorOrderId = $scope.paymentResult.data.razorOrderId; | |
854 | - $scope.paymentResponse.amount = data.amount; | |
855 | - $scope.paymentResponse.currency = "INR"; | |
856 | - $scope.paymentResponse.status = $scope.paymentResult.data.status; | |
857 | - console.log("$scope.paymentResponse.amount=====",$scope.paymentResponse.amount) | |
858 | - $http({ | |
859 | - method: 'PUT', | |
860 | - url: BASE_URL+'/payments/'+$scope.paymentResult.data.id, | |
861 | - data: $scope.paymentResponse, | |
862 | - headers: {} | |
863 | - }).then(function mySuccess(searchResult) { | |
864 | - console.log("searchResult",searchResult) | |
865 | - $location.path("/confirmation") | |
866 | - }, function myError(error) { | |
867 | - }); | |
868 | - } | |
869 | - //} | |
870 | - | |
871 | - }, function myError(error) { | |
872 | - | |
873 | - }); | |
825 | + // var i = 0; | |
826 | + // $scope.payingAmnt = $scope.payingAmnt * 100; | |
827 | + // var options = { | |
828 | + // //"key": "rzp_test_YwHsVFiDIQ2WUQ", | |
829 | + // "key": "rzp_live_mkmCb4FkstuWaS", | |
830 | + // "amount": $scope.payingAmnt, | |
831 | + | |
832 | + // "name": "Startup Jalsa", | |
833 | + // "description":"amount", | |
834 | + // "currency": "INR", | |
835 | + // "status": "done", | |
836 | + | |
837 | + // "prefill": { | |
838 | + // "email": $scope.detail.email, | |
839 | + // "contact": $scope.detail.phone | |
840 | + // }, | |
841 | + | |
842 | + // "theme": { | |
843 | + // "color": "#2196f3 ", | |
844 | + // "image_padding":"NO" | |
845 | + // }, | |
846 | + // "modal": { | |
847 | + // "ondismiss": function(){ | |
848 | + // } | |
849 | + // }, | |
850 | + // "handler": function (response){ | |
851 | + // createPayment(response); | |
852 | + // } | |
853 | + // }; | |
854 | + // var rzp1 = new Razorpay(options); | |
855 | + // rzp1.open(); | |
856 | + // $scope.paymentResponse = {}; | |
857 | + // function createPayment(response){ | |
858 | + // console.log("response12333333",response) | |
859 | + // $scope.paymentResponse.razorPaymentId = response.razorpay_payment_id; | |
860 | + // $scope.paymentResponse.razorOrderId = $scope.paymentResult.data.razorOrderId; | |
861 | + // $scope.paymentResponse.amount = data.amount; | |
862 | + // $scope.paymentResponse.currency = "INR"; | |
863 | + // $scope.paymentResponse.status = $scope.paymentResult.data.status; | |
864 | + // console.log("$scope.paymentResponse.amount=====",$scope.paymentResponse.amount) | |
865 | + // $http({ | |
866 | + // method: 'PUT', | |
867 | + // url: BASE_URL+'/payments/'+$scope.paymentResult.data.id, | |
868 | + // data: $scope.paymentResponse, | |
869 | + // headers: {} | |
870 | + // }).then(function mySuccess(searchResult) { | |
871 | + // console.log("searchResult",searchResult) | |
872 | + // $location.path("/confirmation") | |
873 | + // }, function myError(error) { | |
874 | + // }); | |
875 | + // } | |
876 | + // //} | |
877 | + | |
878 | + // }, function myError(error) { | |
879 | + | |
880 | + // }); | |
874 | 881 | |
875 | 882 | // }) |
876 | 883 | |
877 | 884 | //} |
885 | + }) | |
878 | 886 | |
879 | 887 | } |
880 | 888 | ... | ... |