Browse Source

Merge branch '长阳分支中职' of http://123.57.209.16:3000/bjquanjiang/DigitalScholl into 长阳分支中职

新疆警官学校中职
zhangli 2 years ago
parent
commit
82ffd16817
6 changed files with 913 additions and 298 deletions
  1. +49
    -4
      Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/TimeTable.cs
  2. +6
    -0
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages.json
  3. +453
    -0
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuAttendanceLeave/IndexInStudent/list.vue
  4. +371
    -268
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/studentCheck/list.vue
  5. +32
    -25
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/timeTable/leaveFrom.vue
  6. +2
    -1
      Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/timeTable/list.vue

+ 49
- 4
Learun.Framework.Ultimate V7/Learun.Application.WebApi/Modules/TimeTable.cs View File

@@ -89,7 +89,51 @@ namespace Learun.Application.WebApi.Modules
public Response GetStuLessonInfo(dynamic _)
{
var param = this.GetReqData<TimeParameter>();
var lessonInfos = stuAttendanceIBLL.GetStuLessonInfo(userInfo.account, param.StartDate, param.EndDate);

var startdate = DateTime.Today;
var startDate = Common.CalculateFirstDateOfWeek(startdate).ToString("yyyy-MM-dd");
var endDate = Common.CalculateLastDateOfWeek(startdate).ToString("yyyy-MM-dd");
var lessonInfos = stuAttendanceIBLL.GetStuLessonInfo("", "", "");

var strAcademicYear = "";
var strSemester = "";
var AcademicYearShort = "";

// 获取学年,学期
if (!param.StartDate.IsEmpty() && !param.EndDate.IsEmpty())
{
var NewsemesterAndYear = Common.GetSemesterAndYear(param.StartDate);
strAcademicYear = NewsemesterAndYear.AcademicYearLong;
strSemester = NewsemesterAndYear.Semester;
AcademicYearShort = NewsemesterAndYear.AcademicYearShort;
}
else
{
var semesterAndYear = Common.GetSemesterAndYear(startDate);
strAcademicYear = semesterAndYear.AcademicYearLong;
strSemester = semesterAndYear.Semester;
AcademicYearShort = semesterAndYear.AcademicYearShort;
}

if (param.StartDate.IsEmpty() && param.EndDate.IsEmpty())
{
// 校历
var entity = schoolCalendarIbll.GetSchoolCalendarEntityByNo(AcademicYearShort, strSemester);
var StartTime = entity.StartTime.Value;
//获取第几周
var curWeek = WeekOfYear(startdate, entity.StartTime.Value, entity.EndTime.Value);
///获取当前周次开始时间
startDate = Common.CalculateFirstDateOfWeek(StartTime.AddDays(((curWeek - 1) * 14))).ToString("yyyy-MM-dd");
if (curWeek == 1 && Convert.ToDateTime(startDate) < StartTime)//判断第几周
{
startDate = StartTime.ToString("yyyy-MM-dd");
}
endDate = Common.CalculateFirstDateOfWeek(StartTime.AddDays(((curWeek - 1) * 14))).AddDays(9).ToString("yyyy-MM-dd");
param.StartDate = startDate;
param.EndDate = endDate;
}
lessonInfos = stuAttendanceIBLL.GetStuLessonInfo(userInfo.account, param.StartDate, param.EndDate);

var empNos = lessonInfos.Select(a => a.EmpNo).ToList();
var lessonTerms = arrangeLessonTermIBLL.GetListByEmpNo(empNos);

@@ -101,7 +145,8 @@ namespace Learun.Application.WebApi.Modules
a.LessonTime,
a.EmpNo,
a.ClassRoomName,
a.Sort
a.Sort,
a.AttendOrNo
}).ToList();

var weeks = list.GroupBy(a => a.LessonDate).ToList();
@@ -113,7 +158,7 @@ namespace Learun.Application.WebApi.Modules
var result = new { week, weekList };
results.Add(result);
}
return Success(results);
return Success(new { results, schoolName = "课程表", semester = $"{strAcademicYear}学年度 第{strSemester}学期", startDate = param.StartDate, endDate = param.EndDate });

}

