var fbTableUpdateCol = FbTablePlugin.extend({
	initialize: function(tableform, options, lang) {
		this.setOptions(tableform, options);
		this.lang = Object.extend({'selectrow':'Please select a row!'}, lang || {});
		window.addEvent('domready', function(){
		this.tableid = this.tableform.getElement('input[name=tableid]').value;
			this.watchButton();
		}.bind(this));
	},
	
	watchButton:function(){
		var button = this.tableform.getElement('input[name='+this.options.name+']');
		if(!button){
			return;
		}
		button.addEvent('click', function(event){
			var e = new Event(event);
			e.stop();
			var ok = false;
			this.tableform.getElements('input[name^=ids]').each(function(c){
				if(c.checked){
					ok = true;
				}
			});
			if(!ok){
				alert(this.lang.selectrow);
				return;
			}
			this.tableform.getElement('input[name=fabrik_tableplugin_name]').value = 'update_col';
			this.tableform.getElement('input[name=fabrik_tableplugin_renderOrder]').value = button.name.split('-').getLast();
			oPackage.submitfabrikTable(this.tableid, 'doPlugin');
		}.bind(this));
	}
	});