cancel
Showing results for 
Search instead for 
Did you mean: 

Date picker

xerox
Champ in-the-making
Champ in-the-making
If you want to to do an advanced search, and want to look at the created date, the datepicker goes only to 2008. Does anyone know where I can change this.
I know this isn't logical for created date, but I've just add my property retention date to the advanced search, and here I need it.

thx in advance

Nick
6 REPLIES 6

gavinc
Champ in-the-making
Champ in-the-making
It is possible to change the number of years that are shown but it's not currently configurable.

You will have to manually change the advanced-search.jsp in the /jsp/dialog folder, look for
<a:inputDatePicker
in the file and you'll see the 'yearCount' attribute, change this number to change the number of years displayed.

xerox
Champ in-the-making
Champ in-the-making
Thx, but this doesnt' solve my problem.
Now with my retention aspect I've used the file web-client-config-custom.xml

<!– Example of configuring advanced search –>
  
   <config evaluator="string-compare" condition="Advanced Search">
      <advanced-search>
         <content-types>
         </content-types>
         <custom-properties>
            <meta-data aspect="cm:retention" property="cm:lockRemove" />
         </custom-properties>
      </advanced-search>
   </config>

So in advanced-search.jsp isn't a inputDatePicker for my property.
Or over see I something?

Nick

gavinc
Champ in-the-making
Champ in-the-making
Apologies, I misunderstood your question.

Currently, there isn't a way to do what you want without changing the Java code. The custom properties UI controls are dynamically generated and the default attributes set. If you don't mind changing Java code and recompiling, the code for this is in org.alfresco.web.ui.repo.component.UISearchCustomProperties. Again seach for 'yearCount' and change appropriately.

In 1.3 we are adding the notion of "component generators" which are registered as managed beans. These will generate the dynamic controls used in the UI, this in turn will allow you to override the default behaviour or provide a completely different component. So basiclly this should be easier to do in the future.

xerox
Champ in-the-making
Champ in-the-making
thanx for your answer…
I think I'll wait for version 1.3Smiley Happy

kevinr
Star Contributor
Star Contributor
There is currently no way to configure the "years into the future" value for a custom attribute datapicker component. Feel free to raise a JIRA task for it.

Thanks,

Kevin

dwilson
Champ in-the-making
Champ in-the-making
Link to wiki article on this topic for forum searching archival info:

http://wiki.alfresco.com/wiki/Simple_Customisations#Changing_Year_Ranges