当前位置: 首页>>代码示例>>PHP>>正文


PHP Sugar_Smarty::display方法代码示例

本文整理汇总了PHP中Sugar_Smarty::display方法的典型用法代码示例。如果您正苦于以下问题:PHP Sugar_Smarty::display方法的具体用法?PHP Sugar_Smarty::display怎么用?PHP Sugar_Smarty::display使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Sugar_Smarty的用法示例。


在下文中一共展示了Sugar_Smarty::display方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: display

 /**
  * @see ViewQuickcreate::display()
  */
 public function display()
 {
     $userPref = $GLOBALS['current_user']->getPreference('email_link_type');
     $defaultPref = $GLOBALS['sugar_config']['email_default_client'];
     if ($userPref != '') {
         $client = $userPref;
     } else {
         $client = $defaultPref;
     }
     if ($client == 'sugar') {
         $eUi = new EmailUI();
         if (!empty($this->bean->id) && !in_array($this->bean->object_name, array('EmailMan'))) {
             $fullComposeUrl = "index.php?module=Emails&action=Compose&parent_id={$this->bean->id}&parent_type={$this->bean->module_dir}";
             $composeData = array('parent_id' => $this->bean->id, 'parent_type' => $this->bean->module_dir);
         } else {
             $fullComposeUrl = "index.php?module=Emails&action=Compose";
             $composeData = array('parent_id' => '', 'parent_type' => '');
         }
         $j_quickComposeOptions = $eUi->generateComposePackageForQuickCreate($composeData, $fullComposeUrl);
         $json_obj = getJSONobj();
         $opts = $json_obj->decode($j_quickComposeOptions);
         $opts['menu_id'] = 'dccontent';
         $ss = new Sugar_Smarty();
         $ss->assign('json_output', $json_obj->encode($opts));
         $ss->display('modules/Emails/templates/dceMenuQuickCreate.tpl');
     } else {
         $emailAddress = '';
         if (!empty($this->bean->id) && !in_array($this->bean->object_name, array('EmailMan')) && !is_null($this->bean->emailAddress)) {
             $emailAddress = $this->bean->emailAddress->getPrimaryAddress($this->bean);
         }
         echo "<script>document.location.href='mailto:{$emailAddress}';lastLoadedMenu=undefined;DCMenu.closeOverlay();</script>";
         die;
     }
 }
开发者ID:delkyd,项目名称:sugarcrm_dev,代码行数:37,代码来源:view.quickcreate.php

示例2: display

 function display()
 {
     $db = DBManagerFactory::getInstance();
     /* <<<<<<< HEAD
     		$sql = "SELECT p.id,p.first_name,p.last_name,p.dob FROM reg_patient p WHERE p.id not in (SELECT distinct pe.reg_patient_reg_encounterreg_patient_ida FROM `reg_patient_reg_encounter_c` pe, reg_encounter_cstm e WHERE pe.reg_patient_reg_encounterreg_encounter_idb=e.id_c AND e.next_pmp_review_due_c is not null) ORDER By p.last_name, p.first_name";
     ======= */
     $sql = "SELECT p.id,p.first_name,p.last_name,p.dob, rec.mrn_c AS mrn,(SELECT p1b.name provname FROM reg_provider p1b,reg_provider_reg_patient_c p2b WHERE p2b.reg_provider_reg_patientreg_provider_ida = p1b.id AND p2b.reg_provider_reg_patientreg_patient_idb = p.id AND p2b.deleted =0)provname FROM reg_patient p LEFT JOIN reg_patient_cstm rec ON rec.id_c = p.id WHERE p.id not in (SELECT distinct pe.reg_patient_reg_encounterreg_patient_ida FROM `reg_patient_reg_encounter_c` pe, reg_encounter_cstm e WHERE pe.reg_patient_reg_encounterreg_encounter_idb=e.id_c AND e.last_pmp_review_done_c is not null) ORDER By p.last_name, p.first_name";
     // >>>>>>> 3097a71433de82fec730df252659026274347e46
     $resultb = $db->query($sql, true);
     $final = array();
     while ($row = $db->fetchByAssoc($resultb)) {
         $final[] = $row;
     }
     $sql1 = "SELECT p.id, rec.mrn_c AS mrn,(SELECT p1b.name provname FROM reg_provider p1b,reg_provider_reg_patient_c p2b WHERE p2b.reg_provider_reg_patientreg_provider_ida = p1b.id AND p2b.reg_provider_reg_patientreg_patient_idb = p.id AND p2b.deleted =0)provname FROM reg_patient p LEFT JOIN reg_patient_cstm rec ON rec.id_c = p.id WHERE p.id not in (SELECT distinct pe.reg_patient_reg_encounterreg_patient_ida FROM `reg_patient_reg_encounter_c` pe, reg_encounter_cstm e WHERE pe.reg_patient_reg_encounterreg_encounter_idb=e.id_c AND e.last_pmp_review_done_c is not null) GROUP BY provname ORDER By p.last_name, p.first_name";
     $resultb1 = $db->query($sql1, true);
     $final1 = array();
     while ($row1 = $db->fetchByAssoc($resultb1)) {
         $final1[] = $row1;
     }
     $sugarSmarty = new Sugar_Smarty();
     $sugarSmarty->assign("data", $final);
     $sugarSmarty->assign("data1", $final1);
     $sugarSmarty->assign("title", "Patients who do not have PMP");
     $sugarSmarty->display('custom/modules/REG_Patient/tpls/Report1REG_Patient.tpl');
     //        parent::display();
 }
