Changeset 2627751
- Timestamp:
- 11/10/2021 10:08:07 PM (4 years ago)
- Location:
- rimplenet/trunk/includes
- Files:
-
- 3 edited
-
class-wallets.php (modified) (1 diff)
-
class-withdrawals.php (modified) (2 diffs)
-
layouts/rimplenet-withdrawal-form.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
rimplenet/trunk/includes/class-wallets.php
r2609583 r2627751 936 936 } 937 937 938 939 //NEW METHOD for checking Txn Exist 940 function rimplenet_txn_exists($user_id,$txn_id){ 941 global $wpdb; 942 943 $txn_request_id = $user_id."_".$txn_id; 944 $row_result = $wpdb->get_row("SELECT * FROM $wpdb->postmeta WHERE meta_key='txn_request_id' AND meta_value='$txn_request_id'" ); 945 if(!empty($row_result)){//it means txn has already exist 946 947 $funds_id = $row_result->post_id; 948 $status = "transaction_already_executed"; 949 $response_message = "Transaction Already Executed"; 950 $data = array("txn_id"=>$funds_id); 951 } 952 else{ 953 954 $funds_id = $row_result->post_id; 955 $status = "transaction_does_not_exist"; 956 $response_message = "Transaction does not exist"; 957 $data = array("info"=>"transaction_does_not_exist"); 958 } 959 960 961 if(!empty($status)){ 962 $result = array("status"=>$status, 963 "message"=>$response_message, 964 "data"=>$data); 965 }else{ 966 $result = array("status"=>"unknown_error", 967 "message"=>"Unknown Error", 968 "data"=>array( 969 "error"=>"unknown_error" 970 ) 971 ); 972 } 973 974 975 return $result; 976 } 977 938 978 939 979 function rimplenet_txn_exist($user_id,$external_txn_id){ -
rimplenet/trunk/includes/class-withdrawals.php
r2609583 r2627751 53 53 54 54 } 55 elseif($user_wdr_bal<=0){ 56 $status = "user_wdr_bal_is_zero_or_less"; 57 $response_message = "User Withdrawable Balance should not be Zero or Less"; 58 $data = array("error"=>"User Withdrawable Balance should not be Zero or Less"); 59 } 55 60 elseif($amount_to_withdraw<=0){ 56 61 $status = "amount_is_zero_or_less"; … … 98 103 $status = "success"; 99 104 $response_message = "Withdrawal Request Submitted Successful"; 105 do_action('rimplenet_withdraw_user_wallet_bal_submitted_success',$txn_wdr_id, $wallet_id, $amount_to_withdraw, $user_id_withdrawing ); 100 106 $data = array("txn_id"=>$txn_wdr_id); 101 107 } -
rimplenet/trunk/includes/layouts/rimplenet-withdrawal-form.php
r2610704 r2627751 10 10 <center> 11 11 <div class="alert alert-danger alert-dismissible fade show" role="alert"> 12 <strong> ERROR: </strong> Please Login or Register to Procced12 <strong> ERROR: </strong> Please Login or Register by clicking account tab 13 13 <button type="button" class="close" data-dismiss="alert" aria-label="Close"> 14 14 <span aria-hidden="true">×</span>
Note: See TracChangeset
for help on using the changeset viewer.