ReferenceBrowserWidget: Programatically setting a startup_directory

Dave Fregon dave at netaxxs.com.au
Tue Apr 17 23:02:06 UTC 2007



Eric Steele wrote:
> 
> Andreas Jung wrote:
>> --On 10. April 2007 12:40:59 -0400 Eric Steele 
>> <ems174 at psu.edu> wrote:
>> 
>>> Hi,
>>>
>>> I'm using ReferenceBrowserWidget (1.7.1) on my Person object ("John Doe"
>>> below) to allow people to link to Specialty object in a
>>> SpecialtiesFolder. I'd like to be able to set startup_directory to be
>>> the
>>> path to my SpecialtiesFolder (which I won't know the exact name of).
>>>
>>> - "Directory" (FacultyStaffDirectory)
>>>      - "Specialties" (SpecialtiesFolder)
>>>          - "Some Specialty" (Specialty)
>>>      - "John Doe" (Person)
>>>
>>>
>>> Since, I don't know the name and can't hardcode a path, I've tried using
>>> a method name as the value of startup_directory, but that's throwing an
>>> AttributeError. Is there another/any way to do this?
>>>
>> 
>> In this case you must extend the functionality of the 
>> ReferenceBrowserWidget
>> implementation. Your problem is an unsupported usecase. Patches are 
>> welcome.
>> 
>> -aj
>> 
> 
> Thanks. I'd be happy to take a crack at it. I've submitted my request 
> for commit access.
> 
> Is this the place to be talking about this sort of thing, or is the 
> Archetypes list more appropriate?
> 
> Eric
> 
> 

You may also wish to check out PopupReferenceWidget for your use case, as
well as LiveSearchWidget, both of which have path implementations.

Dave
-- 
View this message in context: http://www.nabble.com/ReferenceBrowserWidget%3A-Programatically-setting-a-startup_directory-tf3554114s20094.html#a10049442
Sent from the Product Developers mailing list archive at Nabble.com.





More information about the Product-Developers mailing list