开发者ID:apikck,项目名称:REG_Patient,代码行数:26,代码来源:view.reports1.php

示例3: display

 function display()
 {
     global $mod_strings, $app_strings;
     require_once 'include/connectors/utils/ConnectorUtils.php';
     require_once 'include/connectors/sources/SourceFactory.php';
     $sugar_smarty = new Sugar_Smarty();
     $sugar_smarty->assign('mod', $mod_strings);
     $sugar_smarty->assign('APP', $app_strings);
     $connectors = ConnectorUtils::getConnectors(true);
     $required_fields = array();
     //Get required fields for first connector only
     foreach ($connectors as $id => $entry) {
         $s = SourceFactory::getSource($id);
         $connector_strings = ConnectorUtils::getConnectorStrings($id);
         $fields = $s->getRequiredConfigFields();
         foreach ($fields as $field_id) {
             $label = isset($connector_strings[$field_id]) ? $connector_strings[$field_id] : $field_id;
             $required_fields[$id][$field_id] = $label;
         }
         break;
     }
     $sugar_smarty->assign('SOURCES', $connectors);
     $sugar_smarty->assign('REQUIRED_FIELDS', $required_fields);
     echo get_module_title('Connectors', $mod_strings['LBL_MODIFY_PROPERTIES_PAGE_TITLE'], true);
     $sugar_smarty->display('modules/Connectors/tpls/modify_properties.tpl');
 }
开发者ID:klr2003,项目名称:sourceread,代码行数:26,代码来源:view.modifyproperties.php

示例4: display

 function display()
 {
     /* get sort order from session */
     //session_start(); // Make a reference to the current session object,set order
     //$_SESSION['regnamesort']= 'test' ; Set a value in a session variable
     //$GLOBALS['log']->fatal('start display');
     //var_dump($this->bean);
     $smarty = new Sugar_Smarty();
     //parent::display();
     $db = DBManagerFactory::getInstance();
     $myquery = "SELECT tab4a.first_name fname, tab4a.last_name lname,  tab5a.mrn_c mrn, tab4a.gender gender,location_c FROM reg_patient  tab4a , reg_patient_cstm tab5a WHERE tab4a.id = tab5a.id_c AND tab4a.id = '" . $_REQUEST['patid'] . "'";
     $result = $db->query($myquery);
     $patdata = null;
     $row = $db->fetchRow($result);
     $smarty->assign("patdata", $row);
     $risk = new RiskEvaluation();
     //when week filter need to add week interval
     //get patient risk if exists
     //if ($_POST['mysort'] == 'week')
     if (!empty($_REQUEST['patid'])) {
         $risk->getRisk($_REQUEST['patid']);
         $smarty->assign("pid", $_REQUEST['patid']);
     }
     //echo 'request'.$_REQUEST['patid'];
     //else return false; //param not found
     //var_dump($risk);
     //print "<pre>";
     //print_r($risk);
     $smarty->assign("myrisk", $risk);
     global $current_user;
     $smarty->assign("myuser", $current_user);
     $smarty->assign("test", "test");
     $smarty->display('custom/modules/REG_Patient/tpls/RiskEvaluationREG_Patient.tpl');
 }
