Javascript Smartclient对utf-8字符的支持
我有以下Smartclient JS代码,它不能在UI中正确呈现UTF-8字符Javascript Smartclient对utf-8字符的支持,javascript,smartgwt,smartclient,Javascript,Smartgwt,Smartclient,我有以下Smartclient JS代码,它不能在UI中正确呈现UTF-8字符 function getGridLoadedWithDatasource(DS, DSfields) { var statGrid = isc.ListGrid.create({ ID: "statusGrid", autoFetchData: true, fields: DSfields, dataSource: DS, canEdit: false, autoDr
function getGridLoadedWithDatasource(DS, DSfields) {
var statGrid = isc.ListGrid.create({
ID: "statusGrid",
autoFetchData: true,
fields: DSfields,
dataSource: DS,
canEdit: false,
autoDraw: true,
showRecordComponents: true,
showRecordComponentsByCell: true,
createRecordComponent : function (record, colNum) {
var fieldName = this.getFieldName(colNum);
if (fieldName == "btnClaim" && record["PTicketname"]=='Reklamacija') {
var button = isc.IButton.create({
height: 18,
width: 65,
//icon: "flags/16/" + record["countryCode"] + ".png",
title: "Žalba",
click : function () {
//alert("Hello man!");
isc.say("Need to draw a form here");
//getInvoiceDetailWindow(record["rednibr"],tech, ba_id);
}
});
return button;
}
}
});
return statGrid;
}
我用于标题的单词在UI上被打断。如何以及在何处为smartclient小部件启用/配置UTF-8
致以最良好的祝愿 如果在Javascript代码中使用特殊字符作为文本,则必须确保Javascript源代码的字符编码与主页相同。例如,在记事本++中,您应该使用“Encoding/UTF-8 without BOM”或类似菜单将其设置为UTF-8。我非常确定这不是错误。然而,我用Sublime文本编辑器将远程文件转换为UTF-8编码文件,结果证明是可行的。