Пример #1
0
 function display()
 {
     $this->populateCurrency();
     $this->populateQuoteTemplates();
     $this->populateLineItems();
     parent::display();
 }
Пример #2
0
 /**
  * display
  * Override the display method to support customization for the buttons that display
  * a popup and allow you to copy the account's address into the selected contacts.
  * The custom_code_billing and custom_code_shipping Smarty variables are found in
  * include/SugarFields/Fields/Address/DetailView.tpl (default).  If it's a English U.S.
  * locale then it'll use file include/SugarFields/Fields/Address/en_us.DetailView.tpl.
  */
 function display()
 {
     global $app_strings, $app_list_strings;
     global $mod_strings;
     parent::display();
     $smarty = new Sugar_Smarty();
     $smarty->assign('APP', $app_strings);
     $smarty->assign('MOD', $mod_strings);
     $smarty->assign('RECORD', $this->bean->id);
     $popup_request_data = array('call_back_function' => 'set_return', 'form_name' => 'xeBayOrderSend', 'field_to_name_array' => array('description' => 'message'));
     $json = getJSONobj();
     $smarty->assign('ENCODED_TEMPLATES_POPUP_REQUEST_DATA', $json->encode($popup_request_data));
     $smarty->assign("TEMPLATE_SELECT", SugarThemeRegistry::current()->getImage('id-ff-select', '', null, null, '.png', $mod_strings['LBL_SELECT']));
     $smarty->assign("TEMPLATE_CLEAR", SugarThemeRegistry::current()->getImage('id-ff-clear', '', null, null, '.gif', $mod_strings['LBL_ID_FF_CLEAR']));
     $itemAssociation = '';
     $this->bean->load_relationship('xebaytransactions');
     $transactions = $this->bean->xebaytransactions->getBeans();
     $first = true;
     foreach ($transactions as &$transaction) {
         if (!empty($transaction->item_item_id)) {
             if ($first == true) {
                 $first = false;
                 $smarty->assign('ITEM_ID', $transaction->item_item_id);
                 $smarty->assign('SUBJECT', $transaction->name);
                 $itemAssociation .= "<input name='item_assocaition' id='{$transaction->name}' type='radio' value='{$transaction->item_item_id}' checked='checked' onclick=select_item_id(this) />{$transaction->name}<br>";
             } else {
                 $itemAssociation .= "<input name='item_assocaition' id='{$transaction->name}' type='radio' value='{$transaction->item_item_id}' onclick=select_item_id(this) />{$transaction->name}<br>";
             }
         }
     }
     $smarty->assign('ITEM_ASSOCIATION', $itemAssociation);
     $smarty->assign('SALUTATION', str_replace("\n", "<br>", $this->bean->get_salutation()));
     $smarty->assign('SIGNATURE', str_replace("\n", "<br>", $this->bean->get_signature()));
     $smarty->display("modules/xeBayOrders/tpls/send.tpl");
 }
Пример #3
0
 function display()
 {
     global $mod_strings, $app_list_strings;
     $this->displayPopupHtml();
     // Contract Value:
     $html = '
             <table cellpadding="0" cellspacing="0" border="1" width="100%" style="border-collapse:collapse" class="table_clone" id="contract_value">
                 <thead>
                     <tr bgcolor="#CCCCCC">
                         <th align="center"> ' . $mod_strings['LBL_CONTRACT_SERVICE'] . '</th>
                         <th align="center"> ' . $mod_strings['LBL_CONTRACT_SOLUONG'] . '</th> 
                         <th align="center"> ' . $mod_strings['LBL_CONTRACT_GIATOUR'] . '</th>
                         <th align="center"> ' . $mod_strings['LBL_CONTRACT_THUE'] . '</th>
                         <th align="center"> ' . $mod_strings['LBL_CONTRACT_THANHTIEN'] . '</th>
                         <th align="center">&nbsp;</th>
                     </tr>
                 </thead>
                 <tbody>
         ';
     $html .= $this->bean->get_contract_values_detailview();
     $html .= '</tbody>
                     </table>';
     $this->dv->ss->assign("contract_value", $html);
     // Contract Condition:
     $html = '
               <table cellpadding="0" cellspacing="0" border="0" width="100%" class="table_clone" id="contract_condition">
                     <tbody>
         ';
     $html .= $this->bean->get_contract_condition_detailview();
     $html .= '</tbody>
                     </table>';
     $this->dv->ss->assign("contract_condition", $html);
     $this->dv->ss->assign("tongtien", format_number($this->bean->tongtien));
     parent::display();
 }
