mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-10-13 15:28:05 +01:00
clean up the code
This commit is contained in:
parent
dc8bb69359
commit
a96d679087
5
.vscode/settings.json
vendored
5
.vscode/settings.json
vendored
@ -24,5 +24,8 @@
|
|||||||
"source.organizeImports": "explicit"
|
"source.organizeImports": "explicit"
|
||||||
},
|
},
|
||||||
"typescript.preferences.importModuleSpecifier": "non-relative",
|
"typescript.preferences.importModuleSpecifier": "non-relative",
|
||||||
"editor.defaultFormatter": "esbenp.prettier-vscode"
|
"editor.defaultFormatter": "esbenp.prettier-vscode",
|
||||||
|
"[typescriptreact]": {
|
||||||
|
"editor.defaultFormatter": "vscode.typescript-language-features"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -265,16 +265,10 @@ class QueryTabComponentImpl extends React.Component<QueryTabComponentImplProps,
|
|||||||
}
|
}
|
||||||
|
|
||||||
public onExecuteQueryClick = async (): Promise<void> => {
|
public onExecuteQueryClick = async (): Promise<void> => {
|
||||||
// console.log("i am ",this.props.collection.databaseId);
|
|
||||||
// console.log("I am query",this.state.sqlQueryEditorContent );
|
|
||||||
// console.log("i am",this.props.collection.id());
|
|
||||||
const query1=this.state.sqlQueryEditorContent;
|
const query1=this.state.sqlQueryEditorContent;
|
||||||
const db = this.props.collection.databaseId;
|
const db = this.props.collection.databaseId;
|
||||||
const container = this.props.collection.id();
|
const container = this.props.collection.id();
|
||||||
useQueryMetadataStore.getState().setMetadata(query1, db, container);
|
useQueryMetadataStore.getState().setMetadata(query1, db, container);
|
||||||
console.log("i am ",query1);
|
|
||||||
console.log("I am db",db);
|
|
||||||
console.log("i am cnt",container);
|
|
||||||
this._iterator = undefined;
|
this._iterator = undefined;
|
||||||
|
|
||||||
setTimeout(async () => {
|
setTimeout(async () => {
|
||||||
|
@ -392,8 +392,7 @@ const QueryStatsTab: React.FC<Pick<ResultsViewProps, "queryResults">> = ({ query
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
metric: "User defined function execution time",
|
metric: "User defined function execution time",
|
||||||
value: `${
|
value: `${aggregatedQueryMetrics.runtimeExecutionTimes?.userDefinedFunctionExecutionTime?.toString() || 0
|
||||||
aggregatedQueryMetrics.runtimeExecutionTimes?.userDefinedFunctionExecutionTime?.toString() || 0
|
|
||||||
} ms`,
|
} ms`,
|
||||||
toolTip: "Total time spent executing user-defined functions",
|
toolTip: "Total time spent executing user-defined functions",
|
||||||
},
|
},
|
||||||
@ -699,8 +698,6 @@ const handleUpdatePolicy = async () => {
|
|||||||
indexingPolicy: updatedPolicy,
|
indexingPolicy: updatedPolicy,
|
||||||
});
|
});
|
||||||
|
|
||||||
console.log("Indexing policy successfully updated:", updatedPolicy);
|
|
||||||
|
|
||||||
const newIncluded = [...included, ...notIncluded.filter(item =>
|
const newIncluded = [...included, ...notIncluded.filter(item =>
|
||||||
selectedIndexes.find(s => s.index === item.index)
|
selectedIndexes.find(s => s.index === item.index)
|
||||||
)];
|
)];
|
||||||
@ -850,7 +847,8 @@ const renderRow = (item: IIndexMetric, index: number) => {
|
|||||||
'--spinner-thickness': '2px',
|
'--spinner-thickness': '2px',
|
||||||
'--spinner-color': '#0078D4',
|
'--spinner-color': '#0078D4',
|
||||||
} as React.CSSProperties} />
|
} as React.CSSProperties} />
|
||||||
</div>;}
|
</div>;
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
@ -891,8 +889,8 @@ return (
|
|||||||
fontWeight: "bold",
|
fontWeight: "bold",
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<div style={{ width: "18px", height: "18px" }}></div> {/* Checkbox column */}
|
<div style={{ width: "18px", height: "18px" }}></div>
|
||||||
<div style={{ width: "24px" }}></div> {/* Chevron column */}
|
<div style={{ width: "24px" }}></div>
|
||||||
<div>Index</div>
|
<div>Index</div>
|
||||||
<div><span style={{ whiteSpace: "nowrap" }}>Estimated Impact</span></div>
|
<div><span style={{ whiteSpace: "nowrap" }}>Estimated Impact</span></div>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user