Commit a7ff982e authored by Frank Bergmann's avatar Frank Bergmann

- changes on GanttProject import

parent 074bb8c8
......@@ -111,38 +111,15 @@ on im_timesheet_task_dependencies (task_id_two);
-- Allocate a user to a specific task
-- with a certain percentage of his time
--
create table im_timesheet_task_allocations (
task_id integer
constraint im_timesheet_task_alloc_task_nn
not null
constraint im_timesheet_task_alloc_task_fk
references acs_objects,
user_id integer
constraint im_timesheet_task_alloc_user_fk
references users,
role_id integer
constraint im_timesheet_task_alloc_role_fk
references im_categories,
percentage numeric(6,2),
-- -- No check anymore - might want to alloc 120%...
-- constraint im_timesheet_task_alloc_perc_ck
-- check (percentage >= 0 and percentage <= 200),
task_manager_p char(1)
constraint im_timesheet_task_resp_ck
check (task_manager_p in ('t','f')),
note varchar(1000),
primary key (task_id, user_id)
);
create index im_timesheet_tasks_dep_alloc_task_idx
on im_timesheet_task_allocations (task_id);
create index im_timesheet_tasks_dep_alloc_user_idx
on im_timesheet_task_allocations (user_id);
---------------------------------------------------------
-- Assignment information is stored in im_biz_object_members
alter table im_biz_object_members
add percentage numeric(8,2);
......
......@@ -15,28 +15,28 @@
<fullquery name="im_timesheet_task_list_component.task_query">
<querytext>
select
t.*,
p.project_id,
p.project_name,
p.project_nr,
p.note,
cc.cost_center_name,
cc.cost_center_code,
im_category_from_id(t.task_type_id) as task_type,
im_category_from_id(t.task_status_id) as task_status,
im_category_from_id(t.uom_id) as uom,
im_material_nr_from_id(t.material_id) as material_nr,
to_char(t.percent_completed, '999990') as percent_completed_rounded
from
$projects_perm_sql p,
im_timesheet_tasks_view t
left outer join im_cost_centers cc on (t.cost_center_id = cc.cost_center_id)
where
t.project_id = p.project_id
$subproject_sql
$restriction_clause
$order_by_clause
select
t.*,
p.project_id,
p.project_name,
p.project_nr,
p.note,
cc.cost_center_name,
cc.cost_center_code,
im_category_from_id(t.task_type_id) as task_type,
im_category_from_id(t.task_status_id) as task_status,
im_category_from_id(t.uom_id) as uom,
im_material_nr_from_id(t.material_id) as material_nr,
to_char(t.percent_completed, '999990') as percent_completed_rounded
from
$projects_perm_sql p,
im_timesheet_tasks_view t
left outer join im_cost_centers cc on (t.cost_center_id = cc.cost_center_id)
where
t.project_id = p.project_id
$subproject_sql
$restriction_clause
$order_by_clause
</querytext>
</fullquery>
......@@ -45,21 +45,21 @@ $order_by_clause
<fullquery name="im_timesheet_task_list_component.task_subprojects">
<querytext>
select
children.project_id as subproject_id,
children.project_nr as subproject_nr,
children.project_name as subproject_name,
tree_level(children.tree_sortkey) -
tree_level(parent.tree_sortkey) as subproject_level
from
im_projects parent,
im_projects children
where
children.project_status_id not in ([im_project_status_deleted],[im_project_status_canceled])
and children.tree_sortkey between parent.tree_sortkey and tree_right(parent.tree_sortkey)
and parent.project_id = :restrict_to_project_id
order by
children.tree_sortkey
select
children.project_id as subproject_id,
children.project_nr as subproject_nr,
children.project_name as subproject_name,
tree_level(children.tree_sortkey) -
tree_level(parent.tree_sortkey) as subproject_level
from
im_projects parent,
im_projects children
where
children.project_status_id not in ([im_project_status_deleted],[im_project_status_canceled])
and children.tree_sortkey between parent.tree_sortkey and tree_right(parent.tree_sortkey)
and parent.project_id = :restrict_to_project_id
order by
children.tree_sortkey
</querytext>
</fullquery>
......
......@@ -339,7 +339,6 @@ ad_proc -public im_timesheet_task_list_component {
"
}
set ttt {
select
t.*,
......@@ -375,7 +374,6 @@ ad_proc -public im_timesheet_task_list_component {
}
# ---------------------- Get the SQL Query -------------------------
set task_statement [db_qd_get_fullname "task_query" 0]
set task_sql_uneval [db_qd_replace_sql $task_statement {}]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment