Quantcast

Default value for drop-down lists

classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Default value for drop-down lists

Dave Hamilton

Is there a means by which you can specify the default value for a drop-down list?

 

In my case, when creating a repository entry for a source, 99% of the time I want to specify ‘Scanned Copy’ (one of my added values) for Media Type rather than the current default of ‘Book’.

 

Is there any way of doing this?

 

Regards

 

Dave Hamilton

 

 

 

 


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Simon C. Tremblay
For me it would be setting the default for Places search.  I more often search by title than by name.

The easiest solution I see would be to remember the last item chosen in the drop-down lists.

Simon



On 25 March 2017 at 21:19, Dave Hamilton <[hidden email]> wrote:

Is there a means by which you can specify the default value for a drop-down list?

 

In my case, when creating a repository entry for a source, 99% of the time I want to specify ‘Scanned Copy’ (one of my added values) for Media Type rather than the current default of ‘Book’.

 

Is there any way of doing this?

 

Regards

 

Dave Hamilton


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Helge.Privat
1+ for the last selected value per repository!


Am 26.03.2017 um 15:35 schrieb Simon C. Tremblay:

> For me it would be setting the default for Places search.  I more
> often search by title than by name.
>
> The easiest solution I see would be to remember the last item chosen
> in the drop-down lists.
>
> Simon
>
>
>
> On 25 March 2017 at 21:19, Dave Hamilton <[hidden email]
> <mailto:[hidden email]>> wrote:
>
>     Is there a means by which you can specify the default value for a
>     drop-down list?
>
>      
>
>     In my case, when creating a repository entry for a source, 99% of
>     the time I want to specify ‘Scanned Copy’ (one of my added values)
>     for Media Type rather than the current default of ‘Book’.
>
>      
>
>     Is there any way of doing this?
>
>      
>
>     Regards
>
>      
>
>     Dave Hamilton
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>
>
> _______________________________________________
> Gramps-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gramps-users
> https://gramps-project.org



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Gerhard Killesreiter
In reply to this post by Dave Hamilton
Am 26.03.2017 um 03:19 schrieb Dave Hamilton:
> Is there a means by which you can specify the default value for a drop-down
> list?
>
>

I too wish there was, but I am not aware of such a functionality.

Cheers,
Gerhard



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Nick Hall
In reply to this post by Dave Hamilton
On 26/03/17 02:19, Dave Hamilton wrote:

Is there a means by which you can specify the default value for a drop-down list?

In my case, when creating a repository entry for a source, 99% of the time I want to specify ‘Scanned Copy’ (one of my added values) for Media Type rather than the current default of ‘Book’.

Is there any way of doing this?

No.  However, it would only require adding one line of source code.

Nick.



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Agnes Charrel-Berthillier
In reply to this post by Dave Hamilton
On 3/25/17 6:19 PM, Dave Hamilton wrote:

In my case, when creating a repository entry for a source, 99% of the time I want to specify ‘Scanned Copy’ (one of my added values) for Media Type rather than the current default of ‘Book’.

 

Not aware of any way to set default values for drop down lists, but for this specific issue and sources from the same repository I will create the first one, change the media type, then drag it to the clipboard. It can then be dragged and dropped into the depot tab of the next sources, and the media type (and ref #) will be pre-populated with the values assigned to the reference before it was dragged into the clipboard. You can then modify it as needed for each new source.

HTH,


Agnes


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Gerhard Killesreiter
In reply to this post by Nick Hall
Am 27.03.2017 um 18:28 schrieb Nick Hall:

> On 26/03/17 02:19, Dave Hamilton wrote:
>>
>> Is there a means by which you can specify the default value for a
>> drop-down list?
>>
>> In my case, when creating a repository entry for a source, 99% of the
>> time I want to specify ‘Scanned Copy’ (one of my added values) for
>> Media Type rather than the current default of ‘Book’.
>>
>> Is there any way of doing this?
>>
> No.  However, it would only require adding one line of source code.
>

Do you mean to hardcode Dave's custom value? Or to make it configurable
from the UI?

Cheers,
Gerhard


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Nick Hall
On 27/03/17 21:51, Gerhard Killesreiter wrote:
> Do you mean to hardcode Dave's custom value? Or to make it configurable
> from the UI?

I was suggesting adding the following line to the add_button_clicked
method in the gui/editors/displaytabs/repoembedlist.py file:

ref.set_media_type('Scanned Copy')

Making it configurable would require a bigger change.


Nick.



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Gerhard Killesreiter
Am 27.03.2017 um 23:34 schrieb Nick Hall:

> On 27/03/17 21:51, Gerhard Killesreiter wrote:
>> Do you mean to hardcode Dave's custom value? Or to make it configurable
>> from the UI?
>
> I was suggesting adding the following line to the add_button_clicked
> method in the gui/editors/displaytabs/repoembedlist.py file:
>
> ref.set_media_type('Scanned Copy')
>
> Making it configurable would require a bigger change.

I think that having some sort of "session" support would be very nice,
e.g. the most recently used source item would be offered for re-use when
you click on the "add source" button, etc. Or the most recently used
place when you want to attach a place to an event, etc.

Would save me a lot of time entering data.

Cheers,
Gerhard


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Dave Scheipers
Hi Gerhard

When I'm using a source during a session that doesn't lend itself moving to a clipboard (i.e. needing access to the attached citations) I'll add a tilde ~ to the start of the source title which places it as alphabetically first. When I'm done just remove the tilde.

Hope this trick helps, Dave

On Tue, Mar 28, 2017 at 7:57 AM, Gerhard Killesreiter <[hidden email]> wrote:
Am 27.03.2017 um 23:34 schrieb Nick Hall:
> On 27/03/17 21:51, Gerhard Killesreiter wrote:
>> Do you mean to hardcode Dave's custom value? Or to make it configurable
>> from the UI?
>
> I was suggesting adding the following line to the add_button_clicked
> method in the gui/editors/displaytabs/repoembedlist.py file:
>
> ref.set_media_type('Scanned Copy')
>
> Making it configurable would require a bigger change.

I think that having some sort of "session" support would be very nice,
e.g. the most recently used source item would be offered for re-use when
you click on the "add source" button, etc. Or the most recently used
place when you want to attach a place to an event, etc.

Would save me a lot of time entering data.

Cheers,
Gerhard


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Nick Hall
In reply to this post by Gerhard Killesreiter
On 28/03/17 12:57, Gerhard Killesreiter wrote:
> I think that having some sort of "session" support would be very nice,
> e.g. the most recently used source item would be offered for re-use when
> you click on the "add source" button, etc. Or the most recently used
> place when you want to attach a place to an event, etc.

This is why I created the Census and Form editors.  They automatically
add a citation to all data entered.


Displaying the most recently used objects in sel3ectors has already been
requested.  See:

5024: By default, to display [Last Recent Used] and [bookmarked] objects
on selectors

https://gramps-project.org/bugs/view.php?id=5024


Nick.



------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Default value for drop-down lists

Gerhard Killesreiter
In reply to this post by Dave Scheipers
Am 28.03.2017 um 14:17 schrieb Dave Scheipers:
> Hi Gerhard
>
> When I'm using a source during a session that doesn't lend itself moving to
> a clipboard (i.e. needing access to the attached citations) I'll add a
> tilde *~* to the start of the source title which places it as
> alphabetically first. When I'm done just remove the tilde.
>
> Hope this trick helps, Dave


Thanks, Dave, that's very helpful. I still would prefer an inbuilt
solution, though.

Cheers,
Gerhard


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gramps-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gramps-users
https://gramps-project.org
Loading...