Пример #4
0
 /**
  * display
  *
  */
 function display()
 {
     parent::display();
     global $current_user, $app_strings, $mod_strings;
     if (isset($this->bean->query_id) && !empty($this->bean->query_id)) {
         //CHECK FOR SUB-QUERIES
         $this->bean->check_interlock();
         //OUTPUT THE DATASET
         $data_set = BeanFactory::getBean('CustomQueries', $this->bean->query_id);
         $QueryView = new ReportListView();
         $QueryView->initNewXTemplate('modules/CustomQueries/QueryView.html', $mod_strings);
         $QueryView->setHeaderTitle($this->bean->name);
         //below: make sure to aquire the custom layout headers if available
         $QueryView->export_type = "Ent";
         $QueryView->xTemplateAssign('EDIT_INLINE', SugarThemeRegistry::current()->getImage('edit_inline', 'align="absmiddle" border="0"', null, null, '.gif', $app_strings['LNK_EDIT']));
         $QueryView->xTemplateAssign('LEFTARROW_INLINE', SugarThemeRegistry::current()->getImage('calendar_previous', 'align="absmiddle" border="0"', null, null, '.gif', $mod_strings['LBL_LEFT']));
         $QueryView->xTemplateAssign('RIGHTARROW_INLINE', SugarThemeRegistry::current()->getImage('calendar_next', 'align="absmiddle" border="0"', null, null, '.gif', $mod_strings['LBL_RIGHT']));
         $QueryView->setup($data_set, $this->bean, "main", "CUSTOMQUERY");
         $query_results = $QueryView->processDataSet();
         if ($query_results['result'] == "Error") {
             if (is_admin($current_user)) {
                 echo "<font color=\"red\"><b>" . $query_results['result_msg'] . "" . $app_strings['ERROR_EXAMINE_MSG'] . "</font><BR>" . $query_results['msg'] . "</b>";
             } else {
                 echo "<font color=\"red\"><b>" . $query_results['result_msg'] . "</font></b><BR>";
             }
         }
         //end if there is even a query for the data set
     } else {
         echo "<font color=\"red\"><b>" . $app_strings['NO_QUERY_SELECTED'] . "</font></b><BR>";
     }
 }
Пример #5
0
 function display()
 {
     echo '<style type="text/css">@import url("custom/include/OfficeReportsMerge/Prettify/prettify.css"); </style>';
     echo '<script>YAHOO.util.Event.onDOMReady(function() {prettyPrint();});</script>';
     $this->dv->process();
     parent::display();
 }
Пример #6
0
 function zd_TicketsViewDetail()
 {
     parent::SugarView();
     $repair = new RepairAndClear();
     $repair->module_list = array('zd_Tickets');
     $repair->clearTpls();
 }
Пример #7
0
 /**
  * display
  * Override the display method to support customization for the buttons that display
  * a popup and allow you to copy the account's address into the selected contacts.
  * The custom_code_billing and custom_code_shipping Smarty variables are found in
  * include/SugarFields/Fields/Address/DetailView.tpl (default).  If it's a English U.S.
  * locale then it'll use file include/SugarFields/Fields/Address/en_us.DetailView.tpl.
  */
 function display()
 {
     //clear detailview cache
     /* $this->th2 = new TemplateHandler(); 
        $this->th2->clearCache($this->module);  */
     parent::display();
 }
Пример #8
0
 /**
  * display
  */
 function display()
 {
     $this->bean->parseInterval();
     $this->bean->setIntervalHumanReadable();
     $this->ss->assign('JOB_INTERVAL', $this->bean->intervalHumanReadable);
     parent::display();
 }
