3 * Copyright Medical Information Integration,LLC info@mi-squared.com
4 * This program is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version 2
7 * of the License, or (at your option) any later version.
9 * @file C_FormPainMap.class.php
11 * @brief This file contains the C_FormPainMap class, used to control a clickmap bassed form.
14 /* Include the class we're extending. */
15 require_once($GLOBALS['fileroot'] . "/interface/clickmap/C_AbstractClickmap.php");
17 /* included so that we can instantiate FormPainMap in createModel, to model the data contained in this form. */
18 require_once("FormPainMap.php");
21 * @class C_FormPainMap
23 * @brief This class extends the C_AbstractClickmap class, to create a form useful for modelling patient pain complaints.
25 class C_FormPainMap
extends C_AbstractClickmap
28 * The title of the form, used when calling addform().
32 static $FORM_TITLE = "Graphical Pain Map";
34 * The 'code' of the form, also used when calling addform().
38 static $FORM_CODE = "painmap";
40 /* initializer, just calls parent's initializer. */
41 public function __construct()
43 parent
::__construct();
47 * @brief Called by C_AbstractClickmap's members to instantiate a Model object on demand.
50 * optional id of a form in the EMR, to populate data from.
52 public function createModel($form_id = "")
55 return new FormPainMap($form_id);
57 return new FormPainMap();
62 * @brief return the path to the backing image relative to the webroot.
66 return $GLOBALS['webroot'] . "/interface/forms/" . C_FormPainMap
::$FORM_CODE ."/templates/painmap.png";
70 * @brief return a n arra containing the options for the dropdown box.
72 function getOptionList()
74 return array( "0" => "None",
84 "10" => "Worst Possible" );
88 * @brief return a label for the dropdown boxes on the form, as a string.
90 function getOptionsLabel()