From 85d17cdfb4c0349917b6beba9e60ab5c41edf7d6 Mon Sep 17 00:00:00 2001 From: zttProjectSpace Date: Fri, 25 Apr 2025 15:43:21 +0800 Subject: [PATCH] =?UTF-8?q?=E6=95=B0=E6=8D=AE=E9=9B=86=E7=AE=A1=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/svg/taskEmpty.svg | 61 ++++ src/assets/svg/taskFailed.svg | 46 +++ src/assets/svg/taskList.svg | 13 + src/assets/svg/taskLoading.svg | 49 ++++ src/assets/svg/taskScore.svg | 7 + src/components/Upload/index.vue | 1 - src/styles/dataSet.scss | 140 ++++----- src/styles/dataSetDrawer.scss | 151 ++++++++++ src/styles/reset.scss | 4 + src/views/dataSet/dataSetDrawer.vue | 319 +++++++++++++++++++++ src/views/knowledgeFile/dataSetDialog.vue | 7 +- src/views/knowledgeFile/index.vue | 13 +- src/views/knowledgeLibrary/libraryInfo.vue | 43 +-- src/views/login/index.vue | 2 - 14 files changed, 757 insertions(+), 99 deletions(-) create mode 100644 src/assets/svg/taskEmpty.svg create mode 100644 src/assets/svg/taskFailed.svg create mode 100644 src/assets/svg/taskList.svg create mode 100644 src/assets/svg/taskLoading.svg create mode 100644 src/assets/svg/taskScore.svg create mode 100644 src/styles/dataSetDrawer.scss create mode 100644 src/views/dataSet/dataSetDrawer.vue diff --git a/src/assets/svg/taskEmpty.svg b/src/assets/svg/taskEmpty.svg new file mode 100644 index 0000000..5fc2704 --- /dev/null +++ b/src/assets/svg/taskEmpty.svg @@ -0,0 +1,61 @@ + + + Created with Pixso. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/assets/svg/taskFailed.svg b/src/assets/svg/taskFailed.svg new file mode 100644 index 0000000..d604e88 --- /dev/null +++ b/src/assets/svg/taskFailed.svg @@ -0,0 +1,46 @@ + + + Created with Pixso. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/assets/svg/taskList.svg b/src/assets/svg/taskList.svg new file mode 100644 index 0000000..7246b5e --- /dev/null +++ b/src/assets/svg/taskList.svg @@ -0,0 +1,13 @@ + + + Created with Pixso. + + + + + + + + + + diff --git a/src/assets/svg/taskLoading.svg b/src/assets/svg/taskLoading.svg new file mode 100644 index 0000000..183bad2 --- /dev/null +++ b/src/assets/svg/taskLoading.svg @@ -0,0 +1,49 @@ + + + Created with Pixso. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/assets/svg/taskScore.svg b/src/assets/svg/taskScore.svg new file mode 100644 index 0000000..0796468 --- /dev/null +++ b/src/assets/svg/taskScore.svg @@ -0,0 +1,7 @@ + + + Created with Pixso. + + + + diff --git a/src/components/Upload/index.vue b/src/components/Upload/index.vue index dac2eb3..4067bba 100644 --- a/src/components/Upload/index.vue +++ b/src/components/Upload/index.vue @@ -291,7 +291,6 @@ const handleChange = (file: UploadFile) => { // 超出文件数量限制时的处理 const handleExceed = (files: File[], uploadFiles: any[]) => { - console.log(uploadFiles.length); ElMessage.warning(`超出文件数量限制,最多只能上传 ${props.maxFileNum} 个文件!`); }; diff --git a/src/styles/dataSet.scss b/src/styles/dataSet.scss index f199375..b6fc73b 100644 --- a/src/styles/dataSet.scss +++ b/src/styles/dataSet.scss @@ -51,85 +51,87 @@ } .statusFail, - .statusSuccess, - .statusCancel { - height: 24px; - width: fit-content; - padding: 0px 8px; - font-size: 12px; - line-height: 24px; - color: rgb(255 255 255); - text-align: center; - border-radius: 2px; - } + .statusSuccess, + .statusCancel { + height: 24px; + width: fit-content; + padding: 0px 8px; + font-size: 12px; + line-height: 24px; + color: rgb(255 255 255); + text-align: center; + border-radius: 2px; + } - .statusFail { - background: rgb(227, 32, 32); - } + .statusFail { + background: rgb(227, 32, 32); + } - .statusSuccess { - background: rgb(36, 171, 54); - } + .statusSuccess { + background: rgb(36, 171, 54); + } - .statusCancel { - background: rgb(141, 152, 170); - } + .statusCancel { + background: rgb(141, 152, 170); + } - .statusWaitIng { - display: flex; - align-items: center; - gap: 9px; - } + .statusWaitIng { + display: flex; + align-items: center; + gap: 9px; + } - @keyframes rotate-img { - from { - transform: rotate(0); - } + @keyframes rotate-img { + from { + transform: rotate(0); + } - to { - transform: rotate(360deg); - } - } + to { + transform: rotate(360deg); + } + } - .icon-loading { - height: 16px; - width: 16px; - background-repeat: no-repeat !important; - background-size: 100% !important; - display: inline-block; - background: url('/src/assets/icons/taskLoading.png'); - } + .icon-loading { + height: 16px; + width: 16px; + background-repeat: no-repeat !important; + background-size: 100% !important; + display: inline-block; + background: url('/src/assets/icons/taskLoading.png'); + } - .icon-box { - animation: rotate-img 0.8s infinite linear; - } + .icon-box { + animation: rotate-img 0.8s infinite linear; + } + + .statusGenerate { + display: flex; + align-items: center; - .statusGenerate { - display: flex; - align-items: center; - - .percent-box { - .el-progress-bar { - width: 88px; - } - .el-progress__text { - width: fit-content; - } - } - - .el-progress__text { - width: 24px; - min-width: 18px; - color: rgb(0 0 0); - } - - .statusGenerateText { - font-size: 12px; - font-family: 'HarmonyOS Sans SC Medium'; - margin-left: 2px; - color: rgb(0 0 0); - } + .percent-box { + .el-progress-bar { + width: 88px; } + .el-progress__text { + width: fit-content; + } + } + + .el-progress__text { + width: 24px; + min-width: 18px; + color: rgb(0 0 0); + } + .statusGenerateText { + font-size: 12px; + font-family: 'HarmonyOS Sans SC Medium'; + margin-left: 2px; + color: rgb(0 0 0); + } + } + .dataSet-container-table-box{ + margin-top: 16px; + } } diff --git a/src/styles/dataSetDrawer.scss b/src/styles/dataSetDrawer.scss new file mode 100644 index 0000000..5db65cb --- /dev/null +++ b/src/styles/dataSetDrawer.scss @@ -0,0 +1,151 @@ +.dataSetDrawerContainer{ + width: 60% !important; + .el-drawer__header{ + padding-top: 24px !important; + padding-left: 24px !important; + padding-bottom: 16px !important; + margin: unset !important; + .el-drawer__title{ + font-size: 16px; + font-weight: 700; + color: var(--o-text-color-primary); + + } + } + .el-drawer__footer{ + padding:0 24px 0 0 !important; + height: 48px !important; + display: flex; + align-items: center; + box-shadow: 0px -8px 16px 0px rgba(0, 0,0,0.1); + background-color: var(--o-bg-color-base); + } + .el-checkbox__input.is-indeterminate .el-checkbox__inner:before { + width: 12px !important; + top: 4px !important; + } + + .dataSetInfoContainer{ + display: flex; + flex-direction: column; + gap: 16px; + width: 100%; + padding: 16px 24px 24px !important; + background-color: var(--o-bg-color-light); + border-radius: 8px; + margin-bottom: 16px; + .dataSetInfoBox{ + display: flex; + justify-content: space-between; + } + .dataSetInfoNameBox,.dataSetInfoDescBox{ + display: flex; + gap: 24px; + } + .dataSetInfoNameBox{ + align-items: center; + } + + .dataSetInfoLabel{ + color: var(--o-text-color-secondary); + font-size: 12px; + position: relative; + } + + .dataSetInfoLabel::before{ + position: absolute; + color: var(--el-color-danger); + content: "*"; + left: -8px; + top: 1px; + } + + .dataSetInfoTitle{ + font-size: 14px; + } + + .dataSetInfoContent{ + width: 412px; + color: var(--o-text-color-primary); + font-size: 12px; + } + + .dataSetInfoEdit{ + color: #6395fd; + cursor: pointer; + font-size: 12px; + } + + .dataSetInfoOps{ + display: flex; + gap: 8px; + color: #6395fd; + cursor: pointer; + font-size: 12px; + } + } + + .dataSetInfoCenterBox{ + display: flex; + justify-content:space-between; + margin-bottom: 8px; + .dataSetInfoRight{ + display: flex; + gap: 8px; + .dataSetListBox,.dataSetScoreBox{ + height: 32px; + padding:0 16px; + display: flex; + align-items: center; + justify-content: center; + background: var(--o-bg-color-dark); + border-radius: 4px; + .dataSetListIcon{ + margin-top: 5px; + margin-right: 4px; + } + .dataSetScoreIcon{ + margin-top: 4px; + margin-right: 4px; + } + .dataSetListText,.dataSetScoreText{ + margin-right: 8px; + color: var(--o-text-color-secondary); + } + + .dataSetListNumber{ + font-size: 14px; + } + + .dataSetScoreNumber{ + color: var(--o-color-major); + font-size: 14px; + } + } + } + .el-button.is-disabled, .el-button.is-disabled:hover { + background-color: #ebedf3 !important; + background-image: none; + border-color: unset !important; + color: var(--o-button-color_disabled) !important; + cursor: not-allowed; + } + } + + .el-table tbody tr td:first-child .cell { + padding-left: 16px !important; + } + + .el-table tbody .el-table__cell:not(.el-table__expanded-cell):first-child, + .el-table thead .cell, + .el-table tbody .el-table-column--selection + th.el-table__cell, + .el-table-column--selection + td.el-table__cell { + padding: unset !important; + } + tbody .el-table__cell{ + padding: 0 !important; + } + .el-table__row .cell{ + padding: 8px !important; + } +} \ No newline at end of file diff --git a/src/styles/reset.scss b/src/styles/reset.scss index b640950..28eb3db 100644 --- a/src/styles/reset.scss +++ b/src/styles/reset.scss @@ -315,6 +315,10 @@ div:focus { } } +.el-table__header thead tr th { + background-color: #f4f6fa !important; +} + .el-button:focus-visible { outline: unset !important; } diff --git a/src/views/dataSet/dataSetDrawer.vue b/src/views/dataSet/dataSetDrawer.vue new file mode 100644 index 0000000..cdca683 --- /dev/null +++ b/src/views/dataSet/dataSetDrawer.vue @@ -0,0 +1,319 @@ + + diff --git a/src/views/knowledgeFile/dataSetDialog.vue b/src/views/knowledgeFile/dataSetDialog.vue index a2bc14c..2418a2e 100644 --- a/src/views/knowledgeFile/dataSetDialog.vue +++ b/src/views/knowledgeFile/dataSetDialog.vue @@ -1,7 +1,7 @@