12345678910111213141516171819202122232425262728293031323334353637383940414243 |
- <?php
- namespace app\command;
- use think\console\Command;
- use think\console\Input;
- use think\console\Output;
- use think\facade\Cache;
- class HandleDataScreen extends Command
- {
- protected function configure()
- {
- $this->setName('handle_data_screen')
- ->setDescription('处理数据大屏的统计数据');
- }
- protected function execute(Input $input, Output $output)
- {
- $key = 'wfwfwf';
- // $data = [
- // 'a'=>[
- // ['name'=>'a','age'=>3],
- // ['name'=>'b','age'=>4],
- // ],
- // 'bb'=>'bbbb',
- // 'ccc'=>['item'=>9999]
- // ];
- $rs = Cache::store('redis')->handler()->hmset($key,['name'=>'张三','age'=>23]);
- halt($rs);
- }
- }
|