|
|
@@ -282,6 +282,8 @@ function cwp7_ClientArea($params) {
|
|
|
$response
|
|
|
);
|
|
|
}
|
|
|
+ cwp7CheckLimit($params,'test');
|
|
|
+
|
|
|
$domains = $response['result']['domains'];
|
|
|
$subDomains = $response['result']['subdomins'];
|
|
|
$clientInfo['domains'] = array();
|
|
|
@@ -1149,3 +1151,25 @@ function cwp7CheckSOA($domain, $nameserverIP, $nameserverName ) {
|
|
|
}
|
|
|
return $result->answer[0]->mname;
|
|
|
}
|
|
|
+
|
|
|
+/**
|
|
|
+ * Check limits for a service of an account .
|
|
|
+ *
|
|
|
+ * @param array $params common module parameters
|
|
|
+ * @param string $service target service for check
|
|
|
+ *
|
|
|
+ * @see https://developers.whmcs.com/provisioning-modules/supported-functions/
|
|
|
+ *
|
|
|
+ * @return bool 'none' -> not registered, 'self' -> registered at own or the name of an other responsible nameserver
|
|
|
+ */
|
|
|
+function cwp7CheckLimit($params, $service) {
|
|
|
+ $cwp7 = new cwp7_Admin($params['serverhostname'], $params['serveraccesshash']);
|
|
|
+ $response = $cwp7->getQuota($params['username']);
|
|
|
+ logModuleCall(
|
|
|
+ 'cwp7',
|
|
|
+ __FUNCTION__,
|
|
|
+ $response,
|
|
|
+ 'debug',
|
|
|
+ $service
|
|
|
+ );
|
|
|
+}
|