diff --git a/app/Controllers/MasterController.php b/app/Controllers/MasterController.php index 90f429d..2735db0 100644 --- a/app/Controllers/MasterController.php +++ b/app/Controllers/MasterController.php @@ -789,19 +789,22 @@ class MasterController extends BaseController // print_r($this->session->get());die; - $clientData = $this->ClientDocsModel->select('client.name as client_name, client_branch.email, client_branch.mobile_no') + $clientData = $this->ClientDocsModel->select('client.name as client_name, client_branch.email, client_branch.mobile_no, client_branch.whatsapp') ->join('client_branch', 'client_docs.client_branch_id = client_branch.id', 'left') ->join('client', 'client_branch.client_id = client.client_id', 'left') ->where('client_docs.id', $doc_id)->get()->getRow(); // helper('url'); $url ='Preview and Approve Document'; - $businessData = $this->BranchModel->select('branches.* , business.business_name ') - ->join('business', 'branches.business_id = business.business_id', 'left') - ->where('branches.branch_id',$this->session->get('logged_in_staff_branch_id')) + // $businessData = $this->BranchModel->select('branches.* , business.business_name ') + // ->join('business', 'branches.business_id = business.business_id', 'left') + // ->where('branches.branch_id',$this->session->get('logged_in_staff_branch_id')) + // ->get()->getRow(); + $businessData = $this->BusinessModel->select('business.*') + ->where('business.business_id',$this->session->get('logged_in_staff_business_id')) ->get()->getRow(); $subject = 'BB-Sign Verify Document'; $message = "Dear " . $clientData->client_name . ",
" . $businessData->business_name . " has requested your approval for a document. Please click the link below to preview and approve.

" . $url; - $MailHelper->send_url_email($clientData->email , $businessData->email, $subject, $message); + $MailHelper->send_url_email($clientData->email , '', $subject, $message); $notificationHelper = new NotificationHelper(); $number = '91'.$clientData->mobile_no; // Replace with dynamic recipient number if($clientData->whatsapp == 1){