董佳音

修改判断邮箱长度,个人中心显示页码,收藏

... ... @@ -195,13 +195,17 @@ body{
.userLoginText{
height: 70px;
line-height: 70px;
max-width: 85px;
display: inline-block;
overflow: hidden;
text-align: center;
}
.userLoginText:hover{
color:#3498db;
}
.exitBox{
position: absolute;
left:-48px;
left:-25px;
top:55px;
width:130px;
height:78px;
... ... @@ -1281,6 +1285,7 @@ body{
left: 50%;
right: 50%;
background: #fff;
border-radius: 3px;
}
.userLogin{
height:420px;
... ... @@ -1568,6 +1573,11 @@ body{
padding-top:5px;
padding-bottom:6px;
}
.teacherMyCenterName{
max-width: 100px;
float: left;
overflow: hidden;
}
.teacherMyCenter2{
float: left;
width: 100%;
... ... @@ -2051,6 +2061,10 @@ body{
color: #999999;
padding-left: 15px;
}
.myCenterErrorTitle{
font-size: 14px;
color: #999999;
}
/*上传图片*/
.updataPhoto{
width:450px;
... ...
... ... @@ -133,74 +133,12 @@
<div class="classifyListContent" id="lanclassContent">
</div>
<div class="pageNumContentBox" id="lanclassPageBox">
<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0">
<tbody>
<tr>
<td height="60" colspan="11" class="tr_bottom" style="">
<span class="classHandlerPageMsg" id="pageNumContentMsg" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span class="classHandlerHomePage" id="pageNumContentHomePage">首页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerUpPage" id="pageNumContentUpPage">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerDownPage" id="pageNumContentDownPage">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerEndPage" id="pageNumContentEndPage">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="pageNumContentPageInfoInput" class="classHandlerPageInfoInput" type="text">
</li>
<li class="classHandlerPageInfo classHandlerPageInfoCheck">
<span id="pageNumContentSpecificPage">GO</span>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<!--推荐老师-->
<div class="classifyListBox" id="teacherIntroAllBox">
<div class="classifyListTitle" id="teacherIntroTitle">推荐老师</div>
<div class="classifyListContent" id="teacherIntroContent">
</div>
<div class="pageNumContentBox" id="teacherIntroPageBox">
<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0">
<tbody>
<tr>
<td height="60" colspan="11" class="tr_bottom" style="">
<span class="classHandlerPageMsg" id="pageNumContentMsg" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span class="classHandlerHomePage" id="pageNumContentHomePage">首页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerUpPage" id="pageNumContentUpPage">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerDownPage" id="pageNumContentDownPage">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerEndPage" id="pageNumContentEndPage">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="pageNumContentPageInfoInput" class="classHandlerPageInfoInput" type="text">
</li>
<li class="classHandlerPageInfo classHandlerPageInfoCheck">
<span id="pageNumContentSpecificPage">GO</span>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<!--直播课堂详情-->
<div class="lanclassBox" id="lanclassBox">
... ... @@ -1533,7 +1471,7 @@
<img class="teacherMyCenterImg" id="myCenterImg" src="images/u373.png" alt="">
<p class="teacherMyCenterInfoBox">
<span class="teacherMyCenterInfo" id="teacherMyCenterTime">上午好,</span>
<span id="teacherMyCenterName"></span>
<span id="teacherMyCenterName" class="teacherMyCenterName"></span>
<span id="teacherMyCenterStatus"></span>
</p>
</div>
... ... @@ -1936,7 +1874,7 @@
<span class="requiredMsg">*</span>
</li>
<li class="usersignLi">
<input id="signMail" class="userMailInput usersignInput" type="text" placeholder="填写邮箱" maxlength="20"
<input id="signMail" class="userMailInput usersignInput" type="text" placeholder="填写邮箱" maxlength="40"
onkeyup="this.value=this.value.replace(/^ +| +$/g,'')">
</li>
<li class="usersignNameLi usersignLi">
... ... @@ -1972,7 +1910,7 @@
<ul>
<li class="usersignTit">登录</li>
<li class="usersignNameLi usersignLi">
<input id="loginName" class="usersignInput classThemeInfo" type="text" placeholder="手机/用户名/邮箱" value="" maxlength="20"
<input id="loginName" class="usersignInput classThemeInfo" type="text" placeholder="用户名/邮箱" value="" maxlength="40"
onkeyup="this.value=this.value.replace(/^ +| +$/g,'')">
</li>
<li class="userPassWordLi usersignLi">
... ...
... ... @@ -89,7 +89,6 @@ class CollectApe extends Ape {
'token':ClassDataProxy.token},
success:function(_data){
//获取我的课程数据
loger.log('收藏数据信息',_data)
if(_data && _data.code){
if(callback){
callback(_data);
... ...
... ... @@ -42,6 +42,7 @@ class ListDetailsApe extends Ape {
let _id = $(evt.currentTarget).attr('data');
this._id = _id;
this.classInfoDetail(_id);
this.collectInfoDetail(_id);
this.commonalityClass();
//查看当前点击的列表是否收藏
this._emit(MessageTypes.IS_COLLECT,{id : _id});
... ...
... ... @@ -185,7 +185,7 @@ class LoginOrRegister extends Ape {
}
}
_signMail(mail){
let filter = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
let filter = /^([a-zA-Z0-9]+[_|\-|\.]?)*[a-zA-Z0-9]+@([a-zA-Z0-9]+[_|\-|\.]?)*[a-zA-Z0-9]+(\.[a-zA-Z]{2,3})+$/;
if(mail.value == ''){
ClassDataProxy.getMarginTopHandler($('#warnHintBox'));
ErrorApe.showWarnError('邮箱不能为空');
... ... @@ -329,7 +329,7 @@ class LoginOrRegister extends Ape {
//登录信息提交
_loginBtnHandler(){
let _name = document.getElementById("loginName");//用户名
let _passWord = document.getElementById("loginPassWord");//手机号
let _passWord = document.getElementById("loginPassWord");//密码
if(_name.value && _passWord.value){
let signInfo = {
"loginName": _name.value, // 登录名
... ... @@ -350,7 +350,7 @@ class LoginOrRegister extends Ape {
ClassDataProxy.getMarginTopHandler($('#warnHintBox'));
ErrorApe.showWarnError('登录成功');
ClassDataProxy.userType= _data.returnData.data.userType;
ClassDataProxy.loginName =_name.value;
ClassDataProxy.loginName = _data.returnData.data.userName;
ClassDataProxy.password = _passWord.value;
ClassDataProxy.token =_data.returnData.data.token
ClassDataProxy.userPhoto = _data.returnData.data.userPhoto;
... ...
... ... @@ -465,35 +465,50 @@ class MyCenterApe extends Ape {
}
//老师端首页课程数据渲染
_teacherCourseCourse(_data){
let myCurriculumInfo = $('#myCurriculumInfo');
if(_data){
let myCurriculumInfo = $('#myCurriculumInfo');
let that = this;
setInterval(function () {
myCurriculumInfo.empty();
for (let i = 0; i < _data.length; i++) {
let item = _data[i];
if (item) {
let lastTimer = 0;
let timer = ClassDataProxy.getTimeCountDown(item.meetingBeginTime, item.meetingEndTime)
if(timer.indexOf('|') !=-1){
timer = timer.substr(0,timer.length-1);
lastTimer = 1;
}else if(timer.indexOf('.') !=-1){
timer = timer.substr(0,timer.length-1);
lastTimer = 0;
let timerNew = null;
let newTimeDateList = [];
for(let j = 0;j<_data.length; j++){
if (ClassDataProxy.getTimeDay(_data[j].meetingEndTime)) {
newTimeDateList.push(_data[j])
}
}
loger.log('老师端数据',newTimeDateList)
if(newTimeDateList.length > 0){
setInterval(function () {
myCurriculumInfo.empty();
for (let i = 0; i < _data.length; i++) {
let item = _data[i];
if (item) {
let lastTimer = 0;
let timer = ClassDataProxy.getTimeCountDown(item.meetingBeginTime, item.meetingEndTime)
if(timer.indexOf('|') !=-1){
timer = timer.substr(0,timer.length-1);
lastTimer = 1;
}else if(timer.indexOf('.') !=-1){
timer = timer.substr(0,timer.length-1);
lastTimer = 0;
}
let curInfo = that._format(curriculumList, {
_infoTit: item.meetingName,
_meetingNumber: item.meetingId,
_countDown: timer,
_isShow: (lastTimer == 1) ? 'none' : 'block'
})
myCurriculumInfo.append(curInfo);
} else {
console.error('_gainClassData没数据')
}
let curInfo = that._format(curriculumList, {
_infoTit: item.meetingName,
_meetingNumber: item.meetingId,
_countDown: timer,
_isShow: (lastTimer == 1) ? 'none' : 'block'
})
myCurriculumInfo.append(curInfo);
} else {
console.error('_gainClassData没数据')
}
}
},1000)
},1000)
}else{
clearInterval(timerNew);
let _classifyList = '<div class="myCenterErrorTitle">暂无数据~</div>';
myCurriculumInfo.empty();
myCurriculumInfo.append(_classifyList)
}
}
}
//老师端首页直播数据
... ... @@ -614,36 +629,51 @@ class MyCenterApe extends Ape {
})
}
studentCourseList(_data){
let myCurriculumInfo = $('#myCurriculumInfo');
if(_data){
let myCurriculumInfo = $('#myCurriculumInfo');
let that = this;
setInterval(function () {
myCurriculumInfo.empty();
for (let i = 0; i < _data.length; i++) {
let item = _data[i];
if (item) {
let lastTimer = 0;
let timer = ClassDataProxy.getTimeCountDown(item.meetingBeginTime, item.meetingEndTime)
if(timer.indexOf('|') !=-1){
timer = timer.substr(0,timer.length-1);
lastTimer = 1;
}else if(timer.indexOf('.') !=-1){
timer = timer.substr(0,timer.length-1);
lastTimer = 0;
}
let curInfo = that._format(curriculumList, {
_infoTit: item.meeting_name,
_meetingNumber: item.meetingId,
_countDown: timer,
_isShow: (lastTimer == 1) ? 'none' : 'block'
})
let timerNew = null;
let newTimeDateList = [];
for(let j = 0;j<_data.length; j++){
if (ClassDataProxy.getTimeDay(_data[j].meetingEndTime)) {
newTimeDateList.push(_data[j])
}
}
if(newTimeDateList.length > 0){
timerNew = setInterval(function () {
myCurriculumInfo.empty();
for (let i = 0; i < newTimeDateList.length; i++) {
let item = newTimeDateList[i];
if (item) {
let lastTimer = 0;
let timer = ClassDataProxy.getTimeCountDown(item.meetingBeginTime, item.meetingEndTime)
if(timer.indexOf('|') !=-1){
timer = timer.substr(0,timer.length-1);
lastTimer = 1;
}else if(timer.indexOf('.') !=-1){
timer = timer.substr(0,timer.length-1);
lastTimer = 0;
}
let curInfo = that._format(curriculumList, {
_infoTit: item.meeting_name,
_meetingNumber: item.meetingId,
_countDown: timer,
_isShow: (lastTimer == 1) ? 'none' : 'block'
})
myCurriculumInfo.append(curInfo);
} else {
console.error('_gainClassData没数据')
} else {
console.error('_gainClassData没数据')
}
}
}
},1000)
},1000)
}else{
clearInterval(timerNew);
let _classifyList = '<div class="myCenterErrorTitle">暂无数据~</div>';
myCurriculumInfo.empty();
myCurriculumInfo.append(_classifyList)
}
}
}
//学生端首页 待学习数据
_studentStudyModule(){
... ... @@ -706,6 +736,7 @@ class MyCenterApe extends Ape {
studentStudyOverList(studentMyCenterContentList,_data){
studentMyCenterContentList.empty();
$('#courseMinutePageBox').hide();
let recordData = 0;
if(_data){
for(let i = 0;i<_data.length;i++){
if(_data[i]){
... ... @@ -725,12 +756,17 @@ class MyCenterApe extends Ape {
_liveTimer : _data[i].meetingBeginTime.split(' ')[0]
})
studentMyCenterContentList.append(_classifyList)
recordData = 1;
}
}else{
console.error('_gainClassData没数据')
}
}
}
if(recordData == 0){
let _classifyList = '<div class="dataCenterErrorTitle">暂无数据~</div>';
studentMyCenterContentList.append(_classifyList)
}
}
//收藏
_studenTcollectModule(){
... ... @@ -747,6 +783,7 @@ class MyCenterApe extends Ape {
studentTcollectList(studentMyCenterContentList,_data){
studentMyCenterContentList.empty();
$('#courseMinutePageBox').hide();
let recordData = 0;
if(_data){
for(let i = 0;i<_data.length;i++){
if(_data[i]){
... ... @@ -766,13 +803,17 @@ class MyCenterApe extends Ape {
_liveTimer : _data[i].meetingBeginTime.split(' ')[0]
})
studentMyCenterContentList.append(_classifyList)
recordData = 1;
}
}else{
console.error('_gainClassData没数据')
}
}
}
if(recordData == 0){
let _classifyList = '<div class="dataCenterErrorTitle">暂无数据~</div>';
studentMyCenterContentList.append(_classifyList)
}
}
clearLocalStorage(){
window.localStorage.clear();
... ...
... ... @@ -248,7 +248,7 @@ class MyCoursesApe extends Ape {
let courseMinuteList = $('#courseMinuteList');
let card = $('#teacherLiveList .liveInfoLeftLiCheck').index();
$('#courseMinutePage').attr('data',ind)
$('#courseMinutePageBox'+card).show().siblings().hide();
$('.classHandlerPageBox').hide();
this.presentIndT = 1;
switch (parseInt(ind)){
case 1:
... ... @@ -338,8 +338,8 @@ class MyCoursesApe extends Ape {
let _dataList = _data.meetingInfo;
this.pageNoT = pagenum;
$('#courseMinutePageMsg0').html('第'+page+'页/共'+pagenum+'页,有'+count+'个记录');
if(count <=8){
$('#courseMinutePageBox0').hide();
if(count >=8){
$('#courseMinutePageBox0').show().siblings().hide();
}
}
}
... ... @@ -352,8 +352,8 @@ class MyCoursesApe extends Ape {
let _dataList = _data.meetingInfo;
this.pageNoT = pagenum;
$('#courseMinutePageMsg1').html('第'+page+'页/共'+pagenum+'页,有'+count+'个记录');
if(count <=8){
$('#courseMinutePageBox1').hide();
if(count >=8){
$('#courseMinutePageBox1').show().siblings().hide();
}
}
}
... ... @@ -366,8 +366,8 @@ class MyCoursesApe extends Ape {
let _dataList = _data.meetingInfo;
this.pageNoT = pagenum;
$('#courseMinutePageMsg2').html('第'+page+'页/共'+pagenum+'页,有'+count+'个记录');
if(count <=8){
$('#courseMinutePageBox2').hide();
if(count >=8){
$('#courseMinutePageBox2').show().siblings().hide();
}
}
}
... ...