forked from openemr/openemr
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
More complete support for activity flag in list_options table. (opene…
…mr#274) * More complete support for activity flag in list_options table. * Added more modules to previous commit.
- Loading branch information
1 parent
9f9409f
commit 894a2ab
Showing
72 changed files
with
200 additions
and
197 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ | |
* sl_eob_search.php. For automated (X12 835) remittance posting | ||
* see sl_eob_process.php. | ||
* | ||
* Copyright (C) 2005-2010 Rod Roark <[email protected]> | ||
* Copyright (C) 2005-2016 Rod Roark <[email protected]> | ||
* | ||
* LICENSE: This program is free software; you can redistribute it and/or | ||
* modify it under the terms of the GNU General Public License | ||
|
@@ -23,8 +23,6 @@ | |
* @author Terry Hill <[email protected]> | ||
* @link http://www.open-emr.org | ||
*/ | ||
|
||
|
||
|
||
require_once("../globals.php"); | ||
require_once("$srcdir/log.inc"); | ||
|
@@ -253,7 +251,7 @@ function updateFields(payField, adjField, balField, coPayField, isFirstProcCode) | |
$reason_type = '1'; | ||
if ($reason) { | ||
$tmp = sqlQuery("SELECT option_value FROM list_options WHERE " . | ||
"list_id = 'adjreason' AND " . | ||
"list_id = 'adjreason' AND activity = 1 AND " . | ||
"option_id = '" . add_escape_custom($reason) . "'"); | ||
if (empty($tmp['option_value'])) { | ||
// This should not happen but if it does, apply old logic. | ||
|
@@ -668,7 +666,7 @@ function updateFields(payField, adjField, balField, coPayField, isFirstProcCode) | |
// Adjustment reasons are now taken from the list_options table. | ||
echo " <option value=''></option>\n"; | ||
$ores = sqlStatement("SELECT option_id, title, is_default FROM list_options " . | ||
"WHERE list_id = 'adjreason' ORDER BY seq, title"); | ||
"WHERE list_id = 'adjreason' AND activity = 1 ORDER BY seq, title"); | ||
while ($orow = sqlFetchArray($ores)) { | ||
echo " <option value='" . htmlspecialchars($orow['option_id'], ENT_QUOTES) . "'"; | ||
if ($orow['is_default']) echo " selected"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?php | ||
// Copyright (C) 2006, 2010 Rod Roark <[email protected]> | ||
// Copyright (C) 2006-2016 Rod Roark <[email protected]> | ||
// | ||
// This program is free software; you can redistribute it and/or | ||
// modify it under the terms of the GNU General Public License | ||
|
@@ -42,7 +42,7 @@ function genWarehouseList($tag_name, $currvalue, $title, $class='') { | |
$allow_multiple = $drow['allow_multiple']; | ||
|
||
$lres = sqlStatement("SELECT * FROM list_options " . | ||
"WHERE list_id = 'warehouse' ORDER BY seq, title"); | ||
"WHERE list_id = 'warehouse' AND activity = 1 ORDER BY seq, title"); | ||
|
||
echo "<select name='".attr($tag_name)."' id='".attr($tag_name)."'"; | ||
if ($class) echo " class='".attr($class)."'"; | ||
|
@@ -456,7 +456,7 @@ function trans_type_changed() { | |
"di.inventory_id, di.lot_number, di.on_hand, lo.title " . | ||
"FROM drug_inventory AS di " . | ||
"LEFT JOIN list_options AS lo ON lo.list_id = 'warehouse' AND " . | ||
"lo.option_id = di.warehouse_id " . | ||
"lo.option_id = di.warehouse_id AND lo.activity = 1 " . | ||
"WHERE di.drug_id = ? AND di.inventory_id != ? AND " . | ||
"di.on_hand > 0 AND di.destroy_date IS NULL " . | ||
"ORDER BY di.lot_number, lo.title, di.inventory_id", array ($drug_id,$lot_id)); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?php | ||
// Copyright (C) 2006-2015 Rod Roark <[email protected]> | ||
// Copyright (C) 2006-2016 Rod Roark <[email protected]> | ||
// | ||
// This program is free software; you can redistribute it and/or | ||
// modify it under the terms of the GNU General Public License | ||
|
@@ -90,7 +90,7 @@ function sellDrug($drug_id, $quantity, $fee, $patient_id=0, $encounter_id=0, | |
$query = "SELECT di.*, lo.option_id, lo.seq " . | ||
"FROM drug_inventory AS di " . | ||
"LEFT JOIN list_options AS lo ON lo.list_id = 'warehouse' AND " . | ||
"lo.option_id = di.warehouse_id " . | ||
"lo.option_id = di.warehouse_id AND lo.activity = 1 " . | ||
"WHERE " . | ||
"di.drug_id = ? AND di.destroy_date IS NULL "; | ||
$sqlarr = array($drug_id); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?php | ||
// Copyright (C) 2009 Rod Roark <[email protected]> | ||
// Copyright (C) 2009-2016 Rod Roark <[email protected]> | ||
// | ||
// This program is free software; you can redistribute it and/or | ||
// modify it under the terms of the GNU General Public License | ||
|
@@ -23,7 +23,7 @@ | |
$formname = isset($_GET['formname']) ? $_GET['formname'] : ''; | ||
|
||
$tmp = sqlQuery("SELECT title FROM list_options WHERE " . | ||
"list_id = 'lbfnames' AND option_id = ? LIMIT 1", array($formname) ); | ||
"list_id = 'lbfnames' AND option_id = ? AND activity = 1 LIMIT 1", array($formname) ); | ||
$formtitle = $tmp['title']; | ||
|
||
$fres = sqlStatement("SELECT * FROM layout_options " . | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
<?php | ||
/* $Id$ */ | ||
// Copyright (C) 2008-2014 Rod Roark <[email protected]> | ||
// Copyright (C) 2008-2014, 2016 Rod Roark <[email protected]> | ||
// Adapted for cross-platform operation by Bill Cernansky (www.mi-squared.com) | ||
// | ||
// This program is free software; you can redistribute it and/or | ||
|
@@ -303,7 +303,7 @@ function gzopen($filename, $mode, $use_include_path = 0) | |
echo "<b>" . xlt('Lists') . "</b><br />\n"; | ||
echo "<select multiple name='form_sel_lists[]' size='15'>"; | ||
$lres = sqlStatement("SELECT option_id, title FROM list_options WHERE " . | ||
"list_id = 'lists' ORDER BY title, seq"); | ||
"list_id = 'lists' AND activity = 1 ORDER BY title, seq"); | ||
while ($lrow = sqlFetchArray($lres)) { | ||
echo "<option value='" . attr($lrow['option_id']) . "'"; | ||
echo ">" . text(xl_list_label($lrow['title'])) . "</option>\n"; | ||
|
@@ -315,7 +315,7 @@ function gzopen($filename, $mode, $use_include_path = 0) | |
echo "<b>" . xlt('Layouts') . "</b><br />\n"; | ||
echo "<select multiple name='form_sel_layouts[]' size='15'>"; | ||
$lres = sqlStatement("SELECT option_id, title FROM list_options WHERE " . | ||
"list_id = 'lbfnames' ORDER BY title, seq"); | ||
"list_id = 'lbfnames' AND activity = 1 ORDER BY title, seq"); | ||
while ($lrow = sqlFetchArray($lres)) { | ||
echo "<option value='" . attr($lrow['option_id']) . "'"; | ||
echo ">" . text(xl_layout_label($lrow['title'])) . "</option>\n"; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<?php | ||
// Copyright (C) 2012 Rod Roark <[email protected]> | ||
// Copyright (C) 2012, 2016 Rod Roark <[email protected]> | ||
// Sponsored by David Eschelbacher, MD | ||
// | ||
// This program is free software; you can redistribute it and/or | ||
|
@@ -24,7 +24,7 @@ | |
$header = ""; | ||
$coljson = ""; | ||
$res = sqlStatement("SELECT option_id, title FROM list_options WHERE " . | ||
"list_id = 'ptlistcols' ORDER BY seq, title"); | ||
"list_id = 'ptlistcols' AND activity = 1 ORDER BY seq, title"); | ||
while ($row = sqlFetchArray($res)) { | ||
$colname = $row['option_id']; | ||
$title = xl_list_label($row['title']); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.