mirror of
https://github.com/open-metadata/OpenMetadata.git
synced 2025-08-19 06:28:03 +00:00
Made Fields immutable for Applications (#20799)
* Made dropdown immutable for input field * added tests * removed test
This commit is contained in:
parent
9bd67915b4
commit
72b4ac486d
@ -50,6 +50,7 @@ import {
|
||||
elasticsearchToJsonLogic,
|
||||
getJsonTreeFromQueryFilter,
|
||||
jsonLogicToElasticsearch,
|
||||
READONLY_SETTINGS,
|
||||
} from '../../../../../../utils/QueryBuilderUtils';
|
||||
import { getExplorePath } from '../../../../../../utils/RouterUtils';
|
||||
import searchClassBase from '../../../../../../utils/SearchClassBase';
|
||||
@ -268,6 +269,10 @@ const QueryBuilderWidget: FC<WidgetProps> = ({
|
||||
<Builder {...props} />
|
||||
</div>
|
||||
)}
|
||||
settings={{
|
||||
...config.settings,
|
||||
...(props.readonly ? READONLY_SETTINGS : {}),
|
||||
}}
|
||||
value={treeInternal}
|
||||
onChange={handleChange}
|
||||
/>
|
||||
|
@ -50,6 +50,11 @@
|
||||
}
|
||||
|
||||
.query-builder-form-field {
|
||||
.ant-select-disabled.ant-select:not(.ant-select-customize-input)
|
||||
.ant-select-selector {
|
||||
color: @black;
|
||||
background-color: @background-color;
|
||||
}
|
||||
.hide--line.one--child {
|
||||
margin-top: 0;
|
||||
padding-top: 16px;
|
||||
|
@ -114,7 +114,14 @@ export const getSelectEqualsNotEqualsProperties = (
|
||||
},
|
||||
};
|
||||
};
|
||||
|
||||
export const READONLY_SETTINGS = {
|
||||
immutableGroupsMode: true,
|
||||
immutableFieldsMode: true,
|
||||
immutableOpsMode: true,
|
||||
immutableValuesMode: true,
|
||||
canRegroup: false,
|
||||
canRemove: false,
|
||||
};
|
||||
export const getSelectAnyInProperties = (
|
||||
parentPath: Array<string>,
|
||||
termObjects: Array<EsTerm>
|
||||
|
Loading…
x
Reference in New Issue
Block a user