edit username will edit on plan
This commit is contained in:
parent
938173cab7
commit
847f074a6b
@ -45,10 +45,6 @@ switch ($action) {
|
|||||||
if ($_app_stage != 'demo') {
|
if ($_app_stage != 'demo') {
|
||||||
if (file_exists($dvc)) {
|
if (file_exists($dvc)) {
|
||||||
require_once $dvc;
|
require_once $dvc;
|
||||||
$exp = $p['plan_expired'];
|
|
||||||
$p['plan_expired'] = 0;
|
|
||||||
(new $p['device'])->remove_customer($user, $p);
|
|
||||||
$p['plan_expired'] = $exp;
|
|
||||||
(new $p['device'])->add_customer($user, $p);
|
(new $p['device'])->add_customer($user, $p);
|
||||||
} else {
|
} else {
|
||||||
new Exception(Lang::T("Devices Not Found"));
|
new Exception(Lang::T("Devices Not Found"));
|
||||||
|
@ -577,12 +577,7 @@ switch ($action) {
|
|||||||
if (file_exists($dvc)) {
|
if (file_exists($dvc)) {
|
||||||
require_once $dvc;
|
require_once $dvc;
|
||||||
if ($userDiff) {
|
if ($userDiff) {
|
||||||
$c['username'] = $oldusername;
|
(new $p['device'])->change_username($p, $oldusername, $username);
|
||||||
$exp = $p['plan_expired'];
|
|
||||||
$p['plan_expired'] = 0;
|
|
||||||
(new $p['device'])->remove_customer($c, $p);
|
|
||||||
$c['username'] = $username;
|
|
||||||
$p['plan_expired'] = $exp;
|
|
||||||
}
|
}
|
||||||
(new $p['device'])->add_customer($c, $p);
|
(new $p['device'])->add_customer($c, $p);
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user