Reputation: 5851
I am using Azure API Management Portal now for some reasons I want to disable Subscribe button from Product Page when User hit it to subscribe after the approval from the manager it will subscribe the product and subscribe button will be hide. Right Now when the user hit the subscribe button and its status is IsPending
it still shows on the client side. Now tell me how I can achieve this thing.
Upvotes: 0
Views: 137
Reputation: 106
You can edit the template of the Product page to modify the behavior of the Subscribe button. At the bottom of that template you will find this:
{% if CannotAddBecauseSubscriptionNumberLimitReached %}
<b>{% localized "ProductDetailsStrings|TextblockSubscriptionLimitReached" %}</b>
{% elsif CannotAddBecauseMultipleSubscriptionsNotAllowed == false %}
<subscribe-button></subscribe-button>
{% endif %}
You can check if the SubscriptionState variable equals 3 then a request has been submitted and the button should not be shown.
All states of that variable are documented here: https://msdn.microsoft.com/en-us/library/azure/mt697541.aspx#Subscription
Upvotes: 2