|
@@ -271,8 +271,31 @@
|
|
$('.loading-btn').hide();
|
|
$('.loading-btn').hide();
|
|
alert("成功提交!");
|
|
alert("成功提交!");
|
|
}
|
|
}
|
|
|
|
+
|
|
},
|
|
},
|
|
});
|
|
});
|
|
|
|
+
|
|
|
|
+ // 寄信
|
|
|
|
+ let templateParams = {
|
|
|
|
+ name: name,
|
|
|
|
+ phone: phone,
|
|
|
|
+ company: company,
|
|
|
|
+ email: email,
|
|
|
|
+ demand: demand,
|
|
|
|
+ caption: caption,
|
|
|
|
+ budget: budget,
|
|
|
|
+ date: date,
|
|
|
|
+ agree: agree,
|
|
|
|
+ };
|
|
|
|
+
|
|
|
|
+ emailjs.send('service_kyazqjp', 'template_n0sqgwh', templateParams).then(
|
|
|
|
+ (response) => {
|
|
|
|
+ console.log('SUCCESS!', response.status, response.text);
|
|
|
|
+ },
|
|
|
|
+ (error) => {
|
|
|
|
+ console.log('FAILED...', error);
|
|
|
|
+ },
|
|
|
|
+ );
|
|
};
|
|
};
|
|
|
|
|
|
$('button').on('click', function (e) {
|
|
$('button').on('click', function (e) {
|
|
@@ -305,14 +328,5 @@
|
|
$('.errorText').hide();
|
|
$('.errorText').hide();
|
|
send();
|
|
send();
|
|
}
|
|
}
|
|
-
|
|
|
|
- // if (name === "" || phoneCode === "" || company === "" || email === "" || demand === "" || caption === "" || budget === "" || date === "" || countryCode === "") {
|
|
|
|
- // $('.errorText').show();
|
|
|
|
- // return;
|
|
|
|
- // } else {
|
|
|
|
- // $('.loading-btn').show();
|
|
|
|
- // $('.errorText').hide();
|
|
|
|
- // send();
|
|
|
|
- // }
|
|
|
|
});
|
|
});
|
|
</script>
|
|
</script>
|