Commit 10d5fde1 authored by Frank Bergmann's avatar Frank Bergmann

- CSV Import for projects:

  - Fixed import of Project Manager field
parent 2464eb18
......@@ -38,6 +38,7 @@ ad_proc -public im_csv_import_guess_im_project { } {} {
{start_date "Start Date" date ""}
{end_date "end Date" date ""}
{percent_completed "Percent Completed" number ""}
{project_lead_id "Project Manager" user_name ""}
{project_budget "Budget" number ""}
{project_budget_hours "Budget Hours" number ""}
}
......
......@@ -327,18 +327,8 @@ foreach csv_line_fields $values_list_of_lists {
if {$ns_write_p} { ns_write "<li><font color=brown>Warning: Didn't find customer_name='$customer_name', using 'internal' customer</font>\n" }
}
# 'forgiving' routine -> project_lead_id might be empty or contain a name or email address.
# Check if empty:
if { "" eq $project_lead_id } {
if {$ns_write_p} { ns_write "<li><font color=brown>Warning: No project manager found. Will try to create project w/o PM. </font>\n" }
} else {
set project_lead $project_lead_id
set project_lead_tuple [im_csv_import_parser_user_name $project_lead]
set project_lead_id [lindex $project_lead_tuple 0]
set project_lead_error [lindex $project_lead_tuple 1]
if {"" ne $project_lead_error} {
if {$ns_write_p} { ns_write "<li><font color=brown>Warning: Error parsing project_lead '$project_lead':<br>$project_lead_error.</font>\n" }
}
}
set customer_contact_id ""
......
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