Commit 2bff2781 by Saliya Randunu

create invalid coupon popup and functional changes

parent 5c9bf5ae
......@@ -5981,7 +5981,7 @@ label, label .label-title span {
text-align: center;
}
.change-plan-button .change-plan-no-button {
.change-plan-button .popup-no-button{
height: 60px;
width: 160px;
border: 1px solid #DBDBDF;
......
......@@ -47,6 +47,17 @@
width : 600, height : 640
});
var isinvliadCoupon = getParameterByName("invalidcoupon");
if (isinvliadCoupon==='true'){
PopupCoupon = new jBox('Modal', {
id : "change-plan",
overlay : true, content : $("#invalid-coupon-popup") ,
width : 500, height : 450
});
PopupCoupon.open();
}
$(".select-btn").on("click",function(){
Popup.setContent($("#" + $(this).data('popupid') ));
Popup.open();
......@@ -226,7 +237,7 @@
</div>
<div class="change-plan-button">
<a class="change-plan-no-button">No</a>
<a class="change-plan-no-button popup-no-button">No</a>
<oneit:button skin="link" value="Yes" name="saveCompany" cssClass="change-plan-yes-button"
requestAttribs="<%= CollectionUtils.mapEntry("nextPage", nextPage)
.toMap() %>" />
......@@ -319,7 +330,18 @@
</div>
<div id="invalid-coupon-popup" style="display:none" >
<div class="change-plan-content">
<h3>Oops!</h3>
<div class="upgrade-info">
<span>We're having some difficulty validating your coupon. <br> Please check the code supplied and try again</span>
<span>For further assitance, please <a href='#'>contact us</a></span>
</div>
</div>
<div class="change-plan-button">
<a class="invalid-coupon-close-button popup-no-button">Close & Try</a>
</div>
</div>
</oneit:dynIncluded>
......@@ -121,3 +121,13 @@ function removeLogo() {
$('.u-img-tag').hide();
$('#replace-btn').text('Upload');
}
function getParameterByName(name, url) {
if (!url) url = window.location.href;
name = name.replace(/[\[\]]/g, "\\$&");
var regex = new RegExp("[?&]" + name + "(=([^&#]*)|&|#|$)"),
results = regex.exec(url);
if (!results) return null;
if (!results[2]) return '';
return decodeURIComponent(results[2].replace(/\+/g, " "));
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment