data = $data; } public function headings(): array { return [ 'id', '姓名', '头像', '手机', '性别', '年龄代', '婚恋状态', '信仰', '出生地', '工作地', '学历', '分享人', '申请时间', ]; } //设置列格式 public function columnFormats(): array { return [ 'A' => NumberFormat::FORMAT_TEXT, ]; } public function collection() { $data = collect($this->data); return $data; } }