@@ -523,6 +523,57 @@ public function mail_transport_delete($session_id, $primary_id)
523523 return $ affected_rows ;
524524 }
525525
526+ //* Get mail relay_recipient details
527+ public function mail_relay_recipient_get ($ session_id , $ primary_id )
528+ {
529+ global $ app ;
530+
531+ if (!$ this ->checkPerm ($ session_id , 'mail_relay_get ' )) {
532+ $ this ->server ->fault ('permission_denied ' , 'You do not have the permissions to access this function. ' );
533+ return false ;
534+ }
535+ $ app ->uses ('remoting_lib ' );
536+ $ app ->remoting_lib ->loadFormDef ('../mail/form/mail_relay_recipient.tform.php ' );
537+ return $ app ->remoting_lib ->getDataRecord ($ primary_id );
538+ }
539+
540+
541+ //* relay recipient email
542+ public function mail_relay_recipient_add ($ session_id , $ client_id , $ params )
543+ {
544+ if (!$ this ->checkPerm ($ session_id , 'mail_relay_add ' ))
545+ {
546+ $ this ->server ->fault ('permission_denied ' ,'You do not have the permissions to access this function. ' );
547+ return false ;
548+ }
549+ $ affected_rows = $ this ->insertQuery ('../mail/form/mail_relay_recipient.tform.php ' , $ client_id , $ params );
550+ return $ affected_rows ;
551+ }
552+
553+
554+ public function mail_relay_recipient_update ($ session_id , $ client_id , $ primary_id , $ params )
555+ {
556+ if (!$ this ->checkPerm ($ session_id , 'mail_relay_update ' ))
557+ {
558+ $ this ->server ->fault ('permission_denied ' ,'You do not have the permissions to access this function. ' );
559+ return false ;
560+ }
561+ $ affected_rows = $ this ->updateQuery ('../mail/form/mail_relay_recipient.tform.php ' , $ client_id , $ primary_id , $ params );
562+ return $ affected_rows ;
563+ }
564+
565+
566+ public function mail_relay_recipient_delete ($ session_id , $ primary_id )
567+ {
568+ if (!$ this ->checkPerm ($ session_id , 'mail_relay_delete ' ))
569+ {
570+ $ this ->server ->fault ('permission_denied ' ,'You do not have the permissions to access this function. ' );
571+ return false ;
572+ }
573+ $ affected_rows = $ this ->deleteQuery ('../mail/form/mail_relay_recipient.tform.php ' , $ primary_id );
574+ return $ affected_rows ;
575+ }
576+
526577 //* Get spamfilter whitelist details
527578 public function mail_spamfilter_whitelist_get ($ session_id , $ primary_id )
528579 {
0 commit comments