我有以下内容:
<ext:RecordField Name="ID" />
<ext:RecordField Name="UserName" />
<ext:RecordField Name="FirstName" />
<ext:RecordField Name="LasttName" />
i want use FirstName& LasttName on :
<ext:Column ColumnID="Name" Sortable="false" DataIndex="????"
Resizable="false" MenuDisabled="true"/>
我需要的是在同一列上使用多于data_index 是可能的,我该如何实现?提前谢谢!
答案 0 :(得分:2)
尝试这样的事情:
//In your head:
<script type="text/javascript">
var myRenderer = function(value, metadata, record) {
return record.get('FirstName') + ' ' + record.get('LastName');
}
</script>
<ext:Column ColumnID="Name" Sortable="false" Resizable="false" MenuDisabled="true">
<Renderer Fn="myRenderer" />
</ext:Column>