[galaxy-dev] Populating tool select menu with database data? tag deprecated
Hi, I have a question related to this Galaxy threads: http://dev.list.galaxyproject.org/Populating-tool-select-menu-with-database -data-tp4139069.html I implemented the example with the deprecated tag which is working fine. But I do not invest time in a tag which might vanish soon. What is the replacement for this tag or how is the way it should be done? Here is what I want to do: My ultimate goal is to load fastq.gz files from an external Data Management System which I can connect via a JSON API. Here is the code which generates the menu shwon in the attached screen shot: Python code: import jsonrpclib server = jsonrpclib.Server('https:///rmi-general-information-v1.json') sessionToken = server.tryToAuthenticateForAllServices(, ) projects = server.listProjects(sessionToken) experimentType = 'HT_SEQUENCING' def getExperiments(): eList = [] experiments = server.listExperiments(sessionToken, projects, experimentType) for experiment in experiments: eList.append([experiment['code'], experiment['code'], False]) return eList The corresponding XML file calls the getExperiments() function: Depending on the selection in the first drop down list (experiments) I want to show/fill a second list which shows a list of items which are in the selected experiment. Finally the fastq files should be listed. The structure is like this: *Experiment1 - Sample1 + fastq1.gz + fastq2.gz + fastq3.gz - Sample2 + fastq1.gz + fastq2.gz *Experiment2 - Sample1 + fastq1.gz I am on Galaxy r7148. If somebody could direct me in the right direction would be highly appreciated. Kind regards Manuel -- Manuel Kohler Center for Information Sciences and Databases (C-ISD) Department of Biosystems Science & Engineering (D-BSSE) ETH Zurich, Maulbeerstrasse (1078, 1.02), CH-4058 Basel, +41 61 387 3132 <>___ Please keep all replies on the list by using "reply all" in your mail client. To manage your subscriptions to this and other Galaxy lists, please use the interface at: http://lists.bx.psu.edu/
Re: [galaxy-dev] Populating tool select menu with database data?
On 02/08/2011 12:50 PM, Kempenaar, M (med) wrote: Hello Hans-Rudolf, Do you know if the 'dynamic_options' attribute also works for control elements other then select menu's? For example I want to present the user a set of checkboxes that correspond to column names from a file, could I use something like a loop that either iterates on data received from the 'dynamics_option' function or from a meta attribute? I don't quite follow your question.you can also use it in combinations with "": In one of our cases, we dynamically read the contents of a directory, the the user can select a sub-directory, and the on the second page, the content of the selected sub-directory is presented (again, read on the fly). Similarly, you can read the header of a file and present it. Regards, Hans To get a bit further off topic, I made a new tabular datatype that has a meta-attribute for storing column names, but I can't use them in my XML files.. Any ideas would be welcome! Regards, Marcel -Original Message- From: galaxy-dev-boun...@lists.bx.psu.edu on behalf of Hans-Rudolf Hotz Sent: Tue 2/8/2011 10:04 AM To: galaxy-dev@lists.bx.psu.edu Subject: Re: [galaxy-dev] Populating tool select menu with database data? Leandro we use the "dynamic_options" attribute, eg: and then we have a little python script ("extra_code_for_foo_list.py") with the "ds_fooOptions" function, eg def ds_fooOptions(): """List available foos as tuples of (displayName,value)""" foos = Hi Dannon, Sorry that I didn't explain well I have a local database with certain information and I would like to dynamically populate a Galaxy tool select menu with the results of a SQL statement. Is this possible? best, Leandro On Mon, Feb 7, 2011 at 6:05 PM, Dannon Baker wrote: Leandro, Could you elaborate on what you're trying to do, perhaps what database data you're referring to? -Dannon On Feb 7, 2011, at 11:58 AM, Leandro Hermida wrote: Sorry to bug again, Does anyone know where I can find an example on how to dynamically populate a tool select menu with database data? regards, Leandro On Thu, Feb 3, 2011 at 3:32 PM, Leandro Hermida wrote: Hi, Sorry I tried to search for this and couldn't find an example to this basic question where can I find an example on how to populate a tool select menu with database data? best, Leandro ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev De inhoud van dit bericht is vertrouwelijk en alleen bestemd voor de geadresseerde(n). Anderen dan de geadresseerde(n) mogen geen gebruik maken van dit bericht, het niet openbaar maken of op enige wijze verspreiden of vermenigvuldigen. Het UMCG kan niet aansprakelijk gesteld worden voor een incomplete aankomst of vertraging van dit verzonden bericht. The contents of this message are confidential and only intended for the eyes of the addressee(s). Others than the addressee(s) are not allowed to use this message, to make it public or to distribute or multiply this message in any way. The UMCG cannot be held responsible for incomplete reception or delay of this transferred message. ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev
Re: [galaxy-dev] Populating tool select menu with database data?
Hello Hans-Rudolf, Do you know if the 'dynamic_options' attribute also works for control elements other then select menu's? For example I want to present the user a set of checkboxes that correspond to column names from a file, could I use something like a loop that either iterates on data received from the 'dynamics_option' function or from a meta attribute? To get a bit further off topic, I made a new tabular datatype that has a meta-attribute for storing column names, but I can't use them in my XML files.. Any ideas would be welcome! Regards, Marcel -Original Message- From: galaxy-dev-boun...@lists.bx.psu.edu on behalf of Hans-Rudolf Hotz Sent: Tue 2/8/2011 10:04 AM To: galaxy-dev@lists.bx.psu.edu Subject: Re: [galaxy-dev] Populating tool select menu with database data? Leandro we use the "dynamic_options" attribute, eg: and then we have a little python script ("extra_code_for_foo_list.py") with the "ds_fooOptions" function, eg def ds_fooOptions(): """List available foos as tuples of (displayName,value)""" foos = Hi Dannon, > > Sorry that I didn't explain well I have a local database with > certain information and I would like to dynamically populate a Galaxy > tool select menu with the results of a SQL statement. Is this > possible? > > best, > Leandro > > > On Mon, Feb 7, 2011 at 6:05 PM, Dannon Baker wrote: >> Leandro, >> >> Could you elaborate on what you're trying to do, perhaps what database data >> you're referring to? >> >> -Dannon >> >> >> On Feb 7, 2011, at 11:58 AM, Leandro Hermida wrote: >> >>> Sorry to bug again, >>> >>> Does anyone know where I can find an example on how to dynamically >>> populate a tool select menu with database data? >>> >>> regards, >>> Leandro >>> >>> On Thu, Feb 3, 2011 at 3:32 PM, Leandro Hermida >>> wrote: >>>> Hi, >>>> >>>> Sorry I tried to search for this and couldn't find an example to this basic >>>> question where can I find an example on how to populate a tool select >>>> menu with database data? >>>> >>>> best, >>>> Leandro >>>> >>> ___ >>> galaxy-dev mailing list >>> galaxy-dev@lists.bx.psu.edu >>> http://lists.bx.psu.edu/listinfo/galaxy-dev >> >> > ___ > galaxy-dev mailing list > galaxy-dev@lists.bx.psu.edu > http://lists.bx.psu.edu/listinfo/galaxy-dev ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev De inhoud van dit bericht is vertrouwelijk en alleen bestemd voor de geadresseerde(n). Anderen dan de geadresseerde(n) mogen geen gebruik maken van dit bericht, het niet openbaar maken of op enige wijze verspreiden of vermenigvuldigen. Het UMCG kan niet aansprakelijk gesteld worden voor een incomplete aankomst of vertraging van dit verzonden bericht. The contents of this message are confidential and only intended for the eyes of the addressee(s). Others than the addressee(s) are not allowed to use this message, to make it public or to distribute or multiply this message in any way. The UMCG cannot be held responsible for incomplete reception or delay of this transferred message. ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev
Re: [galaxy-dev] Populating tool select menu with database data?
Leandro we use the "dynamic_options" attribute, eg: and then we have a little python script ("extra_code_for_foo_list.py") with the "ds_fooOptions" function, eg def ds_fooOptions(): """List available foos as tuples of (displayName,value)""" foos = Hi Dannon, Sorry that I didn't explain well I have a local database with certain information and I would like to dynamically populate a Galaxy tool select menu with the results of a SQL statement. Is this possible? best, Leandro On Mon, Feb 7, 2011 at 6:05 PM, Dannon Baker wrote: Leandro, Could you elaborate on what you're trying to do, perhaps what database data you're referring to? -Dannon On Feb 7, 2011, at 11:58 AM, Leandro Hermida wrote: Sorry to bug again, Does anyone know where I can find an example on how to dynamically populate a tool select menu with database data? regards, Leandro On Thu, Feb 3, 2011 at 3:32 PM, Leandro Hermida wrote: Hi, Sorry I tried to search for this and couldn't find an example to this basic question where can I find an example on how to populate a tool select menu with database data? best, Leandro ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev
Re: [galaxy-dev] Populating tool select menu with database data?
Hi Dannon, Sorry that I didn't explain well I have a local database with certain information and I would like to dynamically populate a Galaxy tool select menu with the results of a SQL statement. Is this possible? best, Leandro On Mon, Feb 7, 2011 at 6:05 PM, Dannon Baker wrote: > Leandro, > > Could you elaborate on what you're trying to do, perhaps what database data > you're referring to? > > -Dannon > > > On Feb 7, 2011, at 11:58 AM, Leandro Hermida wrote: > >> Sorry to bug again, >> >> Does anyone know where I can find an example on how to dynamically >> populate a tool select menu with database data? >> >> regards, >> Leandro >> >> On Thu, Feb 3, 2011 at 3:32 PM, Leandro Hermida >> wrote: >>> Hi, >>> >>> Sorry I tried to search for this and couldn't find an example to this basic >>> question where can I find an example on how to populate a tool select >>> menu with database data? >>> >>> best, >>> Leandro >>> >> ___ >> galaxy-dev mailing list >> galaxy-dev@lists.bx.psu.edu >> http://lists.bx.psu.edu/listinfo/galaxy-dev > > ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev
Re: [galaxy-dev] Populating tool select menu with database data?
Leandro, Could you elaborate on what you're trying to do, perhaps what database data you're referring to? -Dannon On Feb 7, 2011, at 11:58 AM, Leandro Hermida wrote: > Sorry to bug again, > > Does anyone know where I can find an example on how to dynamically > populate a tool select menu with database data? > > regards, > Leandro > > On Thu, Feb 3, 2011 at 3:32 PM, Leandro Hermida > wrote: >> Hi, >> >> Sorry I tried to search for this and couldn't find an example to this basic >> question where can I find an example on how to populate a tool select >> menu with database data? >> >> best, >> Leandro >> > ___ > galaxy-dev mailing list > galaxy-dev@lists.bx.psu.edu > http://lists.bx.psu.edu/listinfo/galaxy-dev ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev
Re: [galaxy-dev] Populating tool select menu with database data?
Sorry to bug again, Does anyone know where I can find an example on how to dynamically populate a tool select menu with database data? regards, Leandro On Thu, Feb 3, 2011 at 3:32 PM, Leandro Hermida wrote: > Hi, > > Sorry I tried to search for this and couldn't find an example to this basic > question where can I find an example on how to populate a tool select > menu with database data? > > best, > Leandro > ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev
[galaxy-dev] Populating tool select menu with database data?
Hi, Sorry I tried to search for this and couldn't find an example to this basic question where can I find an example on how to populate a tool select menu with database data? best, Leandro ___ galaxy-dev mailing list galaxy-dev@lists.bx.psu.edu http://lists.bx.psu.edu/listinfo/galaxy-dev