diff --git a/api/app/lib/controllers/data/index.js b/api/app/lib/controllers/data/index.js index 51d653e3..93c7ac93 100644 --- a/api/app/lib/controllers/data/index.js +++ b/api/app/lib/controllers/data/index.js @@ -78,7 +78,7 @@ async function dataExport (ctx) { const tableAttributes = models[modalOption.tableName].tableAttributes let header = [] for (let k in tableAttributes) { - if (k != 'id') { + if (k != 'id' && tableAttributes[k].comment) { header.push({ title: tableAttributes[k].comment || '-', key: k, diff --git a/web/client/src/components/simpleFileDownButton.js b/web/client/src/components/simpleFileDownButton.js new file mode 100644 index 00000000..3878d345 --- /dev/null +++ b/web/client/src/components/simpleFileDownButton.js @@ -0,0 +1,40 @@ +import React, { useState, useEffect, useRef } from "react"; +import { connect } from "react-redux"; +import moment from 'moment' +import { Button } from "antd"; + +const SimpleFileDownButton = (props) => { + const { src, user } = props + const [downloadUrl, setDownloadUrl] = useState('') + + return ( + <> + + { + downloadUrl ?