Пример #9
0
 /**
  * @see SugarView::display()
  */
 public function display()
 {
     global $beanFiles;
     require_once $beanFiles['Quote'];
     require_once $beanFiles['TaxRate'];
     require_once $beanFiles['Shipper'];
     if ($this->bean->fetched_row['date_quote_expected_closed'] == '1970-01-01' || $this->bean->fetched_row['date_quote_expected_closed'] == '0001-01-01') {
         $this->bean->date_quote_expected_closed = '';
     }
     $this->bean->load_relationship('product_bundles');
     $product_bundle_list = $this->bean->product_bundles->getBeans();
     if (is_array($product_bundle_list)) {
         usort($product_bundle_list, array('ProductBundle', 'compareProductBundlesByIndex'));
     }
     $this->ss->assign('ordered_bundle_list', $product_bundle_list);
     $currency = BeanFactory::getBean('Currencies', $this->bean->currency_id);
     $this->ss->assign('CURRENCY_SYMBOL', $currency->symbol);
     $this->ss->assign('CURRENCY', $currency->iso4217);
     $this->ss->assign('CURRENCY_ID', $currency->id);
     if (!(strpos($_SERVER['HTTP_USER_AGENT'], 'Mozilla/5') === false)) {
         $this->ss->assign('PDFMETHOD', 'POST');
     } else {
         $this->ss->assign('PDFMETHOD', 'GET');
     }
     // if there is an opportunity on this quote, then disable the convert to Opportunity
     $disable_convert = '';
     if (!empty($this->bean->opportunity_id)) {
         $disable_convert = 'disabled="disabled"';
     }
     $this->ss->assign('DISABLE_CONVERT', $disable_convert);
     global $app_list_strings, $current_user;
     $this->ss->assign('APP_LIST_STRINGS', $app_list_strings);
     $this->ss->assign('gridline', $current_user->getPreference('gridline') == 'on' ? '1' : '0');
     parent::display();
 }
Пример #10
0
 function display()
 {
     $output = array();
     $fields = unencodeMultienum($this->bean->report_vars);
     foreach ($fields as $field) {
         if (strpos($field, '.')) {
             list($module_name, $field_name) = explode('.', $field, 2);
             if (!isset($output[$module_name])) {
                 $output[$module_name] = array();
             }
             $output[$module_name][$field_name] = Reports_Utils::translateField($field, '', false);
         } else {
             $output[$field] = Reports_Utils::translateField($field, $this->bean->report_module);
         }
         $html = '<ul>';
         //krsort($output);
         foreach ($output as $key => $field) {
             if (is_array($field)) {
                 $html .= "<li><b>{$key}</b></li><ul>";
                 foreach ($field as $rel_key => $rel_field) {
                     $html .= "<li>{$rel_field}&nbsp;&nbsp;&nbsp;<input type='text' size=25 value='[{$key}.{$rel_key}]'></li>";
                 }
                 $html .= '</ul>';
             } else {
                 $html .= "<li>{$field}&nbsp;&nbsp;&nbsp;<input type='text' size=25 value='[{$key}]'></li>";
             }
         }
         $html .= '</ul>';
     }
     $this->ss->assign('REPORT_VARS_TREE', $html);
     $this->ss->assign('DOWNLOAD_TEMPLATE_LINK', $this->bean->getStoredFileName());
     parent::display();
 }
Пример #11
0
 public function testdisplay()
 {
     error_reporting(E_ERROR | E_PARSE);
     //execute the method with essential parameters set. it should return some html.
     $view = new ViewDetail();
     $view->module = 'Users';
     $view->bean = new User();
     $view->bean->id = 1;
     $view->ss = new Sugar_Smarty();
     $view->preDisplay();
     ob_start();
     $view->display();
     $renderedContent = ob_get_contents();
     ob_end_clean();
     $this->assertGreaterThan(0, strlen($renderedContent));
 }