开发者ID:apikck,项目名称:REG_Patient,代码行数:34,代码来源:snippetexample.php

示例5: display

 function display()
 {
     global $app_strings, $current_user, $mod_strings, $app_list_strings;
     $smarty = new Sugar_Smarty();
     require_once 'include/JSON.php';
     //Load the field list from the target module
     $selected_lang = $_SESSION['authenticated_user_language'];
     $vardef = array();
     //Copy app strings
     $my_list_strings = array_merge($app_list_strings);
     $child = $_REQUEST['field'];
     //if we are using ModuleBuilder then process the following
     if (!empty($_REQUEST['package']) && $_REQUEST['package'] != 'studio') {
         require_once 'modules/ModuleBuilder/MB/ModuleBuilder.php';
         $mb = new ModuleBuilder();
         $this->module = $mb->getPackageModule($_REQUEST['package'], $_REQUEST['view_module']);
         $vardef = $this->module->getVardefs();
         $this->module->mblanguage->generateAppStrings(false);
         $my_list_strings = array_merge($my_list_strings, $this->module->mblanguage->appListStrings[$selected_lang . '.lang.php']);
     } else {
         $vardef = BeanFactory::getBean($_REQUEST['view_module'])->field_defs;
     }
     foreach ($my_list_strings as $key => $value) {
         if (!is_array($value)) {
             unset($my_list_strings[$key]);
         }
     }
     $parents = $this->getParentDDs($vardef, $child, $my_list_strings);
     $visibility_grid = !empty($vardef[$child]['visibility_grid']) ? $vardef[$child]['visibility_grid'] : array();
     $smarty->assign('app_strings', $app_strings);
     $smarty->assign('mod', $mod_strings);
     $smarty->assign('parents', JSON::encode($parents));
     $smarty->assign('visibility_grid', JSON::encode($visibility_grid));
     $smarty->display('modules/ExpressionEngine/tpls/ddEditor.tpl');
 }
开发者ID:jglaine,项目名称:sugar761-ent,代码行数:35,代码来源:view.editDepDropdown.php

示例6: display

 function display()
 {
     global $app_strings, $current_user, $mod_strings, $theme;
     if (is_dir("themes/{$theme}/ext/resources/css")) {
         $cssDir = opendir("themes/{$theme}/ext/resources/css");
     }
     $smarty = new Sugar_Smarty();
     $type = !empty($_REQUEST['type']) ? $_REQUEST['type'] : 'main';
     $mbt = false;
     $admin = false;
     $mb = strtolower($type);
     $smarty->assign('TYPE', $type);
     $smarty->assign('app_strings', $app_strings);
     $smarty->assign('mod', $mod_strings);
     //Replaced by javascript function "setMode"
     switch ($type) {
         case 'studio':
             //$smarty->assign('ONLOAD','ModuleBuilder.getContent("module=ModuleBuilder&action=wizard")');
             require_once 'modules/ModuleBuilder/Module/StudioTree.php';
             $mbt = new StudioTree();
             break;
         case 'mb':
             //$smarty->assign('ONLOAD','ModuleBuilder.getContent("module=ModuleBuilder&action=package&package=")');
             require_once 'modules/ModuleBuilder/MB/MBPackageTree.php';
             $mbt = new MBPackageTree();
             break;
         case 'dropdowns':
             // $admin = is_admin($current_user);
             require_once 'modules/ModuleBuilder/Module/DropDownTree.php';
             $mbt = new DropDownTree();
             break;
         default:
             //$smarty->assign('ONLOAD','ModuleBuilder.getContent("module=ModuleBuilder&action=home")');
             require_once 'modules/ModuleBuilder/Module/MainTree.php';
             $mbt = new MainTree();
     }
     $smarty->assign('TEST_STUDIO', displayStudioForCurrentUser());
     $smarty->assign('ADMIN', is_admin($current_user));
     $smarty->display('modules/ModuleBuilder/tpls/includes.tpl');
     if ($mbt) {
         $smarty->assign('TREE', $mbt->fetch());
         $smarty->assign('TREElabel', $mbt->getName());
     }
     $userPref = $current_user->getPreference('mb_assist', 'Assistant');
     if (!$userPref) {
         $userPref = "na";
     }
     $smarty->assign('userPref', $userPref);
     ///////////////////////////////////
     require_once 'include/SugarTinyMCE.php';
     $tiny = new SugarTinyMCE();
     $tiny->defaultConfig['width'] = 300;
     $tiny->defaultConfig['height'] = 300;
     $tiny->buttonConfig = "code,separator,bold,italic,underline,strikethrough,separator,justifyleft,justifycenter,justifyright,\n\t                         justifyfull,separator,forecolor,backcolor,\n\t                         ";
     $tiny->buttonConfig2 = "pastetext,pasteword,fontselect,fontsizeselect,";
     $tiny->buttonConfig3 = "";
     $ed = $tiny->getInstance();
     $smarty->assign("tiny", $ed);
     $smarty->display('modules/ModuleBuilder/tpls/index.tpl');
 }
