BatchCustomSendMsgsTransformers.php 2.5 KB

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. namespace App\Http\Controllers\Manage\OfficialAccount\Transformers;
  3. class BatchCustomSendMsgsTransformers
  4. {
  5. public function transform($batchCustomSendMsgs){
  6. return [
  7. 'id' => isset($batchCustomSendMsgs->id)?$batchCustomSendMsgs->id:'',
  8. 'name' => isset($batchCustomSendMsgs->name)?$batchCustomSendMsgs->name:'',
  9. 'create_time' => isset($batchCustomSendMsgs->create_time)?$batchCustomSendMsgs->create_time:'',
  10. 'send_time' => isset($batchCustomSendMsgs->send_time)?$batchCustomSendMsgs->send_time:'',
  11. 'content' => isset($batchCustomSendMsgs->content)?$batchCustomSendMsgs->content:'',
  12. 'redirect_url' => isset($batchCustomSendMsgs->redirect_url)?$batchCustomSendMsgs->redirect_url:'',
  13. 'status' => isset($batchCustomSendMsgs->status)?$batchCustomSendMsgs->status:'',
  14. 'subscribe_time' => isset($batchCustomSendMsgs->subscribe_time)?$batchCustomSendMsgs->subscribe_time:'',
  15. 'sex' => isset($batchCustomSendMsgs->sex)?$batchCustomSendMsgs->sex:'',
  16. 'balance' => isset($batchCustomSendMsgs->balance)?$batchCustomSendMsgs->balance:'',
  17. 'order_type' => isset($batchCustomSendMsgs->order_type)?$batchCustomSendMsgs->order_type:'',
  18. 'category_id' => isset($batchCustomSendMsgs->category_id)?$batchCustomSendMsgs->category_id:'',
  19. 'user_num' => isset($batchCustomSendMsgs->user_num)?$batchCustomSendMsgs->user_num:'',
  20. 'is_full_send' => isset($batchCustomSendMsgs->is_full_send)?$batchCustomSendMsgs->is_full_send:'',
  21. 'book_names' => isset($batchCustomSendMsgs->book_names)?$batchCustomSendMsgs->book_names:'',
  22. 'bids' => isset($batchCustomSendMsgs->bids)?$batchCustomSendMsgs->bids:'',
  23. 'pv' => isset($batchCustomSendMsgs->pv)?$batchCustomSendMsgs->pv:'',
  24. 'uv' => isset($batchCustomSendMsgs->uv)?$batchCustomSendMsgs->uv:'',
  25. 'pay_user_num' => isset($batchCustomSendMsgs->pay_user_num)?$batchCustomSendMsgs->pay_user_num:'',
  26. 'total_order_num' => isset($batchCustomSendMsgs->total_order_num)?$batchCustomSendMsgs->total_order_num:'',
  27. 'suc_order_num' => isset($batchCustomSendMsgs->suc_order_num)?$batchCustomSendMsgs->suc_order_num:'',
  28. 'success_order_sum' => isset($batchCustomSendMsgs->success_order_sum)?$batchCustomSendMsgs->success_order_sum:'',
  29. ];
  30. }
  31. }