uniapp Use picker Error: Error in render: “TypeError: Cannot read property ‘XXX’ of undefined”

In uniapp, picker is used to render the object array, and the data is obtained from the background. The page code is as follows:

The data acquisition code is as follows:

Error report encountered:

The mistake here is that the property ProjectName is undefined, so you only need to add this property to the object array:

Previously:

Replace with:

If you use the hbuilder built-in browser, you may not see the error until you refresh it twice;

above;

Similar Posts: