reset password

This commit is contained in:
venbatechnologies@gmail.com 2018-04-25 10:36:11 +05:30
parent 713268de56
commit c274c1c70d
2 changed files with 10 additions and 4 deletions

View File

@ -12,6 +12,8 @@ class Forgot_model extends CI_Model {
//
function forget($user=null, $password)
{
//echo $password;
$this->db->select('ID,Emailid,MobileNumber,Password');
$this->db->from(LOGIN);
$this->db->where('MobileNumber', $user['MobileNumber']);
@ -20,6 +22,10 @@ class Forgot_model extends CI_Model {
// echo $forgotDetails->MobileNumber;exit();
$mobile=$forgotDetails1->MobileNumber;
$user['MobileNumber'] = $mobile;
// print_r($user);
// die();
// $result = $query->result_array();
if($forgotDetails1){
$this->db->select('ID,Emailid,MobileNumber,Password');
@ -31,7 +37,7 @@ class Forgot_model extends CI_Model {
$existUserID=$forgotDetails->ID;
$this->db->where('ID', $existUserID);
$upatePassword=$this->db->update('T_Login', $user);
// print_r ($upatePassword) ;
// print_r($user) ;
//exit();
if($upatePassword) {
$this->smssend($mobile, $password);

View File

@ -43,7 +43,7 @@ class Login_model extends CI_Model
if ($password == $loginDetails->Password) {
if($loginDetails->ListCode == SUPER_ADMIN){
// echo "Super";
echo "Super";
// print_r($loginDetails);exit();
$this->db->select('t1.MobileNumber, t1.ListCode, t1.ID, t2.BranchCode, t2.FinanceModuleAccess');
$this->db->from('' . LOGIN . ' as t1');