mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Framework stability fixes.
This commit is contained in:
parent
169d8fa480
commit
0ddd053e88
@ -71,7 +71,7 @@ SQLTab.propTypes = {
|
|||||||
getSQLValue: PropTypes.func.isRequired,
|
getSQLValue: PropTypes.func.isRequired,
|
||||||
};
|
};
|
||||||
|
|
||||||
export function getFieldMetaData(field, schema, value, viewHelperProps) {
|
export function getFieldMetaData(field, schema, value, viewHelperProps, onlyModeCheck=false) {
|
||||||
let retData = {
|
let retData = {
|
||||||
readonly: false,
|
readonly: false,
|
||||||
disabled: false,
|
disabled: false,
|
||||||
@ -89,6 +89,10 @@ export function getFieldMetaData(field, schema, value, viewHelperProps) {
|
|||||||
return retData;
|
return retData;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(onlyModeCheck) {
|
||||||
|
return retData;
|
||||||
|
}
|
||||||
|
|
||||||
let {visible, disabled, readonly} = field;
|
let {visible, disabled, readonly} = field;
|
||||||
|
|
||||||
let verInLimit = (_.isUndefined(viewHelperProps.serverInfo) ? true :
|
let verInLimit = (_.isUndefined(viewHelperProps.serverInfo) ? true :
|
||||||
|
@ -136,7 +136,9 @@ function getChangedData(topSchema, viewHelperProps, sessData, stringify=false) {
|
|||||||
/* Will be called recursively as data can be nested */
|
/* Will be called recursively as data can be nested */
|
||||||
const parseChanges = (schema, accessPath, changedData)=>{
|
const parseChanges = (schema, accessPath, changedData)=>{
|
||||||
schema.fields.forEach((field)=>{
|
schema.fields.forEach((field)=>{
|
||||||
let {modeSupported} = getFieldMetaData(field, schema, {}, viewHelperProps);
|
/* At this point the schema assignments like top may not have been done
|
||||||
|
So, only check the mode by passing true to getFieldMetaData */
|
||||||
|
let {modeSupported} = getFieldMetaData(field, schema, {}, viewHelperProps, true);
|
||||||
if(!modeSupported) {
|
if(!modeSupported) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -73,7 +73,7 @@ export default function DataGridViewWithHeaderForm(props) {
|
|||||||
</Box>
|
</Box>
|
||||||
</Box>}
|
</Box>}
|
||||||
</Box>
|
</Box>
|
||||||
<DataGridView {...otherProps} canAdd={false}/>
|
<DataGridView {...otherProps} label="" canAdd={false}/>
|
||||||
</Box>
|
</Box>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user