vtiger Forum Index vtiger
The Honest Open Source CRM
 

Add more fields in email templates
Click here to go to the original topic

 
       vtiger Forum Index -> Feature Requests - 5.0.4
Previous topic :: Next topic  
Author Message
neojet



Joined: 07 Dec 2005
Posts: 41
Location: Marseille (France)

Posted: Fri Jul 18, 2008 8:34 am    Post subject: Add more fields in email templates  

Hi.
I would like you add more fields for merged emails, by using custom fields for each module for example.
Add account custom fields for Account selection you see?

I think that the function getMergedDescription() manages this but I don't know how to modify this code to do what I want.

Code:
   switch($parent_type)
   {
      case 'Accounts':
         if(is_array($fields["accounts"]))
         {
            $columnfields = implode(',',$fields["accounts"]);
            $query = 'select '.$columnfields.' from vtiger_account where accountid ='.$id;
            $result = $adb->query($query);
            foreach($fields["accounts"] as $columnname)         
            {
               $token_data = '$accounts-'.$columnname.'$';
               $description = str_replace($token_data,$adb->query_result($result,0,$columnname),$description);
            }
         }
         break;


Do you have an idea?
Back to top  
 
       vtiger Forum Index -> Feature Requests - 5.0.4
Page 1 of 1


Powered by phpBB Search Engine Indexer
Powered by phpBB 2.0.15 © 2001, 2002 phpBB Group