CMinder.Module.require('CMinder.Module', 0.1);
CMinder.Module.createNamespace('CMinder.Family', 0.1);

CMinder.Family.InquiryShort = {    
    button: null,
    form: null,
    init: function(e) {
    },    
    startSettings: function (button, myClass, form) {
        CMinder.Includes.Validator.errorClass = myClass;        
        this.form = (form);
        YAHOO.util.Event.addListener(button,'click',this.myClickHandler,this,true);        
    },    
    myClickHandler: function(e,args) {
        var txtCountry = $("txtCountry");
        var ddlState = $("ddlState");
        if (txtCountry.value == '') {
            ddlState.setAttribute("class", "cmValidate"); 
        }
        else {
            ddlState.setAttribute("class", ""); 
        }
    
        var success = CMinder.Includes.Validator.validate();
        if (success) {
            $("isFormSubmitted").value = "true";
            $(this.form).submit();
        }          
    }
}