PDA

View Full Version : [CLOSED] All combobox are required after migrating from v1.6



ViDom
Oct 01, 2012, 8:14 AM
Hi,

Like in Title what's changed and maked that happend?

In v1.6 I've simply asign Truncate property to false but now there is no such a property any longer.

Is it renamed or deleted? How can I handle this?

Daniil
Oct 01, 2012, 10:28 AM
Hi @ViDom,

Please use the EnforceMaxLength property now.
http://docs.sencha.com/ext-js/4-1/#!/api/Ext.form.field.Text-cfg-enforceMaxLength

Thank you for the question. We will add a respective CHANGELOG item.

ViDom
Oct 01, 2012, 10:30 AM
Hi @ViDom,

Please use the EnforceMaxLength property now.
http://docs.sencha.com/ext-js/4-1/#!/api/Ext.form.field.Text-cfg-enforceMaxLength

Thank you for the question. We will add a respective CHANGELOG item.

I'm glad too help improve framework by testing it in extremly crazy situation/solution ;)

There is information that default value is false so it's shouldn't be required field or maybe I'm wrong?

Daniil
Oct 01, 2012, 10:33 AM
Hi,

False means that it will allow to type more than MaxLength and a validation error will be shown. If you need this behavior, then yes, you can omit this property.

If you need a behavior when it doesn't allow to type more that MaxLength, then you should explicitly set EnforceMaxLength to true.

ViDom
Oct 01, 2012, 10:45 AM
Hi,

False means that it will allow to type more than MaxLength and a validation error will be shown. If you need this behavior, then yes, you can omit this property.

If you need a behavior when it doesn't allow to type more that MaxLength, then you should explicitly set EnforceMaxLength to true.

but what about situation when I don't want make any restriction about length and don't show validation error?
Is there such a thing provide that kind functionality?

Daniil
Oct 01, 2012, 11:58 AM
Then, I think, you should not set MaxLength.

ViDom
Oct 01, 2012, 12:08 PM
Then, I think, you should not set MaxLength.

thing is I don't set MaxLenght at all and all the time I've got red border inside comboboxes even when it's shouldn't be that way.

Daniil
Oct 01, 2012, 12:11 PM
Please clarify what error does it show?

ViDom
Oct 01, 2012, 12:39 PM
Please clarify what error does it show?

This field is required in tooltip at combobox.

I've decide to revert all changes from v2.0 to v1.6 it's too many issues to resolved with migrating a big system where a lot of stuff maked for dynamically create.

Daniil
Oct 01, 2012, 12:41 PM
This error is produced by this setting.

AllowBlank="false"

If you don't need this error, you should remove this setting.

ViDom
Oct 01, 2012, 1:06 PM
This error is produced by this setting.

AllowBlank="false"

If you don't need this error, you should remove this setting.

that's the problem I've asign

AllowBlank = true;

Vladimir
Oct 01, 2012, 1:11 PM
Please post generated javascript.
Or can you provide simple test sample reproduces the problem?

I cannot reproduce the issue and you are first who has such issue with v2.0