Пример #12
0
 function display()
 {
     global $mod_strings, $app_strings, $app_list_strings, $sugar_config, $current_user;
     $this->ss->assign("MOD", $mod_strings);
     $this->ss->assign("APP_LIST", $app_list_strings);
     // Sync info from tilkee server
     $this->bean->sync_from_API('update_tilks');
     // Build Stat url
     $stat_url = "";
     if (isset($current_user->tilkee_token_c) && !empty($current_user->tilkee_token_c) && !empty($this->bean->stat_url)) {
         $stat_url = $this->bean->stat_url . '&access_token=' . $current_user->tilkee_token_c;
     }
     $this->ss->assign("STAT_URL", $stat_url);
     // Build Stat url
     /*$preview_url = "";
       if (isset($current_user->tilkee_token_c) && !empty($current_user->tilkee_token_c) && !empty($this->bean->preview_url)) {
           $preview_url = $this->bean->preview_url.'&access_token='.$current_user->tilkee_token_c;
       }*/
     $this->ss->assign("PREVIEW_URL", $this->bean->preview_url);
     $button_array = $this->dv->defs['templateMeta']['form']['buttons'];
     $new_button_array = array();
     $new_button_array[] = $button_array[0];
     // EDIT
     //$new_button_array[] = $button_array[1]; // DUPLICATE
     $new_button_array[] = $button_array[3];
     // DUPLICATE
     switch ($this->bean->status) {
         case 'reviewing':
             $new_button_array[] = $button_array[2];
             // DELETE
             $new_button_array[] = $button_array[4];
             // ARCHIVED/WON
             $new_button_array[] = $button_array[5];
             // ARCHIVED/LOST
             $new_button_array[] = $button_array[6];
             // ARCHIVED
             break;
         case 'pending_approval':
             break;
         case 'activated':
             $new_button_array[] = $button_array[4];
             // ARCHIVED/WON
             $new_button_array[] = $button_array[5];
             // ARCHIVED/LOST
             $new_button_array[] = $button_array[6];
             // ARCHIVED
             break;
         case 'archived':
             $new_button_array[] = $button_array[2];
             // DELETE
             $new_button_array[] = $button_array[7];
             // DESARCHIVED
             break;
         default:
             break;
     }
     $this->dv->defs['templateMeta']['form']['buttons'] = $new_button_array;
     parent::display();
 }
Пример #13
0
 public function preDisplay()
 {
     parent::preDisplay();
     if (ACLController::checkAccess('KBDocuments', 'edit', true)) {
         array_push($this->dv->defs['templateMeta']['form']['buttons'], array('customCode' => '<input title="{$MOD.LBL_CREATE_KB_DOCUMENT}" accessKey="M" class="button" onclick="this.form.return_module.value=\'Cases\'; this.form.return_action.value=\'DetailView\';this.form.action.value=\'EditView\';this.form.module.value=\'KBDocuments\';" type="submit" name="button" value="{$MOD.LBL_CREATE_KB_DOCUMENT}">', 'sugar_html' => array('type' => 'submit', 'value' => '{$MOD.LBL_CREATE_KB_DOCUMENT}', 'htmlOptions' => array('title' => '{$MOD.LBL_CREATE_KB_DOCUMENT}', 'accessKey' => 'M', 'class' => 'button', 'onclick' => 'this.form.return_module.value=\'Cases\'; this.form.return_action.value=\'DetailView\';this.form.action.value=\'EditView\';this.form.module.value=\'KBDocuments\';', 'name' => 'button'))));
     }
     $this->dv->th->deleteTemplate($this->dv->module, $this->dv->view);
 }
Пример #14
0
 function display()
 {
     global $sugar_config;
     //If the convert lead action has been disabled for already converted leads, disable the action link.
     $disableConvert = $this->bean->status == 'Converted' && !empty($sugar_config['disable_convert_lead']) ? TRUE : FALSE;
     $this->ss->assign("DISABLE_CONVERT_ACTION", $disableConvert);
     parent::display();
 }
Пример #15
0
 /**
  * @see SugarView::display()
  */
 public function display()
 {
     global $beanFiles;
     require_once $beanFiles['ProjectTask'];
     $focus = BeanFactory::getBean('ProjectTask', $_REQUEST['record']);
     $this->ss->assign('resource', $focus->getResourceName());
     parent::display();
 }
Пример #16
0
 function display()
 {
     $admin = Administration::getSettings();
     if (isset($admin->settings['portal_on']) && $admin->settings['portal_on']) {
         $this->ss->assign("PORTAL_ENABLED", true);
     }
     parent::display();
 }
