本文整理汇总了PHP中ViewList::display方法的典型用法代码示例。如果您正苦于以下问题:PHP ViewList::display方法的具体用法?PHP ViewList::display怎么用?PHP ViewList::display使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ViewList
的用法示例。
在下文中一共展示了ViewList::display方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: display
function display()
{
if (isset($_REQUEST['close_window'])) {
echo "<script>window.close();</script>";
}
parent::display();
}
示例2: display
public function display()
{
global $current_user;
if (!$current_user->is_admin) {
sugar_die(translate("LBL_MUST_BE_ADMIN"));
}
parent::display();
}
示例3: display
function display()
{
global $mod_strings;
$javascript = <<<EOF
<script>
</script>
EOF;
echo $javascript;
parent::display();
}
示例4: 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>";
}
示例5: display
function display()
{
parent::display();
echo '<div id="map_div" style="display:none;position:fixed;width:100%; height:95%;padding:0;top:0px;left:0px;z-index:100;">';
$map_html = '<style>';
$map_html .= ' .ui-autocomplete {';
$map_html .= ' background-color: white;';
$map_html .= ' width: 300px;';
$map_html .= ' border: 1px solid #cfcfcf;';
$map_html .= ' list-style-type: none;';
$map_html .= ' padding-left: 0px;}';
$map_html .= ' </style>';
$map_html .= ' <input id="address" type="hidden"/>';
$map_html .= ' <div id="map_canvas" style="width:100%; height:100%; border: 1px solid; margin:0;"></div></div>';
echo $map_html;
// echo('<div type="button" id="map_knopke" value="Карта Google" title="Карта Google" style="position:fixed; top:200px;right: 0px;z-index:200;width:1em; line-height:1em;border:1px solid black;background-color:#58b;opacity:0.6;-moz-opacity:0.6;color:white;font-weight:bold;padding:3px;cursor:pointer;">К А Р Т А G O O G L E</div>');
echo '<div type="button" id="map_knopke" value="Карта Google" title="Карта Google" style="
position:fixed;
top:250px;
right: -37px;
z-index:200;
line-height:1em;
border:1px solid black;
background-color:#356B83;
background-image:linear-gradient(to bottom, #609EB9, #356B83);
border-color: #356B83 #356B83 #002A80;
transform: rotate(90deg);
-webkit-transform: rotate(90deg);
-o-transform: rotate(90deg);
-ms-transform: rotate(90deg);
color:white;
padding:5px;
font-size: 15px;
border-radius: 3px;
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.25);
cursor:pointer;">Карта Google</div>';
echo '<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>';
echo '<script type="text/javascript" src="https://google-maps-utility-library-v3.googlecode.com/svn/tags/infobox/1.1.11/src/infobox.js"></script>';
echo "<script src='custom/modules/Realty/js/listview.js'></script>";
}
示例6: display
function display()
{
$smarty = new Sugar_Smarty();
parent::display();
$db = DBManagerFactory::getInstance();
$myquery = 'SELECT tab4.first_name fname, tab4.last_name lname, tab1.date_modified, tab3.next_rx_refill_due_c refill, tab2.pat patid, tab5.mrn_c mrn FROM 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, reg_patient tab4, reg_patient_cstm tab5 WHERE 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 AND tab5.id_c = tab4.id UNION SELECT tab4a.first_name fname, tab4a.last_name lname, null datemod, null refill, tab4a.id patid, tab5a.mrn_c mrn FROM reg_patient tab4a , reg_patient_cstm tab5a where tab4a.id not in (select reg_patient_reg_encounterreg_patient_ida pat FROM reg_patient_reg_encounter_c )and tab4a.id = tab5a.id_c ORDER BY refill DESC';
if ($_POST['mysort'] == 'week') {
$myquery = 'SELECT tab4.first_name fname, tab4.last_name lname, tab1.date_modified, tab3.next_rx_refill_due_c refill, tab2.pat patid, tab5.mrn_c mrn FROM 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, reg_patient tab4, reg_patient_cstm tab5 WHERE 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 AND tab5.id_c = tab4.id AND tab3.next_rx_refill_due_c BETWEEN NOW() AND DATE_ADD(NOW(), INTERVAL 7 DAY) ';
}
$result = $db->query($myquery);
while ($row = $db->fetchRow($result)) {
$mydata[] = $row;
}
$smarty->assign("mydata", $mydata);
$db1 = DBManagerFactory::getInstance();
$provquery = 'SELECT p1b.name provname from reg_provider p1b';
$resultprov = $db1->query($provquery);
while ($provrow = $db1->fetchRow($resultprov)) {
$provdata[] = $provrow;
}
$smarty->assign("provdata", $provdata);
$smarty->display($this->lv->tpl);
}
示例7: display
public function display()
{
$GLOBALS['log']->info("JrMis_DepartmentsViewList.display");
$GLOBALS['log']->debug("JrMis_DepartmentsViewList.display, this: " . print_r($this, TRUE));
global $app_list_strings;
$province_list = array();
$city_list = array();
$province_list[''] = '';
$province_list = array_merge($province_list, $app_list_strings['jrmis_province_list']);
$city_list[''] = '';
$GLOBALS['log']->debug("JrMis_DepartmentsViewList.display, city_list: " . print_r($city_list, TRUE));
$this->ss->assign('PROVINCE_LIST', $province_list);
$this->ss->assign('CITY_LIST', $city_list);
parent::display();
}
示例8: automessage
function display()
{
global $mod_strings, $sugar_config;
$bean = BeanFactory::getBean('xeBayAccounts');
$ebay_account_options = "<select name='ebay_account_name' id='ebay_account_name' title=''>";
$resp = $bean->get_list("", "ebay_auth_token<>''", 0, -1, -1, 0, false, array('name'));
if ($resp['row_count'] > 0) {
$ebay_account_options = "<select name='ebay_account_name' id='ebay_account_name' title=''>";
if ($resp['row_count'] > 1) {
$ebay_account_options .= "<option value='All'>All</option>";
}
foreach ($resp['list'] as &$account) {
$name = $account->name;
$ebay_account_options .= "<option value='{$name}'>{$name}</option>";
}
}
$ebay_account_options .= "</select>";
$express_carrier_options = get_select_options_with_id(getExpressCarrierDropDown(), isset($sugar_config['ebay_express_carrier']) ? $sugar_config['ebay_express_carrier'] : 'default');
$shortcuts_unhandled = <<<EOF
<script>
var OO = {};
OO.get = YAHOO.util.Dom.get;
OO.importorderDialog = false;\t
OO.toggle_importorder = function (){
\tvar sd = OO.get("importorder_dialog");
\tif(!OO.importorderDialog){\t
\t\tOO.importorderDialog = new YAHOO.widget.Dialog("importorder_dialog",{
\t\t\t \tfixedcenter: true,
\t\t\t \tdraggable: false,
\t\t\t \tvisible : false,
\t\t\t \tmodal : true,
\t\t\t \tclose: true
\t\t});
\t\tvar listeners = new YAHOO.util.KeyListener(document, { keys : 27 }, {fn: function() { OO.importorderDialog.cancel();} } );
\t\tOO.importorderDialog.cfg.queueProperty("keylisteners", listeners);
\t}
\tOO.importorderDialog.cancelEvent.subscribe(function(e, a, o){
\t\tOO.get("form_importorder").reset();
\t});
\tsd.style.display = "block";\t
\tOO.importorderDialog.render();
\tOO.importorderDialog.show();
}
OO.printallDialog = false;\t
OO.toggle_printall = function (){
\tvar sd = OO.get("printall_dialog");
\tif(!OO.printallDialog){\t
\t\tOO.printallDialog = new YAHOO.widget.Dialog("printall_dialog",{
\t\t\t \tfixedcenter: true,
\t\t\t \tdraggable: false,
\t\t\t \tvisible : false,
\t\t\t \tmodal : true,
\t\t\t \tclose: true
\t\t});
\t\tvar listeners = new YAHOO.util.KeyListener(document, { keys : 27 }, {fn: function() { OO.printallDialog.cancel();} } );
\t\tOO.printallDialog.cfg.queueProperty("keylisteners", listeners);
\t}
\tOO.printallDialog.cancelEvent.subscribe(function(e, a, o){
\t\tOO.get("form_printall").reset();
\t});
\tsd.style.display = "block";\t
\tOO.printallDialog.render();
\tOO.printallDialog.show();
}
OO.exportallDialog = false;\t
OO.toggle_exportall = function (){
\tvar sd = OO.get("exportall_dialog");
\tif(!OO.exportallDialog){\t
\t\tOO.exportallDialog = new YAHOO.widget.Dialog("exportall_dialog",{
\t\t\t \tfixedcenter: true,
\t\t\t \tdraggable: false,
\t\t\t \tvisible : false,
\t\t\t \tmodal : true,
\t\t\t \tclose: true
\t\t});
\t\tvar listeners = new YAHOO.util.KeyListener(document, { keys : 27 }, {fn: function() { OO.exportallDialog.cancel();} } );
\t\tOO.exportallDialog.cfg.queueProperty("keylisteners", listeners);
\t}
\tOO.exportallDialog.cancelEvent.subscribe(function(e, a, o){
\t\tOO.get("form_exportall").reset();
\t});
\tsd.style.display = "block";\t
\tOO.exportallDialog.render();
\tOO.exportallDialog.show();
}
OO.completeallDialog = false;\t
OO.toggle_completeall = function (){
\tvar sd = OO.get("completeall_dialog");
\tif(!OO.completeallDialog){\t
\t\tOO.completeallDialog = new YAHOO.widget.Dialog("completeall_dialog",{
\t\t\t \tfixedcenter: true,
\t\t\t \tdraggable: false,
\t\t\t \tvisible : false,
\t\t\t \tmodal : true,
\t\t\t \tclose: true
\t\t});
\t\tvar listeners = new YAHOO.util.KeyListener(document, { keys : 27 }, {fn: function() { OO.completeallDialog.cancel();} } );
\t\tOO.completeallDialog.cfg.queueProperty("keylisteners", listeners);
\t}
\tOO.completeallDialog.cancelEvent.subscribe(function(e, a, o){
//.........这里部分代码省略.........
示例9: display
public function display()
{
parent::display();
}
示例10: display
function display()
{
global $mod_strings, $sugar_config;
$bean = BeanFactory::getBean('xeBayAccounts');
$ebay_account_options = "<select name='ebay_account_name' id='ebay_account_name' title=''>";
$resp = $bean->get_list("", "ebay_auth_token<>''", 0, -1, -1, 0, false, array('name'));
if ($resp['row_count'] > 0) {
$ebay_account_options = "<select name='ebay_account_name' id='ebay_account_name' title=''>";
if ($resp['row_count'] > 1) {
$ebay_account_options .= "<option value='All'>All</option>";
}
foreach ($resp['list'] as &$account) {
$name = $account->name;
$ebay_account_options .= "<option value='{$name}'>{$name}</option>";
}
}
$ebay_account_options .= "</select>";
$shortcuts = <<<EOF
<script>
var OO = {};
OO.get = YAHOO.util.Dom.get;
OO.checkDialog = false;\t
OO.toggle_check = function (){
\tvar sd = OO.get("check_dialog");
\tif(!OO.checkDialog){\t
\t\tOO.checkDialog = new YAHOO.widget.Dialog("check_dialog",{
\t\t\t \tfixedcenter: true,
\t\t\t \tdraggable: false,
\t\t\t \tvisible : false,
\t\t\t \tmodal : true,
\t\t\t \tclose: true
\t\t});
\t\tvar listeners = new YAHOO.util.KeyListener(document, { keys : 27 }, {fn: function() { OO.checkDialog.cancel();} } );
\t\tOO.checkDialog.cfg.queueProperty("keylisteners", listeners);
\t}
\tOO.checkDialog.cancelEvent.subscribe(function(e, a, o){
\t\tOO.get("form_check").reset();
\t});
\tsd.style.display = "block";\t
\tOO.checkDialog.render();
\tOO.checkDialog.show();
}
</script>
<div id="check_dialog" style="width: 450px; display: none;">
\t<div class="hd">{$mod_strings['LBL_CHECK_TITLE']}</div>
\t<div class="bd">
\t<form name="check" id="form_check" method="POST" action="index.php?module=xeBayMessages&action=check">
\t\t<table class='edit view tabForm'>
\t\t\t<tr>
\t\t\t\t<td scope="row" valign="top" width="55%">
\t\t\t\t\t{$mod_strings['LBL_EBAY_ACCOUNT']}
\t\t\t\t</td>
\t\t\t\t<td width="45%">\t
\t\t\t\t\t<input type="hidden" name="ebay_account_name" value="">{$ebay_account_options}
\t\t\t\t</td>
\t\t\t</tr>
\t\t\t<tr>
\t\t\t\t<td scope="row" valign="top">
\t\t\t\t\t{$mod_strings['LBL_NUMBER_OF_DAYS']}
\t\t\t\t</td>
\t\t\t\t<td>\t
\t\t\t\t\t<input type="hidden" name="number_of_days" value="">
\t\t\t <select name='number_of_days' id='number_of_days' title=''>
\t\t\t\t <option value='1'>1</option>
\t\t\t\t <option value='2' selected>2</option>
\t\t\t\t <option value='3'>3</option>
\t\t\t\t <option value='5'>5</option>
\t\t\t\t <option value='7'>7</option>
\t\t\t\t <option value='15'>15</option>
\t\t\t\t <option value='30'>30</option>
\t\t\t\t <option value='90'>90</option>
\t\t\t </select>
\t\t\t\t</td>
\t\t\t</tr>
\t\t\t<tr>
\t\t\t\t<td scope="row" valign="top">
\t\t\t\t\t{$mod_strings['LBL_MESSAGE_STATUS']}
\t\t\t\t</td>
\t\t\t\t<td>\t
\t\t\t\t\t<input type="hidden" name="message_status" value="">
\t\t\t <select name='message_status' id='message_status' title=''>
\t\t\t\t <option value=''></option>
\t\t\t\t <option value='Unanswered' selected>{$mod_strings['LBL_UNANSWERED']}</option>
\t\t\t\t <option value='Answered'>{$mod_strings['LBL_ANSWERED']}</option>
\t\t\t </select>
\t\t\t\t</td>
\t\t\t</tr>
\t\t</table>
\t</form>
\t<div style="text-align: right;">
\t\t<button id="btn-save-checkDialog" class="button" type="button" onclick="OO.get('form_check').submit()">{$mod_strings['LBL_APPLY_BUTTON']}</button>
\t\t<button id="btn-cancel-checkDialog" class="button" type="button" onclick="OO.checkDialog.cancel()">{$mod_strings['LBL_CANCEL_BUTTON']}</button>
\t</div>
\t</div>
</div>
<input title="{$mod_strings['LBL_CHECK_TIPS']}" class="button" type="submit" name="button" value="{$mod_strings['LBL_CHECK']}" id="check_btn" onclick="OO.toggle_check()">
<br/>
<br/>
EOF;
//.........这里部分代码省略.........
示例11: display
function display()
{
$smarty = new Sugar_Smarty();
parent::display();
$db = DBManagerFactory::getInstance();
$myquery = 'SELECT tab4.first_name fname, tab4.last_name lname, tab1.date_modified, tab3.next_rx_refill_due_c refill, tab2.pat patid, tab5.mrn_c mrn FROM 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, reg_patient tab4, reg_patient_cstm tab5 WHERE 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 AND tab5.id_c = tab4.id UNION SELECT tab4a.first_name fname, tab4a.last_name lname, null datemod, null refill, tab4a.id patid, tab5a.mrn_c mrn FROM reg_patient tab4a , reg_patient_cstm tab5a where tab4a.id not in (select reg_patient_reg_encounterreg_patient_ida pat FROM reg_patient_reg_encounter_c )and tab4a.id = tab5a.id_c ORDER BY refill DESC';
$select_base = 'SELECT tab4.first_name fname, tab4.last_name lname, tab5.mrn_c mrn, tab4.id patid ';
$from_base = ' FROM reg_patient tab4, reg_patient_cstm tab5';
$where_base = ' WHERE tab5.id_c = tab4.id ';
$select_refill = ' , DATE_FORMAT(tab3.next_rx_refill_due_c,"%m/%d/%Y") refill, DATE_FORMAT(tab3.next_uts_due_c,"%m/%d/%Y") uts ';
$from_refill = ' , 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_refill = ' 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 ';
$select_norefill = ', ( 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.next_uts_due_c,"%m/%d/%Y") uts11 FROM reg_encounter_cstm tab3 where tab3.id_c = enclink ) uts ';
$select_noprovider = ', (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_provider = ' ,p1b.name provname';
$from_provider = ' ,reg_provider p1b, reg_provider_reg_patient_c p2b ';
$where_provider = ' AND p2b.reg_provider_reg_patientreg_provider_ida = p1b.id AND p2b.reg_provider_reg_patientreg_patient_idb = tab4.id ';
$testselect = $select_base;
$testfrom = $from_base;
$testwhere = $where_base;
//when week filter need to add week interval
//when provfilter need to add prov
//if ($_POST['mysort'] == 'week')
if (!empty($_POST['mysort']) and $_POST['mysort'] != 'all' and $_POST['mysort'] != 'none') {
$testselect .= $select_refill;
$testfrom .= $from_refill;
if ($_POST['mysort'] != 'cust') {
$testwhere .= $where_refill . ' AND tab3.next_rx_refill_due_c BETWEEN NOW() AND DATE_ADD(NOW(), INTERVAL ' . $_POST['mysort'] . ' DAY) ';
} else {
$testwhere .= $where_refill . ' AND tab3.next_rx_refill_due_c BETWEEN str_to_date("' . $_POST['last_pcp_visit_c1'] . '", "%m/%d/%Y") AND str_to_date("' . $_POST['last_pcp_visit_c2'] . '", "%m/%d/%Y") ';
}
} else {
$testselect .= $select_norefill;
}
if (!empty($_POST['provsort']) and $_POST['provsort'] != "none") {
$testselect .= $select_provider;
$testfrom .= $from_provider;
$testwhere .= $where_provider . " AND p1b.name = '" . $_POST['provsort'] . "' ";
} else {
$testselect .= $select_noprovider;
}
$testquery = $testselect . $testfrom . $testwhere . ' ORDER BY refill DESC, provname ASC';
//var_dump($testquery);
//$myquery = 'SELECT tab4.first_name fname, tab4.last_name lname, tab1.date_modified, DATE_FORMAT(tab3.next_rx_refill_due_c,"%m/%d/%Y") refill, tab2.pat patid, tab5.mrn_c mrn, p1b.name provname FROM 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, reg_patient tab4, reg_patient_cstm tab5, reg_provider p1b, reg_provider_reg_patient_c p2b WHERE 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 AND tab5.id_c = tab4.id AND p2b.reg_provider_reg_patientreg_provider_ida = p1b.id AND p2b.reg_provider_reg_patientreg_patient_idb = tab4.id ';
//if ($_POST['mysort'] == 'week') $myquery.= ' AND tab3.next_rx_refill_due_c BETWEEN NOW() AND DATE_ADD(NOW(), INTERVAL 60 DAY) ';
//if (!empty($_POST['provsort']) AND $_POST['provsort'] != "none") $myquery.= " AND p1b.name = '" . $_POST['provsort'] . "' ";
//var_dump($_POST);
//var_dump($myquery);
$result = $db->query($testquery);
$mydata[] = "";
while ($row = $db->fetchRow($result)) {
$mydata[] = $row;
}
$smarty->assign("mydata", $mydata);
//query for all providers
$db1 = DBManagerFactory::getInstance();
$provquery = 'SELECT p1b.name provname from reg_provider p1b';
$resultprov = $db1->query($provquery);
$provdata[] = "";
while ($provrow = $db1->fetchRow($resultprov)) {
$provdata[] = $provrow;
}
$smarty->assign("provdata", $provdata);
$smarty->display($this->lv->tpl);
}
示例12: display
public function display()
{
parent::display();
$this->seed->displayCronInstructions();
}
示例13: display
function display()
{
global $mod_strings, $sugar_config;
$shortcuts = <<<EOF
<script>
var OO = {};
OO.get = YAHOO.util.Dom.get;
OO.importlistDialog = false;\t
OO.toggle_importlist = function (){
\tvar sd = OO.get("importlist_dialog");
\tif(!OO.importlistDialog){\t
\t\tOO.importlistDialog = new YAHOO.widget.Dialog("importlist_dialog",{
\t\t\t \tfixedcenter: true,
\t\t\t \tdraggable: false,
\t\t\t \tvisible : false,
\t\t\t \tmodal : true,
\t\t\t \tclose: true
\t\t});
\t\tvar listeners = new YAHOO.util.KeyListener(document, { keys : 27 }, {fn: function() { OO.importlistDialog.cancel();} } );
\t\tOO.importlistDialog.cfg.queueProperty("keylisteners", listeners);
\t}
\tOO.importlistDialog.cancelEvent.subscribe(function(e, a, o){
\t\tOO.get("form_importlist").reset();
\t});
\tsd.style.display = "block";\t
\tOO.importlistDialog.render();
\tOO.importlistDialog.show();
}
</script>
<div id="importlist_dialog" style="width: 450px; display: none;">
\t<div class="hd">{$mod_strings['LBL_IMPORT_TITLE']}</div>
\t<div class="bd">
\t<form name="importlist" id="form_importlist" method="POST" action="index.php?module=xeBaySellerSurveys&action=importlist">
\t\t<table class='edit view tabForm'>
\t\t\t<tr>
\t\t\t\t<td scope="row" valign="top" width="25%">
\t\t\t\t\t{$mod_strings['LBL_EBAY_ACCOUNT']}
\t\t\t\t</td>
\t\t\t\t<td width="45%">
\t\t\t\t\t<input type="text" name="user_id" id="user_id" value="" />
\t\t\t\t</td>
\t\t\t</tr>
\t\t</table>
\t</form>
\t<div style="text-align: right;">
\t\t<button id="btn-save-importlistDialog" class="button" type="button" onclick="OO.get('form_importlist').submit()">{$mod_strings['LBL_APPLY_BUTTON']}</button>
\t\t<button id="btn-cancel-importlistDialog" class="button" type="button" onclick="OO.importlistDialog.cancel()">{$mod_strings['LBL_CANCEL_BUTTON']}</button>
\t</div>
\t</div>
</div>
<input title="{$mod_strings['LBL_IMPORT_TIPS']}" class="button" type="submit" name="button" value="{$mod_strings['LBL_IMPORT']}" id="import_order" onclick="OO.toggle_importlist()">
<br/>
<br/>
EOF;
// echo $shortcuts;
parent::display();
}
示例14: testdisplay
public function testdisplay()
{
$view = new ViewList();
//test without setting bean attibute. it shuold return no access html.
ob_start();
$view->display();
$renderedContent1 = ob_get_contents();
ob_end_clean();
$this->assertGreaterThan(0, strlen($renderedContent1));
//test with bean, seed and other arrtibutes set. it shuold return html.
$view->bean = new User();
$view->seed = new User();
$view->module = 'Users';
$view->prepareSearchForm();
$view->preDisplay();
ob_start();
$view->display();
$renderedContent2 = ob_get_contents();
ob_end_clean();
$this->assertGreaterThan(0, strlen($renderedContent2));
}
示例15: display
function display()
{
echo '<form method="POST" action="index.php?module=REG_Patient&action=topcare">Choose an option to filter: <select name="mysort" onchange="this.form.submit()"><option value="none"></option><option value="all">All Refills</option><option value="week">Next Seven Days</option></select></form>';
parent::display();
}