Support A2Billing :

provided by Star2Billing S.L.

Support A2Billing :
It is currently Tue Mar 19, 2024 3:27 am
Hosted Voice Broadcast


All times are UTC




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: change customer password
PostPosted: Tue Mar 06, 2012 9:39 pm 
Offline

Joined: Tue Nov 29, 2011 10:16 pm
Posts: 4
customer cannot change password A2B_entity_password.php its seems
not functioning , I'm using a2billing 1.9.4 with Asterisk 1.8.9.0

any idea :D


Top
 Profile  
 
 Post subject: Re: change customer password
PostPosted: Mon Apr 23, 2012 6:10 pm 
Offline
User avatar

Joined: Fri Sep 18, 2009 5:46 pm
Posts: 132
Location: hhhhmmmmm
i think its permission issue.


Top
 Profile  
 
 Post subject: Re: change customer password
PostPosted: Thu Jan 31, 2013 1:22 pm 
Offline

Joined: Tue Nov 13, 2012 11:15 am
Posts: 4
To fix this issue I modified A2Billing_entity_password.php file.

It had:


if ($form_action=="ask-modif") {
$instance_sub_table = new Table('cc_card',"id");
$check_old_pwd = "id = '".$_SESSION["card_id"]."' AND uipass = '$OldPassword'";
$result_check=$instance_sub_table -> Get_list ($DBHandle,$check_old_pwd);
if (is_array($result_check)) {
$QUERY = "UPDATE cc_card SET uipass= '".$NewPassword."' WHERE ( ID = ".$_SESSION["card_id"]." ) ";
$result = $instance_sub_table -> SQLExec ($DBHandle, $QUERY, 0);
// update Session password
$_SESSION["pr_password"] = $NewPassword;
}
}

I replaced to:


if ($form_action=="ask-modif") {
$instance_sub_table = new Table('cc_card',"id");
$check_old_pwd = "id = '".$_SESSION["card_id"]."' AND uipass = '$OldPassword'";
$result_check=$instance_sub_table -> Get_list ($DBHandle,$check_old_pwd);
if (is_array($result_check)) {
// GUI
$QUERY = "UPDATE cc_card SET uipass= '".$NewPassword."' WHERE ( ID = ".$_SESSION["card_id"]." ) ";
$result = $instance_sub_table -> SQLExec ($DBHandle, $QUERY, 0);
// SIP
$QUERY = "UPDATE cc_sip_buddies SET secret= '".$NewPassword."' WHERE ( id_cc_card = ".$_SESSION["card_id"]." ) ";
$result = $instance_sub_table -> SQLExec ($DBHandle, $QUERY, 0);
// update Session password
$_SESSION["pr_password"] = $NewPassword;
}
}

After that, once customer changed password from his interface his login and SIP password are synchronized and SIP password changed.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 
Hosted Voice Broadcast


All times are UTC


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group