'; $hidden .= ''; $hidden .= ''; $hidden .= ''; $hidden .= ''; $hidden .= ''; $hidden .= ''; $hidden .= ''; $hidden .= ''; $hidden .= ''; return $hidden; } function renderRelatedActivities($query,$id) { global $mod_strings; global $app_strings; $hidden = getHiddenValues($id); $hidden .= ''; echo $hidden; $focus = new Activity(); $button = ''; if(isPermitted("Activities",1,"") == 'yes') { $button .= ' '; $button .= ' '; } $returnset = '&return_module=Potentials&return_action=DetailView&return_id='.$id; $list = GetRelatedList('Potentials','Activities',$focus,$query,$button,$returnset); echo ''; } function renderRelatedContacts($query,$id) { global $mod_strings; global $app_strings; $hidden = getHiddenValues($id); echo $hidden; $focus = new Contact(); $button = ''; if(isPermitted("Contacts",3,"") == 'yes') { $button .= ' '; } $returnset = '&return_module=Potentials&return_action=DetailView&return_id='.$id; $list = GetRelatedList('Potentials','Contacts',$focus,$query,$button,$returnset); echo ''; } function renderRelatedProducts($query,$id) { require_once('modules/Products/Product.php'); global $mod_strings; global $app_strings; $hidden = getHiddenValues($id); echo $hidden; $focus = new Product(); $button = ''; if(isPermitted("Products",1,"") == 'yes') { $button .= ' '; } if(isPermitted("Products",3,"") == 'yes') { $button .= ' '; } $returnset = '&return_module=Potentials&return_action=DetailView&return_id='.$id; $list = GetRelatedList('Potentials','Products',$focus,$query,$button,$returnset); echo ''; } function renderRelatedAttachments($query,$id) { $hidden = getHiddenValues($id); echo $hidden; getAttachmentsAndNotes('Potentials',$query,$id); echo ''; } function renderRelatedHistory($query,$id) { getHistory('Potentials',$query,$id); echo '

'; } function renderRelatedStageHistory($query,$id) { global $theme; $theme_path="themes/".$theme."/"; $image_path=$theme_path."images/"; require_once ($theme_path."layout_utils.php"); global $adb; global $mod_strings; global $app_strings; $result=$adb->query($query); $noofrows = $adb->num_rows($result); echo '
'; echo get_form_header($app_strings['LBL_SALES_STAGE'].' '.$app_strings['LBL_HISTORY'],'', false); if($noofrows == 0) { echo 'Sales Stage Never Changed'; } else { $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $i=1; while($row = $adb->fetch_array($result)) { if ($i%2==0) $trowclass = 'evenListRow'; else $trowclass = 'oddListRow'; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $list .= ''; $i++; } $list .= '
'; $list .= ''; $list .= $app_strings['LBL_AMOUNT'].''; $list .= ''; $list .= $app_strings['LBL_SALES_STAGE'].''; $list .= ''; $list .= $app_strings['LBL_PROBABILITY'].''; $list .= ''; $list .= $app_strings['LBL_CLOSE_DATE'].''; $list .= ''; $list .= $app_strings['LBL_LAST_MODIFIED'].''; $list .= ''; $list .= '
'; $list .= ''.$row['amount'].''; $list .= ''; $list .= $row['stage']; $list .= ''; $list .= ''; $list .= $row['probability']; $list .= ''; $list .= ''; $list .= $row['closedate']; $list .= ''; $list .= ''; $list .= $row['lastmodified']; $list .= '
'; echo $list; } echo "
\n"; } function renderRelatedQuotes($query,$id,$acntid='') { global $mod_strings; global $app_strings; require_once('modules/Quotes/Quote.php'); $hidden = getHiddenValues($id); $hidden .=''; echo $hidden; if($acntid!='') $focus = new Quote(); $button = ''; if(isPermitted("Quotes",1,"") == 'yes') { $button .= ' '; } $returnset = '&return_module=Potentials&return_action=DetailView&return_id='.$id; $list = GetRelatedList('Potentials','Quotes',$focus,$query,$button,$returnset); echo ''; } function renderRelatedSalesOrders($query,$id,$acntid='') { require_once('modules/Orders/SalesOrder.php'); global $mod_strings; global $app_strings; $hidden = getHiddenValues($id); $hidden .=''; echo $hidden; $focus = new SalesOrder(); $button = ''; if(isPermitted("SalesOrder",1,"") == 'yes') { $button .= ' '; } $returnset = '&return_module=Potentials&return_action=DetailView&return_id='.$id; $list = GetRelatedList('Potentials','SalesOrder',$focus,$query,$button,$returnset); echo ''; } echo get_form_footer(); ?>