87,989
社区成员
发帖
与我相关
我的任务
分享
for(i=0;i<jsonArr.length;i++){
var photo = jsonArr[i].photo;
var photourl;
if(typeof(photo) == "undefined")
{
var photourl = "http://172.16.104.13:8081/static/images/avatar_64_64.png";
}
else{
photourl = TS.app.utils.getAvatarURL(photo);
}
var departmentSpace_url = TS.app.utils.getSystemURL("department/"+jsonArr[i].id);
selectItem +="<div class='space-selectItem-two'id='space-"+i+"' style='width:100%;height:100%;line-height:2;'>"
+"<span style='width:24px;height:24px; margin-left: 8px;'><image style='width:24px;height:24px;' src='"+photourl+"'/>" +
"</span>"
+"<span class='space-head-"+i+"' style='display:inline-block;'>"
+"<a hidefocus='true' href='"+departmentSpace_url+"' class='select'>"
+jsonArr[i].name
+"</a>"+"</span>"+"</div>";
<div class='space-selectItem-two' url='"+departmentSpace_url+"' style='width:100%;height:100%;line-height:2;'onclick(function(url))>这样写$(this).attr("url")就可以得到