Skip to content

Commit

Permalink
bug fixing on malaria
Browse files Browse the repository at this point in the history
  • Loading branch information
mandajustin committed Nov 9, 2016
1 parent e751fc9 commit ce51947
Show file tree
Hide file tree
Showing 9 changed files with 272 additions and 8 deletions.
2 changes: 1 addition & 1 deletion app/controllers/encounters_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ class EncountersController < GenericEncountersController
c.instance_eval do
notes = params[:observations][0][:concept_name] rescue "" #TODO: Find a better way of this.
encounters_to_process = ["NOTES","OUTPATIENT DIAGNOSIS"]
if encounters_to_process.include? params[:encounter][:encounter_type_name] && notes != "CLINICAL NOTES CONSTRUCT"
if encounters_to_process.include? params[:encounter][:encounter_type_name] #&& notes != "CLINICAL NOTES CONSTRUCT"
DashBoardService.push_to_dashboard(params)
end
end
Expand Down
16 changes: 11 additions & 5 deletions app/views/encounters/idsr_complaints.rhtml
Original file line number Diff line number Diff line change
Expand Up @@ -104,19 +104,25 @@
outline: 1px solid #ddd; /* focus style */
}
.synd-content{
height: 600px;
height: 580px;
padding-left: 10px;
padding-right: 10px;
padding-top: 1px;
padding-top: 0px;
width: 98%;
margin-top: 0px;
overflow: auto;
border-bottom: 1px solid lightgrey ;
}
.top-space{
height: 20px;
width: 98%;
/*border-bottom: 1px solid lightgrey ;*/
}
</style>
<div class="label"><span id="label-text"></span></div>

<div class="synd-content">
<form action="/encounters/create_complaints" method="post">
<div class="top-space" id="top-space"><span>&nbsp;&nbsp;</div>
<div class="synd-content" id="cont">
<form action="/encounters/create_complaints" method="post" style="padding-top: 0px">
<%= hidden_field_tag "encounter[encounter_type_name]","NOTES" %>
<%= hidden_field_tag "encounter[patient_id]",@patient_id %>
<%= hidden_field_tag "encounter[encounter_datetime]",DateTime.now() %>
Expand Down
2 changes: 1 addition & 1 deletion app/views/encounters/outpatient_diagnosis.rhtml
Original file line number Diff line number Diff line change
Expand Up @@ -244,7 +244,7 @@
</div>
<div id="cover"></div>

