|
@@ -57,13 +57,13 @@ class UserService
|
|
|
|
|
|
public static function qappAddDesktop(int $uid, int $status)
|
|
public static function qappAddDesktop(int $uid, int $status)
|
|
{
|
|
{
|
|
- $key = "last_add_desktop_status_".$uid;
|
|
|
|
- $last_status = Cache::get($key, -1);
|
|
|
|
|
|
+ $key = "last_add_desktop_status";
|
|
|
|
+ $last_status = Redis::hget($key,$uid);
|
|
|
|
|
|
- if ($last_status > -1 && $last_status == $status){
|
|
|
|
|
|
+ if ($last_status != NULL && $last_status == $status){
|
|
return false;
|
|
return false;
|
|
}
|
|
}
|
|
- Cache::forever($key, $status);
|
|
|
|
|
|
+ Redis::hset($key,$uid,$status);
|
|
|
|
|
|
// myLog('incrAddDeskTop')->info('qappAddDesktop', compact('uid', 'status'));
|
|
// myLog('incrAddDeskTop')->info('qappAddDesktop', compact('uid', 'status'));
|
|
$log = QappUserAddDestop::where('uid', $uid)->orderBy('id', 'desc')->first();
|
|
$log = QappUserAddDestop::where('uid', $uid)->orderBy('id', 'desc')->first();
|