开发者ID:klr2003,项目名称:sourceread,代码行数:60,代码来源:view.main.php

示例7: display

 function display()
 {
     $template = new Sugar_Smarty();
     $template->assign('subpanel_tabs', $this->tabs);
     $template->assign('subpanel_tabs_count', count($this->tabs));
     $template->assign('jscallback', $this->jscallback);
     $template->assign('subpanel_current_key', $this->current_key);
     return $template->display('include/tabs.tpl');
 }
开发者ID:sacredwebsite,项目名称:SuiteCRM,代码行数:9,代码来源:tabs.php

示例8: display

 function display()
 {
     global $mod_strings, $app_strings;
     echo get_module_title('Connectors', $mod_strings['LBL_ADMINISTRATION_MAIN'], true);
     $sugar_smarty = new Sugar_Smarty();
     $sugar_smarty->assign('mod', $mod_strings);
     $sugar_smarty->assign('app', $app_strings);
     $sugar_smarty->assign('IMG', 'themes/default/images/');
     $sugar_smarty->display('modules/Connectors/tpls/administration.tpl');
 }
开发者ID:klr2003,项目名称:sourceread,代码行数:10,代码来源:view.connectorsettings.php

示例9: display

 function display()
 {
     require_once "include/Expressions/Dependency.php";
     require_once "include/TemplateHandler/TemplateHandler.php";
     $th = new TemplateHandler();
     $depScript = $th->createDependencyJavascript(array('phone_office' => array('calculated' => true, "formula" => 'add(strlen($name), $employees)', "enforced" => true)), array(), "EditView");
     $smarty = new Sugar_Smarty();
     $smarty->assign("dependencies", $depScript);
     $smarty->display('modules/ExpressionEngine/tpls/cfTest.tpl');
 }
开发者ID:jglaine,项目名称:sugar761-ent,代码行数:10,代码来源:view.cfTest.php

