PDA

View Full Version : buttongroup button styling



qt4x11
23 May 2012, 9:42 AM
The code below generates the buttongroup ('Filter' and 'Expert As CSV') in the right panel pictured below. It looks like the buttons in a buttongroup are styled differently than regular buttons, as in they are transparent with some type of mouseover behavior.

I'm not good with css, what's the best way to edit the buttongroup so that these buttons look like button elements that are generated with Ext.panel.panel.buttons ? - as in, no transparent or mouseover styling?

35555


},{
xtype: 'panel',
layout : {
type : 'table',
columns: 3
},
defaults: {
// applied to each contained panel
bodyStyle: 'padding:30px'
},
frame: true,
style: {
border: 0,
padding: 0
},
flex: 1,
items : [{
xtype: 'buttongroup',
style: {
border: 0,
padding: 0,
background: '#DFE9F6'
},
items : [{
text : 'Filter',
handler : function() {
var form = this.up('form').getForm();
if (form.isValid()) {
var grid = Ext.ComponentQuery.query('#ccsGrid')[0];
var from_date = Ext.ComponentQuery.query('#from_date')[0];
var to_date = Ext.ComponentQuery.query('#to_date')[0];
var includeAbandoned = Ext.ComponentQuery.query('#includeAbandoned')[0].getValue();
// converts Date object value to a string of
// 'yyyy-mm-dd'.
var startDateString = Ext.util.Format.date(from_date
.getValue(), 'Y-m-d');
var endDateString = Ext.util.Format.date(to_date
.getValue(), 'Y-m-d');
grid.getStore().load({
params : {
startDate : startDateString,
endDate : endDateString,
includeAbandoned: includeAbandoned
}
});
}
}
}, {
text : 'Export As CSV',
handler : function() {
var from_date = Ext.ComponentQuery.query('#from_date')[0];
var to_date = Ext.ComponentQuery.query('#to_date')[0];
// converts Date object value to a string of
// 'yyyy-mm-dd'.
var startDateString = Ext.util.Format.date(from_date
.getValue(), 'Y-m-d');
var endDateString = Ext.util.Format.date(
to_date.getValue(), 'Y-m-d');
window.location = "/leservlet/ReportServlet?action=companyCustomerSummaryReport&startDate="
+ startDateString
+ "&endDate="
+ endDateString
+ "&exportAsCSV=true"
}
}]

qt4x11
23 May 2012, 12:39 PM
n/m - I got it to work another way.