Browse Source

Merge branch '娄底高职分支' of http://123.57.209.16:3000/bjquanjiang/DigitalScholl into 娄底高职分支

娄底高职分支
ndbs 2 years ago
parent
commit
26dcb427e1
5 changed files with 343 additions and 378 deletions
  1. +4
    -4
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/OpenLessonPlanOfElectiveStudent/list.vue
  2. +1
    -1
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/OpenLessonPlanOfElectiveStudentPre/list.vue
  3. +1
    -1
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/OpenLessonPlanOfElectiveStudentSelected/list.vue
  4. +5
    -5
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/timeTable/leaveFrom.vue
  5. +332
    -367
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/timeTable/list.vue

+ 4
- 4
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/OpenLessonPlanOfElectiveStudent/list.vue View File

@@ -102,14 +102,14 @@ export default {
};
if (true) {
_postParam.queryJson = JSON.stringify({
StuNo: _this.user.account,
StuMajorNo: _this.user.majorno,
StuGrade: _this.user.grade
StuNo: _this.user.account||undefined,
StuMajorNo: _this.user.majorno||undefined,
StuGrade: _this.user.grade||undefined
});
}
// console.log(_this.user)
_this.LOADING('加载数据中…')
_this.HTTP_GET('learun/EducationalAdministration/OpenLessonPlanOfElectiveStudent/pagelist', _postParam, '加载数据时出错').then(res => {
_this.HTTP_GET('learun/OpenLessonPlanOfElectiveStudent/pagelist', _postParam, '加载数据时出错').then(res => {
_this.HIDE_LOADING();
// console.log(res);
this.data = this.data.concat(res.rows);


+ 1
- 1
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/OpenLessonPlanOfElectiveStudentPre/list.vue View File

@@ -108,7 +108,7 @@ export default {
});
}
_this.LOADING('加载数据中…')
_this.HTTP_GET('learun/EducationalAdministration/OpenLessonPlanOfElectiveStudent/pagelist', _postParam, '加载数据时出错').then(res => {
_this.HTTP_GET('learun/OpenLessonPlanOfElectiveStudent/pagelist', _postParam, '加载数据时出错').then(res => {
_this.HIDE_LOADING();
// console.log(res);
this.data = this.data.concat(res.rows);


+ 1
- 1
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/OpenLessonPlanOfElectiveStudentSelected/list.vue View File

@@ -106,7 +106,7 @@ export default {
});
}
_this.LOADING('加载数据中…')
_this.HTTP_GET('learun/EducationalAdministration/OpenLessonPlanOfElectiveStudent/studentpagelist', _postParam, '加载数据时出错').then(res => {
_this.HTTP_GET('learun/OpenLessonPlanOfElectiveStudent/studentpagelist', _postParam, '加载数据时出错').then(res => {
_this.HIDE_LOADING();
// console.log(res);
this.data = this.data.concat(res.rows);


+ 5
- 5
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/timeTable/leaveFrom.vue View File

@@ -130,7 +130,7 @@ export default {
}),
this.FETCH_DATASOURCE('bjsj').then(data => {
// console.log(data)
this.dataSource.ClassNo = data.data.sort((a,b)=>{return b.classno-a.classno}).map(t => ({
this.dataSource.ClassNo = data.data.map(t => ({
text: t.classname,
value: t.classno
}));
@@ -175,14 +175,14 @@ export default {
this.queryData.StuNo = res.StuNo;
this.queryData.StuName = res.StuName;
this.queryData.Grade = res.Grade;
this.queryData.EmpNo = res.EmpNo;
this.queryData.EmpNo = this.pageInfo.EmpNo;
this.queryData.DeptNo = res.DeptNo;
this.queryData.DeptName = this.displayListItem(res, 'DeptNo');
this.queryData.MajorNo = res.MajorNo;
this.queryData.MajorName = this.displayListItem(res, 'MajorNo');
this.queryData.ClassNo = res.ClassNo;
this.queryData.ClassName = this.displayListItem(res, 'ClassNo');
this.queryData.Remark = res.Remark;
this.queryData.Remark = '';
this.queryData.LeaveType = '1';
this.queryData.LessonNo = this.pageInfo.LessonNo;
@@ -208,10 +208,10 @@ export default {
this.LOADING('保存数据中…');
this.HTTP_POST('learun/adms/EducationalAdministration/StuAttendanceLeave/save', _postData, '加载数据时出错').then(res => {
this.HIDE_LOADING();
console.log(res)
//console.log(res)
if(res){
this.TOAST('提交成功!');
this.EMIT('timeTable');
this.EMIT('timeTable',this.queryData.LessonDate);
this.NAV_BACK();
}
});


+ 332
- 367
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/timeTable/list.vue View File

@@ -11,40 +11,35 @@
<text>{{todayWeek.Monday}}</text>
-
<text>{{todayWeek.Sunday}}</text>
<text class="text-xxl cuIcon cuIcon-right" @click="timeTap(2)"></text>
<text class="text-xxl cuIcon cuIcon-right" @click="timeTap(2)"></text>
</view>
</view>
<view class="timeTable_sec2">
<view class="tSec2Top">
<view class="tSec2TopUl">
<view class="tSec2TopLi" v-for="(item, ind) in weekArr" :key="item.en" @click="liTap(ind)"
:class="ind == num? 'active' : ''">
<text>{{ item.en }}</text>
<text>{{ item.cn }}</text>
</view>
<view class="tSec2TopLi" v-for="(item, ind) in weekArr" :key="item.en" @click="liTap(ind)" :class="ind == num? 'active' : ''">
<text>{{ item.en }}</text>
<text>{{ item.cn }}</text>
</view>

</view>
<view class="tSec2Box">
<view class="tSec2Con" v-for="(items, i) in weekArr" :key="items.num" v-show="i == num">
<view class="tSec2Con" v-for="(items, i) in dataArr" :key="items.num" v-show="i == num">
<view class="tSec2List">
<view v-if="dataArr[i+1]&&dataArr[i+1].length <= 0" class="tSec2ListLi">
<view class="noHtml">该时间段没有课表</view>
</view>
<view v-if="dataArr[i+1]&&dataArr[i+1].length > 0">
<view class="tSec2ListLi" v-for="(k, j) in dataArr[i+1]" :key="j" @click="classTap(k)">
<view class="tSec2ListL">第 {{ k.jc }} 节</view>
<view v-if="items.lessonData.length <= 0" class="tSec2ListLi"><view class="noHtml">该时间段没有课表</view></view>
<view v-if="items.lessonData.length > 0">
<view class="tSec2ListLi" v-for="(k, j) in items.lessonData" :key="j" @click="classTap(k)">
<view class="tSec2ListL">第 {{ k.sectionTime }} 节</view>
<view class="tSec2ListR">
<view class="tSec2ListBox">
<view class="tSec2ListT">{{ k.curriculum }}</view>
<view class="tSec2ListT">{{ k.LessonName }}</view>
<view class="tSec2ListTxt">{{ k.ClassName }}</view>
<view class="tSec2ListTxt">
<text class="text-xxl cuIcon cuIcon-profile"></text>
{{ k.teacher }}
{{ k.EmpName }}
</view>
</view>
<view class="tSec2Location">
<text class="text-xxl cuIcon cuIcon-location"></text>
{{ k.className }}
{{ k.ClassroomName }}
</view>
</view>
</view>
@@ -57,364 +52,334 @@
</template>

<script>
import common from '@/common/js/common.js'
export default {
data() {
return {
semester: '',
num: 0,
user: null,
weekDayTime: 0,
noClassTime:0,
todayWeek: {},
dataArr: [],
weekArr: [{
en: 'ONE',
cn: '星期一'
},
{
en: 'TWO',
cn: '星期二'
},
{
en: 'THREE',
cn: '星期三'
},
{
en: 'FOUR',
cn: '星期四'
},
{
en: 'FIVE',
cn: '星期五'
},
{
en: 'SIX',
cn: '星期六'
},
{
en: 'SEVEN',
cn: '星期七'
},
{
en: 'EIGHT',
cn: '星期八'
},
{
en: 'NINE',
cn: '星期九'
},
{
en: 'TEN',
cn: '星期十'
}
]
};
import common from '@/common/js/common.js'
export default {
data() {
return {
semester: '',
num: 0,
user: null,
weekDayTime: 0,
todayWeek: {},
dataArr: [],
weekArr: [
{
en: 'MON',
cn: '星期一'
},
{
en: 'TUE',
cn: '星期二'
},
{
en: 'WED',
cn: '星期三'
},
{
en: 'THU',
cn: '星期四'
},
{
en: 'FRI',
cn: '星期五'
},
{
en: 'SAT',
cn: '星期六'
},
{
en: 'SUN',
cn: '星期日'
}
]
};
},
onUnload() {
this.OFF('timeTable');
},
methods: {
async init(obj) {
//console.log(obj)
let _this = this;
_this.todayWeek = common.weekday(obj);
//console.log(_this.todayWeek)
_this.semester = common.judgeDate(obj);
_this.weekDayTime = 7 * common.oneDayTime();
_this.user = _this.GET_GLOBAL('loginUser');
_this.loadData(_this.todayWeek.Monday, _this.todayWeek.Sunday);
},
onUnload() {
this.OFF('timeTable');
liTap(ind) {
this.num = ind;
},
methods: {
// 初始化数据
async init() {
let _this = this;
// _this.todayWeek = common.weekday2();
_this.weekDayTime = 14 * common.oneDayTime();
_this.noClassTime = 4 * common.oneDayTime();
_this.loadData();
},
liTap(ind) {
this.num = ind;
},
// 切换时间
timeTap(num) {
let _this = this;
if (num == 1) {
_this.todayWeek.MondayTime = _this.todayWeek.MondayTime - _this.weekDayTime ;
_this.todayWeek.SundayTime = _this.todayWeek.SundayTime - _this.weekDayTime;
} else {
_this.todayWeek.MondayTime = _this.todayWeek.MondayTime + _this.weekDayTime;
_this.todayWeek.SundayTime = _this.todayWeek.SundayTime + _this.weekDayTime;
timeTap(num) {
let _this = this;
if (num == 1) {
_this.todayWeek.MondayTime = _this.todayWeek.MondayTime - _this.weekDayTime;
_this.todayWeek.SundayTime = _this.todayWeek.SundayTime - _this.weekDayTime;
} else {
_this.todayWeek.MondayTime = _this.todayWeek.MondayTime + _this.weekDayTime;
_this.todayWeek.SundayTime = _this.todayWeek.SundayTime + _this.weekDayTime;
}
_this.num = 0;
_this.todayWeek.Monday = common.fmtDate(_this.todayWeek.MondayTime);
_this.todayWeek.Sunday = common.fmtDate(_this.todayWeek.SundayTime);
_this.semester = common.judgeDate(_this.todayWeek.SundayTime);
_this.loadData(_this.todayWeek.Monday, _this.todayWeek.Sunday);
},
loadData(start, end) {
let param = { StartDate: start, EndDate: end };
// let param = { StartDate: '2018-11-05', EndDate: '2018-11-11' };
let _this = this;
_this.LOADING('加载数据中…');
_this.HTTP_GET('learun/adms/timetable/list', param, '加载数据时出错').then(res => {
this.HIDE_LOADING();
// console.log(res);
_this.ProcessingData(res);
});
},
ProcessingData(data) {
let dataM = [
{
weekTime: 1,
num: Math.floor(Math.random() * 100000000),
lessonData: []
},
{
weekTime: 2,
num: Math.floor(Math.random() * 100000000),
lessonData: []
},
{
weekTime: 3,
num: Math.floor(Math.random() * 100000000),
lessonData: []
},
{
weekTime: 4,
num: Math.floor(Math.random() * 100000000),
lessonData: []
},
{
weekTime: 5,
num: Math.floor(Math.random() * 100000000),
lessonData: []
},
{
weekTime: 6,
num: Math.floor(Math.random() * 100000000),
lessonData: []
},
{
weekTime: 7,
num: Math.floor(Math.random() * 100000000),
lessonData: []
}
_this.num = 0;
_this.todayWeek.Monday = common.fmtDate(_this.todayWeek.MondayTime);
_this.todayWeek.Sunday = common.fmtDate(_this.todayWeek.SundayTime);
_this.loadData(_this.todayWeek.Monday, _this.todayWeek.Sunday);
},
// 获取数据
loadData(start, end) {
if(!this.user) return
let {
Description,
account: Account
} = this.user
let param = {
StartDate: start,
EndDate: end,
Description,
Account,
};
let _this = this;
_this.LOADING('加载数据中…');
_this.HTTP_GET('learun/adms/timetable/TenDay', param, '加载数据时出错').then(res => {
this.HIDE_LOADING();
_this.semester = res.semester
_this.dataArr = _this.ProcessingData(res.weekList);
// 回显日期
if (!start) {
_this.todayWeek.MondayTime = new Date(res.startDate).valueOf();
_this.todayWeek.SundayTime = new Date(res.endDate).valueOf() + _this.noClassTime;
_this.num = 0;
_this.todayWeek.Monday = common.fmtDate(_this.todayWeek.MondayTime);
_this.todayWeek.Sunday = common.fmtDate(_this.todayWeek.SundayTime);
];
data.forEach((n, i) => {
n.sectionTime = n.LessonTime.slice(1);
dataM.forEach((k, j) => {
if (k.weekTime == n.LessonTime.slice(0, 1)) {
k.lessonData.push(n);
}
});

},
// 处理课程数据
ProcessingData(res) {
let courseCateByDay = {}
for (let i = 1; i < 11; i++) {
courseCateByDay[i] = []
}
res.forEach((item) => {
item.list.sort((a, b) => {
return a.jc - b.jc
})
courseCateByDay[item.time] = item.list
})
return courseCateByDay;
},
classTap(data) {
return ""
let _this = this;
// console.log(_this.user)
if (_this.user.Description == "教师") {
//console.log("教师");
} else if (_this.user.Description == "学生") {
let LeaveType = data.LeaveType;
//console.log(LeaveType);
let IsCheck = data.IsCheck;
//console.log(IsCheck);
if (LeaveType == "1") {
let msg = "请假申请中";
if (IsCheck == "1") {
msg = "请假通过";
}
if (IsCheck == "2") {
msg = "请假未通过";
}
_this.TOAST(msg);
} else {
// var param = {
// AcademicYearNo: data.AcademicYear,
// ClassRoomNo: data.ClassRoomNo,
// EmpNo: data.EmpNo,
// LessonDate: data.LessonDate,
// LessonNo: data.LessonNo,
// LessonSortNo: data.LessonSortNo,
// LessonTime: data.LessonTime,
// Semester: data.Semester
// };
this.NAV_TO('./leaveFrom', data, true);
}
}
});
dataM.forEach((n, i) => {
n.lessonData.sort(common.compare('sectionTime'));
});
this.dataArr = dataM;
},
classTap(data) {
let _this = this;
// console.log(_this.user)
if (_this.user.Description == "教师") {
//console.log("教师");
} else if (_this.user.Description == "学生") {
let LeaveType = data.LeaveType;
//console.log(LeaveType);
let IsCheck = data.IsCheck;
//console.log(IsCheck);
if (LeaveType == "1") {
let msg = "请假申请中";
if (IsCheck == "1") {
msg = "请假通过";
}
if (IsCheck == "2") {
msg = "请假未通过";
}
_this.TOAST(msg);
}
else {
this.NAV_TO('./leaveFrom', data, true);
}
}
},
created() {
this.ON('timeTable', this.init);
this.user = this.GET_GLOBAL('loginUser');
this.init()
onfun(obj){
this.init(obj);
}
};
},
created() {
//this.ON('timeTable', this.init);
this.ON('timeTable', this.onfun);
this.init()
}
};
</script>

<style lang="less" scoped>
.page {
background: #fff;
}

.timeTable_sec1 {
padding: 14px 12px;
text-align: center;
background: #0075c4;
color: #94d4ff;
font-size: 0;
}

.tSec1Box>* {
display: inline-block;
vertical-align: middle;
}

.tSec1Line {
height: 13px;
width: 1px;
background: #94d4ff;
margin: 0 10px;
}

.tSec1Box {
font-size: 15px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}

#semester {
margin-bottom: 10px;
}

#weekTime {}

#weekTime text {
margin: 0 10px;
}

.tSec1Box>text {
width: auto;
text-align: center;
line-height: 22px;
}

.tSec1Box image {
width: 15px;
margin-right: 2px;
}

.tSec1Box text:after {
display: none;
}

.timeTable_sec2 {
margin-bottom: 30px;
}

.tSec2Top {
padding: 0 12px;
background: #0075c4;
height: 55px;
text-align: center;
overflow: auto;
}

.tSec2TopUl {
width: 800px;
}

.tSec2TopLi {
width: 10%;
float: left;
line-height: 18px;
padding: 9px 0 9px;
color: #fff;
font-size: 13px;
border-right: 1px solid #1084d2;
border-top: 1px solid #1084d2;
}

.tSec2TopLi:first-child {
border-left: 1px solid #1084d2;
}

.tSec2TopLi.active {
color: #0075c4;
background: #fff;
border-color: #fff;
}

.tSec2TopLi text {
display: block;
}

.tSec2TopLi text:first-child {
letter-spacing: 2px;
text-transform: uppercase;
}

.tSec2Box {
padding: 0 12px;
margin-top: 10px;
}

.tSec2Con {
border-left: 1px solid #d5eaf7;
border-right: 1px solid #d5eaf7;
border-top: 1px solid #d5eaf7;
// display: none;
}

.tSec2Con:first-child {
display: block;
}

.tSec2List {
margin-top: 10px;
}

.tSec2List:first-child {
margin-top: 0;
}

.tSec2ListLi {
border-bottom: 1px solid #d5eaf7;
overflow: hidden;
height: 60px;
}

.tSec2ListL {
float: left;
background: #e8f6ff;
height: 100%;
width: 20%;
text-align: center;
line-height: 36px;
padding: 11px 0;
font-size: 14px;
color: #646464;
}

.tSec2ListR {
float: left;
width: 80%;
height: 100%;
line-height: 18px;
padding: 4px 0;
overflow: hidden;
}

.tSec2ListBox {
width: 62%;
float: left;
padding-left: 5px;
}

.tSec2ListT {
color: #3e3e3e;
font-size: 15px;
margin: 5px 0;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}

.tSec2ListTxt {
color: #888888;
font-size: 13px;
}

.tSec2Location {
width: 38%;
float: left;
line-height: 44px;
font-size: 13px;
color: #888888;
}

.noHtml {
height: 100%;
line-height: 60px;
text-align: center;
font-size: 14px;
}
.page{
background: #fff;
}
.timeTable_sec1 {
padding: 14px 12px;
text-align: center;
background: #0075c4;
color: #94d4ff;
font-size: 0;
}
.tSec1Box > * {
display: inline-block;
vertical-align: middle;
}
.tSec1Line {
height: 13px;
width: 1px;
background: #94d4ff;
margin: 0 10px;
}
.tSec1Box {
font-size: 15px;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
#semester {
margin-bottom: 10px;
}
#weekTime {
}
#weekTime text {
margin: 0 10px;
}
.tSec1Box > text {
width: auto;
text-align: center;
line-height: 22px;
}
.tSec1Box image {
width: 15px;
margin-right: 2px;
}
.tSec1Box text:after {
display: none;
}
.timeTable_sec2 {
margin-bottom: 30px;
}
.tSec2Top {
padding: 0 12px;
background: #0075c4;
height: 55px;
text-align: center;
overflow: hidden;
}
.tSec2TopLi {
width: 14.285714%;
float: left;
line-height: 18px;
padding: 9px 0 9px;
color: #fff;
font-size: 13px;
border-right: 1px solid #1084d2;
border-top: 1px solid #1084d2;
}
.tSec2TopLi:first-child {
border-left: 1px solid #1084d2;
}
.tSec2TopLi.active {
color: #0075c4;
background: #fff;
border-color: #fff;
}
.tSec2TopLi text {
display: block;
}

.tSec2TopLi text:first-child {
letter-spacing: 2px;
text-transform: uppercase;
}
.tSec2Box {
padding: 0 12px;
margin-top: 10px;
}
.tSec2Con {
border-left: 1px solid #d5eaf7;
border-right: 1px solid #d5eaf7;
border-top: 1px solid #d5eaf7;
// display: none;
}
.tSec2Con:first-child {
display: block;
}
.tSec2List {
margin-top: 10px;
}
.tSec2List:first-child {
margin-top: 0;
}
.tSec2ListLi {
border-bottom: 1px solid #d5eaf7;
overflow: hidden;
height: 64px;
}
.tSec2ListL {
float: left;
background: #e8f6ff;
height: 100%;
width: 25%;
text-align: center;
line-height: 36px;
padding: 11px 0;
font-size: 14px;
color: #646464;
}
.tSec2ListR {
float: left;
width: 75%;
height: 100%;
line-height: 18px;
padding: 4px 0;
overflow: hidden;
}
.tSec2ListBox {
width: 70%;
float: left;
padding-left: 5px;
}
.tSec2ListT {
color: #3e3e3e;
font-size: 15px;
margin: 2px 0;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
.tSec2ListTxt {
color: #888888;
font-size: 13px;
}
.tSec2Location {
width: 30%;
float: left;
line-height: 44px;
font-size: 13px;
color: #888888;
}
.noHtml {
height: 100%;
line-height: 60px;
text-align: center;
font-size: 14px;
}
</style>

Loading…
Cancel
Save