示例10: display

 function display()
 {
     global $app_strings, $current_user, $mod_strings, $theme, $beanList, $beanFiles;
     $smarty = new Sugar_Smarty();
     $json = new JSON();
     require_once 'include/JSON.php';
     //Load the field list from the target module
     if (!empty($_REQUEST['targetModule']) && $_REQUEST['targetModule'] != 'undefined') {
         $module = $_REQUEST['targetModule'];
         if (isset($_REQUEST['package']) && $_REQUEST['package'] != 'studio' && $_REQUEST['package'] != '') {
             //Get the MB Parsers
             require_once 'modules/ModuleBuilder/MB/MBPackage.php';
             $pak = new MBPackage($_REQUEST['package']);
             $defs = $pak->modules[$module]->getVardefs();
             $fields = FormulaHelper::cleanFields(array_merge($pak->modules[$module]->getLinkFields(), $defs['fields']));
         } else {
             $seed = BeanFactory::getBean($module);
             $fields = FormulaHelper::cleanFields($seed->field_defs);
         }
         $smarty->assign('Field_Array', $json->encode($fields));
     } else {
         $fields = array(array('income', 'number'), array('employed', 'boolean'), array('first_name', 'string'), array('last_name', 'string'));
         $smarty->assign('Field_Array', $json->encode($fields));
     }
     if (!empty($_REQUEST['targetField'])) {
         $smarty->assign("target", $_REQUEST['targetField']);
     }
     if (isset($_REQUEST['returnType'])) {
         $smarty->assign("returnType", $_REQUEST['returnType']);
     }
     //Assign any requested Javascript event actions
     foreach (array('onSave', 'onLoad', 'onClose') as $e) {
         if (!empty($_REQUEST[$e])) {
             $smarty->assign($e, html_entity_decode($_REQUEST[$e], ENT_QUOTES));
         } else {
             $smarty->assign($e, 'function(){}');
         }
     }
     //Check if we need to load Ext ourselves
     if (!isset($_REQUEST['loadExt']) || $_REQUEST['loadExt'] && $_REQUEST['loadExt'] != "false") {
         $smarty->assign('loadExt', true);
     } else {
         $smarty->assign('loadExt', false);
     }
     if (!empty($_REQUEST['formula'])) {
         $smarty->assign('formula', $json->decode(htmlspecialchars_decode($_REQUEST['formula'])));
     }
     if (isset($_REQUEST['returnType'])) {
         $smarty->assign('returnType', $_REQUEST['returnType']);
     }
     $smarty->assign('app_strings', $app_strings);
     $smarty->assign('mod', $mod_strings);
     $smarty->display('modules/ExpressionEngine/tpls/formulaBuilder.tpl');
 }
开发者ID:jglaine,项目名称:sugar761-ent,代码行数:54,代码来源:view.editformula.php

示例11: display

 function display()
 {
     global $app_strings, $current_user, $mod_strings, $theme;
     if (is_dir("themes/{$theme}/ext/resources/css")) {
         $cssDir = opendir("themes/{$theme}/ext/resources/css");
     }
     $smarty = new Sugar_Smarty();
     $type = !empty($_REQUEST['type']) ? $_REQUEST['type'] : 'main';
     $mbt = false;
     $admin = false;
     $mb = strtolower($type);
     $smarty->assign('TYPE', $type);
     $smarty->assign('app_strings', $app_strings);
     $smarty->assign('mod', $mod_strings);
     //Replaced by javascript function "setMode"
     switch ($type) {
         case 'studio':
             //$smarty->assign('ONLOAD','ModuleBuilder.getContent("module=ModuleBuilder&action=wizard")');
             require_once 'modules/ModuleBuilder/Module/StudioTree.php';
             $mbt = new StudioTree();
             break;
         case 'mb':
             //$smarty->assign('ONLOAD','ModuleBuilder.getContent("module=ModuleBuilder&action=package&package=")');
             require_once 'modules/ModuleBuilder/MB/MBPackageTree.php';
             $mbt = new MBPackageTree();
             break;
         case 'sugarportal':
             require_once 'modules/ModuleBuilder/Module/SugarPortalTree.php';
             $mbt = new SugarPortalTree();
             break;
         case 'dropdowns':
             // $admin = is_admin($current_user);
             require_once 'modules/ModuleBuilder/Module/DropDownTree.php';
             $mbt = new DropDownTree();
             break;
         default:
             //$smarty->assign('ONLOAD','ModuleBuilder.getContent("module=ModuleBuilder&action=home")');
             require_once 'modules/ModuleBuilder/Module/MainTree.php';
             $mbt = new MainTree();
     }
     $smarty->assign('TEST_STUDIO', displayStudioForCurrentUser());
     $smarty->assign('ADMIN', is_admin($current_user));
     $smarty->display('modules/ModuleBuilder/tpls/includes.tpl');
     if ($mbt) {
         $smarty->assign('TREE', $mbt->fetch());
         $smarty->assign('TREElabel', $mbt->getName());
     }
     $userPref = $current_user->getPreference('mb_assist', 'Assistant');
     if (!$userPref) {
         $userPref = "na";
     }
     $smarty->assign('userPref', $userPref);
     $smarty->display('modules/ModuleBuilder/tpls/index.tpl');
 }
开发者ID:nerdystudmuffin,项目名称:dashlet-subpanels,代码行数:54,代码来源:view.main.php

示例12: display

 function display()
 {
     require_once 'include/connectors/utils/ConnectorUtils.php';
     require_once 'include/connectors/sources/SourceFactory.php';
     global $mod_strings, $app_strings;
     $sugar_smarty = new Sugar_Smarty();
     $sugar_smarty->assign('mod', $mod_strings);
     $sugar_smarty->assign('APP', $app_strings);
     $connectors = ConnectorUtils::getConnectors(true);
     $sugar_smarty->assign('SOURCES', $connectors);
     echo get_module_title('Connectors', $mod_strings['LBL_MODIFY_MAPPING_PAGE_TITLE'], true);
     $sugar_smarty->display('modules/Connectors/tpls/modify_mapping.tpl');
 }
开发者ID:klr2003,项目名称:sourceread,代码行数:13,代码来源:view.modifymapping.php

示例13: display

 function display()
 {
     echo "TESTING ONLY";
     $pm = new PatientMedList('123');
     $pm->GetMedsDB();
     echo "there";
     $sugarSmarty = new Sugar_Smarty();
     $sugarSmarty->assign("duration", $duration);
     $sugarSmarty->assign("med", $pm->medlist);
     $sugarSmarty->assign("patid", $pm->patid);
     $sugarSmarty->assign("title", "Test med");
     $sugarSmarty->display('custom/modules/REG_Patient/tpls/testmed.tpl');
     //        parent::display();
 }
开发者ID:apikck,项目名称:REG_Patient,代码行数:14,代码来源:view.testmed.php

示例14: display

 function display()
 {
     //$provlist = Array();
     $smarty = new Sugar_Smarty();
     //parent::display();
     $db = DBManagerFactory::getInstance();
     $queryprov = "SELECT p1b.id provid, p1b.name provname  from reg_provider p1b ORDER BY provname";
     $sql = $db->query($queryprov);
     while (($a = $db->fetchByAssoc($sql)) != null) {
         $provlist[] = array("provid" => $a["provid"], "provname" => $a["provname"]);
     }
     echo "here";
     $smarty->assign("provlist", $provlist);
     $smarty->display('custom/modules/REG_Patient/tpls/ReportMain.tpl');
 }
开发者ID:apikck,项目名称:REG_Patient,代码行数:15,代码来源:view.reportmain.php

