|
|
@ -12,6 +12,7 @@ declare (strict_types=1); |
|
|
|
|
|
|
|
|
|
|
|
namespace app\store\model\dealer; |
|
|
|
namespace app\store\model\dealer; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
use app\common\enum\user\UserTypeEnum; |
|
|
|
use app\common\model\dealer\User as UserModel; |
|
|
|
use app\common\model\dealer\User as UserModel; |
|
|
|
use app\store\model\dealer\Apply as ApplyModel; |
|
|
|
use app\store\model\dealer\Apply as ApplyModel; |
|
|
|
use app\store\model\dealer\Referee as RefereeModel; |
|
|
|
use app\store\model\dealer\Referee as RefereeModel; |
|
|
@ -89,6 +90,9 @@ class User extends UserModel |
|
|
|
// 删除申请记录 |
|
|
|
// 删除申请记录 |
|
|
|
$applyModel = new ApplyModel(); |
|
|
|
$applyModel = new ApplyModel(); |
|
|
|
$applyModel->where(['user_id' => $this['user_id']])->delete(); |
|
|
|
$applyModel->where(['user_id' => $this['user_id']])->delete(); |
|
|
|
|
|
|
|
//修改会员身份 |
|
|
|
|
|
|
|
$userModel = new \app\common\model\User(); |
|
|
|
|
|
|
|
$userModel->where(['user_id' => $this['user_id']])->save(['user_type' => UserTypeEnum::NORMAL, 'fx_effective_time' => null]); |
|
|
|
$this->onDeleteReferee($this['user_id']); |
|
|
|
$this->onDeleteReferee($this['user_id']); |
|
|
|
// 标记当前分销商记录为已删除 |
|
|
|
// 标记当前分销商记录为已删除 |
|
|
|
return $this->delete(); |
|
|
|
return $this->delete(); |
|
|
|