本文整理汇总了PHP中get_test_name_by_id函数的典型用法代码示例。如果您正苦于以下问题:PHP get_test_name_by_id函数的具体用法?PHP get_test_name_by_id怎么用?PHP get_test_name_by_id使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了get_test_name_by_id函数的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: array
$existing_stat_list = array();
$testName = null;
for ($i = 0; $i < count($lab_config_id_array); $i++) {
$labIdTestTypeIdSeparated = explode(":", $lab_config_id_array[$i]);
$lab_config_id = $labIdTestTypeIdSeparated[0];
$test_type_id = $labIdTestTypeIdSeparated[1];
$retval = StatsLib::getDiscreteInfectionStatsAggregate($lab_config_id, $date_from, $date_to, $test_type_id);
$existing_stat_list = $stat_list;
$stat_list = array_merge($existing_stat_list, $retval);
$lab_config = LabConfig::getById($lab_config_id);
$labName = $lab_config->name;
$labNamesArray[] = $labName;
getWeeklyStats($lab_config, $test_type_id, $date_from, $date_to);
if (!$testName) {
$saved_db = DbUtil::switchToLabConfig($lab_config_id);
$testName = get_test_name_by_id($test_type_id);
DbUtil::switchRestore($saved_db);
}
if (count($stat_list) == 0) {
?>
<div class='sidetip_nopos'>
<?php
echo LangUtil::$pageTerms['TIPS_NODISCRETE'];
?>
</div>
<?php
include "includes/footer.php";
return;
}
}
echo LangUtil::$generalTerms['TEST_TYPE'] . ": " . $testName . "<br>";
开发者ID:caseyi,项目名称:BLIS,代码行数:31,代码来源:process_aggregation.php
示例2: foreach
}
?>
</table>
<?php
}
?>
<br><br>
<?php
} else {
$bullet = 1;
foreach ($data_list as $key => $value) {
echo $bullet++;
?>
). <b>Test Name:</b>
<?php
echo get_test_name_by_id($key);
?>
<br><b>
Clinical Data:
</b>
<?php
if (stripos($value, "!#!") === 0) {
$data = substr($value, 3);
$dat = explode("%%%", $value);
$text = substr($dat[0], 3);
$table = $dat[1];
} else {
if (stripos($value, "%%%") === 0) {
$table = substr($value, 3);
$text = "";
} else {
开发者ID:caseyi,项目名称:BLIS,代码行数:31,代码来源:reports_testhistory2.php
示例3: explode
$date_from = $_REQUEST['date_from'];
$date_from_array = explode("-", $date_from);
$date_to_array = explode("-", $date_to);
$test_type = TestType::getById($test_type_id);
$lab_config = LabConfig::getById($_SESSION['lab_config_id']);
$worksheet_config = $lab_config->getWorkSheetConfig($test_type_id);
# Fetch all measures for this test type
$measure_list = $test_type->getMeasures();
# Create a table with specimen ID field and these measures
# Fetch currently pending tests for this test type
$pending_tests = get_pending_tests_by_type_date($test_type_id, $date_from, $date_to);
if (count($pending_tests) == 0 || $pending_tests == null) {
?>
<div class='sidetip_nopos'>
<?php
echo get_test_name_by_id($test_type_id) . " " . LangUtil::$pageTerms['MSG_PENDINGNOTFOUND'];
?>
.
</div>
<?php
return;
}
?>
<small><?php
echo count($pending_tests) . " " . LangUtil::$generalTerms['SPECIMENS'];
?>
</small><br>
<form id='batch_form' name='batch_form' action='results_batch_add.php' method='post'>
<?php
# Hidden field for tracking test type
?>
开发者ID:jfurlong,项目名称:BLIS,代码行数:31,代码来源:batch_results_form_fetch.php
示例4: round
if ($count_all != 0) {
$infection_rate = round(($count_all - $count_negative) / $count_all * 100, 2);
}
echo "d.push([{$x_val}*1000, {$infection_rate}]);";
$count++;
//$x_val += 2;
}
?>
});
</script>
<?php
if ($count != 0) {
?>
<center>
<?php
echo get_test_name_by_id($test_type_id);
?>
- <?php
echo LangUtil::$pageTerms['PROGRESSION_M'];
?>
</center>
<table>
<tbody>
<tr valign='top'>
<td>
<span id="<?php
echo $ylabel_id;
?>
" class='flipv_up' style="width:30px;height:30px;"><?php
echo LangUtil::$generalTerms['MENU_INFECTIONSUMMARY'];
?>
开发者ID:caseyi,项目名称:BLIS,代码行数:31,代码来源:monthly_prevalance.php
示例5: getDiscreteInfectionStatsAggregate
public static function getDiscreteInfectionStatsAggregate($lab_config_id, $date_from, $date_to, $test_type_id)
{
$retval = array();
#All Tests & All Labs
if ($test_type_id == 0 && $lab_config_id == 0) {
$site_list = get_site_list($_SESSION['user_id']);
$userId = $_SESSION['user_id'];
$saved_db = DbUtil::switchToGlobal();
$query = "SELECT * FROM test_mapping WHERE user_id = {$userId}";
$resultset = query_associative_all($query, $row_count);
foreach ($resultset as $record) {
$labIdTestIds = explode(';', $record['lab_id_test_id']);
foreach ($labIdTestIds as $labIdTestId) {
$labIdTestId = explode(':', $labIdTestId);
$labId = $labIdTestId[0];
$testId = $labIdTestId[1];
$test_type_list_all[$labId][] = $testId;
$test_type_names[$labId][] = $record['test_name'];
}
}
DbUtil::switchRestore($saved_db);
foreach ($site_list as $key => $value) {
$lab_config = LabConfig::getById($key);
$test_type_list = array();
$test_type_list = $test_type_list_all[$key];
$testNames = $test_type_names[$key];
$saved_db = DbUtil::switchToLabConfig($lab_config->id);
$testCount = -1;
# For each test type, fetch negative records
foreach ($test_type_list as $test_type_id) {
$query_string = "SELECT COUNT(*) AS count_val FROM test t, specimen s " . "WHERE t.test_type_id={$test_type_id} " . "AND t.specimen_id=s.specimen_id " . "AND ( s.date_collected BETWEEN '{$date_from}' AND '{$date_to}' ) " . "AND (result LIKE 'N,%' OR result LIKE 'n�gatif,%' OR result LIKE 'negatif,%' OR result LIKE 'n,%' OR result LIKE 'negative,%')";
$record = query_associative_one($query_string);
$count_negative = intval($record['count_val']);
$query_string = "SELECT COUNT(*) AS count_val FROM test t, specimen s " . "WHERE t.test_type_id={$test_type_id} " . "AND t.specimen_id=s.specimen_id " . "AND result!=''" . "AND ( s.date_collected BETWEEN '{$date_from}' AND '{$date_to}' )";
$record = query_associative_one($query_string);
$count_all = intval($record['count_val']);
$testCount++;
# If total tests is 0, ignore
if ($count_all == 0) {
continue;
}
$testName = $testNames[$testCount];
if (!array_key_exists($testName, $retval)) {
$retval[$testName] = array($count_all, $count_negative);
} else {
$count_all += intval($retval[$testName][0]);
$count_negative += intval($retval[$testName][1]);
$retval[$testName] = array($count_all, $count_negative);
}
}
}
DbUtil::switchRestore($saved_db);
return $retval;
} else {
if ($test_type_id == 0 && count($lab_config_id) == 1) {
$lab_config = LabConfig::getById($lab_config_id[0]);
$retvalues = StatsLib::getDiscreteInfectionStats($lab_config, $date_from, $date_to);
$saved_db = DbUtil::switchToLabConfig($lab_config->id);
foreach ($retvalues as $key => $value) {
$testName = get_test_name_by_id($key);
$retval[$testName] = $value;
}
DbUtil::switchRestore($saved_db);
return $retval;
} else {
if ($test_type_id == 0 && count($lab_config_id) > 1) {
$userId = $_SESSION['user_id'];
$saved_db = DbUtil::switchToGlobal();
$query = "SELECT * FROM test_mapping WHERE user_id = {$userId}";
$resultset = query_associative_all($query, $row_count);
foreach ($resultset as $record) {
$labIdTestIds = explode(';', $record['lab_id_test_id']);
foreach ($labIdTestIds as $labIdTestId) {
$labIdTestId = explode(':', $labIdTestId);
$labId = $labIdTestId[0];
$testId = $labIdTestId[1];
$test_type_list_all[$labId][] = $testId;
$test_type_names[$labId][] = $record['test_name'];
}
}
DbUtil::switchRestore($saved_db);
foreach ($lab_config_id as $key) {
$lab_config = LabConfig::getById($key);
$test_type_list = array();
$test_type_list = $test_type_list_all[$key];
$testNames = $test_type_names[$key];
$saved_db = DbUtil::switchToLabConfig($lab_config->id);
$testCount = -1;
# For each test type, fetch negative records
foreach ($test_type_list as $test_type_id) {
$query_string = "SELECT COUNT(*) AS count_val FROM test t, specimen s " . "WHERE t.test_type_id={$test_type_id} " . "AND t.specimen_id=s.specimen_id " . "AND ( s.date_collected BETWEEN '{$date_from}' AND '{$date_to}' ) " . "AND (result LIKE 'N,%' OR result LIKE 'n�gatif,%' OR result LIKE 'negatif,%' OR result LIKE 'n,%' OR result LIKE 'negative,%')";
$record = query_associative_one($query_string);
$count_negative = intval($record['count_val']);
$query_string = "SELECT COUNT(*) AS count_val FROM test t, specimen s " . "WHERE t.test_type_id={$test_type_id} " . "AND t.specimen_id=s.specimen_id " . "AND result!=''" . "AND ( s.date_collected BETWEEN '{$date_from}' AND '{$date_to}' )";
//echo($query_string);
$record = query_associative_one($query_string);
$count_all = intval($record['count_val']);
$testCount++;
# If total tests is 0, ignore
if ($count_all == 0) {
//.........这里部分代码省略.........
开发者ID:caseyi,项目名称:BLIS,代码行数:101,代码来源:stats_lib.php
示例6: foreach
?>
. <br><br>
<?php
if ($_SESSION['sid'] != 0) {
echo LangUtil::$generalTerms['SPECIMEN_ID'] . ": ";
$specimen->getAuxId();
echo "<br>";
}
//if($_SESSION['pnamehide'] == 0)
if ($_SESSION['user_level'] == $LIS_TECH_SHOWPNAME) {
echo LangUtil::$generalTerms['PATIENT'] . ": {$patient->name} ({$patient->sex} " . $patient->getAgeNumber() . ") <br>";
} else {
echo LangUtil::$generalTerms['GENDER'] . "/" . LangUtil::$generalTerms['AGE'] . ": {$patient->sex} /" . $patient->getAgeNumber() . "<br>";
}
foreach ($test_list as $test) {
$test_name = get_test_name_by_id($test->testTypeId);
echo "<b>{$test_name}</b> ";
if ($test->isPending() === true) {
echo LangUtil::$generalTerms['PENDING_RESULTS'];
} else {
echo $test->decodeResult();
}
echo "<br>";
}
?>
<br>
<a href='specimen_info.php?sid=<?php
echo $specimen_id;
?>
'><?php
echo LangUtil::$generalTerms['DETAILS'];
开发者ID:caseyi,项目名称:BLIS,代码行数:31,代码来源:result_add.php
示例7: getGetGoalTatTable
public function getGetGoalTatTable($lab_config_id)
{
# Returns HTML table showing existing goal TAT values
$lab_config = get_lab_config_by_id($lab_config_id);
$tat_list = $lab_config->getGoalTatValues();
?>
<table class='tablesorter' style='width:600px;'>
<thead>
<tr valign='top'>
<th><?php echo LangUtil::$generalTerms['TEST_TYPE']; ?></th>
<th><?php echo LangUtil::$generalTerms['TAT']; ?></th>
</tr>
</thead>
<tbody>
<?php
foreach($tat_list as $key=>$value)
{
?>
<tr valign='top'>
<td>
<?php
if($key != 0)
{
echo get_test_name_by_id($key, $lab_config_id);
}
else
{
echo LangUtil::$pageTerms['MSG_PENDINGTAT'];
}
?>
</td>
<td>
<?php
echo "$value ".LangUtil::$generalTerms['HOURS'];
/*
if($value < 24)
echo "$value hours";
else
{
$value_days = round($value/24, 2);
echo "$value_days days";
}
*/
?>
</td>
</tr>
<?php
}
?>
</tbody>
</table>
<?php
}
开发者ID:jfurlong,项目名称:BLIS,代码行数:53,代码来源:page_elemsdff.php
示例8: getAssociatedTests
public function getAssociatedTests()
{
if ($this->patientId == "") {
return " - ";
} else {
$query_string = "SELECT t.test_type_id FROM test t, specimen sp " . "WHERE t.result <> '' " . "AND t.specimen_id=sp.specimen_id " . "AND sp.patient_id={$this->patientId}";
$recordset = query_associative_all($query_string, $row_count);
foreach ($recordset as $record) {
$testName = get_test_name_by_id($record['test_type_id']);
$result .= $testName . "<br>";
}
return $result;
}
}
开发者ID:nchopra,项目名称:C4G-BLIS,代码行数:14,代码来源:db_lib.php
示例9: get_username_by_id
<b><?php
echo LangUtil::$generalTerms['REGD_BY'];
?>
</b>: <?php
echo get_username_by_id($specimen->userId);
?>
<br>
<b><?php
echo LangUtil::$generalTerms['TESTS'];
?>
</b>:
<br>
<?php
$test_list = get_tests_by_specimen_id($specimen_id);
foreach ($test_list as $test) {
echo get_test_name_by_id($test->testTypeId) . " :- <br>";
if ($test->isPending()) {
echo " " . LangUtil::$generalTerms['PENDING_RESULTS'];
} else {
echo " " . LangUtil::$generalTerms['ENTERED_BY'] . ": " . get_username_by_id($test->userId) . " on: " . $test->timestamp;
}
echo "<br>";
if ($test->isVerified()) {
echo " " . LangUtil::$generalTerms['VERIFIED_BY'] . ": " . get_username_by_id($test->verifiedBy) . " on: " . $test->getDateVerified();
} else {
echo " " . LangUtil::$generalTerms['PENDING_VER'];
}
echo "<br>";
if ($specimen->isReported()) {
echo " " . LangUtil::$generalTerms['REPORTED'] . ": " . $specimen->getDateReported();
echo "<br>";
开发者ID:nchopra,项目名称:C4G-BLIS,代码行数:31,代码来源:reports_specimenlog.php
示例10: foreach
<tbody>
<?php
$all_entries = $ust->getResultEntryLog($user_id, $lab_config_id, $date_from, $date_to);
foreach ($all_entries as $entry) {
?>
<tr>
<td>
<?php
$count++;
echo $count;
?>
</td>
<td>
<?php
$tname = get_test_name_by_id($entry->testTypeId);
if ($tname != '') {
echo $tname;
} else {
echo '-';
}
?>
</td>
<td>
<?php
if ($entry->testId != '') {
echo $entry->testId;
} else {
echo '-';
}
?>
开发者ID:caseyi,项目名称:BLIS,代码行数:31,代码来源:reports_user_stats_individual.php
示例11: get_custom_data_specimen_bytype
echo "<td>";
$custom_data = get_custom_data_specimen_bytype($specimen->specimenId, $custom_field->id);
if ($custom_data == null) {
echo "-";
} else {
$field_value = $custom_data->getFieldValueString($lab_config->id, 1);
if ($field_value == "" or $field_value == null) {
$field_value = "-";
}
echo $field_value;
}
echo "</td>";
}
}
if ($report_config->useTestName == 1) {
echo "<td>" . get_test_name_by_id($test->testTypeId) . "</td>";
}
if ($report_config->useComments == 1) {
echo "<td>";
echo $specimen->getComments();
echo "</td>";
}
if ($report_config->useReferredTo == 1) {
echo "<td>" . $specimen->getReferredToName() . "</td>";
}
if ($report_config->useReferredToHospital == 1) {
echo "<td>" . $specimen->getReferredFromName() . "</td>";
}
if ($report_config->useDoctor == 1) {
echo "<td>" . $specimen->getDoctor() . "</td>";
}
开发者ID:jfurlong,项目名称:BLIS,代码行数:31,代码来源:reports_dailyspecimens.php
示例12: processWeeklyTrends
function processWeeklyTrends($lab_config_id, $test_type_id, $date_from, $date_to, $test_name = null)
{
global $namesArray;
global $stat_list;
# All Tests & All Labs */
if ($test_type_id == 0 && $lab_config_id == 0) {
$site_list = get_site_list($_SESSION['user_id']);
$userId = $_SESSION['user_id'];
$saved_db = DbUtil::switchToGlobal();
$query = "SELECT * FROM test_mapping WHERE user_id = {$userId}";
$resultset = query_associative_all($query, $row_count);
foreach ($resultset as $record) {
$labIdTestIds = explode(';', $record['lab_id_test_id']);
foreach ($labIdTestIds as $labIdTestId) {
$labIdTestId = explode(':', $labIdTestId);
$labId = $labIdTestId[0];
$testId = $labIdTestId[1];
$test_type_list_all[$labId][] = $testId;
$test_type_names[$labId][] = $record['test_name'];
}
}
DbUtil::switchRestore($saved_db);
foreach ($site_list as $key => $value) {
$lab_config = LabConfig::getById($key);
$test_type_list = array();
$test_type_list = $test_type_list_all[$key];
$testNames = $test_type_names[$key];
$saved_db = DbUtil::switchToLabConfig($lab_config->id);
$testCount = -1;
foreach ($test_type_list as $test_type_id) {
$query_string = "SELECT COUNT(*) AS count_val FROM test t, specimen s " . "WHERE t.test_type_id={$test_type_id} " . "AND t.specimen_id=s.specimen_id " . "AND result!=''" . "AND ( s.date_collected BETWEEN '{$date_from}' AND '{$date_to}' )";
$record = query_associative_one($query_string);
$count_all = intval($record['count_val']);
$testCount++;
if ($count_all == 0) {
continue;
}
$namesArray[] = $lab_config->name . " - " . $testNames[$testCount];
getWeeklyStats($lab_config, $test_type_id, $date_from, $date_to);
}
}
} else {
if ($test_type_id == 0 && count($lab_config_id) == 1) {
$lab_config = LabConfig::getById($lab_config_id[0]);
$test_type_list = get_discrete_value_test_types($lab_config);
foreach ($test_type_list as $test_type_id) {
$namesArray[] = get_test_name_by_id($test_type_id, $lab_config_id[0]);
getWeeklyStats($lab_config, $test_type_id, $date_from, $date_to);
}
} else {
if ($test_type_id == 0 && count($lab_config_id) > 1) {
$userId = $_SESSION['user_id'];
$saved_db = DbUtil::switchToGlobal();
$query = "SELECT * FROM test_mapping WHERE user_id = {$userId}";
$resultset = query_associative_all($query, $row_count);
foreach ($resultset as $record) {
$labIdTestIds = explode(';', $record['lab_id_test_id']);
foreach ($labIdTestIds as $labIdTestId) {
$labIdTestId = explode(':', $labIdTestId);
$labId = $labIdTestId[0];
$testId = $labIdTestId[1];
$test_type_list_all[$labId][] = $testId;
$test_type_names[$labId][] = $record['test_name'];
}
}
DbUtil::switchRestore($saved_db);
foreach ($lab_config_id as $key) {
$lab_config = LabConfig::getById($key);
$test_type_list = array();
$test_type_list = $test_type_list_all[$key];
$testNames = $test_type_names[$key];
$saved_db = DbUtil::switchToLabConfig($lab_config->id);
$testCount = -1;
foreach ($test_type_list as $test_type_id) {
$query_string = "SELECT COUNT(*) AS count_val FROM test t, specimen s " . "WHERE t.test_type_id={$test_type_id} " . "AND t.specimen_id=s.specimen_id " . "AND result!=''" . "AND ( s.date_collected BETWEEN '{$date_from}' AND '{$date_to}' )";
$record = query_associative_one($query_string);
$count_all = intval($record['count_val']);
$testCount++;
if ($count_all == 0) {
continue;
}
$namesArray[] = $lab_config->name . " - " . $testNames[$testCount];
getWeeklyStats($lab_config, $test_type_id, $date_from, $date_to);
}
}
} else {
/* Build Array Map with Lab Id as Key and Test Id as corresponding Value */
$labIdTestIds = explode(";", $test_type_id);
$testIds = array();
foreach ($labIdTestIds as $labIdTestId) {
$labIdTestIdsSeparated = explode(":", $labIdTestId);
$labId = $labIdTestIdsSeparated[0];
$testId = $labIdTestIdsSeparated[1];
$testIds[$labId] = $testId;
}
# Particular Test & All Labs
if ($test_type_id != 0 && $lab_config_id == 0) {
$site_list = get_site_list($_SESSION['user_id']);
foreach ($site_list as $key => $value) {
$lab_config = LabConfig::getById($key);
//.........这里部分代码省略.........
开发者ID:jfurlong,项目名称:BLIS,代码行数:101,代码来源:report_prevalence_agg.php
示例13: processWeeklyTrends
function processWeeklyTrends($lab_config_id, $test_type_id, $date_from, $date_to, $test_name = null)
{
global $namesArray;
global $stat_list;
$lab_config = LabConfig::getById($lab_config_id[0]);
$test_type_list = get_discrete_value_test_types($lab_config);
foreach ($test_type_list as $test_type_id) {
$namesArray[] = get_test_name_by_id($test_type_id, $lab_config_id[0]);
getWeeklyStats($lab_config, $test_type_id, $date_from, $date_to);
}
}
开发者ID:caseyi,项目名称:BLIS,代码行数:11,代码来源:reports_infection.php
注:本文中的get_test_name_by_id函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论