Commit 97745018 authored by hangjun83's avatar hangjun83

优化

parent 200c978b
......@@ -59,7 +59,8 @@ class ThirdPlatformJobCommand extends Command
$service = app(ThirdPlatformService::class);
switch($action_type){
case 'createPlatformToken' :
$service->createPlatformToken();
$token = $service->createPlatformToken();
var_dump($token);
break;
default:
}
......
......@@ -73,6 +73,7 @@ class AppServiceProvider extends ServiceProvider
\App\Console\Commands\BideJobCommand::class,
\App\Console\Commands\BjsJobCommand::class,
\App\Console\Commands\ZhenkhJobCommand::class,
\App\Console\Commands\ThirdPlatformJobCommand::class,
\App\Console\Commands\KafkaConsumerCommand::class,
\App\Console\Commands\TestJobCommand::class
]);
......
......@@ -37,5 +37,16 @@ class ThirdPlatformService extends PlatformAbstractService
}
return true;
}
public function createPlatformToken($platformName)
{
$this->setPlatformName($platformName);
$token = $this->getPlatformInfo('platform_token');
if($token){
$jwtToken = $this->generateToken($token);
return $jwtToken;
}
return null;
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment