Ext.define('rgpd.view.SAISIE.saisieCategoriePers', {
extend: 'Ext.window.Window',
alias: 'widget.saisie_categorie_persform',
requires: [
'Ext.form.Panel',
'rgpd.store.sCategoriePers'
],
title: 'Ajout d\'une catégorie de personnes',
autoShow: true,
height: 700,
width: 700,
//resizable: false,
layout: 'fit',
items: [
{
xtype: 'tabpanel',
items: [
{
xtype: 'panel',
title: 'Sélection',
items: [
{
xtype: 'checkboxfield',
// create checkbox from store
},
// other items
我有一个包含 tabpanel 的窗口。我想显示我所有的商店内容(可以用网格来完成)并且能够使用复选框选择多行。这可能吗 ?我没有找到 checkboxfield 和 checkboxgroup 的商店属性。
我发现的解决方案是使用
{
xtype: 'grid',
store: 'sCategoriePers',
id: 'gridsaisiecategoriepers',
title: 'Categories de Personnes',
multiSelect: true,
columns: [
{
text: 'Id',
hideable: false,
dataIndex: 'id',
autoSizeColumn : true,
hidden: true
},
{
text: 'Nom',
dataIndex: 'nom',
autoSizeColumn : true,
flex: 1
},
],
selModel: {
selType: 'checkboxmodel',
showHeaderCheckbox: true
},
// ...
然后您可以使用 getSelection() 获取选定的行
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句