Add old (not updated) Spotter template
This commit is contained in:
parent
f2b21327aa
commit
8ec2608f0e
9
sahana-spotter/Dockerfile
Normal file
9
sahana-spotter/Dockerfile
Normal file
@ -0,0 +1,9 @@
|
||||
FROM sahana:latest
|
||||
|
||||
COPY image.d /
|
||||
|
||||
RUN \
|
||||
# Change ownership of the newly copied files
|
||||
find /srv/web2py ! -user sahana -exec chown -R sahana:sahana {} +
|
||||
|
||||
VOLUME ["/srv/web2py/applications/eden/models"]
|
@ -0,0 +1,250 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
"""
|
||||
Machine-specific settings
|
||||
All settings which are typically edited for a specific machine should be done here
|
||||
|
||||
Deployers should ideally not need to edit any other files outside of their template folder
|
||||
|
||||
Note for Developers:
|
||||
/models/000_config.py is NOT in the Git repository, to avoid leaking of
|
||||
sensitive or irrelevant information into the repository.
|
||||
For changes to be committed, please also edit:
|
||||
modules/templates/000_config.py
|
||||
"""
|
||||
|
||||
import os
|
||||
|
||||
# Remove this line when you have edited this file sufficiently to proceed to the web interface
|
||||
FINISHED_EDITING_CONFIG_FILE = True
|
||||
|
||||
# Select the Template
|
||||
# - which Modules are enabled
|
||||
# - PrePopulate data
|
||||
# - Security Policy
|
||||
# - Workflows
|
||||
# - Theme
|
||||
# - note that you should restart your web2py after changing this setting
|
||||
settings.base.template = "Spotter"
|
||||
|
||||
# Database settings
|
||||
# Uncomment to use a different database, other than sqlite
|
||||
settings.database.db_type = "postgres"
|
||||
#settings.database.db_type = "mysql"
|
||||
# Uncomment to use a different host
|
||||
settings.database.host = os.getenv("POSTGRES_HOST", "localhost")
|
||||
# Uncomment to use a different port
|
||||
#settings.database.port = 3306
|
||||
#settings.database.port = 5432
|
||||
# Uncomment to select a different name for your database
|
||||
settings.database.database = os.getenv("POSTGRES_DB", "sahana")
|
||||
# Uncomment to select a different username for your database
|
||||
settings.database.username = os.getenv("POSTGRES_USER", "sahana")
|
||||
# Uncomment to set the password
|
||||
# NB Web2Py doesn't like passwords with an @ in them
|
||||
settings.database.password = os.getenv("POSTGRES_PASSWORD", "password")
|
||||
# Uncomment to use a different pool size
|
||||
#settings.database.pool_size = 30
|
||||
# Do we have a spatial DB available? (currently supports PostGIS. Spatialite to come.)
|
||||
settings.gis.spatialdb = True
|
||||
|
||||
# Base settings
|
||||
settings.base.system_name = T("Spotter Cluster")
|
||||
settings.base.system_name_short = T("Spotter")
|
||||
# Set this to the Public URL of the instance
|
||||
settings.base.public_url = os.getenv("SAHANA_PUBLIC_URL", "http://127.0.0.1:8080")
|
||||
|
||||
# Switch to "False" in Production for a Performance gain
|
||||
# (need to set to "True" again when Table definitions are changed)
|
||||
settings.base.migrate = True
|
||||
# To just create the .table files (also requires migrate=True):
|
||||
#settings.base.fake_migrate = True
|
||||
|
||||
# Set this to True to switch to Debug mode
|
||||
# Debug mode means that uncompressed CSS/JS files are loaded
|
||||
# JS Debug messages are also available in the Console
|
||||
# can also load an individual page in debug mode by appending URL with
|
||||
# ?debug=1
|
||||
settings.base.debug = True
|
||||
|
||||
# Uncomment this to prevent automated test runs from remote
|
||||
# settings.base.allow_testing = False
|
||||
|
||||
# Configure the log level ("DEBUG", "INFO", "WARNING", "ERROR" or "CRITICAL"), None = turn off logging (default)
|
||||
#settings.log.level = "ERROR" # DEBUG set automatically when base.debug is True
|
||||
# Uncomment to prevent writing log messages to the console (sys.stderr)
|
||||
#settings.log.console = False
|
||||
# Configure a log file (file name)
|
||||
#settings.log.logfile = None
|
||||
# Uncomment to get detailed caller information
|
||||
#settings.log.caller_info = True
|
||||
|
||||
# Uncomment to use Content Delivery Networks to speed up Internet-facing sites
|
||||
#settings.base.cdn = True
|
||||
|
||||
# Allow language files to be updated automatically
|
||||
#settings.L10n.languages_readonly = False
|
||||
|
||||
# This setting should be changed _before_ registering the 1st user
|
||||
# - should happen automatically if installing using supported scripts
|
||||
settings.auth.hmac_key = os.getenv("SAHANA_HMAC_KEY", "akeytochange")
|
||||
|
||||
# If using Masterkey Authentication, then set this to a deployment-specific 32 char string:
|
||||
#settings.auth.masterkey_app_key = "randomstringrandomstringrandomstring"
|
||||
|
||||
# Minimum Password Length
|
||||
#settings.auth.password_min_length = 8
|
||||
|
||||
# Email settings
|
||||
# Outbound server
|
||||
settings.mail.server = os.getenv("SAHANA_MAIL_HOST", "127.0.0.1:25")
|
||||
#settings.mail.tls = True
|
||||
# Useful for Windows Laptops:
|
||||
# https://www.google.com/settings/security/lesssecureapps
|
||||
#settings.mail.server = "smtp.gmail.com:587"
|
||||
#settings.mail.tls = True
|
||||
#settings.mail.login = "username:password"
|
||||
# From Address - until this is set, no mails can be sent
|
||||
settings.mail.sender = os.getenv("SAHANA_MAIL_SENDER", "'Sahana' <sahana@example.org>")
|
||||
# Default email address to which requests to approve new user accounts gets sent
|
||||
# This can be overridden for specific domains/organisations via the auth_domain table
|
||||
settings.mail.approver = os.getenv("SAHANA_MAIL_APPROVER", "useradmin@example.org")
|
||||
# Daily Limit on Sending of emails
|
||||
#settings.mail.limit = 1000
|
||||
|
||||
# Uncomment to restrict to specific country/countries
|
||||
#settings.gis.countries= ("LK",)
|
||||
|
||||
# Bing API Key (for Map layers)
|
||||
# http://www.microsoft.com/maps/create-a-bing-maps-key.aspx
|
||||
#settings.gis.api_bing = ""
|
||||
# GetAddress API Key (for GetAddress.io Postcode to Address lookup)
|
||||
#settings.gis.api_getaddress = ""
|
||||
# Google API Key (for Google Maps Layers)
|
||||
settings.gis.api_google = os.getenv("SAHANA_API_KEY_GOOGLE", "")
|
||||
# OpenWeatherMap API Key (for OpenWeatherMap Layers)
|
||||
settings.gis.api_openweathermap = os.getenv("SAHANA_API_KEY_OPENWEATHERMAP", "")
|
||||
|
||||
# GeoNames username
|
||||
#settings.gis.geonames_username = ""
|
||||
|
||||
# Fill this in to get a Facebook Pixel for your site
|
||||
#settings.base.facebook_pixel_id = ""
|
||||
# Fill this in to get Google Analytics for your site
|
||||
#settings.base.google_analytics_tracking_id = ""
|
||||
|
||||
# Chat server, see: http://eden.sahanafoundation.org/wiki/InstallationGuidelines/Chat
|
||||
#settings.base.chat_server = {
|
||||
# "ip": "127.0.0.1",
|
||||
# "port": 7070,
|
||||
# "name": "servername",
|
||||
# # Default group everyone is added to
|
||||
# "groupname" : "everyone",
|
||||
# "server_db" : "openfire",
|
||||
# # These settings fallback to main DB settings if not specified
|
||||
# # Only mysql/postgres supported
|
||||
# #"server_db_type" : "mysql",
|
||||
# #"server_db_username" : "",
|
||||
# #"server_db_password": "",
|
||||
# #"server_db_port" : 3306,
|
||||
# #"server_db_ip" : "127.0.0.1",
|
||||
# }
|
||||
|
||||
# GeoServer (Currently used by GeoExplorer. Will allow REST control of GeoServer.)
|
||||
# NB Needs to be publically-accessible URL for querying via client JS
|
||||
#settings.gis.geoserver_url = "http://localhost/geoserver"
|
||||
#settings.gis.geoserver_username = "admin"
|
||||
#settings.gis.geoserver_password = ""
|
||||
# Print Service URL: http://eden.sahanafoundation.org/wiki/BluePrintGISPrinting
|
||||
#settings.gis.print_service = "/geoserver/pdf/"
|
||||
|
||||
# Google OAuth (to allow users to login using Google)
|
||||
# https://code.google.com/apis/console/
|
||||
#settings.auth.google_id = ""
|
||||
#settings.auth.google_secret = ""
|
||||
|
||||
# Pootle server
|
||||
# settings.L10n.pootle_url = "http://pootle.sahanafoundation.org/"
|
||||
# settings.L10n.pootle_username = "username"
|
||||
# settings.L10n.pootle_password = "*****"
|
||||
|
||||
# SOLR server for Full-Text Search
|
||||
#settings.base.solr_url = "http://127.0.0.1:8983/solr/"
|
||||
|
||||
# Memcache server to allow sharing of sessions across instances
|
||||
#settings.base.session_memcache = '127.0.0.1:11211'
|
||||
|
||||
settings.base.session_db = True
|
||||
|
||||
# UI options
|
||||
# Should user be prompted to save before navigating away?
|
||||
#settings.ui.navigate_away_confirm = False
|
||||
# Should user be prompted to confirm actions?
|
||||
#settings.ui.confirm = False
|
||||
# Should potentially large dropdowns be turned into autocompletes?
|
||||
# (unused currently)
|
||||
#settings.ui.autocomplete = True
|
||||
#settings.ui.read_label = "Details"
|
||||
#settings.ui.update_label = "Edit"
|
||||
|
||||
# Audit settings
|
||||
# - can be a callable for custom hooks (return True to also perform normal logging, or False otherwise)
|
||||
# NB Auditing (especially Reads) slows system down & consumes diskspace
|
||||
#settings.security.audit_write = False
|
||||
#settings.security.audit_read = False
|
||||
|
||||
# Performance Options
|
||||
# Maximum number of search results for an Autocomplete Widget
|
||||
#settings.search.max_results = 200
|
||||
# Maximum number of features for a Map Layer
|
||||
#settings.gis.max_features = 1000
|
||||
|
||||
# CAP Settings
|
||||
# Change for different authority and organisations
|
||||
# See http://alerting.worldweather.org/ for oid
|
||||
# Country root oid. The oid for the organisation includes this base
|
||||
#settings.cap.identifier_oid = "2.49.0.0.608.0"
|
||||
# Set the period (in days) after which alert info segments expire (default=2)
|
||||
#settings.cap.info_effective_period = 2
|
||||
|
||||
# =============================================================================
|
||||
# Import the settings from the Template
|
||||
# - note: invalid settings are ignored
|
||||
#
|
||||
settings.import_template()
|
||||
|
||||
# =============================================================================
|
||||
# Over-rides to the Template may be done here
|
||||
#
|
||||
|
||||
# e.g.
|
||||
#settings.security.self_registration = True
|
||||
#settings.base.system_name = T("Sahana TEST")
|
||||
#settings.base.prepopulate = ("MY_TEMPLATE_ONLY")
|
||||
#settings.base.prepopulate += ("default", "default/users")
|
||||
#settings.base.theme = "default"
|
||||
settings.L10n.default_language = "cs"
|
||||
#settings.security.policy = 7 # Organisation-ACLs
|
||||
# Enable Additional Module(s)
|
||||
#from gluon.storage import Storage
|
||||
#settings.modules["delphi"] = Storage(
|
||||
# name_nice = T("Delphi Decision Maker"),
|
||||
# restricted = False,
|
||||
# module_type = 10,
|
||||
# )
|
||||
# Disable a module which is normally used by the template
|
||||
# - NB Only templates with adaptive menus will work nicely with this!
|
||||
#del settings.modules["irs"]
|
||||
|
||||
# Production instances should set this before prepopulate is run
|
||||
settings.base.prepopulate_demo = 0
|
||||
|
||||
# After 1st_run, set this for Production to save 1x DAL hit/request
|
||||
#settings.base.prepopulate = 0
|
||||
|
||||
# =============================================================================
|
||||
# A version number to tell update_check if there is a need to refresh the
|
||||
# running copy of this file
|
||||
VERSION = 1
|
||||
|
||||
# END =========================================================================
|
@ -0,0 +1,309 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
"""
|
||||
Global settings:
|
||||
|
||||
Those which are typically edited during a deployment are in
|
||||
000_config.py & their results parsed into here. Deployers
|
||||
shouldn't typically need to edit any settings here.
|
||||
"""
|
||||
|
||||
# Keep all our configuration options off the main global variables
|
||||
|
||||
# Use response.s3 for one-off variables which are visible in views without explicit passing
|
||||
s3.formats = Storage()
|
||||
|
||||
# Workaround for this Bug in Selenium with FF4:
|
||||
# http://code.google.com/p/selenium/issues/detail?id=1604
|
||||
s3.interactive = settings.get_ui_confirm()
|
||||
|
||||
s3.base_url = "%s/%s" % (settings.get_base_public_url(),
|
||||
appname,
|
||||
)
|
||||
s3.download_url = "%s/default/download" % s3.base_url
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Client tests
|
||||
|
||||
# Check whether browser is Mobile & store result in session
|
||||
# - commented-out until we make use of it
|
||||
#if session.s3.mobile is None:
|
||||
# from s3 import s3_is_mobile_client
|
||||
# session.s3.mobile = s3_is_mobile_client(request)
|
||||
#if session.s3.browser is None:
|
||||
# from s3 import s3_populate_browser_compatibility
|
||||
# session.s3.browser = s3_populate_browser_compatibility(request)
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Global variables
|
||||
|
||||
# Strings to i18n
|
||||
# Common Labels
|
||||
#messages["BREADCRUMB"] = ">> "
|
||||
messages["UNKNOWN_OPT"] = ""
|
||||
messages["NONE"] = ""
|
||||
messages["OBSOLETE"] = "Obsolete"
|
||||
messages["READ"] = settings.get_ui_label_read()
|
||||
messages["UPDATE"] = settings.get_ui_label_update()
|
||||
messages["DELETE"] = "Delete"
|
||||
messages["COPY"] = "Copy"
|
||||
messages["NOT_APPLICABLE"] = "N/A"
|
||||
messages["ADD_PERSON"] = "Create a Person"
|
||||
messages["ADD_LOCATION"] = "Create Location"
|
||||
messages["SELECT_LOCATION"] = "Select a location"
|
||||
messages["COUNTRY"] = "Country"
|
||||
messages["ORGANISATION"] = "Organization"
|
||||
messages["AUTOCOMPLETE_HELP"] = "Enter some characters to bring up a list of possible matches"
|
||||
|
||||
for u in messages:
|
||||
if isinstance(messages[u], str):
|
||||
globals()[u] = T(messages[u])
|
||||
|
||||
# CRUD Labels
|
||||
s3.crud_labels = Storage(READ = READ,
|
||||
UPDATE = UPDATE,
|
||||
DELETE = DELETE,
|
||||
COPY = COPY,
|
||||
NONE = NONE,
|
||||
)
|
||||
|
||||
# Error Messages
|
||||
ERROR["BAD_RECORD"] = "Record not found!"
|
||||
ERROR["BAD_METHOD"] = "Unsupported method!"
|
||||
ERROR["BAD_FORMAT"] = "Unsupported data format!"
|
||||
ERROR["BAD_REQUEST"] = "Invalid request"
|
||||
ERROR["BAD_SOURCE"] = "Invalid source"
|
||||
ERROR["BAD_TEMPLATE"] = "XSLT stylesheet not found"
|
||||
ERROR["BAD_RESOURCE"] = "Nonexistent or invalid resource"
|
||||
ERROR["DATA_IMPORT_ERROR"] = "Data import error"
|
||||
ERROR["INTEGRITY_ERROR"] = "Integrity error: record can not be deleted while it is referenced by other records"
|
||||
ERROR["METHOD_DISABLED"] = "Method disabled"
|
||||
ERROR["NO_MATCH"] = "No matching element found in the data source"
|
||||
ERROR["NOT_IMPLEMENTED"] = "Not implemented"
|
||||
ERROR["NOT_PERMITTED"] = "Operation not permitted"
|
||||
ERROR["PARSE_ERROR"] = "XML parse error"
|
||||
ERROR["TRANSFORMATION_ERROR"] = "XSLT transformation error"
|
||||
ERROR["UNAUTHORISED"] = "Not Authorized"
|
||||
ERROR["VALIDATION_ERROR"] = "Validation error"
|
||||
|
||||
# To get included in <HEAD>
|
||||
s3.stylesheets = []
|
||||
s3.external_stylesheets = []
|
||||
# To get included at the end of <BODY>
|
||||
s3.scripts = []
|
||||
s3.scripts_modules = []
|
||||
s3.js_global = []
|
||||
s3.jquery_ready = []
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Languages
|
||||
|
||||
s3.l10n_languages = settings.get_L10n_languages()
|
||||
|
||||
# Default strings are in US English
|
||||
T.current_languages = ("en", "en-us")
|
||||
# Check if user has selected a specific language
|
||||
if get_vars._language:
|
||||
language = get_vars._language
|
||||
session.s3.language = language
|
||||
elif session.s3.language:
|
||||
# Use the last-selected language
|
||||
language = session.s3.language
|
||||
elif auth.is_logged_in():
|
||||
# Use user preference
|
||||
language = auth.user.language
|
||||
else:
|
||||
# Use system default
|
||||
language = settings.get_L10n_default_language()
|
||||
#else:
|
||||
# # Use what browser requests (default web2py behaviour)
|
||||
# T.force(T.http_accept_language)
|
||||
|
||||
# IE doesn't set request.env.http_accept_language
|
||||
#if language != "en":
|
||||
T.force(language)
|
||||
|
||||
# Store for views (e.g. Ext)
|
||||
if language.find("-") == -1:
|
||||
# Ext peculiarities
|
||||
if language == "vi":
|
||||
s3.language = "vn"
|
||||
elif language == "el":
|
||||
s3.language = "el_GR"
|
||||
else:
|
||||
s3.language = language
|
||||
else:
|
||||
lang_parts = language.split("-")
|
||||
s3.language = "%s_%s" % (lang_parts[0], lang_parts[1].upper())
|
||||
|
||||
# List of Languages which use a Right-to-Left script (Arabic, Hebrew, Farsi, Urdu)
|
||||
if language in ("ar", "prs", "ps", "ur"):
|
||||
s3.rtl = True
|
||||
else:
|
||||
s3.rtl = False
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Auth
|
||||
|
||||
_settings = auth.settings
|
||||
_settings.lock_keys = False
|
||||
|
||||
_settings.expiration = 28800 # seconds
|
||||
|
||||
if settings.get_auth_openid():
|
||||
# Requires http://pypi.python.org/pypi/python-openid/
|
||||
try:
|
||||
from gluon.contrib.login_methods.openid_auth import OpenIDAuth
|
||||
openid_login_form = OpenIDAuth(auth)
|
||||
from gluon.contrib.login_methods.extended_login_form import ExtendedLoginForm
|
||||
_settings.login_form = ExtendedLoginForm(auth, openid_login_form,
|
||||
signals = ["oid", "janrain_nonce"],
|
||||
)
|
||||
except ImportError:
|
||||
session.warning = "Library support not available for OpenID"
|
||||
|
||||
# Allow use of LDAP accounts for login
|
||||
# NB Currently this means that change password should be disabled:
|
||||
#_settings.actions_disabled.append("change_password")
|
||||
# (NB These are not automatically added to PR or to Authenticated role since they enter via the login() method not register())
|
||||
#from gluon.contrib.login_methods.ldap_auth import ldap_auth
|
||||
# Require even alternate login methods to register users 1st
|
||||
#_settings.alternate_requires_registration = True
|
||||
# Active Directory
|
||||
#_settings.login_methods.append(ldap_auth(mode="ad", server="dc.domain.org", base_dn="ou=Users,dc=domain,dc=org"))
|
||||
# or if not wanting local users at all (no passwords saved within DB):
|
||||
#_settings.login_methods = [ldap_auth(mode="ad", server="dc.domain.org", base_dn="ou=Users,dc=domain,dc=org")]
|
||||
# Domino
|
||||
#_settings.login_methods.append(ldap_auth(mode="domino", server="domino.domain.org"))
|
||||
# OpenLDAP
|
||||
#_settings.login_methods.append(ldap_auth(server="directory.sahanafoundation.org", base_dn="ou=users,dc=sahanafoundation,dc=org"))
|
||||
# Allow use of Email accounts for login
|
||||
#_settings.login_methods.append(email_auth("smtp.gmail.com:587", "@gmail.com"))
|
||||
|
||||
# Require captcha verification for registration
|
||||
#auth.settings.captcha = RECAPTCHA(request, public_key="PUBLIC_KEY", private_key="PRIVATE_KEY")
|
||||
# Require Email Verification
|
||||
_settings.registration_requires_verification = settings.get_auth_registration_requires_verification()
|
||||
_settings.on_failed_authorization = URL(c="default", f="user",
|
||||
args = "not_authorized",
|
||||
)
|
||||
_settings.reset_password_requires_verification = True
|
||||
_settings.verify_email_next = URL(c="default", f="index")
|
||||
|
||||
# Require Admin approval for self-registered users
|
||||
_settings.registration_requires_approval = settings.get_auth_registration_requires_approval()
|
||||
|
||||
# We don't wish to clutter the groups list with 1 per user.
|
||||
_settings.create_user_groups = False
|
||||
# We need to allow basic logins for Webservices
|
||||
_settings.allow_basic_login = True
|
||||
|
||||
_settings.logout_onlogout = s3_auth_on_logout
|
||||
_settings.login_onaccept = s3_auth_on_login
|
||||
# Now read in auth.login() to avoid setting unneccesarily in every request
|
||||
#_settings.login_next = settings.get_auth_login_next()
|
||||
if settings.has_module("vol") and \
|
||||
settings.get_auth_registration_volunteer():
|
||||
_settings.register_next = URL(c="vol", f="person")
|
||||
|
||||
# Languages available in User Profiles
|
||||
#if len(s3.l10n_languages) > 1:
|
||||
# from s3 import IS_ISO639_2_LANGUAGE_CODE
|
||||
# _settings.table_user.language.requires = IS_ISO639_2_LANGUAGE_CODE(sort = True,
|
||||
# translate = True,
|
||||
# zero = None,
|
||||
# )
|
||||
#else:
|
||||
# field = _settings.table_user.language
|
||||
# field.default = s3.l10n_languages.keys()[0]
|
||||
# field.readable = False
|
||||
# field.writable = False
|
||||
|
||||
_settings.lock_keys = True
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Mail
|
||||
|
||||
# These settings could be made configurable as part of the Messaging Module
|
||||
# - however also need to be used by Auth (order issues)
|
||||
sender = settings.get_mail_sender()
|
||||
if sender:
|
||||
mail.settings.sender = sender
|
||||
mail.settings.server = settings.get_mail_server()
|
||||
mail.settings.tls = settings.get_mail_server_tls()
|
||||
mail_server_login = settings.get_mail_server_login()
|
||||
if mail_server_login:
|
||||
mail.settings.login = mail_server_login
|
||||
# Email settings for registration verification and approval
|
||||
_settings.mailer = mail
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# Session
|
||||
|
||||
# Custom Notifications
|
||||
response.error = session.error
|
||||
response.confirmation = session.confirmation
|
||||
response.information = session.information
|
||||
response.warning = session.warning
|
||||
session.error = []
|
||||
session.confirmation = []
|
||||
session.information = []
|
||||
session.warning = []
|
||||
|
||||
# Shortcuts for system role IDs, see modules/s3aaa.py/AuthS3
|
||||
#system_roles = auth.get_system_roles()
|
||||
#ADMIN = system_roles.ADMIN
|
||||
#AUTHENTICATED = system_roles.AUTHENTICATED
|
||||
#ANONYMOUS = system_roles.ANONYMOUS
|
||||
#EDITOR = system_roles.EDITOR
|
||||
#MAP_ADMIN = system_roles.MAP_ADMIN
|
||||
#ORG_ADMIN = system_roles.ORG_ADMIN
|
||||
#ORG_GROUP_ADMIN = system_roles.ORG_GROUP_ADMIN
|
||||
|
||||
# -----------------------------------------------------------------------------
|
||||
# CRUD
|
||||
|
||||
s3_formstyle = settings.get_ui_formstyle()
|
||||
s3_formstyle_read = settings.get_ui_formstyle_read()
|
||||
s3_formstyle_mobile = s3_formstyle
|
||||
submit_button = T("Save")
|
||||
s3_crud = s3.crud
|
||||
s3_crud.formstyle = s3_formstyle
|
||||
s3_crud.formstyle_read = s3_formstyle_read
|
||||
s3_crud.submit_button = submit_button
|
||||
# Optional class for Submit buttons
|
||||
#s3_crud.submit_style = "submit-button"
|
||||
s3_crud.confirm_delete = T("Do you really want to delete these records?")
|
||||
s3_crud.archive_not_delete = settings.get_security_archive_not_delete()
|
||||
s3_crud.navigate_away_confirm = settings.get_ui_navigate_away_confirm()
|
||||
|
||||
# JSON Formats
|
||||
s3.json_formats = ("geojson", "s3json")
|
||||
|
||||
# CSV Formats
|
||||
s3.csv_formats = ("hrf", "s3csv")
|
||||
|
||||
# Datatables default number of rows per page
|
||||
s3.ROWSPERPAGE = 20
|
||||
|
||||
# Valid Extensions for Image Upload fields
|
||||
s3.IMAGE_EXTENSIONS = ("png", "PNG", "jpg", "JPG", "jpeg", "JPEG")
|
||||
|
||||
# Default CRUD strings
|
||||
s3.crud_strings = Storage(label_create = T("Add Record"),
|
||||
title_display = T("Record Details"),
|
||||
title_list = T("Records"),
|
||||
title_update = T("Edit Record"),
|
||||
title_map = T("Map"),
|
||||
title_report = T("Report"),
|
||||
label_list_button = T("List Records"),
|
||||
label_delete_button = T("Delete Record"),
|
||||
msg_record_created = T("Record added"),
|
||||
msg_record_modified = T("Record updated"),
|
||||
msg_record_deleted = T("Record deleted"),
|
||||
msg_list_empty = T("No Records currently available"),
|
||||
msg_match = T("Matching Records"),
|
||||
msg_no_match = T("No Matching Records"),
|
||||
)
|
||||
|
||||
# END =========================================================================
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,11 @@
|
||||
"Catalog","Category Code","Category","Item Code","Item Name","Unit of Measure","Pack","Pack2 Quantity","Notes"
|
||||
"Default","Agriculture","Agriculture","AgRice20","Rice Seed","sack20kg",,,"This should provide enough seed for 1 Hectare of land"
|
||||
"Default","Food","Food","FdRice5","Rice","kg","sack",5,"This should feed 12 people for 1 day"
|
||||
"Default","Food","Food","FdRice50","Rice","kg","sack",50,"This should feed 125 people for 1 day"
|
||||
"Default","Food","Food","FdCookKit","Cooking Utensils","kit",,,"Cooking Utensils for a Household"
|
||||
"Default","Health","Health","HlFAidKit","First Aid Kit","kit",,,"This should provide basic first aid (bandages, oral rehydration salts, etc) for 100 people to self-administer"
|
||||
"Default","Health","Health","HlMedKit","Medical Kit","kit",,,"This should provide medical supplies (medicines, vaccines) for a professional clinic to provide assistance to a total community of 10,000 people."
|
||||
"Default","Shelter","Shelter","ShTentKit","Shelter Kit","kit",,,"This kit is suitable to provide emergency repair to a damaged home. It contains a tarpaulin, zinc sheet, wooden poles, hammer & nails"
|
||||
"Default","Shelter","Shelter","ShTent","Tent","piece",,,"This should house a family of up to 8 people"
|
||||
"Default","WASH","WASH","WSHygKit","Hygiene Kit","kit",,,"Personal Hygiene supplies for 100 Households (5 persons/household): Each get 2x Buckets, 10x Soap, Cotton cloth"
|
||||
"Default","WASH","WASH","WswPure","Water Purification Sachets","kit",,,"Designed to provide a 1st phase drinking water purification solution at the household level. Contains 600 sachets to provide sufficient drinking water (4l) for 100 people for 30 days."
|
|
@ -0,0 +1,4 @@
|
||||
Type,Name,Priority
|
||||
Default,"Level 1",3
|
||||
Default,"Level 2",2
|
||||
Default,"Level 3",1
|
|
@ -0,0 +1,11 @@
|
||||
Type,Name,Comments
|
||||
"Default","Disaster Psychology",
|
||||
"Default","Fire Suppression",
|
||||
"Default","Hazmat",
|
||||
"Default","Incident Command",
|
||||
"Default","Language - American Sign Language",
|
||||
"Default","Language - French",
|
||||
"Default","Language - Spanish",
|
||||
"Default","Medical Treatment",
|
||||
"Default","Security",
|
||||
"Default","Scene Sizeup",
|
|
@ -0,0 +1,14 @@
|
||||
Type,Name,Comments
|
||||
Driving License,"Driving - Motorcycle"
|
||||
Driving License,"Driving - Car"
|
||||
Driving License,"Driving - Class A: Combination (tractor plus trailer) vehicle","26,000 lb (11,790 kg) or more. Includes split (coupled) buses."
|
||||
Driving License,"Driving - Class B: Single (straight) vehicle","26,000 lb (11,790 kg) or more (includes most buses including articulated buses). Also includes combination vehicles for commercial use weighing less than 26,000 lb GVW."
|
||||
Driving License,"Driving - Class C: Commercial vehicle","that doesn't fit classes A or B but is placarded for hazardous materials or is intended to carry more than 15 persons (excluding Georgia). May include heavy-duty non-commercial vehicles with trailers capable of carrying over 16,000 lb, and all vehicles that can carry over 16,000 lb but not more than 25,999 lb."
|
||||
Driving License,"Driving - P: Passenger Transport","Required to drive a bus that carries 16 or more persons"
|
||||
Driving License,"Driving - H: Hazardous Materials","Also requires a TSA criminal background check as well as a written exam. The driver must be a US Citizen or permanent lawful resident to obtain an H or X endorsement."
|
||||
Driving License,"Driving - M: Metal coil"
|
||||
Driving License,"Driving - N: Tank Vehicles","Required for carrying liquids in bulk"
|
||||
Driving License,"Driving - T: Double/ Triple Trailers (Road trains)","Class A licenses only"
|
||||
Driving License,"Driving - X: Hazardous Materials and Tank Combination"," Also requires a TSA criminal background check as well as a written exam. The driver must be a US Citizen or permanent lawful resident to obtain an H or X endorsement."
|
||||
Driving License,"Driving - L: Air Brakes"
|
||||
Driving License,"Driving - S: School Bus","In addition to a standard bus endorsement, additional TSA and CORI background checks are required."
|
Can't render this file because it has a wrong number of fields in line 2.
|
@ -0,0 +1,23 @@
|
||||
Type,Name,Comments
|
||||
Driving License,"Driving - Motorcycle"
|
||||
Driving License,"Driving - Car"
|
||||
Driving License,"Driving - Class AM (14 years)","Two-wheel mopeds, Three-wheeled vehicles, light quadricycles. Maximum speed 45 km/h and engine capacity of less than or equal to 50 cm cubic"
|
||||
Driving License,"Driving - Class A1 (16 years)","Motorcycles, Tricycles, Agricultural Machinery. Maximum power 11 kW (Motorcycles) e 15 kW (Tricycles)"
|
||||
Driving License,"Driving - Class A2 (18 years)","Motorcycles. Power not exceeding 35 kW"
|
||||
Driving License,"Driving - Class A (20 o 21 years)","Tricycles or Motorcycles. Power greater than 15 kW, top speed exceeding 45 km/h"
|
||||
Driving License,"Driving - Class B1 (16 years)","Quadricycles. Mass less or equal to 400 kg (550 kg for vehicles used for the transport of goods, maximum engine power less than or equal to 15 kW"
|
||||
Driving License,"Driving - Class B/B96 (18 years)","Vehicles or machines Agricole. Max mass authorized 3500 kg and designed for the transport of not more than eight persons in addition to the driver. It can be combined with a trailer."
|
||||
Driving License,"Driving - Class BE (18 years)","Vehicles with a towing vehicle in category B and a trailer or semitrailer. Maximum mass of the trailer does not exceed 3500 kg."
|
||||
Driving License,"Driving - Class C1 (18 years)","Vehicles designed for the transport of not more than eight persons in addition to the driver. Maximum authorized mass exceeding 3500 kg, but not exceeding 7500 kg; can be combined with a trailer having a maximum authorized mass does not exceed 750 kg."
|
||||
Driving License,"Driving - Class C1E (18 years)","Vehicles with engine category C1 or B. Maximum authorized mass of the trailer is 750 Kg (C1) o 3500 Kg (B), overall should not exceed 12000 Kg"
|
||||
Driving License,"Driving - Class C (21 years)","Vehicles for the transport of not more than eight persons in addition to the driver. It can be combined with a trailer having a maximum authorized mass does not exceed 750 kg"
|
||||
Driving License,"Driving - Class CE (21 years)","Vehicles with engine type C and with a trailer. Maximum authorized mass 750 kg"
|
||||
Driving License,"Driving - Class D1 (21 years)","Vehicles designed for the transport of not more than 16 people, in addition to the driver. Maximum length of 8 meters, can be combined with a trailer having a maximum authorized mass does not exceed 750 kg."
|
||||
Driving License,"Driving - Class D1E (21 years)","Vehicles with engine type D1 and its trailer. Maximum authorized mass of the trailer is 750 Kg"
|
||||
Driving License,"Driving - Class D (24 years)","Vehicles designed for the transport of more than eight persons in addition to the driver, can be coupled to a trailer. Maximum authorized mass of the trailer is 750 kg"
|
||||
Driving License,"Driving - Class DE (24 years)","Vehicles with engine type D and a trailer. Maximum authorized mass of the trailer is 750 Kg"
|
||||
Driving License,"Driving - Class KA (21 years)","Karts of total mass until ad 1,3 tons. Rental service with driver."
|
||||
Driving License,"Driving - Class KB (21 years)","Karts of total mass over 1,3 tons and taxi. Rental service with driver."
|
||||
Driving License,"Driving - Class CQC Person (21 years)","Vehicles of category D1, D e/o D+E in public service or line rental with driver"
|
||||
Driving License,"Driving - Class CQC Goods (21 years)","Vehicles of category C1, C e/o C+E for professional transport"
|
||||
Driving License,"Driving - Class CFP","ADR Class B / A o B+explosives / B+radioactive (Vehicles carrying dangerous goods)"
|
Can't render this file because it has a wrong number of fields in line 2.
|
@ -0,0 +1,8 @@
|
||||
Type,Name,Priority
|
||||
Languages,"No",1
|
||||
Languages,"Bad",2
|
||||
Languages,"Fair",3
|
||||
Languages,"Average",4
|
||||
Languages,"Good",5
|
||||
Languages,"Excellent",6
|
||||
Languages,"Fluent",7
|
|
@ -0,0 +1,11 @@
|
||||
Type,Name,Comments
|
||||
Languages,"English - Spoken"
|
||||
Languages,"English - Written"
|
||||
Languages,"French - Spoken"
|
||||
Languages,"French - Written"
|
||||
Languages,"Spanish - Spoken"
|
||||
Languages,"Spanish - Written"
|
||||
Languages,"Arabic - Spoken"
|
||||
Languages,"Arabic - Written"
|
||||
Languages,"Chinese - Spoken"
|
||||
Languages,"Chinese - Written"
|
Can't render this file because it has a wrong number of fields in line 2.
|
@ -0,0 +1,279 @@
|
||||
"Catalog","Category Code","Category","Item Name","Unit of Measure","Pack","Pack Quantity","Pack2","Pack2 Quantity","Pack3","Pack3 Quantity","Comments"
|
||||
"Standard","CLOTHING","Appliances, Clothing, and Furniture","Childrens Clothing","ea",,,,,,,"priority"
|
||||
"Standard","CLOTHING","Appliances, Clothing, and Furniture","Furniture","ea",,,,,,,
|
||||
"Standard","CLOTHING","Appliances, Clothing, and Furniture","Household appliance","ea",,,,,,,
|
||||
"Standard","CLOTHING","Appliances, Clothing, and Furniture","Linens","ea",,,,,,,"priority"
|
||||
"Standard","CLOTHING","Appliances, Clothing, and Furniture","Mens Clothing","ea",,,,,,,"priority"
|
||||
"Standard","CLOTHING","Appliances, Clothing, and Furniture","Womens Clothing","ea",,,,,,,"priority"
|
||||
"Standard","MATERIALS","Building Materials","Asphalt","cy",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Blinds","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Cabinet","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Carpeting","sy",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Concrete","cy",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Counter Top","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Door","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Drywall","sf",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Ducting","lf",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Electrical Materials","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Faucet","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Fencing","lf",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Grips & Handles","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","HVAC Tools","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Levels","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Loader","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Lumber","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Manholes","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Paint","gal",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","PayLoader","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Pipe","lf",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Pipe Accessories","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Pipe Repair Kits","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Polymer/Setting Aid","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Roofing Materials","sq",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Sand","cy",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Sand Bags","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Screens","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Sink","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Steel","lbs",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Sulfur Dioxide","cy",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Tarps","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Tile","sf",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Toilet","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Tub","ea",,,,,,,
|
||||
"Standard","MATERIALS","Building Materials","Windows","ea",,,,,,,
|
||||
"Standard","$","Cash","Bank Cards","$",,,,,,,
|
||||
"Standard","$","Cash","Check","$",,,,,,,
|
||||
"Standard","$","Cash","Domestic Currency","$",,,,,,,"priority"
|
||||
"Standard","$","Cash","Foreign currency","$ equivalent",,,,,,,
|
||||
"Standard","$","Cash","Vouchers","$",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Aerator","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Air Compressor","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Air Conditioner/Heater","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Air Cooled Chiller Unit","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Air Curtain Burner","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Air Supply","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Aircraft","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Ambulance & Equipment","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","ATM","ea",,,,,,,"Cash Dispenser"
|
||||
"Standard","EQUIP","Equipment & Tools","Auger","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Barge","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Barricades","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Beacon","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Boat","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Bolt Cutters","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Boots","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Box Blade","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Breaker","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Broom","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Bucket","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Cabling","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Cage","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Camera","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Camera Snakes","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Carbon","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Chain Saw","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Chipper","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Chlorination Equipment","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Chlorination/Dechlorination ","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Compactor","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Computer (Laptops, Monitors, Cables, PC's)","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Concrete Grinder","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Copier","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Crane","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Cutter","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Dehumidifier","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Derrick","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Dock Plates","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Dozer","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Drywall Tools","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Dumpster","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Electrical panel","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Excavator","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Face Masks","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Fan","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Fax Machine","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Field Rake","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Fire Hydrant","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Fire Pump","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Fire Suppression","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Flashlight","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Flotation Device","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Fork Lift","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Furnace","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Garbage Can","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Generator","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Generator Cable","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Gloves","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","GPS / Transponder","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Grader","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Grader Blade","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Hardhat","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Heater","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Helicopter","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Helmet","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Hose","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Ice Machine","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Jackhammer","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Jaws of Life","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Laboratory/Sampling Equipment","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Ladder","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Life","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Light Plant","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Light Tower","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Lighting","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Megaphone/Loudspeaker","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Message Board","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Metal Detector","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Mixer","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Mop","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Mower","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Mulcher","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Pallet","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Pallet Grabber","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Pallet Jack","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Phone","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Phone Line","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Plastic Liners","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Pliers","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Plumbing Tools","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Poles","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Power Cord","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Power Distribution Box","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Power Line","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Power Supply","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","PPE","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Pressure Washer","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Printer","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Projector","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Pump","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Pump Extender","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Pump System","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Radio","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Rope","lf",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Satellite","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Saw","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Scanner","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Scraper","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Screwdriver","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Sensor","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Shovel","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Shrinkwrap","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Sign","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Snow Thrower","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Solids Processing","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Sprayer","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Strainers/T-Joints/Elbows","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Stretcher","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Striking Tools","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Striper","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Sweeper","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Table","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Tamper Plate","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Tank","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Tent","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Tire Balancer","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Tire Changer","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Topdresser","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Towels","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Tractor","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Transformer","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Traprake","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Trench Box","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Trencher","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Trowel","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Tub Grinder","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Utencils","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Vacuum","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Valves","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Vehicles","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Ventilator","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Vibrator","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Video Conferencing","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Video Transmitter","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Walkers","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Water Cooler","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Water Purification System","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Welder","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Well Equipment","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Wheelchair","ea",,,,,,,
|
||||
"Standard","EQUIP","Equipment & Tools","Wrench","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Agriculture Laboratory","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Airport","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Animal Feedlot","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Animal Shelter","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Barn","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Cold Storage","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Empty Lot","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Grain Storage","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Hand Wash Station","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Mobile Kitchen","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Office","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Other Facilities","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Rail Station","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Shelter","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Staging","ea",,,,,,,
|
||||
"Standard","FACILITY","Facilities","Storage","ea",,,,,,,
|
||||
"Standard","FOOD","Food & Water","Animal Feed","lbs",,,,,,,
|
||||
"Standard","FOOD","Food & Water","Canned/Dried Food","lbs",,,,,,,"priority"
|
||||
"Standard","FOOD","Food & Water","Ice","lbs",,,,,,,"priority"
|
||||
"Standard","FOOD","Food & Water","Infant Formula","lbs",,,,,,,"priority"
|
||||
"Standard","FOOD","Food & Water","Non-Potable Water","gal",,,,,,,
|
||||
"Standard","FOOD","Food & Water","Perishable Food","lbs",,,,,,,"priority"
|
||||
"Standard","FOOD","Food & Water","Potable Water","gal",,,,,,,"priority"
|
||||
"Standard","FUEL","Fuel","Aviation","gal",,,,,,,
|
||||
"Standard","FUEL","Fuel","Diesel","gal",,,,,,,
|
||||
"Standard","FUEL","Fuel","Gasoline","gal",,,,,,,"priority"
|
||||
"Standard","FUEL","Fuel","Heating Oil","gal",,,,,,,
|
||||
"Standard","FUEL","Fuel","Liquid Propane","gal",,,,,,,"priority"
|
||||
"Standard","FUEL","Fuel","Natural Gas","gal",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Anticeptic","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Bandages","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Batteries","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Body Bags","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Boxes","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Cane","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Cleaners","ea",,,,,,,"priority"
|
||||
"Standard","SUPPLIES","General supplies","Crutches","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Defibrilator","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Diapers","dz",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Hearing Aid","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","ID Badges","ea",,,,,,,
|
||||
"Standard","SUPPLIES","General supplies","Insect Repellant","ea",,,,,,,
|
||||
"Standard","MEDICAL","Medical supplies","Office Supplies","ea",,,,,,,
|
||||
"Standard","MEDICAL","Medical supplies","Plastic Sheeting","roll",,,,,,,"priority"
|
||||
"Standard","MEDICAL","Medical supplies","Tape","roll",,,,,,,
|
||||
"Standard","MEDICAL","Medical supplies","Tarps","ea",,,,,,,"priority"
|
||||
"Standard","MEDICAL","Medical supplies","Toiletries","ea",,,,,,,"priority"
|
||||
"Standard","MEDICAL","Medical supplies","Towels","ea",,,,,,,
|
||||
"Standard","MEDICAL","Medical supplies","Trash Bags","bx",,,,,,,"priority"
|
||||
"Standard","MEDICAL","Medical supplies","Ventilator","ea",,,,,,,
|
||||
"Standard","MEDICAL","Medical supplies","Wheelchair","ea",,,,,,,
|
||||
"Standard","OTHER","Other","Other","ea",,,,,,,
|
||||
"Standard","SERVICES","Services","Accounting","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Administrative","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Architecture","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Automotive repair","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Care and shelter","hour","day",8,"week",40,"month",160,"priority"
|
||||
"Standard","SERVICES","Services","Catering","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Communications","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Construction","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Debris removal","hour","day",8,"week",40,"month",160,"priority"
|
||||
"Standard","SERVICES","Services","Demolition","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Engineering","hour","day",8,"week",40,"month",160,"priority"
|
||||
"Standard","SERVICES","Services","Firefighting ","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Fumigation","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","General Labor","hour","day",8,"week",40,"month",160,"priority"
|
||||
"Standard","SERVICES","Services","Health Care","hour","day",8,"week",40,"month",160,"priority"
|
||||
"Standard","SERVICES","Services","Household Repair","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Housing","hour","day",8,"week",40,"month",160,"priority"
|
||||
"Standard","SERVICES","Services","Legal","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Other Services","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Photography","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Planning (Urban)","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Resource Protection (Environmental)","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Search and Rescue","hour","day",8,"week",40,"month",160,"priority"
|
||||
"Standard","SERVICES","Services","Security","hour","day",8,"week",40,"month",160,"priority"
|
||||
"Standard","SERVICES","Services","Skilled Labor","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Translation","hour","day",8,"week",40,"month",160,
|
||||
"Standard","SERVICES","Services","Transportation","hour","day",8,"week",40,"month",160,"priority"
|
||||
"Standard","SERVICES","Services","Warehousing","hour","day",8,"week",40,"month",160,
|
|
@ -0,0 +1 @@
|
||||
|
@ -0,0 +1,91 @@
|
||||
uid,role,description,controller,function,table,entity,uacl,oacl,Notes
|
||||
ANONYMOUS,Anonymous,Unauthenticated users,,,org_organisation,,READ,READ,Required for self-registration
|
||||
ANONYMOUS,Anonymous,,org,sites_for_org,,,READ,READ,Required for self-registration
|
||||
ANONYMOUS,Anonymous,,gis,,,,READ,READ,
|
||||
ANONYMOUS,Anonymous,,vulnerability,,,,READ,READ,
|
||||
ANONYMOUS,Anonymous,,water,,,,READ,READ,
|
||||
ANONYMOUS,Anonymous,,delphi,,,,READ,READ,
|
||||
AUTHENTICATED,Authenticated,Authenticated - all logged-in users,gis,,,,READ,READ,
|
||||
AUTHENTICATED,Authenticated,,vulnerability,,,,READ,READ,
|
||||
AUTHENTICATED,Authenticated,,water,,,,READ,READ,
|
||||
AUTHENTICATED,Authenticated,,delphi,,,,READ,READ,
|
||||
AUTHENTICATED,Authenticated,,impact,,,,READ,READ,
|
||||
AUTHENTICATED,Authenticated,,doc,,,,READ,READ,
|
||||
EDITOR,Editor,Editor - can access & make changes to any unprotected data,pr,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,vulnerability,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,survey,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,security,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,fire,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,deploy,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,water,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,budget,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,cap,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,vol,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,delphi,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,org,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,scenario,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,vehicle,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,member,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,cr,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,gis,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,asset,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,patient,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,transport,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,po,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,impact,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,dvr,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,event,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,msg,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,supply,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,project,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,doc,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,hrm,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,appadmin,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,hms,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,req,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,mpr,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,sync,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,inv,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,stats,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,edu,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,dvi,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
EDITOR,Editor,,cms,,,,ALL,CREATE|READ|UPDATE|REVIEW|APPROVE,
|
||||
MAP_ADMIN,Map Admin,"Complementary role: FULL access mode only to the maps and their configurations
|
||||
When to assign: Staff Directors.",gis,,,,ALL,ALL,
|
||||
ORG_ADMIN,Organization Admin,,org,,,,ALL,ALL,
|
||||
ORG_GROUP_ADMIN,Organzation Group Admin,,,,,,,,
|
||||
medical_admin,Medical Details Admin,"Complementary role: FULL access but only to medical data of registered evacuees. It must be assigned with other roles to grant access to the other types of data.
|
||||
When to assign: Medical Staff.",patient,,,,ALL,ALL,
|
||||
medical_admin,Medical Details Admin,,hms,,,,ALL,ALL,
|
||||
medical_admin,Medical Details Admin,,dvi,,,,ALL,ALL,
|
||||
notification_sender,Notification Sender,,msg,,,,ALL,ALL,
|
||||
org_reader,Organization Reader,"Complementary role: Access in ""READ only"" mode to Organization data and its branches
|
||||
When to assign: Staff Directors",org,,,,READ,READ,
|
||||
private_user_editor,Private User Editor,"FULL access to modules Evacuees and Shelter.
|
||||
When to assign: private user member of a shelter / Organization and committed to provide assistance to some evacuees",cr,,,,ALL,ALL,
|
||||
private_user_editor,Private User Editor,,dvr,,,,ALL,ALL,
|
||||
private_user_reader,Private User Reader,"Access in ""READ only"" mode to modules Evacuees and Shelter.
|
||||
When to assign: private user member of a Shelter / Organization and committed to provide assistance to some evacuees.",cr,,,,READ,READ,
|
||||
private_user_reader,Private User Reader,,dvr,,,,READ,READ,
|
||||
public_auth_editor,Public Authority Editor,"FULL access to modules Evacuees and Shelter.
|
||||
When to assign: supervisor user member of local government office with the rights to register data.",cr,,,,ALL,ALL,
|
||||
public_auth_editor,Public Authority Editor,,dvr,,,,ALL,ALL,
|
||||
public_auth_editor,Public Authority Editor,,mpr,,,,READ,READ,
|
||||
public_auth_reader,Public Authority Reader,"Access in ""READ only"" mode to modules Evacuees and Shelter.
|
||||
When to assign: supervisor user member of a local government office.",dvr,,,,READ,READ,
|
||||
staff_admin,Staff Admin,"FULL access to modules Staff, Volunteer, Evacuees and Shelter.
|
||||
When to assign: Staff assigned to manage one or more shelters.",vol,,,,ALL,ALL,
|
||||
staff_admin,Staff Admin,,cr,,,,ALL,ALL,
|
||||
staff_admin,Staff Admin,,dvr,,,,ALL,ALL,
|
||||
staff_admin,Staff Admin,,hrm,,,,ALL,ALL,
|
||||
staff_reader,Staff Reader,"Access in ""READ only"" mode to modules Staff, Volunteer, Evacuees and Shelter.
|
||||
When to assign: Staff assigned to manage one or more shelters.",vol,,,,READ,READ,
|
||||
staff_reader,Staff Reader,,cr,,,,READ,READ,
|
||||
staff_reader,Staff Reader,,dvr,,,,READ,READ,
|
||||
staff_reader,Staff Reader,,hrm,,,,READ,READ,
|
||||
vol_editor,Volunteer Editor,"FULL access to modules Evacuees and Shelter.
|
||||
When to assign: volunteer (trusted person) volunteer who provides assistance to some evacuees inside a well-defined group of shelters.",cr,,,,ALL,ALL,
|
||||
vol_editor,Volunteer Editor,,dvr,,,,ALL,ALL,
|
||||
vol_reader,Volunteer Reader,"Access in ""READ only"" mode to modules Evacuees and Shelter.
|
||||
When to assign: volunteer who provides assistance to some evacuees inside a well- defined group of shelters.",cr,,,,READ,READ,
|
||||
vol_reader,Volunteer Reader,,dvr,,,,READ,READ,
|
|
@ -0,0 +1,21 @@
|
||||
Name
|
||||
"CPA - Certified Public Accountant"
|
||||
"CSW - Certified Social Worker"
|
||||
"DR1 - Driver's License - Car"
|
||||
"DR2 - Driver's License - Lt truck"
|
||||
"DR3 - Driver's License Heavy truck"
|
||||
"DR4 - Driver's License Bus"
|
||||
"DR5 - Driver's License Commercial"
|
||||
"DR6 - Driver's License Motorcycle"
|
||||
"EMT - Emergency Medical Technician"
|
||||
"HRO - Ham Radio Operator"
|
||||
"LPC - Licensed Professional Counselor"
|
||||
"LPN - Licensed Practical Nurse"
|
||||
"LSW - Licensed Social Worker"
|
||||
"LVN - Licensed Vocational Nurse"
|
||||
"MD - Medical Doctor"
|
||||
"MFT - Marriage and Family Therapist"
|
||||
"MT - Medical Technician"
|
||||
"PA - Physician Assistant"
|
||||
"PSY - Psychologist"
|
||||
"RN - Registered Nurse"
|
|
@ -0,0 +1,4 @@
|
||||
Name,Module,Resource,Body
|
||||
About,default,about,"<h2>About</h2>"
|
||||
Help,default,help,"<h2>Help</h2><a href='http://eden.sahanafoundation.org/wiki/UserGuidelines' target='_blank'>User & Administration Guide</a> - online version"
|
||||
CMS Module Index,cms,,"<h2>Content Management System</h2><p>This module allows the editing of page content using a web browser.</p><p>Posts can be either full pages, embedded within other pages or part of a series (for use as news items or blog posts)</p>"
|
|
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,6 @@
|
||||
"Name","Comments"
|
||||
"IDP Refugee Camp","OCHA Icons"
|
||||
"Permanent Camp","OCHA Icons"
|
||||
"Spontaneous Site","OCHA Icons"
|
||||
"Temporary Camp","OCHA Icons"
|
||||
"Transition Site","OCHA Icons"
|
|
@ -0,0 +1,50 @@
|
||||
../themes/default/layout.css
|
||||
../themes/default/xtheme-gray.css
|
||||
../themes/default/footer.css
|
||||
../themes/default/widgets.css
|
||||
../themes/default/shortcut.css
|
||||
../themes/default/homepage.css
|
||||
font-awesome/font-awesome.css
|
||||
plugins/jquery.cluetip.css
|
||||
plugins/jquery.dataTables.css
|
||||
plugins/jquery.dataTables.responsive.css
|
||||
plugins/jquery.tagit.css
|
||||
#ui/accordion.css
|
||||
ui/core.css
|
||||
ui/autocomplete.css
|
||||
ui/button.css
|
||||
#ui/checkboxradio.css
|
||||
#ui/controlgroup.css
|
||||
ui/datepicker.css
|
||||
ui/dialog.css
|
||||
# Needed for Delphi
|
||||
ui/draggable.css
|
||||
ui/menu.css
|
||||
#ui/progressbar.css
|
||||
ui/resizable.css
|
||||
ui/selectmenu.css
|
||||
ui/slider.css
|
||||
#ui/sortable.css
|
||||
#ui/spinner.css
|
||||
ui/tabs.css
|
||||
#ui/tooltip.css
|
||||
ui/fgtimepicker.css
|
||||
ui/multiselect.css
|
||||
ui/timepicker-addon.css
|
||||
#calendars/ui.calendars.picker.css
|
||||
#calendars/ui-smoothness.calendars.picker.css
|
||||
../themes/foundation/jquery-ui.theme.css
|
||||
gis/style.css
|
||||
zocial/zocial.css
|
||||
../themes/default/gis.css
|
||||
../themes/foundation/map.css
|
||||
../themes/default/mobile.css
|
||||
../themes/default/print.css
|
||||
d3/nv.d3.css
|
||||
#../themes/default/project.css
|
||||
../themes/default/report.css
|
||||
../themes/default/survey.css
|
||||
../themes/default/newsfeed.css
|
||||
../themes/default/theme.css
|
||||
#../themes/default/style.css
|
||||
# Final line required for parsing
|
@ -0,0 +1,4 @@
|
||||
Position,Code,Status,Default,Comments
|
||||
1,PENDING,Pending,false,
|
||||
2,OPEN,Open,true,
|
||||
3,CLOSED,Closed,false,
|
|
@ -0,0 +1,25 @@
|
||||
Type,Comments,KV:XX
|
||||
Accident,,
|
||||
Avalanche,,
|
||||
Civil Unrest,,
|
||||
Cold Wave,,
|
||||
Collapse,,
|
||||
Drought,,
|
||||
Earthquake,,
|
||||
Epidemic,,
|
||||
Explosion,,
|
||||
Extreme Winter Conditions,,
|
||||
Fire,,
|
||||
Flash Flood,,
|
||||
Flood,,
|
||||
Food Security,,
|
||||
Heat Wave,,
|
||||
Land Slide,,
|
||||
Local Storm,,
|
||||
Locust,,
|
||||
Population Movement,,
|
||||
Rockfall,,
|
||||
Subsidence,,
|
||||
Tropical Cyclone,,
|
||||
Tsunami,,
|
||||
Volcano,,
|
|
@ -0,0 +1,3 @@
|
||||
UUID,Name,Region Country,Default Country,Zoom,Lat,Lon,Projection,LatMin,LatMax,LonMin,LonMax,Marker
|
||||
SITE_DEFAULT,Default,,,2,22.593723263,5.28516253,900913,-90,90,-180,180,marker_red
|
||||
,WGS84,,,2,22.593723263,5.28516253,4326,-90,90,-180,180,
|
|
@ -0,0 +1,98 @@
|
||||
UUID,Country,L1,L2,L3,L4,L5,Edit L1
|
||||
SITE_DEFAULT,,"State / Province","County / District","City / Town / Village","Village / Suburb",,
|
||||
,AF,Province,District,Village,,,
|
||||
,AL,County,District,Municipality,,,
|
||||
,AM,Province,Community,Settlement,,,
|
||||
,AR,Province,Department,Municipality,
|
||||
,AS,District,County,Village,,,
|
||||
,AT,State,"District / City",Municipality,
|
||||
,AU,"State / Territory",Local Government Area,,,,
|
||||
,AZ,Economic Region,"District (Rayon)",,,,
|
||||
,BA,"District / Entity",Canton,Municipality,,,
|
||||
,BD,Division,District,"Thana / Upazil","Village / Union / Area",,
|
||||
,BE,Region,Province,Arrondissement,Commune,
|
||||
,BG,Province,Municipality,,,
|
||||
,BI,Province,Commune,Colline,Sous Colline,
|
||||
,BN,District,Mukim,,
|
||||
,BO,Department,Province,Municipality,Canton
|
||||
,BR,State,Municipality,District,,
|
||||
,BT,District,Sub-District,,
|
||||
,BZ,District,,,
|
||||
,CD,Province,Territory/Commune,,,,
|
||||
,CF,Prefecture,Sub-Prefecture,Commune,,
|
||||
,CK,Island Council,Village Committee,,,
|
||||
,CL,Region,Province,Commune,,
|
||||
,CM,Region,Division,Sub-Division,Village,
|
||||
,CO,Department,Municipality,Corregimiento,
|
||||
,CR,Province,Canton,District,
|
||||
,CU,Province,Municipality,
|
||||
,DE,"Federal State","Rural District / District","Town / Municipality",Locality,
|
||||
,DO,Province,Municipality,,,,
|
||||
,EC,Province,Canton,Parish,,,
|
||||
,FI,Regional State Administrative Agency,Region,Sub-region,Municipality,,
|
||||
,FJ,Division,Province,District,,,,
|
||||
,GB,Country,County,District,Parish,,
|
||||
,GE,"Region / Republic",District,,,,
|
||||
,GN,Region,Prefecture,Sub-prefecture,,,
|
||||
,GR,Decentralized Administration,Region,Regional Unit,Municipality,,
|
||||
,GT,Department,Municipality,
|
||||
,HN,Department,Municipality,Village,,,
|
||||
,HR,County,"Town / Municipality",,,,
|
||||
,HT,Department,Commune,Communal section,,
|
||||
,HU,County,District,,,,
|
||||
,ID,Province,"Regency / City",District,Administrative Village,,
|
||||
,IN,State,District,Sub-District,,,
|
||||
,IQ,Province,District,,,,
|
||||
,IT,Region,Province,Commune,,,
|
||||
,JO,Governorate,District,Subdistrict,,,
|
||||
,KE,County,Constituency,Location,SubLocation,
|
||||
,KG,"Oblast / State City","District (Rayon) / Oblast City","Town / Village Group",Village,,
|
||||
,KH,Province,District,Commune,Village,
|
||||
,KI,Island Council,,,,
|
||||
,KZ,Province,District,,,,
|
||||
,LA,Province,District,Village,,,
|
||||
,LB,Governorate,District,,,,
|
||||
,LK,Province,District,Divisional Secretariat,Grama Niladhari,,
|
||||
,LR,County,District,Clan,,,
|
||||
,LT,County,Municipality,Eldership,,,
|
||||
,LY,District,"City / Town / Village",,,,
|
||||
,MG,Region,District,Commune,Fokontany,
|
||||
,MK,Municipality,,,,
|
||||
,MM,State,District,Township,Village Tract,Village,
|
||||
,MN,Province,District,Sub-District,,,
|
||||
,MP,Municipality,Village,,,,
|
||||
,MV,"Atoll/City",Island,,,,
|
||||
,MX,State,Municipality,
|
||||
,MY,State,District,Mukim,,,
|
||||
,NI,Department,Municipality,
|
||||
,NP,Region,Zone,District,Village Development Committee,Ward,
|
||||
,NZ,Region,Territorial Authority,,,,
|
||||
,PA,Province,District,Corregimiento,,
|
||||
,PE,Region,Province,District,,
|
||||
,PG,Province,District,LLG,Village,,
|
||||
,PH,Region,Province,"City / Municipality",Barangay,,
|
||||
,PK,Province,District,Tehsil,Union Council,Village,
|
||||
,PL,Province,County,Municipality,,,
|
||||
,PR,Municipality,Barrio,,,,
|
||||
,PY,Department,District,"City / Town / Village",,,
|
||||
,RS,District,"Municipality / City",,,,
|
||||
,SB,Province,Ward,,
|
||||
,SE,County,Municipality,,,,
|
||||
,SG,Region,,,
|
||||
,SL,Province,District,Chiefdom,,,
|
||||
,SV,Department,Municipality,
|
||||
,SY,Governorate,District,Subdistrict
|
||||
,TD,Region,Department,Sub-Prefecture,Canton,
|
||||
,TH,Province,District,Sub-District,,,
|
||||
,TJ,Province,District,Jamoat,Village,,
|
||||
,TL,District,SubDistrict,Suco,Aldeia,,
|
||||
,TM,Province,District,,,,
|
||||
,TO,Island Group,District,,,,
|
||||
,TR,Province,District / Town,Neighborhood / Village,,,
|
||||
,TV,Island Council,,,,
|
||||
,US,State,County,City,Neighborhood,,False
|
||||
,UZ,Province,District,,,,
|
||||
,VN,Province,District,Commune,,,
|
||||
,VU,Province,Area Council,,
|
||||
,XK,District,Municipality,,,,
|
||||
,YE,Governorate,District,Sub-District,Village,,
|
Can't render this file because it has a wrong number of fields in line 6.
|
@ -0,0 +1,4 @@
|
||||
Name,Type,Enabled,Default
|
||||
Bing Aerial,aerial,False,
|
||||
Bing Hybrid,hybrid,False,
|
||||
Bing Road,road,False,
|
|
@ -0,0 +1,2 @@
|
||||
Name,Enabled,Visible
|
||||
Coordinate Grid,False,False
|
|
@ -0,0 +1,24 @@
|
||||
Name,Description,Controller,Function,Marker,GPS Marker,Popup Format,Attributes,Filter,Site,Points,Trackable,Style,Opacity,Folder,Visible,Enabled,Cluster Threshold,Refresh
|
||||
Airports,All Active Airports,transport,airport,airport,Airport,{name} (T('Airport')),name,~.obsolete=False,,True,,,,,False,,,
|
||||
Assets,,asset,asset,asset,Flag,{number} (T('Asset'))<br />{person_id},"number,person_id",,,True,True,,,,False,,,
|
||||
Demographics,For summary page,stats,demographic_data,,,{location_id}: {value},"location_id,value",,,,,"[{'prop':'value','fillOpacity':0.5}]",0.5,,False,False,0,0
|
||||
Heliports,All Active Heliports,transport,heliport,helicopter,Heliport,{name} (T('Heliport')),name,~.obsolete=False,,True,,,,,False,,,
|
||||
Hospitals,All Active Medical Facilities,hms,hospital,hospital,Medical Facility,{name} (T('Hospital')),name,~.obsolete=False,,True,,,,,False,,,
|
||||
Incident Reports,,event,incident_report,incident,Danger Area,{name} (T('Incident'))<br />{incident_type_id},"name,incident_type_id",,,True,,,,,False,,,
|
||||
Locations,Used by Location Details,gis,location,,,{name},"name,gis_feature_type",~.level__ne=None&~.end_date=None,,,,"[{'prop':'gis_feature_type','cat':1,'externalGraphic':'img/markers/marker_red.png'},{'prop':'gis_feature_type','cat':3,'fill':'00BFFF','fillOpacity':0.5},{'prop':'gis_feature_type','cat':6,'fill':'00BFFF','fillOpacity':0.5}]",0.9,,False,,0,0
|
||||
Offices,All Active Offices,org,office,office,Building,{name} (T('Office'))<br />{organisation_id},"name,organisation_id",~.obsolete=False,,True,,,,,False,,,
|
||||
PoIs,Points of Interest,gis,poi,,,{name} ({poi_type_id}),"name,poi_type_id",,,True,,,,,,False,,
|
||||
Projects,,project,location,project,,{name} (T('Project'))<br />{location_id}<br />{multi_activity_type_id},"name,location_id,multi_activity_type_id",,,,,,,,False,,,
|
||||
Requests,All Open Requests,req,req,request,"Navaid, Red",{req_ref} (T('Request'))<br />{site_id},"req_ref,site_id",~.fulfil_status__ne=2,True,,,,,,False,,,
|
||||
Seaports,All Active Seaports,transport,seaport,port,Marina,{name} (T('Seaport')),name,~.obsolete=False,,True,,,,,False,,,
|
||||
Shelters,All Active Shelters,cr,shelter,shelter,Campground,{name} (T('Shelter'))<br />T('Population') {population}<br />T('Capacity') {capacity_day},"name,population,capacity_day",~.status__ne=1,,True,,,,,False,,,
|
||||
Staff,All Active Staff,hrm,staff,staff,"Contact, Dreadlocks",{person_id} (T('Staff'))<br />{job_title_id}<br />{organisation_id},"person_id,job_title_id,organisation_id",~.status=1,,True,True,,,,False,,,
|
||||
Stock Items,Used for Search Results,inv,inv_item,,,{item_id} (T('Stock Item'))<br />{site_id}<br />{quantity} {item_pack_id}<br />T('Expires') {expiry_date},"item_id,site_id,quantity,item_pack_id,expiry_date",,,,,,,,False,False,,
|
||||
Training Events,Used for Search Results,hrm,training_event,,,{course_id} (T('Training Event'))<br />{site_id}<br />{start_date},"course_id,site_id,start_date",,,True,,,,,False,False,,
|
||||
Tweets,All Tweets,msg,twitter_result,twitter,,{body},body,,,True,,,,,False,,,
|
||||
Vehicles,,vehicle,vehicle,vehicle,Car,{number} (T('Vehicle'))<br />{person_id},"number,person_id",,,True,True,,,,False,,,
|
||||
Volunteers,All Active Volunteers,vol,volunteer,volunteer,"Contact, Dreadlocks",{person_id} (T('Volunteer'))<br />{organisation_id},"person_id,organisation_id",~.status=1,,True,True,,,,False,,,
|
||||
Warehouses,All Active Warehouses,inv,warehouse,warehouse,Building,{name} (T('Warehouse'))<br />{organisation_id},"name,organisation_id",~.obsolete=False,,True,,,,,False,,,
|
||||
All Alerts,,cap,alert,marker_red,,{headline} (T('Alert')),"id,cap_info.headline,cap_info.priority,cap_area.name",~.is_template=False,,,,"[{'fallback':'No Priority'},{'prop':'priority','cat':'Urgent','fill':'FF0000'},{'prop':'priority','cat':'High','fill':'FFA500'},{'prop':'priority','cat':'Low','fill':'FFFF00'},{'prop':'priority','cat':'-','fill':'222222'}]",0.25,,False,False,,
|
||||
Public Alerts,,cap,public,marker_red,,{headline} (T('Alert')),"id,cap_info.headline,cap_info.priority,cap_area.name",~.is_template=False&~.scope=Public,,,,"[{'fallback':'No Priority'},{'prop':'priority','cat':'Urgent','fill':'FF0000'},{'prop':'priority','cat':'High','fill':'FFA500'},{'prop':'priority','cat':'Low','fill':'FFFF00'},{'prop':'priority','cat':'-','fill':'222222'}]",0.25,,False,False,,
|
||||
Predefined Areas,,cap,area,marker_red,,{name} (T('Predefined Area')),"id,cap_area.name,cap_area.priority,cap_area.event_type_id,cap_area.altitude,cap_area.ceiling",~.is_template=True,,,,,0.25,,False,False,,
|
|
@ -0,0 +1,2 @@
|
||||
Name,Description,URL,Projection,Marker,Style,Folder,Config,Enabled,Visible
|
||||
Earthquakes: Recent Events,USGS M4.5 7-day,http://earthquake.usgs.gov/earthquakes/feed/v1.0/summary/4.5_week.geojson,4326,,"[{'prop':'mag','low':4.5,'high':5.4,'label':'5','fillOpacity':0.8,'fill':'FFFF00','graphic':'circle','size':5},{'prop':'mag','low':5.5,'high':6.4,'label':'6','fillOpacity':0.8,'fill':'FFA500','graphic':'circle','size':7},{'prop':'mag','low':6.5,'high':7.4,'label':'7','fillOpacity':0.8,'fill':'FFCA00','graphic':'circle','size':9},{'prop':'mag','low':7.5,'high':9.9,'label':'8+','fillOpacity':0.8,'fill':'FF0000','graphic':'circle','size':11}]",Incidents,,True,False
|
|
@ -0,0 +1,4 @@
|
||||
Name,Description,URL,Marker,Enabled,Visible,Folder,Image
|
||||
Fires (US),InciWeb,http://inciweb.nwcg.gov/feeds/rss/incidents/,fire,False,False,Incidents,
|
||||
Floods,Dartmouth Flood Observatory,http://www.gdacs.org/xml/rssfl.xml,flood,False,False,Incidents,gdas:gfds_image
|
||||
Volcanoes,USGS: US recent,http://volcano.wr.usgs.gov/rss/vhpcaprss.xml,volcano,False,False,Incidents,
|
|
@ -0,0 +1,8 @@
|
||||
Name,Description,Type,Enabled,Default
|
||||
"Google Maps","Streets",maps,"False",
|
||||
"Google Hybrid","Streets over Satellite imagery",hybrid,"False",
|
||||
"Google Satellite","Satellite imagery",satellite,"False",
|
||||
"Google Terrain","Streets over topography",terrain,"False",
|
||||
"Google MapMaker","Community additions to streets. This is much more detailed than normal Google in some locations. It is incompatioble with Streetview.",mapmaker,"False",
|
||||
"Google MapMapker Hybrid","Community additions to streets overlaid over Satellite imagery. This is much more detailed than normal Google in some locations. It is incompatioble with Streetview.",mapmakerhybrid,"False",
|
||||
"Google Streetview","Streetview allows access to a 3D photographic panorama. It is incompatible with MapMaker layers.",streetview,"True",
|
|
@ -0,0 +1,2 @@
|
||||
Name,Description,URL,Enabled
|
||||
"MGRS Atlas PDFs""http://en.wikipedia.org/wiki/Military_grid_reference_system","http://www.sharedgeo.org/datasets/shared/maps/usng/pdf.map?VERSION=1.0.0&SERVICE=WFS&request=GetFeature&typename=wfs_all_maps",False
|
Can't render this file because it has a wrong number of fields in line 2.
|
@ -0,0 +1,12 @@
|
||||
Name,Enabled,Visible,Base,Default,Folder,URL,URL2,URL3,Attribution,"Zoom Levels"
|
||||
"OpenStreetMap (MapQuest)","False",,,,,"http://otile1.mqcdn.com/tiles/1.0.0/osm/","http://otile2.mqcdn.com/tiles/1.0.0/osm/","http://otile3.mqcdn.com/tiles/1.0.0/osm/","Tiles Courtesy of <a href=""http://open.mapquest.co.uk/"" target=""_blank"">MapQuest</a> <img src=""//developer.mapquest.com/content/osm/mq_logo.png"" border=""0"">",
|
||||
"OpenStreetMap (MapQuest SSL)","False",,,,,"https://otile1-s.mqcdn.com/tiles/1.0.0/osm/","https://otile2-s.mqcdn.com/tiles/1.0.0/osm/","https://otile3-s.mqcdn.com/tiles/1.0.0/osm/","Tiles Courtesy of <a href=""http://open.mapquest.co.uk/"" target=""_blank"">MapQuest</a> <img src=""//developer.mapquest.com/content/osm/mq_logo.png"" border=""0"">",
|
||||
"OpenStreetMap (Humanitarian)","True",,,"True",,"//a.tile.openstreetmap.fr/hot/","//b.tile.openstreetmap.fr/hot/","//c.tile.openstreetmap.fr/hot/","Tiles Courtesy of <a href=""http://hot.openstreetmap.org/"" target=""_blank"">Humanitarian OpenStreetMap Team</a>",
|
||||
"OpenStreetMap (Standard)","False",,,,,"//a.tile.openstreetmap.org/","//b.tile.openstreetmap.org/","//c.tile.openstreetmap.org/","Tiles Courtesy of <a href=""http://www.openstreetmap.org/"" target=""_blank"">OpenStreetMap</a>",
|
||||
"OpenStreetMap (Landscape)","False",,,,,"http://a.tile3.opencyclemap.org/landscape/","http://b.tile3.opencyclemap.org/landscape/","http://c.tile3.opencyclemap.org/landscape/","Tiles Courtesy of <a href=""http://www.opencyclemap.org/"" target=""_blank"">OpenCycleMap</a>",
|
||||
"OpenStreetMap (Cycle Map)","False",,,,,"http://a.tile.opencyclemap.org/cycle/","http://b.tile.opencyclemap.org/cycle/","http://c.tile.opencyclemap.org/cycle/","Tiles Courtesy of <a href=""http://www.opencyclemap.org/"" target=""_blank"">OpenCycleMap</a>",
|
||||
"OpenStreetMap (Transport Map)","False",,,,,"http://a.tile2.opencyclemap.org/transport/","http://b.tile2.opencyclemap.org/transport/","http://c.tile2.opencyclemap.org/transport/","Tiles Courtesy of <a href=""http://www.opencyclemap.org/"" target=""_blank"">OpenCycleMap</a>",
|
||||
"OpenStreetMap (Labels)","False","False","False",,,"http://casa.oobrien.com/maptiler/labelsonly/",,,"Labels overlay CC-by-SA by <a href=""http://oobrien.com/oom/"" target=""_blank"">OpenOrienteeringMap</a>/<a href=""http://www.openstreetmap.org/"">OpenStreetMap</a> data",
|
||||
"OpenStreetMap (Relief)","False","False","False",,,"http://toolserver.org/~cmarqu/hill/",,,"Relief by <a href=""http://hikebikemap.de/"" target=""_blank"">Hike & Bike Map</a>",
|
||||
"OpenStreetMap (Taiwan)","False",,,,,"http://tile.openstreetmap.tw/tiles/",,,,
|
||||
"OpenStreetMap (Sahana)","False",,,,,"http://geo.eden.sahanafoundation.org/tiles/",,,,
|
|
@ -0,0 +1,3 @@
|
||||
Name,Description,Type,Config,Folder,Enabled,Visible
|
||||
"Current Weather",,city,,Weather,"True","False"
|
||||
"Weather Stations",,station,,Weather,"True","False"
|
|
@ -0,0 +1,15 @@
|
||||
Name,Description,Enabled,Folder,URL,URL2,URL3,Layer Name,Attribution,Zoom Levels,Format
|
||||
"Blue Marble Topography & Bathymetry (January)","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","blue-marble-topo-bathy-jan",'<a href="http://mapbox.com" target="_blank">MapBox</a>',9,
|
||||
"Blue Marble Topography & Bathymetry (July)","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","blue-marble-topo-bathy-jul",'<a href="http://mapbox.com" target="_blank">MapBox</a>',9,
|
||||
"Blue Marble Topography (January)","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","blue-marble-topo-jan",'<a href="http://mapbox.com" target="_blank">MapBox</a>',9,
|
||||
"Blue Marble Topography (July)","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","blue-marble-topo-jul",'<a href="http://mapbox.com" target="_blank">MapBox</a>',9,
|
||||
"Control Room","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","control-room",'<a href="http://mapbox.com" target="_blank">MapBox</a>',9,
|
||||
"Geography Class","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","geography-class",'<a href="http://mapbox.com" target="_blank">MapBox</a>',9,
|
||||
"Natural Earth Hypsometric","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","natural-earth-hypso",'<a href="http://mapbox.com" target="_blank">MapBox</a>',7,
|
||||
"Natural Earth Hypsometric & Bathymetry","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","natural-earth-hypso-bathy",'<a href="http://mapbox.com" target="_blank">MapBox</a>',7,
|
||||
"Natural Earth I","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","natural-earth-1",'<a href="http://mapbox.com" target="_blank">MapBox</a>',7,
|
||||
"Natural Earth II","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","natural-earth-2",'<a href="http://mapbox.com" target="_blank">MapBox</a>',7,
|
||||
"World Dark","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","world-dark",'<a href="http://mapbox.com" target="_blank">MapBox</a>',12,
|
||||
"World Light","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","world-light",'<a href="http://mapbox.com" target="_blank">MapBox</a>',12,
|
||||
"World Glass","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","world-glass",'<a href="http://mapbox.com" target="_blank">MapBox</a>',11,
|
||||
"World Print","MapBox",False,,"http://a.tiles.mapbox.com/mapbox/","http://b.tiles.mapbox.com/mapbox/","http://c.tiles.mapbox.com/mapbox/","world-print",'<a href="http://mapbox.com" target="_blank">MapBox</a>',10,
|
Can't render this file because it contains an unexpected character in line 2 and column 211.
|
@ -0,0 +1,15 @@
|
||||
Name,Description,URL,Layers,Folder,Config,Enabled,Visible,Base,Transparent,Opacity,Format,Queryable,LegendURL,Style,Map
|
||||
VMap0,A Free low-resolution Vector Map of the whole world,http://vmap0.tiles.osgeo.org/wms/vmap0,basic,,WGS84,True,True,True,,,,False,,,
|
||||
Blue Marble,A composite of four months of MODIS observations with a spatial resolution (level of detail) of 1 square kilometer per pixel.,http://maps.opengeo.org/geowebcache/service/wms,bluemarble,,WGS84,True,True,True,,,,False,,,
|
||||
LandSat,Global 15m satellite imagery from 2003.,http://hyperquad.telascience.org/cgi-bin/onearth?,OnEarth_PAN_321_20030801,,WGS84,True,True,True,,,image/jpeg,False,,,
|
||||
MODIS/Terra Corrected Reflectance (True Color),,http://lance2.modaps.eosdis.nasa.gov/cgi-bin/mapserv.cgi?map_layer[Terra250]=DATA+terr_250m_2012125.vrt,Terra250,,WGS84,True,False,True,,,image/jpeg,False,,,rrglobal_terra_250m.map
|
||||
MODIS/Aqua Corrected Reflectance (True Color),,http://lance2.modaps.eosdis.nasa.gov/cgi-bin/mapserv.cgi?map_layer[Aqua250]=DATA+aqua_250m_2012125.vrt,Aqua250_143,,WGS84,True,False,True,,,image/jpeg;mode=24bit,False,,,rrglobal_aqua_250m.map
|
||||
Terra Corrected Reflectance (True Color),,http://lance2.modaps.eosdis.nasa.gov/cgi-bin/mapserv.cgi?map_layer[Terra250]=DATA+terr_250m_2012125.vrt,Terra250,,WGS84,True,False,False,True,,image/png,False,,,rrglobal_terra_250m.map
|
||||
US Radar Mosaic,"The nowCOAST 'obs' Web Map Service (WMS) provides layers containing near real-time surface meteorological and oceanographic observations from various sources. Some observations are updated as frequently as every six minutes, while others are updated hourly. The 'obs' WMS is one of several map services provided by NOAA's nowCOAST project (http://nowcoast.noaa.gov). For further layer information such as layer icons, legend graphics, layer descriptions, and valid timestamps, see the nowCOAST 'LayerInfo Web Service' description page at: http://nowcoast.noaa.gov/help/layerinfo.shtml. For more information about nowCOAST's available Web Map Services, see the nowCOAST Map Services information page at: http://nowcoast.noaa.gov/help/mapservices.shtml. nowCOAST is a product of the NOAA/NOS/OCS Coast Survey Development Laboratory.",http://nowcoast.noaa.gov:80/wms/com.esri.wms.Esrimap/obs?,RAS_RIDGE_NEXRAD,Weather,WGS84,True,False,False,True,,image/png,False,,,
|
||||
Fires (Last 24 Hours),Provides MODIS (MODIS Rapid Response Collection) Fires/Hotspots for the past 24 hours. Please visit http://maps.geog.umd.edu/firms/ for more information,http://firefly.geog.umd.edu/wms/wms?,fires24,Hazards,WGS84,True,False,False,True,,image/png,False,,,
|
||||
Fires (Last 48 Hours),Provides MODIS (MODIS Rapid Response Collection) Fires/Hotspots for the past 48 hours. Please visit http://maps.geog.umd.edu/firms/ for more information,http://firefly.geog.umd.edu/wms/wms?,fires48,Hazards,WGS84,True,False,False,True,,image/png,False,,,
|
||||
Population Density 2010 (Alternate server),GPWv3,http://sedac.ciesin.columbia.edu/geoserver/wms?,gpw-v3:gpw-v3-population-density-future-estimates_2010,Population,WGS84,True,False,False,True,0.8,image/png,False,,,
|
||||
Population Density 2000 (Persons per km2),GRUMPv1,http://beta.sedac.ciesin.columbia.edu:8080/geoserver/wms?,grump-v1:grump-v1-population-density_2000 ,Population,WGS84,True,False,False,True,0.8,image/png,False,,,
|
||||
Precipitation forecast,,http://geo.weatheroffice.gc.ca/geomet/?,GDPS.ETA_PR,Weather,,True,False,False,True,0.4,image/png,False,http://geo.weatheroffice.gc.ca/geomet/?LANG=E%26SERVICE=WMS%26VERSION=1.1.1%26REQUEST=GetLegendGraphic%26STYLE=PRECIPMM%26LAYER=GDPS.ETA_PR%26format=image/png,PRECIPMM,
|
||||
Cloud forecast,,http://geo.weatheroffice.gc.ca/geomet/?,GDPS.ETA_NT,Weather,,True,False,False,True,0.4,image/png,False,http://geo.weatheroffice.gc.ca/geomet/?LANG=E%26SERVICE=WMS%26VERSION=1.1.1%26REQUEST=GetLegendGraphic%26STYLE=CLOUD%26LAYER=GDPS.ETA_NT%26format=image/png,CLOUD,
|
||||
Sea Level: Rise of 2m,Data from https://www.cresis.ku.edu/data/sea-level-rise-maps,http://lacrmt.sahanafoundation.org:8080/geoserver/wms?,lacrmt:inund2,Hazards,,False,False,False,True,0.4,image/png,False,,,
|
|
@ -0,0 +1,79 @@
|
||||
Name,Height,Width,Image
|
||||
marker_red,34,20,"marker_red.png"
|
||||
marker_yellow,34,20,"marker_yellow.png"
|
||||
marker_amber,34,20,"marker_amber.png"
|
||||
marker_green,34,20,"marker_green.png"
|
||||
airport,33,44,"ersSymbolsV0202/Infrastructures_S1/Trans_Airport_S1.png"
|
||||
ambulance,40,40,"ersSymbolsV0202/Operations_S1/E_Med_Ambulance_S1_ch.png"
|
||||
asset,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Staging_Areas_S1.png"
|
||||
asset_green,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Staging_Areas_S1_green.png"
|
||||
asset_red,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Staging_Areas_S1_red.png"
|
||||
asset_yellow,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Staging_Areas_S1_yellow.png"
|
||||
bridge,33,44,"ersSymbolsV0202/Infrastructures_S1/Trans_Bridge_S1.png"
|
||||
church,33,44,"ersSymbolsV0202/Infrastructures_S1/Public_Venue_Church_S1.png"
|
||||
earthquake,50,50,"ersSymbolsV0202/Natural_Events/Geo_Earth_Quake_Epicenter.png"
|
||||
elderly,33,44,"ersSymbolsV0202/Infrastructures_S1/Special_Needs_Elder_Care_S1.png"
|
||||
fire,50,50,"ersSymbolsV0202/Incidents/Fire_Theme.png"
|
||||
fire_station,40,40,"ersSymbolsV0202/Operations_S1/Fire_Station_S1.png"
|
||||
flood,50,50,"ersSymbolsV0202/Natural_Events/Hydro_Meteor_Flood.png"
|
||||
food,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Food_Distribution_Centers_S1.png"
|
||||
food_green,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Food_Distribution_Centers_S1_green.png"
|
||||
food_red,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Food_Distribution_Centers_S1_red.png"
|
||||
food_yellow,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Food_Distribution_Centers_S1_yellow.png"
|
||||
hazmat,50,50,"ersSymbolsV0202/Incidents/Hazmat_Toxic_and_Infectious.png"
|
||||
hazmat_green,50,50,"ersSymbolsV0202/Incidents/Hazmat_Toxic_and_Infectious_green.png"
|
||||
hazmat_red,50,50,"ersSymbolsV0202/Incidents/Hazmat_Toxic_and_Infectious_red.png"
|
||||
hazmat_yellow,50,50,"ersSymbolsV0202/Incidents/Hazmat_Toxic_and_Infectious_yellow.png"
|
||||
helicopter,33,44,"ersSymbolsV0202/Infrastructures_S1/Trans_Helicopter_Landing_Site_S1.png"
|
||||
hospital,40,40,"ersSymbolsV0202/Operations_S1/E_Med_Hospital_S1.png"
|
||||
hospital_green,40,40,"ersSymbolsV0202/Operations_S1/E_Med_Hospital_S1_Green.png"
|
||||
hospital_red,40,40,"ersSymbolsV0202/Operations_S1/E_Med_Hospital_S1_Red.png"
|
||||
hospital_yellow,40,40,"ersSymbolsV0202/Operations_S1/E_Med_Hospital_S1_Yellow.png"
|
||||
incident,50,50,"ersSymbolsV0202/Incidents/Incident_Theme.png"
|
||||
information,32,32,Information.png
|
||||
mobile_phone,40,40,Mobile_Phone.png
|
||||
mosque,33,44,"ersSymbolsV0202/Infrastructures_S1/Public_Venue_Mosque_S1.png"
|
||||
news,48,48,News.png
|
||||
office,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Operations_Center_S1.png"
|
||||
office_green,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Operations_Center_S1_green.png"
|
||||
office_red,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Operations_Center_S1_red.png"
|
||||
office_yellow,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Operations_Center_S1_yellow.png"
|
||||
orphanage,33,44,"ersSymbolsV0202/Infrastructures_S1/Special_Needs_Child_Day_Care_S1.png"
|
||||
phone,10,5,SMS_Message_Phone.png
|
||||
police_station,40,40,"ersSymbolsV0202/Operations_S1/Law_Enforcement_Theme_S1.png"
|
||||
port,33,44,"ersSymbolsV0202/Infrastructures_S1/Trans_Port_S1.png"
|
||||
project,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Teams_S1.png"
|
||||
rail_station,33,44,"ersSymbolsV0202/Infrastructures_S1/Trans_Rail_Station_S1.png"
|
||||
request,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Operations_Theme_S1.png"
|
||||
request_red,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Operations_Theme_S1_red.png"
|
||||
request_yellow,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Operations_Theme_S1_yellow.png"
|
||||
residence,33,44,"ersSymbolsV0202/Infrastructures_S1/Public_Venues_Theme_S1.png"
|
||||
residence_green,33,44,"ersSymbolsV0202/Infrastructures_S1/Public_Venues_Theme_S1_green.png"
|
||||
residence_red,33,44,"ersSymbolsV0202/Infrastructures_S1/Public_Venues_Theme_S1_red.png"
|
||||
residence_yellow,33,44,"ersSymbolsV0202/Infrastructures_S1/Public_Venues_Theme_S1_yellow.png"
|
||||
school,33,44,"ersSymbolsV0202/Infrastructures_S1/Edu_Schools_S1.png"
|
||||
shelter,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Shelters_S1.png"
|
||||
shelter_green,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Shelters_S1_green.png"
|
||||
shelter_red,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Shelters_S1_red.png"
|
||||
shelter_yellow,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Shelters_S1_yellow.png"
|
||||
special_needs,33,44,"ersSymbolsV0202/Infrastructures_S1/Special_Needs_Adult_Day_Care_S1.png"
|
||||
special_needs_green,33,44,"ersSymbolsV0202/Infrastructures_S1/Special_Needs_Adult_Day_Care_S1_Green.png"
|
||||
special_needs_red,33,44,"ersSymbolsV0202/Infrastructures_S1/Special_Needs_Adult_Day_Care_S1_Red.png"
|
||||
special_needs_yellow,33,44,"ersSymbolsV0202/Infrastructures_S1/Special_Needs_Adult_Day_Care_S1_Yellow.png"
|
||||
staff,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Staff_S1.png"
|
||||
staff_red,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Staff_S1_red.png"
|
||||
staff_yellow,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Staff_S1_yellow.png"
|
||||
team,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Teams_S1.png"
|
||||
temple,33,44,"ersSymbolsV0202/Infrastructures_S1/Public_Venue_Temple_S1.png"
|
||||
tsunami,50,50,"ersSymbolsV0202/Natural_Events/Hydro_Meteor_Tsunami_ch.png"
|
||||
twitter,32,32,Twitter.png
|
||||
ushahidi,31,32,Ushahidi.png
|
||||
vehicle,40,40,"ersSymbolsV0202/Operations_S1/Emergency_Vehicle_S1.png"
|
||||
volcano,50,50,"ersSymbolsV0202/Natural_Events/Geo_Volcanic_Threat.png"
|
||||
volunteer,40,39,Volunteer.png
|
||||
water,33,44,"ersSymbolsV0202/Infrastructures_S1/Water_Supply_Infrastructure_Theme_S1.png"
|
||||
warehouse,33,44,"ersSymbolsV0202/Infrastructures_S1/Agri_Commercial_Food_Distribution_Center_S1.png"
|
||||
warehouse_green,33,44,"ersSymbolsV0202/Infrastructures_S1/Agri_Commercial_Food_Distribution_Center_S1_green.png"
|
||||
warehouse_red,33,44,"ersSymbolsV0202/Infrastructures_S1/Agri_Commercial_Food_Distribution_Center_S1_red.png"
|
||||
warehouse_yellow,33,44,"ersSymbolsV0202/Infrastructures_S1/Agri_Commercial_Food_Distribution_Center_S1_yellow.png"
|
||||
youtube,32,32,YouTube.png
|
|
@ -0,0 +1,128 @@
|
||||
Type,Comments,KV:XX
|
||||
"Animal Die Off",,"EMS:animalHealth.animalDieOff"
|
||||
"Animal Feed",,"EMS:animalHealth.animalFeed"
|
||||
"Aircraft Crash",,"EMS:aviation.aircraftCrash"
|
||||
"Aircraft Hijacking",,"EMS:aviation.aircraftHijacking"
|
||||
"Airport Closure",,"EMS:aviation.airportClosure"
|
||||
"Airspace Closure",,"EMS:aviation.airspaceClosure"
|
||||
"Notice to Airmen",,"EMS:aviation.noticeToAirmen"
|
||||
"Space Debris",,"EMS:aviation.spaceDebris"
|
||||
"Demonstrations",,"EMS:civil.demonstrations"
|
||||
"Dignitary Visit",,"EMS:civil.dignitaryVisit"
|
||||
"Displaced Populations",,"EMS:civil.displacedPopulations"
|
||||
"Civil Emergency",,"EMS:civil.emergency"
|
||||
"Looting",,"EMS:civil.looting"
|
||||
"Public Event",,"EMS:civil.publicEvent"
|
||||
"Riot",,"EMS:civil.riot"
|
||||
"Volunteer Request",,"EMS:civil.volunteerRequest"
|
||||
"Crime",,"EMS:crime"
|
||||
"Bomb",,"EMS:crime.bomb"
|
||||
"Bomb Explosion",,"EMS:crime.bombExplosion"
|
||||
"Bomb Threat",,"EMS:crime.bombThreat"
|
||||
"Dangerous Person",,"EMS:crime.dangerousPerson"
|
||||
"Drugs",,"EMS:crime.drugs"
|
||||
"Home Crime",,"EMS:crime.homeCrime"
|
||||
"Illegal Immigrant",,"EMS:crime.illegalImmigrant"
|
||||
"Industrial Crime",,"EMS:crime.industrialCrime"
|
||||
"Poisoning",,"EMS:crime.poisoning"
|
||||
"Retail Crime",,"EMS:crime.retailCrime"
|
||||
"Shooting",,"EMS:crime.shooting"
|
||||
"Stowaway",,"EMS:crime.stowaway"
|
||||
"Terrorism",,"EMS:crime.terrorism"
|
||||
"Vehicle Crime",,"EMS:crime.vehicleCrime"
|
||||
"Fire",,"EMS:fire"
|
||||
"Forest Fire",,"EMS:fire.forestFire"
|
||||
"Hot Spot",,"EMS:fire.hotSpot"
|
||||
"Industry Fire",,"EMS:fire.industryFire"
|
||||
"Smoke",,"EMS:fire.smoke"
|
||||
"Urban Fire",,"EMS:fire.urbanFire"
|
||||
"Wild Fire",,"EMS:fire.wildFire"
|
||||
"Flood",,"EMS:flood"
|
||||
"Dam Overflow",,"EMS:flood.damOverflow"
|
||||
"Flash Flood",,"EMS:flood.flashFlood"
|
||||
"High Water",,"EMS:flood.highWater"
|
||||
"Overland Flow Flood",,"EMS:flood.overlandFlowFlood"
|
||||
"Tsunami",,"EMS:flood.tsunami"
|
||||
"Avalanche",,"EMS:geophysical.avalanche"
|
||||
"Earthquake",,"EMS:geophysical.earthquake"
|
||||
"Lahar",,"EMS:geophysical.lahar"
|
||||
"Landslide",,"EMS:geophysical.landslide"
|
||||
"Magnetic Storm",,"EMS:geophysical.magneticStorm"
|
||||
"Meteorite",,"EMS:geophysical.meteorite"
|
||||
"Pyroclastic Flow",,"EMS:geophysical.pyroclasticFlow"
|
||||
"Pyroclastic Surge",,"EMS:geophysical.pyroclasticSurge"
|
||||
"Volcanic Ash Cloud",,"EMS:geophysical.volcanicAshCloud"
|
||||
"Volcanic Event",,"EMS:geophysical.volcanicEvent"
|
||||
"Hazardous Material",,"EMS:hazardousMaterial"
|
||||
"Biological Hazard",,"EMS:hazardousMaterial.biologicalHazard"
|
||||
"Chemical Hazard",,"EMS:hazardousMaterial.chemicalHazard"
|
||||
"Explosive Hazard",,"EMS:hazardousMaterial.explosiveHazard"
|
||||
"Falling Object Hazard",,"EMS:hazardousMaterial.fallingObjectHazard"
|
||||
"Infectious Disease (Hazardous Material)",,"EMS:hazardousMaterial.infectiousDisease"
|
||||
"Poisonous Gas",,"EMS:hazardousMaterial.poisonousGas"
|
||||
"Radiological Hazard",,"EMS:hazardousMaterial.radiologicalHazard"
|
||||
"Infectious Disease",,"EMS:health.infectiousDisease"
|
||||
"Infestation",,"EMS:health.infestation"
|
||||
"Iceberg",,"EMS:ice.iceberg"
|
||||
"Ice Pressure",,"EMS:ice.icePressure"
|
||||
"Rapid Close Lead",,"EMS:ice.rapidCloseLead"
|
||||
"Special Ice",,"EMS:ice.specialIce"
|
||||
"Marine Security",,"EMS:marine.marineSecurity"
|
||||
"Nautical Accident",,"EMS:marine.nauticalAccident"
|
||||
"Nautical Hijacking",,"EMS:marine.nauticalHijacking"
|
||||
"Port Closure",,"EMS:marine.portClosure"
|
||||
"Special Marine",,"EMS:marine.specialMarine"
|
||||
"Blizzard",,"EMS:meteorological.blizzard"
|
||||
"Blowing Snow",,"EMS:meteorological.blowingSnow"
|
||||
"Drought",,"EMS:meteorological.drought"
|
||||
"Dust Storm",,"EMS:meteorological.dustStorm"
|
||||
"Fog",,"EMS:meteorological.fog"
|
||||
"Freezing Drizzle",,"EMS:meteorological.freezingDrizzle"
|
||||
"Freezing Rain",,"EMS:meteorological.freezingRain"
|
||||
"Freezing Spray",,"EMS:meteorological.freezingSpray"
|
||||
"Hail",,"EMS:meteorological.hail"
|
||||
"Hurricane",,"EMS:meteorological.hurricane"
|
||||
"Rain Fall",,"EMS:meteorological.rainFall"
|
||||
"Snow Fall",,"EMS:meteorological.snowFall"
|
||||
"Snow Squall",,"EMS:meteorological.snowSquall"
|
||||
"Squall",,"EMS:meteorological.squall"
|
||||
"Storm Surge",,"EMS:meteorological.stormSurge"
|
||||
"Thunderstorm",,"EMS:meteorological.thunderstorm"
|
||||
"Tornado",,"EMS:meteorological.tornado"
|
||||
"Tropical Storm",,"EMS:meteorological.tropicalStorm"
|
||||
"Waterspout",,"EMS:meteorological.waterspout"
|
||||
"Winter Storm",,"EMS:meteorological.winterStorm"
|
||||
"Missing Person",,"EMS:missingPerson"
|
||||
"Child Abduction Emergency","http://en.wikipedia.org/wiki/Amber_Alert","EMS:missingPerson.amberAlert"
|
||||
"Missing Vulnerable Person",,"EMS:missingPerson.missingVulnerablePerson"
|
||||
"Missing Senior Citizen","http://en.wikipedia.org/wiki/Silver_Alert","EMS:missingPerson.silver"
|
||||
"Emergency Support Facility",,"EMS:publicService.emergencySupportFacility"
|
||||
"Emergency Support Service",,"EMS:publicService.emergencySupportService"
|
||||
"School Closure",,"EMS:publicService.schoolClosure"
|
||||
"School Lockdown",,"EMS:publicService.schoolLockdown"
|
||||
"Service or Facility",,"EMS:publicService.serviceOrFacility"
|
||||
"Transit",,"EMS:publicService.transit"
|
||||
"Railway Accident",,"EMS:railway.railwayAccident"
|
||||
"Railway Hijacking",,"EMS:railway.railwayHijacking"
|
||||
"Bridge Closed",,"EMS:roadway.bridgeClosure"
|
||||
"Hazardous Road Conditions",,"EMS:roadway.hazardousRoadConditions"
|
||||
"Road Accident",,"EMS:roadway.roadwayAccident"
|
||||
"Road Closed",,"EMS:roadway.roadwayClosure"
|
||||
"Road Delay",,"EMS:roadway.roadwayDelay"
|
||||
"Road Hijacking",,"EMS:roadway.roadwayHijacking"
|
||||
"Road Usage Condition",,"EMS:roadway.roadwayUsageCondition"
|
||||
"Traffic Report",,"EMS:roadway.trafficReport"
|
||||
"Arctic Outflow",,"EMS:temperature.arcticOutflow"
|
||||
"Cold Wave",,"EMS:temperature.coldWave"
|
||||
"Flash Freeze",,"EMS:temperature.flashFreeze"
|
||||
"Frost",,"EMS:temperature.frost"
|
||||
"Heat and Humidity",,"EMS:temperature.heatAndHumidity"
|
||||
"Heat Wave",,"EMS:temperature.heatWave"
|
||||
"Wind Chill",,"EMS:temperature.windChill"
|
||||
"Gale Wind",,"EMS:wind.galeWind"
|
||||
"Hurricane Force Wind",,"EMS:wind.hurricaneForceWind"
|
||||
"Storm Force Wind",,"EMS:wind.stormForceWind"
|
||||
"Strong Wind",,"EMS:wind.strongWind"
|
||||
"Building Collapsed",,,
|
||||
"People Trapped",,,
|
||||
"Power Failure",,,
|
Can't render this file because it has a wrong number of fields in line 126.
|
@ -0,0 +1,293 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from gluon import *
|
||||
from gluon.storage import Storage
|
||||
from s3 import *
|
||||
#from s3theme import NAV, SECTION
|
||||
|
||||
# Below is an example which you can base your own template's layout.py on
|
||||
# - there are also other examples in the other templates folders
|
||||
# - you will need to restart web2py after making changes to this file
|
||||
|
||||
# =============================================================================
|
||||
#class S3MainMenuLayout(S3NavigationItem):
|
||||
# """
|
||||
# Application Main Menu Layout
|
||||
#
|
||||
# The layout() function takes an S3NavigationItem instance as input
|
||||
# and renders it as an HTML helper class instance. If the item can
|
||||
# or shall not be rendered on the page, this method must return None.
|
||||
#
|
||||
# S3NavigationItem instances provide a number of attributes and methods
|
||||
# to support context-sensisitve rendering (see modules/s3/s3navigation.py).
|
||||
#
|
||||
# Note that individual items can override the layout method by explicitly
|
||||
# setting the layout-property in the item's constructor.
|
||||
# """
|
||||
#
|
||||
# @staticmethod
|
||||
# def layout(item):
|
||||
# """ Custom Layout Method """
|
||||
#
|
||||
# @staticmethod
|
||||
# def layout(item):
|
||||
# """ Layout Method (Item Renderer) """
|
||||
#
|
||||
# # Manage flags: hide any disabled/unauthorized items
|
||||
# if not item.authorized and not item.opts.always_display:
|
||||
# item.enabled = False
|
||||
# item.visible = False
|
||||
# elif item.enabled is None or item.enabled:
|
||||
# item.enabled = True
|
||||
# item.visible = True
|
||||
#
|
||||
# if item.enabled and item.visible:
|
||||
#
|
||||
# items = item.render_components()
|
||||
# if item.parent is not None:
|
||||
#
|
||||
# if item.attr._class:
|
||||
# classes = item.attr._class.split(" ")
|
||||
# else:
|
||||
# classes = []
|
||||
#
|
||||
# if item.parent.parent is None:
|
||||
# # Item at the top-level?
|
||||
# toplevel = True
|
||||
# if item.opts.right:
|
||||
# classes.append("menu-right")
|
||||
# else:
|
||||
# toplevel = False
|
||||
#
|
||||
# if item.components:
|
||||
# classes.append("has-dropdown not-click")
|
||||
# _class = " ".join(classes)
|
||||
# # Menu item with Dropdown
|
||||
# if item.get_first(enabled=True):
|
||||
# _href = item.url()
|
||||
# return LI(A(item.label,
|
||||
# _href=_href,
|
||||
# _id=item.attr._id
|
||||
# ),
|
||||
# UL(items,
|
||||
# _class="dropdown"
|
||||
# ),
|
||||
# _class=_class,
|
||||
# )
|
||||
# else:
|
||||
# # Menu item without Drop-Down
|
||||
# if toplevel:
|
||||
# item_url = item.url()
|
||||
# if item_url == URL(c="default", f="index"):
|
||||
# classes.append("menu-home")
|
||||
# if item.selected:
|
||||
# classes.append("active")
|
||||
# _class = " ".join(classes)
|
||||
# return LI(A(item.label,
|
||||
# _href=item_url,
|
||||
# _id=item.attr._id,
|
||||
# _target=item.attr._target,
|
||||
# ),
|
||||
# _class=_class,
|
||||
# )
|
||||
# else:
|
||||
# # Submenu item
|
||||
# if isinstance(item.label, dict):
|
||||
# if "id" in item.label:
|
||||
# return S3MainMenuDefaultLayout.checkbox_item(item)
|
||||
# elif "name" in item.label:
|
||||
# label = item.label["name"]
|
||||
# else:
|
||||
# return None
|
||||
# else:
|
||||
# label = item.label
|
||||
# link = A(label,
|
||||
# _href=item.url(),
|
||||
# _id=item.attr._id,
|
||||
# _target=item.attr._target,
|
||||
# )
|
||||
# _class = " ".join(classes)
|
||||
# return LI(link, _class=_class)
|
||||
# else:
|
||||
# # The main menu itself
|
||||
# T = current.T
|
||||
# settings = current.deployment_settings
|
||||
#
|
||||
# if item.opts.title_area:
|
||||
# # Custom override
|
||||
# title_area = item.opts.title_area
|
||||
# else:
|
||||
# # Standard: render a menu logo
|
||||
# logo = settings.get_ui_menu_logo()
|
||||
# if logo is None:
|
||||
# # Render an icon
|
||||
# logo = SPAN(settings.get_system_name_short(),
|
||||
# _class="logo",
|
||||
# )
|
||||
# elif isinstance(logo, str):
|
||||
# # Assume image-URL
|
||||
# logo = IMG(_src = logo,
|
||||
# _class = "logo",
|
||||
# _alt = settings.get_system_name_short(),
|
||||
# )
|
||||
# #else:
|
||||
# # use as-is (assume HTML or T())
|
||||
# title_area = A(logo,
|
||||
# _href = URL(c="default", f="index"),
|
||||
# _title = T("Homepage"),
|
||||
# )
|
||||
#
|
||||
# # Arrange items left/right
|
||||
# right = []
|
||||
# left = []
|
||||
# for item in items:
|
||||
# if "menu-right" in item["_class"]:
|
||||
# item.remove_class("menu-right")
|
||||
# right.append(item)
|
||||
# else:
|
||||
# left.append(item)
|
||||
# right.reverse()
|
||||
#
|
||||
# # Reverse if right-to-left
|
||||
# if current.response.s3.rtl:
|
||||
# right, left = left, right
|
||||
#
|
||||
# # Build top-bar HTML
|
||||
# return NAV(UL(LI(title_area,
|
||||
# _class="name",
|
||||
# ),
|
||||
# LI(A(SPAN(T("Menu"))),
|
||||
# _class="toggle-topbar menu-icon",
|
||||
# ),
|
||||
# _class="title-area",
|
||||
# ),
|
||||
# SECTION(UL(right,
|
||||
# _class="right",
|
||||
# ),
|
||||
# UL(left,
|
||||
# _class="left",
|
||||
# ),
|
||||
# _class="top-bar-section",
|
||||
# ),
|
||||
# _class = "top-bar",
|
||||
# data = {"topbar": " "},
|
||||
# )
|
||||
# else:
|
||||
# return None
|
||||
#
|
||||
# # ---------------------------------------------------------------------
|
||||
# @staticmethod
|
||||
# def checkbox_item(item):
|
||||
# """ Render special active items """
|
||||
#
|
||||
# name = item.label
|
||||
# link = item.url()
|
||||
# _id = name["id"]
|
||||
# if "name" in name:
|
||||
# _name = name["name"]
|
||||
# else:
|
||||
# _name = ""
|
||||
# if "value" in name:
|
||||
# _value = name["value"]
|
||||
# else:
|
||||
# _value = False
|
||||
# if "request_type" in name:
|
||||
# _request_type = name["request_type"]
|
||||
# else:
|
||||
# _request_type = "ajax"
|
||||
# if link:
|
||||
# if _request_type == "ajax":
|
||||
# _onchange='''var val=$('#%s:checked').length;$.getS3('%s'+'?val='+val,null,false,null,false,false)''' % \
|
||||
# (_id, link)
|
||||
# else:
|
||||
# # Just load the page. Use this if the changed menu
|
||||
# # item should alter the contents of the page, and
|
||||
# # it's simpler just to load it.
|
||||
# _onchange="location.href='%s'" % link
|
||||
# else:
|
||||
# _onchange=None
|
||||
# return LI(A(INPUT(_type="checkbox",
|
||||
# _id=_id,
|
||||
# _onchange=_onchange,
|
||||
# value=_value,
|
||||
# ),
|
||||
# "%s" % _name,
|
||||
# _nowrap="nowrap",
|
||||
# ),
|
||||
# _class="menu-toggle",
|
||||
# )
|
||||
#
|
||||
# =============================================================================
|
||||
#class S3OptionsMenuLayout(S3NavigationItem):
|
||||
# """ Controller Options Menu Layout """
|
||||
#
|
||||
# @staticmethod
|
||||
# def layout(item):
|
||||
# """ Custom Layout Method """
|
||||
#
|
||||
# # Manage flags: hide any disabled/unauthorized items
|
||||
# if not item.authorized:
|
||||
# enabled = False
|
||||
# visible = False
|
||||
# elif item.enabled is None or item.enabled:
|
||||
# enabled = True
|
||||
# visible = True
|
||||
#
|
||||
# if enabled and visible:
|
||||
# if item.parent is not None:
|
||||
# if item.enabled and item.authorized:
|
||||
#
|
||||
# if item.components:
|
||||
# # Submenu
|
||||
# _class = ""
|
||||
# if item.parent.parent is None and item.selected:
|
||||
# _class = "active"
|
||||
#
|
||||
# section = [LI(A(item.label,
|
||||
# _href=item.url(),
|
||||
# _id=item.attr._id,
|
||||
# ),
|
||||
# _class="heading %s" % _class,
|
||||
# ),
|
||||
# ]
|
||||
#
|
||||
# items = item.render_components()
|
||||
# if items:
|
||||
# section.append(UL(items))
|
||||
# return section
|
||||
#
|
||||
# else:
|
||||
# # Submenu item
|
||||
# if item.parent.parent is None:
|
||||
# _class = "heading"
|
||||
# else:
|
||||
# _class = ""
|
||||
#
|
||||
# return LI(A(item.label,
|
||||
# _href=item.url(),
|
||||
# _id=item.attr._id,
|
||||
# ),
|
||||
# _class=_class,
|
||||
# )
|
||||
# else:
|
||||
# # Main menu
|
||||
# items = item.render_components()
|
||||
# return DIV(NAV(UL(items, _id="main-sub-menu", _class="side-nav")), _class="sidebar")
|
||||
#
|
||||
# else:
|
||||
# return None
|
||||
#
|
||||
# =============================================================================
|
||||
#class S3MenuSeparatorLayout(S3NavigationItem):
|
||||
# """ Simple menu separator """
|
||||
#
|
||||
# @staticmethod
|
||||
# def layout(item):
|
||||
# """ Custom Layout Method """
|
||||
#
|
||||
# if item.parent is not None:
|
||||
# return LI(_class="divider hide-for-small")
|
||||
# else:
|
||||
# return None
|
||||
#
|
||||
# END =========================================================================
|
@ -0,0 +1,49 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
import datetime
|
||||
import os
|
||||
import time
|
||||
|
||||
from gluon import current
|
||||
from gluon.settings import global_settings
|
||||
|
||||
# =============================================================================
|
||||
class Daily():
|
||||
""" Daily Maintenance Tasks """
|
||||
|
||||
def __call__(self):
|
||||
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
request = current.request
|
||||
|
||||
now = request.utcnow
|
||||
month_past = now - datetime.timedelta(weeks=4)
|
||||
|
||||
# Cleanup Scheduler logs
|
||||
table = s3db.scheduler_run
|
||||
db(table.start_time < month_past).delete()
|
||||
|
||||
# Cleanup Sync logs
|
||||
table = s3db.sync_log
|
||||
db(table.timestmp < month_past).delete()
|
||||
|
||||
# Cleanup Sessions
|
||||
osjoin = os.path.join
|
||||
osstat = os.stat
|
||||
osremove = os.remove
|
||||
folder = osjoin(global_settings.applications_parent,
|
||||
request.folder,
|
||||
"sessions")
|
||||
# Convert to UNIX time
|
||||
month_past_u = time.mktime(month_past.timetuple())
|
||||
for file in os.listdir(folder):
|
||||
filepath = osjoin(folder, file)
|
||||
status = osstat(filepath)
|
||||
if status.st_mtime < month_past_u:
|
||||
try:
|
||||
osremove(filepath)
|
||||
except:
|
||||
pass
|
||||
|
||||
# END =========================================================================
|
@ -0,0 +1,2 @@
|
||||
First Name,Last Name,Email,Password,Role,Organisation
|
||||
Admin,User,${SAHANA_ADMIN_USER},${SAHANA_ADMIN_PWD},ADMIN,
|
|
@ -0,0 +1,4 @@
|
||||
Name,Organisation
|
||||
"Normal Member",
|
||||
"Life Member",
|
||||
"Honorary Member",
|
|
@ -0,0 +1,116 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
from gluon import *
|
||||
from s3 import *
|
||||
from s3layouts import *
|
||||
try:
|
||||
from .layouts import *
|
||||
except ImportError:
|
||||
pass
|
||||
import s3menus as default
|
||||
|
||||
# Below is an example which you can base your own template's menus.py on
|
||||
# - there are also other examples in the other templates folders
|
||||
|
||||
# =============================================================================
|
||||
#class S3MainMenu(default.S3MainMenu):
|
||||
#"""
|
||||
#Custom Application Main Menu:
|
||||
|
||||
#The main menu consists of several sub-menus, each of which can
|
||||
#be customised separately as a method of this class. The overall
|
||||
#composition of the menu is defined in the menu() method, which can
|
||||
#be customised as well:
|
||||
|
||||
#Function Sub-Menu Access to (standard)
|
||||
|
||||
#menu_modules() the modules menu the Eden modules
|
||||
#menu_gis() the GIS menu GIS configurations
|
||||
#menu_admin() the Admin menu System/User Administration
|
||||
#menu_lang() the Language menu Selection of the GUI locale
|
||||
#menu_auth() the User menu Login, Logout, User Profile
|
||||
#menu_help() the Help menu Contact page, About page
|
||||
|
||||
#The standard uses the MM layout class for main menu items - but you
|
||||
#can of course use a custom layout class which you define in layouts.py.
|
||||
|
||||
#Additional sub-menus can simply be defined as additional functions in
|
||||
#this class, and then be included in the menu() method.
|
||||
|
||||
#Each sub-menu function returns a list of menu items, only the menu()
|
||||
#function must return a layout class instance.
|
||||
#"""
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
#@classmethod
|
||||
#def menu(cls):
|
||||
#""" Compose Menu """
|
||||
|
||||
#main_menu = MM()(
|
||||
|
||||
## Modules-menu, align-left
|
||||
#cls.menu_modules(),
|
||||
|
||||
## Service menus, align-right
|
||||
## Note: always define right-hand items in reverse order!
|
||||
#cls.menu_help(right=True),
|
||||
#cls.menu_auth(right=True),
|
||||
#cls.menu_lang(right=True),
|
||||
#cls.menu_admin(right=True),
|
||||
#cls.menu_gis(right=True)
|
||||
#)
|
||||
#return main_menu
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
#@classmethod
|
||||
#def menu_modules(cls):
|
||||
#""" Custom Modules Menu """
|
||||
|
||||
#return [
|
||||
#homepage(),
|
||||
#homepage("gis"),
|
||||
#homepage("pr")(
|
||||
#MM("Persons", f="person"),
|
||||
#MM("Groups", f="group")
|
||||
#),
|
||||
#MM("more", link=False)(
|
||||
#homepage("dvi"),
|
||||
#homepage("irs")
|
||||
#),
|
||||
#]
|
||||
|
||||
# =============================================================================
|
||||
#class S3OptionsMenu(default.S3OptionsMenu):
|
||||
#"""
|
||||
#Custom Controller Menus
|
||||
|
||||
#The options menu (left-hand options menu) is individual for each
|
||||
#controller, so each controller has its own options menu function
|
||||
#in this class.
|
||||
|
||||
#Each of these option menu functions can be customised separately,
|
||||
#by simply overriding (re-defining) the default function. The
|
||||
#options menu function must return an instance of the item layout.
|
||||
|
||||
#The standard menu uses the M item layout class, but you can of
|
||||
#course also use any other layout class which you define in
|
||||
#layouts.py (can also be mixed).
|
||||
|
||||
#Make sure additional helper functions in this class don't match
|
||||
#any current or future controller prefix (e.g. by using an
|
||||
#underscore prefix).
|
||||
#"""
|
||||
|
||||
#def cr(self):
|
||||
#""" CR / Shelter Registry """
|
||||
|
||||
#return M(c="cr")(
|
||||
#M("Camp", f="shelter")(
|
||||
#M("New", m="create"),
|
||||
#M("List All"),
|
||||
#M("Map", m="map"),
|
||||
#M("Import", m="import"),
|
||||
#)
|
||||
#)
|
||||
|
||||
# END =========================================================================
|
@ -0,0 +1,758 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# vim: ai ts=4 sts=4 et sw=4 encoding=utf-8
|
||||
|
||||
""" Monitoring
|
||||
|
||||
Template-specific Monitoring Tasks are defined here.
|
||||
|
||||
@copyright: 2014-2020 (c) Sahana Software Foundation
|
||||
@license: MIT
|
||||
|
||||
Permission is hereby granted, free of charge, to any person
|
||||
obtaining a copy of this software and associated documentation
|
||||
files (the "Software"), to deal in the Software without
|
||||
restriction, including without limitation the rights to use,
|
||||
copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the
|
||||
Software is furnished to do so, subject to the following
|
||||
conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
||||
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
||||
OTHER DEALINGS IN THE SOFTWARE.
|
||||
"""
|
||||
|
||||
__all__ = ("S3Monitor",)
|
||||
|
||||
import datetime
|
||||
import json
|
||||
import os
|
||||
import platform
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
from gluon import current
|
||||
|
||||
try:
|
||||
import requests
|
||||
except ImportError:
|
||||
REQUESTS = None
|
||||
else:
|
||||
REQUESTS = True
|
||||
|
||||
INSTANCE_TYPES = {"prod": 1,
|
||||
"setup": 2,
|
||||
"test": 3,
|
||||
"demo": 4,
|
||||
}
|
||||
|
||||
# =============================================================================
|
||||
class S3Monitor(object):
|
||||
"""
|
||||
Monitoring Check Scripts
|
||||
"""
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def diskspace(task_id, run_id):
|
||||
"""
|
||||
Test the free diskspace
|
||||
"""
|
||||
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
|
||||
# Read the Task Options
|
||||
ttable = s3db.setup_monitor_task
|
||||
task = db(ttable.id == task_id).select(ttable.options,
|
||||
ttable.server_id,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
options = task.options or {}
|
||||
options_get = options.get
|
||||
|
||||
partition = options_get("partition", "/") # Root Partition by default
|
||||
space_min = options_get("space_min", 1000000000) # 1 Gb
|
||||
|
||||
stable = s3db.setup_server
|
||||
server = db(stable.id == task.server_id).select(stable.host_ip,
|
||||
stable.remote_user,
|
||||
stable.private_key,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
|
||||
if server.host_ip == "127.0.0.1":
|
||||
result = os.statvfs(partition)
|
||||
space = result.f_bavail * result.f_frsize
|
||||
percent = float(result.f_bavail) / float(result.f_blocks) * 100
|
||||
if space < space_min:
|
||||
return {"result": "Warning: %s free (%d%%)" % \
|
||||
(_bytes_to_size_string(space), percent),
|
||||
"status": 2,
|
||||
}
|
||||
|
||||
return {"result": "OK. %s free (%d%%)" % \
|
||||
(_bytes_to_size_string(space), percent),
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
ssh = _ssh(server)
|
||||
if isinstance(ssh, dict):
|
||||
# We failed to login
|
||||
return ssh
|
||||
|
||||
command = "import os;result=os.statvfs('%s');print(result.f_bavail);print(result.f_frsize);print(result.f_blocks)" % partition
|
||||
stdin, stdout, stderr = ssh.exec_command('python -c "%s"' % command)
|
||||
outlines = stdout.readlines()
|
||||
ssh.close()
|
||||
|
||||
f_bavail = int(outlines[0])
|
||||
f_frsize = int(outlines[1])
|
||||
f_blocks = int(outlines[2])
|
||||
|
||||
space = f_bavail * f_frsize
|
||||
percent = float(f_bavail) / float(f_blocks) * 100
|
||||
if space < space_min:
|
||||
return {"result": "Warning: %s free (%d%%)" % \
|
||||
(_bytes_to_size_string(space), percent),
|
||||
"status": 2,
|
||||
}
|
||||
|
||||
return {"result": "OK. %s free (%d%%)" % \
|
||||
(_bytes_to_size_string(space), percent),
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def eden(task_id, run_id):
|
||||
"""
|
||||
Test that we can retrieve the public_url, which checks:
|
||||
- DNS must resolve to correct IP
|
||||
- Server must be up
|
||||
- Firewall cannot be blocking
|
||||
- Web server is running
|
||||
- UWSGI is running
|
||||
- Database is running
|
||||
- Eden can connect to Database
|
||||
"""
|
||||
|
||||
if REQUESTS is None:
|
||||
return {"result": "Critical: Requests library not installed",
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
|
||||
# Read the Task Options
|
||||
ttable = s3db.setup_monitor_task
|
||||
task = db(ttable.id == task_id).select(ttable.options,
|
||||
ttable.deployment_id,
|
||||
ttable.server_id,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
options = task.options or {}
|
||||
options_get = options.get
|
||||
|
||||
appname = options_get("appname", "eden")
|
||||
public_url = options_get("public_url")
|
||||
timeout = options_get("timeout", 60) # 60s (default is no timeout!)
|
||||
|
||||
if not public_url:
|
||||
deployment_id = task.deployment_id
|
||||
if deployment_id:
|
||||
# Read from the instance
|
||||
itable = s3db.setup_instance
|
||||
query = (itable.deployment_id == deployment_id) & \
|
||||
(itable.type == 1)
|
||||
instance = db(query).select(itable.url,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
if instance:
|
||||
public_url = instance.url
|
||||
if not public_url:
|
||||
# Use the server name
|
||||
stable = s3db.setup_server
|
||||
server = db(stable.id == task.server_id).select(stable.name,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
public_url = "https://%s" % server.name
|
||||
|
||||
url = "%(public_url)s/%(appname)s/default/public_url" % {"appname": appname,
|
||||
"public_url": public_url,
|
||||
}
|
||||
|
||||
try:
|
||||
r = requests.get(url, timeout = timeout) # verify=True
|
||||
except requests.exceptions.SSLError:
|
||||
# e.g. Expired Certificate
|
||||
import traceback
|
||||
tb_parts = sys.exc_info()
|
||||
tb_text = "".join(traceback.format_exception(tb_parts[0],
|
||||
tb_parts[1],
|
||||
tb_parts[2]))
|
||||
return {"result": "Critical: SSL Error\n\n%s" % tb_text,
|
||||
"status": 3,
|
||||
}
|
||||
except requests.exceptions.Timeout:
|
||||
import traceback
|
||||
tb_parts = sys.exc_info()
|
||||
tb_text = "".join(traceback.format_exception(tb_parts[0],
|
||||
tb_parts[1],
|
||||
tb_parts[2]))
|
||||
return {"result": "Critical: Timeout Error\n\n%s" % tb_text,
|
||||
"status": 3,
|
||||
}
|
||||
except requests.exceptions.TooManyRedirects:
|
||||
import traceback
|
||||
tb_parts = sys.exc_info()
|
||||
tb_text = "".join(traceback.format_exception(tb_parts[0],
|
||||
tb_parts[1],
|
||||
tb_parts[2]))
|
||||
return {"result": "Critical: TooManyRedirects Error\n\n%s" % tb_text,
|
||||
"status": 3,
|
||||
}
|
||||
except requests.exceptions.ConnectionError:
|
||||
# e.g. DNS Error
|
||||
import traceback
|
||||
tb_parts = sys.exc_info()
|
||||
tb_text = "".join(traceback.format_exception(tb_parts[0],
|
||||
tb_parts[1],
|
||||
tb_parts[2]))
|
||||
return {"result": "Critical: Connection Error\n\n%s" % tb_text,
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
if r.status_code != 200:
|
||||
return {"result": "Critical: HTTP Error. Status = %s" % r.status_code,
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
if r.text != public_url:
|
||||
return {"result": "Critical: Page returned '%s' instead of '%s'" % \
|
||||
(r.text, public_url),
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
latency = int(r.elapsed.microseconds / 1000)
|
||||
latency_max = options_get("latency_max", 2000) # 2 seconds
|
||||
if latency > latency_max:
|
||||
return {"result": "Warning: Latency of %s exceeded threshold of %s." % \
|
||||
(latency, latency_max),
|
||||
"status": 2,
|
||||
}
|
||||
|
||||
return {"result": "OK. Latency: %s" % latency,
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def email_round_trip(task_id, run_id):
|
||||
"""
|
||||
Check that a Mailbox is being Polled & Parsed OK and can send replies
|
||||
"""
|
||||
|
||||
# Read the Task Options
|
||||
ttable = current.s3db.setup_monitor_task
|
||||
task = current.db(ttable.id == task_id).select(ttable.options,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
options = task.options or {}
|
||||
options_get = options.get
|
||||
|
||||
to = options_get("to", None)
|
||||
if not to:
|
||||
return {"result": "Critical: No recipient address specified",
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
subject = options_get("subject", "")
|
||||
message = options_get("message", "")
|
||||
reply_to = options_get("reply_to")
|
||||
if not reply_to:
|
||||
# Use the outbound email address
|
||||
reply_to = current.deployment_settings.get_mail_sender()
|
||||
if not reply_to:
|
||||
return {"result": "Critical: No reply_to specified",
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
# Append the run_id for the remote parser to identify as a monitoring message & return to us to be able to match the run
|
||||
message = "%s\n%s" % (message, ":run_id:%s:" % run_id)
|
||||
|
||||
# Append the reply_to address for the remote parser
|
||||
message = "%s\n%s" % (message, ":reply_to:%s:" % reply_to)
|
||||
|
||||
# Send the Email
|
||||
result = current.msg.send_email(to,
|
||||
subject,
|
||||
message,
|
||||
reply_to = reply_to)
|
||||
|
||||
if result:
|
||||
# Schedule a task to see if the reply has arrived
|
||||
wait = options_get("wait", 60) # Default = 60 minutes
|
||||
start_time = datetime.datetime.utcnow() + \
|
||||
datetime.timedelta(minutes = wait)
|
||||
current.s3task.schedule_task("setup_monitor_check_email_reply",
|
||||
args = [run_id],
|
||||
start_time = start_time,
|
||||
timeout = 300, # seconds
|
||||
repeats = 1 # one-time
|
||||
)
|
||||
return {"result": "OK so far: Waiting for Reply",
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
return {"result": "Critical: Unable to send Email",
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def http(task_id, run_id):
|
||||
"""
|
||||
Test that HTTP is accessible
|
||||
"""
|
||||
|
||||
if REQUESTS is None:
|
||||
return {"result": "Critical: Requests library not installed",
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
raise NotImplementedError
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def https(task_id, run_id):
|
||||
"""
|
||||
Test that HTTP is accessible
|
||||
"""
|
||||
|
||||
if REQUESTS is None:
|
||||
return {"result": "Critical: Requests library not installed",
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
raise NotImplementedError
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def load_average(task_id, run_id):
|
||||
"""
|
||||
Test the Load Average
|
||||
"""
|
||||
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
|
||||
# Read the Task Options
|
||||
ttable = s3db.setup_monitor_task
|
||||
task = db(ttable.id == task_id).select(ttable.options,
|
||||
ttable.server_id,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
options = task.options or {}
|
||||
options_get = options.get
|
||||
|
||||
which = options_get("which", 2) # 15 min average
|
||||
load_max = options_get("load_max", 2)
|
||||
|
||||
stable = s3db.setup_server
|
||||
server = db(stable.id == task.server_id).select(stable.host_ip,
|
||||
stable.remote_user,
|
||||
stable.private_key,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
|
||||
if server.host_ip == "127.0.0.1":
|
||||
loadavg = os.getloadavg()
|
||||
if loadavg[which] > load_max:
|
||||
return {"result": "Warning: load average: %0.2f, %0.2f, %0.2f" % \
|
||||
(loadavg[0], loadavg[1], loadavg[2]),
|
||||
"status": 2,
|
||||
}
|
||||
|
||||
return {"result": "OK. load average: %0.2f, %0.2f, %0.2f" % \
|
||||
(loadavg[0], loadavg[1], loadavg[2]),
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
ssh = _ssh(server)
|
||||
if isinstance(ssh, dict):
|
||||
# We failed to login
|
||||
return ssh
|
||||
|
||||
command = "import os;loadavg=os.getloadavg();print(loadavg[0]);print(loadavg[1]);print(loadavg[2])"
|
||||
stdin, stdout, stderr = ssh.exec_command('python -c "%s"' % command)
|
||||
outlines = stdout.readlines()
|
||||
ssh.close()
|
||||
|
||||
loadavg = {0: float(outlines[0]),
|
||||
1: float(outlines[1]),
|
||||
2: float(outlines[2]),
|
||||
}
|
||||
|
||||
if loadavg[which] > load_max:
|
||||
return {"result": "Warning: load average: %0.2f, %0.2f, %0.2f" % \
|
||||
(loadavg[0], loadavg[1], loadavg[2]),
|
||||
"status": 2,
|
||||
}
|
||||
|
||||
return {"result": "OK. load average: %0.2f, %0.2f, %0.2f" % \
|
||||
(loadavg[0], loadavg[1], loadavg[2]),
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def ping(task_id, run_id):
|
||||
"""
|
||||
ICMP Ping a server
|
||||
- NB AWS instances don't respond to ICMP Ping by default, but this can be enabled in the Firewall
|
||||
"""
|
||||
|
||||
s3db = current.s3db
|
||||
|
||||
# Read the IP to Ping
|
||||
ttable = s3db.setup_monitor_task
|
||||
stable = s3db.setup_server
|
||||
query = (ttable.id == task_id) & \
|
||||
(ttable.server_id == stable.id)
|
||||
row = current.db(query).select(stable.host_ip,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
|
||||
host_ip = row.host_ip
|
||||
|
||||
try:
|
||||
# @ToDo: Replace with socket?
|
||||
# - we want to see the latency
|
||||
if platform.system().lower == "windows":
|
||||
_format = "n"
|
||||
else:
|
||||
_format = "c"
|
||||
output = subprocess.check_output("ping -{} 1 {}".format(_format,
|
||||
host_ip),
|
||||
shell = True)
|
||||
except Exception:
|
||||
import traceback
|
||||
tb_parts = sys.exc_info()
|
||||
tb_text = "".join(traceback.format_exception(tb_parts[0],
|
||||
tb_parts[1],
|
||||
tb_parts[2]))
|
||||
return {"result": "Critical: Ping failed\n\n%s" % tb_text,
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
return {"result": "OK",
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def scheduler(task_id, run_id):
|
||||
"""
|
||||
Test whether the scheduler is running
|
||||
"""
|
||||
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
|
||||
# Read the Task Options
|
||||
ttable = s3db.setup_monitor_task
|
||||
task = db(ttable.id == task_id).select(ttable.options,
|
||||
ttable.server_id,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
options = task.options or {}
|
||||
options_get = options.get
|
||||
|
||||
stable = s3db.setup_server
|
||||
server = db(stable.id == task.server_id).select(stable.host_ip,
|
||||
stable.remote_user,
|
||||
stable.private_key,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
|
||||
earliest = current.request.utcnow - datetime.timedelta(seconds = 900) # 15 minutes
|
||||
|
||||
if server.host_ip == "127.0.0.1":
|
||||
# This shouldn't make much sense as a check, since this won't run if the scheduler has died
|
||||
# - however in practise, it can actually provide useful warning!
|
||||
|
||||
wtable = s3db.scheduler_worker
|
||||
worker = db(wtable.status == "ACTIVE").select(wtable.last_heartbeat,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
|
||||
error = None
|
||||
if worker is None:
|
||||
error = "Warning: Scheduler not ACTIVE"
|
||||
|
||||
elif worker.last_heartbeat < earliest:
|
||||
error = "Warning: Scheduler stalled since %s" % worker.last_heartbeat.strftime("%H:%M %a %d %b")
|
||||
|
||||
if error:
|
||||
appname = options_get("appname", "eden")
|
||||
instance = options_get("instance", "prod")
|
||||
|
||||
# Restart uwsgi
|
||||
error += "\n\nAttempting to restart:\n"
|
||||
# Note this needs to actually run after last task as it kills us ;)
|
||||
# NB Need to ensure the web2py user has permission to run sudo
|
||||
command = 'echo "sudo service uwsgi-%s restart" | at now + 1 minutes' % instance
|
||||
output = subprocess.check_output(command,
|
||||
stderr = subprocess.STDOUT,
|
||||
shell = True)
|
||||
error += output.decode("utf-8")
|
||||
# Restart Monitoring Scripts
|
||||
command = 'echo "cd /home/%s;python web2py.py --no-banner -S %s -M -R applications/%s/static/scripts/tools/restart_monitor_tasks.py" | at now + 5 minutes' % \
|
||||
(instance, appname, appname)
|
||||
output = subprocess.check_output(command,
|
||||
stderr = subprocess.STDOUT,
|
||||
shell = True)
|
||||
error += output.decode("utf-8")
|
||||
return {"result": error,
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
return {"result": "OK",
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
|
||||
ssh = _ssh(server)
|
||||
if isinstance(ssh, dict):
|
||||
# We failed to login
|
||||
return ssh
|
||||
|
||||
appname = options_get("appname", "eden")
|
||||
instance = options_get("instance", "prod")
|
||||
|
||||
command = "cd /home/%s;python web2py.py --no-banner -S %s -M -R applications/%s/static/scripts/tools/check_scheduler.py -A '%s'" % \
|
||||
(instance, appname, appname, earliest)
|
||||
stdin, stdout, stderr = ssh.exec_command(command)
|
||||
outlines = stdout.readlines()
|
||||
|
||||
if outlines:
|
||||
error = outlines[0]
|
||||
# Restart uwsgi
|
||||
error += "\n\nAttempting to restart:\n"
|
||||
command = "sudo service uwsgi-%s restart" % instance
|
||||
stdin, stdout, stderr = ssh.exec_command(command)
|
||||
outlines = stdout.readlines()
|
||||
if outlines:
|
||||
error += "\n".join(outlines)
|
||||
else:
|
||||
# Doesn't usually give any output
|
||||
error += "OK"
|
||||
ssh.close()
|
||||
return {"result": error,
|
||||
"status": 3,
|
||||
}
|
||||
ssh.close()
|
||||
|
||||
return {"result": "OK",
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def tcp(task_id, run_id):
|
||||
"""
|
||||
Test that a TCP port is accessible
|
||||
"""
|
||||
|
||||
raise NotImplementedError
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def tickets(task_id, run_id):
|
||||
"""
|
||||
Test whether there are new tickets today
|
||||
- designed to be run daily (period 86400s)
|
||||
"""
|
||||
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
|
||||
# Read the Task Options
|
||||
ttable = s3db.setup_monitor_task
|
||||
task = db(ttable.id == task_id).select(ttable.options,
|
||||
#ttable.period,
|
||||
ttable.server_id,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
options = task.options or {}
|
||||
options_get = options.get
|
||||
|
||||
stable = s3db.setup_server
|
||||
server = db(stable.id == task.server_id).select(stable.host_ip,
|
||||
stable.remote_user,
|
||||
stable.private_key,
|
||||
stable.deployment_id,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
|
||||
request = current.request
|
||||
today = request.utcnow.date().isoformat()
|
||||
|
||||
if server.host_ip == "127.0.0.1":
|
||||
appname = request.application
|
||||
public_url = current.deployment_settings.get_base_public_url()
|
||||
tickets = os.listdir("applications/%s/errors" % appname)
|
||||
new = []
|
||||
for ticket in tickets:
|
||||
#if os.stat(ticket).st_mtime < now - task.period:
|
||||
if today in ticket:
|
||||
url = "%s/%s/admin/ticket/%s/%s" % (public_url,
|
||||
appname,
|
||||
appname,
|
||||
ticket,
|
||||
)
|
||||
new.append(url)
|
||||
|
||||
if new:
|
||||
return {"result": "Warning: New tickets:\n\n%s" % "\n".join(new),
|
||||
"status": 2,
|
||||
}
|
||||
|
||||
return {"result": "OK",
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
ssh = _ssh(server)
|
||||
if isinstance(ssh, dict):
|
||||
# We failed to login
|
||||
return ssh
|
||||
|
||||
appname = options_get("appname", "eden")
|
||||
instance = options_get("instance", "prod")
|
||||
|
||||
command = "import os;ts=os.listdir('/home/%s/applications/%s/errors');for t in ts:print(t) if '%s' in t" % \
|
||||
(instance, appname, today)
|
||||
stdin, stdout, stderr = ssh.exec_command('python -c "%s"' % command)
|
||||
outlines = stdout.readlines()
|
||||
ssh.close()
|
||||
|
||||
if outlines:
|
||||
itable = s3db.setup_instance
|
||||
query = (itable.deployment_id == server.deployment_id) & \
|
||||
(itable.type == INSTANCE_TYPES[instance])
|
||||
instance = db(query).select(itable.url,
|
||||
limitby = (0, 1)
|
||||
).first()
|
||||
public_url = instance.url
|
||||
new = []
|
||||
for ticket in outlines:
|
||||
url = "%s/%s/admin/ticket/%s/%s" % (public_url,
|
||||
appname,
|
||||
appname,
|
||||
ticket,
|
||||
)
|
||||
new.append(url)
|
||||
return {"result": "Warning: New tickets:\n\n%s" % "\n".join(new),
|
||||
"status": 2,
|
||||
}
|
||||
|
||||
return {"result": "OK",
|
||||
"status": 1,
|
||||
}
|
||||
|
||||
# =============================================================================
|
||||
def _bytes_to_size_string(b):
|
||||
#def _bytes_to_size_string(b: int) -> str:
|
||||
"""
|
||||
Convert a number in bytes to a sensible unit.
|
||||
|
||||
From https://github.com/jamesoff/simplemonitor/blob/develop/simplemonitor/Monitors/host.py#L35
|
||||
"""
|
||||
|
||||
kb = 1024
|
||||
mb = kb * 1024
|
||||
gb = mb * 1024
|
||||
tb = gb * 1024
|
||||
|
||||
if b > tb:
|
||||
return "%0.2fTiB" % (b / float(tb))
|
||||
elif b > gb:
|
||||
return "%0.2fGiB" % (b / float(gb))
|
||||
elif b > mb:
|
||||
return "%0.2fMiB" % (b / float(mb))
|
||||
elif b > kb:
|
||||
return "%0.2fKiB" % (b / float(kb))
|
||||
else:
|
||||
return str(b)
|
||||
|
||||
# =============================================================================
|
||||
def _ssh(server):
|
||||
"""
|
||||
SSH into a Server
|
||||
"""
|
||||
|
||||
remote_user = server.remote_user
|
||||
private_key = server.private_key
|
||||
if not private_key or not remote_user:
|
||||
if remote_user:
|
||||
return {"result": "Critical. Missing Private Key",
|
||||
"status": 3,
|
||||
}
|
||||
elif private_key:
|
||||
return {"result": "Critical. Missing Remote User",
|
||||
"status": 3,
|
||||
}
|
||||
else:
|
||||
return {"result": "Critical. Missing Remote User & Private Key",
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
# SSH in & run check
|
||||
try:
|
||||
import paramiko
|
||||
except ImportError:
|
||||
return {"result": "Critical. Paramiko required.",
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
keyfile = open(os.path.join(current.request.folder, "uploads", private_key), "r")
|
||||
mykey = paramiko.RSAKey.from_private_key(keyfile)
|
||||
|
||||
ssh = paramiko.SSHClient()
|
||||
ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
|
||||
try:
|
||||
ssh.connect(hostname = server.host_ip,
|
||||
username = remote_user,
|
||||
pkey = mykey)
|
||||
except paramiko.ssh_exception.AuthenticationException:
|
||||
import traceback
|
||||
tb_parts = sys.exc_info()
|
||||
tb_text = "".join(traceback.format_exception(tb_parts[0],
|
||||
tb_parts[1],
|
||||
tb_parts[2]))
|
||||
return {"result": "Critical. Authentication Error\n\n%s" % tb_text,
|
||||
"status": 3,
|
||||
}
|
||||
except paramiko.ssh_exception.SSHException:
|
||||
import traceback
|
||||
tb_parts = sys.exc_info()
|
||||
tb_text = "".join(traceback.format_exception(tb_parts[0],
|
||||
tb_parts[1],
|
||||
tb_parts[2]))
|
||||
return {"result": "Critical. SSH Error\n\n%s" % tb_text,
|
||||
"status": 3,
|
||||
}
|
||||
|
||||
return ssh
|
||||
|
||||
# END =========================================================================
|
@ -0,0 +1,5 @@
|
||||
Name,Comments,KV:XX
|
||||
Headquarters,,
|
||||
Regional,,
|
||||
National,,
|
||||
Field,,
|
|
@ -0,0 +1,24 @@
|
||||
Abrv,Name,SubsectorOf
|
||||
"Agriculture","Agriculture",
|
||||
"Camp","Camp Coordination/Management",
|
||||
"Recovery","Early Recovery",
|
||||
"Education","Education",
|
||||
"Shelter","Emergency Shelter",
|
||||
"Telecommunications","Emergency Telecommunications",
|
||||
"Health","Health",
|
||||
"Logistics","Logistics",
|
||||
"Nutrition","Nutrition",
|
||||
"Protection","Protection",
|
||||
"WASH","Water Sanitation Hygiene",
|
||||
"Clothing",,"Shelter"
|
||||
"Shelter",,"Shelter"
|
||||
"Cooking NFIs",,"Nutrition"
|
||||
"Food Supply",,"Nutrition"
|
||||
"Aggravating factors",,"WASH"
|
||||
"Disease vectors",,"WASH"
|
||||
"Drainage",,"WASH"
|
||||
"Excreta disposal",,"WASH"
|
||||
"Hygiene NFIs",,"WASH"
|
||||
"Hygiene practice",,"WASH"
|
||||
"Solid waste",,"WASH"
|
||||
"Water supply",,"WASH"
|
|
@ -0,0 +1,11 @@
|
||||
Type,Comments
|
||||
Academic,
|
||||
Bilateral,Donor
|
||||
Government,
|
||||
Intergovernmental,
|
||||
Military,
|
||||
NGO,
|
||||
Private,Organisation/Foundation
|
||||
Red Cross / Red Crescent,
|
||||
Supplier,
|
||||
UN agency,
|
|
@ -0,0 +1,683 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
# vim: ai ts=4 sts=4 et sw=4 encoding=utf-8
|
||||
|
||||
""" Message Parsing
|
||||
|
||||
Template-specific Message Parsers are defined here.
|
||||
|
||||
@copyright: 2012-2020 (c) Sahana Software Foundation
|
||||
@license: MIT
|
||||
|
||||
Permission is hereby granted, free of charge, to any person
|
||||
obtaining a copy of this software and associated documentation
|
||||
files (the "Software"), to deal in the Software without
|
||||
restriction, including without limitation the rights to use,
|
||||
copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the
|
||||
Software is furnished to do so, subject to the following
|
||||
conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be
|
||||
included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
|
||||
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
|
||||
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
||||
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
|
||||
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
||||
OTHER DEALINGS IN THE SOFTWARE.
|
||||
"""
|
||||
|
||||
__all__ = ("S3Parser",)
|
||||
|
||||
#import re
|
||||
|
||||
#import pyparsing
|
||||
try:
|
||||
import nltk
|
||||
from nltk.corpus import wordnet as wn
|
||||
NLTK = True
|
||||
except:
|
||||
NLTK = False
|
||||
|
||||
from gluon import current
|
||||
from gluon.tools import fetch
|
||||
|
||||
from s3.s3fields import S3Represent
|
||||
from s3.s3parser import S3Parsing
|
||||
from s3.s3utils import soundex
|
||||
|
||||
# =============================================================================
|
||||
class S3Parser(object):
|
||||
"""
|
||||
Message Parsing Template
|
||||
"""
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def parse_email(message):
|
||||
"""
|
||||
Parse Responses
|
||||
- parse responses to mails from the Monitor service
|
||||
"""
|
||||
|
||||
reply = None
|
||||
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
|
||||
# Need to use Raw currently as not showing in Body
|
||||
message_id = message.message_id
|
||||
table = s3db.msg_email
|
||||
record = db(table.message_id == message_id).select(table.raw,
|
||||
limitby=(0, 1)
|
||||
).first()
|
||||
if not record:
|
||||
return reply
|
||||
|
||||
message_body = record.raw
|
||||
if not message_body:
|
||||
return reply
|
||||
|
||||
# What type of message is this?
|
||||
if ":run_id:" in message_body:
|
||||
# Response to Monitor Check
|
||||
|
||||
# Parse Mail
|
||||
try:
|
||||
run_id = S3Parser._parse_value(message_body, "run_id")
|
||||
run_id = int(run_id)
|
||||
except:
|
||||
return reply
|
||||
|
||||
# Update the Run entry to show that we have received the reply OK
|
||||
rtable = s3db.monitor_run
|
||||
db(rtable.id == run_id).update(result = "Reply Received",
|
||||
status = 1)
|
||||
return reply
|
||||
|
||||
else:
|
||||
# Don't know what this is: ignore
|
||||
return reply
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def parse_twitter(message):
|
||||
"""
|
||||
Filter unstructured tweets
|
||||
"""
|
||||
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
cache = s3db.cache
|
||||
|
||||
# Start with a base priority
|
||||
priority = 0
|
||||
|
||||
# Default Category
|
||||
category = "Unknown"
|
||||
|
||||
# Lookup the channel type
|
||||
#ctable = s3db.msg_channel
|
||||
#channel = db(ctable.channel_id == message.channel_id).select(ctable.instance_type,
|
||||
# limitby=(0, 1)
|
||||
# ).first()
|
||||
#service = channel.instance_type.split("_", 2)[1]
|
||||
#if service in ("mcommons", "tropo", "twilio"):
|
||||
# service = "sms"
|
||||
#if service == "twitter":
|
||||
# priority -= 1
|
||||
#elif service == "sms":
|
||||
# priority += 1
|
||||
service = "twitter"
|
||||
|
||||
# Lookup trusted senders
|
||||
# - these could be trained or just trusted
|
||||
table = s3db.msg_sender
|
||||
ctable = s3db.pr_contact
|
||||
query = (table.deleted == False) & \
|
||||
(ctable.pe_id == table.pe_id) & \
|
||||
(ctable.contact_method == "TWITTER")
|
||||
senders = db(query).select(table.priority,
|
||||
ctable.value,
|
||||
cache=cache)
|
||||
for s in senders:
|
||||
if sender == s[ctable].value:
|
||||
priority += s[table].priority
|
||||
break
|
||||
|
||||
# If Anonymous, check their history
|
||||
# - within our database
|
||||
# if service == "twitter":
|
||||
# # Check Followers
|
||||
# # Check Retweets
|
||||
# # Check when account was created
|
||||
# (Note that it is still possible to game this - plausible accounts can be purchased)
|
||||
|
||||
ktable = s3db.msg_keyword
|
||||
keywords = db(ktable.deleted == False).select(ktable.id,
|
||||
ktable.keyword,
|
||||
ktable.incident_type_id,
|
||||
cache=cache)
|
||||
incident_type_represent = S3Represent(lookup="event_incident_type")
|
||||
if NLTK:
|
||||
# Lookup synonyms
|
||||
# @ToDo: Cache
|
||||
synonyms = {}
|
||||
for kw in keywords:
|
||||
syns = []
|
||||
try:
|
||||
synsets = wn.synsets(kw.keyword)
|
||||
for synset in synsets:
|
||||
syns += [lemma.name for lemma in synset.lemmas]
|
||||
except LookupError:
|
||||
nltk.download("wordnet")
|
||||
synsets = wn.synsets(kw.keyword)
|
||||
for synset in synsets:
|
||||
syns += [lemma.name for lemma in synset.lemmas]
|
||||
synonyms[kw.keyword.lower()] = syns
|
||||
|
||||
ltable = s3db.gis_location
|
||||
query = (ltable.deleted != True) & \
|
||||
(ltable.name != None)
|
||||
locs = db(query).select(ltable.id,
|
||||
ltable.name,
|
||||
cache=cache)
|
||||
lat = lon = None
|
||||
location_id = None
|
||||
loc_matches = 0
|
||||
|
||||
# Split message into words
|
||||
words = message.split(" ")
|
||||
|
||||
index = 0
|
||||
max_index = len(words) - 1
|
||||
for word in words:
|
||||
word = word.lower()
|
||||
if word.endswith(".") or \
|
||||
word.endswith(":") or \
|
||||
word.endswith(","):
|
||||
word = word[:-1]
|
||||
|
||||
skip = False
|
||||
|
||||
if word in ("safe", "ok"):
|
||||
priority -= 1
|
||||
elif word in ("help"):
|
||||
priority += 1
|
||||
elif service == "twitter" and \
|
||||
word == "RT":
|
||||
# @ToDo: Increase priority of the original message
|
||||
priority -= 1
|
||||
skip = True
|
||||
|
||||
# Look for URL
|
||||
if word.startswith("http://"):
|
||||
priority += 1
|
||||
skip = True
|
||||
# @ToDo: Follow URL to see if we can find an image
|
||||
#try:
|
||||
# page = fetch(word)
|
||||
#except urllib2.HTTPError:
|
||||
# pass
|
||||
# Check returned str for image like IS_IMAGE()
|
||||
|
||||
if (index < max_index):
|
||||
if word == "lat":
|
||||
skip = True
|
||||
try:
|
||||
lat = words[index + 1]
|
||||
lat = float(lat)
|
||||
except:
|
||||
pass
|
||||
elif word == "lon":
|
||||
skip = True
|
||||
try:
|
||||
lon = words[index + 1]
|
||||
lon = float(lon)
|
||||
except:
|
||||
pass
|
||||
|
||||
if not skip:
|
||||
for kw in keywords:
|
||||
_word = kw.keyword.lower()
|
||||
if _word == word:
|
||||
# Check for negation
|
||||
if index and words[index - 1].lower() == "no":
|
||||
pass
|
||||
else:
|
||||
category = incident_type_represent(kw.incident_type_id)
|
||||
break
|
||||
elif NLTK:
|
||||
# Synonyms
|
||||
if word in synonyms[_word]:
|
||||
# Check for negation
|
||||
if index and words[index - 1].lower() == "no":
|
||||
pass
|
||||
else:
|
||||
category = incident_type_represent(kw.incident_type_id)
|
||||
break
|
||||
# Check for Location
|
||||
for loc in locs:
|
||||
name = loc.name.lower()
|
||||
# @ToDo: Do a Unicode comparison
|
||||
if word == name:
|
||||
if not loc_matches:
|
||||
location_id = loc.id
|
||||
priority += 1
|
||||
loc_matches += 1
|
||||
elif (index < max_index) and \
|
||||
("%s %s" % (word, words[index + 1]) == name):
|
||||
# Try names with 2 words
|
||||
if not loc_matches:
|
||||
location_id = loc.id
|
||||
priority += 1
|
||||
loc_matches += 1
|
||||
|
||||
index += 1
|
||||
|
||||
# @ToDo: Prioritise reports from people located where they are reporting from
|
||||
# if coordinates:
|
||||
|
||||
if not loc_matches or loc_matches > 1:
|
||||
if lat and lon:
|
||||
location_id = ltable.insert(lat = lat,
|
||||
lon = lon)
|
||||
elif service == "twitter":
|
||||
# @ToDo: Use Geolocation of Tweet
|
||||
#location_id =
|
||||
pass
|
||||
|
||||
# @ToDo: Update records inside this function with parsed data
|
||||
# @ToDo: Image
|
||||
#return category, priority, location_id
|
||||
|
||||
# No reply here
|
||||
return None
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
def search_resource(self, message):
|
||||
"""
|
||||
1st Pass Parser for searching resources
|
||||
- currently supports people, hospitals and organisations.
|
||||
"""
|
||||
|
||||
message_body = message.body
|
||||
if not message_body:
|
||||
return None
|
||||
|
||||
pquery, name = self._parse_keywords(message_body)
|
||||
|
||||
if "person" in pquery:
|
||||
reply = self.search_person(message, pquery, name)
|
||||
elif "hospital" in pquery:
|
||||
reply = self.search_hospital(message, pquery, name)
|
||||
elif "organisation" in pquery:
|
||||
reply = self.search_organisation(message, pquery, name)
|
||||
else:
|
||||
reply = None
|
||||
|
||||
return reply
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
def search_person(self, message, pquery=None, name=None):
|
||||
"""
|
||||
Search for People
|
||||
- can be called direct
|
||||
- can be called from search_resource
|
||||
"""
|
||||
|
||||
message_body = message.body
|
||||
if not message_body:
|
||||
return None
|
||||
|
||||
if not pquery or not name:
|
||||
pquery, name = self._parse_keywords(message_body)
|
||||
|
||||
T = current.T
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
|
||||
reply = None
|
||||
result = []
|
||||
|
||||
# Person Search [get name person phone email]
|
||||
s3_accessible_query = current.auth.s3_accessible_query
|
||||
table = s3db.pr_person
|
||||
query = (table.deleted == False) & \
|
||||
(s3_accessible_query("read", table))
|
||||
rows = db(query).select(table.pe_id,
|
||||
table.first_name,
|
||||
table.middle_name,
|
||||
table.last_name)
|
||||
_name = soundex(str(name))
|
||||
for row in rows:
|
||||
if (_name == soundex(row.first_name)) or \
|
||||
(_name == soundex(row.middle_name)) or \
|
||||
(_name == soundex(row.last_name)):
|
||||
presult = dict(name = row.first_name, id = row.pe_id)
|
||||
result.append(presult)
|
||||
|
||||
if len(result) == 0:
|
||||
return T("No Match")
|
||||
|
||||
elif len(result) > 1:
|
||||
return T("Multiple Matches")
|
||||
|
||||
else:
|
||||
# Single Match
|
||||
reply = result[0]["name"]
|
||||
table = s3db.pr_contact
|
||||
if "email" in pquery:
|
||||
query = (table.pe_id == result[0]["id"]) & \
|
||||
(table.contact_method == "EMAIL") & \
|
||||
(s3_accessible_query("read", table))
|
||||
recipient = db(query).select(table.value,
|
||||
orderby = table.priority,
|
||||
limitby=(0, 1)).first()
|
||||
if recipient:
|
||||
reply = "%s Email->%s" % (reply, recipient.value)
|
||||
else:
|
||||
reply = "%s 's Email Not available!" % reply
|
||||
if "phone" in pquery:
|
||||
query = (table.pe_id == result[0]["id"]) & \
|
||||
(table.contact_method == "SMS") & \
|
||||
(s3_accessible_query("read", table))
|
||||
recipient = db(query).select(table.value,
|
||||
orderby = table.priority,
|
||||
limitby=(0, 1)).first()
|
||||
if recipient:
|
||||
reply = "%s Mobile->%s" % (reply,
|
||||
recipient.value)
|
||||
else:
|
||||
reply = "%s 's Mobile Contact Not available!" % reply
|
||||
|
||||
return reply
|
||||
|
||||
# ---------------------------------------------------------------------
|
||||
def search_hospital(self, message, pquery=None, name=None):
|
||||
"""
|
||||
Search for Hospitals
|
||||
- can be called direct
|
||||
- can be called from search_resource
|
||||
"""
|
||||
|
||||
message_body = message.body
|
||||
if not message_body:
|
||||
return None
|
||||
|
||||
if not pquery or not name:
|
||||
pquery, name = self._parse_keywords(message_body)
|
||||
|
||||
T = current.T
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
|
||||
reply = None
|
||||
result = []
|
||||
|
||||
# Hospital Search [example: get name hospital facility status ]
|
||||
table = s3db.hms_hospital
|
||||
stable = s3db.hms_status
|
||||
query = (table.deleted == False) & \
|
||||
(current.auth.s3_accessible_query("read", table))
|
||||
rows = db(query).select(table.id,
|
||||
table.name,
|
||||
table.aka1,
|
||||
table.aka2,
|
||||
table.phone_emergency
|
||||
)
|
||||
_name = soundex(str(name))
|
||||
for row in rows:
|
||||
if (_name == soundex(row.name)) or \
|
||||
(_name == soundex(row.aka1)) or \
|
||||
(_name == soundex(row.aka2)):
|
||||
result.append(row)
|
||||
|
||||
if len(result) == 0:
|
||||
return T("No Match")
|
||||
|
||||
elif len(result) > 1:
|
||||
return T("Multiple Matches")
|
||||
|
||||
else:
|
||||
# Single Match
|
||||
hospital = result[0]
|
||||
status = db(stable.hospital_id == hospital.id).select(stable.facility_status,
|
||||
stable.clinical_status,
|
||||
stable.security_status,
|
||||
limitby=(0, 1)
|
||||
).first()
|
||||
reply = "%s %s (%s) " % (reply, hospital.name,
|
||||
T("Hospital"))
|
||||
if "phone" in pquery:
|
||||
reply = reply + "Phone->" + str(hospital.phone_emergency)
|
||||
if "facility" in pquery:
|
||||
reply = reply + "Facility status " + \
|
||||
str(stable.facility_status.represent\
|
||||
(status.facility_status))
|
||||
if "clinical" in pquery:
|
||||
reply = reply + "Clinical status " + \
|
||||
str(stable.clinical_status.represent\
|
||||
(status.clinical_status))
|
||||
if "security" in pquery:
|
||||
reply = reply + "Security status " + \
|
||||
str(stable.security_status.represent\
|
||||
(status.security_status))
|
||||
|
||||
return reply
|
||||
|
||||
# ---------------------------------------------------------------------
|
||||
def search_organisation(self, message, pquery=None, name=None):
|
||||
"""
|
||||
Search for Organisations
|
||||
- can be called direct
|
||||
- can be called from search_resource
|
||||
"""
|
||||
|
||||
message_body = message.body
|
||||
if not message_body:
|
||||
return None
|
||||
|
||||
if not pquery or not name:
|
||||
pquery, name = self._parse_keywords(message_body)
|
||||
|
||||
T = current.T
|
||||
db = current.db
|
||||
s3db = current.s3db
|
||||
|
||||
reply = None
|
||||
result = []
|
||||
|
||||
# Organization search [example: get name organisation phone]
|
||||
s3_accessible_query = current.auth.s3_accessible_query
|
||||
table = s3db.org_organisation
|
||||
query = (table.deleted == False) & \
|
||||
(s3_accessible_query("read", table))
|
||||
rows = db(query).select(table.id,
|
||||
table.name,
|
||||
table.phone,
|
||||
table.acronym)
|
||||
_name = soundex(str(name))
|
||||
for row in rows:
|
||||
if (_name == soundex(row.name)) or \
|
||||
(_name == soundex(row.acronym)):
|
||||
result.append(row)
|
||||
|
||||
if len(reply) == 0:
|
||||
return T("No Match")
|
||||
|
||||
elif len(result) > 1:
|
||||
return T("Multiple Matches")
|
||||
|
||||
else:
|
||||
# Single Match
|
||||
org = result[0]
|
||||
reply = "%s %s (%s) " % (reply, org.name,
|
||||
T("Organization"))
|
||||
if "phone" in pquery:
|
||||
reply = reply + "Phone->" + str(org.phone)
|
||||
if "office" in pquery:
|
||||
otable = s3db.org_office
|
||||
query = (otable.organisation_id == org.id) & \
|
||||
(s3_accessible_query("read", otable))
|
||||
office = db(query).select(otable.address,
|
||||
limitby=(0, 1)).first()
|
||||
reply = reply + "Address->" + office.address
|
||||
|
||||
return reply
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
def parse_ireport(self, message):
|
||||
"""
|
||||
Parse Messages directed to the IRS Module
|
||||
- logging new incidents
|
||||
- responses to deployment requests
|
||||
"""
|
||||
|
||||
message_body = message.body
|
||||
if not message_body:
|
||||
return None
|
||||
|
||||
(lat, lon, code, text) = current.msg.parse_opengeosms(message_body)
|
||||
|
||||
if code == "SI":
|
||||
# Create New Incident Report
|
||||
reply = self._create_ireport(lat, lon, text)
|
||||
else:
|
||||
# Is this a Response to a Deployment Request?
|
||||
words = message_body.split(" ")
|
||||
text = ""
|
||||
reponse = ""
|
||||
report_id = None
|
||||
comments = False
|
||||
for word in words:
|
||||
if "SI#" in word and not ireport:
|
||||
report = word.split("#")[1]
|
||||
report_id = int(report)
|
||||
elif (soundex(word) == soundex("Yes")) and report_id \
|
||||
and not comments:
|
||||
response = True
|
||||
comments = True
|
||||
elif soundex(word) == soundex("No") and report_id \
|
||||
and not comments:
|
||||
response = False
|
||||
comments = True
|
||||
elif comments:
|
||||
text += word + " "
|
||||
|
||||
if report_id:
|
||||
reply = self._respond_drequest(message, report_id, response, text)
|
||||
else:
|
||||
reply = None
|
||||
|
||||
return reply
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def _create_ireport(lat, lon, text):
|
||||
"""
|
||||
Create New Incident Report
|
||||
"""
|
||||
|
||||
s3db = current.s3db
|
||||
rtable = s3db.irs_ireport
|
||||
gtable = s3db.gis_location
|
||||
info = text.split(" ")
|
||||
name = info[len(info) - 1]
|
||||
category = ""
|
||||
for a in range(0, len(info) - 1):
|
||||
category = category + info[a] + " "
|
||||
|
||||
#@ToDo: Check for an existing location in DB
|
||||
#records = db(gtable.id>0).select(gtable.id, \
|
||||
# gtable.lat,
|
||||
# gtable.lon)
|
||||
#for record in records:
|
||||
# try:
|
||||
# if "%.6f"%record.lat == str(lat) and \
|
||||
# "%.6f"%record.lon == str(lon):
|
||||
# location_id = record.id
|
||||
# break
|
||||
# except:
|
||||
# pass
|
||||
|
||||
location_id = gtable.insert(name="Incident:%s" % name,
|
||||
lat=lat,
|
||||
lon=lon)
|
||||
rtable.insert(name=name,
|
||||
message=text,
|
||||
category=category,
|
||||
location_id=location_id)
|
||||
|
||||
# @ToDo: Include URL?
|
||||
reply = "Incident Report Logged!"
|
||||
return reply
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def _parse_keywords(message_body):
|
||||
"""
|
||||
Parse Keywords
|
||||
- helper function for search_resource, etc
|
||||
"""
|
||||
|
||||
# Equivalent keywords in one list
|
||||
primary_keywords = ["get", "give", "show"]
|
||||
contact_keywords = ["email", "mobile", "facility", "clinical",
|
||||
"security", "phone", "status", "hospital",
|
||||
"person", "organisation"]
|
||||
|
||||
pkeywords = primary_keywords + contact_keywords
|
||||
keywords = message_body.split(" ")
|
||||
pquery = []
|
||||
name = ""
|
||||
for word in keywords:
|
||||
match = None
|
||||
for key in pkeywords:
|
||||
if soundex(key) == soundex(word):
|
||||
match = key
|
||||
break
|
||||
if match:
|
||||
pquery.append(match)
|
||||
else:
|
||||
name = word
|
||||
|
||||
return pquery, name
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def _parse_value(text, fieldname):
|
||||
"""
|
||||
Parse a value from a piece of text
|
||||
"""
|
||||
|
||||
parts = text.split(":%s:" % fieldname, 1)
|
||||
parts = parts[1].split(":", 1)
|
||||
result = parts[0]
|
||||
return result
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
@staticmethod
|
||||
def _respond_drequest(message, report_id, response, text):
|
||||
"""
|
||||
Parse Replies To Deployment Request
|
||||
"""
|
||||
|
||||
# Can we identify the Human Resource?
|
||||
hr_id = S3Parsing().lookup_human_resource(message.from_address)
|
||||
if hr_id:
|
||||
rtable = current.s3db.irs_ireport_human_resource
|
||||
query = (rtable.ireport_id == report_id) & \
|
||||
(rtable.human_resource_id == hr_id)
|
||||
current.db(query).update(reply = text,
|
||||
response = response)
|
||||
reply = "Response Logged in the Report (Id: %d )" % report_id
|
||||
else:
|
||||
reply = None
|
||||
|
||||
return reply
|
||||
|
||||
# END =========================================================================
|
@ -0,0 +1,31 @@
|
||||
"Name"
|
||||
"Advocacy"
|
||||
"Awareness raising"
|
||||
"BDRT (Branch disaster response teams)"
|
||||
"Capacity Building"
|
||||
"CDRT (Community disaster response teams)"
|
||||
"Children's Education"
|
||||
"Climate change mitigation"
|
||||
"Climate change preparednes"
|
||||
"Community Based Health and First Aid (CBHFA)"
|
||||
"Community organisation"
|
||||
"Contingency planning"
|
||||
"DM Planning"
|
||||
"Early warning"
|
||||
"Evacuation drills"
|
||||
"Food security "
|
||||
"Hygiene promotion"
|
||||
"IDRL"
|
||||
"IEC Materials"
|
||||
"Livelihoods"
|
||||
"Logistics"
|
||||
"Mainstreaming DRR"
|
||||
"NDRT (National disaster response teams)"
|
||||
"Nutrition"
|
||||
"Risk transfer"
|
||||
"Sanitation"
|
||||
"School Safety"
|
||||
"Small scale mitigation"
|
||||
"Tools & Equipment"
|
||||
"VCA (Vulnerability and Capacity Assessment)"
|
||||
"Water Supply"
|
|
@ -0,0 +1,11 @@
|
||||
"Name"
|
||||
"Individuals"
|
||||
"Families/HH"
|
||||
"Men"
|
||||
"Women"
|
||||
"Boys"
|
||||
"Girls"
|
||||
"Teachers"
|
||||
"Pupils"
|
||||
"Government Staff"
|
||||
"Stakeholder Staff"
|
|
@ -0,0 +1,17 @@
|
||||
"Name","Comments"
|
||||
"Avalanche","snow avalanche, snow slide"
|
||||
"Cold Wave","extreme weather, extreme temperature, cold temperatures"
|
||||
"Cyclone","hurricane, tropical storm, tropical depression, typhoon"
|
||||
"Drought","deficiency of precipitation, desertification, pronounced absence of rainfall"
|
||||
"Earthquake","seismic, tectonic"
|
||||
"Epidemic","bubonic plague, cholera, dengue, non-pandemic diseases, typhoid"
|
||||
"Flood","inundation; includes: flash floods"
|
||||
"Heat Wave","extreme weather, extreme temperature, high temperatures"
|
||||
"Insect Infestation","locust, plague, African bees"
|
||||
"Land Slide","debris flow, mud flow, mud slide, rock fall, slide, lahar, rock slide and topple"
|
||||
"Storm Surge","coastal flood, wave surge, wind setup"
|
||||
"Technical","Disaster chemical spill/leak, explosions, collapses, gas leaks, urban fire, oil spill, technical failure"
|
||||
"Tornado","waterspout, twister, vortex"
|
||||
"Tsunami","Tsunami"
|
||||
"Volcano","crater, lava, magma, molten materials, pyroclastic flows, volcanic rock, volcanic ash"
|
||||
"Fire","urban fire, bush fire, forest fire, uncontrolled fire, wildland fire"
|
|
@ -0,0 +1,4 @@
|
||||
Name,Comments
|
||||
Proposed,
|
||||
Current,
|
||||
Completed,
|
|
@ -0,0 +1,30 @@
|
||||
Name,Comments
|
||||
Capacity Development,"training and development, institutional strengthening, institutional learning"
|
||||
Civil Society/NGOs,"civic action, collective community action, community-based organization (CBO) action, grassroots action, integrative DRR, non-governmental organization (NGO) action"
|
||||
Climate Change,"adaptation to climate change, sustainable development"
|
||||
Community-based DRR,"local knowledge, local risk mapping"
|
||||
Complex Emergency,"multiple hazard crisis, humanitarian crisis, conflict"
|
||||
Critical Infrastructure,"communications systems, health facilities, 'lifelines', power and energy, emergency evacuation shelters, financial infrastructure, schools, transportation, waste disposal, water supplies"
|
||||
Disaster Risk Management,"civil protection, contingency and emergency planning, early recovery, preparedness"
|
||||
Early Warning,"risk knowledge, monitoring and warning service, risk communication, response capability, disaster preparedness, risk modelling"
|
||||
Economics of DRR,"cost benefit analysis, disaster risk financing, financial effects of disasters, poverty and disaster risk, risk sharing, socio-economic impacts of disasters"
|
||||
Education & School Safety,"learning, safe schools"
|
||||
Environment,"sustainable development, environmental degradation, ecosystems and environmental management"
|
||||
Food Security & Agriculture,"cost benefit analysis, disaster risk financing, financial effects of disasters, poverty and disaster risk, risk sharing, socio-economic impacts of disasterscost benefit analysis, disaster risk financing, financial effects of disasters, poverty and disaster risk, risk sharing, socio-economic impacts of disasters"
|
||||
Gender,"gendered vulnerability, gender-sensitive disaster risk management"
|
||||
GIS & Mapping,"geographic information systems, hazard exposure mapping, vulnerability mapping, risk mapping"
|
||||
Governance,"disaster risk reduction policy and legislation, National Platform for disaster risk reduction, Regional Platforms for disaster risk reduction"
|
||||
Health & Health Facilities,"capacity of health practitioners, mental health"
|
||||
Indigenous Knowledge,"indigenous early warning system, local adaptation for implementation, local knowledge, local skills, local technical knowledge, local knowledge systems, traditional knowledge, transferable indigenous knowledge; related: coastal zones, food security and agricultural practice, housing, mountain ecosystems, river basin management, water management"
|
||||
Information Management,"disaster databases, disaster information, disaster risk information portals, ICT"
|
||||
Media,"disaster reporting, disaster information dissemination"
|
||||
Private-public Partnerships,"corporate social responsibility, private sector engagement in DRR"
|
||||
Recovery,"building back better, long-term recovery and reconstruction, rehabilitation, shelter"
|
||||
Risk Identification & Assessment,"risk assessment, loss data, disaster risk management"
|
||||
Risk Transfer & Insurance,"disaster insurance, contingency funding, micro-insurance, post-disaster loans, risk financing, risk insurance, risk sharing, pooling"
|
||||
Social Impacts & Resilience,"coping capacity, loss absorption, loss acceptance, psychosocial support, social vulnerability, trauma prevention"
|
||||
Space Technology,satellite disaster imagery
|
||||
Structural Safety,"building codes, building standards, building materials, construction, retrofitting"
|
||||
Urban Risk & Planning,"urban planning, urban management"
|
||||
Vulnerable Populations,"at-risk populations, including: children, orphans, disabled, elderly, homeless, hospitalized people, illegal immigrants, illiterate, medically or chemically dependent, impoverished populations, migrants, Person With Disabilities (PWDs), speakers of non-local languages"
|
||||
Water,"drinking water, freshwater, irrigation, potable water, water and sanitation, water resource management"
|
|
@ -0,0 +1,2 @@
|
||||
Name,Comments
|
||||
Received,
|
|
@ -0,0 +1,64 @@
|
||||
# =============================================================================
|
||||
# Add a list of CSV files to import into the system
|
||||
#
|
||||
# The list of import files is a comma separated list as follows:
|
||||
#
|
||||
# prefix,tablename,csv file name,stylesheet
|
||||
#
|
||||
# The CSV file is assumed to be in the same directory as this file
|
||||
# The style sheet is assumed to be in either of the following directories:
|
||||
# static/formats/s3csv/prefix/
|
||||
# static/formats/s3csv/
|
||||
#
|
||||
# For details on how to import data into the system see the following:
|
||||
# zzz_1st_run
|
||||
# s3import::S3BulkImporter
|
||||
# =============================================================================
|
||||
# Roles
|
||||
*,import_role,auth_roles.csv
|
||||
auth,user,masterUsers.csv,user.xsl
|
||||
# GIS
|
||||
# Markers
|
||||
gis,marker,gis_marker.csv,marker.xsl
|
||||
# Config
|
||||
gis,config,gis_config.csv,config.xsl
|
||||
gis,hierarchy,gis_hierarchy.csv,hierarchy.xsl
|
||||
# Layers
|
||||
gis,layer_feature,gis_layer_feature.csv,layer_feature.xsl
|
||||
gis,layer_config,gis_layer_openstreetmap.csv,layer_openstreetmap.xsl
|
||||
gis,layer_config,gis_layer_openweathermap.csv,layer_openweathermap.xsl
|
||||
gis,layer_config,gis_layer_bing.csv,layer_bing.xsl
|
||||
gis,layer_config,gis_layer_google.csv,layer_google.xsl
|
||||
gis,layer_config,gis_layer_wms.csv,layer_wms.xsl
|
||||
gis,layer_config,gis_layer_tms.csv,layer_tms.xsl
|
||||
gis,layer_geojson,gis_layer_geojson.csv,layer_geojson.xsl
|
||||
gis,layer_georss,gis_layer_georss.csv,layer_georss.xsl
|
||||
gis,layer_config,gis_layer_coordinate.csv,layer_coordinate.xsl
|
||||
# -----------------------------------------------------------------------------
|
||||
cms,post,cms_post.csv,post.xsl
|
||||
# -----------------------------------------------------------------------------
|
||||
org,sector,org_sector.csv,sector.xsl
|
||||
org,organisation_type,organisation_type.csv,organisation_type.xsl
|
||||
org,office_type,office_type.csv,office_type.xsl
|
||||
supply,catalog_item,DefaultItems.csv,catalog_item.xsl
|
||||
supply,catalog_item,StandardItems.csv,catalog_item.xsl
|
||||
supply,person_item_status,supply_person_item_status.csv,person_item_status.xsl
|
||||
hrm,skill,DefaultSkillList.csv,skill.xsl
|
||||
hrm,skill,DrivingSkillList.csv,skill.xsl
|
||||
hrm,skill,DrivingSkillList_EU.csv,skill.xsl
|
||||
hrm,skill,LanguageSkillList.csv,skill.xsl
|
||||
hrm,competency_rating,DefaultSkillCompetency.csv,competency_rating.xsl
|
||||
hrm,competency_rating,LanguageCompetency.csv,competency_rating.xsl
|
||||
hrm,certificate,certificate.csv,certificate.xsl
|
||||
project,status,project_status.csv,status.xsl
|
||||
project,activity_type,project_activity_type.csv,activity_type.xsl
|
||||
project,hazard,project_hazard.csv,hazard.xsl
|
||||
project,theme,project_theme.csv,theme.xsl
|
||||
project,beneficiary_type,project_beneficiary_type.csv,beneficiary_type.xsl
|
||||
# Spotter
|
||||
cr,shelter_type,cr_shelter_type.csv,shelter_type.xsl
|
||||
event,event_type,event_type.csv,event_type.xsl
|
||||
event,incident_type,incident_type.csv,incident_type.xsl
|
||||
member,membership_type,membership_type.csv,membership_type.xsl
|
||||
work,job_type,work_job_type.csv,job_type.xsl
|
||||
# =============================================================================
|
@ -0,0 +1,49 @@
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
"""
|
||||
This file specifies the tests which are to be run on the default template.
|
||||
|
||||
modules/tests/suite.py runs this file to get the test_list which is to be loaded.
|
||||
To add more tests which are to run on this template, simply add the class name
|
||||
to the list below.
|
||||
"""
|
||||
|
||||
from gluon import current
|
||||
|
||||
current.selenium_tests = ["CreateOrganisation",
|
||||
"CreateOffice",
|
||||
"CreateStaff",
|
||||
"CreateStaffJobTitle",
|
||||
"CreateStaffCertificate",
|
||||
"SearchStaff",
|
||||
"StaffReport",
|
||||
"CreateVolunteer",
|
||||
"CreateVolunteerJobTitle",
|
||||
"CreateVolunteerProgramme",
|
||||
"CreateVolunteerSkill",
|
||||
"CreateVolunteerCertificate",
|
||||
"VolunteerSearch",
|
||||
"CreateStaffTraining",
|
||||
"CreateVolunteerTraining",
|
||||
"SendItem",
|
||||
"ReceiveItem",
|
||||
"SendReceiveItem",
|
||||
"CreateProject",
|
||||
"CreateAsset",
|
||||
"AssetSearch",
|
||||
"AssetReport",
|
||||
"AddStaffParticipants",
|
||||
"AddStaffToOrganisation",
|
||||
"AddStaffToOffice",
|
||||
"AddStaffToWarehouse",
|
||||
"CreateWarehouse",
|
||||
"SearchWarehouse",
|
||||
"CreateItem",
|
||||
"CreateCatalog",
|
||||
"CreateCategory",
|
||||
"ReportTestHelper",
|
||||
"CreateFacility",
|
||||
"CreateEvent",
|
||||
"CreateIncidentReport",
|
||||
"ImportStaff"
|
||||
]
|
@ -0,0 +1,5 @@
|
||||
{{if settings.ui.get("social_buttons"):}}<div id="socialmedia_share"></div>{{pass}}
|
||||
<p id="poweredby">
|
||||
{{poweredby=T("Powered by Sahana")}}
|
||||
<img src='/{{=appname}}/static/img/S3menu_logo.png' width='30' height='28' style='vertical-align:middle' alt='{{=poweredby}}' /><a target='_blank' href='http://eden.sahanafoundation.org' title='{{=poweredby}}'>{{=poweredby}}</a>
|
||||
</p>
|
@ -0,0 +1,100 @@
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml" lang="{{=T.accepted_language or "en"}}">{{# class="no-js" needed for modernizr }}
|
||||
<head>{{theme_styles=response.s3.theme_styles}}
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
{{# Always force latest IE rendering engine (even in intranet) & Chrome Frame }}
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
|
||||
<title>{{try:}}{{=title}}{{except:}}{{=response.title or settings.get_system_name_short()}}{{pass}}</title>
|
||||
{{if response.refresh:}}{{=XML(response.refresh)}}{{pass}}
|
||||
{{# http://dev.w3.org/html5/markup/meta.name.html }}
|
||||
<meta name="application-name" content="{{=appname}}" />
|
||||
{{# Set your site up with Google: http://google.com/webmasters }}
|
||||
{{# <meta name="google-site-verification" content="" /> }}
|
||||
{{a="""<!-- Mobile Viewport Fix
|
||||
j.mp/mobileviewport & davidbcalhoun.com/2010/viewport-metatag
|
||||
device-width: Occupy full width of the screen in its current orientation
|
||||
initial-scale = 1.0 retains dimensions instead of zooming out if page height > device height
|
||||
maximum-scale = 1.0 retains dimensions instead of zooming in if page width < device width
|
||||
--> """}}
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1" />
|
||||
{{# Place favicon.ico and apple-touch-icon.png in the root of your domain and delete these references }}
|
||||
<link rel="shortcut icon" href="/{{=appname}}/static/favicon.ico" type="image/x-icon" />
|
||||
{{# <link rel="apple-touch-icon" href="/=appname/static/favicon.png" /> }}
|
||||
{{# All JavaScript at the bottom, except for Modernizr which enables HTML5 elements & feature detects }}{{# This kills the map in IE8: VML.js }}
|
||||
{{#<script src="/=appname/static/scripts/modernizr.min.js"></script>}}
|
||||
{{for sheet in s3.external_stylesheets:}}
|
||||
<link href="{{=sheet}}" rel="stylesheet" type="text/css" media="screen" charset="utf-8" />
|
||||
{{pass}}
|
||||
{{include "foundation.css.html"}}
|
||||
{{for sheet in s3.stylesheets:}}
|
||||
<link href="/{{=appname}}/static/styles/{{=sheet}}" rel="stylesheet" type="text/css" media="screen" charset="utf-8" />
|
||||
{{pass}}
|
||||
{{if s3.debug:}}{{=s3base.s3_include_debug_css()}}{{else:}}
|
||||
{{# Built by /static/scripts/tools/build.sahana.py }}
|
||||
<link href="/{{=appname}}/static/themes/{{=theme_styles}}/eden.min.css" rel="stylesheet" type="text/css" />
|
||||
{{pass}}
|
||||
{{include "scripts_top.html"}}
|
||||
</head>
|
||||
{{try:}}
|
||||
{{if r.representation == "popup":}}{{representation = "popup"}}
|
||||
{{elif r.representation == "iframe":}}{{representation = "iframe"}}
|
||||
{{else:}}{{representation = ""}}{{pass}}
|
||||
{{except:}}{{representation = ""}}{{pass}}
|
||||
{{if representation == "popup":}}
|
||||
<body class='popup'>
|
||||
{{if response.flash or response.confirmation:}}{{include "layout_popup.html"}}
|
||||
{{else:}}{{include}}{{pass}}
|
||||
{{if s3.debug:}}{{s3.scripts.append(URL(c="static", f="scripts", args=["S3", "s3.popup.js"]))}}
|
||||
{{else:}}{{s3.scripts.append(URL(c="static", f="scripts", args=["S3", "s3.popup.min.js"]))}}{{pass}}
|
||||
{{elif representation == "iframe":}}
|
||||
{{include "layout_iframe.html"}}
|
||||
{{include}}
|
||||
{{else:}}
|
||||
<body>
|
||||
<header>
|
||||
<div class="fixed">
|
||||
{{=current.menu.main}}
|
||||
</div>
|
||||
</header>
|
||||
<main role="main" class="main">
|
||||
<div class='row'>
|
||||
{{if current.menu.options is not None:}}
|
||||
<a id='menu-options-toggle' class='tiny secondary button show-for-small' data-status='off' data-off='{{=T("Show Options")}}' data-on='{{=T("Hide Options")}}'>{{=T("Show Options")}}</a>
|
||||
<div class='medium-3 large-2 columns hide-for-small' id='menu-options'>
|
||||
{{=current.menu.options}}
|
||||
</div>
|
||||
<div class='medium-9 large-10 columns' id='content'>
|
||||
{{else:}}
|
||||
<div class='medium-12 columns' id='content'>
|
||||
{{pass}}
|
||||
<div class='row'>
|
||||
<div class='medium-8 medium-centered columns' id='alert-space'>
|
||||
{{if response.error:}}<div class='alert alert-error'>{{=response.error}}</div>{{pass}}
|
||||
{{if response.warning:}}<div class='alert alert-warning'>{{=response.warning}}</div>{{pass}}
|
||||
{{if response.information:}}<div class='alert alert-info'>{{=response.information}}</div>{{pass}}
|
||||
{{if response.confirmation:}}<div class='alert alert-success'>{{=response.confirmation}}</div>{{pass}}
|
||||
{{if response.flash:}}<div class='alert alert-success'>{{=response.flash}}</div>{{pass}}
|
||||
</div>
|
||||
</div>
|
||||
{{#include "breadcrumbs.html"}}
|
||||
{{include}}
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
<footer role="complementary" class="footer">
|
||||
<div class='row' id='footer'>
|
||||
<div class='medium-12 columns'>
|
||||
{{include "../modules/templates/%s/views/footer.html" % response.s3.theme_layouts}}
|
||||
{{if s3.debug:}}
|
||||
<div class="row">
|
||||
<div class='medium-12 columns'>{{=s3.toolbar()}}</div>
|
||||
</div>
|
||||
{{pass}}
|
||||
</div>
|
||||
</div>
|
||||
</footer>
|
||||
{{pass}}
|
||||
{{include "scripts.html"}}
|
||||
{{include "foundation.js.html"}}
|
||||
</body>
|
||||
</html>
|
@ -0,0 +1,28 @@
|
||||
Name,Comments
|
||||
Administration,
|
||||
Child Care,
|
||||
Cleanup,
|
||||
Cleaning,
|
||||
Collection,
|
||||
Communication,
|
||||
Construction,
|
||||
Cooking,
|
||||
Coordination,
|
||||
Demolition,
|
||||
Distribution,
|
||||
Elderly Care,
|
||||
IT/Telecom,
|
||||
Maintenance,
|
||||
Medical Care,
|
||||
Nursing,
|
||||
Outreach,
|
||||
Plumbing,
|
||||
Repair,
|
||||
Shipping,
|
||||
Search and Rescue,
|
||||
Survey,
|
||||
Training,
|
||||
Transport,
|
||||
Triage,
|
||||
Warehousing,
|
||||
Other,
|
|
Loading…
Reference in New Issue
Block a user