Squashed commit of the following:

commit 2991a0288e
Author: zcx <1078327420@qq.com>
Date:   Sun May 12 19:24:16 2024 +0800

    1

commit f0a01dc52a
Author: zcx <1078327420@qq.com>
Date:   Sun May 12 19:14:07 2024 +0800

    1

commit 103b91481d
Merge: 3f241a6 d73c814
Author: zcx <1078327420@qq.com>
Date:   Sat May 11 16:10:15 2024 +0800

    Merge branch 'develop' of https://bdgit.educoder.net/mwxbgi697/softegg into 曾晨曦_branch

commit d73c814619
Author: zcx <1078327420@qq.com>
Date:   Sat May 11 16:04:16 2024 +0800

    Squashed commit of the following:

    commit 3f241a6a46
    Author: zcx <1078327420@qq.com>
    Date:   Sat May 11 16:03:53 2024 +0800

        1

    commit ecd56eeb36
    Merge: f745de4 55dbf59
    Author: zcx <1078327420@qq.com>
    Date:   Sat May 11 16:03:36 2024 +0800

        Merge branch 'develop' of https://bdgit.educoder.net/mwxbgi697/softegg into 曾晨曦_branch

    commit f745de4fef
    Merge: d83686a c82f1ef
    Author: zcx <1078327420@qq.com>
    Date:   Sat May 11 15:51:39 2024 +0800

        Merge branch 'develop' of https://bdgit.educoder.net/mwxbgi697/softegg into 曾晨曦_branch

    commit d83686a012
    Author: zcx <1078327420@qq.com>
    Date:   Fri May 10 11:06:40 2024 +0800

        新界面

    commit 977b40cd4f
    Author: zcx <1078327420@qq.com>
    Date:   Fri May 10 10:44:28 2024 +0800

        新的页面代码

    commit 548cc49c7d
    Author: zcx <1078327420@qq.com>
    Date:   Fri May 10 10:20:18 2024 +0800

        聊天界面初始版

    commit ff3952859f
    Merge: 7b44e8a c656856
    Author: zcx <1078327420@qq.com>
    Date:   Fri May 10 10:15:56 2024 +0800

        Merge branch 'develop' of https://bdgit.educoder.net/mwxbgi697/softegg into 曾晨曦_branch

        # Conflicts:
        #	doc/自由同行-软件需求构思及描述.docx

    commit 7b44e8a348
    Author: zcx <1078327420@qq.com>
    Date:   Fri May 10 10:12:14 2024 +0800

        1

    commit 5e48c1f463
    Merge: 167bb2d bfb34b1
    Author: zcx <1078327420@qq.com>
    Date:   Fri May 10 10:10:13 2024 +0800

        Merge branch '曾晨曦_branch' of https://bdgit.educoder.net/mwxbgi697/softegg into 曾晨曦_branch

        # Conflicts:
        #	doc/“自由同行”软件需求规格说明书.docx

    commit 167bb2d273
    Author: zcx <1078327420@qq.com>
    Date:   Fri May 10 10:09:46 2024 +0800

        前端代码初始版

    commit e5d3488734
    Author: zcx <1078327420@qq.com>
    Date:   Sun Mar 31 11:48:46 2024 +0800

        更新

    commit bfb34b10a2
    Author: zcx <1078327420@qq.com>
    Date:   Tue Mar 26 11:15:48 2024 +0800

        需求规格说明书

    commit 26f7946e45
    Author: zcx <1078327420@qq.com>
    Date:   Tue Mar 26 11:08:14 2024 +0800

        1

    commit 31f1339042
    Merge: 3671794 9d34b69
    Author: zcx <1078327420@qq.com>
    Date:   Tue Mar 26 11:07:41 2024 +0800

        Merge branch 'develop' of https://bdgit.educoder.net/mwxbgi697/softegg into 曾晨曦_branch

    commit 36717942eb
    Author: zcx <1078327420@qq.com>
    Date:   Thu Mar 21 15:50:06 2024 +0800

        用例图
wuyifan_branch
zcx 1 year ago
parent 3f241a6a46
commit a8191418b4

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="WEB_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$/walktofree" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

