董佳音

修改查看课堂信息和老师信息显示头像

... ... @@ -100,7 +100,7 @@ class ListDetailsApe extends Ape {
siteId:ClassDataProxy.siteId,
userType : 1
}
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/users/getUserByUserType';
let _url = ClassDataProxy.locationProtocol + ClassDataProxy.locationProt + '/users/getUser';
this.detailPage(_url,data,function(_data){
if(_data){
that._classDateContent(_data.returnData.data);
... ... @@ -126,13 +126,14 @@ class ListDetailsApe extends Ape {
}
//老师
_lanclassRender(_dataList){
loger.log('老师1111',_dataList)
$('#defaultBox').hide();
$('.curriculumBox').hide();
$('#teacherDetailBox').show();
$('#teacherDetailBox').attr('data',this._id);
$('#teacherDetailInfoImg').attr('src','images/u293.png');//老师授课标题图片
$('#teacherDetailInfoDetailName').text(_dataList.user_name);//老师名字
let _img = _dataList.userPhoto;
let defaultImg = 'images/u373.png'
$('#teacherDetailInfoImg').attr('src',_img?_img:defaultImg);//老师授课标题图片
$('#teacherDetailInfoDetailName').text(_dataList.userName);//老师名字
$('#teacherDetailInfoDetailSex').text();//老师性别
$('#teacherDetailInfoDetailPoint').text();//老师专长
$('#teacherDetailInfoDetailAge').text(3+'年');//老师教龄
... ... @@ -152,9 +153,14 @@ class ListDetailsApe extends Ape {
$('.curriculumBox').hide();
$('#lanclassBox').show();
$('#lanclassBox').attr('data',this._id);
$('#lanclassContentCover').attr('src','images/u373.png');//老师授课标题图片
let _img = _dataList.meetingPhoto;
let defaultImg = 'images/u373.png'
$('#lanclassContentCover').attr('src',_img?_img:defaultImg);//老师授课标题图片
$('#lanclassContentTitle').text(_dataList.meetingName);//老师授课标题
$('#lanclassContentInfoPortrait').text();//老师授课老师头像
let _teacherImg = _dataList.teacherPhoto;
let teacherDefault = 'images/u293.png';
$('#lanclassContentInfoPortrait').attr('src',_teacherImg?_teacherImg:teacherDefault);//老师授课老师头像
$('#lanclassContentInfoName').text(_dataList.create_user);//老师授课老师名字
$('#teacherInfoName').text(_dataList.create_user);//老师授课老师名字
$('#lanclassContentInfoTimeStart').text(_dataList.beginTime);//老师授课开始时间
... ...
... ... @@ -828,6 +828,7 @@ class MyCenterApe extends Ape {
$('#teacherIntroAllBox').hide();
$('#teacherDetailBox').hide();
$('#teacherUI .recordLi').eq(2).show();
$('#myCenterBox').show();
}else if(ClassDataProxy.userType == ClassDataProxy.USER_TYPE_1){
$('#myCenterBox').show();
}
... ...
... ... @@ -68,7 +68,7 @@ let _headSwitchTitleApe;
class Main {
constructor() {
this.clientVersion="v1.8.6.20170928";
this.clientVersion="v1.8.7.20170928";
loger.warn("clientVersion:"+this.clientVersion);
let locationProtocol= location.protocol;
... ... @@ -124,7 +124,6 @@ class Main {
//将地址转化成一个对象
_parseUrlParams() {
let url = encodeURI(location.search);
loger.log('地址栏参数',location.search)
let thisParam = {};
let strs;
// 判断是否存在请求的参数
... ... @@ -343,10 +342,20 @@ class Main {
}
//判断登录用户的状态
_localStorageState(){
let _href = window.location.href.split('.')[0].split('//')[1];
let _idHref ;
if(_href.indexOf('localhost') !=-1){
_idHref = 'networkschool';
}else{
_idHref = window.location.href.split('.')[0].split('//')[1];
}
loger.log(_idHref,'111111111')
let userType = window.localStorage.getItem('userType')||0;
let loginName = window.localStorage.getItem('loginName')|| '';
let id = window.localStorage.getItem('id')|| '';
let siteId = window.localStorage.getItem('siteId')|| 'markettest';
let siteId = window.localStorage.getItem('siteId')|| _idHref;
let userMobile = window.localStorage.getItem('userMobile')|| '';
let userEmail = window.localStorage.getItem('userEmail')|| '';
... ...