Ext.define('PMG.dashboard.MailProcessing', { extend: 'Ext.panel.Panel', xtype: 'pmgMailProcessing', setData: function(data) { var me = this; me.down('#ptime').update(data); me.down('#traffic').update(data); }, layout: { type: 'hbox', align: 'center', pack: 'center' }, defaults: { xtype: 'box', flex: 1, style: { 'text-align':'center' } }, items: [ { itemId: 'traffic', data: { in: 0, out: 0 }, tpl: [ '

' + gettext('Traffic') + '

', '', '', '', '', '', '', '

{in}

' + PMG.Utils.format_rule_direction(0) + '

{out}

' + PMG.Utils.format_rule_direction(1) + '
', ] }, { itemId: 'ptime', data: { avgptime: 0, }, tpl: [ '

' + gettext('Avg. Processing Time') + '

', '

{ptime}

' ] } ] })