@ -1,131 +0,0 @@
<template>
<div class="task-app">
<h1>任务发布和展示</h1>
<!-- 发布任务表单 -->
<div class="task-form-container">
<h2>发布任务</h2>
<form @submit.prevent="submitTask" class="task-form">
<label for="taskInput">任务</label>
<input type="text" id="taskInput" v-model.trim="newTask" placeholder="请输入任务内容">
<button type="submit" :disabled="!newTask.trim()">发布任务</button>
</form>
</div>
<!-- 展示任务列表 -->
<div class="task-list-container">
<h2>已发布任务</h2>
<div v-if="tasks.length > 0" class="task-list">
<ul>
<li v-for="(task, index) in tasks" :key="index">{{ task }}</li>
</ul>
</div>
<div v-else class="no-tasks">
<p>暂无任务</p>
</div>
</div>
</div>
</template>
<script>
import axios from 'axios';
export default {
data() {
return {
tasks: [],
newTask: ''
};
},
mounted() {
this.fetchTasks();
},
methods: {
fetchTasks() {
axios.get('/api/tasks')
.then(response => {
this.tasks = response.data.tasks;
})
.catch(error => {
console.error('Error fetching tasks:', error);
});
},
submitTask() {
if (!this.newTask.trim()) return;
axios.post('/api/tasks', { task: this.newTask.trim() })
.then(() => {
this.newTask = ''; //
this.fetchTasks(); //
})
.catch(error => {
console.error('Error submitting task:', error);
});
}
}
};
</script>
<style scoped>
.task-app {
max-width: 600px;
margin: 0 auto;
padding: 20px;
font-family: Arial, sans-serif;
}
.task-form-container {
border: 2px solid #007bff;
border-radius: 8px;
padding: 10px;
margin-bottom: 20px;
}
.task-list-container {
border: 2px solid #28a745;
border-radius: 8px;
padding: 10px;
}
.task-form {
margin-bottom: 20px;
}
.task-form input[type="text"] {
width: calc(100% - 80px);
padding: 8px;
font-size: 16px;
border: 1px solid #ccc;
border-radius: 4px;
}
.task-form button {
padding: 8px 16px;
font-size: 16px;
border: none;
border-radius: 4px;
background-color: #007bff;
color: #fff;
cursor: pointer;
}
.task-form button:disabled {
opacity: 0.5;
cursor: not-allowed;
}
.task-list {
margin-top: 20px;
}
.no-tasks {
color: #888;
}
/* 响应式设计 */
@media (max-width: 768px) {
.task-form input[type="text"] {
width: 100%;
}
}
</style>

@ -0,0 +1,41 @@
<template>
<div>
<h1>任务列表</h1>
<div v-for="task in tasks" :key="task.id" class="task-item">
<div>{{ task.title }}</div>
<div>{{ task.description }}</div>
</div>
</div>
</template>
<script>
export default {
data() {
return {
tasks: []
};
},
mounted() {
this.fetchTasks();
},
methods: {
async fetchTasks() {
try {
const response = await fetch('http://localhost:3000/tasks');
const data = await response.json();
this.tasks = data;
} catch (error) {
console.error(error);
}
}
}
};
</script>
<style>
.task-item {
border: 1px solid #ccc;
padding: 10px;
margin: 10px 0;
}
</style>

@ -0,0 +1,44 @@
<script setup>
defineProps({
msg: {
type: String,
required: true
}
})
</script>
<template>
<div class="greetings">
<h1 class="green">{{ msg }}</h1>
<h3>
Youve successfully created a project with
<a href="https://vitejs.dev/" target="_blank" rel="noopener">Vite</a> +
<a href="https://vuejs.org/" target="_blank" rel="noopener">Vue 3</a>.
</h3>
</div>
</template>
<style scoped>
h1 {
font-weight: 500;
font-size: 2.6rem;
position: relative;
top: -10px;
}
h3 {
font-size: 1.2rem;
}
.greetings h1,
.greetings h3 {
text-align: center;
}
@media (min-width: 1024px) {
.greetings h1,
.greetings h3 {
text-align: left;
}
}
</style>