Пример #17
0
 function display()
 {
     $this->populateTemplates();
     $this->setDecodeHTML();
     $this->displayPopupHtml();
     global $mod_strings;
     global $app_strings;
     global $app_list_strings;
     global $gridline;
     $detailView = new DetailView();
     $offset = 0;
     if (isset($_REQUEST['offset']) or isset($_REQUEST['record'])) {
         $result = $detailView->processSugarBean("CONTRACTLIQUIDATE", $this->bean, $offset);
         if ($result == null) {
             sugar_die($app_strings['ERROR_NO_RECORD']);
         }
         $this->bean = $result;
     } else {
         header("Location: index.php?module=ContractLiquidate&action=index");
     }
     if (isset($_REQUEST['isDuplicate']) && $_REQUEST['isDuplicate'] == 'true') {
         $this->bean->id = "";
     }
     global $theme;
     $theme_path = "themes/" . $theme . "/";
     $image_path = $theme_path . "images/";
     require_once $theme_path . 'layout_utils.php';
     $GLOBALS['log']->info("ContractLiquidate detail view");
     $this->dv->ss->assign("MOD", $mod_strings);
     $this->dv->ss->assign("APP", $app_strings);
     $this->dv->ss->assign("THEME", $theme);
     $this->dv->ss->assign("GRIDLINE", $gridline ? $gridline : 0);
     $this->dv->ss->assign("IMAGE_PATH", $image_path);
     $this->dv->ss->assign("PRINT_URL", "index.php?" . $GLOBALS['request_string']);
     $this->dv->ss->assign("ID", $this->bean->id);
     $this->dv->ss->assign("ASSIGNED_USER_NAME", $this->bean->assigned_user_name);
     $this->dv->ss->assign("NAME", $this->bean->name);
     $this->dv->ss->assign("NUMBER", $this->bean->number);
     $this->dv->ss->assign("DATE", $this->bean->date);
     $this->dv->ss->assign("CONTRACT", $this->bean->contract);
     $this->dv->ss->assign("CONTRACT_ID", $this->bean->contract_id);
     $this->dv->ss->assign("TONGCONG_CONTRACT_KEHOACH", number_format($this->bean->tongcong_contract_kehoach, '1', '.', ''));
     $this->dv->ss->assign("TONGCONG_CONTRACT_THUCTE", number_format($this->bean->tongcong_contract_thucte, '1', '.', ''));
     $this->dv->ss->assign("TONGCONG_TANG_KEHOACH", number_format($this->bean->tongcong_tang_kehoach, '1', '.', ''));
     $this->dv->ss->assign("TONGCONG_TANG_THUCTE", number_format($this->bean->tongcong_tang_thucte, '1', '.', ''));
     $this->dv->ss->assign("TONGCONG_GIAM_KEHOACH", number_format($this->bean->tongcong_giam_kehoach, '1', '.', ''));
     $this->dv->ss->assign("TONGCONG_GIAM_THUCTE", number_format($this->bean->tongcong_giam_thucte, '1', '.', ''));
     $this->dv->ss->assign("TONGTIEN_KEHOACH", number_format($this->bean->tongtien_kehoach, '1', '.', ''));
     $this->dv->ss->assign("TONGTIEN_THUCTE", number_format($this->bean->tongtien_thucte, '1', '.', ''));
     $this->dv->ss->assign("TIENTHANHTOAN", number_format($this->bean->tienthanhtoan, '1', '.', ''));
     $this->dv->ss->assign("TIENCONLAI", number_format($this->bean->tienconlai, '1', '.', ''));
     $this->dv->ss->assign("TIENTRALAI", number_format($this->bean->tientralai, '1', '.', ''));
     $this->dv->ss->assign("GIATRIHOPDONG", $this->bean->giatrihopdong_detail());
     $this->dv->ss->assign("PHATSINHTANG", $this->bean->phatsinhtang_detail());
     $this->dv->ss->assign("PHATSINHGIAM", $this->bean->phatsinhgiam_detail());
     $this->dv->ss->assign("BANGCHU", $this->bean->bangchu);
     parent::display();
 }
