mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-31 18:59:08 +00:00
website: style fixes
This commit is contained in:
@@ -43,19 +43,24 @@
|
||||
</div></p>
|
||||
<script>
|
||||
$("#footer-subscribe-button").click(function() {
|
||||
|
||||
$("#footer-subscribe-email").attr('disabled', true);
|
||||
$("#footer-subscribe-button").html("Sending...")
|
||||
.attr("disabled", true);
|
||||
|
||||
if($("#footer-subscribe-email").val()) {
|
||||
erpnext.send_message({
|
||||
subject:"Subscribe me",
|
||||
sender: $("#footer-subscribe-email").val(),
|
||||
message: "Subscribe to newsletter (via website footer).",
|
||||
callback: function(r) {
|
||||
console.log(r)
|
||||
if(!r.exc) {
|
||||
$("#footer-subscribe-email").val("").attr('disabled', true);
|
||||
$("#footer-subscribe-button").html("Thank You :)")
|
||||
.addClass("btn-success").attr("disabled", true);
|
||||
} else {
|
||||
$("#footer-subscribe-button").html("Error :( Not a valid id?").addClass("btn-danger");
|
||||
$("#footer-subscribe-button").html("Error :( Not a valid id?")
|
||||
.addClass("btn-danger").attr("disabled", false);
|
||||
$("#footer-subscribe-email").val("").attr('disabled', false);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user