Show
Ignore:
Timestamp:
04/30/08 13:35:20 (23 months ago)
Author:
JensDiemer
Message:

Experimental new Preferences!

  • New editor used the newforms models in the plugin class
  • Doesn't realy use the preferences (in search and find_and_replace) only display it
  • the system_settings doesn't used, too. Only for display the data.
  • Not ready in all cases
  • there can exist some print debug!
Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/pylucid/PyLucid/plugins_internal/find_and_replace/find_and_replace.py

    r1476 r1544  
    4141MAX_TERM_LEN = 150 
    4242 
     43class PreferencesForm(forms.Form): 
     44    min_term_len = forms.IntegerField( 
     45        help_text="Min length of a search term", 
     46        initial=2, min_value=1 
     47    ) 
     48    max_term_len = forms.IntegerField( 
     49        help_text="Max length of a search term", 
     50        initial=150, min_value=1, max_value=500 
     51    ) 
     52 
    4353 
    4454# for FindReplaceForm ChoiceField 
     
    6979 
    7080    def find_and_replace(self): 
     81        self.page_msg("Preferences:", self.preferences) 
     82 
    7183        context = {} 
    7284        if self.request.method == 'POST':