董佳音

修改预约模块 整理管理员列表切换

... ... @@ -711,6 +711,7 @@ body{
.classManagementRight{
width: 998px;
float: left;
display: none;
}
.addUserBtn{
width:100px;
... ... @@ -721,7 +722,6 @@ body{
font-size: 14px;
margin-bottom:8px;
cursor: pointer;
display: none;
}
.addUserIcon{
background: url("../images/add.png") no-repeat;
... ... @@ -798,6 +798,7 @@ body{
border-radius: 2px;
margin-top: 8px;
float: left;
font-size: 12px;
text-align: center;
}
.classManagementRightContent{
... ... @@ -816,7 +817,7 @@ body{
font-size: 12px;
color: #333333;
border-bottom:1px solid #e6e6e6;
line-height: 42px;
padding-top:10px;
}
.tr_mainLeft{
border-left:1px solid #e6e6e6;
... ... @@ -828,6 +829,9 @@ body{
margin: 0 3px;
color:#3498db;
}
.classHandlePort1{
margin: 0 12px;
}
.classHandlerPageMsg{
font-size: 12px;
color: #333333;
... ... @@ -1884,7 +1888,7 @@ body{
.userClass{
height: 535px;
}
/*用户注册信息*/
.userClassList{
display: none;
.classHandleThen{
color:#ccc;
}
... ...
... ... @@ -243,7 +243,7 @@
</div>
</div>
</div>
<!--预约老师弹窗-->
<!--预约老师成功弹窗-->
<div class="userSignBox" id="teacherDetailRemindersBox">
<div class="usersign teacherDetailReminders" id="teacherDetailReminders">
<a href="javascript: void(0)" id="teacherDetailRemindersA" class="usersignA iconfont">&#xe638;</a>
... ... @@ -297,35 +297,257 @@
</li>
</ul>
</div>
<div class="classManagementRight" id="classManagementRight">
<div class="addUserBtn" id="addUserBtn">
<label class="addUserIcon"></label>
<span class="addUserText">添加用户</span>
<div class="classManagementRightMian">
<div class="classManagementRight" id="classManagementRight0">
<div class="classManagementRightTitle" id="classManagementRightTitle0">
<ul class="liveInfoLeft" id="liveInfoList0">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">正在直播</li>
<li class="liveInfoLeftLi">未开始</li>
<li class="liveInfoLeftLi">已结束</li>
</ul>
<div class="liveInfoRight" id="liveInfoRight0">
<input class="liveInfoRightInput" id="liveInfoRightInput0" type="text">
<img class="liveInfoRightInputBtn" id="liveInfoRightInputBtn0" src="images/nav_link_14.png" alt="">
</div>
<div class="liveInfoCenter" id="liveInfoCenter0">
<span class="liveInfoCenterTime">时间</span>
<div class="liveInfoCenterLiveCase liveInfoCenterLiveStart" id="liveInfoCenterLiveStart0"></div>
<span class="liveInfoCenterTime"></span>
<div class="liveInfoCenterLiveCase liveInfoCenterLiveEnd" id="liveInfoCenterLiveEnd0"></div>
</div>
</div>
<div class="classManagementRightContent" id="courseContent0">
</div>
<div class="classHandlerPageBox" id="classHandlerPageBox0">
<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="classHandlerPageMsg0" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span class="classHandlerHomePage" id="classHandlerHomePage0">首页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerUpPage" id="classHandlerUpPage0">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerDownPage" id="classHandlerDownPage0">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerEndPage" id="classHandlerEndPage0">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="classHandlerPageInfoInput0" class="classHandlerPageInfoInput" type="text">
</li>
<li class="classHandlerPageInfo classHandlerPageInfoCheck">
<span id="classHandlerSpecificPage0">GO</span>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="classManagementRightTitle" id="classManagementRightTitle">
<ul class="liveInfoLeft" id="liveInfoList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">正在直播</li>
<li class="liveInfoLeftLi">未开始</li>
<li class="liveInfoLeftLi">已结束</li>
</ul>
<ul class="liveInfoLeft userClassList" id="userClassList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">全部课堂</li>
<li class="liveInfoLeftLi">问题课堂</li>
</ul>
<div class="liveInfoRight" id="liveInfoRight">
<input class="liveInfoRightInput" id="liveInfoRightInput" type="text">
<img class="liveInfoRightInputBtn" id="liveInfoRightInputBtn" src="images/nav_link_14.png" alt="">
<div class="classManagementRight" id="classManagementRight2">
<div class="classManagementRightTitle" id="classManagementRightTitle2">
<div class="liveInfoRight" id="liveInfoRight2">
<input class="liveInfoRightInput" id="liveInfoRightInput2" type="text">
<img class="liveInfoRightInputBtn" id="liveInfoRightInputBtn2" src="images/nav_link_14.png" alt="">
</div>
</div>
<div class="liveInfoCenter" id="liveInfoCenter">
<span class="liveInfoCenterTime">时间</span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveStart"></div>
<span class="liveInfoCenterTime"></span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveEnd"></div>
<div class="classManagementRightContent" id="courseContent2">
<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="9%" class="tr_center">
课堂主题
</th>
<th width="8%" class="tr_center">
课堂号
</th>
<th width="8%" class="tr_center">
老师
</th>
<th width="6%" class="tr_center">
课堂状态
</th>
<th width="24%" class="tr_center">
课堂时间
</th>
<th width="6%" class="tr_center">
在线人数
</th>
<th width="22%" class="tr_center">
操作
</th>
</tr>
</tbody>
</table>
</div>
<div class="classHandlerPageBox" id="classHandlerPageBox2">
<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="classHandlerPageMsg2" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span class="classHandlerHomePage" id="classHandlerHomePage2">首页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerUpPage" id="classHandlerUpPage2">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerDownPage" id="classHandlerDownPage2">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerEndPage" id="classHandlerEndPage2">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="classHandlerPageInfoInput2" class="classHandlerPageInfoInput" type="text">
</li>
<li class="classHandlerPageInfo classHandlerPageInfoCheck">
<span id="classHandlerSpecificPage2">GO</span>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="classManagementRightContent" id="courseContent">
<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" id="t_box" class="t_box">
<tbody>
<div class="classManagementRight" id="classManagementRight3">
<div class="addUserBtn" id="addUserBtn">
<label class="addUserIcon"></label>
<span class="addUserText">添加用户</span>
</div>
<div class="classManagementRightTitle" id="classManagementRightTitle3">
<ul class="liveInfoLeft userClassList" id="userClassList3">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">老师</li>
<li class="liveInfoLeftLi">学生</li>
<li class="liveInfoLeftLi">兼课</li>
</ul>
<div class="liveInfoRight" id="liveInfoRight3">
<input class="liveInfoRightInput" id="liveInfoRightInput3" type="text">
<img class="liveInfoRightInputBtn" id="liveInfoRightInputBtn3" src="images/nav_link_14.png" alt="">
</div>
</div>
<div class="classManagementRightContent" id="courseContent3">
</div>
<div class="classHandlerPageBox" id="classHandlerPageBox3">
<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="classHandlerPageMsg3" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span class="classHandlerHomePage" id="classHandlerHomePage3">首页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerUpPage" id="classHandlerUpPage3">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerDownPage" id="classHandlerDownPage3">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerEndPage" id="classHandlerEndPage3">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="classHandlerPageInfoInput3" class="classHandlerPageInfoInput" type="text">
</li>
<li class="classHandlerPageInfo classHandlerPageInfoCheck">
<span id="classHandlerSpecificPage3">GO</span>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="classManagementRight" id="classManagementRight4">
<div class="classManagementRightTitle" id="classManagementRightTitle4">
<ul class="liveInfoLeft userClassList" id="aboutClassList4">
<li class="liveInfoLeftLi liveInfoLeftLiCheck" data="0">课程</li>
<li class="liveInfoLeftLi" data="1">老师</li>
</ul>
<div class="liveInfoRight" id="liveInfoRight4">
<input class="liveInfoRightInput" id="liveInfoRightInput4" type="text">
<img class="liveInfoRightInputBtn" id="liveInfoRightInputBtn4" src="images/nav_link_14.png" alt="">
</div>
</div>
<div class="classManagementRightContent" id="courseContent4">
</div>
<div class="classHandlerPageBox" id="classHandlerPageBox4">
<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="classHandlerPageMsg4" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span class="classHandlerHomePage" id="classHandlerHomePage4">首页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerUpPage" id="classHandlerUpPage4">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerDownPage" id="classHandlerDownPage4">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerEndPage" id="classHandlerEndPage4">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="classHandlerPageInfoInput4" class="classHandlerPageInfoInput" type="text">
</li>
<li class="classHandlerPageInfo classHandlerPageInfoCheck">
<span id="classHandlerSpecificPage4">GO</span>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="classManagementRight" id="classManagementRight5">
<div class="addUserBtn" id="addUserBtn">
<label class="addUserIcon"></label>
<span class="addUserText">添加用户</span>
</div>
<div class="classManagementRightTitle" id="classManagementRightTitle">
<ul class="liveInfoLeft" id="liveInfoList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">正在直播</li>
<li class="liveInfoLeftLi">未开始</li>
<li class="liveInfoLeftLi">已结束</li>
</ul>
<ul class="liveInfoLeft userClassList" id="userClassList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">老师</li>
<li class="liveInfoLeftLi">学生</li>
<li class="liveInfoLeftLi">兼课</li>
</ul>
<ul class="liveInfoLeft userClassList" id="aboutClassList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">课程</li>
<li class="liveInfoLeftLi">老师</li>
</ul>
<div class="liveInfoRight" id="liveInfoRight">
<input class="liveInfoRightInput" id="liveInfoRightInput" type="text">
<img class="liveInfoRightInputBtn" id="liveInfoRightInputBtn" src="images/nav_link_14.png" alt="">
</div>
<div class="liveInfoCenter" id="liveInfoCenter">
<span class="liveInfoCenterTime">时间</span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveStart"></div>
<span class="liveInfoCenterTime"></span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveEnd"></div>
</div>
</div>
<div class="classManagementRightContent" id="courseContent">
<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" id="t_box" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="9%" class="tr_center">
课堂主题
... ... @@ -349,6 +571,285 @@
操作
</th>
</tr>
</tbody>
</table>
</div>
<div class="classHandlerPageBox" id="classHandlerPageBox">
<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="classHandlerPageMsg" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span class="classHandlerHomePage" id="classHandlerHomePage">首页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerUpPage" id="classHandlerUpPage">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerDownPage" id="classHandlerDownPage">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerEndPage" id="classHandlerEndPage">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="classHandlerPageInfoInput" class="classHandlerPageInfoInput" type="text">
</li>
<li class="classHandlerPageInfo classHandlerPageInfoCheck">
<span id="classHandlerSpecificPage">GO</span>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="classManagementRight" id="classManagementRight6">
<div class="addUserBtn" id="addUserBtn">
<label class="addUserIcon"></label>
<span class="addUserText">添加用户</span>
</div>
<div class="classManagementRightTitle" id="classManagementRightTitle">
<ul class="liveInfoLeft" id="liveInfoList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">正在直播</li>
<li class="liveInfoLeftLi">未开始</li>
<li class="liveInfoLeftLi">已结束</li>
</ul>
<ul class="liveInfoLeft userClassList" id="userClassList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">老师</li>
<li class="liveInfoLeftLi">学生</li>
<li class="liveInfoLeftLi">兼课</li>
</ul>
<ul class="liveInfoLeft userClassList" id="aboutClassList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">课程</li>
<li class="liveInfoLeftLi">老师</li>
</ul>
<div class="liveInfoRight" id="liveInfoRight">
<input class="liveInfoRightInput" id="liveInfoRightInput" type="text">
<img class="liveInfoRightInputBtn" id="liveInfoRightInputBtn" src="images/nav_link_14.png" alt="">
</div>
<div class="liveInfoCenter" id="liveInfoCenter">
<span class="liveInfoCenterTime">时间</span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveStart"></div>
<span class="liveInfoCenterTime"></span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveEnd"></div>
</div>
</div>
<div class="classManagementRightContent" id="courseContent">
<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" id="t_box" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="9%" class="tr_center">
课堂主题
</th>
<th width="8%" class="tr_center">
课堂号
</th>
<th width="8%" class="tr_center">
老师
</th>
<th width="6%" class="tr_center">
课堂状态
</th>
<th width="24%" class="tr_center">
课堂时间
</th>
<th width="6%" class="tr_center">
在线人数
</th>
<th width="22%" class="tr_center">
操作
</th>
</tr>
</tbody>
</table>
</div>
<div class="classHandlerPageBox" id="classHandlerPageBox">
<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="classHandlerPageMsg" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span class="classHandlerHomePage" id="classHandlerHomePage">首页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerUpPage" id="classHandlerUpPage">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerDownPage" id="classHandlerDownPage">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerEndPage" id="classHandlerEndPage">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="classHandlerPageInfoInput" class="classHandlerPageInfoInput" type="text">
</li>
<li class="classHandlerPageInfo classHandlerPageInfoCheck">
<span id="classHandlerSpecificPage">GO</span>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="classManagementRight" id="classManagementRight7">
<div class="addUserBtn" id="addUserBtn">
<label class="addUserIcon"></label>
<span class="addUserText">添加用户</span>
</div>
<div class="classManagementRightTitle" id="classManagementRightTitle">
<ul class="liveInfoLeft" id="liveInfoList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">正在直播</li>
<li class="liveInfoLeftLi">未开始</li>
<li class="liveInfoLeftLi">已结束</li>
</ul>
<ul class="liveInfoLeft userClassList" id="userClassList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">老师</li>
<li class="liveInfoLeftLi">学生</li>
<li class="liveInfoLeftLi">兼课</li>
</ul>
<ul class="liveInfoLeft userClassList" id="aboutClassList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">课程</li>
<li class="liveInfoLeftLi">老师</li>
</ul>
<div class="liveInfoRight" id="liveInfoRight">
<input class="liveInfoRightInput" id="liveInfoRightInput" type="text">
<img class="liveInfoRightInputBtn" id="liveInfoRightInputBtn" src="images/nav_link_14.png" alt="">
</div>
<div class="liveInfoCenter" id="liveInfoCenter">
<span class="liveInfoCenterTime">时间</span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveStart"></div>
<span class="liveInfoCenterTime"></span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveEnd"></div>
</div>
</div>
<div class="classManagementRightContent" id="courseContent">
<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" id="t_box" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="9%" class="tr_center">
课堂主题
</th>
<th width="8%" class="tr_center">
课堂号
</th>
<th width="8%" class="tr_center">
老师
</th>
<th width="6%" class="tr_center">
课堂状态
</th>
<th width="24%" class="tr_center">
课堂时间
</th>
<th width="6%" class="tr_center">
在线人数
</th>
<th width="22%" class="tr_center">
操作
</th>
</tr>
</tbody>
</table>
</div>
<div class="classHandlerPageBox" id="classHandlerPageBox">
<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="classHandlerPageMsg" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span class="classHandlerHomePage" id="classHandlerHomePage">首页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerUpPage" id="classHandlerUpPage">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerDownPage" id="classHandlerDownPage">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span class="classHandlerEndPage" id="classHandlerEndPage">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="classHandlerPageInfoInput" class="classHandlerPageInfoInput" type="text">
</li>
<li class="classHandlerPageInfo classHandlerPageInfoCheck">
<span id="classHandlerSpecificPage">GO</span>
</li>
</ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="classManagementRight" id="classManagementRight8">
<div class="addUserBtn" id="addUserBtn">
<label class="addUserIcon"></label>
<span class="addUserText">添加用户</span>
</div>
<div class="classManagementRightTitle" id="classManagementRightTitle">
<ul class="liveInfoLeft" id="liveInfoList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">正在直播</li>
<li class="liveInfoLeftLi">未开始</li>
<li class="liveInfoLeftLi">已结束</li>
</ul>
<ul class="liveInfoLeft userClassList" id="userClassList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">老师</li>
<li class="liveInfoLeftLi">学生</li>
<li class="liveInfoLeftLi">兼课</li>
</ul>
<ul class="liveInfoLeft userClassList" id="aboutClassList">
<li class="liveInfoLeftLi liveInfoLeftLiCheck">课程</li>
<li class="liveInfoLeftLi">老师</li>
</ul>
<div class="liveInfoRight" id="liveInfoRight">
<input class="liveInfoRightInput" id="liveInfoRightInput" type="text">
<img class="liveInfoRightInputBtn" id="liveInfoRightInputBtn" src="images/nav_link_14.png" alt="">
</div>
<div class="liveInfoCenter" id="liveInfoCenter">
<span class="liveInfoCenterTime">时间</span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveStart"></div>
<span class="liveInfoCenterTime"></span>
<div class="liveInfoCenterLiveCase" id="liveInfoCenterLiveEnd"></div>
</div>
</div>
<div class="classManagementRightContent" id="courseContent">
<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" id="t_box" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="9%" class="tr_center">
课堂主题
</th>
<th width="8%" class="tr_center">
课堂号
</th>
<th width="8%" class="tr_center">
老师
</th>
<th width="6%" class="tr_center">
课堂状态
</th>
<th width="24%" class="tr_center">
课堂时间
</th>
<th width="6%" class="tr_center">
在线人数
</th>
<th width="22%" class="tr_center">
操作
</th>
</tr>
</tbody>
</table>
... ... @@ -361,16 +862,16 @@
<span class="classHandlerPageMsg" id="classHandlerPageMsg" style="line-height: 38px; padding-left: 20px; float: left">第1页/共2页,有16个记录</span>
<ul class="classHandlerPageInfoBox">
<li class="classHandlerPageInfo">
<span id="classHandlerHomePage" id="classHandlerHomePage">首页</span>
<span class="classHandlerHomePage" id="classHandlerHomePage">首页</span>
</li>
<li class="classHandlerPageInfo">
<span id="classHandlerUpPage" id="classHandlerUpPage">上一页</span>
<span class="classHandlerUpPage" id="classHandlerUpPage">上一页</span>
</li>
<li class="classHandlerPageInfo">
<span id="classHandlerDownPage" id="classHandlerDownPage">下一页</span>
<span class="classHandlerDownPage" id="classHandlerDownPage">下一页</span>
</li>
<li class="classHandlerPageInfo">
<span id="classHandlerEndPage" id="classHandlerEndPage">尾页</span>
<span class="classHandlerEndPage" id="classHandlerEndPage">尾页</span>
</li>
<li class="classHandlerPageInfo">
<input id="classHandlerPageInfoInput" class="classHandlerPageInfoInput" type="text">
... ... @@ -385,6 +886,7 @@
</table>
</div>
</div>
</div>
</div>
<!--创建课堂-->
<div id="createClassBox" class="userSignBox createClassBox">
... ... @@ -1408,8 +1910,8 @@
</div>
</div>
<div class="form_button">
<span id="createUserCancel" class="createClassBtn main_closeBtn">取消</span>
<input id="createUserConfirm" type="button" value="完成" class="createClassBtn createClassConfirm btnHover">
<span id="createUserCancel" class="createClassBtn main_closeBtn">取消</span>
</div>
</div>
</div>
... ...
... ... @@ -15,6 +15,9 @@ MessageTypes.HOME_SKIP= "home_skip"; //首页跳转
//
//管理员列表
MessageTypes.SWITCH_CLASS= "switch_class"; //创建课堂
export default MessageTypes;
... ...
//*
// 约课模块
// */
import Loger from "../Loger";
import Ape from "./Ape";
import $ from "jquery";
import ClassDataProxy from "proxy/ClassDataProxy";
import dateUI from 'libs/laydate';
import ErrorApe from "./ErrorApe";
let loger = Loger.getLoger('PC-AboutClassApe');
const adminListTit = `<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" id="t_box" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="6%" class="tr_center">
姓名
</th>
<th width="7%" class="tr_center">
电话
</th>
<th width="8%" class="tr_center">
年龄
</th>
<th width="7%" class="tr_center">
所约课程
</th>
<th width="9%" class="tr_center">
操作
</th>
</tr>
`;
//管理首页
const adminList = `<tr align="center" bgcolor="#FFFFFF" height="44" bordercolor="#e6e6e6">
<td width="7%" class="tr_main tr_mainLeft">{_userName}</td>
<td width="8%" class="tr_main">{_phone}</td>
<td width="8%" class="tr_main">{_age}</td>
<td width="8%" class="tr_main">{_course}</td>
<td width="10%" class="tr_main tr_mainRight" align="center" >
<a class="classHandlePort" href="###">&nbsp;</a>
<a id="{_removeInd}" class="classHandlePort" href="###">删除</a>
<a class="classHandlePort" href="###">&nbsp;</a>
<a id="{_stay}" class="classHandlePort" data="{_aboutMsg}" href="###">待回访</a>
<a class="classHandlePort" href="###">&nbsp;</a>
</td>
</tr>
`;
const adminListEnd = `</tbody></table>`;
const adminListTit1 = `<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" id="t_box" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="6%" class="tr_center">
姓名
</th>
<th width="7%" class="tr_center">
电话
</th>
<th width="8%" class="tr_center">
年龄
</th>
<th width="7%" class="tr_center">
约课老师
</th>
<th width="9%" class="tr_center">
操作
</th>
</tr>
`;
//管理首页
const adminList1 = `<tr align="center" bgcolor="#FFFFFF" height="44" bordercolor="#e6e6e6">
<td width="7%" class="tr_main tr_mainLeft">{_userName}</td>
<td width="8%" class="tr_main">{_phone}</td>
<td width="8%" class="tr_main">{_age}</td>
<td width="8%" class="tr_main">{_course}</td>
<td width="10%" class="tr_main tr_mainRight" align="center" >
<a class="classHandlePort1" href="###">&nbsp;&nbsp;</a>
<a id="{_removeInd}" class="classHandlePort" href="###">删除</a>
<a class="classHandlePort1" href="###">&nbsp;&nbsp;</a>
</td>
</tr>
`;
class AboutClassApe extends Ape {
constructor() {
super();
this.classDateList = {};//创建课堂信息
this.isLocalStorage();
this.pageNo = 0;
this.presentInd = 1;
this.addEvent();
this.init();
}
init() {
$('#aboutClassList4 li').on('click',this._userClassListHandler.bind(this));//用户列表
$('#classHandlerHomePage4').on('click',this._homePageHandler.bind(this));//首页
$('#classHandlerUpPage4').on('click',this._upPageHandler.bind(this));//上页
$('#classHandlerDownPage4').on('click',this._downPageHandler.bind(this));//下页
$('#classHandlerEndPage4').on('click',this._endPageHandler.bind(this));//尾页
$('#classHandlerSpecificPage4').on('click',this._assignPageHandler.bind(this));//指定页
}
addEvent() {
}
isLocalStorage(){
}
//首页
_homePageHandler(){
this.presentInd = 1;
this.userAdminHandler(this.presentInd);
}
//上页
_upPageHandler(){
if(this.presentInd >1){
this.presentInd--;
this.userAdminHandler(this.presentInd);
}
}
//下页
_downPageHandler(){
if(this.presentInd < this.pageNo){
this.presentInd++;
this.userAdminHandler(this.presentInd);
}
}
//尾页
_endPageHandler(){
this.presentInd = this.pageNo;
this.userAdminHandler(this.presentInd);
}
//指定页
_assignPageHandler(){
let inputVal = $('#classHandlerPageInfoInput4').val();
if(parseInt(inputVal) <= this.pageNo || parseInt(inputVal) >= 1 ){
this.userAdminHandler(parseInt(inputVal));
}
}
// 约课界面
userAdminHandler(ind){
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/users/getUser';
let that = this;
$.ajax({
type: "POST",
url: _url,
timeout:5000,
data:{siteId:ClassDataProxy.siteId,userType:ClassDataProxy.USER_TYPE_1},
headers: {siteId:ClassDataProxy.siteId,
pageno:7,
'page':ind,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
//获取课堂数据
if(_data && _data.code == 200){
let ind = $('#aboutClassList4').find('.liveInfoLeftLiCheck').attr('data');
if(ind == 0 ){
that._gainUserClassData(_data.returnData.data);
}else{
that._gainUserClassData1(_data.returnData.data);
}
}
},
error:function(error){
//alert('直播数据获取失败')
loger.log(error,'直播数据获取失败')
}
})
}
_gainUserClassData(_data){
let _dataList = _data.users;
let courseContent = $('#courseContent4');
courseContent.empty();
let count = _data.count;
let page = _data.page;
let pageno = _data.pageno;
this.pageNo = pageno;
$('#classHandlerPageMsg4').html('第'+page+'页/共'+pageno+'页,有'+count+'个记录');
courseContent.append(adminListTit);
if(_dataList){
if(count <= 7){
$('#classHandlerPageBox4').hide();
}
for(let i = 0;i<_dataList.length;i++){
let _adminList = this._format(adminList,{
_userName : _dataList[i].loginName,
_phone : _dataList[i].userMobile,
_age : '女',
_totalNmu : '2',
_course : '《少儿英语》',
_removeInd : 'classDoc'+i,
_stay : 'classMedia'+i,
_aboutMsg : _dataList[i].id
})
courseContent.append(_adminList);
}
courseContent.append(adminListEnd);
}
}
_gainUserClassData1(_data){
let _dataList = _data.users;
let courseContent = $('#courseContent4');
courseContent.empty();
let count = _data.count;
let page = _data.page;
let pageno = _data.pageno;
this.pageNo = pageno;
$('#classHandlerPageMsg4').html('第'+page+'页/共'+pageno+'页,有'+count+'个记录');
courseContent.append(adminListTit1);
if(_dataList){
if(count <= 7){
$('#classHandlerPageBox4').hide();
}
for(let i = 0;i<_dataList.length;i++){
let _adminList = this._format(adminList1,{
_userName : _dataList[i].loginName,
_phone : _dataList[i].userMobile,
_age : '女',
_totalNmu : '2',
_course : _dataList[i].userName,
_removeInd : 'classDoc'+i,
_stay : 'classMedia'+i,
_aboutMsg : _dataList[i].id
})
courseContent.append(_adminList);
}
courseContent.append(adminListEnd);
}
}
_switchover(evt){
$(evt.currentTarget).addClass('liveInfoLeftLiCheck').siblings().removeClass('liveInfoLeftLiCheck');
}
_userClassListHandler(evt){
this._switchover(evt);
this.userAdminHandler(1);
}
//工具类
_format(str, obj) {
return str.replace(/\{(\w+)\}/g, function (match, group, index) {
return obj[group];
});
};
}
export default AboutClassApe;
\ No newline at end of file
... ...
//*
// 管理员界面
// 管理员列表
// */
import Loger from "../Loger";
import Ape from "./Ape";
import $ from "jquery";
import ClassDataProxy from "proxy/ClassDataProxy";
import MessageTypes from "../MessageTypes";
import dateUI from 'libs/laydate';
let loger = Loger.getLoger('PC-AdministratorApe');
const adminListTit = `<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" id="t_box" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="8%" class="tr_center">
课堂主题
</th>
<th width="8%" class="tr_center">
课堂号
</th>
<th width="7%" class="tr_center">
老师
</th>
<th width="6%" class="tr_center">
课堂状态
</th>
<th width="20%" class="tr_center">
课堂时间
</th>
<th width="6%" class="tr_center">
在线人数
</th>
<th width="20%" class="tr_center">
操作
</th>
</tr>
`;
//管理首页
const adminList = `<tr align="center" bgcolor="#FFFFFF" height="44" bordercolor="#e6e6e6">
<td width="7%" class="tr_main tr_mainLeft">{_meetingName}</td>
<td width="7%" class="tr_main">{_esenglish}</td>
<td width="7%" class="tr_main">{_userName}</td>
<td width="6%" class="tr_main">{_stateInfo}</td>
<td width="18%" class="tr_main">{_time}</td>
<td width="6%" class="tr_main">{_onlineLen}</td>
<td width="18%" class="tr_main tr_mainRight" align="center" >
<a id="{_DocInd}" class="classHandlePort" href="###">文档</a>
<a id="{_mediaInd}" class="classHandlePort" href="###">多媒体</a>
<a id="{_musicInd}" class="classHandlePort" href="###">伴音</a>
<a id="{_updateInd}" class="classHandlePort" href="###">修改</a>
<a id="{_removeInd}" class="classHandlePort" href="###">删除</a>
<a id="{_joinInd}" class="classHandlePort" data="{_esenglish}" href="###">加入课堂</a>
</td>
</tr>
`;
const adminListEnd = `</tbody></table>`;
class AdministratorApe extends Ape {
constructor() {
super();
this.classDateList = {};//课堂的所有数据
this.pageNo = 0;
this.presentInd = 0;
this.isLocalStorage();
this.addEvent();
this.init();
}
init() {
this.detailPage();
$('#collectYes').hide();
$('#classManagementRight0').show();
$('#recordUl .recordLi').on('click',this._switchover.bind(this));//课堂分类
$('#classHandlerHomePage').on('click',this._homePageHandler.bind(this));//首页
$('#classHandlerUpPage').on('click',this._upPageHandler.bind(this));//上页
$('#classHandlerDownPage').on('click',this._downPageHandler.bind(this));//下页
$('#classHandlerEndPage').on('click',this._endPageHandler.bind(this));//尾页
$('#classHandlerSpecificPage').on('click',this._assignPageHandler.bind(this));//指定页
$('#courseContent').on('click','.classHandlePort',this._classHandlePortHandler.bind(this));//加入课堂
//日历插件
this._dateUI();
}
addEvent() {
}
isLocalStorage(){
if(ClassDataProxy.userType == ClassDataProxy.USER_TYPE_2){
this.detailPage();
}
}
//首页
_homePageHandler(){
this.presentInd = 1;
this._pageNumBtnHandler(this.presentInd);
}
//上页
_upPageHandler(){
if(this.presentInd >1){
this.presentInd--;
this._pageNumBtnHandler(this.presentInd);
}
}
//下页
_downPageHandler(){
if(this.presentInd < this.pageNo){
this.presentInd++;
this._pageNumBtnHandler(this.presentInd);
}
}
//尾页
_endPageHandler(){
this.presentInd = this.pageNo;
this._pageNumBtnHandler(this.presentInd);
}
//指定页
_assignPageHandler(){
let inputVal = $('#classHandlerPageInfoInput').val();
if(parseInt(inputVal) <= this.pageNo || parseInt(inputVal) >= 1 ){
this._pageNumBtnHandler(parseInt(inputVal));
}
}
_classHandlePortHandler(evt){
let id = $(evt.target).attr('data');
loger.log(id,11111111111)
// window.open('/3m/attend.do?meetingNumber=' + id);
}
//点击翻页
_pageNumBtnHandler(ind){
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/meeting/getMeeting';
let that = this;
$.ajax({
type: "POST",
url: _url,
data:{siteId:'markettest'},
headers: {'page':ind,
type:8,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo',
},
success:function(_data){
if(_data.code != 200 ){
loger.warn(_data.returnData.data.msg)
}
that.classDateList = _data.returnData.data;
that._gainClassData(_data.returnData.data);
},
error:function(error){
console.log(error,'失败')
}
})
}
detailPage(){
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/meeting/getMeeting';
let that = this;
$.ajax({
type: "POST",
url: _url,
data:{siteId:'markettest'},
headers: {siteId:'markettest',
type:8,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
if(_data || _data.code == 200){
that._gainClassData(_data.returnData.data);
}
},
error:function(error){
console.log(error,'失败')
}
})
}
_classDateTitle(){
$('#classifyListTitle').html($('.header_listMsgCheck').attr('data'));
}
_gainClassData(_data){
let courseContent = $('#courseContent');
courseContent.empty();
let count = _data.count;
let page = _data.page;
let pageno = _data.pageno;
let _dataList = _data.meetingInfo;
this.pageNo = pageno;
$('#classHandlerPageMsg').html('第'+page+'页/共'+pageno+'页,有'+count+'个记录');
courseContent.append(adminListTit);
if(_dataList){
if(_dataList.length <= 1){
$('#classHandlerPageBox').hide();
}
for(let i = 0;i<_dataList.length;i++){
let _adminList = this._format(adminList,{
_meetingName : _dataList[i].meetingName,
_esenglish : _dataList[i].meetingNumber,
_userName : _dataList[i].create_user,
_stateInfo : '准备',
_time: _dataList[i].beginTime+' - '+_dataList[i].endTime,
_onlineLen : '0',
_DocInd : 'classDoc'+i,
_mediaInd : 'classMedia'+i,
_musicInd : 'classMusic'+i,
_updateInd : 'classUpdate'+i,
_removeInd : 'classRemove'+i,
_joinInd : 'classJoin'+i
})
courseContent.append(_adminList);
}
courseContent.append(adminListEnd);
//设置当前时间 给输入框默认值
this._setNewTime();
//设置弹框位置
this._setMarginTop();
}
_switchover(evt){
$(evt.currentTarget).addClass('recordLiCheck').siblings().removeClass('recordLiCheck');
let ind = $(evt.currentTarget).attr('data');
this._emit(MessageTypes.SWITCH_CLASS,ind);
if(ind > 1){
$('.classManagementRight').eq(ind-1).show().siblings().hide();
}else{
$('.classManagementRight').eq(ind).show().siblings().hide();
}
}
_classDatepageNum(_data){ //page
let _pageContent = _data.count;
let _pageNum = Math.ceil(_pageContent / _data.pageno);
this.pagingConstruct(1,_pageNum);
_dateUI(){
//执行一个laydate实例
dateUI.render({
elem: '.liveInfoCenterLiveStart' //指定元素
});
//执行一个laydate实例
dateUI.render({
elem: '.liveInfoCenterLiveEnd' //指定元素
});
//执行一个laydate实例
dateUI.render({
elem: '#createClassStartTime' //指定元素
});
//执行一个laydate实例
dateUI.render({
elem: '#createClassEndTime' //指定元素
});
//执行一个laydate实例
dateUI.render({
elem: '#createUserAbortTime' //指定元素
});
}
pagingConstruct(paging,total){
let pageNumContentBox = $('#pageNumContentBox');
pageNumContentBox.empty();
let pagingDivInnerHTML = '<div class="pageNumContent">';
let isHiddenExist = 0;
for(let i =1 ;i<=total;i++){
if(i == paging){
pagingDivInnerHTML +='<span class="pageNumBtn pageNumBtnCheck">'+i+'</span>';
}else{
if (i < 4 || i < (paging + 4) && i > (paging - 2) && i < (total / 2 + 2) || i > (total - 2)) {
pagingDivInnerHTML +='<span class="pageNumBtn">'+i+'</span>';
isHiddenExist = 0;
}else{
if(isHiddenExist == 0){
pagingDivInnerHTML += '<span class="pageNumBtn">...</span>';
isHiddenExist = 1;
}
}
}
}
pagingDivInnerHTML += '</div>';
pageNumContentBox.append(pagingDivInnerHTML);
//设置当前时间 给输入框默认值
_setNewTime(){
let newDate = new Date();
let ysar = newDate.getFullYear();
let month = newDate.getMonth()+1;//月
let date = newDate.getDate();//日
month<10?'0'+month:month;
date<10?'0'+date:date;
let time = ysar+'-'+month+'-'+date;
$('.liveInfoCenterLiveStart').html(time);
$('.liveInfoCenterLiveEnd').html(time);
$('#createUserAbortTime').html(time);
}
//设置弹框位置
_setMarginTop(){
this._setMarginTopHandler($('#createUserAccount'));//创建用户选择身份
this._setMarginTopHandler($('#userLogin'));//登录
this._setMarginTopHandler($('#usersign'));//注册
this._setMarginTopHandler($('#warnHintBox'));//错误提示
this._setMarginTopHandler($('#removeHandler'));//删除
this._setMarginTopHandler($('#updateInputBox'));//修改信息输入框
this._setMarginTopHandler($('#teacherDetailReminders'));//预约成功弹框
this._setMarginTopHandler($('#createUser'));//注册老师账号
this._setMarginTopHandler($('#createClass'));//创建课堂
}
//设置弹框位置 方法
_setMarginTopHandler(_data){
let clienth = document.documentElement.clientHeight || document.body.clientHeight
_data.css('margin-top',(clienth - parseInt(_data.height()))/2)
}
//工具类
_format(str, obj) {
return str.replace(/\{(\w+)\}/g, function (match, group, index) {
return obj[group];
});
};
}
export default AdministratorApe;
\ No newline at end of file
... ...
... ... @@ -26,12 +26,6 @@ class CreateClassApe extends Ape {
$('#collectYes').hide();
//默认显示当前时间戳
this._showPresentTime();
// $('#createClassBtn').on('click',this._createClassBtnHandler.bind(this));
$('.recordLi').on('click',this._recordLiHandler.bind(this));//课堂分类
$('#liveInfoList li').on('click',this._liveInfoLeftLiHandler.bind(this));//首页
$('#userClassList li').on('click',this._userClassListHandler.bind(this));//用户列表
//创建课堂
$('#createClassA').on('click',this._closeClassHandler.bind(this));//关闭创建课堂
$('.main_closeBtn').on('click',this._closeClassHandler.bind(this));//关闭创建课堂
... ... @@ -42,12 +36,8 @@ class CreateClassApe extends Ape {
$('#createClassSubmit3').on('click',this._createClassSubmit3Handler.bind(this));//创建课堂第三步
$('#openParamBtn').on('click',this._openParamBtnHandler.bind(this));//打开更多参数
//用户管理
$('#addUserBtn').on('click',this._addUserBtnHandler.bind(this));//创建用户按钮
$('#createUserYes').on('click',this._createUserYesHandler.bind(this));//进入创建用户界面
$('#createUserConfirm').on('click',this._createUserConfirmHandler.bind(this));//创建用户按钮
$('#createUserA').on('click',this._closeUserClassHandler.bind(this));//关闭创建课堂
$('#createUserCancel').on('click',this._closeUserClassHandler.bind(this));//关闭创建课堂
$('#courseContent').on('click','.classHandlePort',this._classHandlePortHandler.bind(this));//加入课堂
//日历插件
this._dateUI();
}
... ... @@ -75,52 +65,7 @@ class CreateClassApe extends Ape {
let i=(i%4);
$('#classifyListContent').find('.classifyList').eq(i==3).addClass('classifyListR');
}
_recordLiHandler(evt){
$(evt.currentTarget).addClass('recordLiCheck').siblings().removeClass('recordLiCheck');
let ind = $(evt.currentTarget).attr('data');
loger.log('=',ind)
switch (parseInt(ind)){
case 0:
//首页
this._createClassHomePage();
break;
case 1:
//创建课堂
this._createClassBtnHandler();
break;
case 2:
//班级管理
break;
case 3:
//用户管理
this.userAdminHandler();
break;
case 4:
//约课管理
break;
case 5:
//录制管理
break;
case 6:
//站点配置
break;
case 7:
//统计报告
break;
case 8:
//个人设置
break;
}
}
_switchover(evt){
$(evt.currentTarget).addClass('liveInfoLeftLiCheck').siblings().removeClass('liveInfoLeftLiCheck');
}
_liveInfoLeftLiHandler(evt){
this._switchover(evt);
}
_userClassListHandler(evt){
this._switchover(evt);
}
_createClassBtnHandler(){
$('#createClassBox').show();
$('#scheduleForm1').show();
... ... @@ -131,18 +76,6 @@ class CreateClassApe extends Ape {
//获取第一步中老师列表
this.allotSpeaker();
}
//首页
_createClassHomePage(){
$('#addUserBtn').hide();
$('#userClassList').hide();
$('#liveInfoList').show();
}
//用户管理
userAdminHandler(){
$('#addUserBtn').show();
$('#userClassList').show();
$('#liveInfoList').hide();
}
//获取第一步中老师列表
allotSpeaker(){
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/users/getUser';
... ... @@ -320,7 +253,7 @@ class CreateClassApe extends Ape {
headers: {'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
//获取课堂数据
if(_data || _data.code == 0){
if(_data && _data.code == 0){
that._enterClass(_data.returnData.data);
}
},
... ... @@ -346,152 +279,9 @@ class CreateClassApe extends Ape {
$('#chatInterval').val('0');
$('#aheadTime').val('0');
}
//用户管理
_addUserBtnHandler(){
$('#createUserAccountBox').show();
}
_createUserYesHandler(){
$('#createUserAccountBox').hide();
$('#createUserBox').show();
let val = $('#createUserRole').val();
let name = '';
switch (parseInt(val)){
case 0:
name = '老师';
break;
case 1:
name = '兼课';
break;
default:
return;
}
$('#createUserTitle').html('添加'+name)
$("input[name='createUserTeacher']").get(val).checked = true;//创建身份
}
//创建用户
_createUserConfirmHandler(){
let _name = document.getElementById("createUserName");//老师名字
let _passWord = document.getElementById("createUserPassWord");//密码
let createUserRealName = document.getElementById("createUserRealName");//真实姓名
let createCharacter = $("input[name='createUserTeacher']:checked").val();//角色
let phone = document.getElementById("createUserPhone");//手机号
let identity = document.getElementById("createUserIdentity");//身份证号
let mail = document.getElementById("createUserMail");//邮箱
let createUserNote = $('#createUserNote').val();//备注信息
let createUserAbortTime = $('#createUserAbortTime').html();//有效期
if(_name.value && createUserRealName.value && phone.value && mail.value){
let createUserList = {
"loginName": _name.value, // 登录名
"password": parseInt(_passWord.value), //登录密码
"companyName":null, //公司名字
"userName":createUserRealName.value, //用户名
"userRole":3, // 用户角色 0超级管理员,1管理员,2监课,3老师,4学生
"userType": 1,
"userEmail":mail.value, // 用户邮箱
"userMobile":parseInt(phone.value), // 用户手机号
"content":createUserNote, // 用户简介
"groupId":1, //用户组id
"IDcard":123123,
"time":1
}
let that = this;
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/users/addUser';
$.ajax({
type: "POST",
url: _url,
data: createUserList,
timeout:5000,
success:function(_data){
//注册成功后 跳转登录界面
if(_data && _data.code == 200){
loger.log(_data,'注册老师账号成功')
ErrorApe.showWarnError('注册成功');
$('#createUserBox').hide();
}else{
ErrorApe.showWarnError(_data.returnData.data.msg);
}
},
error:function(error){
console.log(error,'失败')
}
})
}else{
this._signMail(mail);//判断邮箱
this._signIdentity(identity);
this._signPhone(phone);//判断手机号
this._signName(createUserRealName);//判断用户名
this._signName(_name);//判断登录名
}
}
_signName(_name){
if(!_name.value){
_name.focus();
return false;
}
}
_signPhone(phone){
let reg = "^1[3|4|5|8][0-9]\\d{8}$";
let re = new RegExp(reg);
if(!phone.value){
phone.focus();
return false;
}
if (re.test(phone.value)) {
$('#createUserPhone').css('color','#000');
} else {
$('#createUserPhone').val('手机号输入不合法')
.css('color','#d95136');
phone.focus();
return false;
}
}
_signMail(mail){
let filter = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
if(!mail.value){
mail.focus();
return false;
}
if (filter.test(mail.value)){
$('#createUserMail').css('color','#000');
}
else {
$('#createUserMail').val('电子邮箱输入不合法')
.css('color','#d95136');
mail.focus();
return false;
}
}
_signIdentity(identity){
let reg = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/;
if(!identity.value){
identity.focus();
return false;
}
if (reg.test(identity.value)){
$('#createUserIdentity').css('color','#000');
}
else {
$('#createUserIdentity').val('身份证号码输入不合法')
.css('color','#d95136');
identity.focus();
return false;
}
}
_closeUserClassHandler(){
$('#createUserBox').hide();
this._clearUserClssMsg();
}
_clearUserClssMsg(){
$('#createUserName').val('');
$('#createUserPassWord').val('');
$('#createUserRealName').val('');
$('#createUserPhone').val('');
$('#createUserIdentity').val('');
$('#createUserMail').val('');
$('#createUserNote').val('');
_classHandlePortHandler(evt){
let id = $(evt.target).attr('data');
// window.open('/3m/attend.do?meetingNumber=' + id);
}
//设置当前时间 给输入框默认值
_setNewTime(){
... ...
//*
// 用户管理模块
// */
import Loger from "../Loger";
import Ape from "./Ape";
import $ from "jquery";
import ClassDataProxy from "proxy/ClassDataProxy";
import ErrorApe from "./ErrorApe";
let loger = Loger.getLoger('PC-CreateUserApe');
const adminListTit = `<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="8%" class="tr_center">
登录名
</th>
<th width="8%" class="tr_center">
姓名
</th>
<th width="8%" class="tr_center">
科目
</th>
<th width="8%" class="tr_center">
上课总数
</th>
<th width="8%" class="tr_center">
最新约课
</th>
<th width="10%" class="tr_center">
操作
</th>
</tr>
`;
//管理首页
const adminList = `<tr align="center" bgcolor="#FFFFFF" height="44" bordercolor="#e6e6e6">
<td width="8%" class="tr_main tr_mainLeft">{_loginName}</td>
<td width="8%" class="tr_main">{_userName}</td>
<td width="8%" class="tr_main">{_course}</td>
<td width="8%" class="tr_main">{_totalNmu}</td>
<td width="8%" class="tr_main">{_latest}</td>
<td width="10%" class="tr_main tr_mainRight" align="center" >
<a id="{_removeInd}" class="classHandlePort" href="###">删除</a>
<a id="{_joinInd}" class="classHandlePort"" data="{_aboutMsg}" href="###">查看约课信息</a>
</td>
</tr>
`;
const adminListEnd = `</tbody></table>`;
class CreateUserApe extends Ape {
constructor() {
super();
this.pageNo = 0;
this.presentInd = 1;
this.addEvent();
this.init();
}
init() {
$('#userClassList3 li').on('click',this._userClassListHandler.bind(this));//用户列表
//用户管理
$('#addUserBtn').on('click',this._addUserBtnHandler.bind(this));//创建用户按钮
$('#createUserYes').on('click',this._createUserYesHandler.bind(this));//进入创建用户界面
$('#createUserConfirm').on('click',this._createUserConfirmHandler.bind(this));//创建用户按钮
$('#createUserA').on('click',this._closeUserClassHandler.bind(this));//关闭创建课堂
$('#createUserCancel').on('click',this._closeUserClassHandler.bind(this));//关闭创建课堂
$('#classHandlerHomePage3').on('click',this._homePageHandler.bind(this));//首页
$('#classHandlerUpPage3').on('click',this._upPageHandler.bind(this));//上页
$('#classHandlerDownPage3').on('click',this._downPageHandler.bind(this));//下页
$('#classHandlerEndPage3').on('click',this._endPageHandler.bind(this));//尾页
$('#classHandlerSpecificPage3').on('click',this._assignPageHandler.bind(this));//指定页
}
addEvent() {
}
_switchover(evt){
$(evt.currentTarget).addClass('liveInfoLeftLiCheck').siblings().removeClass('liveInfoLeftLiCheck');
}
_userClassListHandler(evt){
this._switchover(evt);
}
//首页
_homePageHandler(){
this.presentInd = 1;
this.userAdminHandler(this.presentInd);
}
//上页
_upPageHandler(){
if(this.presentInd >1){
this.presentInd--;
this.userAdminHandler(this.presentInd);
}
}
//下页
_downPageHandler(){
if(this.presentInd < this.pageNo){
this.presentInd++;
this.userAdminHandler(this.presentInd);
}
}
//尾页
_endPageHandler(){
this.presentInd = this.pageNo;
this.userAdminHandler(this.presentInd);
}
//指定页
_assignPageHandler(){
let inputVal = $('#classHandlerPageInfoInput3').val();
if(parseInt(inputVal) <= this.pageNo || parseInt(inputVal) >= 1 ){
this.userAdminHandler(parseInt(inputVal));
}
}
//用户管理 创建用户界面
userAdminHandler(ind){
this.createUserClassUI();
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/users/getUser';
let that = this;
$.ajax({
type: "POST",
url: _url,
timeout:5000,
data:{siteId:ClassDataProxy.siteId,userType:ClassDataProxy.USER_TYPE_1},
headers: {siteId:ClassDataProxy.siteId,
pageno:7,
'page':ind,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
loger.log(_data,'创建用户界面用户列表数据')
loger.log(ClassDataProxy.USER_TYPE_1,'创建用户界面用户列表数据')
//获取课堂数据
if(_data && _data.code == 200){
that._gainUserClassData(_data.returnData.data);
}
},
error:function(error){
//alert('直播数据获取失败')
loger.log(error,'直播数据获取失败')
}
})
}
_gainUserClassData(_data){
let _dataList = _data.users;
let courseContent = $('#courseContent3');
courseContent.empty();
let count = _data.count;
let page = _data.page;
let pageno = _data.pageno;
this.pageNo = pageno;
$('#classHandlerPageMsg3').html('第'+page+'页/共'+pageno+'页,有'+count+'个记录');
courseContent.append(adminListTit);
if(_dataList){
if(count <= 7){
$('#classHandlerPageBox3').hide();
}
for(let i = 0;i<_dataList.length;i++){
let _adminList = this._format(adminList,{
_loginName : _dataList[i].loginName,
_userName : _dataList[i].userName,
_course : '暂无',
_totalNmu : '2',
_latest : '1',
_removeInd : 'classDoc'+i,
_joinInd : 'classMedia'+i,
_aboutMsg : _dataList[i].id
})
courseContent.append(_adminList);
}
courseContent.append(adminListEnd);
}
}
createUserClassUI(){
}
//用户管理
_addUserBtnHandler(){
$('#createUserAccountBox').show();
}
_createUserYesHandler(){
$('#createUserAccountBox').hide();
$('#createUserBox').show();
let val = $('#createUserRole').val();
let name = '';
switch (parseInt(val)){
case 0:
name = '老师';
break;
case 1:
name = '兼课';
break;
default:
return;
}
$('#createUserTitle').html('添加'+name)
$("input[name='createUserTeacher']").get(val).checked = true;//创建身份
}
//创建用户
_createUserConfirmHandler(){
let _name = document.getElementById("createUserName");//老师名字
let _passWord = document.getElementById("createUserPassWord");//密码
let createUserRealName = document.getElementById("createUserRealName");//真实姓名
let createCharacter = $("input[name='createUserTeacher']:checked").val();//角色
let phone = document.getElementById("createUserPhone");//手机号
let identity = document.getElementById("createUserIdentity");//身份证号
let mail = document.getElementById("createUserMail");//邮箱
let createUserNote = $('#createUserNote').val();//备注信息
let createUserAbortTime = $('#createUserAbortTime').html();//有效期
if(_name.value && createUserRealName.value && phone.value && mail.value){
let createUserList = {
"loginName": _name.value, // 登录名
"password": parseInt(_passWord.value), //登录密码
"companyName":null, //公司名字
"userName":createUserRealName.value, //用户名
"userRole":3, // 用户角色 0超级管理员,1管理员,2监课,3老师,4学生
"userType": 1,
"userEmail":mail.value, // 用户邮箱
"userMobile":parseInt(phone.value), // 用户手机号
"content":createUserNote, // 用户简介
"groupId":1, //用户组id
"IDcard":123123,
"time":1,
"siteId":ClassDataProxy.siteId
}
let that = this;
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/users/addUser';
$.ajax({
type: "POST",
url: _url,
data: createUserList,
timeout:5000,
headers: {siteId:ClassDataProxy.siteId},
success:function(_data){
//注册成功后 跳转登录界面
if(_data && _data.code == 200){
loger.log(_data,'注册老师账号成功')
ErrorApe.showWarnError('注册成功');
$('#createUserBox').hide();
}else{
ErrorApe.showWarnError(_data.returnData.data.msg);
}
},
error:function(error){
console.log(error,'失败')
}
})
}else{
this._signMail(mail);//判断邮箱
this._signIdentity(identity);
this._signPhone(phone);//判断手机号
this._signName(createUserRealName);//判断用户名
this._signName(_name);//判断登录名
}
}
_signName(_name){
if(!_name.value){
_name.focus();
return false;
}
}
_signPhone(phone){
let reg = "^1[3|4|5|8][0-9]\\d{8}$";
let re = new RegExp(reg);
if(!phone.value){
phone.focus();
return false;
}
if (re.test(phone.value)) {
$('#createUserPhone').css('color','#000');
} else {
$('#createUserPhone').val('手机号输入不合法')
.css('color','#d95136');
phone.focus();
return false;
}
}
_signMail(mail){
let filter = /^([a-zA-Z0-9_\.\-])+\@(([a-zA-Z0-9\-])+\.)+([a-zA-Z0-9]{2,4})+$/;
if(!mail.value){
mail.focus();
return false;
}
if (filter.test(mail.value)){
$('#createUserMail').css('color','#000');
}
else {
$('#createUserMail').val('电子邮箱输入不合法')
.css('color','#d95136');
mail.focus();
return false;
}
}
_signIdentity(identity){
let reg = /(^\d{15}$)|(^\d{18}$)|(^\d{17}(\d|X|x)$)/;
if(!identity.value){
identity.focus();
return false;
}
if (reg.test(identity.value)){
$('#createUserIdentity').css('color','#000');
}
else {
$('#createUserIdentity').val('身份证号码输入不合法')
.css('color','#d95136');
identity.focus();
return false;
}
}
_closeUserClassHandler(){
$('#createUserBox').hide();
this._clearUserClssMsg();
}
_clearUserClssMsg(){
$('#createUserName').val('');
$('#createUserPassWord').val('');
$('#createUserRealName').val('');
$('#createUserPhone').val('');
$('#createUserIdentity').val('');
$('#createUserMail').val('');
$('#createUserNote').val('');
}
//工具类
_format(str, obj) {
return str.replace(/\{(\w+)\}/g, function (match, group, index) {
return obj[group];
});
};
}
export default CreateUserApe;
\ No newline at end of file
... ...
... ... @@ -69,8 +69,8 @@ class HomeApe extends Ape {
$.ajax({
type: "POST",
url: _url,
data:{siteId:'markettest'},
headers: {siteId:'markettest',
data:{siteId:ClassDataProxy.siteId},
headers: {siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
// loger.log(_data,'成功')
... ... @@ -91,8 +91,8 @@ class HomeApe extends Ape {
type: "GET",
url: _url,
timeout:5000,
data:{siteId:'markettest'},
headers: {siteId:'markettest',
data:{siteId:ClassDataProxy.siteId},
headers: {siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
// loger.log(_data,'成功')
... ...
... ... @@ -73,7 +73,7 @@ class LanclassApe extends Ape {
url: _url,
timeout:5000,
headers: {'page':_ele.text(),
siteId:'markettest',
siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo',
},
... ... @@ -101,8 +101,8 @@ class LanclassApe extends Ape {
type: "POST",
url: _url,
timeout:5000,
data:{siteId:'markettest'},
headers: {siteId:'markettest',
data:{siteId:ClassDataProxy.siteId},
headers: {siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
// loger.log(_data,'成功')
... ...
... ... @@ -54,7 +54,7 @@ class ListDetailsApe extends Ape {
url: _url,
timeout:5000,
headers: {
siteId:'markettest',
siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'
},
data:signInfo,
... ...
... ... @@ -72,10 +72,10 @@ class LanclassApe extends Ape {
url: _url,
timeout:5000,
headers: {'page':_ele.text(),
siteId:'markettest',
siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo',
},
data:{siteId:'markettest'},
data:{siteId:ClassDataProxy.siteId},
success:function(_data){
if(_data != 200 ){
// loger.warn(_data.data.msg)
... ... @@ -101,8 +101,8 @@ class LanclassApe extends Ape {
type: "POST",
url: _url,
timeout:5000,
data:{siteId:'markettest'},
headers: {siteId:'markettest',
data:{siteId:ClassDataProxy.siteId},
headers: {siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
// loger.log(_data,'成功')
... ...
... ... @@ -326,11 +326,13 @@ class LoginOrRegister extends Ape {
successLogin(_data){
//登录成功后显示用户名字
$('#homeUserLoginBtn').text( ClassDataProxy.loginName);
$('#teacherMyCenterName').text( ClassDataProxy.loginName);
this._userLoginAHandler();
this._emit(MessageTypes.LOGIN_IN,{userType: ClassDataProxy.userType});
}
updateChangeUser(_data){
loger.log(_data)
loger.log('登录成功后更改用户名',_data)
let _dataList = _data.returnData.data;
let oneselfInfoLoginName = $('#oneselfInfoLoginName');//登录名
let oneselfInfoUserName = $('#oneselfInfoUserName');//用户名
... ...
//*
// 管理员首页界面
// */
import Loger from "../Loger";
import Ape from "./Ape";
import $ from "jquery";
import ClassDataProxy from "proxy/ClassDataProxy";
import MessageTypes from "../MessageTypes";
let loger = Loger.getLoger('PC-ManagementHomePageApe');
const adminListTit = `<table width="100%" align="center" cellpadding="0" cellspacing="0" border="0" class="t_box">
<tbody>
<tr align="center" height="44" class="tr_center" bgcolor="#fff" bordercolor="#e6e6e6">
<th width="8%" class="tr_center">
课堂主题
</th>
<th width="8%" class="tr_center">
课堂号
</th>
<th width="7%" class="tr_center">
老师
</th>
<th width="6%" class="tr_center">
课堂状态
</th>
<th width="20%" class="tr_center">
课堂时间
</th>
<th width="6%" class="tr_center">
在线人数
</th>
<th width="20%" class="tr_center">
操作
</th>
</tr>
`;
//管理首页
const adminList = `<tr align="center" bgcolor="#FFFFFF" height="44" bordercolor="#e6e6e6">
<td width="7%" class="tr_main tr_mainLeft">{_meetingName}</td>
<td width="7%" class="tr_main">{_esenglish}</td>
<td width="7%" class="tr_main">{_userName}</td>
<td width="6%" class="tr_main">{_stateInfo}</td>
<td width="18%" class="tr_main">{_time}</td>
<td width="6%" class="tr_main">{_onlineLen}</td>
<td width="18%" class="tr_main tr_mainRight" align="center" >
<a id="{_DocInd}" class="classHandlePort" href="###">文档</a>
<a id="{_mediaInd}" class="classHandlePort" href="###">多媒体</a>
<a id="{_musicInd}" class="classHandlePort" href="###">伴音</a>
<a id="{_updateInd}" class="classHandlePort" href="###">修改</a>
<a id="{_removeInd}" class="classHandlePort" href="###">删除</a>
<a id="{_joinInd}" class="classHandlePort" data="{_esenglish}" href="###">加入课堂</a>
</td>
</tr>
`;
const adminListEnd = `</tbody></table>`;
class ManagementHomePageApe extends Ape {
constructor() {
super();
this.classDateList = {};//课堂的所有数据
this.pageNo = 0;
this.presentInd = 1;
this.addEvent();
this.init();
}
init() {
$('#liveInfoList0 li').on('click',this._liveInfoLeftLiHandler.bind(this));//首页
$('#classHandlerHomePage0').on('click',this._homePageHandler.bind(this));//首页
$('#classHandlerUpPage0').on('click',this._upPageHandler.bind(this));//上页
$('#classHandlerDownPage0').on('click',this._downPageHandler.bind(this));//下页
$('#classHandlerEndPage0').on('click',this._endPageHandler.bind(this));//尾页
$('#classHandlerSpecificPage0').on('click',this._assignPageHandler.bind(this));//指定页
}
addEvent() {
}
//首页
_createClassHomePage(){
this.detailPage();
}
//首页
_homePageHandler(){
this.presentInd = 1;
this._pageNumBtnHandler(this.presentInd);
}
//上页
_upPageHandler(){
if(this.presentInd > 1){
this.presentInd--;
this._pageNumBtnHandler(this.presentInd);
}
}
//下页
_downPageHandler(){
loger.log(this.presentInd,111111)
if(this.presentInd < this.pageNo){
this.presentInd++;
this._pageNumBtnHandler(this.presentInd);
}
}
//尾页
_endPageHandler(){
this.presentInd = this.pageNo;
this._pageNumBtnHandler(this.presentInd);
}
//指定页
_assignPageHandler(){
let inputVal = $('#classHandlerPageInfoInput').val();
if(parseInt(inputVal) <= this.pageNo || parseInt(inputVal) >= 1 ){
this._pageNumBtnHandler(parseInt(inputVal));
}
}
//点击翻页
_pageNumBtnHandler(ind){
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/meeting/getMeeting';
let that = this;
$.ajax({
type: "POST",
url: _url,
data:{siteId:ClassDataProxy.siteId},
headers: {'page':ind,
pageno:8,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo',
},
success:function(_data){
if(_data.code != 200 ){
loger.warn(_data.returnData.data.msg)
}
that.classDateList = _data.returnData.data;
that._gainClassData(_data.returnData.data);
},
error:function(error){
console.log(error,'失败')
}
})
}
detailPage(){
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/meeting/getMeeting';
let that = this;
$.ajax({
type: "POST",
url: _url,
data:{siteId:ClassDataProxy.siteId},
headers: {siteId:ClassDataProxy.siteId,
pageno:8,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
if(_data || _data.code == 200){
that._gainClassData(_data.returnData.data);
}
},
error:function(error){
console.log(error,'失败')
}
})
}
_gainClassData(_data){
let courseContent = $('#courseContent0');
courseContent.empty();
let count = _data.count;
let page = _data.page;
let pageno = _data.pageno;
let _dataList = _data.meetingInfo;
this.pageNo = pageno;
$('#classHandlerPageMsg0').html('第'+page+'页/共'+pageno+'页,有'+count+'个记录');
courseContent.append(adminListTit);
if(_dataList){
if(count <= 8){
$('#classHandlerPageBox0').hide();
}
for(let i = 0;i<_dataList.length;i++){
let _adminList = this._format(adminList,{
_meetingName : _dataList[i].meetingName,
_esenglish : _dataList[i].meetingNumber,
_userName : _dataList[i].create_user,
_stateInfo : '准备',
_time: _dataList[i].beginTime+' - '+_dataList[i].endTime,
_onlineLen : '0',
_DocInd : 'classDoc'+i,
_mediaInd : 'classMedia'+i,
_musicInd : 'classMusic'+i,
_updateInd : 'classUpdate'+i,
_removeInd : 'classRemove'+i,
_joinInd : 'classJoin'+i
})
courseContent.append(_adminList);
}
courseContent.append(adminListEnd);
}
}
_switchover(evt){
$(evt.currentTarget).addClass('liveInfoLeftLiCheck').siblings().removeClass('liveInfoLeftLiCheck');
}
_liveInfoLeftLiHandler(evt){
this._switchover(evt);
}
//工具类
_format(str, obj) {
return str.replace(/\{(\w+)\}/g, function (match, group, index) {
return obj[group];
});
};
}
export default ManagementHomePageApe;
\ No newline at end of file
... ...
... ... @@ -24,7 +24,6 @@ class MyCenterApe extends Ape {
super();
this.isLocalStorage();
this.data = 0;
this._curriculumInfo();
this.addEvent();
this.init();
}
... ... @@ -56,8 +55,8 @@ class MyCenterApe extends Ape {
type: "POST",
url: _url,
timeout:5000,
data:{siteId:'markettest',loginName:'market'},
headers: {siteId:'markettest',
data:{siteId:ClassDataProxy.siteId,userType:1},
headers: {siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
success:function(_data){
loger.log(_data,'个人中心用户列表数据')
... ... @@ -71,6 +70,9 @@ class MyCenterApe extends Ape {
})
}
isLocalStorage(){
if(ClassDataProxy.userType == ClassDataProxy.USER_TYPE_1){
this._curriculumInfo();
}
$('#teacherMyCenterName').text(ClassDataProxy.loginName);
$('.myCenterContentBox').eq(0).show();
let newDate = new Date();
... ... @@ -152,7 +154,7 @@ class MyCenterApe extends Ape {
type: "PUT",
url: _url,
timeout:5000,
headers: {siteId:'markettest',
headers: {siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
data:signInfo,
success:function(_data){
... ...
... ... @@ -38,7 +38,7 @@ class SubscribeApe extends Ape {
$.ajax({
type: "POST",
url: _url,
data:{siteId:'markettest',
data:{siteId:ClassDataProxy.siteId,
"studentId":ClassDataProxy.id,
"status":parseInt(status),
"meetingId":id
... ... @@ -48,11 +48,13 @@ class SubscribeApe extends Ape {
success:function(_data){
let arr = ['收藏成功!','预约成功!','报名成功!']
loger.log(_data,'预约信息')
loger.log(ClassDataProxy.loginName,'预约信息')
//获取课堂数据
if(_data && _data.code == 200 || _data.returnData.data.msg == '您已预约这堂课'){
if(_data && _data.code == 200){
loger.log(_data,'预约信息')
$('#teacherDetailRemindersBox').show();
// ErrorApe.showWarnError(arr[status]);
}else if(_data.returnData.data.msg == '您已预约这堂课' && ClassDataProxy.loginName){
ErrorApe.showWarnError('您已预约这堂课');
}else{
that.toLogin();
}
... ...
... ... @@ -69,10 +69,10 @@ class TeacherDetailApe extends Ape {
url: _url,
timeout:5000,
headers: {'page':_ele.text(),
siteId:'markettest',
siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo',
},
data:{siteId:'markettest'},
data:{siteId:ClassDataProxy.siteId},
success:function(_data){
loger.log('点击翻页返回数据',_data)
if(_data != 200 ){
... ... @@ -99,9 +99,9 @@ class TeacherDetailApe extends Ape {
type: "POST",
url: _url,
timeout:5000,
headers: {siteId:'markettest',
headers: {siteId:ClassDataProxy.siteId,
'token':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IlhXQnJlRU00T0swYTVqUUIyUTFicGtObHlxOUFWbXZkIiwibmFtZSI6ImFkbWluIiwiY29kZSI6MSwiaWF0IjoxNTAzNDUxODU0LCJleHAiOjIyODEwNTE4NTR9.3kTVzKd_jbP7l69nxOpNaFeSjVnnjZkagYMzRB8fjNo'},
data:{siteId:'markettest'},
data:{siteId:ClassDataProxy.siteId},
success:function(_data){
loger.log('老师界面渲染数据',_data)
//获取课堂数据
... ...
... ... @@ -15,13 +15,17 @@ import LanclassApe from 'ape/LanclassApe';//互动课堂
import LiveClassApe from 'ape/LiveClassApe';//直播课堂
import HomeApe from 'ape/HomeApe';//首页
import TeacherDetailApe from 'ape/TeacherDetailApe';//老师
import ManagementHomePageApe from 'ape/ManagementHomePageApe';//管理员首页
import CreateClassApe from 'ape/CreateClassApe';//创建课堂
import CreateUserApe from 'ape/CreateUserApe';//创建用户界面
import AboutClassApe from 'ape/AboutClassApe';//约课界面
import ListDetailsApe from 'ape/ListDetailsApe';//列表详情
import AdministratorApe from 'ape/AdministratorApe';//管理员
import MyCenterApe from 'ape/MyCenterApe';//个人中心
import SubscribeApe from 'ape/SubscribeApe';//预约
import MessageTypes from "MessageTypes";
import Loger from "Loger";
let loger = Loger.getLoger('networkSchool');
... ... @@ -31,7 +35,10 @@ let _lanclassApe;
let _liveClassApe;
let _homeApe;
let _teacherDetailApe;
let _managementHomePageApe;
let _createClassApe;
let _createUserApe;
let _aboutClassApe;
let _listDetailsApe;
let _administratorApe;
let _myCenterApe;
... ... @@ -39,7 +46,7 @@ let _subscribeApe;
class Main {
constructor() {
this.clientVersion="v1.7.1.20170906";
this.clientVersion="v1.7.2.20170906";
loger.warn("clientVersion:"+this.clientVersion);
let locationProtocol= location.protocol;
... ... @@ -58,6 +65,8 @@ class Main {
//课堂初始化和启动流程
this.init();
//默认显示管理员首页
this.switchClass(0);
}
//获取地址栏参数
... ... @@ -131,11 +140,19 @@ class Main {
//老师
_teacherDetailApe = new TeacherDetailApe();
//创建课堂
_managementHomePageApe = new ManagementHomePageApe();
//创建课堂
_createClassApe = new CreateClassApe();
//创建用户老师
_createUserApe = new CreateUserApe();
//创建约课
_aboutClassApe = new AboutClassApe();
//列表详情
_listDetailsApe = new ListDetailsApe();
//管理员
_administratorApe = new AdministratorApe();
_administratorApe.on(MessageTypes.SWITCH_CLASS,this.switchClass.bind(this));
//个人中心
_myCenterApe = new MyCenterApe();
... ... @@ -177,6 +194,44 @@ class Main {
}
}
}
switchClass(_data){
let ind = parseInt(_data);
loger.log('管理员列表',ind)
switch (ind){
case 0:
//首页
_managementHomePageApe._createClassHomePage();
break;
case 1:
//创建课堂
_createClassApe._createClassBtnHandler();
break;
case 2:
//班级管理
break;
case 3:
//用户管理
_createUserApe.userAdminHandler();
break;
case 4:
//约课管理
_aboutClassApe.userAdminHandler();
break;
case 5:
//录制管理
break;
case 6:
//站点配置
break;
case 7:
//统计报告
break;
case 8:
//个人设置
break;
}
}
//判断登录用户的状态
_localStorageState(){
let userType = window.localStorage.getItem('userType')||0;
... ... @@ -236,9 +291,6 @@ class Main {
$('#lanclassBox').hide();
$('#classifyListBox').hide();
$('#recordUl .recordLi').eq(0).addClass('recordLiCheck').siblings().removeClass('recordLiCheck');
$('#addUserBtn').hide();
$('#liveInfoList').show();
$('#userClassList').hide();
}
_teacherHome(){
$('#slideshow').hide();
... ...