底部tabbar修改 首页 班级 我的页面修改 添加班级功能 添加老师页面
|
|
@ -4,9 +4,9 @@ const install = (Vue, vm) => {
|
|||
// baseUrl: 'http://2087p773d1.wicp.vip', // 请求的本域名
|
||||
// baseUrl: 'https://lchighpass.zhieasy.cn',
|
||||
// baseUrl: 'http://speaking.viphk.91tunnel.com',//测试https://speaking.iava.top/
|
||||
baseUrl: 'http://yml.dev.bc3.top',//
|
||||
// baseUrl: 'http://yml.dev.bc3.top',//
|
||||
// baseUrl: 'https://ielts.zhieasy.cn',//正式
|
||||
// baseURL: 'https://api.admin-v2.langsi.online',
|
||||
baseURL: 'https://api.admin-v2.langsi.online',
|
||||
// baseUrl: 'http://i3qsdb.natappfree.cc',//正式
|
||||
|
||||
// baseUrl: 'http://hwihh5.natappfree.cc',
|
||||
|
|
@ -42,7 +42,7 @@ const install = (Vue, vm) => {
|
|||
// 所以哪怕您重新登录修改了Storage,下一次的请求将会是最新值
|
||||
// const token = uni.getStorageSync('token');
|
||||
|
||||
const token = " Bearer f545811267c149bc85fb14e8e8638e94"
|
||||
const token = " Bearer ca5a6cd7473c4b18b22044321b1fba91"
|
||||
|
||||
// console.log("我是token", token)
|
||||
config.header.Authorization = token;
|
||||
|
|
|
|||
47
components/tab-bar/tab-bar.vue
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
<template>
|
||||
<view>
|
||||
<view class="u-page">
|
||||
<!-- 所有内容的容器 -->
|
||||
</view>
|
||||
<!-- 与包裹页面所有内容的元素u-page同级,且在它的下方 -->
|
||||
<u-tabbar v-model="current" :list="list" icon-size='40rpx' active-color='#3996fd' inactive-color="#c8c7cb"></u-tabbar>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
list: [
|
||||
{
|
||||
iconPath: require('@/static/tabbar/home.png'),
|
||||
selectedIconPath:require('@/static/tabbar/home-active.png'),
|
||||
text: '首页',
|
||||
customIcon: true,
|
||||
pagePath:'/pages/index/index2'
|
||||
},
|
||||
{
|
||||
iconPath: require('@/static/tabbar/tiku.png'),
|
||||
selectedIconPath:require('@/static/tabbar/tiku-act.png'),
|
||||
text: '题库',
|
||||
customIcon: true,
|
||||
pagePath:'/pages/home/home'
|
||||
}
|
||||
,{
|
||||
iconPath: require('@/static/tabbar/my.png'),
|
||||
selectedIconPath:require('@/static/tabbar/my-active.png'),
|
||||
text: '我的',
|
||||
customIcon: true,
|
||||
pagePath:'/pages/user/usertwo'
|
||||
},
|
||||
],
|
||||
current: 0
|
||||
}
|
||||
},
|
||||
}
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
/deep/.u-tabbar__content__item__button{
|
||||
top: 20rpx !important;
|
||||
}
|
||||
</style>
|
||||
58
pages.json
|
|
@ -34,16 +34,7 @@
|
|||
}
|
||||
},
|
||||
|
||||
{
|
||||
"path" : "pages/pages_index/teacher_index",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText": "首页",
|
||||
"navigationBarBackgroundColor": "#4473f6",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},
|
||||
|
||||
|
||||
{
|
||||
|
||||
|
|
@ -138,7 +129,28 @@
|
|||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "pages/user/user",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText": "",
|
||||
"navigationBarBackgroundColor": "#4473f6",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
},
|
||||
{
|
||||
"path" : "pages/Mystudent/addTeacher",
|
||||
"style" :
|
||||
{
|
||||
"navigationBarTitleText": "",
|
||||
"navigationBarBackgroundColor": "#4473f6",
|
||||
"enablePullDownRefresh": false,
|
||||
"navigationStyle": "custom"
|
||||
}
|
||||
}
|
||||
|
||||
],
|
||||
"subPackages": [
|
||||
{
|
||||
|
|
@ -218,6 +230,32 @@
|
|||
|
||||
|
||||
],
|
||||
"tabBar": {
|
||||
"color": "#a9b7b7",
|
||||
"selectedColor": "#5185fd",
|
||||
"borderStyle": "white",
|
||||
"backgroundColor": "#ffffff",
|
||||
"list": [
|
||||
{
|
||||
"selectedIconPath": "/static/tabbar/home.png",
|
||||
"iconPath": "/static/tabbar/home-active.png",
|
||||
"pagePath": "pages/index/index",
|
||||
"text": "首页"
|
||||
},
|
||||
{
|
||||
"selectedIconPath": "/static/tabbar/tiku.png",
|
||||
"iconPath": "/static/tabbar/tiku-act.png",
|
||||
"pagePath": "pages/Mystudent/student",
|
||||
"text": "题库"
|
||||
}
|
||||
,{
|
||||
"selectedIconPath": "/static/tabbar/my.png",
|
||||
"iconPath": "/static/tabbar/my-active.png",
|
||||
"pagePath": "pages/user/user",
|
||||
"text": "我的"
|
||||
}
|
||||
]
|
||||
},
|
||||
"globalStyle": {
|
||||
"navigationBarTextStyle": "black",
|
||||
"navigationBarTitleText": "uni-app",
|
||||
|
|
|
|||
371
pages/Mystudent/addTeacher.vue
Normal file
|
|
@ -0,0 +1,371 @@
|
|||
<template>
|
||||
<view class="searchpage">
|
||||
<u-navbar title="添加老师" :border-bottom="false" :background="bgc" title-color='#2E4975' title-size='36'
|
||||
height='36' :custom-back="addstu"></u-navbar>
|
||||
<u-toast ref="uToast" />
|
||||
<view class="serchbox">
|
||||
<view class="serchimg">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/uVMACkynkipOxuTYDqm0">
|
||||
|
||||
</image>
|
||||
</view>
|
||||
<input type="text"
|
||||
v-model="searchKeyword"
|
||||
placeholder="搜索相关内容..."
|
||||
class="input"
|
||||
placeholder-style="color:#C7CDD3"
|
||||
@input="search()">
|
||||
</view>
|
||||
<view class="check_card">
|
||||
<!-- <view class="check_card_stu " v-for="(item,index ) in stulist" :key="index" @click="toggleSelection(item)" :class="{ 'act1': item.isSelected }">
|
||||
<view class="check_card_stu_info_left">
|
||||
<view class="class_card_left">
|
||||
<image :src="item.headImgUrl"></image>
|
||||
</view>
|
||||
<view class="class_card_right">
|
||||
<view class="class_card_right_top" v-html="highlightSearch(item.nickName)">
|
||||
|
||||
</view>
|
||||
<view class="class_card_right_bot">
|
||||
ID:{{item.id}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view> -->
|
||||
<view class="teacher_card" v-for="(item,index) in stulist" :key="index" @click="toggleSelection(item)" :class="{ 'act1': item.isSelected }">
|
||||
<view class="class_card_left">
|
||||
<image src=" https://file.langsi.online/yasiimg/web/static/udWNTRG6GulmTtgPRQ49"></image>
|
||||
</view>
|
||||
<view class="class_card_right">
|
||||
<view class="class_card_right_top" v-html="item.teacherInfo.nickname">
|
||||
|
||||
</view>
|
||||
<view class="class_card_right_bot">
|
||||
{{item.roleText}}
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view class="zhanwei" style="width: 100%; height: 230rpx;">
|
||||
|
||||
</view>
|
||||
<view class="botbtn" @click="addstu()" v-show="selectedIds.length>0">
|
||||
<view class="btn">
|
||||
确定添加({{selectedIds.length}})
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
bgc: {
|
||||
backgroundColor: "#F6F9FC",
|
||||
},
|
||||
checkindex: 1,
|
||||
stulist:[],
|
||||
searchKeyword:'',
|
||||
orgstulist:[],
|
||||
selectedIds: [],
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
// this.classid=option.id
|
||||
this.selectedIds=JSON.parse(decodeURIComponent(option.teacherinfo))
|
||||
|
||||
},
|
||||
onShow(){
|
||||
this.getallstu()
|
||||
},
|
||||
methods: {
|
||||
addstu() {
|
||||
console.log('调用了');
|
||||
uni.setStorageSync('selectedteacherinfo', this.selectedIds);
|
||||
|
||||
// Navigate back to the previous page
|
||||
uni.navigateBack({
|
||||
delta: 1, // Number of pages to go back
|
||||
success(res) {
|
||||
console.log(res);
|
||||
},
|
||||
fail(err) {
|
||||
console.error(err);
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
},
|
||||
toggleSelection(item) {
|
||||
// const selectedIndex = this.selectedIds.indexOf(item.id);
|
||||
const selectedIndex = this.selectedIds.findIndex(selectedItem => selectedItem.id === item.id);
|
||||
if (selectedIndex === -1) {
|
||||
// If not selected, add to the array and apply the 'act1' class
|
||||
this.selectedIds.push({ name: item.teacherInfo.nickname, avatar: item.teacherInfo.avatar, id: item.teacherId });
|
||||
|
||||
item.isSelected = true; // Add a property to the item to track selection
|
||||
} else {
|
||||
// If already selected, remove from the array and remove the 'act1' class
|
||||
this.selectedIds.splice(selectedIndex, 1);
|
||||
item.isSelected = false;
|
||||
console.log(this.selectedIds,'selectedIdsselectedIdsselectedIds');
|
||||
}
|
||||
|
||||
},
|
||||
search() {
|
||||
// 根据关键字过滤 this.classlist
|
||||
if (this.searchKeyword !== '') {
|
||||
const filteredList = JSON.parse(JSON.stringify(this.orgstulist)).filter(item => {
|
||||
// 匹配 nickName 或者 id
|
||||
return item.teacherInfo.nickname.includes(this.searchKeyword)
|
||||
});
|
||||
// 更新 this.classlist 为过滤后的列表
|
||||
this.stulist = filteredList;
|
||||
this.selectedIds.forEach(selectedItem => {
|
||||
const index = this.stulist.findIndex(item => item.teacherId === selectedItem.teacherId);
|
||||
if (index !== -1) {
|
||||
this.$set(this.stulist, index, { ...this.stulist[index], isSelected: true });
|
||||
}
|
||||
});
|
||||
} else {
|
||||
this.fuwei();
|
||||
}
|
||||
},
|
||||
fuwei() {
|
||||
|
||||
this.stulist = JSON.parse(JSON.stringify(this.orgstulist));
|
||||
this.selectedIds.forEach(selectedItem => {
|
||||
const index = this.stulist.findIndex(item => item.teacherId === selectedItem.teacherId);
|
||||
if (index !== -1) {
|
||||
this.$set(this.stulist, index, { ...this.stulist[index], isSelected: true });
|
||||
}
|
||||
});
|
||||
},
|
||||
highlightSearch(name) {
|
||||
// 使用正则表达式替换匹配到的 searchKeyword 为带有颜色的文字
|
||||
if (this.searchKeyword) {
|
||||
const regex = new RegExp(this.searchKeyword, 'gi');
|
||||
return name.replace(regex, match => `<span style="color: #2D7CE6 ;">${match}</span>`);
|
||||
}
|
||||
return name;
|
||||
},
|
||||
getallstu(){
|
||||
this.$u.get(`https://api.admin-v2.langsi.online/admin-api/classroom/teacher/list`).then(res => {
|
||||
|
||||
|
||||
if (res.code == 0) {
|
||||
this.stulist=res.data
|
||||
this.orgstulist = JSON.parse(JSON.stringify(res.data));
|
||||
this.selectedIds.forEach(selectedItem => {
|
||||
const index = this.stulist.findIndex(item => item.teacherId === selectedItem.id);
|
||||
if (index !== -1) {
|
||||
this.$set(this.stulist, index, { ...this.stulist[index], isSelected: true });
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
page {
|
||||
background: linear-gradient(183deg, #F0F6FF 0%, #FAFAFA 100%);
|
||||
}
|
||||
|
||||
.searchpage {
|
||||
width: 750rpx;
|
||||
padding: 0 32rpx;
|
||||
|
||||
.serchbox {
|
||||
padding: 0 32rpx;
|
||||
display: flex;
|
||||
flex-wrap: nowrap;
|
||||
margin-top: 30rpx;
|
||||
align-items: center;
|
||||
width: 686rpx;
|
||||
height: 88rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
|
||||
.serchimg {
|
||||
width: 30.51rpx;
|
||||
height: 32rpx;
|
||||
margin-right: 24rpx;
|
||||
}
|
||||
|
||||
.input {
|
||||
margin: 0 auto;
|
||||
width: 568rpx;
|
||||
height: 88rpx;
|
||||
border-radius: 30rpx;
|
||||
// background-color: #f5f8fc;
|
||||
// display: flex;
|
||||
// justify-content: center;
|
||||
// align-items: center;
|
||||
// text-align: center;
|
||||
font-size: 28rpx;
|
||||
font-family: Source Han Sans CN, Source Han Sans CN-Light;
|
||||
font-weight: 300;
|
||||
text-align: left;
|
||||
color: #a7b9cd;
|
||||
letter-spacing: 1.2rpx;
|
||||
line-height: 36rpx;
|
||||
// padding: 0 100rpx;
|
||||
// padding-right: 135rpx;
|
||||
box-sizing: border-box;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.check_card {
|
||||
margin-top: 20rpx;
|
||||
.teacher_card{
|
||||
margin-bottom: 20rpx;
|
||||
padding: 24rpx;
|
||||
display: flex;
|
||||
flex-wrap: nowrap;
|
||||
width: 686rpx;
|
||||
height: 130rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
.class_card_left {
|
||||
width: 76rpx;
|
||||
height: 76rpx;
|
||||
}
|
||||
|
||||
.class_card_right {
|
||||
margin-left: 20rpx;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
|
||||
.class_card_right_top {
|
||||
width: 100%;
|
||||
font-size: 28rpx;
|
||||
font-family:'PingFang','PingFang';
|
||||
font-weight: bold;
|
||||
color: #072F5A;
|
||||
}
|
||||
|
||||
.class_card_right_bot {
|
||||
margin-top: 8rpx;
|
||||
font-size: 24rpx;
|
||||
font-family:'PingFang','PingFang';
|
||||
font-weight: 500;
|
||||
color: #2D7CE6;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.check_card_stu {
|
||||
display: flex;
|
||||
flex-wrap: nowrap;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
padding: 32rpx;
|
||||
width: 686rpx;
|
||||
height: 148rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
border: 2rpx solid #FFFFFF;
|
||||
margin-bottom: 20rpx;
|
||||
|
||||
.check_card_stu_info_left {
|
||||
display: flex;
|
||||
flex-wrap: nowrap;
|
||||
|
||||
.class_card_left {
|
||||
width: 76rpx;
|
||||
height: 76rpx;
|
||||
}
|
||||
|
||||
.class_card_right {
|
||||
margin-left: 12rpx;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
|
||||
.class_card_right_top {
|
||||
width: 100%;
|
||||
font-size: 28rpx;
|
||||
font-family: 'PingFang', 'PingFang';
|
||||
font-weight: bold;
|
||||
color: #072F5A;
|
||||
}
|
||||
|
||||
.class_card_right_bot {
|
||||
margin-top: 4rpx;
|
||||
font-size: 20rpx;
|
||||
font-family: 'PingFang', 'PingFang';
|
||||
font-weight: 500;
|
||||
color: rgba(7, 47, 90, 0.6);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.check_card_stu_info_right {
|
||||
width: 50%;
|
||||
display: flex;
|
||||
flex-wrap: nowrap;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
|
||||
.class_info {
|
||||
width: 110rpx;
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
justify-content: center;
|
||||
|
||||
.class_info_top {
|
||||
font-size: 20rpx;
|
||||
font-family: 'PingFang', 'PingFang';
|
||||
font-weight: 500;
|
||||
color: rgba(7, 47, 90, 0.5);
|
||||
}
|
||||
|
||||
.class_info_bot {
|
||||
margin-top: 12rpx;
|
||||
font-size: 28rpx;
|
||||
font-family: 'PingFang', 'PingFang';
|
||||
font-weight: 800;
|
||||
color: #2D7CE6;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
.act1 {
|
||||
border: 2rpx solid #2D7CE6;
|
||||
}
|
||||
}
|
||||
.botbtn{
|
||||
padding: 32rpx 32rpx 0 32rpx;
|
||||
margin-left: -32rpx;
|
||||
position: fixed;
|
||||
bottom: 0;
|
||||
width: 750rpx;
|
||||
height: 200rpx;
|
||||
background: #FFFFFF;
|
||||
box-shadow: 0rpx -10rpx 16rpx 0rpx rgba(202,202,202,0.25);
|
||||
border-radius: 40rpx 40rpx 0rpx 0rpx;
|
||||
.btn{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: 28rpx;
|
||||
font-family:'PingFang','PingFang';
|
||||
font-weight: 800;
|
||||
color: #FFFFFF;
|
||||
width: 686rpx;
|
||||
height: 80rpx;
|
||||
background: linear-gradient(180deg, #74AFFF 0%, #2D7CE6 100%);
|
||||
border-radius: 104rpx 104rpx 104rpx 104rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,10 +1,6 @@
|
|||
<template>
|
||||
<view class="addpage">
|
||||
<u-navbar :title="title"
|
||||
:border-bottom="false"
|
||||
:background="bgc"
|
||||
title-color='#2E4975'
|
||||
title-size='36'
|
||||
<u-navbar :title="title" :border-bottom="false" :background="bgc" title-color='#2E4975' title-size='36'
|
||||
height='36'></u-navbar>
|
||||
<view class="topbox">
|
||||
<view class="search_box">
|
||||
|
|
@ -19,10 +15,7 @@
|
|||
|
||||
</image>
|
||||
</view>
|
||||
<input type="text"
|
||||
placeholder="搜索相关内容..."
|
||||
class="input"
|
||||
placeholder-style="color:#C7CDD3 ">
|
||||
<input type="text" placeholder="搜索相关内容..." class="input" placeholder-style="color:#C7CDD3 ">
|
||||
</view>
|
||||
|
||||
</view>
|
||||
|
|
@ -182,7 +175,8 @@
|
|||
</view>
|
||||
</view>
|
||||
<!-- 弹出层 -->
|
||||
<u-popup v-model="show" mode="bottom" length="75%" :safe-area-inset-bottom='true' :closeable="true" :duration="300">
|
||||
<u-popup v-model="show" mode="bottom" length="75%" :safe-area-inset-bottom='true' :closeable="true"
|
||||
:duration="300">
|
||||
<view class="pop-up">
|
||||
<view class="caption">创建班级</view>
|
||||
<!-- 班级图像 -->
|
||||
|
|
@ -225,7 +219,9 @@
|
|||
<view class="caption_boder_text2">点击头像选择班级学员</view>
|
||||
</view>
|
||||
<view class="caption_boder">
|
||||
<view class="class_tp_image"><image src="http://tmp/4cj9prAeuoV015239042fae83018055c4c5c86e5231e.png" mode=""></image></view>
|
||||
<view class="class_tp_image">
|
||||
<image src="http://tmp/4cj9prAeuoV015239042fae83018055c4c5c86e5231e.png" mode=""></image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 班级老师 -->
|
||||
|
|
@ -235,7 +231,9 @@
|
|||
<view class="caption_boder_text2">点击头像选择班级学员</view>
|
||||
</view>
|
||||
<view class="caption_boder">
|
||||
<view class="class_tp_image"><image src="http://tmp/4cj9prAeuoV015239042fae83018055c4c5c86e5231e.png" mode=""></image></view>
|
||||
<view class="class_tp_image">
|
||||
<image src="http://tmp/4cj9prAeuoV015239042fae83018055c4c5c86e5231e.png" mode=""></image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="caption_add">添加</view>
|
||||
|
|
@ -260,8 +258,7 @@ export default {
|
|||
form: {
|
||||
name: ''
|
||||
},
|
||||
list: [
|
||||
{
|
||||
list: [{
|
||||
value: '1',
|
||||
label: '听力'
|
||||
},
|
||||
|
|
@ -315,6 +312,7 @@ export default {
|
|||
.no-padding /deep/ .u-form-item {
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
page {
|
||||
background: #F6F9FC;
|
||||
}
|
||||
|
|
@ -332,6 +330,7 @@ page {
|
|||
flex-wrap: nowrap;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
.search_box {
|
||||
|
||||
width: 480rpx;
|
||||
|
|
@ -406,6 +405,7 @@ page {
|
|||
}
|
||||
|
||||
}
|
||||
|
||||
.addclass {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
|
@ -585,6 +585,7 @@ page {
|
|||
border: 2rpx solid #2D7CE6;
|
||||
}
|
||||
}
|
||||
|
||||
.botbtn {
|
||||
padding: 32rpx 32rpx 0 32rpx;
|
||||
margin-left: -32rpx;
|
||||
|
|
@ -595,6 +596,7 @@ page {
|
|||
background: #FFFFFF;
|
||||
box-shadow: 0rpx -10rpx 16rpx 0rpx rgba(202, 202, 202, 0.25);
|
||||
border-radius: 40rpx 40rpx 0rpx 0rpx;
|
||||
|
||||
.btn {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
|
@ -610,8 +612,10 @@ page {
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
.pop-up {
|
||||
padding: 30rpx 32rpx;
|
||||
|
||||
.caption {
|
||||
font-size: 36rpx;
|
||||
text-align: center;
|
||||
|
|
@ -619,12 +623,14 @@ page {
|
|||
color: #2E4975;
|
||||
padding-top: 20rpx;
|
||||
}
|
||||
|
||||
.caption_top {
|
||||
font-size: 28rpx;
|
||||
font-family: 'PingFang';
|
||||
color: #2E4975;
|
||||
margin-top: 40rpx;
|
||||
}
|
||||
|
||||
.dashboard {
|
||||
position: absolute;
|
||||
width: 40rpx;
|
||||
|
|
@ -632,24 +638,29 @@ page {
|
|||
bottom: 0;
|
||||
right: 0;
|
||||
}
|
||||
|
||||
.caption_input {
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
border: 2rpx solid #DDE2EE;
|
||||
margin-top: 16rpx;
|
||||
padding: 0 20rpx;
|
||||
}
|
||||
|
||||
.caption_top_links {
|
||||
font-size: 20rpx;
|
||||
font-family: 'PingFang';
|
||||
font-weight: 500;
|
||||
color: #2D7CE6;
|
||||
}
|
||||
|
||||
.element.style {
|
||||
background-color: red;
|
||||
}
|
||||
|
||||
.u-list-item u-add-wrap {
|
||||
width: 62rpx !important;
|
||||
}
|
||||
|
||||
.caption_add {
|
||||
width: 93.1%;
|
||||
background: #2D7CE6;
|
||||
|
|
@ -660,21 +671,25 @@ page {
|
|||
color: #fff;
|
||||
margin-top: 40rpx;
|
||||
}
|
||||
|
||||
.caption_class {
|
||||
margin-top: 40rpx;
|
||||
}
|
||||
|
||||
.class_body {
|
||||
margin-top: 40rpx;
|
||||
|
||||
.caption_flex {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.caption_boder_text2 {
|
||||
font-size: 23rpx;
|
||||
font-weight: 500;
|
||||
color: #2D7CE6;
|
||||
}
|
||||
}
|
||||
|
||||
.caption_boder {
|
||||
position: relative;
|
||||
width: 96rpx;
|
||||
|
|
@ -683,6 +698,7 @@ page {
|
|||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
border: 2rpx solid #DDE2EE;
|
||||
margin-top: 17rpx;
|
||||
|
||||
.class_tp_image {
|
||||
position: absolute;
|
||||
top: 28rpx;
|
||||
|
|
|
|||
|
|
@ -1,10 +1,6 @@
|
|||
<template>
|
||||
<view class="pagebox">
|
||||
<u-navbar title="作业安排"
|
||||
:border-bottom="false"
|
||||
:background="bgc"
|
||||
title-color='#2E4975'
|
||||
title-size='36'
|
||||
<u-navbar title="作业安排" :border-bottom="false" :background="bgc" title-color='#2E4975' title-size='36'
|
||||
height='36'></u-navbar>
|
||||
<view class="serchbox">
|
||||
<view class="serchimg">
|
||||
|
|
@ -12,10 +8,8 @@
|
|||
|
||||
</image>
|
||||
</view>
|
||||
<input type="text"
|
||||
placeholder="搜索相关内容..."
|
||||
class="input"
|
||||
placeholder-style="color:#C7CDD3 ">
|
||||
<input type="text" v-model="searchKeyword" placeholder="搜索相关内容..." class="input"
|
||||
placeholder-style="color:#C7CDD3" @input="search()">
|
||||
</view>
|
||||
<view class="checkbox">
|
||||
<view class="chekcont">
|
||||
|
|
@ -39,10 +33,12 @@
|
|||
<view class="work_card_top_left_img">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/u07sCQb6mW6OSamVr1Va"></image>
|
||||
</view>
|
||||
{{item.name}}
|
||||
<view class="txt" v-html="highlightSearch(item.name)">
|
||||
|
||||
</view>
|
||||
<view class="work_card_top_right"
|
||||
:class="isalready == true ? 'act2' : ''">
|
||||
|
||||
</view>
|
||||
<view class="work_card_top_right" :class="isalready == true ? 'act2' : ''">
|
||||
进行中
|
||||
</view>
|
||||
</view>
|
||||
|
|
@ -52,16 +48,20 @@
|
|||
<view class="work_card_cont_text" v-if="items.classify==1||items.classify==2">
|
||||
{{items.paperName}}-{{items.testName}}
|
||||
</view>
|
||||
<view class="work_card_cont_tag" v-if="items.classify==1" style="background: rgba(27,225,178,0.1);color: #1BE1B2;">
|
||||
<view class="work_card_cont_tag" v-if="items.classify==1"
|
||||
style="background: rgba(27,225,178,0.1);color: #1BE1B2;">
|
||||
听力
|
||||
</view>
|
||||
<view class="work_card_cont_tag" v-if="items.classify==2" style="background: rgba(242,182,42,0.2);color: #F2AA02 ;">
|
||||
<view class="work_card_cont_tag" v-if="items.classify==2"
|
||||
style="background: rgba(242,182,42,0.2);color: #F2AA02 ;">
|
||||
阅读
|
||||
</view>
|
||||
<view class="work_card_cont_tag" v-if="items.classify==3" style="background:rgba(63,122,242,0.2);color: #3F7AF2 ;">
|
||||
<view class="work_card_cont_tag" v-if="items.classify==3"
|
||||
style="background:rgba(63,122,242,0.2);color: #3F7AF2 ;">
|
||||
写作
|
||||
</view>
|
||||
<view class="work_card_cont_tag" v-if="items.classify==4" style="background: rgba(242,63,235,0.1);color: #F23FEB ;">
|
||||
<view class="work_card_cont_tag" v-if="items.classify==4"
|
||||
style="background: rgba(242,63,235,0.1);color: #F23FEB ;">
|
||||
口语
|
||||
</view>
|
||||
|
||||
|
|
@ -116,14 +116,23 @@ export default {
|
|||
backgroundColor: "#F0F6FF",
|
||||
},
|
||||
isalready: true,
|
||||
work: [
|
||||
{ "iswork": "0" },
|
||||
{ "iswork": "1" },
|
||||
{ "iswork": "2" },
|
||||
{ "iswork": "0" }
|
||||
work: [{
|
||||
"iswork": "0"
|
||||
},
|
||||
{
|
||||
"iswork": "1"
|
||||
},
|
||||
{
|
||||
"iswork": "2"
|
||||
},
|
||||
{
|
||||
"iswork": "0"
|
||||
}
|
||||
],
|
||||
classid: 0,
|
||||
workinfo:[]
|
||||
workinfo: [],
|
||||
orgworkinfo: [],
|
||||
searchKeyword: '',
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
|
|
@ -133,6 +142,14 @@ export default {
|
|||
this.getworklist()
|
||||
},
|
||||
methods: {
|
||||
highlightSearch(name) {
|
||||
// 使用正则表达式替换匹配到的 searchKeyword 为带有颜色的文字
|
||||
if (this.searchKeyword) {
|
||||
const regex = new RegExp(this.searchKeyword, 'gi');
|
||||
return name.replace(regex, match => `<span style="color: #2D7CE6 ;">${match}</span>`);
|
||||
}
|
||||
return name;
|
||||
},
|
||||
formatTimestamp(timestamp) {
|
||||
const date = new Date(timestamp);
|
||||
const year = date.getFullYear();
|
||||
|
|
@ -150,12 +167,30 @@ export default {
|
|||
|
||||
if (res.code == 0) {
|
||||
this.workinfo = res.data
|
||||
this.orgworkinfo = JSON.parse(JSON.stringify(res.data));
|
||||
// this.classlist = res.data.list
|
||||
// this.isloding = false
|
||||
|
||||
}
|
||||
})
|
||||
},
|
||||
search() {
|
||||
// 根据关键字过滤 this.classlist
|
||||
if (this.searchKeyword !== '') {
|
||||
const filteredList = JSON.parse(JSON.stringify(this.orgworkinfo)).filter(item => {
|
||||
// 匹配 nickName 或者 id
|
||||
return item.name.includes(this.searchKeyword) || item.des.includes(this.searchKeyword);
|
||||
});
|
||||
// 更新 this.classlist 为过滤后的列表
|
||||
this.workinfo = filteredList;
|
||||
} else {
|
||||
this.fuwei();
|
||||
}
|
||||
},
|
||||
fuwei() {
|
||||
|
||||
this.workinfo = JSON.parse(JSON.stringify(this.orgworkinfo));
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
|
@ -269,6 +304,12 @@ page {
|
|||
width: 38rpx;
|
||||
height: 32rpx;
|
||||
}
|
||||
.txt{
|
||||
font-size: 28rpx;
|
||||
font-family: 'PingFang', 'PingFang';
|
||||
font-weight: 800;
|
||||
color: #2E4975;
|
||||
}
|
||||
}
|
||||
|
||||
.work_card_top_right {
|
||||
|
|
@ -334,6 +375,7 @@ page {
|
|||
flex-wrap: wrap;
|
||||
margin-top: 22rpx;
|
||||
width: 100%;
|
||||
|
||||
.work_card_info_top {
|
||||
display: flex;
|
||||
flex-wrap: nowrap;
|
||||
|
|
@ -369,6 +411,7 @@ page {
|
|||
border-left: 8rpx solid #DFDFDF;
|
||||
}
|
||||
}
|
||||
|
||||
.botbtn {
|
||||
padding: 32rpx 32rpx 0 32rpx;
|
||||
margin-left: -32rpx;
|
||||
|
|
@ -379,6 +422,7 @@ page {
|
|||
background: #FFFFFF;
|
||||
box-shadow: 0rpx -10rpx 16rpx 0rpx rgba(202, 202, 202, 0.25);
|
||||
border-radius: 40rpx 40rpx 0rpx 0rpx;
|
||||
|
||||
.btn {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
|
@ -393,4 +437,5 @@ page {
|
|||
border-radius: 104rpx 104rpx 104rpx 104rpx;
|
||||
}
|
||||
}
|
||||
}</style>
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,14 +1,9 @@
|
|||
<template>
|
||||
<view class="view_body">
|
||||
<u-navbar :is-back="false"
|
||||
title='班级'
|
||||
title-color="#2E4975"
|
||||
:border-bottom="false"
|
||||
:background="bgc"
|
||||
<u-navbar :is-back="false" title='班级' title-color="#2E4975" :border-bottom="false" :background="bgc"
|
||||
id="navbar">
|
||||
</u-navbar>
|
||||
<view class="nocont"
|
||||
v-show="shownocont">
|
||||
<view class="nocont" v-show="shownocont">
|
||||
<view class="nocont_tip">
|
||||
<view class="nocont_tip_img">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/uVcz1RzZi6US2NKa0ssl"></image>
|
||||
|
|
@ -22,8 +17,7 @@
|
|||
|
||||
</view>
|
||||
|
||||
<view class="student_page"
|
||||
v-show="shownocont == false">
|
||||
<view class="student_page" v-show="shownocont == false">
|
||||
<view class="student_page_top">
|
||||
<view class="search_box">
|
||||
<view class="check_search">
|
||||
|
|
@ -37,17 +31,12 @@
|
|||
|
||||
</image>
|
||||
</view>
|
||||
<input type="text"
|
||||
v-model="searchKeyword"
|
||||
placeholder="搜索相关内容..."
|
||||
class="input"
|
||||
placeholder-style="color:#C7CDD3"
|
||||
@input="search()">
|
||||
<input type="text" v-model="searchKeyword" placeholder="搜索相关内容..." class="input"
|
||||
placeholder-style="color:#C7CDD3" @input="search()">
|
||||
</view>
|
||||
</view>
|
||||
<view class="info_box">
|
||||
<view class="info_cont"
|
||||
style="width:80rpx ;">
|
||||
<view class="info_cont" style="width:80rpx ;">
|
||||
<view class="info_cont_top">
|
||||
学生人数
|
||||
</view>
|
||||
|
|
@ -73,40 +62,31 @@
|
|||
</view>
|
||||
</view>
|
||||
<view class="chekbox">
|
||||
<view class="check"
|
||||
:class="checkindex == 1 ? 'act1' : ''"
|
||||
@click="checkindex = 1">
|
||||
<view class="check" :class="checkindex == 1 ? 'act1' : ''" @click="checkindex = 1">
|
||||
班级
|
||||
</view>
|
||||
<view class="check"
|
||||
:class="checkindex == 0 ? 'act1' : ''"
|
||||
@click="checkindex = 0">
|
||||
<view class="check" :class="checkindex == 0 ? 'act1' : ''" @click="checkindex = 0">
|
||||
学生
|
||||
</view>
|
||||
|
||||
<view class="add">
|
||||
<view class="add" @click="addsmt()">
|
||||
+ 添加
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view class="class_box"
|
||||
v-if="checkindex == 1">
|
||||
<view class="class_box" v-if="checkindex == 1">
|
||||
<view class="class_box_top">
|
||||
|
||||
<view @click="changeclass()"
|
||||
class="class_box_top_cont">
|
||||
<view @click="changeclass()" class="class_box_top_cont">
|
||||
班级人数
|
||||
<view class="iconfont icon-arow_down"></view>
|
||||
<view class="dropdown_box"
|
||||
v-show="classnum">
|
||||
<view class="dropdown_item"
|
||||
:class="classnumindex == 0 ? 'act2' : ''"
|
||||
<view class="dropdown_box" v-show="classnum">
|
||||
<view class="dropdown_item" :class="classnumindex == 0 ? 'act2' : ''"
|
||||
@click="chengclassnumindex(0)">
|
||||
降序
|
||||
</view>
|
||||
<view class="dropdown_item"
|
||||
:class="classnumindex == 1 ? 'act2' : ''"
|
||||
<view class="dropdown_item" :class="classnumindex == 1 ? 'act2' : ''"
|
||||
@click="chengclassnumindex(1)">
|
||||
升序
|
||||
</view>
|
||||
|
|
@ -114,29 +94,23 @@
|
|||
</view>
|
||||
</view>
|
||||
|
||||
<view @click="changetext()"
|
||||
class="class_box_top_cont">
|
||||
<view @click="changetext()" class="class_box_top_cont">
|
||||
标签文字
|
||||
<view class="iconfont icon-arow_down"></view>
|
||||
<view class="dropdown_box"
|
||||
v-show="showtext">
|
||||
<view class="dropdown_item"
|
||||
:class="textindex == 1 ? 'act2' : ''"
|
||||
<view class="dropdown_box" v-show="showtext">
|
||||
<view class="dropdown_item" :class="textindex == 1 ? 'act2' : ''"
|
||||
@click="chengetextindex(1)">
|
||||
听力
|
||||
</view>
|
||||
<view class="dropdown_item"
|
||||
:class="textindex == 2 ? 'act2' : ''"
|
||||
<view class="dropdown_item" :class="textindex == 2 ? 'act2' : ''"
|
||||
@click="chengetextindex(2)">
|
||||
阅读
|
||||
</view>
|
||||
<view class="dropdown_item"
|
||||
:class="textindex == 3 ? 'act2' : ''"
|
||||
<view class="dropdown_item" :class="textindex == 3 ? 'act2' : ''"
|
||||
@click="chengetextindex(3)">
|
||||
写作
|
||||
</view>
|
||||
<view class="dropdown_item"
|
||||
:class="textindex == 4 ? 'act2' : ''"
|
||||
<view class="dropdown_item" :class="textindex == 4 ? 'act2' : ''"
|
||||
@click="chengetextindex(4)">
|
||||
口语
|
||||
</view>
|
||||
|
|
@ -151,10 +125,8 @@
|
|||
|
||||
</view>
|
||||
|
||||
<view class="class_card"
|
||||
v-for="(item, index) in classlist"
|
||||
v-if="isloding == false"
|
||||
:key="index" @click="toclassdetal(item)">
|
||||
<view class="class_card" v-for="(item, index) in classlist" v-if="isloding == false" :key="index"
|
||||
@click="toclassdetal(item)">
|
||||
<view class="class_card_top">
|
||||
<view class="class_card_left">
|
||||
<image src=" https://file.langsi.online/yasiimg/web/static/udWNTRG6GulmTtgPRQ49"></image>
|
||||
|
|
@ -163,27 +135,22 @@
|
|||
<view class="class_card_right_top" v-html="highlightSearch(item.name)">
|
||||
<!-- {{ item.name }} -->
|
||||
</view>
|
||||
<view class="class_card_right_bot"
|
||||
v-show="item.classify == 1">
|
||||
<view class="class_card_right_bot" v-show="item.classify == 1">
|
||||
听力
|
||||
</view>
|
||||
<view class="class_card_right_bot"
|
||||
v-show="item.classify == 2">
|
||||
<view class="class_card_right_bot" v-show="item.classify == 2">
|
||||
阅读
|
||||
</view>
|
||||
<view class="class_card_right_bot"
|
||||
v-show="item.classify == 3">
|
||||
<view class="class_card_right_bot" v-show="item.classify == 3">
|
||||
写作
|
||||
</view>
|
||||
<view class="class_card_right_bot"
|
||||
v-show="item.classify == 4">
|
||||
<view class="class_card_right_bot" v-show="item.classify == 4">
|
||||
口语
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="class_infobox">
|
||||
<view class="class_info"
|
||||
style="width:80rpx ;">
|
||||
<view class="class_info" style="width:80rpx ;">
|
||||
<view class="class_info_top">
|
||||
班级人数
|
||||
</view>
|
||||
|
|
@ -215,10 +182,8 @@
|
|||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="overlay"
|
||||
v-if="false">
|
||||
<view class="addstudent"
|
||||
v-show="false">
|
||||
<view class="overlay" v-if="false">
|
||||
<view class="addstudent" v-show="false">
|
||||
|
||||
<view class="close">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/uSzPsPoFgoVwcsl7pJ89"></image>
|
||||
|
|
@ -232,9 +197,7 @@
|
|||
学员名称
|
||||
</view>
|
||||
<view class="addstudent_input">
|
||||
<input type="text"
|
||||
placeholder="搜索相关内容..."
|
||||
class="input"
|
||||
<input type="text" placeholder="搜索相关内容..." class="input"
|
||||
placeholder-style="color:#C7CDD3;font-size: 24rpx; ">
|
||||
</view>
|
||||
</view>
|
||||
|
|
@ -243,9 +206,7 @@
|
|||
学员ID
|
||||
</view>
|
||||
<view class="addstudent_input">
|
||||
<input type="text"
|
||||
placeholder="搜索相关内容..."
|
||||
class="input"
|
||||
<input type="text" placeholder="搜索相关内容..." class="input"
|
||||
placeholder-style="color:#C7CDD3;font-size: 24rpx; ">
|
||||
</view>
|
||||
</view>
|
||||
|
|
@ -253,8 +214,7 @@
|
|||
添加
|
||||
</view>
|
||||
</view>
|
||||
<view class="addtip"
|
||||
v-show="false">
|
||||
<view class="addtip" v-show="false">
|
||||
<view class="logo">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/uxsaoHOpSUoxnX7lU3Fe"></image>
|
||||
</view>
|
||||
|
|
@ -265,6 +225,113 @@
|
|||
</view>
|
||||
</view>
|
||||
<indexlist v-show="checkindex == 0" />
|
||||
<u-popup v-model="show" mode="bottom" length="75%" :safe-area-inset-bottom='true' :closeable="true"
|
||||
:duration="300" border-radius="25">
|
||||
<view class="pop-up">
|
||||
<view class="caption">创建班级</view>
|
||||
<!-- 班级图像 -->
|
||||
<view style="margin-top: 16rpx;">
|
||||
<view class="caption_top">班级头像</view>
|
||||
<view
|
||||
style="width: 112rpx; height: 112rpx; position: relative;border: 2rpx solid #DDE2EE;border-radius: 50%;"
|
||||
@click="btn()">
|
||||
<view class="imgbox" style="width: 112rpx; height: 112rpx;border-radius: 50%;">
|
||||
<image :src="imgurl" mode="" style="width: 112rpx; height: 112rpx;border-radius: 50%;">
|
||||
</image>
|
||||
</view>
|
||||
|
||||
<view class="dashboard">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/u03pE8b1O2DykSYUg2mp" mode="">
|
||||
</image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 班级名称 -->
|
||||
<view>
|
||||
<view class="caption_top">班级名称</view>
|
||||
<view class="caption_input">
|
||||
<u-input v-model="designation" :type="type" :border="border" placeholder="请输入班级名称" />
|
||||
</view>
|
||||
</view>
|
||||
<!-- 班级标签 -->
|
||||
<view>
|
||||
<view class="caption_top">班级标签</view>
|
||||
<!-- 弹出层 -->
|
||||
<u-select v-model="show2" :list="list" @confirm="confirm"></u-select>
|
||||
|
||||
<view class="caption_input">
|
||||
<u-input v-model="form.name" @click="showPopup" placeholder="请输入班级标签" />
|
||||
</view>
|
||||
|
||||
|
||||
|
||||
|
||||
</view>
|
||||
<!-- 班级学生 -->
|
||||
<view class="class_body">
|
||||
<view class="caption_flex">
|
||||
<view>班级学生</view>
|
||||
<view class="caption_boder_text2">点击头像选择班级学员</view>
|
||||
</view>
|
||||
<view class="select_box" style="display: flex;flex-wrap: wrap;">
|
||||
<view class="class_ys" v-for="(item, index) in stuinfo" :key="index"
|
||||
style="position: relative;">
|
||||
<view class="close"
|
||||
style="position: absolute;top: 0rpx;right: 8rpx;width: 20rpx;height: 20rpx;"
|
||||
@click="delstu(item.id)">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/ueH3qwYazyVXmiYoVPJE" mode="">
|
||||
</image>
|
||||
</view>
|
||||
<view class="class_tp">
|
||||
<image :src="item.avatar" mode=""
|
||||
style="width: 56rpx;height: 56rpx;border-radius: 50%;"></image>
|
||||
</view>
|
||||
<view class="class_wz">{{ item.name }}</view>
|
||||
</view>
|
||||
<view class="caption_boder" @click="toaddstu()">
|
||||
|
||||
<view class="class_tp_image" >
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/utw2UbXetgo1FDQpvGKq" mode="">
|
||||
</image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<!-- 班级老师 -->
|
||||
<view class="class_body">
|
||||
<view class="caption_flex">
|
||||
<view>班级老师</view>
|
||||
<view class="caption_boder_text2">点击加号选择班级老师</view>
|
||||
</view>
|
||||
<view class="select_box" style="display: flex;flex-wrap: wrap;">
|
||||
<view class="class_ys" v-for="(item, index) in teacherinfo" :key="index"
|
||||
style="position: relative;">
|
||||
<view class="close"
|
||||
style="position: absolute;top: 0rpx;right: 8rpx;width: 20rpx;height: 20rpx;"
|
||||
@click="delstu(item.id)">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/ueH3qwYazyVXmiYoVPJE" mode="">
|
||||
</image>
|
||||
</view>
|
||||
<view class="class_tp">
|
||||
<image :src="item.avatar" mode=""
|
||||
style="width: 56rpx;height: 56rpx;border-radius: 50%;"></image>
|
||||
</view>
|
||||
<view class="class_wz">{{ item.name }}</view>
|
||||
</view>
|
||||
<view class="caption_boder" @click="addteacher()">
|
||||
|
||||
<view class="class_tp_image" >
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/utw2UbXetgo1FDQpvGKq" mode="">
|
||||
</image>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view class="caption_add" @click="addclass()">添加</view>
|
||||
</view>
|
||||
</u-popup>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
|
@ -293,13 +360,233 @@ export default {
|
|||
totalLastNum: '',
|
||||
totalAvgScore: '',
|
||||
totalWorkCompletionDegre: 0,
|
||||
// 班级名称数据绑定
|
||||
designation: '',
|
||||
// 班级标签数据绑定
|
||||
labels: '',
|
||||
// 弹出层的变量
|
||||
show: false,
|
||||
// 下拉框
|
||||
show2: false,
|
||||
form:{
|
||||
name: '',
|
||||
},
|
||||
|
||||
list: [{
|
||||
value: '1',
|
||||
label: '听力'
|
||||
},
|
||||
{
|
||||
value: '2',
|
||||
label: '阅读'
|
||||
},
|
||||
{
|
||||
value: '3',
|
||||
label: '写作'
|
||||
},
|
||||
{
|
||||
value: '4',
|
||||
label: '口语'
|
||||
}
|
||||
],
|
||||
icons: 'arrow-down-fill',
|
||||
icons_rigth: 'arrow-down-fill',
|
||||
icons_top: 'arrow-up-fill',
|
||||
imgurl: "",
|
||||
token: '',
|
||||
userImgs: '',
|
||||
teacherinfo: [],
|
||||
stuinfo: [],
|
||||
}
|
||||
},
|
||||
onLoad(option) {
|
||||
this.getclassList()
|
||||
uni.removeStorageSync('selectedteacherinfo');
|
||||
uni.removeStorageSync('selectedStuInfo');
|
||||
},
|
||||
onShow() {
|
||||
const selectedteacherinfo = uni.getStorageSync('selectedteacherinfo');
|
||||
|
||||
if (selectedteacherinfo && selectedteacherinfo.length > 0) {
|
||||
this.teacherinfo = selectedteacherinfo
|
||||
// Remove duplicates from this.classinfo
|
||||
// this.classinfo = this.classinfo.filter(item => !selectedClassInfo.some(selectedItem => selectedItem.id === item.id));
|
||||
|
||||
// // Add non-duplicate items from selectedClassInfo to this.classinfo
|
||||
// this.classinfo = this.classinfo.concat(selectedClassInfo);
|
||||
|
||||
}
|
||||
const selectedstuInfo = uni.getStorageSync('selectedStuInfo');
|
||||
|
||||
if (selectedstuInfo && selectedstuInfo.length > 0) {
|
||||
this.stuinfo = selectedstuInfo
|
||||
// Remove duplicates from this.classinfo
|
||||
// this.stuinfo = this.stuinfo.filter(item => !selectedstuInfo.some(selectedItem => selectedItem.id === item.id));
|
||||
|
||||
// // Add non-duplicate items from selectedClassInfo to this.classinfo
|
||||
// this.stuinfo = this.stuinfo.concat(selectedstuInfo);
|
||||
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
addclass(){
|
||||
|
||||
let memberIds =[]
|
||||
let teacherIds =[]
|
||||
this.stuinfo.forEach(item => {
|
||||
memberIds.push(item.id); // 将 id 添加到数组中
|
||||
});
|
||||
this.teacherinfo.forEach(item => {
|
||||
teacherIds.push(item.id); // 将 id 添加到数组中
|
||||
});
|
||||
let classif =''
|
||||
if(this.form.name=='听力'){
|
||||
classif=1
|
||||
}else if(this.form.name=='阅读'){
|
||||
classif=2
|
||||
}else if(this.form.name=='写作'){
|
||||
classif=3
|
||||
}else if(this.form.name=='口语'){
|
||||
classif=4
|
||||
}
|
||||
let data ={
|
||||
name:this.designation,
|
||||
avatar:this.imgurl,
|
||||
classify:classif,
|
||||
memberIds:memberIds,
|
||||
teacherIds:teacherIds
|
||||
|
||||
}
|
||||
this.$u.post(`https://api.admin-v2.langsi.online/admin-api/classroom/create`, data).then(res => {
|
||||
if (res.code === 0) {
|
||||
this.$refs.uToast.show({
|
||||
title: '添加成功',
|
||||
type: 'success',
|
||||
position:'top'
|
||||
})
|
||||
uni.removeStorageSync('selectedteacherinfo');
|
||||
uni.removeStorageSync('selectedStuInfo');
|
||||
this.getclassList()
|
||||
this.stuinfo=[]
|
||||
this.teacherinfo=[]
|
||||
this.designation=''
|
||||
this.form.name=''
|
||||
this.imgurl=''
|
||||
this.show=false
|
||||
}else{
|
||||
this.$refs.uToast.show({
|
||||
title: '添加失败',
|
||||
type: 'error',
|
||||
position:'top'
|
||||
|
||||
})
|
||||
|
||||
}
|
||||
});
|
||||
console.log(data,'data');
|
||||
},
|
||||
delcls(id) {
|
||||
this.teacherinfo = this.teacherinfo.filter(item => item.id !== id);
|
||||
},
|
||||
delstu(id) {
|
||||
this.stuinfo = this.stuinfo.filter(item => item.id !== id);
|
||||
},
|
||||
toaddstu() {
|
||||
uni.navigateTo({
|
||||
url: "/pages_teacher/pages_add/add_studentsforwork?stuinfo=" + encodeURIComponent(JSON
|
||||
.stringify(this.stuinfo))
|
||||
|
||||
}).then(res => {
|
||||
|
||||
}).catch(err => {
|
||||
|
||||
});
|
||||
},
|
||||
addteacher() {
|
||||
uni.navigateTo({
|
||||
url: "/pages/Mystudent/addTeacher?teacherinfo=" + encodeURIComponent(JSON.stringify(this.teacherinfo))
|
||||
}).then(res => {
|
||||
|
||||
}).catch(err => {
|
||||
|
||||
});
|
||||
},
|
||||
getQiniuToken() {
|
||||
wx.request({
|
||||
url: 'https://v2.ielts.langsi.online/file/getToken',
|
||||
method: 'get', // Adjust the request method as needed
|
||||
// data: yourData,
|
||||
header: {
|
||||
'Authorization': 'eyJhbGciOiJIUzUxMiJ9.eyJub3RfeWJzX3VzZXJfa2V5IjoiNWZiYzA4YmUtNDZlMi00NDUzLThmYjQtMjFlNzhjZDIxY2EyIn0.jw2fyMnlNEW-zx8cH6aPh_H-WqEAHDQdh4oCpYg3qBIJZEmw6L4oNWJPvKHM9edmRdLO0p2z7_vlCYoY00NqxA '
|
||||
},
|
||||
success: (res) => {
|
||||
console.log(res);
|
||||
this.token = res.data.data.token
|
||||
},
|
||||
fail: (err) => {
|
||||
console.log(err);
|
||||
}
|
||||
});
|
||||
// this.$u.get('https://v2.ielts.langsi.online/file/getToken').then(res => {
|
||||
// console.log(res.data);
|
||||
// this.token = res.data.token
|
||||
// }).catch(err => {
|
||||
// console.log(err)
|
||||
// })
|
||||
|
||||
},
|
||||
btn() {
|
||||
this.getQiniuToken()
|
||||
let _this = this
|
||||
let math = 'static/' + _this.$u.guid(20)
|
||||
uni.chooseImage({
|
||||
success: (chooseImageRes) => {
|
||||
let tempFilePaths = chooseImageRes.tempFilePaths;
|
||||
console.log(tempFilePaths)
|
||||
tempFilePaths.forEach(item => {
|
||||
// 上传图片到七牛云
|
||||
wx.uploadFile({
|
||||
url: 'https://upload-cn-east-2.qiniup.com',
|
||||
name: 'file',
|
||||
filePath: item,
|
||||
formData: {
|
||||
token: _this.token, //后端返回的token
|
||||
key: 'yasiimg/header/' + math
|
||||
},
|
||||
success: function(res) {
|
||||
|
||||
let str = JSON.parse(res.data)
|
||||
// console.log(str.key)
|
||||
_this.userImgs = 'https://file.langsi.online/' + str
|
||||
.key
|
||||
console.log(_this.userImgs)
|
||||
_this.imgurl = _this.userImgs
|
||||
}
|
||||
});
|
||||
})
|
||||
|
||||
|
||||
}
|
||||
});
|
||||
},
|
||||
addsmt() {
|
||||
if (this.checkindex == 1) {
|
||||
this.create()
|
||||
}
|
||||
},
|
||||
create() {
|
||||
this.show = !this.show
|
||||
},
|
||||
showPopup() {
|
||||
this.show2 = !this.show2
|
||||
this.icons = this.icons_top
|
||||
},
|
||||
confirm(e) {
|
||||
this.icons = this.icons_rigth
|
||||
e.forEach(item => {
|
||||
this.form.name = item.label
|
||||
})
|
||||
},
|
||||
highlightSearch(name) {
|
||||
// 使用正则表达式替换匹配到的 searchKeyword 为带有颜色的文字
|
||||
if (this.searchKeyword) {
|
||||
|
|
@ -321,7 +608,8 @@ export default {
|
|||
search() {
|
||||
// 根据关键字过滤 this.classlist
|
||||
if (this.searchKeyword != '') {
|
||||
const filteredList = JSON.parse(JSON.stringify(this.changeclasslist)).filter(item => item.name.includes(this.searchKeyword));
|
||||
const filteredList = JSON.parse(JSON.stringify(this.changeclasslist)).filter(item => item.name
|
||||
.includes(this.searchKeyword));
|
||||
// 更新 this.classlist 为过滤后的列表
|
||||
this.classlist = filteredList;
|
||||
} else {
|
||||
|
|
@ -408,7 +696,8 @@ export default {
|
|||
const totalMembersSum = list.reduce((sum, item) => sum + item.totalMembers, 0);
|
||||
|
||||
// 计算 workCompletionDegree 平均值
|
||||
const workCompletionDegreeAvg = list.reduce((sum, item) => sum + item.workCompletionDegree, 0) / list.length;
|
||||
const workCompletionDegreeAvg = list.reduce((sum, item) => sum + item
|
||||
.workCompletionDegree, 0) / list.length;
|
||||
|
||||
// 计算 avgScore 平均值
|
||||
const avgScoreAvg = list.reduce((sum, item) => sum + item.avgScore, 0) / list.length;
|
||||
|
|
@ -920,4 +1209,157 @@ export default {
|
|||
}
|
||||
}
|
||||
}
|
||||
}</style>
|
||||
|
||||
.pop-up {
|
||||
padding: 30rpx 32rpx;
|
||||
border-radius: 20rpx 20rpx 0rpx 0rpx;
|
||||
|
||||
.caption {
|
||||
font-size: 36rpx;
|
||||
text-align: center;
|
||||
font-weight: 800;
|
||||
color: #2E4975;
|
||||
padding-top: 20rpx;
|
||||
}
|
||||
|
||||
.caption_top {
|
||||
font-size: 28rpx;
|
||||
font-family: 'PingFang';
|
||||
color: #2E4975;
|
||||
margin-top: 40rpx;
|
||||
|
||||
.imgbox {
|
||||
width: 112rpx;
|
||||
height: 112rpx;
|
||||
border: 2rpx solid #DDE2EE;
|
||||
border-radius: 50%;
|
||||
}
|
||||
}
|
||||
|
||||
.dashboard {
|
||||
position: absolute;
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
bottom: 0;
|
||||
right: 0;
|
||||
}
|
||||
|
||||
.caption_input {
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
border: 2rpx solid #DDE2EE;
|
||||
margin-top: 16rpx;
|
||||
padding: 0 20rpx;
|
||||
}
|
||||
|
||||
.caption_top_links {
|
||||
font-size: 20rpx;
|
||||
font-family: 'PingFang';
|
||||
font-weight: 500;
|
||||
color: #2D7CE6;
|
||||
}
|
||||
|
||||
.element.style {
|
||||
background-color: red;
|
||||
}
|
||||
|
||||
.u-list-item u-add-wrap {
|
||||
width: 62rpx !important;
|
||||
}
|
||||
|
||||
.caption_add {
|
||||
width: 93.1%;
|
||||
background: #2D7CE6;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
text-align: center;
|
||||
margin: 0 auto;
|
||||
padding: 24rpx 0;
|
||||
color: #fff;
|
||||
margin-top: 40rpx;
|
||||
}
|
||||
|
||||
.caption_class {
|
||||
margin-top: 40rpx;
|
||||
}
|
||||
|
||||
.class_body {
|
||||
margin-top: 40rpx;
|
||||
|
||||
.caption_flex {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.caption_boder_text2 {
|
||||
font-size: 23rpx;
|
||||
font-weight: 500;
|
||||
color: #2D7CE6;
|
||||
}
|
||||
}
|
||||
|
||||
.select_box {
|
||||
.class_ys:nth-child(3n) {
|
||||
margin-right: 0;
|
||||
}
|
||||
|
||||
.class_ys {
|
||||
margin-top: 20rpx;
|
||||
margin-right: 20rpx;
|
||||
width: 215rpx;
|
||||
height: 96rpx;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
padding: 20rpx;
|
||||
// width: 215rpx;
|
||||
height: 96rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
border: 2rpx solid #F0F0F0;
|
||||
|
||||
.class_tp {
|
||||
width: 56rpx;
|
||||
height: 56rpx;
|
||||
margin-right: 12rpx;
|
||||
}
|
||||
|
||||
.class_wz {
|
||||
width: 125rpx;
|
||||
font-size: 28rpx;
|
||||
font-family: 'PingFang';
|
||||
font-weight: 500;
|
||||
color: #072F5A;
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.caption_boder {
|
||||
position: relative;
|
||||
width: 96rpx;
|
||||
height: 96rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
border: 2rpx solid #DDE2EE;
|
||||
margin-top: 17rpx;
|
||||
|
||||
.class_tp_image {
|
||||
position: absolute;
|
||||
top: 28rpx;
|
||||
right: 32rpx;
|
||||
bottom: 0;
|
||||
width:
|
||||
28rpx;
|
||||
height:
|
||||
28rpx;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
|
@ -1,38 +0,0 @@
|
|||
<template>
|
||||
<view class="view_body">
|
||||
<u-navbar :is-back="false" title='学生' title-color="#000" :border-bottom="false" :background="true"
|
||||
id="navbar">
|
||||
</u-navbar>
|
||||
<view class="nostudy">
|
||||
<view>
|
||||
<image src="http://tmp/HR4A5dtvNboB4502c7be9965e9ff4c184685e3fb36d9.png" mode=""></image>
|
||||
<text>暂无学生,快去添加吧!</text>
|
||||
</view>
|
||||
<view>
|
||||
<u-button type="primary">主要按钮</u-button>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.view_body{
|
||||
height: 1624rpx;
|
||||
background: linear-gradient(180deg, #E1EEFF 0%, #FFFFFF 100%);
|
||||
}
|
||||
|
||||
</style>
|
||||
|
|
@ -1,55 +1,468 @@
|
|||
<template>
|
||||
<view class="content">
|
||||
<u-navbar title="雅思口语" :is-back="false" title-color="#ffffff" :border-bottom="false"
|
||||
id="navbar">
|
||||
<!-- 头部代码 -->
|
||||
<view class="view_by">
|
||||
<view>
|
||||
<u-navbar :is-back="false" title='首页' title-color="#000" :border-bottom="false" :background="true" id="navbar">
|
||||
</u-navbar>
|
||||
<image class="logo" src="/static/logo.png"></image>
|
||||
<view class="text-area">
|
||||
<text class="title">{{title}}</text>
|
||||
<view class="header_button">
|
||||
<u-button type="primary" shape="circle" :hair-line="false" class="custom-style">学生</u-button>
|
||||
<u-button class="custom-style" shape="circle" :hair-line="false">班级</u-button>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 登录之后显示的页面 -->
|
||||
<view v-if="flag">
|
||||
<view class="view_body">
|
||||
<view class="content_box">
|
||||
<view class="view_text">32</view>
|
||||
<view>已完成人数(人)</view>
|
||||
</view>
|
||||
<view class="content_box">
|
||||
<view class="view_text">90%</view>
|
||||
<view>已完成作业正确率</view>
|
||||
</view>
|
||||
</view>
|
||||
<!-- 作业完成情况 -->
|
||||
<view class="echarts_bar">
|
||||
<view>
|
||||
<text>作业完成情况</text>
|
||||
<view class="echarts_text">
|
||||
<view>本周</view>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="echarts">
|
||||
<l-echart ref="chart" @finished="initChart"></l-echart>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
<!-- 没有数据显示的页面 -->
|
||||
<view>
|
||||
<view class="deer">
|
||||
<view class="deer_images">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/udGRdnpSfgV3LMD8Ksuv" mode=""></image>
|
||||
</view>
|
||||
<view class="deer_right">
|
||||
<view class="deer_text">当前暂无学习数据,快去布置作业吧!</view>
|
||||
<view class="deer_button">
|
||||
<view>去安排</view>
|
||||
<view class="r_image"><image src="https://file.langsi.online/yasiimg/web/static/uITFZ6vUIiA0P2KBz1i8" mode=""></image></view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<view class="echarts_bar">
|
||||
<view>
|
||||
<text>作业完成情况</text>
|
||||
<view class="echarts_text">
|
||||
<view>本周</view>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<view class="echarts">
|
||||
<l-echart ref="chart" @finished="initChart"></l-echart>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</view>
|
||||
<!-- 底部区域 -->
|
||||
<view v-if="flag">
|
||||
<view class="date">
|
||||
8月31日
|
||||
</view>
|
||||
|
||||
<view class="box_rate">
|
||||
<view class="rate_item">
|
||||
<view class="number">
|
||||
21
|
||||
</view>
|
||||
<view class="text">
|
||||
完成人数
|
||||
</view>
|
||||
</view>
|
||||
<view class="rate_item">
|
||||
<view class="number">
|
||||
6
|
||||
</view>
|
||||
<view class="text">
|
||||
平均成绩/分
|
||||
</view>
|
||||
</view>
|
||||
<view class="rate_item">
|
||||
<view class="number">
|
||||
80%
|
||||
</view>
|
||||
<view class="text">
|
||||
作业正确率
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
<view>
|
||||
<view class="view_botton">
|
||||
<view class="view_spoken">
|
||||
<view>
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/u80EhqyvMfcOaaSyK09X" mode=""></image>
|
||||
</view>
|
||||
<view class="view_span">
|
||||
<text>口语单科模考</text>
|
||||
<text>李斯丹妮</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="view_text2">
|
||||
<view>正确率<text class="text2">80%</text></view>
|
||||
<text>2023/02/23 12:00</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="view_botton">
|
||||
<view class="view_spoken">
|
||||
<view>
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/u80EhqyvMfcOaaSyK09X" mode=""></image>
|
||||
</view>
|
||||
<view class="view_span">
|
||||
<text>口语单科模考</text>
|
||||
<text>李斯丹妮</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="view_text2">
|
||||
<view>正确率<text class="text2">80%</text></view>
|
||||
<text>2023/02/23 12:00</text>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
<!--底部导航栏 -->
|
||||
</view>
|
||||
<!-- 没有数据显示的区域 -->
|
||||
<view class="zu_footer">
|
||||
|
||||
<view class="date">8月31日</view>
|
||||
<view class="zu_zp">
|
||||
<view class="zu_image"><image src="https://file.langsi.online/yasiimg/web/static/uFgs4acAUC68weaKB9Yi" mode=""></image></view>
|
||||
<view class="zu_text">暂无学习记录,快去安排作业吧!</view>
|
||||
</view>
|
||||
|
||||
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import * as echarts from '@/uni_modules/lime-echart/static/echarts.min'
|
||||
import LEchart from '@/uni_modules/lime-echart/components/l-echart/l-echart.vue';
|
||||
export default {
|
||||
components: {
|
||||
LEchart
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
title: 'Hello'
|
||||
flag:false
|
||||
}
|
||||
},
|
||||
onLoad() {
|
||||
|
||||
},
|
||||
methods: {
|
||||
async initChart() {
|
||||
let _this = this
|
||||
|
||||
const option = {
|
||||
xAxis: {
|
||||
type: 'category',
|
||||
data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
|
||||
},
|
||||
yAxis: {
|
||||
type: 'value',
|
||||
boundaryGap: ['10%', '20%',]
|
||||
},
|
||||
series: [{
|
||||
data: [120, 200, 150, 80, 70, 110, 130],
|
||||
type: 'bar'
|
||||
}]
|
||||
}
|
||||
|
||||
const chart = await this.$refs.chart.init(echarts);
|
||||
chart.setOption(option)
|
||||
//return chart
|
||||
},
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.content {
|
||||
<style lang="scss" scoped>
|
||||
.view_by {
|
||||
background: linear-gradient(180deg, #E1EEFF 0%, #FFFFFF 100%);
|
||||
padding: 32rpx;
|
||||
|
||||
|
||||
.header_button {
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
align-items: center;
|
||||
|
||||
|
||||
.custom-style {
|
||||
width: 180rpx;
|
||||
height: 72rpx;
|
||||
|
||||
|
||||
}
|
||||
|
||||
.active {
|
||||
background: #2D7CE6;
|
||||
color: #fff;
|
||||
box-shadow: inset 0rpx 8rpx 16rpx 0rpx rgba(255, 255, 255, 0.35);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
.view_body {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin-top: 52rpx;
|
||||
|
||||
.content_box {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
|
||||
|
||||
.content_box:first-child {
|
||||
|
||||
border-right: 2rpx solid rgba(0, 0, 0, 0.11);
|
||||
}
|
||||
|
||||
.view_text {
|
||||
font-size: 76rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 500;
|
||||
color: #2E4975;
|
||||
|
||||
|
||||
}
|
||||
|
||||
view {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
|
||||
}
|
||||
|
||||
.logo {
|
||||
height: 200rpx;
|
||||
width: 200rpx;
|
||||
margin-top: 200rpx;
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
margin-bottom: 50rpx;
|
||||
}
|
||||
|
||||
.text-area {
|
||||
.echarts_bar {
|
||||
width: 686rpx;
|
||||
height: 459rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
opacity: 1;
|
||||
margin-top: 32rpx;
|
||||
padding: 32rpx;
|
||||
|
||||
view {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
|
||||
text {
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 800;
|
||||
color: #2E4975;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
.box_rate {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
padding: 30rpx;
|
||||
background: linear-gradient(179deg, rgba(255, 237, 223, 0.65) 0%, #FFFFFF 100%);
|
||||
border-radius: 18rpx 18rpx 18rpx 18rpx;
|
||||
|
||||
.rate_item {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
}
|
||||
|
||||
.number {
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 800;
|
||||
color: #2D7CE6;
|
||||
}
|
||||
|
||||
.text {
|
||||
font-size: 20rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 500;
|
||||
color: rgba(7, 47, 90, 0.5);
|
||||
}
|
||||
}
|
||||
|
||||
.date {
|
||||
font-size: 24rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 800;
|
||||
color: #2E4975;
|
||||
padding: 30rpx;
|
||||
}
|
||||
|
||||
.view_botton {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
height: 124rpx;
|
||||
background: #fff;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
margin: 20rpx 0rpx;
|
||||
padding: 24rpx;
|
||||
|
||||
.view_spoken {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
.view_span {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
margin-left: 16rpx;
|
||||
}
|
||||
|
||||
.view_span text:nth-child(1) {
|
||||
font-size: 28rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: bold;
|
||||
color: #072F5A;
|
||||
margin-bottom: 7rpx;
|
||||
|
||||
}
|
||||
|
||||
.view_span text:nth-child(2) {
|
||||
font-size: 20rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 500;
|
||||
color: rgba(46, 73, 117, 0.5);
|
||||
margin-bottom: 7rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.view_text2 {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
text-align: right;
|
||||
|
||||
view .text2 {
|
||||
color: #F18F21;
|
||||
font-size: 27rpx;
|
||||
font-weight: 800;
|
||||
margin-left: 7rpx;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
.view_text2 view {
|
||||
font-size: 20rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 500;
|
||||
color: #F18F21;
|
||||
}
|
||||
|
||||
|
||||
.view_text2 text {
|
||||
font-size: 20rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 500;
|
||||
color: rgba(7, 47, 90, 0.4);
|
||||
}
|
||||
|
||||
image {
|
||||
width: 76rpx;
|
||||
height: 76rpx;
|
||||
}
|
||||
|
||||
}
|
||||
.echarts{
|
||||
width: 300rpx;
|
||||
height: 600rpx;
|
||||
margin-top: -100rpx;
|
||||
}
|
||||
.deer{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
.deer_images{
|
||||
width: 145rpx;
|
||||
height: 245rpx;
|
||||
margin-left: 15rpx;
|
||||
}
|
||||
.r_image{
|
||||
width: 16rpx;
|
||||
height: 16rpx;
|
||||
line-height: 16rpx;
|
||||
margin-left: 8rpx;
|
||||
}
|
||||
.deer_button{
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
margin-top: 19rpx;
|
||||
width: 160rpx;
|
||||
height: 56rpx;
|
||||
font-size: 20rpx;
|
||||
font-weight: 500;
|
||||
color: #FFFFFF;
|
||||
|
||||
background: #2D7CE6;
|
||||
border-radius: 86rpx 86rpx 86rpx 86rpx;
|
||||
|
||||
}
|
||||
.deer_right{
|
||||
margin-left: 20rpx;
|
||||
}
|
||||
.deer_text{
|
||||
font-size: 28rpx;
|
||||
|
||||
font-weight: 500;
|
||||
color: #627698;
|
||||
}
|
||||
.operation{
|
||||
height: 459rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
}
|
||||
.zu_image{
|
||||
width: 172rpx;
|
||||
height: 162rpx;
|
||||
|
||||
}
|
||||
.zu_text{
|
||||
font-size: 24rpx;
|
||||
font-weight: 400;
|
||||
color: #0E3B77;
|
||||
margin: 20rpx 0rpx 50rpx 0rpx;
|
||||
}
|
||||
.zu_footer{
|
||||
// padding: 32rpx 0rpx;
|
||||
}
|
||||
.zu_zp{
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
padding: 72rpx;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 36rpx;
|
||||
color: #8f8f94;
|
||||
}
|
||||
</style>
|
||||
|
|
|
|||
|
|
@ -1,105 +0,0 @@
|
|||
<template>
|
||||
<view class="view_dingbu">
|
||||
<view class="top_box">
|
||||
|
||||
<view :class="thisTop==1?'top_box_active':'top_box_item'" @click="checkTop(1)">首页<view class="line"
|
||||
v-if="thisTop==1"></view>
|
||||
</view>
|
||||
<view :class="thisTop==2?'top_box_active':'top_box_item'" @click="checkTop(2)">学生<view class="line"
|
||||
v-if="thisTop==2"></view>
|
||||
</view>
|
||||
<view :class="thisTop==3?'top_box_active':'top_box_item'" @click="checkTop(3)">我的<view class="line"
|
||||
v-if="thisTop==3"></view>
|
||||
</view>
|
||||
</view>
|
||||
<view class="content">
|
||||
<home v-if="thisTop==1"></home>
|
||||
<my v-if="thisTop==2"></my>
|
||||
<min v-if="thisTop==3"></min>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import home from '../compoents/pages_home.vue'
|
||||
import min from '../compoents/pages_mine.vue'
|
||||
import my from '../compoents/pages_my.vue'
|
||||
export default {
|
||||
components: {
|
||||
home,
|
||||
min,
|
||||
my,
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
thisTop: 1,
|
||||
partId: 350,
|
||||
infolist: '',
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
|
||||
checkTop(i) {
|
||||
this.thisTop = i
|
||||
},
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style scoped lang="scss">
|
||||
* {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
|
||||
.top_box {
|
||||
position: fixed;
|
||||
bottom: 0;
|
||||
width: 100%;
|
||||
line-height: 84rpx;
|
||||
background-color: #fff;
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
|
||||
.top_box_item {
|
||||
position: relative;
|
||||
color: #3B5878;
|
||||
font-weight: 800;
|
||||
font-size: 28rpx;
|
||||
|
||||
.line {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
width: 40rpx;
|
||||
height: 4rpx;
|
||||
background: #3996FD;
|
||||
border-radius: 2rpx 2rpx 2rpx 2rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.top_box_active {
|
||||
position: relative;
|
||||
color: #3996FD;
|
||||
font-weight: 800;
|
||||
font-size: 28rpx;
|
||||
|
||||
.line {
|
||||
position: absolute;
|
||||
bottom: 0;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
width: 40rpx;
|
||||
height: 4rpx;
|
||||
background: #3996FD;
|
||||
border-radius: 2rpx 2rpx 2rpx 2rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.content {
|
||||
width: 100%;
|
||||
}
|
||||
</style>
|
||||
279
pages/user/user.vue
Normal file
|
|
@ -0,0 +1,279 @@
|
|||
<template>
|
||||
<view class="view_body">
|
||||
<view class="view_body_images">
|
||||
<u-navbar :is-back="false" title='我的' title-color="#000" :border-bottom="false" :background="true" id="navbar">
|
||||
</u-navbar>
|
||||
<view class="view_header">
|
||||
<view>
|
||||
<view>
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/uxaCSTBJAo7SkGHtheRR" mode=""></image>
|
||||
</view>
|
||||
<view class="view_images">
|
||||
<text>LUlY老师</text>
|
||||
<u-button type="warning" size="mini">认证教师</u-button>
|
||||
</view>
|
||||
</view>
|
||||
<view class="view_sniht">
|
||||
|
||||
</view>
|
||||
</view>
|
||||
<view class="view_reative">
|
||||
<view>
|
||||
<text>学生人数</text>
|
||||
<text>320</text>
|
||||
</view>
|
||||
<view>
|
||||
<text>安排题数(道)</text>
|
||||
<text>4300</text>
|
||||
</view>
|
||||
<view>
|
||||
<text>总完成度</text>
|
||||
<text>43</text>
|
||||
</view>
|
||||
<view>
|
||||
<text>今日完成度</text>
|
||||
<text>43</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="view_centre">
|
||||
<view>
|
||||
<view class="view_centre_images">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/uif1JIGCJXguCEO3Mdqx" mode=""></image>
|
||||
</view>
|
||||
<text>作业安排</text>
|
||||
</view>
|
||||
<view>
|
||||
<view class="view_centre_images">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/u4BHxtTvVDGUDFaKPHz2" mode=""></image>
|
||||
</view>
|
||||
<text>学生管理</text>
|
||||
</view>
|
||||
<view>
|
||||
<view class="view_centre_images">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/uPqAU9hXDLOa1zrX4xJX" mode=""></image>
|
||||
</view>
|
||||
<text>班级管理</text>
|
||||
</view>
|
||||
<view>
|
||||
<view class="view_centre_images">
|
||||
<image src="https://file.langsi.online/yasiimg/web/static/uWHKotvBvHfXxwFzHiMP" mode=""></image>
|
||||
</view>
|
||||
<text>切换题库</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="view_footer">
|
||||
<view>
|
||||
<view class="view_icon">
|
||||
<u-icon name="question-circle" color="#2D7CE6"></u-icon>
|
||||
</view>
|
||||
<view class="wz">
|
||||
<view class="">
|
||||
帮助中心
|
||||
</view>
|
||||
<u-icon name="arrow-right"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="icon">
|
||||
<view class="view_icon">
|
||||
<u-icon name="question-circle" color="#2D7CE6"></u-icon>
|
||||
</view>
|
||||
<view class="wz">
|
||||
<view class="">
|
||||
关于我们
|
||||
</view>
|
||||
<u-icon name="arrow-right"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
<view class="icon">
|
||||
<view class="view_icon">
|
||||
<u-icon name="question-circle" color="#2D7CE6"></u-icon>
|
||||
</view>
|
||||
<view class="wz">
|
||||
<view class="">
|
||||
退出登录
|
||||
</view>
|
||||
<u-icon name="arrow-right"></u-icon>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
data() {
|
||||
return {
|
||||
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.view_body {
|
||||
|
||||
height: 100vh;
|
||||
background: linear-gradient(180deg, #E1EEFF 0%, #FFFFFF 100%);
|
||||
border-radius: 0rpx 0rpx 0rpx 0rpx;
|
||||
padding: 96rpx 34rpx;
|
||||
|
||||
.view_body_images {
|
||||
height: 347rpx;
|
||||
background-image: url('https://file.langsi.online/yasiimg/web/static/u4sEWPTO8OQ8hzPMUdVX');
|
||||
background-size: cover;
|
||||
background-position: center;
|
||||
|
||||
}
|
||||
|
||||
.view_reative {
|
||||
z-index: 100;
|
||||
height: 154rpx;
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
align-items: center;
|
||||
background: linear-gradient(180deg, #E1EEFF 0%, #FFFFFF 100%);
|
||||
// background-color: #FFFFFF;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
border: 2rpx solid #FFFFFF;
|
||||
margin-top: 32rpx;
|
||||
|
||||
view {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
flex-direction: column;
|
||||
}
|
||||
}
|
||||
|
||||
.view_reative view text:nth-child(1) {
|
||||
height: 32rpx;
|
||||
font-size: 20rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 500;
|
||||
color: #2E4975;
|
||||
line-height: 32rpx;
|
||||
}
|
||||
|
||||
.view_reative view text:nth-child(2) {
|
||||
height: 46rpx;
|
||||
font-size: 36rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 800;
|
||||
color: #2E4975;
|
||||
line-height: 47rpx;
|
||||
}
|
||||
|
||||
.view_header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
view {
|
||||
display: flex;
|
||||
}
|
||||
|
||||
image {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
width: 124rpx;
|
||||
height: 124rpx;
|
||||
border-radius: 803rpx 803rpx 803rpx 803rpx;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.view_images {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
margin-left: 20rpx;
|
||||
|
||||
text {
|
||||
height: 58rpx;
|
||||
font-size: 32rpx;
|
||||
font-family: PingFang SC, PingFang SC;
|
||||
font-weight: 800;
|
||||
color: #2E4975;
|
||||
line-height: 58rpx;
|
||||
}
|
||||
}
|
||||
|
||||
.view_centre {
|
||||
display: flex;
|
||||
justify-content: space-evenly;
|
||||
align-items: center;
|
||||
height: 150rpx;
|
||||
background: #FFFFFF;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
overflow: hidden;
|
||||
margin-top: 50rpx;
|
||||
|
||||
view {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
// text-align: center;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
text {
|
||||
font-size: 24rpx;
|
||||
font-weight: 700;
|
||||
color: #20314C;
|
||||
}
|
||||
|
||||
.view_centre_images {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
margin-bottom: 12rpx;
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
.view_footer {
|
||||
width: 686rpx;
|
||||
margin: 20rpx auto;
|
||||
background: #fff;
|
||||
border-radius: 20rpx 20rpx 20rpx 20rpx;
|
||||
padding: 32rpx 40rpx;
|
||||
|
||||
view {
|
||||
display: flex;
|
||||
|
||||
}
|
||||
|
||||
.wz {
|
||||
width: 550rpx;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
border-bottom: 2rpx solid #EEEEEE;
|
||||
padding-bottom: 34rpx;
|
||||
|
||||
}
|
||||
|
||||
.view_icon {
|
||||
width: 35rpx;
|
||||
height: 40rpx;
|
||||
}
|
||||
|
||||
.icon {
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
.view_sniht{
|
||||
width: 35rpx;
|
||||
height: 75rpx;
|
||||
// background-color: red;
|
||||
background: url('https://file.langsi.online/yasiimg/web/static/uv2PZzLhKjm907ZBqqXn') no-repeat center;
|
||||
background-size: 100% auto;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
</style>
|
||||
|
|
@ -312,7 +312,7 @@
|
|||
onLoad(option) {
|
||||
uni.removeStorageSync('selectedClassInfo');
|
||||
uni.removeStorageSync('selectedStuInfo');
|
||||
// uni.removeStorageSync('selectforwork');
|
||||
uni.removeStorageSync('selectforwork');
|
||||
this.classinfo = JSON.parse(decodeURIComponent(option.classinfo))
|
||||
// let classinofs = [{
|
||||
// name: '阅读5班',
|
||||
|
|
|
|||
BIN
static/logo.png
|
Before Width: | Height: | Size: 3.9 KiB |
BIN
static/tabbar/chuanti-act.png
Normal file
|
After Width: | Height: | Size: 532 B |
BIN
static/tabbar/chuanti.png
Normal file
|
After Width: | Height: | Size: 466 B |
BIN
static/tabbar/class-active.png
Normal file
|
After Width: | Height: | Size: 2.5 KiB |
BIN
static/tabbar/class.png
Normal file
|
After Width: | Height: | Size: 1.7 KiB |
BIN
static/tabbar/course-active.png
Normal file
|
After Width: | Height: | Size: 2.5 KiB |
BIN
static/tabbar/course.png
Normal file
|
After Width: | Height: | Size: 1.7 KiB |
BIN
static/tabbar/home-active.png
Normal file
|
After Width: | Height: | Size: 4.3 KiB |
BIN
static/tabbar/home.png
Normal file
|
After Width: | Height: | Size: 3.8 KiB |
BIN
static/tabbar/memory-active.png
Normal file
|
After Width: | Height: | Size: 533 B |
BIN
static/tabbar/my-active.png
Normal file
|
After Width: | Height: | Size: 653 B |
BIN
static/tabbar/my.png
Normal file
|
After Width: | Height: | Size: 646 B |
BIN
static/tabbar/signup-active.png
Normal file
|
After Width: | Height: | Size: 3.5 KiB |
BIN
static/tabbar/signup.png
Normal file
|
After Width: | Height: | Size: 3.2 KiB |
BIN
static/tabbar/tiku-act.png
Normal file
|
After Width: | Height: | Size: 4.1 KiB |
BIN
static/tabbar/tiku.png
Normal file
|
After Width: | Height: | Size: 3.3 KiB |
BIN
static/tabbar/writing-active.png
Normal file
|
After Width: | Height: | Size: 3.4 KiB |
BIN
static/tabbar/writing.png
Normal file
|
After Width: | Height: | Size: 2.5 KiB |