Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // Add classname .choicless-message to field in GF Admin
- $('.choiceless-message').each(function() {
- let $el = $(this)
- let inputsWithChoice = $el.find('input').length
- let inputsWithChoiceDisabled = $el.find('input:disabled').length
- let waitlistHref = $el.data('waitlistHref') || '#'
- if (inputsWithChoice === inputsWithChoiceDisabled) {
- $('<div />').addClass('alert alert-warning').html('<p class="mb-0">There are no more open slots available<br /> <a href=".waitlistHref.">Join the waitlist</a></p>').appendTo($el)
- }
- })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement