Browse Source

教师课堂考勤 修改

master
zhichao lei 3 years ago
parent
commit
0954aa96ea
1 changed files with 4 additions and 5 deletions
  1. +4
    -5
      Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/studentAttendance/form/form.js

+ 4
- 5
Learun.Framework.Ultimate V7/Learun.Application.Mobile/www/pages/studentAttendance/form/form.js View File

@@ -5,7 +5,6 @@
init: function ($page, param) {
//console.log(param) 传过来的参数 在param上
//初始化
console.log(param);
loadData(param);
$('.tSec3Time').html('<span></span>' + param.LessonDate + ' 第' + param.LessonTime.substring(1) + '节<span></span>');
$('.tSec4T').html('<div>' +
@@ -18,7 +17,6 @@
function () {
var that = $(this);
var jsons = JSON.parse(that.attr('student'));
// console.log(jsons)
var type = that.attr('class');
type = type.length == 0 ? 'sStatue1' : type;
that.addClass('active');
@@ -48,13 +46,13 @@

$(".timeTableList li").each(function () {
var keType = $(this).attr("kqtype") ? $(this).attr("kqtype") : "0";
console.log(keType);
var object = JSON.parse($(this).attr("student"));
object.kqType = keType;
rowData.push(object);
})

var jsonObj = JSON.parse(JSON.stringify(rowData));
console.log(JSON.stringify(jsonObj));

learun.layer.confirm('是否确认提交考勤?',
function (num) {
@@ -102,7 +100,6 @@
)
};
learun.httpget(config.webapi + "/teachattendance/students", _postParam, (data) => {
console.log(data);
studentCheckData(data, param)
})
}
@@ -114,7 +111,9 @@
} else {
$.each(weekData2.rows, function (j, k) {
var statusName = !k.Sort ? 'sStatue1' : k.Sort == "准时" ? 'sStatue1' : k.Sort == "早退" ? 'sStatue2' : k.Sort == "旷课" ? 'sStatue3' : k.Sort == "病假" ? 'sStatue4' : k.Sort == "迟到" ? 'sStatue5' : 'sStatue6';
html += '<li student=' + JSON.stringify(k) + ' class="' + statusName + '"><div>' +
var sktype = !k.Sort ? '0' : k.Sort == "准时" ? '0' : k.Sort == "早退" ? '2' : k.Sort == "旷课" ? '5' : k.Sort == "病假" ? '3' : k.Sort == "迟到" ? '1' : '4';
k.kqType=sktype;
html += '<li student=' + JSON.stringify(k) + ' class="' + statusName + '" kqtype="'+sktype+'"><div>' +
k.StuName + '<span class="iconfont icon-check"></span>' +
'</div></li>';
})


Loading…
Cancel
Save