`date` date NOT NULL, # date the record is for
`user_id` int(11) NOT NULL, # user id the expense item is reported by
`group_id` int(11) default NULL, # group id
+ `org_id` int(11) default NULL, # organization id
`client_id` int(11) default NULL, # client id
`project_id` int(11) default NULL, # project id
`name` text NOT NULL, # expense item name (what is an expense for)
CREATE TABLE `tt_predefined_expenses` (
`id` int(11) NOT NULL auto_increment, # predefined expense id
`group_id` int(11) NOT NULL, # group id
+ `org_id` int(11) default NULL, # organization id
`name` varchar(255) NOT NULL, # predefined expense name, such as mileage
`cost` decimal(10,2) default '0.00', # cost for one unit
PRIMARY KEY (`id`)
#
CREATE TABLE `tt_monthly_quotas` (
`group_id` int(11) NOT NULL, # group id
+ `org_id` int(11) default NULL, # organization id
`year` smallint(5) UNSIGNED NOT NULL, # quota year
`month` tinyint(3) UNSIGNED NOT NULL, # quota month
`minutes` int(11) default NULL, # quota in minutes in specified month and year
PRIMARY KEY (`param_name`)
);
-INSERT INTO `tt_site_config` (`param_name`, `param_value`, `created`) VALUES ('version_db', '1.18.14', now()); # TODO: change when structure changes.
+INSERT INTO `tt_site_config` (`param_name`, `param_value`, `created`) VALUES ('version_db', '1.18.17', now()); # TODO: change when structure changes.