ali内部

在webx-component.xml中
需求: 要初始化一个工具类,在vm中被用到
<services:pull xmlns="http://www.alibaba.com/schema/services/pull/factories">
<utils />
<rundata-tool />
<csrfToken />
<form-tool />
<control-tool />
<uris-tool />
<bean-tool id="DateTimeUtil" class="com.alibaba.xxx.utils.DateTimeUtil" autowire="true" scope="global"/>
</services:pull>



#set($spmHome="/static")
<link href="$spmHome/css/backend.css" type="text/css" rel="stylesheet" media="screen" />


$screen_placeholder

$control.setTemplate("spmHeader")




#SLITERAL($msg.content) 这个标签可以转义 html


===================================

============================
内部:
<script type="text/javascript">
jQuery(document).ready(function($) {
var t=new ais.home.notice({$el:$('#content-container')});
t.initData();
});
</script>


var url = App.getDataUrl()+'xservice/getUserInfoByEmplId.jsonp?_='+jQuery.now();
var data = {'emplId':emplId};
jQuery.when(ali.network.easyJsonp(url, data)).done(function(){


}).fail(function(){

});


var source = [
].join('');

var template = Handlebars.compile(source);

var template = Handlebars.compile(source);
Handlebars.registerHelper('image_url', function () {
return App.getZoomImgUrl(this.imageUrl,50);
});

var result = template(data);


if(App.subscribers['ais.search.resource.pagination.nextpage']) {
PageBus.unsubscribe(App.subscribers['ais.search.resource.pagination.nextpage']);
}

App.subscribers['ais.search.resource.pagination.nextpage']=PageBus.subscribe('ais.search.resource.pagination.nextpage', this,function (subj, msg) {

});
PageBus.publish('ais.global.popmsg',{type:3,content:'刷新过滤条件失败'});


Handlebars.registerHelper('tip', function () {
var unreadContent = "";
if(this.unreadContent>0){
unreadContent = "has-unread-content";
}
if(this.tip.trim().length>0){
var _html= ['<div class="name g-csscut-more ',unreadContent,'" >',this.tip,'</div>'].join('');

return new Handlebars.SafeString(_html);
}
return "";
});

private static final Logger logger = LoggerFactory.getLogger(MsgReminderService.class);
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值