Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Displaying date textbox in case of between

    Hi Isomorphic,

    In my ds for date field I have used <useTextField>true</useTextField>
    and it is displaying correctly date field with textbox and datechooser, but the problem is in my advanced search builder, if user choses 'between' as the criteria, then instead of displaying textbox, drop downs are coming.

    We are using SmartClient Version: 7.0 (built 2010-01-25)

    Please find attached the date.gif for your quick reference
    Attached Files

    #2
    Use editorType on the DataSourceField to affect what editor is used. Do not try to set widget-specific properties on DataSourceFields.

    Comment


      #3
      Hi Isomorphic,

      I am already using <editorType>date</editorType> in my ds. Complete entry for the date field in ds file is

      <field>
      <name>estimateDate</name>
      <type>datetime</type>
      <editorType>date</editorType>
      <useTextField>true</useTextField>
      </field>

      But still in case of 'between', instead of textbox it is displaying drop-downs. Could you please verify if it is a Smart Client bug or is there any special handling I need to do in case of 'between' as search operator

      Comment


        #4
        Again, do not try to set widget-specific properties (such as useTextField) on DataSourceFields. If you want to customize the editor, use editorType in conjunction with a trivial custom subclass of DateItem where you have set useTextField:true.

        Also note that your use of editorType is not correct. It takes a classname (eg "DateItem"), not just "date".

        Comment


          #5
          Hi Isomorphic,

          I could not understand how to use editorType in conjunction with a trivial custom subclass of DateItem where I have set useTextField:true.

          Could you please post some sample code

          Comment

          Working...
          X