jQuery( document ).ready( function() {

	jQuery( '.vendor_paypal_mail' ).click( function() {
		var link = elex_mv_admin_ajaxurl_object.ajax_url;
		link += '?action=elex_mv_vendor_payment_mail';
		var formData = new FormData( document.getElementById( 'email_id_vendor' ) );

		jQuery.ajax( {
			url: link,
			type: 'POST',
			data: formData,
			enctype: 'multipart/form-data',
			processData: false,
			contentType: false,
			success: function( result ) {
				if ( result.success ) {
					location.reload();
				}
			},
		} );
	} );

} );
