var FirmsController = Class.create();
FirmsController.prototype = {

	initialize : function() {
		this.url = null;
		this.div = null;
		this.module_name = 'crm';
		this.method = 'post';
	},

	message : function(content_id, url) {

		new Ajax.Updater($(content_id), baseUrl + url, {
			method : 'get',
			evalScripts : true,
			onComplete : function() {
				$(content_id).show();
			}
		});
	},

	sendMessage : function(obj, content_id) {
		new Ajax.Updater($(content_id), baseUrl + '/mediam/firms/message', {
			method : 'post',
			parameters : $(obj).serialize(true)
		});
	}
}

var Firms = new FirmsController();
