Browse Source

feat: 数据集数据结构修改

pull/14/head
cp3hnu 1 year ago
parent
commit
2490a5c4c5
2 changed files with 8 additions and 5 deletions
  1. +4
    -2
      react-ui/src/pages/Dataset/datasetIntro.jsx
  2. +4
    -3
      react-ui/src/pages/Model/modelIntro.jsx

+ 4
- 2
react-ui/src/pages/Dataset/datasetIntro.jsx View File

@@ -126,7 +126,7 @@ const Dataset = () => {
};
const getDatasetVersions = (params) => {
getDatasetVersionIdList(params).then((res) => {
setWordList(res.data);
setWordList(res?.data?.content ?? []);
});
};
const handleChange = (value) => {
@@ -277,7 +277,9 @@ const Dataset = () => {
</div>
</div>
<div style={{ marginBottom: '10px', fontSize: '14px' }}>
{wordList.length > 0 ? wordList[0].description : null}
{wordList.length > 0 && wordList[0].description
? '版本描述:' + wordList[0].description
: null}
</div>
<Table columns={columns} dataSource={wordList} pagination={false} rowKey="id" />
</div>


+ 4
- 3
react-ui/src/pages/Model/modelIntro.jsx View File

@@ -121,8 +121,7 @@ const Dataset = () => {
};
const getModelVersions = (params) => {
getModelVersionIdList(params).then((ret) => {
console.log(ret);
setWordList(ret.data);
setWordList(ret?.data?.content ?? []);
});
};
const handleExport = async () => {
@@ -278,7 +277,9 @@ const Dataset = () => {
</div>
</div>
<div style={{ marginBottom: '10px', fontSize: '14px' }}>
{wordList.length > 0 ? wordList[0].description : null}
{wordList.length > 0 && wordList[0].description
? '版本描述:' + wordList[0].description
: null}
</div>
<Table columns={columns} dataSource={wordList} pagination={false} rowKey="id" />
</div>


Loading…
Cancel
Save