Skip to Content Skip to Menu

CB Subs question: Possible to have X amount of items with each item costing Y?

  • timstohr
  • timstohr
  • OFFLINE
  • Posts: 1091
  • Thanks: 56
  • Karma: 9
4 years 6 months ago #318349 by timstohr
Hi Kyle,
Could you tell me if it would be theoretically possible to have CB subs doing a constant recuring subscription for the following:

_Users can buy subscriptions (for another site, no relation to CB Subs) for 5 Euro per subscription
_They need to input the number of subscriptions that they want to buy
_The user gets a detailed invoice where he sees how much tax he has paid AND how many subscriptions he has bought.
_Recurring either per month or per year.

Is that possible?

Thanks

Tim

Please Log in or Create an account to join the conversation.

  • krileon
  • krileon
  • ONLINE
  • Posts: 48550
  • Thanks: 8290
  • Karma: 1445
4 years 6 months ago - 4 years 6 months ago #318362 by krileon

_Users can buy subscriptions (for another site, no relation to CB Subs) for 5 Euro per subscription

No idea how you plan on interfacing with the other site so I can't say yes or no to this question. If you just need to for example add something to an external database table you can use CBSubs SQL Actions or CB Auto Actions to push data to another database based off subscription state.

_They need to input the number of subscriptions that they want to buy

Create an integer field for them to fill out during registration. Next create a new promotion in CBSubs Promotions that always applies to your plan. Then use the following settings in your promotion to increase the price of the plan based off the number they put in that integer field.

The promotion is: A fixed amount
Fixed Discount Amount in currency above: -[FIELD_NAME]0

The above would increase the price by $10 per site. If you need more complicated calculations you'll need to use CB Code Field and a Code field to use PHP functions to calculate your price. You'd then just substitute that into your promotion as follows.

Fixed Discount Amount in currency above: -[FIELD_NAME]

Example code field usage as follows for $5 per site.

Code:
return ( (int) '[FIELD_NAME]' * 5 );

_The user gets a detailed invoice where he sees how much tax he has paid AND how many subscriptions he has bought.

CBSubs already handles properly providing an invoice. As for also having it show how many sites they subscribed for you can add your integer field to "Payment item text" under the Pricing tab of your plan so that detail is also added to the invoice item.

_Recurring either per month or per year.

CBSubs supports monthly and yearly recurring durations, but if you want to support both you'll need 2 separate plans for that.

You should be able to give all of this a try on our demo site below excluding the code field usage.

demo.cbdemosites.com/


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.
Last edit: 4 years 6 months ago by krileon.

Please Log in or Create an account to join the conversation.

Moderators: beatnantkrileon
Powered by Kunena Forum