@ -104,7 +104,7 @@ export default {
this.$router.push('/home');
},
gotomessage() {
this.$router.push('/message');
this.$router.push('/Communication');
},
gotomine() {
this.$router.push('/mine');

@ -0,0 +1,88 @@
<script setup>
import WelcomeItem from './WelcomeItem.vue'
import DocumentationIcon from './icons/IconDocumentation.vue'
import ToolingIcon from './icons/IconTooling.vue'
import EcosystemIcon from './icons/IconEcosystem.vue'
import CommunityIcon from './icons/IconCommunity.vue'
import SupportIcon from './icons/IconSupport.vue'
</script>
<template>
<WelcomeItem>
<template #icon>
<DocumentationIcon />
</template>
<template #heading>Documentation</template>
Vues
<a href="https://vuejs.org/" target="_blank" rel="noopener">official documentation</a>
provides you with all information you need to get started.
</WelcomeItem>
<WelcomeItem>
<template #icon>
<ToolingIcon />
</template>
<template #heading>Tooling</template>
This project is served and bundled with
<a href="https://vitejs.dev/guide/features.html" target="_blank" rel="noopener">Vite</a>. The
recommended IDE setup is
<a href="https://code.visualstudio.com/" target="_blank" rel="noopener">VSCode</a> +
<a href="https://github.com/johnsoncodehk/volar" target="_blank" rel="noopener">Volar</a>. If
you need to test your components and web pages, check out
<a href="https://www.cypress.io/" target="_blank" rel="noopener">Cypress</a> and
<a href="https://on.cypress.io/component" target="_blank" rel="noopener"
>Cypress Component Testing</a
>.
<br />
More instructions are available in <code>README.md</code>.
</WelcomeItem>
<WelcomeItem>
<template #icon>
<EcosystemIcon />
</template>
<template #heading>Ecosystem</template>
Get official tools and libraries for your project:
<a href="https://pinia.vuejs.org/" target="_blank" rel="noopener">Pinia</a>,
<a href="https://router.vuejs.org/" target="_blank" rel="noopener">Vue Router</a>,
<a href="https://test-utils.vuejs.org/" target="_blank" rel="noopener">Vue Test Utils</a>, and
<a href="https://github.com/vuejs/devtools" target="_blank" rel="noopener">Vue Dev Tools</a>. If
you need more resources, we suggest paying
<a href="https://github.com/vuejs/awesome-vue" target="_blank" rel="noopener">Awesome Vue</a>
a visit.
</WelcomeItem>
<WelcomeItem>
<template #icon>
<CommunityIcon />
</template>
<template #heading>Community</template>
Got stuck? Ask your question on
<a href="https://chat.vuejs.org" target="_blank" rel="noopener">Vue Land</a>, our official
Discord server, or
<a href="https://stackoverflow.com/questions/tagged/vue.js" target="_blank" rel="noopener"
>StackOverflow</a
>. You should also subscribe to
<a href="https://news.vuejs.org" target="_blank" rel="noopener">our mailing list</a> and follow
the official
<a href="https://twitter.com/vuejs" target="_blank" rel="noopener">@vuejs</a>
twitter account for latest news in the Vue world.
</WelcomeItem>
<WelcomeItem>
<template #icon>
<SupportIcon />
</template>
<template #heading>Support Vue</template>
As an independent project, Vue relies on community backing for its sustainability. You can help
us by
<a href="https://vuejs.org/sponsor/" target="_blank" rel="noopener">becoming a sponsor</a>.
</WelcomeItem>
</template>

@ -0,0 +1,87 @@
<template>
<div class="item">
<i>
<slot name="icon"></slot>
</i>
<div class="details">
<h3>
<slot name="heading"></slot>
</h3>
<slot></slot>
</div>
</div>
</template>
<style scoped>
.item {
margin-top: 2rem;
display: flex;
position: relative;
}
.details {
flex: 1;
margin-left: 1rem;
}
i {
display: flex;
place-items: center;
place-content: center;
width: 32px;
height: 32px;
color: var(--color-text);
}
h3 {
font-size: 1.2rem;
font-weight: 500;
margin-bottom: 0.4rem;
color: var(--color-heading);
}
@media (min-width: 1024px) {
.item {
margin-top: 0;
padding: 0.4rem 0 1rem calc(var(--section-gap) / 2);
}
i {
top: calc(50% - 25px);
left: -26px;
position: absolute;
border: 1px solid var(--color-border);
background: var(--color-background);
border-radius: 8px;
width: 50px;
height: 50px;
}
.item:before {
content: ' ';
border-left: 1px solid var(--color-border);
position: absolute;
left: 0;
bottom: calc(50% + 25px);
height: calc(50% - 25px);
}
.item:after {
content: ' ';
border-left: 1px solid var(--color-border);
position: absolute;
left: 0;
top: calc(50% + 25px);
height: calc(50% - 25px);
}
.item:first-of-type:before {
display: none;
}
.item:last-of-type:after {
display: none;
}
}
</style>

@ -86,6 +86,9 @@ export default {
gotohome() {
this.$router.push('/home');
},
search() {
this.$router.push('/DemandList');
}
}
}
</script>

@ -5,6 +5,8 @@ import Home from '../components/HomePage.vue';
import Message from '../components/message.vue';
import Mine from '../components/mine.vue';
import SearchPage from '../components/searchPage.vue';
import Communication from "@/components/Communication.vue";
import DemandList from "@/components/DemandList.vue";
const routes = [
{ path: '/', redirect: '/login' }, // 重定向到/login路径
@ -14,7 +16,9 @@ const routes = [
{ path: '/message', component: Message },
{ path: '/mine', component: Mine },
{ path: '/searchPage', component: SearchPage },
{ path: '/Communication', component: Communication }
{ path: '/Communication', component: Communication },
{ path: '/searchPage', component: SearchPage},
{ path: '/DemandList', component:DemandList}
];
const router = createRouter({

Loading…
Cancel
Save