king
2023-08-07 e1dbc27fbe3f083322f87fc46070191c619c5199
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import React, {Component} from 'react'
import PropTypes from 'prop-types'
 
import MkInterItem from './interItem'
// import './index.scss'
 
class MkInterfaces extends Component {
  static propTpyes = {
    BID: PropTypes.any,
    interfaces: PropTypes.array
  }
 
  state = {}
 
  shouldComponentUpdate (nextProps, nextState) { return false }
 
  /**
   * @description 组件销毁,清除state更新,清除快捷键设置
   */
  componentWillUnmount () {
    this.setState = () => {
      return
    }
  }
 
  render() {
    const { interfaces, BID } = this.props
 
    return (
      <>
        {interfaces.map(m => <MkInterItem key={m.uuid} config={m} BID={BID}/>)}
      </>
    )
  }
}
 
export default MkInterfaces