diff --git a/src/App.vue b/src/App.vue
index 026b3e9..16e7961 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -8,18 +8,20 @@
+
+
diff --git a/src/views/material-center/components/raw-material/components/add-raw-material-drawer/style.scss b/src/views/material-center/components/raw-material/components/add-raw-material-drawer/style.scss
new file mode 100644
index 0000000..d3db885
--- /dev/null
+++ b/src/views/material-center/components/raw-material/components/add-raw-material-drawer/style.scss
@@ -0,0 +1,110 @@
+.xt-add-raw-material-modal {
+ .ant-drawer-header {
+ height: 58px;
+ border-bottom: none;
+ }
+
+ .ant-upload {
+ width: 100%;
+ }
+
+ .ant-select {
+ //.ant-select-selection-overflow-item {
+ // max-width: 50%;
+ //}
+ }
+
+ .ant-drawer-body {
+ padding: 0;
+ display: flex;
+ flex-direction: column;
+
+ .cts {
+ color: #211f24;
+ font-family: $font-family-regular;
+ font-size: 14px;
+ font-style: normal;
+ font-weight: 400;
+ line-height: 22px;
+ }
+
+ .content {
+ .upload-box {
+ transition: all 0.3s;
+
+ &:hover {
+ border-color: #6d4cfe;
+ }
+ }
+
+ .upload-text {
+ color: #000;
+ text-align: center;
+ font-family: $font-family-regular;
+ font-size: 12px;
+ font-style: normal;
+ font-weight: 400;
+ line-height: 20px;
+ }
+
+ .ant-progress {
+ display: flex;
+ align-items: center;
+ justify-content: center;
+
+ .ant-progress-outer {
+ position: relative;
+ width: 100%;
+ height: 6px !important;
+ margin: 0;
+ padding: 0;
+
+ .ant-progress-inner {
+ position: absolute;
+ top: 50%;
+ left: 0;
+ transform: translateY(-50%);
+ width: 100px;
+ height: 6px !important;
+ background: var(--BG-200, #F2F3F5);
+
+ .ant-progress-bg {
+ height: 6px !important;
+ background-color: #6D4CFE;
+ }
+
+ }
+ }
+
+
+ .ant-progress-text {
+ color: var(--Text-1, #211F24);
+ font-family: $font-family-regular;
+ font-size: 12px;
+ font-style: normal;
+ font-weight: 400;
+
+ .anticon {
+ font-size: 16px;
+ }
+
+ }
+
+ &.ant-progress-status-success {
+ .ant-progress-outer {
+ .ant-progress-bg {
+ background-color: #25C883;
+ }
+ }
+
+ .ant-progress-text {
+ color: #25C883;
+ }
+ }
+ }
+ }
+
+ .footer {
+ }
+ }
+}
diff --git a/src/views/material-center/components/raw-material/components/edit-raw-material-modal/index.vue b/src/views/material-center/components/raw-material/components/edit-raw-material-modal/index.vue
new file mode 100644
index 0000000..a31b01f
--- /dev/null
+++ b/src/views/material-center/components/raw-material/components/edit-raw-material-modal/index.vue
@@ -0,0 +1,291 @@
+
+
+
diff --git a/src/views/material-center/components/raw-material/components/edit-raw-material-modal/style.scss b/src/views/material-center/components/raw-material/components/edit-raw-material-modal/style.scss
new file mode 100644
index 0000000..e69de29
diff --git a/src/views/material-center/components/raw-material/components/filter-block/index.vue b/src/views/material-center/components/raw-material/components/filter-block/index.vue
index 43e667b..32696fa 100644
--- a/src/views/material-center/components/raw-material/components/filter-block/index.vue
+++ b/src/views/material-center/components/raw-material/components/filter-block/index.vue
@@ -16,13 +16,30 @@
- 序号
-
-
-
-
-
+ 标签
+
+
+
+
+
+
+
+
+
上传时间
import { defineEmits, defineProps, ref, nextTick } from 'vue';
-import { Button, Input, DatePicker } from 'ant-design-vue';
+import { Button, Input, DatePicker, Select } from 'ant-design-vue';
import dayjs from 'dayjs';
+import { getRawMaterialTagsList } from '@/api/all/generationWorkshop';
const props = defineProps({
query: {
@@ -67,6 +85,14 @@ const props = defineProps({
const emits = defineEmits(['search', 'reset', 'update:query']);
const created_at = ref([]);
+const tagData = ref([]);
+
+const getTagData = async () => {
+ const { code, data } = await getRawMaterialTagsList();
+ if (code === 200) {
+ tagData.value = data ?? [];
+ }
+};
const handleSearch = () => {
emits('update:query', props.query);
@@ -96,4 +122,18 @@ const handleReset = () => {
created_at.value = [];
emits('reset');
};
+
+onMounted(() => {
+ getTagData();
+});
+
+
diff --git a/src/views/material-center/components/raw-material/components/table/index.vue b/src/views/material-center/components/raw-material/components/table/index.vue
index 82843bc..9bb6c91 100644
--- a/src/views/material-center/components/raw-material/components/table/index.vue
+++ b/src/views/material-center/components/raw-material/components/table/index.vue
@@ -33,8 +33,13 @@
-
-
+
+
@@ -45,6 +50,17 @@
{{ TABS_LIST.find((item) => item.value === record.type)?.label ?? '-' }}
+
+
+
+
+ {{ `${tag.name.slice(0, 5)}...` }}
+
+ {{ tag.name }}
+
+
+ -
+
{{ formatFileSize(record.size) }}
@@ -60,7 +76,10 @@
![]()
-
+
+
@@ -72,11 +91,11 @@
diff --git a/src/views/material-center/components/raw-material/components/tags-manage-modal/style.scss b/src/views/material-center/components/raw-material/components/tags-manage-modal/style.scss
new file mode 100644
index 0000000..2ec1a38
--- /dev/null
+++ b/src/views/material-center/components/raw-material/components/tags-manage-modal/style.scss
@@ -0,0 +1,51 @@
+.raw-material-tags-manage-modal {
+ border-radius: 8px;
+
+ .ant-modal-body {
+ // padding: 24px 24px 44px !important;
+ overflow: hidden;
+ display: flex;
+ flex-direction: column;
+
+ .arcanto-btn {
+ width: fit-content;
+
+ .ant-btn-icon {
+ line-height: 16px;
+ }
+ }
+
+ .tag-list {
+ display: flex;
+ flex-wrap: wrap;
+ gap: 12px;
+
+ .tag-item {
+ height: 24px;
+ display: flex;
+ align-items: center;
+ background: #f5f5f5;
+ border-radius: 4px;
+ padding: 4px 12px;
+ position: relative;
+
+ .delete-icon {
+ position: absolute;
+ z-index: 1;
+ top: -6px;
+ right: -6px;
+ cursor: pointer;
+ width: 12px;
+ height: 12px;
+ display: none;
+ }
+
+ &:hover {
+ .delete-icon {
+ display: block;
+ }
+ }
+ }
+ }
+ }
+}
diff --git a/src/views/material-center/components/raw-material/constants.ts b/src/views/material-center/components/raw-material/constants.ts
index 436dd01..ff0bfb1 100644
--- a/src/views/material-center/components/raw-material/constants.ts
+++ b/src/views/material-center/components/raw-material/constants.ts
@@ -5,6 +5,10 @@ export enum RawMaterialType {
Text = 2,
}
+export const imageExtensions = ['.jpg', '.jpeg', '.png', '.gif', '.webp', '.bmp'];
+export const videoExtensions = ['.mp4', '.mov', '.avi', '.flv', '.wmv', '.m4v'];
+export const documentExtensions = ['.txt', '.doc', '.docx', '.pdf', '.xls', '.xlsx'];
+
export const TABS_LIST = [
{
label: '全部',
@@ -37,9 +41,10 @@ export const ORIGIN_LIST = [
export const INITIAL_QUERY = {
name: '',
- uid: '',
+ // uid: '',
type: RawMaterialType.All,
created_at: [],
+ tag_ids: [],
sort_column: undefined,
sort_order: undefined,
};
@@ -55,6 +60,11 @@ export const TABLE_COLUMNS = [
dataIndex: 'type',
width: 80,
},
+ {
+ title: '标签',
+ dataIndex: 'tags',
+ width: 190,
+ },
{
title: '来源',
dataIndex: 'origin',
@@ -81,7 +91,7 @@ export const TABLE_COLUMNS = [
{
title: '操作',
dataIndex: 'operation',
- width: 100,
+ width: 180,
fixed: 'right',
- }
-]
\ No newline at end of file
+ },
+];
diff --git a/src/views/material-center/components/raw-material/img/icon-no-text.png b/src/views/material-center/components/raw-material/img/icon-no-text.png
new file mode 100644
index 0000000..2cbb9e0
Binary files /dev/null and b/src/views/material-center/components/raw-material/img/icon-no-text.png differ
diff --git a/src/views/material-center/components/raw-material/index.vue b/src/views/material-center/components/raw-material/index.vue
index 0673c1c..c2d716a 100644
--- a/src/views/material-center/components/raw-material/index.vue
+++ b/src/views/material-center/components/raw-material/index.vue
@@ -1,14 +1,20 @@