Error while binding values to form field in extjs - extjs

I'm getting the following error, while using ExtJs MVC,
Uncaught TypeError: Cannot call method 'remove' of undefined
I traced the above error which goes to the line where i bind values from model to view,
Ext.getCmp('myForm').loadRecord(myModel);
Some of my form fields are disabled, and i'm still binding them. Is this the problem ?

The error occurs, whenever my model contains irregular data ( especially while trying to bind this unavailable data to a dual list ). Say my dual list contains item values like (A,B,C ) and when i'm trying to bind D, then this error occurs.

Related

TypeError: Cannot read properties of undefined (reading 'childRecords') in syncfusion gantt when collapsing a group

I got an error when collapsing groups in the syncfusion gant. I could reproduce it here with my own set of data (stackblitz).
The error full message :
TypeError: Cannot read properties of undefined (reading 'childRecords')
at e.expandCollapseChartRows (constant.js:13:25)
at e.expandCollapseChartRows (constant.js:13:25)
at e.collapsedGanttRow (constant.js:13:25)
at e.collapsed (constant.js:13:25)
at e.notify (dom.js:466:34)
at d.e.trigger (dom.js:466:34)
at eval (constant.js:130:22)
at e.notify (dom.js:466:34)
at d.e.trigger (dom.js:466:34)
at d.collapseRow (constant.js:130:22)
A screenshot showing the collapse action :
The error occurs only when there are two nested grouping levels which i think is allowed in the syncfusion gantt (right?)
This issue occurs because the TaskID values in your data are not unique. The TaskID field acts as the primary key field in the Gantt. Hence, it should be unique for every record. Please ensure that the TaskID field is unique for every record in your data to avoid this issue.

Can I check react-final-form directly for whether or not it's displaying a validation error for a particular field?

We currently have rules encoded in json that determine if react-final-form will display a validation error or not which I believe is standard. So meta.error will have data for an invalid field and our error display component will display the error. It would be convenient to be able to query something directly to find out if an error message is being displayed for a particular field. Like if the field is called name then form.name.meta.error or state.name.meta.error. Is there anything like that in the api?

Formik - how to access an error message inside an array using Yup validation?

I'm building a form with validations using Formik and Yup, sending specific error messages on missing fields. One of the fields (question) is and array of objects, and I'm can't find a way to access each individual error message.
I've created a validationSchema, but when I try to pass the array index on Formik error prop, I get an error.
Here's a sandbox with an abstraction of the whole form. In this example, it only work if I comment the second label field, but in a normal situation this must be dynamic:
https://codesandbox.io/s/0ov0vxmom0?fontsize=14
I figured out this happens because, when the form is rendered, the error object is empty by default. So if I pass the first index [0], when the object get an error, Formik is able to access it. If I get and error on the next field, for example, Formik would try to access the error on index[1], but the error object would have just index [0]. I must pass exactly the error position because my form could have multiple questions. Any tips?
If you are checking based on the object type you can add .typeError(msg) at the end of each Schema.
Ex.
Yub.object().typeError('Invalid Object');
Yub.array().typeError('Invalid Array');

Binding multiple index from a collection in XAML

Despite having read similar questions, I could not find any one that worked well in my case.
Basically, in order to extend the functionality of the TableRow class, I created a new one in which I have registered a DependencyProperty to clear the cells, and according to Msdn, I am trying to bind two index from a collection, as follows:
<my:myExtendedClass myProperty="{Binding Path=MyCollection[index1,index2]}">
However, I get the following error when I try to pass more than one index:
Error in Template: 'Unexpected token 'String' in rule: 'MarkupExtension ::= '{' TYPENAME (Arguments)? #'}'', in '{Binding Path=MyCollection[index1,index2]}'.'
Other approach would be bind the whole object MyCollection, but, in this way, I would not know which items I have to check each time I call the method.
So, how should I proceed? Thanks in advance!

Ckeckbox marked angularjs

I have an HTML structure mounted within a ng-repeat with ckeckboxes horizontally and vertically is a multidimensional array . When I click on one, I have to save to the database. So far so good , the problem being to bring these checkbox marked because the method that I bring the results , the model of the array of myself as undefined. Follow the link codes :
`http://jsfiddle.net/8eepu0o8/`
The issue lies here:
the model of the array of myself as undefined
Investigate why that's undefined (e.g. F12 your code, put debugger, write to console) - you won't get anything from model by binding to an undefined object.

Resources