wip account states
This commit is contained in:
@@ -130,6 +130,7 @@ function failure_payment_for_user_CIPF($user_id, $order_id, $status) {
|
||||
PLGNTLS_class::debug_infos();
|
||||
|
||||
$acf_card_state = PLGNTLS_class::ACF_CARD_STATE;
|
||||
$acf_account_state = PLGNTLS_class::ACF_ACCOUNT_STATE;
|
||||
$acf_card_expiration = PLGNTLS_class::ACF_CARD_EXPIRATION;
|
||||
$card_duration = PLGNTLS_class::CARD_VALIDITY_TIME;
|
||||
$prof_is_activ = PLGNTLS_class::ACF_PROF_IS_ACTIV;
|
||||
@@ -159,10 +160,12 @@ function failure_payment_for_user_CIPF($user_id, $order_id, $status) {
|
||||
|
||||
/*
|
||||
* other changes on user :
|
||||
* - pofil is inactive
|
||||
* //- pofil is inactive
|
||||
* - account_stat is to_pay
|
||||
*
|
||||
*/
|
||||
update_field($prof_is_activ['_name'], $prof_is_activ['inactiv'], $acf_id);
|
||||
//update_field($prof_is_activ['_name'], $prof_is_activ['inactiv'], $acf_id);
|
||||
update_field($acf_account_state['_name'], $acf_account_state['to_pay'], $acf_id);
|
||||
}
|
||||
|
||||
|
||||
@@ -174,6 +177,7 @@ function validate_payment_for_user_CIPF($user_id, $order_id) {
|
||||
PLGNTLS_class::debug_infos();
|
||||
|
||||
$acf_card_state = PLGNTLS_class::ACF_CARD_STATE;
|
||||
$acf_account_state = PLGNTLS_class::ACF_ACCOUNT_STATE;
|
||||
$acf_card_expiration = PLGNTLS_class::ACF_CARD_EXPIRATION;
|
||||
$acf_card_number = PLGNTLS_class::ACF_CARD_NUMBER;
|
||||
$card_duration = PLGNTLS_class::CARD_VALIDITY_TIME;
|
||||
@@ -256,13 +260,14 @@ function validate_payment_for_user_CIPF($user_id, $order_id) {
|
||||
|
||||
/*
|
||||
* change user :
|
||||
* - profile is active
|
||||
* - card state is renewal
|
||||
* //- profile is active
|
||||
* - payement status is success
|
||||
* - account_state is valid
|
||||
*
|
||||
*/
|
||||
update_field($prof_is_activ['_name'], $prof_is_activ['activ'], $acf_id);
|
||||
//update_field($prof_is_activ['_name'], $prof_is_activ['activ'], $acf_id);
|
||||
update_field($acf_payment_status['_name'], $acf_payment_status['success'], $acf_id);
|
||||
update_field($acf_account_state['_name'], $acf_account_state['valid'], $acf_id);
|
||||
|
||||
/*
|
||||
* reset some fields for the form to buy the card
|
||||
|
||||
Reference in New Issue
Block a user