Пример #18
0
 /**
  * @see SugarView::display()
  *
  * We are overridding the display method to manipulate the portal information.
  * If portal is not enabled then don't show the portal fields.
  */
 public function display()
 {
     $admin = new Administration();
     $admin->retrieveSettings();
     if (isset($admin->settings['portal_on']) && $admin->settings['portal_on']) {
         $this->ss->assign("PORTAL_ENABLED", true);
     }
     parent::display();
 }
Пример #19
0
 function display()
 {
     if (isset($this->bean->lead_id) && !empty($this->bean->lead_id)) {
         //get lead name
         $lead = BeanFactory::getBean('Leads', $this->bean->lead_id);
         $this->ss->assign('lead', $lead);
     }
     parent::display();
 }
Пример #20
0
 /**
  * display
  */
 function display()
 {
     $this->bean->parseInterval();
     $this->bean->setIntervalHumanReadable();
     $this->ss->assign('JOB_INTERVAL', $this->bean->intervalHumanReadable);
     $this->bean->created_by_name = get_assigned_user_name($this->bean->created_by);
     $this->bean->modified_by_name = get_assigned_user_name($this->bean->modified_user_id);
     parent::display();
 }
Пример #21
0
 function display()
 {
     global $app_list_strings;
     $this->ss->assign('APP_LIST', $app_list_strings);
     if (isset($_REQUEST['mode']) && $_REQUEST['mode'] == 'set_target') {
         require_once 'modules/Campaigns/utils.php';
         //call function to create campaign logs
         $mess = track_campaign_prospects($this->bean);
         $confirm_msg = "var ajax_C_LOG_Status = new SUGAR.ajaxStatusClass();\n            window.setTimeout(\"ajax_C_LOG_Status.showStatus('" . $mess . "')\",1000);\n            window.setTimeout('ajax_C_LOG_Status.hideStatus()', 1500);\n            window.setTimeout(\"ajax_C_LOG_Status.showStatus('" . $mess . "')\",2000);\n            window.setTimeout('ajax_C_LOG_Status.hideStatus()', 5000); ";
         $this->ss->assign("MSG_SCRIPT", $confirm_msg);
     }
     if ($this->bean->campaign_type == 'Email' || $this->bean->campaign_type == 'NewsLetter') {
         $this->ss->assign("ADD_BUTTON_STATE", "submit");
         $this->ss->assign("TARGET_BUTTON_STATE", "hidden");
     } else {
         $this->ss->assign("ADD_BUTTON_STATE", "hidden");
         $this->ss->assign("DISABLE_LINK", "display:none");
         $this->ss->assign("TARGET_BUTTON_STATE", "submit");
     }
     $currency = BeanFactory::getBean('Currencies');
     if (!empty($this->bean->currency_id)) {
         $currency->retrieve($this->bean->currency_id);
         if ($currency->deleted != 1) {
             $this->ss->assign('CURRENCY', $currency->iso4217 . ' ' . $currency->symbol);
         } else {
             $this->ss->assign('CURRENCY', $currency->getDefaultISO4217() . ' ' . $currency->getDefaultCurrencySymbol());
         }
     } else {
         $this->ss->assign('CURRENCY', $currency->getDefaultISO4217() . ' ' . $currency->getDefaultCurrencySymbol());
     }
     parent::display();
     //We want to display subset of available, panels, so we will call subpanel
     //object directly instead of using sugarview.
     $GLOBALS['focus'] = $this->bean;
     require_once 'include/SubPanel/SubPanelTiles.php';
     $subpanel = new SubPanelTiles($this->bean, $this->module);
     //get available list of subpanels
     $alltabs = $subpanel->subpanel_definitions->get_available_tabs();
     if (!empty($alltabs)) {
         //iterate through list, and filter out all but 3 subpanels
         foreach ($alltabs as $key => $name) {
             if ($name != 'prospectlists' && $name != 'emailmarketing' && $name != 'tracked_urls') {
                 //exclude subpanels that are not prospectlists, emailmarketing, or tracked urls
                 $subpanel->subpanel_definitions->exclude_tab($name);
             }
         }
         //only show email marketing subpanel for email/newsletter campaigns
         if ($this->bean->campaign_type != 'Email' && $this->bean->campaign_type != 'NewsLetter') {
             //exclude emailmarketing subpanel if not on an email or newsletter campaign
             $subpanel->subpanel_definitions->exclude_tab('emailmarketing');
             // Bug #49893  - 20120120 - Captivea (ybi) - Remove trackers subpanels if not on an email/newsletter campaign (useless subpannl)
             $subpanel->subpanel_definitions->exclude_tab('tracked_urls');
         }
     }
     //show filtered subpanel list
     echo $subpanel->display();
 }
