|
@@ -131,12 +131,13 @@ function initContent(data){
|
|
|
}else{
|
|
|
const icon=require("../images/empty1.png");
|
|
|
const sid=moduleId?"("+moduleId+")":"";
|
|
|
+ const code=k.replace(/[^\u4e00-\u9fa5|a-zA-Z0-9]+/g,'');
|
|
|
const emptyStr=`<div class="empty">
|
|
|
<img src="${icon}" alt="空"/>
|
|
|
<p>暂无信息~</p>
|
|
|
</div>`;
|
|
|
- if(!$(".content-item[code="+k+"] .empty").length){ //显示一条空提示即可
|
|
|
- hml='<div class="content-item" code="'+k+'">' +
|
|
|
+ if(!$(".content-item[code="+code+"] .empty").length){ //显示一条空提示即可
|
|
|
+ hml='<div class="content-item" code="'+code+'">' +
|
|
|
'<h2 class="title">'+k+sid+'</h2>'+emptyStr+'</div>';
|
|
|
$.tmpl(hml,{}).appendTo("#contentInfo");
|
|
|
}
|