示例15: display

 function display()
 {
     $smarty = new Sugar_Smarty();
     parent::display();
     $db = DBManagerFactory::getInstance();
     //$myquery = 'SELECT tab4.first_name fname, tab4.last_name lname,  tab5.mrn_c mrn, tab4.id patid, tab5.location_c location, tab5.active_c active, ( SELECT tab1.reg_patient_reg_encounterreg_encounter_idb enclink  FROM reg_patient_reg_encounter_c tab1 WHERE  tab1.reg_patient_reg_encounterreg_patient_ida = patid AND tab1.date_modified = (SELECT max( date_modified ) dat FROM reg_patient_reg_encounter_c enc1 WHERE  enc1.reg_patient_reg_encounterreg_patient_ida = patid) )  enclink, ( SELECT DATE_FORMAT(tab3.next_rx_refill_due_c,"%m/%d/%Y") ref1 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink )  refill,  ( SELECT DATE_FORMAT(tab3.last_uts_c,"%m/%d/%Y") uts1 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink ) last_uts , ( SELECT DATE_FORMAT(tab3.next_uts_due_c,"%m/%d/%Y") uts11 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink )  uts ,  (SELECT DATE_FORMAT(tab3.next_pcp_visit_c,"%m/%d/%Y") pcp11 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink )  next_pcp,  (SELECT p1b.name provname  from reg_provider p1b, reg_provider_reg_patient_c p2b  WHERE p2b.reg_provider_reg_patientreg_provider_ida = p1b.id  AND p2b.reg_provider_reg_patientreg_patient_idb = patid) provname, ( SELECT risklvl_c risk1 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink )  risk FROM reg_patient tab4, reg_patient_cstm tab5, reg_patient_reg_encounter_c tab1, ( SELECT max( date_modified ) dat, reg_patient_reg_encounterreg_patient_ida pat FROM reg_patient_reg_encounter_c GROUP BY reg_patient_reg_encounterreg_patient_ida) tab2, reg_encounter_cstm tab3 WHERE  tab5.id_c = tab4.id  AND tab1.date_modified = tab2.dat AND tab1.reg_patient_reg_encounterreg_patient_ida = tab2.pat AND tab3.id_c = tab1.reg_patient_reg_encounterreg_encounter_idb  AND tab4.id = tab2.pat';
     $myquery = 'SELECT tab4.first_name fname, tab4.last_name lname,  tab5.mrn_c mrn, tab4.id patid, tab5.location_c location, tab5.active_c active, ( SELECT tab1.reg_patient_reg_encounterreg_encounter_idb enclink  FROM reg_patient_reg_encounter_c tab1 WHERE  tab1.reg_patient_reg_encounterreg_patient_ida = patid AND tab1.date_modified = (SELECT max( date_modified ) dat FROM reg_patient_reg_encounter_c enc1 WHERE  enc1.reg_patient_reg_encounterreg_patient_ida = patid) )  enclink, ( SELECT DATE_FORMAT(tab3.next_rx_refill_due_c,"%m/%d/%Y") ref1 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink )  refill,  ( SELECT DATE_FORMAT(tab3.last_uts_c,"%m/%d/%Y") uts1 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink ) last_uts , ( SELECT DATE_FORMAT(tab3.next_uts_due_c,"%m/%d/%Y") uts11 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink )  uts ,  (SELECT DATE_FORMAT(tab3.next_pcp_visit_c,"%m/%d/%Y") pcp11 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink )  next_pcp,  (SELECT p1b.name provname  from reg_provider p1b, reg_provider_reg_patient_c p2b  WHERE p2b.reg_provider_reg_patientreg_provider_ida = p1b.id  AND p2b.reg_provider_reg_patientreg_patient_idb = patid) provname, ( SELECT risklvl_c risk1 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink )  risk FROM reg_patient tab4, reg_patient_cstm tab5 WHERE  tab5.id_c = tab4.id ';
     $result = $db->query($myquery);
     $mydata = null;
     while ($row = $db->fetchRow($result)) {
         $mydata[] = $row;
     }
     global $cal_strings, $current_language;
     $cal_strings = return_module_language($current_language, 'Calendar');
     if (empty($_REQUEST['view'])) {
         $_REQUEST['view'] = SugarConfig::getInstance()->get('calendar.default_view', 'week');
     }
     $cal = new Calendar($_REQUEST['view']);
     if (in_array($cal->view, array('day', 'week', 'month'))) {
         $cal->add_activities($GLOBALS['current_user']);
     } else {
         if ($cal->view == 'shared') {
             $cal->init_shared();
             global $shared_user;
             $shared_user = new User();
             foreach ($cal->shared_ids as $member) {
                 $shared_user->retrieve($member);
                 $cal->add_activities($shared_user);
             }
         }
     }
     if (in_array($cal->view, array("day", "week", "month", "shared"))) {
         $cal->load_activities();
     }
     if (!empty($_REQUEST['print']) && $_REQUEST['print'] == 'true') {
         $cal->setPrint(true);
     }
     $display = new CalendarDisplay($cal);
     $smarty->assign("mydata", $mydata);
     echo "<table><tr><td>";
     $smarty->display($this->lv->tpl);
     echo "</td>";
     echo "<td style='width:100%;vertical-align:top'>";
     $caltest = new caltest();
     $caltest->test();
     echo "</td></tr></table>";
 }
开发者ID:apikck,项目名称:REG_Patient,代码行数:47,代码来源:view.toplist.php


注:本文中的Sugar_Smarty::display方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。