企业管理
This commit is contained in:
@@ -229,15 +229,26 @@ export const AdminGrpEditModal: React.FC<IProps> = (props) => {
|
||||
<Button onClick={expandAll}>展开</Button>
|
||||
<Button onClick={collapseAll}>折叠</Button>
|
||||
</Space>
|
||||
<Tree
|
||||
checkable
|
||||
checkStrictly={false} // 父子联动
|
||||
treeData={menuTree}
|
||||
checkedKeys={checkedKeys}
|
||||
expandedKeys={expandedKeys}
|
||||
onExpand={(keys) => setExpandedKeys(keys)}
|
||||
onCheck={(keys) => setCheckedKeys(keys as React.Key[])}
|
||||
/>
|
||||
<div
|
||||
style={{
|
||||
maxHeight: 360,
|
||||
overflow: 'auto',
|
||||
border: '1px solid #d9d9d9',
|
||||
borderRadius: 6,
|
||||
padding: 8,
|
||||
background: '#fff',
|
||||
}}
|
||||
>
|
||||
<Tree
|
||||
checkable
|
||||
checkStrictly={false} // 父子联动
|
||||
treeData={menuTree}
|
||||
checkedKeys={checkedKeys}
|
||||
expandedKeys={expandedKeys}
|
||||
onExpand={(keys) => setExpandedKeys(keys)}
|
||||
onCheck={(keys) => setCheckedKeys(keys as React.Key[])}
|
||||
/>
|
||||
</div>
|
||||
</Form.Item>
|
||||
</Form>
|
||||
</ModalPlugin>
|
||||
|
||||
@@ -38,7 +38,13 @@ const AdminGrpSelect: React.FC<IProps> = (props) => {
|
||||
return (
|
||||
<Select
|
||||
status={props.status}
|
||||
showSearch
|
||||
showSearch={{
|
||||
// 搜索时使用 option.label 属性匹配
|
||||
optionFilterProp: 'label',
|
||||
// 下拉排序,可选
|
||||
filterSort: (optionA, optionB) =>
|
||||
(optionA?.label ?? '').toLowerCase().localeCompare((optionB?.label ?? '').toLowerCase()),
|
||||
}}
|
||||
allowClear={props.allowClear}
|
||||
value={props.value}
|
||||
onChange={(value) => {
|
||||
|
||||
@@ -38,7 +38,13 @@ const AdminDepSelect: React.FC<IProps> = (props) => {
|
||||
return (
|
||||
<Select
|
||||
status={props.status}
|
||||
showSearch
|
||||
showSearch={{
|
||||
// 搜索时使用 option.label 属性匹配
|
||||
optionFilterProp: 'label',
|
||||
// 下拉排序,可选
|
||||
filterSort: (optionA, optionB) =>
|
||||
(optionA?.label ?? '').toLowerCase().localeCompare((optionB?.label ?? '').toLowerCase()),
|
||||
}}
|
||||
allowClear={props.allowClear}
|
||||
value={props.value}
|
||||
onChange={(value) => {
|
||||
|
||||
Reference in New Issue
Block a user