mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-23 23:05:59 +00:00
electron app
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
CONNECTIONS=mysql
|
||||
CONNECTIONS=mysql,postgres
|
||||
|
||||
LABEL_mysql=MySql localhost
|
||||
SERVER_mysql=localhost
|
||||
USER_mysql=root
|
||||
@@ -6,6 +7,13 @@ PASSWORD_mysql=test
|
||||
PORT_mysql=3307
|
||||
ENGINE_mysql=mysql
|
||||
|
||||
LABEL_postgres=Postgres localhost
|
||||
SERVER_postgres=localhost
|
||||
USER_postgres=postgres
|
||||
PASSWORD_postgres=test
|
||||
PORT_postgres=5433
|
||||
ENGINE_postgres=postgres
|
||||
|
||||
TOOLBAR=home
|
||||
ICON_home=fas fa-home
|
||||
TITLE_home=Home
|
||||
|
||||
@@ -21,6 +21,12 @@ export default function ToolBar({ toolbarPortalRef }) {
|
||||
const setOpenedTabs = useSetOpenedTabs();
|
||||
const openedTabs = useOpenedTabs();
|
||||
|
||||
React.useEffect(() => {
|
||||
window['dbgate_createNewConnection'] = modalState.open;
|
||||
window['dbgate_newQuery'] = newQuery;
|
||||
window['dbgate_closeAll'] = () => setOpenedTabs([]);
|
||||
});
|
||||
|
||||
function openTabFromButton(button) {
|
||||
if (openedTabs.find((x) => x.tabComponent == 'InfoPageTab' && x.props && x.props.page == button.page)) {
|
||||
setOpenedTabs((tabs) =>
|
||||
|
||||
Reference in New Issue
Block a user