最佳东方 react 职位弹窗组件
npm install ve-pc-react-cascader-post1. # 东方网升-pc-职位选择插件
1. 更改package.json版本
2. build:component
3. npm publish 注:镜像源需切换回NPM官方源
```
yarn install # 安装依赖模块
``
yarn dll # 静态资源预编译
``
yarn start # 运行开发环境,默认监听8888端口
``
yarn build:component # 组件打包
`jsx``
value={this.state.selectVal}
limit={5}
isExtraType={false}
isIcon={false}
isSave={false}
type={1}
// allow={['010908', '010907', '010906', '010111']}
title="请选择职位"
onSave={(arrCodes: string[], arrObj: any[]) => {
console.log('保存', arrCodes, arrObj);
this.setState({
selectVal: arrCodes,
})
this.handleCloseModal()
}}
onCancel={() => {
this.handleCloseModal()
console.log('取消')
}}
onSelect={(codeStr: string, codeObj: object) => {
console.log('选中回调', codeStr, codeObj)
}}
>
| 参数 | 说明 | 类型 | 默认值 |
| --- | --- | --- | --- |
| data | 数据源 | Array | - |
| value | 选中的id数组 | Array | - |
| limit | 最多选择数量 | number | 5 |
| categoryDisplay | 138指定类目二级 | array |
| isExtraType | 是否可选2级选项 | boolean | false |
| isIcon | 是否展示图标 | boolean | false |
| isSave | 是否单选直接关闭, true不关闭,false关闭 | boolean | false |
| type | 基础样式,1最佳东方黄,2招聘通蓝, 3大美业粉 | number | 1 |
| allow | 允许点击的内容code | Array | 所有code |
| title | 头部标题 | string | 请选择职位 |
| language | 中英文 | number | 1 |
| onSave | 保存回调 | function | - |
| onCancel | 取消回调 | function | - |
| onSelect | 选中回调 | function | - |