This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Example of Netzke Helper | |
module Netzke::Helpers::GridPanelClerk | |
# which model's methods should be used as virtual column, along with configuration | |
def self.virtual_attributes | |
[:name] | |
end | |
# preconfigure some columns | |
def self.attributes_config | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Netzke::TreePanel < Netzke::Base | |
api :get_children | |
def self.js_base_class | |
"Ext.tree.TreePanel" | |
end | |
def self.js_extend_properties | |
{ | |
:root => {:text => '/', :id => 'source'} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Netzke | |
class TreeNavigator < BorderLayoutPanel | |
# BorderLayoutPanel's regions | |
def initial_aggregatees | |
{ | |
:west => { | |
:widget_class_name => "TreePanel", | |
:data_class_name => config[:tree_data_class_name], | |
:region_config => { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
CheckColumn plugin from the "Editable Grid" example on http://extjs.com/deploy/dev/examples/ | |
The problem with it is that when a new record is added to the store, the corresponding field value | |
is set to an empty string, instead of being set to false. Here's the fix for it. | |
*/ | |
Ext.grid.CheckColumn = function(config){ | |
Ext.apply(this, config); | |
if(!this.id){ | |
this.id = Ext.id(); | |
} |
NewerOlder