Deprecate ddb export(#353)
This commit is contained in:
parent
8fe4ec5ac8
commit
885eb8298f
@ -24,7 +24,6 @@ import {
|
|||||||
Popconfirm,
|
Popconfirm,
|
||||||
} from "@douyinfe/semi-ui";
|
} from "@douyinfe/semi-ui";
|
||||||
import { toPng, toJpeg, toSvg } from "html-to-image";
|
import { toPng, toJpeg, toSvg } from "html-to-image";
|
||||||
import { saveAs } from "file-saver";
|
|
||||||
import {
|
import {
|
||||||
jsonToMySQL,
|
jsonToMySQL,
|
||||||
jsonToPostgreSQL,
|
jsonToPostgreSQL,
|
||||||
@ -1049,30 +1048,6 @@ export default function ControlPanel({
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
|
||||||
DRAWDB: () => {
|
|
||||||
const result = JSON.stringify(
|
|
||||||
{
|
|
||||||
author: "Unnamed",
|
|
||||||
title: title,
|
|
||||||
date: new Date().toISOString(),
|
|
||||||
tables: tables,
|
|
||||||
relationships: relationships,
|
|
||||||
notes: notes,
|
|
||||||
subjectAreas: areas,
|
|
||||||
database: database,
|
|
||||||
...(databases[database].hasTypes && { types: types }),
|
|
||||||
...(databases[database].hasEnums && { enums: enums }),
|
|
||||||
},
|
|
||||||
null,
|
|
||||||
2,
|
|
||||||
);
|
|
||||||
const blob = new Blob([result], {
|
|
||||||
type: "text/plain;charset=utf-8",
|
|
||||||
});
|
|
||||||
saveAs(blob, `${exportData.filename}.ddb`);
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
MERMAID: () => {
|
MERMAID: () => {
|
||||||
setModal(MODAL.CODE);
|
setModal(MODAL.CODE);
|
||||||
|
Loading…
Reference in New Issue
Block a user