Пример #22
0
 public function __construct()
 {
     parent::__construct();
     $this->options['show_subpanels'] = false;
     $this->options['show_title'] = false;
     $this->options['show_header'] = false;
     $this->options['show_footer'] = false;
     $this->options['show_javascript'] = false;
 }
Пример #23
0
 function ViewQuick()
 {
     parent::SugarView();
     $this->options['show_subpanels'] = false;
     $this->options['show_title'] = false;
     $this->options['show_header'] = false;
     $this->options['show_footer'] = false;
     $this->options['show_javascript'] = false;
 }
Пример #24
0
 function display()
 {
     if (isset($this->bean->lead_id) && !empty($this->bean->lead_id)) {
         //get lead name
         $lead = new Lead();
         $lead->retrieve($this->bean->lead_id);
         $this->ss->assign('lead', $lead);
     }
     parent::display();
 }
Пример #25
0
 function display()
 {
     if (is_admin($GLOBALS['current_user']) || $_REQUEST['record'] == $GLOBALS['current_user']->id) {
         $this->ss->assign('DISPLAY_EDIT', true);
     }
     if (is_admin($GLOBALS['current_user'])) {
         $this->ss->assign('DISPLAY_DUPLICATE', true);
     }
     parent::display();
 }
Пример #26
0
 public function display()
 {
     $admin = new Administration();
     $admin->retrieveSettings();
     if (isset($admin->settings['portal_on']) && $admin->settings['portal_on']) {
         $this->ss->assign("PORTAL_ENABLED", true);
     }
     parent::display();
     echo "<script src='custom/include/javascript/ajaxButton.js'></script>";
 }
Пример #27
0
 public function display()
 {
     //check to see if the file field is empty.  This should not occur and would only happen when an error has ocurred during upload, or from db manipulation of record.
     if (empty($this->bean->filename)) {
         //print error to screen
         $this->errors[] = $GLOBALS['mod_strings']['ERR_MISSING_FILE'];
         $this->displayErrors();
     }
     parent::display();
 }
Пример #28
0
 function display()
 {
     $this->bean->password = empty($this->bean->password) ? '' : EAPM::$passwordPlaceholder;
     $this->ss->assign('return_id', $this->_returnId);
     if ($GLOBALS['current_user']->is_admin || empty($this->bean) || empty($this->bean->id) || $this->bean->isOwner($GLOBALS['current_user']->id)) {
         parent::display();
     } else {
         ACLController::displayNoAccess();
     }
 }
Пример #29
0
 function display()
 {
     global $sugar_config;
     require_once 'modules/AOS_PDF_Templates/formLetter.php';
     formLetter::DVPopupHtml('Leads');
     //If the convert lead action has been disabled for already converted leads, disable the action link.
     $disableConvert = $this->bean->status == 'Converted' && !empty($sugar_config['disable_convert_lead']) ? TRUE : FALSE;
     $this->ss->assign("DISABLE_CONVERT_ACTION", $disableConvert);
     parent::display();
 }
Пример #30
0
 /**
  * @see SugarView::display()
  *
  * We are overridding the display method to manipulate the portal information.
  * If portal is not enabled then don't show the portal fields.
  */
 public function display()
 {
     $admin = new Administration();
     $admin->retrieveSettings();
     if (isset($admin->settings['portal_on']) && $admin->settings['portal_on']) {
         $this->ss->assign("PORTAL_ENABLED", true);
     }
     //echo('<script src="//ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script>');
     parent::display();
 }