Mining.php 690 B

123456789101112131415161718192021
  1. <?php
  2. /**
  3. * Statistics.php
  4. * 统计数据
  5. * Created by: Owen
  6. * Created on: 2019/7/12 11:34
  7. * Description:
  8. *
  9. */
  10. use \GatewayWorker\Lib\Gateway;
  11. require_once "./GatewayWorker/Function/Init.php";
  12. Class MiningCrazyWorker extends Init {
  13. public function Up($client_id,$data){
  14. $reqId = isset($data['httpIdentifier']) ? $data['httpIdentifier'] : '';
  15. $uid = intval($data['uid']);
  16. $levelId = intval($data['levelId']);
  17. $data = oo::commonOprModel('mining')->UpdateMining($uid,$levelId);
  18. Gateway::sendToClient($client_id,$this->encryp(json_encode(['cmd'=>array_search('Mining_Up_Rec',ocmd::$Cmd),'data'=>$data, 'httpIdentifier' => $reqId])));
  19. }
  20. }