2 // Copyright (C) 2009 Aron Racho <aron@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
8 require_once(dirname(__FILE__
) . "/../../../library/classes/ORDataObject.class.php");
10 define("EVENT_VEHICLE",1);
11 define("EVENT_WORK_RELATED",2);
12 define("EVENT_SLIP_FALL",3);
13 define("EVENT_OTHER",4);
17 * class FormHpTjePrimary
20 class FormComplaintHistory
extends ORDataObject
{
38 var $complaint_history;
41 * Constructor sets all Form attributes to their default value
44 function FormComplaintHistory($id= "", $_prefix = "") {
45 if (is_numeric($id)) {
50 $this->date
= date("Y-m-d H:i:s");
53 $this->_table
= "form_complaint_history";
55 $this->pid
= $GLOBALS['pid'];
58 //$this->date = $this->get_date();
63 //$this->temp_methods = parent::_load_enum("temp_locations",false);
66 function toString($html = false) {
68 ."ID: " . $this->id
. "\n";
71 return nl2br($string);
77 function set_id($id) {
78 if (!empty($id) && is_numeric($id)) {
85 function set_pid($pid) {
86 if (!empty($pid) && is_numeric($pid)) {
97 function set_date($dt) {
102 function get_user() {
105 function set_user($u) {
111 function set_activity($tf) {
112 if (!empty($tf) && is_numeric($tf)) {
113 $this->activity
= $tf;
116 function get_activity() {
117 return $this->activity
;
120 function get_complaint_history() {
121 return $this->complaint_history
;
123 function set_complaint_history($data) {
124 $this->complaint_history
= $data;