From 5a68190ca6361973bb98723c0711e88194cec7c3 Mon Sep 17 00:00:00 2001
From: jinsir <874871581@qq.com>
Date: Fri, 28 Feb 2025 19:53:40 +0800
Subject: [PATCH] =?UTF-8?q?=E6=97=A0=E7=94=A8?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
apps/web/src/App.tsx | 6 +-
.../components/coursePreviewAllmsg.tsx | 0
apps/web/src/app/main/course/preview/page.tsx | 0
.../common/container/CollapsibleContent.tsx | 0
.../src/components/common/input/InputList.tsx | 0
.../models/post/PostSelect/PostSelect.tsx | 96 +++++++++++++++++++
apps/web/src/hooks/useGetTaxonomy.ts | 0
7 files changed, 100 insertions(+), 2 deletions(-)
mode change 100644 => 100755 apps/web/src/app/main/course/preview/components/coursePreviewAllmsg.tsx
mode change 100644 => 100755 apps/web/src/app/main/course/preview/page.tsx
mode change 100644 => 100755 apps/web/src/components/common/container/CollapsibleContent.tsx
mode change 100644 => 100755 apps/web/src/components/common/input/InputList.tsx
create mode 100644 apps/web/src/components/models/post/PostSelect/PostSelect.tsx
mode change 100644 => 100755 apps/web/src/hooks/useGetTaxonomy.ts
diff --git a/apps/web/src/App.tsx b/apps/web/src/App.tsx
index 9e6304c..3ae08aa 100755
--- a/apps/web/src/App.tsx
+++ b/apps/web/src/App.tsx
@@ -11,11 +11,12 @@ import dayjs from "dayjs";
import "dayjs/locale/zh-cn";
import { AuthProvider } from './providers/auth-provider';
import { Toaster } from 'react-hot-toast';
-
+// import PostForm from './components/models/post/PostSelect/PostSelect';
dayjs.locale("zh-cn");
function App() {
return (
<>
+ {/* */}
-
+
+
>
);
}
diff --git a/apps/web/src/app/main/course/preview/components/coursePreviewAllmsg.tsx b/apps/web/src/app/main/course/preview/components/coursePreviewAllmsg.tsx
old mode 100644
new mode 100755
diff --git a/apps/web/src/app/main/course/preview/page.tsx b/apps/web/src/app/main/course/preview/page.tsx
old mode 100644
new mode 100755
diff --git a/apps/web/src/components/common/container/CollapsibleContent.tsx b/apps/web/src/components/common/container/CollapsibleContent.tsx
old mode 100644
new mode 100755
diff --git a/apps/web/src/components/common/input/InputList.tsx b/apps/web/src/components/common/input/InputList.tsx
old mode 100644
new mode 100755
diff --git a/apps/web/src/components/models/post/PostSelect/PostSelect.tsx b/apps/web/src/components/models/post/PostSelect/PostSelect.tsx
new file mode 100644
index 0000000..d564424
--- /dev/null
+++ b/apps/web/src/components/models/post/PostSelect/PostSelect.tsx
@@ -0,0 +1,96 @@
+// import React, { useState } from 'react';
+// import { Form, Select, Input } from 'antd';
+// import axios from 'axios';
+
+// const { Option } = Select;
+
+// // 假数据
+// const fakePostsData = Array.from({ length: 15 }, (_, index) => ({
+// id: index + 1,
+// type: 'Lecture',
+// name: `Lecture ${index + 1}`,
+// description: `This is lecture number ${index + 1}`,
+// }));
+
+// // 模拟获取数据的函数
+// async function fetchPosts(query = '') {
+// // 在实际应用中,这里应该是一个真实的API调用
+// return fakePostsData.filter(post =>
+// post.name.toLowerCase().includes(query.toLowerCase()) ||
+// post.description.toLowerCase().includes(query.toLowerCase())
+// );
+// }
+
+// const PostSelector = ({ value, onChange }) => {
+// const [posts, setPosts] = useState([]);
+// const [searchValue, setSearchValue] = useState('');
+
+// const handleSearch = async (query) => {
+// setSearchValue(query);
+// const result = await fetchPosts(query);
+// setPosts(result);
+// };
+
+// const handlePostChange = (selectedIds) => {
+// onChange(selectedIds); // 更新父组件的状态
+// };
+
+// const renderOption = (post) => (
+//
+// );
+
+// return (
+//
+// );
+// };
+
+// const PostForm = () => {
+// const [form] = Form.useForm();
+
+// const onFinish = (values) => {
+// console.log('Received values of form: ', values);
+// };
+
+// return (
+//
+// form.setFieldsValue({ postIds: selectedIds })}
+// />
+//
+
+//
+//
+//
+//
+// );
+// };
+
+// export default PostForm;
\ No newline at end of file
diff --git a/apps/web/src/hooks/useGetTaxonomy.ts b/apps/web/src/hooks/useGetTaxonomy.ts
old mode 100644
new mode 100755