jsp
<script type="text/javascript" src="<%=componentPath%>/scripts/report_<%=localeStr%>.js" ></script>
report_zh_CN.js
var reportPrint_I18N = {
reportName : '报表名称'
}
report_en_US.js
var reportPrint_I18N = {
reportName : 'Name'
}
html
<div style="height:30px;text-align: center;border-bottom: 1px solid #cccccc;margin: 11px 0 0 0;">
{{reportPrint_I18N["reportName"]}}
</div>
js
function init(){
this.template='#dailyAlertPrint',
this.data=function () {
return {
reportPrint_I18N : reportPrint_I18N,
alertConvert2Chn:{"3" : reportPrint_I18N["high"],
"2" : reportPrint_I18N["middle"],
"1" : reportPrint_I18N["low"],
},
}
},
_self.createTime = _self.reportPrint_I18N["createTime1"]+ _self.convert2Time(data.createTime);