EOB invoice fixes.
[openemr.git] / interface / forms / painmap / C_FormPainMap.class.php
blob7a1b13c44c9cb39a149659dcba6b127f842f856c
1 <?php
2 /**
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");
20 /**
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
27 /**
28 * The title of the form, used when calling addform().
30 * @var FORM_TITLE
32 static $FORM_TITLE = "Graphical Pain Map";
33 /**
34 * The 'code' of the form, also used when calling addform().
36 * @var FORM_CODE
38 static $FORM_CODE = "painmap";
40 /* initializer, just calls parent's initializer. */
41 public function __construct()
43 parent::__construct();
46 /**
47 * @brief Called by C_AbstractClickmap's members to instantiate a Model object on demand.
49 * @param form_id
50 * optional id of a form in the EMR, to populate data from.
52 public function createModel($form_id = "")
54 if ($form_id != "") {
55 return new FormPainMap($form_id);
56 } else {
57 return new FormPainMap();
61 /**
62 * @brief return the path to the backing image relative to the webroot.
64 function getImage()
66 return $GLOBALS['webroot'] . "/interface/forms/" . C_FormPainMap::$FORM_CODE ."/templates/painmap.png";
69 /**
70 * @brief return a n arra containing the options for the dropdown box.
72 function getOptionList()
74 return array( "0" => "None",
75 "1" => "Level 1",
76 "2" => "Level 2",
77 "3" => "Level 3",
78 "4" => "Level 4",
79 "5" => "Moderate",
80 "6" => "Level 6",
81 "7" => "Level 7",
82 "8" => "Level 8",
83 "9" => "Level 9",
84 "10" => "Worst Possible" );
87 /**
88 * @brief return a label for the dropdown boxes on the form, as a string.
90 function getOptionsLabel()
92 return "Pain Scale";