sorry it took me a while....
SQLFORM.widgets.string.widget and SQLFORM.widgets.date.widget
are the same.
what you want is to eliminate the datepicker popup. Technically that
is not part of the widget but handled by the JS in the page.
try this, immediately after you insert the form or field:
<script>
jQuery('#table_field').removeClass('date'); // or datetime
</script>
On Nov 28, 11:39 am, viniciusban <[email protected]> wrote:
> I found this thread in archives and I have some thoughts about this
> theme.
>
> 1) I need only one date field in just one of my tables to use
> SQLFORM.widgets.string.widget. All the others, I'd like to use the
> widget. How can I do this?
>
> Anyway, I think that if I set db.my_table.my_date_field.widget =
> SQLFORM.widgets.string.widget, web2py has to obbey me. Or not?
>
> 2) Another thought is: how could we translate the date picker widget?
> I'm Brazilian and my users don't need to know any English. So, it
> would be nice if months and days names were translated using the
> language files.
>
> --
> Vinicius Assef.
>
>
>
>
>
>
>
> ---------- Forwarded message ----------
> From: Thadeus Burgess <[email protected]>
> Date: Jan 19 2010, 5:46 pm
> Subject: How disable date widget?
> To: web2py-users
>
> If this is the case, then take a look at web2py_ajax.html in the views
> file, and remote the jquery code that creates the calendar popup.
>
> -Thadeus
>
> On Tue, Jan 19, 2010 at 1:45 PM, Thadeus Burgess
> <[email protected]> wrote:
> > I believe he is referring to the jQuerydatewidgetand he does not
> > want to use it ?
>
> > -Thadeus
>
> > On Tue, Jan 19, 2010 at 7:39 AM, mdipierro <[email protected]> wrote:
> >> Can you explain "it does not work" What error or incorrect behavior do
> >> you get?
>
> >> On Jan 19, 5:20 am, Alexandre Andrade <[email protected]>
> >> wrote:
> >>> Field('data_assinatura','date', requires=data,
> >>>widget=SQLFORM.widgets.string.widget),
>
> >>> db.convenio.data_assinatura.widget= SQLFORM.widgets.string.widget
>
> >>> and
>
> >>> Field('data_assinatura','date', requires=data,widget=None),
>
> >>> doesn't works.
>
> >>> change thefieldtostringwill make loose all functionalities of web2py do
> >>> work with dates.
>
> >>> --
> >>> Atenciosamente
>
> >>> --
> >>> =========================
> >>> Alexandre Andrade
> >>> Hipercenter.com
>
> >> --
> >> You received this message because you are subscribed to the Google Groups
> >> "web2py-users" group.
> >> To post to this group, send email to [email protected].
> >> To unsubscribe from this group, send email to
> >> [email protected].
> >> For more options, visit this group
> >> athttp://groups.google.com/group/web2py?hl=en.