Project

General

Profile

Revision 44be1b98

ID44be1b98d1ee620183243a3e0b39e5f41a541fba
Parent 1610c4b8
Child 060c7e9f

Added by Katja Luther almost 2 years ago

ref #7880: improve search configuration initialization

View differences:

eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/search/SearchOption.java
34 34
    }
35 35

  
36 36
    public boolean getPreference() {
37
        if (!PreferencesUtil.getPreferenceStore().contains(
38
                IPreferenceKeys.TAXON_SERVICE_CONFIGURATOR_TAXA)) {
37
        if (!PreferencesUtil.getPreferenceStore().contains(IPreferenceKeys.TAXON_SERVICE_CONFIGURATOR_TAXA)) {
39 38
            // initializes the search configurator
40 39
            PreferencesUtil.initializeSearchConfigurator();
41 40
        }
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/preference/PreferencesUtil.java
661 661
	public static IFindTaxaAndNamesConfigurator getSearchConfigurator() {
662 662
		IFindTaxaAndNamesConfigurator configurator = initializeSearchConfigurator();
663 663

  
664
		configurator.setDoTaxa(getPreferenceStore().getBoolean(
664
		configurator.setDoTaxa(getBooleanValue(
665 665
				TAXON_SERVICE_CONFIGURATOR_TAXA));
666
		configurator.setDoSynonyms(getPreferenceStore().getBoolean(
666
		configurator.setDoSynonyms(getBooleanValue(
667 667
				TAXON_SERVICE_CONFIGURATOR_SYNONYMS));
668
		configurator.setDoNamesWithoutTaxa(getPreferenceStore().getBoolean(
668
		configurator.setDoNamesWithoutTaxa(getBooleanValue(
669 669
				TAXON_SERVICE_CONFIGURATOR_NAMES));
670
		configurator.setDoTaxaByCommonNames(getPreferenceStore().getBoolean(
670
		configurator.setDoTaxaByCommonNames(getBooleanValue(
671 671
				TAXON_SERVICE_CONFIGURATOR_COMMON_NAMES));
672 672
		//configurator.setMatchMode(eu.etaxonomy.cdm.persistence.query.MatchMode.valueOf(getStringValue(TAXON_SERVICE_CONFIGURATOR_MATCH_MODE)));
673 673

  
......
704 704
		configurator.setPageNumber(0);
705 705
		// TODO currently limit results to 10000
706 706
		configurator.setPageSize(10000);
707

  
707
		setSearchConfigurator(configurator) ;
708 708
		return configurator;
709 709
	}
710 710

  
......
750 750
	 * Set default values for preferences
751 751
	 */
752 752
	public static void setDefaults() {
753
		getPreferenceStore().setDefault(createPreferenceString(TAXON_SERVICE_CONFIGURATOR_TAXA), true);
754
		getPreferenceStore().setDefault(createPreferenceString(TAXON_SERVICE_CONFIGURATOR_SYNONYMS),
753
		getPreferenceStore().setDefault(TAXON_SERVICE_CONFIGURATOR_TAXA, true);
754
		getPreferenceStore().setDefault(TAXON_SERVICE_CONFIGURATOR_SYNONYMS,
755 755
				true);
756 756
		getPreferenceStore().setDefault(createPreferenceString(EDIT_MAP_SERVICE_ACCES_POINT),
757 757
				"http://edit.africamuseum.be/edit_wp5/v1.2/rest_gen.php");

Also available in: Unified diff

Add picture from clipboard (Maximum size: 40 MB)