Forum OpenACS Development: Project manager pkg.

Collapse
Posted by Iuri Sampaio on
Hi,

i'm playing with P.M. and i found an error at the mainpage. in the projects portlet.

There's a listtemplate that "list" :) all the project names as a link to the peculiar project's page.

It has a misspelling error at the url. which is set like
set item_url [export_vars -base "${base_url}one" {project_item_id}]

The error is in the variable $base_url. it value is "/project-manager/ /project-manager/"
which is wrong and must be only "/project-manager/"

in the file "/packages/project-manager/lib/projects.tcl"
I have:

set _base_url [site_node::get_url_from_object_id -object_id $package_id]

if {![empty_string_p $_base_url]} {
set base_url $_base_url
}

i put @_base_url@ at the adp and i verified that the api [site_node::get_url_from_object_id ...]
returns the worng value
"/project-manager/ /project-manager/"

so, i need to fix the returning value of the API. But i don;t know if the API is used in another part of the system as it is.
in order to avoid mistakes, i tought i could truncate the variable _base_url and it would work locally, only to that part of the code.

is that correct?

Collapse
2: Re: Project manager pkg. (response to 1)
Posted by Iuri Sampaio on
I meant,
can I ammend the API?
Collapse
3: Re: Project manager pkg. (response to 1)
Posted by Malte Sussdorff on
This seems to be a problem with site_node::get_url_from_object_id. Did you make a fresh checkout from HEAD for acs-tcl as well ?
Collapse
4: Re: Project manager pkg. (response to 3)
Posted by Iuri Sampaio on
Yes, i just downloaded from CVS head, plus also did a fresh install on my box. The bug still remains.
Collapse
5: Re: Project manager pkg. (response to 4)
Posted by Iuri Sampaio on
it's solved. i unnecessarily reinstalled project-manager. Its was missing reload acs-tcl ;)

Thanks Malte

Collapse
6: Re: Project manager pkg. (response to 5)
Posted by Malte Sussdorff on
I fixed the issue by taking only the first URL returned by the get_url_from_object_id procedure, as we only need one (we need to go to the package after all).