//Well-Being FORM

! function(e) {
    "use strict";

    function t() {
        e("#contactForm").removeClass().addClass("shake animated").one("webkitAnimationEnd mozAnimationEnd MSAnimationEnd oanimationend animationend", function() {
            e(this).removeClass()
        })
    }

    function a(t, a) {
        if (t) var n = "h4 text-left tada animated text-success";
        else n = "h4 text-left text-danger";
        e("#msgSubmit").removeClass().addClass(n).text(a)
    }
    e("#contactForm").validator().on("submit", function(n) {
        var name, email, msg_subject, phone_number, msg , company, designation;
        n.isDefaultPrevented() ? (t(), a(!1, "Did you fill in the form properly?")) : (n.preventDefault(), name = e("#name").val(),
                                                                                                           company = e("#company").val(),
                                                                                                           designation = e("#designation").val(),
                                                                                                           email = e("#email").val(),
                                                                                                           msg_subject = e("#msg_subject").val(),
                                                                                                           phone_number = e("#phone_number").val(),
                                                                                                           msg  = e("#msg").val(), e.ajax({
            type: "POST",
            url: "/assets/dist/php/form-process.php",
            data: "&name=" + name + "&company=" + company + "&designation=" + designation +"&email=" + email + "&msg_subject=" + msg_subject + "&phone_number=" + phone_number + "&msg=" + msg ,
            success: function(n) {
                "success" == n ? (e("#contactForm")[0].reset(), a(!0, "Message Submitted! Our Team will contact you Shortly.")) : (t(), a(!1, n))
            }
        }))
    })
}(jQuery);
