代码调整;页面添加;功能适配;
This commit is contained in:
parent
d956020d4e
commit
715555c7e3
19
api/account.js
Normal file
19
api/account.js
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
import request from '../utils/request.js'
|
||||||
|
|
||||||
|
export const getSupervisorsProfile = () => {
|
||||||
|
return request({
|
||||||
|
url: "/account/supervisors",
|
||||||
|
method: "get",
|
||||||
|
data: {
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getChildrenProfile = () => {
|
||||||
|
return request({
|
||||||
|
url: "/account/children",
|
||||||
|
method: "get",
|
||||||
|
data: {
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
@ -30,3 +30,57 @@ export const bindDocument = (documentCode) => {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export const checkParents = () => {
|
||||||
|
return request({
|
||||||
|
url: "/document/parents/check",
|
||||||
|
method: "get",
|
||||||
|
data: {
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getParents = () => {
|
||||||
|
return request({
|
||||||
|
url: "/document/parents",
|
||||||
|
method: "get",
|
||||||
|
data: {
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const checkChildren = () => {
|
||||||
|
return request({
|
||||||
|
url: "/document/children/check",
|
||||||
|
method: "get",
|
||||||
|
data: {
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getChildren = () => {
|
||||||
|
return request({
|
||||||
|
url: "/document/children",
|
||||||
|
method: "get",
|
||||||
|
data: {
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const checkSupervisors = () => {
|
||||||
|
return request({
|
||||||
|
url: "/document/supervisors/check",
|
||||||
|
method: "get",
|
||||||
|
data: {
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getSupervisors = () => {
|
||||||
|
return request({
|
||||||
|
url: "/document/supervisors",
|
||||||
|
method: "get",
|
||||||
|
data: {
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
6
app.json
6
app.json
@ -9,7 +9,11 @@
|
|||||||
"pages/my-grade/my-grade",
|
"pages/my-grade/my-grade",
|
||||||
"pages/child-supervisor/child-supervisor",
|
"pages/child-supervisor/child-supervisor",
|
||||||
"pages/announcement/announcement",
|
"pages/announcement/announcement",
|
||||||
"pages/message/message"
|
"pages/message/message",
|
||||||
|
"pages/my-students/my-students",
|
||||||
|
"pages/students-grade-analyse/students-grade-analyse",
|
||||||
|
"pages/my-health/my-health",
|
||||||
|
"pages/my-honors/my-honors"
|
||||||
],
|
],
|
||||||
"window": {
|
"window": {
|
||||||
"backgroundTextStyle": "light",
|
"backgroundTextStyle": "light",
|
||||||
|
@ -1,18 +1,66 @@
|
|||||||
// pages/account-relation-info/account-relation-info.js
|
// pages/account-relation-info/account-relation-info.js
|
||||||
|
import {checkParents, checkChildren, getParents, getChildren, checkSupervisors, getSupervisors} from '../../api/document'
|
||||||
|
|
||||||
Page({
|
Page({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 页面的初始数据
|
* 页面的初始数据
|
||||||
*/
|
*/
|
||||||
data: {
|
data: {
|
||||||
|
parentsInfo: [],
|
||||||
|
childrenInfo: [],
|
||||||
|
supervisorsInfo: []
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 生命周期函数--监听页面加载
|
* 生命周期函数--监听页面加载
|
||||||
*/
|
*/
|
||||||
onLoad: function (options) {
|
onLoad: function (options) {
|
||||||
|
checkParents().then(res => {
|
||||||
|
if(res === true) {
|
||||||
|
return Promise.resolve(res)
|
||||||
|
} else {
|
||||||
|
return Promise.reject(res)
|
||||||
|
}
|
||||||
|
}).then(res => {
|
||||||
|
return getParents()
|
||||||
|
}).then(res => {
|
||||||
|
this.setData({
|
||||||
|
parentsInfo: res
|
||||||
|
})
|
||||||
|
}).catch(err => {
|
||||||
|
|
||||||
|
}).then(res => {
|
||||||
|
return checkChildren().then(res=>{
|
||||||
|
if(res === true) {
|
||||||
|
return Promise.resolve(res)
|
||||||
|
} else {
|
||||||
|
return Promise.reject(res)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}).then(res => {
|
||||||
|
return getChildren().then(res => {
|
||||||
|
this.setData({
|
||||||
|
childrenInfo: res
|
||||||
|
})
|
||||||
|
})
|
||||||
|
}).catch(err => {
|
||||||
|
|
||||||
|
}).then(res => {
|
||||||
|
return checkSupervisors().then(res=>{
|
||||||
|
if(res === true) {
|
||||||
|
return Promise.resolve(res)
|
||||||
|
} else {
|
||||||
|
return Promise.reject(res)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}).then(res => {
|
||||||
|
return getSupervisors().then(res => {
|
||||||
|
this.setData({
|
||||||
|
supervisorsInfo: res
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -4,34 +4,34 @@
|
|||||||
<view class="page__title">关系信息</view>
|
<view class="page__title">关系信息</view>
|
||||||
<view class="page__desc">我与其他账号的关系</view>
|
<view class="page__desc">我与其他账号的关系</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="page__bd">
|
<view class="page__bd" wx:for="{{childrenInfo}}" wx:key="index">
|
||||||
<view class="weui-form-preview">
|
<view class="weui-form-preview">
|
||||||
<view class="weui-form-preview__hd">
|
<view class="weui-form-preview__hd">
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">孩子名称</label>
|
<label class="weui-form-preview__label">孩子姓名</label>
|
||||||
<em class="weui-form-preview__value">李xx</em>
|
<em class="weui-form-preview__value">{{item.realName}}</em>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__bd">
|
<view class="weui-form-preview__bd">
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">性别</label>
|
<label class="weui-form-preview__label">性别</label>
|
||||||
<text class="weui-form-preview__value">女</text>
|
<text class="weui-form-preview__value">{{item.gender === "U" ? "未知" : item.gender === "M" ? "男" : "女" }}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">入学年份</label>
|
<label class="weui-form-preview__label">入学年份</label>
|
||||||
<text class="weui-form-preview__value">2018</text>
|
<text class="weui-form-preview__value">{{item.gradeYear}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">专业或大类</label>
|
<label class="weui-form-preview__label">专业或大类</label>
|
||||||
<text class="weui-form-preview__value">软件工程</text>
|
<text class="weui-form-preview__value">{{item.major}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">学院</label>
|
<label class="weui-form-preview__label">学院</label>
|
||||||
<text class="weui-form-preview__value">软件学院</text>
|
<text class="weui-form-preview__value">{{item.college}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">账号绑定状态</label>
|
<label class="weui-form-preview__label">账号绑定状态</label>
|
||||||
<text class="weui-form-preview__value">已绑定</text>
|
<text class="weui-form-preview__value">{{item.connected ? "已绑定" : "未绑定"}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__ft">
|
<view class="weui-form-preview__ft">
|
||||||
@ -39,34 +39,22 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="page__bd">
|
<view class="page__bd" wx:for="{{parentsInfo}}" wx:key="index">
|
||||||
<view class="weui-form-preview">
|
<view class="weui-form-preview">
|
||||||
<view class="weui-form-preview__hd">
|
<view class="weui-form-preview__hd">
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">家长名称</label>
|
<label class="weui-form-preview__label">家长名称</label>
|
||||||
<em class="weui-form-preview__value">李ok</em>
|
<em class="weui-form-preview__value">{{item.realName}}</em>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__bd">
|
<view class="weui-form-preview__bd">
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">性别</label>
|
<label class="weui-form-preview__label">性别</label>
|
||||||
<text class="weui-form-preview__value">男</text>
|
<text class="weui-form-preview__value">{{item.gender === "U" ? "未知" : item.gender === "M" ? "男" : "女" }}</text>
|
||||||
</view>
|
|
||||||
<view class="weui-form-preview__item">
|
|
||||||
<label class="weui-form-preview__label">所在城市</label>
|
|
||||||
<text class="weui-form-preview__value">Guangdong</text>
|
|
||||||
</view>
|
|
||||||
<view class="weui-form-preview__item">
|
|
||||||
<label class="weui-form-preview__label">所在省份</label>
|
|
||||||
<text class="weui-form-preview__value">Shenzhen</text>
|
|
||||||
</view>
|
|
||||||
<view class="weui-form-preview__item">
|
|
||||||
<label class="weui-form-preview__label">联系电话</label>
|
|
||||||
<text class="weui-form-preview__value">13600000000</text>
|
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">账号绑定状态</label>
|
<label class="weui-form-preview__label">账号绑定状态</label>
|
||||||
<text class="weui-form-preview__value">已绑定</text>
|
<text class="weui-form-preview__value">{{item.connected ? "已绑定" : "未绑定"}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__ft">
|
<view class="weui-form-preview__ft">
|
||||||
@ -74,30 +62,34 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="page__bd">
|
<view class="page__bd" wx:for="{{supervisorsInfo}}" wx:key="index">
|
||||||
<view class="weui-form-preview">
|
<view class="weui-form-preview">
|
||||||
<view class="weui-form-preview__hd">
|
<view class="weui-form-preview__hd">
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">辅导员名称</label>
|
<label class="weui-form-preview__label">辅导员名称</label>
|
||||||
<em class="weui-form-preview__value">高xy</em>
|
<em class="weui-form-preview__value">{{item.realName}}</em>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__bd">
|
<view class="weui-form-preview__bd">
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">性别</label>
|
<label class="weui-form-preview__label">性别</label>
|
||||||
<text class="weui-form-preview__value">女</text>
|
<text class="weui-form-preview__value">{{item.gender === "U" ? "未知" : item.gender === "M" ? "男" : "女" }}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">邮箱</label>
|
<label class="weui-form-preview__label">所管年级</label>
|
||||||
<text class="weui-form-preview__value">supervisor@nwpu.edu.cn</text>
|
<text class="weui-form-preview__value">{{item.gradeYear}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">联系电话</label>
|
<label class="weui-form-preview__label">专业或大类</label>
|
||||||
<text class="weui-form-preview__value">13600000000</text>
|
<text class="weui-form-preview__value">{{item.major}}</text>
|
||||||
|
</view>
|
||||||
|
<view class="weui-form-preview__item">
|
||||||
|
<label class="weui-form-preview__label">学院</label>
|
||||||
|
<text class="weui-form-preview__value">{{item.college}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__item">
|
<view class="weui-form-preview__item">
|
||||||
<label class="weui-form-preview__label">账号绑定状态</label>
|
<label class="weui-form-preview__label">账号绑定状态</label>
|
||||||
<text class="weui-form-preview__value">已绑定</text>
|
<text class="weui-form-preview__value">{{item.connected ? "已绑定" : "未绑定"}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-form-preview__ft">
|
<view class="weui-form-preview__ft">
|
||||||
|
@ -3,6 +3,8 @@
|
|||||||
import {searchDocument, bindDocument} from '../../api/document'
|
import {searchDocument, bindDocument} from '../../api/document'
|
||||||
import {attachRole} from '../../api/user'
|
import {attachRole} from '../../api/user'
|
||||||
|
|
||||||
|
const app = getApp()
|
||||||
|
|
||||||
Page({
|
Page({
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -136,12 +138,12 @@ Page({
|
|||||||
toast: false,
|
toast: false,
|
||||||
hideToast: false,
|
hideToast: false,
|
||||||
});
|
});
|
||||||
// 绑定成功后,跳转进入小程序首页
|
// 绑定成功后,跳转进入小程序首页
|
||||||
wx.navigateTo({
|
wx.navigateTo({
|
||||||
url: '/pages/index/index'
|
url: '/pages/index/index'
|
||||||
})
|
})
|
||||||
}, 300);
|
}, 300);
|
||||||
}, 2000);
|
}, 3000);
|
||||||
|
|
||||||
}).catch(err =>{
|
}).catch(err =>{
|
||||||
console.log(err)
|
console.log(err)
|
||||||
|
@ -2,6 +2,7 @@
|
|||||||
|
|
||||||
import {getDocument} from '../../api/document'
|
import {getDocument} from '../../api/document'
|
||||||
import {login, checkProfile, setProfile, getProfile} from '../../api/user'
|
import {login, checkProfile, setProfile, getProfile} from '../../api/user'
|
||||||
|
import {getSupervisorsProfile, getChildrenProfile} from '../../api/account'
|
||||||
|
|
||||||
// 获取应用实例
|
// 获取应用实例
|
||||||
const app = getApp()
|
const app = getApp()
|
||||||
@ -17,6 +18,8 @@ Page({
|
|||||||
unrecoverable: false,
|
unrecoverable: false,
|
||||||
refresh: false,
|
refresh: false,
|
||||||
unrecoverableInfo: '',
|
unrecoverableInfo: '',
|
||||||
|
childrenInfo: [],
|
||||||
|
supervisorsInfo: []
|
||||||
|
|
||||||
},
|
},
|
||||||
handleLogin() {
|
handleLogin() {
|
||||||
@ -161,7 +164,24 @@ Page({
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
}).then(res => {
|
||||||
|
return getChildrenProfile()
|
||||||
|
}).then(res => {
|
||||||
|
this.setData({
|
||||||
|
childrenInfo: res
|
||||||
|
})
|
||||||
|
}).then(res => {
|
||||||
|
return getSupervisorsProfile()
|
||||||
|
}).then(res => {
|
||||||
|
this.setData({
|
||||||
|
supervisorsInfo: res
|
||||||
|
})
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
|
console.log(err)
|
||||||
|
this.setData({
|
||||||
|
loading: false,
|
||||||
|
unrecoverable: true
|
||||||
|
})
|
||||||
console.log("账户基本信息未设置")
|
console.log("账户基本信息未设置")
|
||||||
}).finally(() => {
|
}).finally(() => {
|
||||||
this.setData({
|
this.setData({
|
||||||
@ -237,4 +257,28 @@ Page({
|
|||||||
url: '/pages/message/message'
|
url: '/pages/message/message'
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
bindMyStudents() {
|
||||||
|
// 跳转
|
||||||
|
wx.navigateTo({
|
||||||
|
url: '/pages/my-students/my-students'
|
||||||
|
})
|
||||||
|
},
|
||||||
|
bindStudentsGradeAnalyse() {
|
||||||
|
// 跳转
|
||||||
|
wx.navigateTo({
|
||||||
|
url: '/pages/students-grade-analyse/students-grade-analyse'
|
||||||
|
})
|
||||||
|
},
|
||||||
|
bindMyHealth() {
|
||||||
|
// 跳转
|
||||||
|
wx.navigateTo({
|
||||||
|
url: '/pages/my-health/my-health'
|
||||||
|
})
|
||||||
|
},
|
||||||
|
bindMyHonors() {
|
||||||
|
// 跳转
|
||||||
|
wx.navigateTo({
|
||||||
|
url: '/pages/my-honors/my-honors'
|
||||||
|
})
|
||||||
|
},
|
||||||
})
|
})
|
||||||
|
@ -29,24 +29,24 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="weui-cells__title">功能</view>
|
<view class="weui-cells__title">功能</view>
|
||||||
<view class="weui-cells demo_badge_cells">
|
<view class="weui-cells demo_badge_cells">
|
||||||
<view class="weui-cell weui-cell_active">
|
<view class="weui-cell weui-cell_active" wx:for="{{childrenInfo}}" wx:key="{{index}}">
|
||||||
<view class="weui-cell__hd">
|
<view class="weui-cell__hd">
|
||||||
<image src="../../images/pic_160.png"></image>
|
<image src="{{item.avatarUrl}}"></image>
|
||||||
<text class="weui-badge">8</text>
|
<text class="weui-badge">8</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell__bd">
|
<view class="weui-cell__bd">
|
||||||
<view>我的孩子</view>
|
<view>{{item.nickName}}</view>
|
||||||
<view class="demo_badge_desc">摘要信息</view>
|
<view class="demo_badge_desc">我的孩子</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell weui-cell_active" bindtap="bindChildSupervisor">
|
<view class="weui-cell weui-cell_active" bindtap="bindChildSupervisor" wx:for="{{supervisorsInfo}}" wx:key="{{index}}">
|
||||||
<view class="weui-cell__hd">
|
<view class="weui-cell__hd">
|
||||||
<image src="../../images/pic_160.png"></image>
|
<image src="{{item.avatarUrl}}"></image>
|
||||||
<text class="weui-badge">8</text>
|
<text class="weui-badge">8</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell__bd">
|
<view class="weui-cell__bd">
|
||||||
<view>孩子的辅导员</view>
|
<view>{{item.nickName}}</view>
|
||||||
<view class="demo_badge_desc">摘要信息</view>
|
<view class="demo_badge_desc">孩子的辅导员</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell weui-cell_active weui-cell_access" bindtap="bindAnnouncement">
|
<view class="weui-cell weui-cell_active weui-cell_access" bindtap="bindAnnouncement">
|
||||||
@ -77,30 +77,30 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="weui-cell__ft"></view>
|
<view class="weui-cell__ft"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell weui-cell_active weui-cell_access">
|
<view class="weui-cell weui-cell_active weui-cell_access" bindtap="bindMyHonors">
|
||||||
<view class="weui-cell__bd">
|
<view class="weui-cell__bd">
|
||||||
<text class="demo_badge_title">我的荣誉</text>
|
<text class="demo_badge_title">我的荣誉</text>
|
||||||
<text class="weui-badge">New</text>
|
<text class="weui-badge">New</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell__ft"></view>
|
<view class="weui-cell__ft"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell weui-cell_active weui-cell_access">
|
<view class="weui-cell weui-cell_active weui-cell_access" bindtap="bindMyHealth">
|
||||||
<view class="weui-cell__bd">
|
<view class="weui-cell__bd">
|
||||||
<text class="demo_badge_title">我的健康</text>
|
<text class="demo_badge_title">我的健康</text>
|
||||||
<text class="weui-badge">New</text>
|
<text class="weui-badge">New</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell__ft"></view>
|
<view class="weui-cell__ft"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell weui-cell_active weui-cell_access">
|
<view class="weui-cell weui-cell_active weui-cell_access" bindtap="bindMyStudents">
|
||||||
<view class="weui-cell__bd">
|
<view class="weui-cell__bd">
|
||||||
<text class="demo_badge_title">我的学生</text>
|
<text class="demo_badge_title">我的学生</text>
|
||||||
<text class="weui-badge">New</text>
|
<text class="weui-badge">New</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell__ft"></view>
|
<view class="weui-cell__ft"></view>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell weui-cell_active weui-cell_access">
|
<view class="weui-cell weui-cell_active weui-cell_access" bindtap="bindStudentsGradeAnalyse">
|
||||||
<view class="weui-cell__bd">
|
<view class="weui-cell__bd">
|
||||||
<text class="demo_badge_title">学生的成绩</text>
|
<text class="demo_badge_title">学生成绩分析</text>
|
||||||
<text class="weui-badge">New</text>
|
<text class="weui-badge">New</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="weui-cell__ft"></view>
|
<view class="weui-cell__ft"></view>
|
||||||
@ -113,6 +113,6 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
<i-spin size="large" fix wx:if="{{ loading }}"></i-spin>
|
<i-spin size="large" fix wx:if="{{ loading }}"></i-spin>
|
||||||
<i-spin size="large" fix wx:if="{{ unrecoverable }}" custom><view>您的账号已被封禁</view></i-spin>
|
<i-spin size="large" fix wx:if="{{ unrecoverable }}" custom><view>您的账号不被允许使用服务</view></i-spin>
|
||||||
|
|
||||||
</view>
|
</view>
|
||||||
|
66
pages/my-health/my-health.js
Normal file
66
pages/my-health/my-health.js
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
// pages/my-health/my-health.js
|
||||||
|
Page({
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面的初始数据
|
||||||
|
*/
|
||||||
|
data: {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面加载
|
||||||
|
*/
|
||||||
|
onLoad: function (options) {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面初次渲染完成
|
||||||
|
*/
|
||||||
|
onReady: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面显示
|
||||||
|
*/
|
||||||
|
onShow: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面隐藏
|
||||||
|
*/
|
||||||
|
onHide: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面卸载
|
||||||
|
*/
|
||||||
|
onUnload: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面相关事件处理函数--监听用户下拉动作
|
||||||
|
*/
|
||||||
|
onPullDownRefresh: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面上拉触底事件的处理函数
|
||||||
|
*/
|
||||||
|
onReachBottom: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户点击右上角分享
|
||||||
|
*/
|
||||||
|
onShareAppMessage: function () {
|
||||||
|
|
||||||
|
}
|
||||||
|
})
|
3
pages/my-health/my-health.json
Normal file
3
pages/my-health/my-health.json
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"usingComponents": {}
|
||||||
|
}
|
8
pages/my-health/my-health.wxml
Normal file
8
pages/my-health/my-health.wxml
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
<!--pages/my-health/my-health.wxml-->
|
||||||
|
<view class="page" data-weui-theme="{{theme}}">
|
||||||
|
<view class="page__hd">
|
||||||
|
<view class="page__title">我的健康</view>
|
||||||
|
<view class="page__desc">我今日的健康信息</view>
|
||||||
|
</view>
|
||||||
|
|
||||||
|
</view>
|
1
pages/my-health/my-health.wxss
Normal file
1
pages/my-health/my-health.wxss
Normal file
@ -0,0 +1 @@
|
|||||||
|
/* pages/my-health/my-health.wxss */
|
66
pages/my-honors/my-honors.js
Normal file
66
pages/my-honors/my-honors.js
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
// pages/my-honors/my-honors.js
|
||||||
|
Page({
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面的初始数据
|
||||||
|
*/
|
||||||
|
data: {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面加载
|
||||||
|
*/
|
||||||
|
onLoad: function (options) {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面初次渲染完成
|
||||||
|
*/
|
||||||
|
onReady: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面显示
|
||||||
|
*/
|
||||||
|
onShow: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面隐藏
|
||||||
|
*/
|
||||||
|
onHide: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面卸载
|
||||||
|
*/
|
||||||
|
onUnload: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面相关事件处理函数--监听用户下拉动作
|
||||||
|
*/
|
||||||
|
onPullDownRefresh: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面上拉触底事件的处理函数
|
||||||
|
*/
|
||||||
|
onReachBottom: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户点击右上角分享
|
||||||
|
*/
|
||||||
|
onShareAppMessage: function () {
|
||||||
|
|
||||||
|
}
|
||||||
|
})
|
3
pages/my-honors/my-honors.json
Normal file
3
pages/my-honors/my-honors.json
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"usingComponents": {}
|
||||||
|
}
|
2
pages/my-honors/my-honors.wxml
Normal file
2
pages/my-honors/my-honors.wxml
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
<!--pages/my-honors/my-honors.wxml-->
|
||||||
|
<text>pages/my-honors/my-honors.wxml</text>
|
1
pages/my-honors/my-honors.wxss
Normal file
1
pages/my-honors/my-honors.wxss
Normal file
@ -0,0 +1 @@
|
|||||||
|
/* pages/my-honors/my-honors.wxss */
|
66
pages/my-students/my-students.js
Normal file
66
pages/my-students/my-students.js
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
// pages/my-student/my-students.js
|
||||||
|
Page({
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面的初始数据
|
||||||
|
*/
|
||||||
|
data: {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面加载
|
||||||
|
*/
|
||||||
|
onLoad: function (options) {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面初次渲染完成
|
||||||
|
*/
|
||||||
|
onReady: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面显示
|
||||||
|
*/
|
||||||
|
onShow: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面隐藏
|
||||||
|
*/
|
||||||
|
onHide: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面卸载
|
||||||
|
*/
|
||||||
|
onUnload: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面相关事件处理函数--监听用户下拉动作
|
||||||
|
*/
|
||||||
|
onPullDownRefresh: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面上拉触底事件的处理函数
|
||||||
|
*/
|
||||||
|
onReachBottom: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户点击右上角分享
|
||||||
|
*/
|
||||||
|
onShareAppMessage: function () {
|
||||||
|
|
||||||
|
}
|
||||||
|
})
|
3
pages/my-students/my-students.json
Normal file
3
pages/my-students/my-students.json
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"usingComponents": {}
|
||||||
|
}
|
45
pages/my-students/my-students.wxml
Normal file
45
pages/my-students/my-students.wxml
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
<!--pages/my-student/my-students.wxml-->
|
||||||
|
<view class="page" data-weui-theme="{{theme}}">
|
||||||
|
<view class="page__hd">
|
||||||
|
<view class="page__title">我的学生</view>
|
||||||
|
<view class="page__desc">我管理的学生们</view>
|
||||||
|
</view>
|
||||||
|
<view class="page__bd">
|
||||||
|
<view class="weui-search-bar {{inputShowed ? 'weui-search-bar_focusing' : ''}}" id="searchBar">
|
||||||
|
<form class="weui-search-bar__form">
|
||||||
|
<view class="weui-search-bar__box">
|
||||||
|
<i class="weui-icon-search"></i>
|
||||||
|
<input type="text" class="weui-search-bar__input" placeholder="搜索" value="{{inputVal}}" focus="{{inputShowed}}" bindinput="inputTyping" />
|
||||||
|
<span class="weui-icon-clear" wx:if="{{inputVal.length > 0}}" bindtap="clearInput"></span>
|
||||||
|
</view>
|
||||||
|
<label class="weui-search-bar__label" bindtap="showInput">
|
||||||
|
<i class="weui-icon-search"></i>
|
||||||
|
<span class="weui-search-bar__text">输入学号搜索</span>
|
||||||
|
</label>
|
||||||
|
</form>
|
||||||
|
<view class="weui-search-bar__cancel-btn" bindtap="hideInput">取消</view>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cells searchbar-result" wx:if="{{inputVal.length > 0}}">
|
||||||
|
<view class="weui-cell weui-cell_active weui-cell_access">
|
||||||
|
<view class="weui-cell__bd weui-cell_primary">
|
||||||
|
<view>实时搜索文本</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cell weui-cell_active weui-cell_access">
|
||||||
|
<view class="weui-cell__bd weui-cell_primary">
|
||||||
|
<view>实时搜索文本</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cell weui-cell_active weui-cell_access">
|
||||||
|
<view class="weui-cell__bd weui-cell_primary">
|
||||||
|
<view>实时搜索文本</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cell weui-cell_active weui-cell_access">
|
||||||
|
<view class="weui-cell__bd weui-cell_primary">
|
||||||
|
<view>实时搜索文本</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
1
pages/my-students/my-students.wxss
Normal file
1
pages/my-students/my-students.wxss
Normal file
@ -0,0 +1 @@
|
|||||||
|
/* pages/my-student/my-students.wxss */
|
66
pages/students-grade-analyse/students-grade-analyse.js
Normal file
66
pages/students-grade-analyse/students-grade-analyse.js
Normal file
@ -0,0 +1,66 @@
|
|||||||
|
// pages/students-grade-analyse/students-grade-analyse.js
|
||||||
|
Page({
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面的初始数据
|
||||||
|
*/
|
||||||
|
data: {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面加载
|
||||||
|
*/
|
||||||
|
onLoad: function (options) {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面初次渲染完成
|
||||||
|
*/
|
||||||
|
onReady: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面显示
|
||||||
|
*/
|
||||||
|
onShow: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面隐藏
|
||||||
|
*/
|
||||||
|
onHide: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 生命周期函数--监听页面卸载
|
||||||
|
*/
|
||||||
|
onUnload: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面相关事件处理函数--监听用户下拉动作
|
||||||
|
*/
|
||||||
|
onPullDownRefresh: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页面上拉触底事件的处理函数
|
||||||
|
*/
|
||||||
|
onReachBottom: function () {
|
||||||
|
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户点击右上角分享
|
||||||
|
*/
|
||||||
|
onShareAppMessage: function () {
|
||||||
|
|
||||||
|
}
|
||||||
|
})
|
3
pages/students-grade-analyse/students-grade-analyse.json
Normal file
3
pages/students-grade-analyse/students-grade-analyse.json
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
{
|
||||||
|
"usingComponents": {}
|
||||||
|
}
|
75
pages/students-grade-analyse/students-grade-analyse.wxml
Normal file
75
pages/students-grade-analyse/students-grade-analyse.wxml
Normal file
@ -0,0 +1,75 @@
|
|||||||
|
<!--pages/students-grade-analyse/students-grade-analyse.wxml-->
|
||||||
|
<view class="page" data-weui-theme="{{theme}}">
|
||||||
|
<view class="page__hd" wx:if="{{true}}">
|
||||||
|
<view class="page__title">学生成绩分析</view>
|
||||||
|
<view class="page__desc">我管理的学生的学业成绩情况</view>
|
||||||
|
</view>
|
||||||
|
<view wx:if="{{true}}">
|
||||||
|
<view class="page__bd">
|
||||||
|
<view class="weui-form-preview">
|
||||||
|
<view class="weui-form-preview__hd">
|
||||||
|
<view class="weui-form-preview__item">
|
||||||
|
<label class="weui-form-preview__label">学生总人数</label>
|
||||||
|
<em class="weui-form-preview__value">254</em>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="weui-form-preview__bd">
|
||||||
|
<view class="weui-form-preview__item">
|
||||||
|
<label class="weui-form-preview__label">平均学分积</label>
|
||||||
|
<text class="weui-form-preview__value">75.6</text>
|
||||||
|
</view>
|
||||||
|
<view class="weui-form-preview__item">
|
||||||
|
<label class="weui-form-preview__label">平均绩点</label>
|
||||||
|
<text class="weui-form-preview__value">2.85</text>
|
||||||
|
</view>
|
||||||
|
<view class="weui-form-preview__item">
|
||||||
|
<label class="weui-form-preview__label">挂科记录数</label>
|
||||||
|
<text class="weui-form-preview__value">12</text>
|
||||||
|
</view>
|
||||||
|
<view class="weui-form-preview__item">
|
||||||
|
<label class="weui-form-preview__label">学期数</label>
|
||||||
|
<text class="weui-form-preview__value">5</text>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="weui-form-preview__ft">
|
||||||
|
<a class="weui-form-preview__btn weui-form-preview__btn_primary">反映问题</a>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="page__bd">
|
||||||
|
<view class="weui-cells__title">功能</view>
|
||||||
|
<view class="weui-cells demo_badge_cells">
|
||||||
|
<view class="weui-cell weui-cell_active weui-cell_access">
|
||||||
|
<view class="weui-cell__bd">
|
||||||
|
<text class="demo_badge_title">需要关注的学生</text>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cell__ft"></view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
<view class="page__bd">
|
||||||
|
<view class="weui-cells__title">学期概况</view>
|
||||||
|
<view class="weui-cells demo_badge_cells">
|
||||||
|
<view class="weui-cell weui-cell_active weui-cell_access">
|
||||||
|
<view class="weui-cell__bd">
|
||||||
|
<text class="demo_badge_title">2019-2020学年春季学期</text>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cell__ft"></view>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cell weui-cell_active weui-cell_access">
|
||||||
|
<view class="weui-cell__bd">
|
||||||
|
<text class="demo_badge_title">2020-2021学年秋季学期</text>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cell__ft"></view>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cell weui-cell_active weui-cell_access">
|
||||||
|
<view class="weui-cell__bd">
|
||||||
|
<text class="demo_badge_title">2020-2021学年春季学期</text>
|
||||||
|
</view>
|
||||||
|
<view class="weui-cell__ft"></view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
|
|
1
pages/students-grade-analyse/students-grade-analyse.wxss
Normal file
1
pages/students-grade-analyse/students-grade-analyse.wxss
Normal file
@ -0,0 +1 @@
|
|||||||
|
/* pages/students-grade-analyse/students-grade-analyse.wxss */
|
@ -14,11 +14,9 @@ const refresh_token = app => {
|
|||||||
method: 'get'
|
method: 'get'
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
// 设置登录信息
|
// 设置登录信息
|
||||||
const userInfo = app.globalData.userInfo
|
app.globalData.userBaseInfo.token = res.token
|
||||||
userInfo.token = res.token
|
|
||||||
resolve(true)
|
resolve(true)
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
console.log(err)
|
|
||||||
// 清空登录信息
|
// 清空登录信息
|
||||||
app.globalData.login = false
|
app.globalData.login = false
|
||||||
app.globalData.userInfo = {}
|
app.globalData.userInfo = {}
|
||||||
|
Loading…
Reference in New Issue
Block a user