<script type="text/javascript">
<script>
<% if (CoreService.get_global_property_value("malaria.enabled.facility").to_s == "true") %>
<% if session[:datetime].blank? %>
jQuery('html').click(function() {
Expand Down
10 changes: 10 additions & 0 deletions app/views/layouts/idsr_complaints.rhtml
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,14 @@
buttonCancel.onclick = function(){
window.location = "/patients/show/<%= @patient_id%>";
}
container.onscroll = function(){
if(container.scrollTop > 50){
document.getElementById("top-space").style.borderBottom = "1px solid lightgrey";
}else{
document.getElementById("top-space").style.borderBottom = "none";
}

}
function init(){
count = 1;
buttonNext = document.getElementById("next");
Expand All @@ -148,6 +155,8 @@
buttonCancel = document.getElementById("cancel");
noteElement = document.getElementById("label-text");
elements = document.getElementsByClassName("syndrome");
container = document.getElementById("cont");

totalElements = elements.length;
if (elements.length == 1)
{
Expand Down Expand Up @@ -204,6 +213,7 @@
}
return checked
}
var con
</script>
</body>
</html>
123 changes: 123 additions & 0 deletions passenger-standalone-1a99pem.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
##########################################################################
# Passenger Standalone is built on the same technology that powers
# Passenger for Nginx, so any configuration option supported by Passenger
# for Nginx can be applied to Passenger Standalone as well. You can do
# this by direct editing the Nginx configuration template that is used by
# Passenger Standalone.
#
# This file is the original template. DO NOT EDIT THIS FILE DIRECTLY.
# Instead, make a copy of this file and pass the `--nginx-config-template`
# parameter to Passenger Standalone.
#
# Learn more about using the Nginx configuration template at:
# https://www.phusionpassenger.com/library/config/standalone/intro.html#nginx-configuration-template
#
# *** NOTE ***
# If you customize the template file, make sure you keep an eye on the
# original template file and merge any changes. New Phusion Passenger
# features may require changes to the template file.
##############################################################

master_process on;
daemon on;
error_log '/var/www/opd/log/passenger.3002.log' ;
pid '/var/www/opd/tmp/pids/passenger.3002.pid';


worker_processes 1;
events {
worker_connections 4096;
}

http {
log_format debug '[$time_local] $msec "$request" $status conn=$connection sent=$bytes_sent body_sent=$body_bytes_sent';
include '/home/justin/.rvm/gems/ruby-2.1.2/gems/passenger-5.0.30/resources/mime.types';
passenger_root '/home/justin/.rvm/gems/ruby-2.1.2/gems/passenger-5.0.30';
passenger_abort_on_startup_error on;
passenger_ctl cleanup_pidfiles L3Zhci93d3cvb3BkL3Bhc3Nlbmdlci1zdGFuZGFsb25lLjF0bXRrMTcvdGVtcF9kaXJfdG91Y2hlci5waWQ=;
passenger_ctl integration_mode standalone;
passenger_ctl standalone_engine nginx;
passenger_user_switching off;
passenger_ruby /home/justin/.rvm/gems/ruby-2.1.2/wrappers/ruby;
passenger_user justin;
passenger_default_user justin;
passenger_analytics_log_user justin;
passenger_log_level 3;


### BEGIN your own configuration options ###
# This is a good place to put your own config
# options. Note that your options must not
# conflict with the ones Passenger already sets.
# Learn more at:
# https://www.phusionpassenger.com/library/config/standalone/intro.html#nginx-configuration-template

### END your own configuration options ###

default_type application/octet-stream;
types_hash_max_size 2048;
server_names_hash_bucket_size 64;
client_max_body_size 1024m;
access_log off;
keepalive_timeout 60;
underscores_in_headers on;
gzip on;
gzip_comp_level 3;
gzip_min_length 150;
gzip_proxied any;
gzip_types text/plain text/css text/json text/javascript
application/javascript application/x-javascript application/json
application/rss+xml application/vnd.ms-fontobject application/x-font-ttf
application/xml font/opentype image/svg+xml text/xml;




server {
server_name _;
listen 0.0.0.0:3002;
root '/var/www/opd/public';
passenger_app_root '/var/www/opd';
passenger_enabled on;
passenger_app_env 'development';
passenger_spawn_method 'smart';
passenger_load_shell_envvars off;

# Rails asset pipeline support.
location ~ "^/assets/.+-([0-9a-f]{32}|[0-9a-f]{64})\..+" {
error_page 490 = @static_asset;
error_page 491 = @dynamic_request;
recursive_error_pages on;

if (-f $request_filename) {
return 490;
}
if (!-f $request_filename) {
return 491;
}
}
location @static_asset {
gzip_static on;
expires max;
add_header Cache-Control public;
add_header ETag "";
}
location @dynamic_request {
passenger_enabled on;
}


### BEGIN your own configuration options ###
# This is a good place to put your own config
# options. Note that your options must not
# conflict with the ones Passenger already sets.
# Learn more at:
# https://www.phusionpassenger.com/library/config/standalone/intro.html#nginx-configuration-template

### END your own configuration options ###
}
passenger_pre_start http://0.0.0.0:3002/;



}
1 change: 1 addition & 0 deletions passenger-standalone.1tmtk17/logs/error.log
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
2016/10/27 14:37:09 [emerg] 11526#0: open() "/var/www/opd/log/passenger.3002.log" failed (13: Permission denied)
123 changes: 123 additions & 0 deletions passenger-standalone.1tmtk17/nginx.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
##########################################################################
# Passenger Standalone is built on the same technology that powers
# Passenger for Nginx, so any configuration option supported by Passenger
# for Nginx can be applied to Passenger Standalone as well. You can do
# this by direct editing the Nginx configuration template that is used by
# Passenger Standalone.
#
# This file is the original template. DO NOT EDIT THIS FILE DIRECTLY.
# Instead, make a copy of this file and pass the `--nginx-config-template`
# parameter to Passenger Standalone.
#
# Learn more about using the Nginx configuration template at:
# https://www.phusionpassenger.com/library/config/standalone/intro.html#nginx-configuration-template
#
# *** NOTE ***
# If you customize the template file, make sure you keep an eye on the
# original template file and merge any changes. New Phusion Passenger
# features may require changes to the template file.
##############################################################

master_process on;
daemon on;
error_log '/var/www/opd/log/passenger.3002.log' ;
pid '/var/www/opd/tmp/pids/passenger.3002.pid';


worker_processes 1;
events {
worker_connections 4096;
}

http {
log_format debug '[$time_local] $msec "$request" $status conn=$connection sent=$bytes_sent body_sent=$body_bytes_sent';
include '/home/justin/.rvm/gems/ruby-2.1.2/gems/passenger-5.0.30/resources/mime.types';
passenger_root '/home/justin/.rvm/gems/ruby-2.1.2/gems/passenger-5.0.30';
passenger_abort_on_startup_error on;
passenger_ctl cleanup_pidfiles L3Zhci93d3cvb3BkL3Bhc3Nlbmdlci1zdGFuZGFsb25lLjF0bXRrMTcvdGVtcF9kaXJfdG91Y2hlci5waWQ=;
passenger_ctl integration_mode standalone;
passenger_ctl standalone_engine nginx;
passenger_user_switching off;
passenger_ruby /home/justin/.rvm/gems/ruby-2.1.2/wrappers/ruby;
passenger_user justin;
passenger_default_user justin;
passenger_analytics_log_user justin;
passenger_log_level 3;


### BEGIN your own configuration options ###
# This is a good place to put your own config
# options. Note that your options must not
# conflict with the ones Passenger already sets.
# Learn more at:
# https://www.phusionpassenger.com/library/config/standalone/intro.html#nginx-configuration-template

### END your own configuration options ###

default_type application/octet-stream;
types_hash_max_size 2048;
server_names_hash_bucket_size 64;
client_max_body_size 1024m;
access_log off;
keepalive_timeout 60;
underscores_in_headers on;
gzip on;
gzip_comp_level 3;
gzip_min_length 150;
gzip_proxied any;
gzip_types text/plain text/css text/json text/javascript
application/javascript application/x-javascript application/json
application/rss+xml application/vnd.ms-fontobject application/x-font-ttf
application/xml font/opentype image/svg+xml text/xml;




server {
server_name _;
listen 0.0.0.0:3002;
root '/var/www/opd/public';
passenger_app_root '/var/www/opd';
passenger_enabled on;
passenger_app_env 'development';
passenger_spawn_method 'smart';
passenger_load_shell_envvars off;

# Rails asset pipeline support.
location ~ "^/assets/.+-([0-9a-f]{32}|[0-9a-f]{64})\..+" {
error_page 490 = @static_asset;
error_page 491 = @dynamic_request;
recursive_error_pages on;

if (-f $request_filename) {
return 490;
}
if (!-f $request_filename) {
return 491;
}
}
location @static_asset {
gzip_static on;
expires max;
add_header Cache-Control public;
add_header ETag "";
}
location @dynamic_request {
passenger_enabled on;
}


### BEGIN your own configuration options ###
# This is a good place to put your own config
# options. Note that your options must not
# conflict with the ones Passenger already sets.
# Learn more at:
# https://www.phusionpassenger.com/library/config/standalone/intro.html#nginx-configuration-template

### END your own configuration options ###
}
passenger_pre_start http://0.0.0.0:3002/;



}
2 changes: 1 addition & 1 deletion public/javascripts/popup.js
Original file line number Diff line number Diff line change
Expand Up @@ -320,7 +320,7 @@ function notifier(){

popupHeader = document.createElement('div');
popupHeader.className = 'popup-header-notifier';
popupHeader.innerHTML = 'Notifications';
popupHeader.innerHTML = 'Notification';
popupHeader.style.borderBottom = '2px solid #7D9EC0';
popupHeader.style.backgroundColor = '#FFFFFF';
popupHeader.style.paddingTop = '5px';
Expand Down
1 change: 1 addition & 0 deletions underlying_disease_alerts
Submodule underlying_disease_alerts added at deefee

0 comments on commit ce51947

Please sign in to comment.