@@ -196,7 +241,7 @@ namespace Learun.Application.WebApi.Modules
var strAcademicYear = "";
var strSemester = "";
var AcademicYearShort = "";
if (!string.IsNullOrEmpty(param.StartDate))
if (!param.StartDate.IsEmpty())
{
var NewsemesterAndYear = Common.GetSemesterAndYear(param.StartDate);
strAcademicYear = NewsemesterAndYear.AcademicYearLong;


+ 6
- 0
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages.json View File

@@ -585,6 +585,12 @@
"navigationBarTitleText": "审核"
}
},
{
"path": "pages/EducationalAdministration/StuAttendanceLeave/IndexInStudent/list",
"style": {
"navigationBarTitleText": "课表请假管理"
}
},
//疫情详细信息
{
"path": "pages/PersonnelManagement/ContactsDetails/list",


+ 453
- 0
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/EducationalAdministration/StuAttendanceLeave/IndexInStudent/list.vue View File

@@ -0,0 +1,453 @@
<template>
<view class="page">
<!-- 主列表页 -->
<view :class="sideOpen ? 'show' : ''" class="mainpage" style="padding-top: 80rpx;">
<!-- 顶部条目/分页信息栏 -->
<l-customlist-banner @buttonClick="sideOpen = true">{{ tips }}</l-customlist-banner>
<!-- 滚动列表,跨端支持上拉/下拉 -->
<l-scroll-list v-if="ready" @pullDown="pullDown" @toBottom="fetchList()" ref="list">
<l-customlist :tips="loadState" showTips>
<!-- 单条记录 -->
<view class="customlist-item" v-for="item of list" :key="item.Id">

<view class="customlist-item-field">
<text class="customlist-item-field-title">申请时间:</text>
{{ displayListItem(item, 'UpdateDate') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">审核状态:</text>
{{ LeaveCheckItem(displayListItem(item, 'IsCheck')) }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">审核备注:</text>
{{ displayListItem(item, 'TecRemark') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">请假类型:</text>
{{ LeaveTypeItem(displayListItem(item, 'LeaveType')) }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">学年:</text>
{{ displayListItem(item, 'AcademicYearNo') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">学期:</text>
{{ displayListItem(item, 'Semester') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">学号:</text>
{{ displayListItem(item, 'StuNo') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">姓名:</text>
{{ displayListItem(item, 'StuName') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">年级:</text>
{{ displayListItem(item, 'Grade') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">系所码:</text>
{{ displayListItem(item, 'DeptNo') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">系名:</text>
{{ displayListItem(item, 'DeptName') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">专业码:</text>
{{ displayListItem(item, 'MajorNo') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">专业名:</text>
{{ displayListItem(item, 'MajorName') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">所在行政班号:</text>
{{ displayListItem(item, 'ClassNo') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">班级名称:</text>
{{ displayListItem(item, 'ClassName') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">课程号:</text>
{{ displayListItem(item, 'LessonNo') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">课程名称:</text>
{{ displayListItem(item, 'LessonName') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">课程类别码:</text>
{{ displayListItem(item, 'LessonSortNo') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">课程类别:</text>
{{ displayListItem(item, 'LessonSortName') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">原上课日期:</text>
{{ displayListItem(item, 'LessonDate') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">上课时间:</text>
{{ displayListItem(item, 'LessonTime') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">教师号:</text>
{{ displayListItem(item, 'EmpNo') }}
</view>
<view class="customlist-item-field">
<text class="customlist-item-field-title">备注:</text>
{{ displayListItem(item, 'Remark') }}
</view>
<!-- <l-customlist-action @view="action('view', item.ID)" /> -->
</view>
</l-customlist>
</l-scroll-list>
</view>
<!-- 关闭侧边抽屉按钮 -->
<view @click="sideOpen = false" :class="sideOpen ? 'show' : ''" class="sideclose">
<l-icon type="pullright" color="blue" />
</view>
<!-- 侧边栏,用于设置查询条件 -->
<scroll-view :class="sideOpen ? 'show' : ''" class="sidepage" scroll-y>
<view v-if="ready" class="padding">
<l-input
v-model="queryData.LessonName"
@change="searchChange"
title ="课程名称"
placeholder="按课程名称查询"
/>
<l-input
v-model="queryData.Grade"
@change="searchChange"
title ="年级"
placeholder="按年级查询"
/>
<l-input
v-model="queryData.StuName"
@change="searchChange"
title ="姓名"
placeholder="按姓名查询"
/>
<l-input
v-model="queryData.EmpNo"
@change="searchChange"
title ="教师号"
placeholder="按教师号查询"
/>
<!-- 重置查询条件按钮 -->
<view class="padding-tb">
<l-button @click="reset" line="orange" class="block" block>重置查询条件</l-button>
</view>
</view>
</scroll-view>
<!-- <l-customlist-add v-if="!sideOpen" @click="action('add')" /> -->
</view>
</template>
<script>
/*
* 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2020 上海力软信息技术有限公司
* 创建人:超级管理员
* 日 期:2020-10-20 15:22
* 描 述:aaa
*/
/**
* 本段代码由移动端代码生成器输出,移动端须 2.2.0 版本及以上可以使用
* 请在移动端 /pages.json 中的 pages 字段中添加一条记录:
* { "path": "pages/EducationalAdministration/StuAttendanceLeave/list", "style": { "navigationBarTitleText": "表单列表页" } }
*
* (navigationBarTitleText 字段为本页面的标题文本,可以修改)
* (必须自行操作该步骤,力软代码生成器不会自动帮您修改 /pages.json 文件)
*/
import moment from 'moment'
import get from 'lodash/get'
import set from 'lodash/set'
import pickBy from 'lodash/pickBy'
import mapValues from 'lodash/mapValues'
export default {
data() {
return {
// 数据项的数据类型、结构
scheme: {
UpdateDate: { type: 'text' },
IsCheck: { type: 'text' },
TecRemark: { type: 'text' },
LeaveType: { type: 'text' },
AcademicYearNo: { type: 'text' },
Semester: { type: 'text' },
StuNo: { type: 'text' },
StuName: { type: 'text' },
Grade: { type: 'text' },
DeptNo: { type: 'text' },
DeptName: { type: 'text' },
MajorNo: { type: 'text' },
MajorName: { type: 'text' },
ClassNo: { type: 'text' },
ClassName: { type: 'text' },
LessonNo: { type: 'text' },
LessonName: { type: 'text' },
LessonSortNo: { type: 'text' },
LessonSortName: { type: 'text' },
LessonDate: { type: 'text' },
LessonTime: { type: 'text' },
EmpNo: { type: 'text' },
Remark: { type: 'text' },
},
// 查询条件
searchData: {},
defaultQueryData: {},
queryData: {
StuNo: '',
StuName: '',
},
// 数据源
dataSource: {
},
// 页面相关参数
ready: false,
tips: '加载中...',
loadState: '向下翻以加载更多',
sideOpen: false,
// 列表与分页信息
page: 1,
total: 2,
list: [],
user: null,
}
},
async onLoad() {
await this.init()
},
onUnload() {
this.OFF('EducationalAdministrationStuAttendanceLeave-list-change')
},
methods: {
// 页面初始化
async init() {
this.ON('EducationalAdministrationStuAttendanceLeave-list-change', this.refreshList)
// 拉取加载列表和数据源
await Promise.all([
() => {}
])
// console.log(this.user)
await this.fetchList()
// 初始化查询条件
this.defaultQueryData = this.COPY(this.queryData)
this.ready = true
},
// 拉取列表
async fetchList() {
if (this.page > this.total) { return }
const result = await this.HTTP_GET(
'learun/adms/EducationalAdministration/StuAttendanceLeave/pagelist',
{
// 这里 sidx 表示排序字段,sord 表示排序方式(DESC=降序,ASC=升序)
// 代码生成器生成时默认按照主键排序,您可以修改成按创建时间的字段降序
pagination: { rows: 10, page: this.page, sidx: 'Id', sord: 'DESC' },
queryJson: JSON.stringify(Object.assign(this.searchData,{StuNo:this.user.account}) ),
},
'加载数据时出错'
)
if (!result) { return }
this.total = result.total
this.page = result.page + 1
this.list = this.list.concat(result.rows)
// console.log(this.list)
this.tips = `已加载 ${Math.min(result.page, result.total)} / ${result.total} 页,共 ${result.records} 项`
this.loadState = result.page >= result.total ? '已加载所有项目' : '向下翻以加载更多'
},
// 刷新清空列表
async refreshList() {
this.page = 1
this.total = 2
this.list = []
await this.fetchList()
},
// 列表下拉
pullDown() {
this.refreshList().then(() => {
this.$refs.list.stopPullDown()
})
},
// 设置搜索条件
async searchChange() {
const result = {}
// 将其他查询项添加到查询 JSON 中
const queryObj = pickBy(this.queryData, t => (Array.isArray(t) ? t.length > 0 : t))
Object.assign(result, mapValues(queryObj, t => (Array.isArray(t) ? t.join(',') : t)))
this.searchData = result
await this.refreshList()
},
// 点击「清空查询条件」按钮
reset() {
this.queryData = this.COPY(this.defaultQueryData)
this.searchChange()
},
// 点击「编辑」、「查看」、「添加」、「删除」按钮
async action(type, id = '') {
switch (type) {
case 'view':
this.NAV_TO(`./single?type=view&id=${id}`)
return
case 'add':
this.NAV_TO('./single?type=create')
return
case 'edit':
this.NAV_TO(`./single?type=edit&id=${id}`)
return
case 'delete':
if (!(await this.CONFIRM('删除项目', '确定要删除该项吗?', true))) {
return
}
this.HTTP_POST('learun/adms/EducationalAdministration/StuAttendanceLeave/delete', id, '删除失败').then(success => {
if(!success) { return }
this.TOAST('删除成功', 'success')
this.refreshList()
})
return
default:
return
}
},
// 显示列表中的标题项
displayListItem(item, field) {
const fieldItem = this.scheme[field]
const value = item[field]
switch (fieldItem.type) {
case 'currentInfo':
case 'organize':
return fieldItem.dataType === 'time' ? value : get(this.GET_GLOBAL(fieldItem.dataType), `${value}.name`, '')
case 'radio':
case 'select':
const selectItem = this.dataSource[field].find(t => t.value === String(value))
return get(selectItem, 'text', '')
case 'checkbox':
if (!value || value.split(',').length <= 0) { return '' }
const checkboxItems = value.split(',')
return this.dataSource[field].filter(t => checkboxItems.includes(t.value)).map(t => t.text).join(',')
case 'datetime':
if (!value) { return '' }
return moment(value).format(Number(fieldItem.dateformat) === 0 ? 'YYYY年 M月 D日' : 'YYYY-MM-DD HH:mm')
default: return value === null || value === undefined ? '' : value
}
},
// 请假审核
LeaveCheckItem(data){
return data==1 ? '同意' : '不同意'
},
// 请假类型审核
LeaveTypeItem(data){
switch(data){
case'1':
return '事假';
break;
case'2':
return '病假';
break;
case'3':
return '婚假';
break;
case'4':
return '探亲假';
break;
case'5':
return '产假';
break;
case'6':
return '丧假';
break;
case'7':
return '补休';
break;
case'8':
return '公假';
break;
case'9':
return '其它';
break;
}
}
},
created() {
this.user = this.GET_GLOBAL('loginUser');
}
}
</script>
<style lang="less" scoped>
@import '~@/common/css/sidepage.less';
@import '~@/common/css/customlist.less';
</style>

+ 371
- 268
Learun.Framework.Ultimate V7/LearunApp-2.2.0/pages/studentCheck/list.vue View File

@@ -9,38 +9,45 @@
<text class="text-xxl cuIcon cuIcon-back" @click="timeTap(1)"></text>
<text>{{todayWeek.Monday}}</text>
-
<text>{{todayWeek.Sunday}}</text>
<text class="text-xxl cuIcon cuIcon-right" @click="timeTap(2)"></text>
<text>{{todayWeek.Sunday}} </text>
<text class="text-xxl cuIcon cuIcon-right" @click="timeTap(2)"></text>
</view>
</view>
<view class="timeTable_sec2">
<view class="tSec2Top2">
<view 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 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>
</view>
<view class="tSec2Box2">
<view class="tSec2Con2" v-for="(items, ind) in dataArr" :key="items.num" v-show="ind == num">
<view class="studCheckList">
<view class="studCheckLi" v-for="(k, index) in items.weekList" :key="k.LessonDate" v-if="items.weekList.length != 0">
<view class="studCheckT">
<view class="studCheckLi" v-for="(k, index) in items.weekList" :key="index"
v-if="items.weekList.length != 0">
<view class="studCheckT">
<image mode="widthFix" src="~@/common/images/book.png"></image>
{{ k.LessonName }}
</view>
<view class="studCheckTxt">
<view class="studCheckTxt">
<image src="~@/common/images/time.png" mode="widthFix"></image>
{{ k.LessonDate }}
<image style="margin:0 5px 0 30px" src="~@/common/images/person.png" mode="widthFix"></image>
<image style="margin:0 5px 0 30px" src="~@/common/images/person.png" mode="widthFix">
</image>
<text>
{{ k.Teacher }}
</text>
<image style="margin:0 5px 0 30px" src="~@/common/images/location.png" mode="widthFix"></image>
<image style="margin:0 5px 0 30px" src="~@/common/images/location.png" mode="widthFix">
</image>
{{ k.ClassRoomName }}
</view>
<view class="studCheckStatue" :class="k.Sort == '迟到'? 'studCheckStatue2' : k.Sort == '早退'? 'studCheckStatue2' : k.Sort == '病假'? 'studCheckStatue4' : k.Sort == '事假'? 'studCheckStatue2' : k.Sort == '准时'? 'studCheckStatue1' : 'studCheckStatue3' ">
</view>
<view class="studCheckStatue"
:class="k.Sort == '迟到'? 'studCheckStatue2' : k.Sort == '早退'? 'studCheckStatue2' : k.Sort == '病假'? 'studCheckStatue4' : k.Sort == '事假'? 'studCheckStatue2' : k.Sort == '准时'? 'studCheckStatue1' : 'studCheckStatue3' ">
<text></text> {{ k.Sort }}
</view>
</view>
</view>
<view class="noHtml" v-if="items.weekList.length == 0">
该时间段没有数据
@@ -53,268 +60,364 @@
</template>

<script>
import common from '@/common/js/common.js'
export default {
data() {
return {
semester: '',
num: 0,
weekDayTime: 0,
todayWeek: {},
dataArr: [],
weekArr: [
{
en: 'MON',
cn: '星期一'
},
{
en: 'TUE',
cn: '星期二'
},
{
en: 'WED',
cn: '星期三'
},
{
en: 'THU',
cn: '星期四'
import common from '@/common/js/common.js'
export default {
data() {
return {
semester: '',
num: 0,
user: null,
weekDayTime: 0,
noClassTime: 0,
todayWeek: {
Monday:'',
Sunday:''
},
{
en: 'FRI',
cn: '星期五'
},
{
en: 'SAT',
cn: '星期六'
},
{
en: 'SUN',
cn: '星期日'
}
]
};
},
methods: {
async init() {
let _this = this;
_this.todayWeek = common.weekday();
_this.semester = common.judgeDate();
_this.weekDayTime = 7 * common.oneDayTime();
_this.studentCheckData(_this.todayWeek.Monday, _this.todayWeek.Sunday);
dataArr: [],
itemcs:'',
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: '星期十'
}
]
// weekArr: [
// {
// en: 'MON',
// cn: '星期一'
// },
// {
// en: 'TUE',
// cn: '星期二'
// },
// {
// en: 'WED',
// cn: '星期三'
// },
// {
// en: 'THU',
// cn: '星期四'
// },
// {
// en: 'FRI',
// cn: '星期五'
// },
// {
// en: 'SAT',
// cn: '星期六'
// },
// {
// en: 'SUN',
// cn: '星期日'
// }
// ]
};
},
studentCheckData(Monday, Sunday) {
// var studCheckList = $('.studCheckList');
let _this = this;
_this.LOADING('加载数据中…')
_this.HTTP_GET(
'learun/adms/timetable/StuLessonInfo',
{StartDate:Monday, EndDate:Sunday},
'加载数据时出错'
).then( res => {
_this.HIDE_LOADING()
//console.log(res)
_this.dataArr.length = 0;
for(let j = 1; j < 8; j++){
let dataFlag = true;
var num = Math.floor(Math.random() * 100000000);
res.forEach((n, i) => {
if(n.week == j){
n.num = num;
_this.dataArr.push(n);
dataFlag = false;
return
methods: {
async init() {
let _this = this;
// _this.todayWeek = common.weekday();
// _this.semester = common.judgeDate();
_this.weekDayTime = 14 * common.oneDayTime();
_this.noClassTime = 4 * common.oneDayTime();
_this.studentCheckData();
},
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;
}
_this.num = 0;
_this.todayWeek.Sunday = common.fmtDate(_this.todayWeek.SundayTime);
_this.todayWeek.Monday = common.fmtDate(_this.todayWeek.MondayTime);
// _this.semester = common.judgeDate(_this.todayWeek.SundayTime);
_this.studentCheckData(_this.todayWeek.Monday, _this.todayWeek.Sunday);
},
studentCheckData(start, end) {
// var studCheckList = $('.studCheckList');
let _this = this;
_this.LOADING('加载数据中…')
_this.HTTP_GET(
'learun/adms/timetable/StuLessonInfo', {
StartDate: start,
EndDate: end
},
'加载数据时出错'
).then(res => {
_this.HIDE_LOADING()
_this.semester = res.semester
// 回显日期
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);
}
console.log(res)
_this.dataArr.length = 0;
for(let j = 1; j < 8; j++){
let dataFlag = true;
var num = Math.floor(Math.random() * 100000000);
res.results.forEach((n, i) => {
if(n.week == j){
n.num = num;
_this.dataArr.push(n);
dataFlag = false;
return
}
})
if(dataFlag){
_this.dataArr.push({
week: j,
num: num,
weekList: []
});
}
})
if(dataFlag){
_this.dataArr.push({
week: j,
num: num,
weekList: []
});
}
}
})
},
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;
}
_this.todayWeek.Monday = common.fmtDate(_this.todayWeek.MondayTime);
_this.todayWeek.Sunday = common.fmtDate(_this.todayWeek.SundayTime);
_this.semester = common.judgeDate(_this.todayWeek.SundayTime);
_this.studentCheckData(_this.todayWeek.Monday, _this.todayWeek.Sunday);
created() {
this.user = this.GET_GLOBAL('loginUser');
this.init()
}
},
created() {
this.init()
}
};

};
</script>

<style lang="less" scoped>
* {
box-sizing: border-box;
}
.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;
}
#semester2 {
margin-bottom: 10px;
}

#weekTime2 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;
}
.tSec2Top2 {
padding: 0 12px;
background: #0075c4;
height: 55px;
text-align: center;
overflow: hidden;
}
.tSec2Top2 view {
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;
}
.tSec2Top2 view:first-child {
border-left: 1px solid #1084d2;
}
.tSec2Top2 view.active {
color: #0075c4;
background: #fff;
border-color: #fff;
}
.tSec2Top2 view text {
display: block;
}

.tSec2Top2 view text:first-child {
letter-spacing: 2px;
text-transform: uppercase;
}
.tSec2Box2 {
background: #fff;
}

.studCheckLi {
border-bottom: 1px solid #d5eaf7;
padding: 8px 12px;
font-size: 15px;
}
.studCheckT {
font-size: 15px;
color: #6e6e6e;
}
.studCheckT image {
width: 11px;
position: relative;
margin-right: 5px;
}
.studCheckTxt {
font-size: 13px;
color: #9d9e9e;
margin: 7px 0;
}
.studCheckTxt text {
// margin: 0 30px;
}
.studCheckTxt image {
width: 12px;
position: relative;
margin-right: 3px;
top: 1px;
}
.studCheckStatue {
font-size: 13px;
}
.studCheckStatue text {
display: inline-block;
width: 8px;
height: 8px;
position: relative;
margin-right: 5px;
vertical-align: middle;
top: -2px;
}
.studCheckStatue1 {
color: #0089fe;
}
.studCheckStatue1 text {
background: #0089fe;
}
.studCheckStatue2 {
color: #f2b60a;
}
.studCheckStatue2 text {
background: #f2b60a;
}
.studCheckStatue3 {
color: #e24545;
}
.studCheckStatue3 text {
background: #e24545;
}
.studCheckStatue4 {
color: #29cf41;
}
.studCheckStatue4 text {
background: #29cf41;
}
.noHtml {
height: 100%;
line-height: 60px;
text-align: center;
font-size: 14px;
}
* {
box-sizing: border-box;
}

.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;
}

#semester2 {
margin-bottom: 10px;
}

#weekTime2 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;
}

.tSec2Top2 {
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;
}

.tSec2Box2 {
background: #fff;
}

.studCheckLi {
border-bottom: 1px solid #d5eaf7;
padding: 8px 12px;
font-size: 15px;
}

.studCheckT {
font-size: 15px;
color: #6e6e6e;
}

.studCheckT image {
width: 11px;
position: relative;
margin-right: 5px;
}

.studCheckTxt {
font-size: 13px;
color: #9d9e9e;
margin: 7px 0;
}

.studCheckTxt text {
// margin: 0 30px;
}

.studCheckTxt image {
width: 12px;
position: relative;
margin-right: 3px;
top: 1px;
}

.studCheckStatue {
font-size: 13px;
}

.studCheckStatue text {
display: inline-block;
width: 8px;
height: 8px;
position: relative;
margin-right: 5px;
vertical-align: middle;
top: -2px;
}

.studCheckStatue1 {
color: #0089fe;
}

.studCheckStatue1 text {
background: #0089fe;
}

.studCheckStatue2 {
color: #f2b60a;
}

.studCheckStatue2 text {
background: #f2b60a;
}

.studCheckStatue3 {
color: #e24545;
}

.studCheckStatue3 text {
background: #e24545;
}

.studCheckStatue4 {
color: #29cf41;
}

.studCheckStatue4 text {
background: #29cf41;
}

.noHtml {
height: 100%;
line-height: 60px;
text-align: center;
font-size: 14px;
}
</style>

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

@@ -14,10 +14,10 @@
<l-input title="班级名称" placeholder="请填写班级名称" :value="queryData.ClassName" disabled right />
<l-input hidden title="课程号" placeholder="请填写课程号" :value="queryData.LessonNo" disabled right />
<l-input title="课程名称" placeholder="请填写课程名称" :value="queryData.LessonName" disabled right />
<l-input hidden title="课程类别码" placeholder="请填写课程类别码" :value="queryData.LessonSortNo" disabled right />
<l-input hidden title="课程类别码" placeholder="请填写课程类别码" :value="queryData.lessonSortNo" disabled right />
<l-input title="课程类别" placeholder="请填写课程类别" :value="queryData.LessonSortName" disabled right />
<l-input hidden title="教室码" placeholder="请填写教室码" :value="queryData.ClassRoomNo" disabled right />
<l-input hidden title="教室码" placeholder="请填写教室码" :value="queryData.classRoomNo" disabled right />
<l-input title="教室名称" placeholder="请填写教室名称" :value="queryData.ClassroomName" disabled right />
<l-input title="原上课日期" placeholder="请填写原上课日期" :value="queryData.LessonDate" disabled right />
<l-input title="上课时间" placeholder="请填写上课时间" :value="queryData.LessonTime" disabled right />
@@ -61,12 +61,12 @@ export default {
dataSource: '1',
dataSourceId: 'BaseUser,f_realname,f_userid'
},
LessonSortNo: {
lessonSortNo: {
type: 'select',
dataSource: '1',
dataSourceId: 'BaseUser,f_realname,f_userid'
},
ClassRoomNo: {
classRoomNo: {
type: 'select',
dataSource: '1',
dataSourceId: 'BaseUser,f_realname,f_userid'
@@ -77,8 +77,8 @@ export default {
MajorNo: [],
ClassNo: [],
LessonNo: [],
LessonSortNo: [],
ClassRoomNo: [],
lessonSortNo: [],
classRoomNo: [],
LeaveType: Object.values(this.GET_GLOBAL('dataDictionary').LeaveType).map(t => ({ value: t.value, text: t.text }))
},
pageInfo: null,
@@ -99,9 +99,9 @@ export default {
ClassName: '',
LessonNo: '',
LessonName: '',
LessonSortNo: '',
lessonSortNo: '',
LessonSortName: '',
ClassRoomNo: '',
classRoomNo: '',
ClassroomName: '',
LessonDate: '',
LessonTime: '',
@@ -143,22 +143,24 @@ export default {
}));
}),
this.FETCH_DATASOURCE('CdLessonSort').then(data => {
// console.log(data)
this.dataSource.LessonSortNo = data.data.map(t => ({
console.log(data)
return this.dataSource.lessonSortNo = data.data.map(t => ({
text: t.lessonsortname,
value: t.lessonsortno
}));
}),
this.FETCH_DATASOURCE('ClassRoomInfo').then(data => {
// console.log(data)
this.dataSource.ClassRoomNo = data.data.map(t => ({
this.dataSource.classRoomNo = data.data.map(t => ({
text: t.classroomname,
value: t.classroomno
value: t.classRoomNo
}));
}),
() => {}
]);
]).then(res=>{
console.log(res)
});
this.userinfo = this.GET_GLOBAL('loginUser'); //获取登录信息
this.pageInfo = this.GET_PARAM(); //获取页面传递参数
@@ -170,12 +172,12 @@ export default {
this.HIDE_LOADING();
this.data = res;
// console.log(res)
this.queryData.AcademicYearNo = this.pageInfo.AcademicYear;
this.queryData.Semester = this.pageInfo.Semester;
this.queryData.AcademicYearNo = this.pageInfo.academicyear;
this.queryData.Semester = this.pageInfo.semester;
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;
@@ -185,16 +187,18 @@ export default {
this.queryData.Remark = res.Remark;
this.queryData.LeaveType = '1';
this.queryData.LessonNo = this.pageInfo.LessonNo;
this.queryData.LessonName = this.displayListItem(this.pageInfo, 'LessonNo');
this.queryData.LessonNo = this.pageInfo.lessonNo;
// this.queryData.LessonName = this.displayListItem(this.pageInfo, 'LessonNo');
this.queryData.LessonName =this.pageInfo.curriculum;
this.queryData.lessonSortNo = this.pageInfo.lessonSortNo;
this.queryData.LessonSortName = this.displayListItem(this.pageInfo, 'lessonSortNo');
this.queryData.LessonSortNo = this.pageInfo.LessonSortNo;
this.queryData.LessonSortName = this.displayListItem(this.pageInfo, 'LessonSortNo');
this.queryData.classRoomNo = this.pageInfo.classRoomNo;
// this.queryData.ClassroomName = this.displayListItem(this.pageInfo, 'classRoomNo');
this.queryData.ClassroomName = this.pageInfo.classRoom;
this.queryData.ClassRoomNo = this.pageInfo.ClassRoomNo;
this.queryData.ClassroomName = this.displayListItem(this.pageInfo, 'ClassRoomNo');
this.queryData.LessonDate = this.pageInfo.LessonDate;
this.queryData.LessonTime = this.pageInfo.LessonTime;
this.queryData.LessonDate = this.pageInfo.lessonDate;
this.queryData.LessonTime = this.pageInfo.lessonTime;
// console.log(res);
// console.log(this.pageInfo);
console.log(this.queryData);
@@ -220,7 +224,10 @@ export default {
displayListItem(item, field) {
const fieldItem = this.scheme[field];
const value = item[field];
switch (fieldItem.type) {
case 'currentInfo':
case 'organize':


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

@@ -186,7 +186,8 @@
return courseCateByDay;
},
classTap(data) {
return ""
// return ""
console.log(data)
let _this = this;
// console.log(_this.user)
if (_this.user.Description == "教师") {


Loading…
Cancel
Save