Hosting Quota Notifications 1.X For WHMCS
From ModulesGarden Wiki
(Difference between revisions)
|
|
Line 149: |
Line 149: |
| |} | | |} |
| {| | | {| |
− | |style="padding: 0px 0px 30px 15px;"|'''Your Product Auto Upgrade For WHMCS is ready to use! ''' | + | |style="padding: 0px 0px 30px 15px;"|'''Your Product Auto Upgrade For WHMCS is now ready to use! ''' |
| |} | | |} |
| | | |
Revision as of 11:50, 13 November 2017
Product Auto Upgrade For WHMCS permits to automatically shift products on the basis of the server resource usage tracked with Advanced Billing For WHMCS module. Additionally, you will be able to modify rules related to the server resource usage according to which the module will upgrade/downgrade products and their configurable options at the same time. Thanks to this module, your clients can decide if they want their products to be adjusted as well as freely set the rules on their own.
|
✔ Define Product Auto Upgrade Groups
|
✔ Enable/Disable Product Auto Upgrade Groups
|
✔ Create Product Auto Upgrade Options
|
✔ Assign Product To An Option - Configurable Option Support
|
✔ Define Options Upgrade/Downgrade Rules
|
✔ Set Up Minimal Upgrade/Downgrade Interval
|
✔ Enable/Disable Any Product Auto Upgrade Option
|
✔ Drag & Drop To Reorder Options
|
✔ Define Client Area Features
|
✔ View List Of All Hostings Affected By Product Auto Upgrade
|
✔ Access Product Auto Upgrade History Of Any Hosting
|
✔ Enable/Disable Product Auto Upgrade And Product Auto Upgrade Options
|
✔ Manage Rules Of Product Auto Upgrade Options
|
✔ Set Up Minimal Upgrade/Downgrade Interval
|
✔ View Products' Product Auto Upgrade History
|
✔ Set Up Rules Of Notifications
|
✔ Define Minimal Notification Interval
|
✔ Requires Advanced Billing For WHMCS - Server Resource Usage Billing (read more)
|
✔ Supports PHP 5.3 Up To PHP 7
|
✔ Supports WHMCS Templates Five and Six
|
✔ Supports WHMCS V6 and V7
|
Installation and Configuration
In this tutorial we will show you how to successfully install and administer Product Auto Upgrade For WHMCS.
We will guide you step by step through the whole installation and configuration process.
|
1. Log in to your client area and download the module.
|
2. In the downloaded file you will find two packages that support different PHP versions. As shown on the screen below, the first one is dedicated to PHP 7, while the second one is aimed at PHP 5.3 up to PHP 5.6. It does not apply to open source versions.
Note: You can check current PHP version in your WHMCS. To do so, go to 'Utilities' → 'System' → 'PHP Info'.
|
3. Extract the downloaded file and choose the one with matching PHP version. Upload and extract the PHP file into the main WHMCS directory.
Files in your WHMCS directory should look like this.
|
Module Configuration
4. Now you need to activate the module in your WHMCS system.
Move to 'Setup' → 'Addon Modules', find 'Advanced Billing' and press 'Activate' button.
Note: Skip this subsection, if you have Advanced Billing For WHMCS already installed.
|
5. In the next step you can assign access permissions for the module.
In order to do that, press 'Configure', choose desired admin roles and press 'Save Changes'.
|
6. Now, set up a cron job, you can find it in your WHMCS → 'Addons' → 'Advanced Billing' as demonstrated on the following screen.
|
Extension Configuration
7. Now, you have to activate the extension in your Advanced Billing For WHMCS.
Log in to your WHMCS admin area and proceed to 'Addons' → 'Advanced Billing' → 'Settings' → 'Extensions'.
Afterwards, find 'Product Auto Upgrade' and enable the extension.
|
8. Next, you need to provide your license key.
Press 'Configure' next to the extension.
|
9. Paste your license key and confirm the changes.
|
Your Product Auto Upgrade For WHMCS is now ready to use!
|
Management
To combine any product with Product Auto Upgrade For WHMCS, you need to firstly enable and then configure it in Advanced Billing For WHMCS.
Advanced Billing For WHMCS is used to collect information about hosting's resource usage.
Important: Product Auto Upgrade For WHMCS uses 'Change Package' functionality to switch the products. Therefore it is required that the products also support this feature.
|
Admin Area
Before you can do anything you must enable the products you want to work with for Advanced Billing.
|
Only then you have to enable the extension Product Auto Upgrade For WHMCS for each of the products. Move to 'Settings', find appropriate section and enable the extension.
|
Groups of Rules
As you might have already noticed, a new tab dedicated to the extension appeared on your Advanced Billing For WHMCS module main menu. Under this section there is located the whole management of the extension.
Let's move to 'Configuration' firstly.
|
What you will find there is a full list of autoscaling groups displayed.
Here you can find information such as status of a group, its name and used submodule. What is more, you can manage groups through using buttons in 'Actions' column to prepare rules for scaling services.
|
Let's see now how to create a new group.
Press 'Create New Group' button and a short formula will appear.
|
You can add products and define rules inside of the group which will result in upgrading/downgrading client's hosting.
Name your new group - this name is only for your information and convenience. Then select the product that can be automatically upgraded or downgraded according to resource usage count. Optionally, you can enable and choose configurable option group that will be used to define products options.
Save the group when it is ready.
|
Your newly created group appeared on the list. Now you can configure it according to your specific needs.
|
Group Configuration
There are two main sections where a group can be configured.
- 'Settings' - a place where general and client area configuration is set up.
- 'Options' - detailed configuration of rules to scale services automatically.
|
Group Settings
General Configuration
- Group Name - name of a group, can be changed at any time and is visible only to the admin.
- Server Type - module type of the product allowed in the group.
- Time Interval - minimum time period between the two products changes that can be made on a single hosting.
- Notifications Time Interval - defines time between notifications sent to a client.
|
|
Client Area Configuration
- Display Client Rules Configuration - shows rules of this group for clients with products configured in the group.
- Modify Rules Configuration - client can modify group rules, changes will affect their product only.
- Modify Time Interval - client can modify the minimum time between two switches on a single hosting.
- Allowed Time Interval Values - specifies what time interval a client can use (they will be displayed in the form of a dropdown menu or a textbox with a limited range).
- Enable Notifications - allows the client to enable/disable notifications.
- Modify Notifications Time Interval - allows the client to modify minimum time between two notifications.
- Allowed Notifications Time Interval Values - defines values which can be used by client.
Do not forget to save the configuration when it is ready.
|
Group Options
The second place where the group rules are configured is Options section.
These rules will be used by the extension to determine which service should be changed. Service will be changed according to the parameters set in rules options if the condition of either downgrade rules or upgrade rules has been met.
|
Every group has already some predefined basic options - disabled at the start. You can base your rules configuration on them or add your own ones in case they are not sufficient. Let us show how to set the autoscaling rules on the basis of these options.
Before you can do anything, you must configure the upgrade and downgarade rules.
|
'Upgrade Rules'/'Downgrade Rules' can have multiple rules defined.
To add a new rule, select it from a dropdown menu marked on the following screen and press 'Add'.
|
You can define comparison type and threshold of any added rule.
To add a rule which will be fulfilled when the product has more or equal than 3 FTP accounts, choose '≥' from 'Comparison Type' and type '3' into 'Threshold' field.
This example can be seen on the following screen.
|
You also have to define a product for each package that will be used when upgrading/downgrading. Press button marked on the screen to go on.
|
Select the product you need from the available in the dropdown menu.
Then select option you wish to be used by clients and add it. Save the changes.
Important! Options selection is available only if a supported configurable options group has been enabled for the group of rules on its creation.
|
Every selected option appears in the box above. Here you can specify available selection under 'Setting' or delete it.
|
Repeat that for all packages that you want to enable.
Note that only packages with selected products can be enabled!
|
Additionally, you can change the order the rules are displayed, simply drag and drop a rule and make a previously downgrade rule an upgrade.
|
Add new option, just type in its name, press 'Add New Option' and then configure it like the previous ones.
|
Finally, you can describe shortly each option. Press ' Description' and a text area will appear. Type in your description there. As you can see you can prepare a few language versions of the description.
|
Accounts
To access the list of hostings affected by the autoscaling groups proceed to 'Product Auto Upgrade' → 'Accounts'.
Information about each hosting can be found here along with access to the hosting history.
Press 'View History' near desired hosting to view its history of changes.
|
Hosting history contains the list of changes ever made for the hosting.
|
Client Area
In the following section we will show you client area with all autoscaling features enabled.
As you can see, autoscaling is displayed on the main page of a product right below the Advanced Billing For WHMCS usage records.
Press 'Show' to view details.
|
You can easily enable/disable autoscaling (red) or a selected option (blue) through pressing 'Enabled'/'Disabled' button and saving the changes.
To browse other options, use their names marked on the following screen.
|
Through pressing 'Show Rules' you can manage switching rules of currently displayed option.
Additionally, you can change the minimum interval between the changes through using marked field.
|
Rules are displayed in a table, press pencil icon next to the rule you wish to change.
Do not forget to save changes when you finish.
|
Besides the management of autoscaling, you can view the history of switches made on a hosting through pressing 'History'.
|
Notifications
Client can also set up notifications, they will be sent when requirements defined by a client are met.
For the settings shown on the following screen, notification will be sent once in ten minutes if the following rules are met.
The product number of Installed applications is equal or higher than 10.
|
Sample Usage
In this section we will show you a sample situation when Product Auto Upgrade For WHMCS is used simultaneously with another built-in extension to Advanced Billing - Recurring Billing.
|
Let's say you have configured 3 cPanel Extended products enabled for Advanced Billing.
|
Each of the products has different limits set:
- Product A: Max 4 FTP accounts and 500 MB storage.
- Product B: Max 10 FTP accounts and 1 GB storage.
- Product C: Max 20 FTP accounts and 5 GB storage.
Afterwards, you have created an autoscaling group, added products listed above to it and defined them with following rules.
|
- Product A - Lowest
- Upgrade Rule: ≥ 3 FTP accounts & ≥ 400 MB storage
- Product B - Middle
- Upgrade Rule: ≥ 9 FTP accounts & ≥ 8 GB storage
- Downgrade Rule: ≤ 3 FTP accounts & ≤ 300 MB storage
- Product C - Highest
- Downgrade Rule: ≤ 8 FTP accounts & ≤ 7 GB storage
|
|
Now, this is which is going to happen:
1. A client, John orders product C and creates 3 FTP accounts in it.
2. Advanced Billing cron job changes product C to product B with the first run, and further to product A in the second run (if provided minimum time interval has passed).
3. John uploads 450 MB of files, so now his product meets product A top rule requirement.
4. Cron runs again, and changes his product to product B.
5. John creates additional 7 FTP accounts and uploads files with total size of 550 MB.
6. Now, his product meets product B upgrade rules only partially, therefore cron run does nothing.
7. Some time passes and total amount of storage used by John reaches 8 GB.
8. This time his product meets product B upgrade rules completely and is updated to product C.
9. John removes 4 of his FTP accounts and 1 GB of files.
10. Therefore his product meets product C bottom rules requirements and is downgraded to product B.
|
That was all about upgrading/downgrading the products, but let us now see how the payments look like.
If your client orders product C and their product gets downgraded to product B, they will be billed with product C price.
However, if the prices and free limits are set per resources, you will help your clients to avoid additional payments if their resource usage is low.
If you do it this way, clients will pay fixed price each month, but additional payment will depend on the resource they use.
In case you own only limited amount of resources, Product Auto Upgrade For WHMCS extension will allow you to use them more efficiently. Whereas the core Advanced Billing For WHMCS features will let you bill your clients adequately.
|
Tips
1. If you want to allow access to a certain product only through automatic upgrade/downgrade of another product, you may set such product as hidden. Product Auto Upgrade For WHMCS allows configuration of hidden products.
|
Common Problems
1. When you have problems with connection, check whether your SELinux or firewall does not block ports.
|
2. In case you encounter any issues when enabling the extension, please make sure you are using Advanced Billing For WHMCS 3.1.3 or later. Product Auto Upgrade For WHMCS 2.0.0 is not supported by the previous versions of Advanced Billing.
|