mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/fe-student.git
synced 2025-12-07 09:56:46 +08:00
feat:增加活动数据
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2022-12-11 16:57:58
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2022-12-12 13:42:24
|
||||
* @LastEditTime: 2022-12-12 17:05:42
|
||||
* @FilePath: /fe-stu/src/api/api.js
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
*/
|
||||
@@ -47,3 +47,5 @@ export const COMMENT_COLLECTION = '/comment/collection post'
|
||||
|
||||
export const ASSESSMENT_QUERY = assessmentId => `/assessment/queryAssessmentDetailById?assessmentId=${assessmentId} post`
|
||||
export const ASSESSMENT_SUBMIT = '/assessmentSubmit/submitAssessmentDetail'
|
||||
|
||||
export const ACTIVITY = '/activity'
|
||||
@@ -23,14 +23,18 @@
|
||||
<!-- <div class="title">【其他活动】管理者进阶腾飞班 - 专属线下活动</div>-->
|
||||
<div class="title">{{ data?.activityName }}</div>
|
||||
<div class="time" style="margin-top: 26px">
|
||||
<img width="15px" height="17px" src="../../assets/image/time.png"/>
|
||||
<div style="margin-left: 8px">{{ data?.createTime }}</div>
|
||||
<img
|
||||
style="width: 15px; height: 17px"
|
||||
src="../../assets/image/time.png"
|
||||
/>
|
||||
<div style="margin-left: 8px">
|
||||
{{ data?.activityStartTime + "-" + data?.activityEndTime }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="time" style="margin-top: 23px">
|
||||
<img
|
||||
width="16px"
|
||||
height="18px"
|
||||
src="../../assets/image/position.png"
|
||||
style="width: 16px; height: 18px"
|
||||
src="../../assets/image/position.png"
|
||||
/>
|
||||
<div style="margin-left: 8px">{{ data?.activityAddress }}</div>
|
||||
</div>
|
||||
@@ -46,15 +50,58 @@
|
||||
<div style="margin-left: 48px; margin-right: 48px">
|
||||
<div class="title">
|
||||
<img
|
||||
width="20px"
|
||||
height="20px"
|
||||
src="../../assets/image/book.png"
|
||||
style="width: 20px; height: 20px"
|
||||
src="../../assets/image/book.png"
|
||||
/>
|
||||
<div class="text">课程详情</div>
|
||||
<div class="text">活动详情</div>
|
||||
<div class="box"></div>
|
||||
</div>
|
||||
<div style="display: flex; align-items: center">
|
||||
<div class="content" v-html="data?.activityExplain"></div>
|
||||
<div class="activedetail">
|
||||
<div>
|
||||
<div>活动时长:</div>
|
||||
<div class="content">
|
||||
{{
|
||||
data?.activityDuration
|
||||
? data?.activityDuration + "分钟"
|
||||
: "-"
|
||||
}}
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div>活动地点:</div>
|
||||
<div class="content">
|
||||
{{ data?.activityAddress ? data?.activityAddress : "-" }}
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div>活动考勤:</div>
|
||||
<div class="content">
|
||||
{{
|
||||
data?.beforeSignIn
|
||||
? "开始前" + data?.beforeSignIn + "分钟开始签到"
|
||||
: "-"
|
||||
}}
|
||||
</div>
|
||||
<div class="content">
|
||||
{{
|
||||
data?.afterSignIn
|
||||
? "开始后" + data?.afterSignIn + "分钟结束签到"
|
||||
: "-"
|
||||
}}
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div>活动完成标准:</div>
|
||||
<div class="content">
|
||||
{{ data?.standardSettings ? "仅签到" : "-" }}
|
||||
</div>
|
||||
</div>
|
||||
<div>
|
||||
<div>活动说明:</div>
|
||||
<div class="content">
|
||||
{{ data?.activityExplain ? data?.activityExplain : "-" }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -62,8 +109,8 @@
|
||||
<div class="teacher">
|
||||
<div class="title">
|
||||
<img
|
||||
style="width: 24px; height: 20px"
|
||||
src="../../assets/image/call.png"
|
||||
style="width: 24px; height: 20px"
|
||||
src="../../assets/image/call.png"
|
||||
/>
|
||||
<div class="text">活动公告</div>
|
||||
<div class="box"></div>
|
||||
@@ -79,16 +126,18 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { TAS_ACTIVITY_DETAIL, TASK_ACTIVITY_SIGN, ACTIVITY } from "@/api/api";
|
||||
import { request, useRequest } from "@/api/request";
|
||||
|
||||
import {TAS_ACTIVITY_DETAIL, TASK_ACTIVITY_SIGN} from "@/api/api";
|
||||
import {request, useRequest} from "@/api/request";
|
||||
|
||||
const {data} = useRequest(TAS_ACTIVITY_DETAIL, {activityId: 22})
|
||||
|
||||
const { data } = useRequest(ACTIVITY, { activityId: 155 });
|
||||
console.log("data", data);
|
||||
const signClick = (tab, event) => {
|
||||
request(TASK_ACTIVITY_SIGN, {activitySubmitId:data.activityId,signInStatus:1}).then(res => {
|
||||
data.value.activityFlag = 1
|
||||
})
|
||||
request(TASK_ACTIVITY_SIGN, {
|
||||
activitySubmitId: data.activityId,
|
||||
signInStatus: 1,
|
||||
}).then((res) => {
|
||||
data.value.activityFlag = 1;
|
||||
});
|
||||
};
|
||||
</script>
|
||||
|
||||
@@ -216,14 +265,15 @@ const signClick = (tab, event) => {
|
||||
left: 23px;
|
||||
top: 53px;
|
||||
}
|
||||
|
||||
.content {
|
||||
margin-left: 8px;
|
||||
font-size: 14px;
|
||||
color: rgba(51, 51, 48, 1);
|
||||
font-weight: 500;
|
||||
line-height: 35px;
|
||||
.activedetail {
|
||||
margin-top: 30px;
|
||||
font-size: 14px;
|
||||
font-weight: 500;
|
||||
color: #333330;
|
||||
line-height: 36px;
|
||||
.content {
|
||||
color: #677d86;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -358,9 +408,9 @@ const signClick = (tab, event) => {
|
||||
background-color: rgba(255, 255, 255, 1);
|
||||
border-radius: 8px;
|
||||
background: linear-gradient(
|
||||
180deg,
|
||||
rgba(36, 120, 255, 0.15) 0%,
|
||||
rgba(255, 255, 255) 50%
|
||||
180deg,
|
||||
rgba(36, 120, 255, 0.15) 0%,
|
||||
rgba(255, 255, 255) 50%
|
||||
);
|
||||
|
||||
.title {
|
||||
|
||||
152
vite.config.js
152
vite.config.js
@@ -2,89 +2,89 @@
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2022-11-21 17:28:10
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2022-11-22 12:45:57
|
||||
* @LastEditTime: 2022-12-12 16:49:27
|
||||
* @FilePath: /fe-stu/vite.config.js
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
*/
|
||||
import {defineConfig} from 'vite'
|
||||
import { defineConfig } from 'vite'
|
||||
import vue from '@vitejs/plugin-vue'
|
||||
import legacy from '@vitejs/plugin-legacy'
|
||||
import {viteMockServe} from 'vite-plugin-mock'
|
||||
import { viteMockServe } from 'vite-plugin-mock'
|
||||
import topLevelAwait from "vite-plugin-top-level-await";
|
||||
|
||||
const path = require('path')
|
||||
|
||||
export default defineConfig(({command}) =>
|
||||
({
|
||||
base: '/fe-student',
|
||||
plugins: [
|
||||
vue(),
|
||||
// legacy({
|
||||
// targets: ['chrome 64', 'defaults', 'not IE 11']
|
||||
// }),
|
||||
topLevelAwait({
|
||||
promiseExportName: '__tla',
|
||||
promiseImportName: i => `__tla_${i}`
|
||||
}),
|
||||
// viteMockServe({
|
||||
// mockPath: './src/mock/mocks',
|
||||
// })
|
||||
],
|
||||
resolve: {
|
||||
alias: [
|
||||
{find: '@', replacement: path.resolve(__dirname, 'src')}
|
||||
]
|
||||
}, server: {
|
||||
proxy: {
|
||||
'/file/upload': {
|
||||
target: 'http://111.231.196.214:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/stu': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/queryVoteSubmitDetailById': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/work': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/discuss': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/discussSubmit': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/comment': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/vote': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/admin': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},'/activity': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},'/liveBroadcast': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},'/examination': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},'/assessment': {
|
||||
target: 'http://localhost:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
}
|
||||
const url = 'http://111.231.196.214:30001'
|
||||
export default defineConfig(({ command }) =>
|
||||
({
|
||||
base: '/fe-student',
|
||||
plugins: [
|
||||
vue(),
|
||||
// legacy({
|
||||
// targets: ['chrome 64', 'defaults', 'not IE 11']
|
||||
// }),
|
||||
topLevelAwait({
|
||||
promiseExportName: '__tla',
|
||||
promiseImportName: i => `__tla_${i}`
|
||||
}),
|
||||
// viteMockServe({
|
||||
// mockPath: './src/mock/mocks',
|
||||
// })
|
||||
],
|
||||
resolve: {
|
||||
alias: [
|
||||
{ find: '@', replacement: path.resolve(__dirname, 'src') }
|
||||
]
|
||||
}, server: {
|
||||
proxy: {
|
||||
'/file/upload': {
|
||||
target: 'http://111.231.196.214:30001',
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/stu': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/queryVoteSubmitDetailById': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/work': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/discuss': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/discussSubmit': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/comment': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/vote': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/admin': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
}, '/activity': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
}, '/liveBroadcast': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
}, '/examination': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
}, '/assessment': {
|
||||
target: url,
|
||||
changeOrigin: true,
|
||||
},
|
||||
}
|
||||
})
|
||||
}
|
||||
})
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user