react Select选择器循环

在父组件创建state

react Select选择器循环

创建一个循环的方法

react Select选择器循环

找到需要该方法的控件

react Select选择器循环

查看handleEntityFormModalVisible方法,将创建循环的方法导入

react Select选择器循环

在render中将状态加入

react Select选择器循环

在子组件中也加入状态

react Select选择器循环

在return中就可以使用grade数组了

react Select选择器循环

效果如下:

react Select选择器循环

相关文章:

  • 2021-11-19
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-05-21
  • 2022-12-23
  • 2021-11-05
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-12-11
  • 2022-12-23
  • 2022-12-23
  • 2021-05-22
  • 2021-07-13
  • 2022-12-23
相关资源
相似解决方案