Index: openacs-4/contrib/packages/project-manager/www/add-edit.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/contrib/packages/project-manager/www/Attic/add-edit.tcl,v diff -u -r1.9 -r1.10 --- openacs-4/contrib/packages/project-manager/www/add-edit.tcl 23 Aug 2003 00:24:34 -0000 1.9 +++ openacs-4/contrib/packages/project-manager/www/add-edit.tcl 29 Aug 2003 00:35:35 -0000 1.10 @@ -37,7 +37,9 @@ # terminology set project_term [parameter::get -parameter "ProjectName" -default "Project"] -set project_term_lower [parameter::get -parameter "projectname" -default "project"] +set project_term_lower [parameter::get -parameter "projectname" -default "project"] +set use_goal_p [parameter::get -parameter "UseGoalP" -default "1"] +set use_project_code_p [parameter::get -parameter "UseUserProjectCodesP" -default "1"] if {[exists_and_not_null project_id]} { @@ -71,38 +73,21 @@ {value $project_name} } - {project_code:text - {label "[set project_term] code"} - {value $project_code} - } - - {goal:text(textarea) - {label "[set project_term] goal"} - {optional} - {value $goal} - {html { rows 5 cols 40 wrap soft}}} - - {description:text(textarea) + {description:text(textarea),optional {label "Description"} - {optional} {value $description} {html { rows 5 cols 40 wrap soft}}} - {deadline_scheduling:text(select) - {label "Scheduling"} - {options {{"From today" "t"} {"From deadline" "e"}} - {value $deadline_scheduling}} } - {planned_start_date:date,to_sql(linear_date) - {label "Planned start date"} + {label "Starts"} {format "MONTH DD YYYY"} {value {[util::date acquire clock [clock scan $planned_start_date]]}} {today} {help} } {planned_end_date:date,to_sql(linear_date) - {label "Planned end date"} + {label "Deadline"} {format "MONTH DD YYYY"} {value {[util::date acquire clock [clock scan $planned_end_date]]}} {today} @@ -111,7 +96,9 @@ {ongoing_p:text(select) {label "Project is ongoing?"} - {options {{"Yes" "t"} {"No" "f"}} {value \$ongoing_p}} } + {options {{"No" "f"} {"Yes" "t"}} {value $ongoing_p}} + {help_text "If yes, then this project has no deadline"} + } } -select_query_name project_query -on_submit { @@ -134,4 +121,21 @@ ad_script_abort } +if {$use_goal_p} { + ad_form -extend -name add_edit -form { + {goal:text(textarea),optional + {label "[set project_term] goal"} + {value $goal} + {html { rows 5 cols 40 wrap soft}}} + } +} + +if {$use_project_code_p} { + ad_form -extend -name add_edit -form { + {project_code:text,optional + {label "[set project_term] code"} + {value $project_code} + } + } +}