douyue4334 2016-06-22 04:38
浏览 268


I want to make export data into excel in my project, i have made it, but after I check the results, the results doesnt like what I want. here I would like to make a result there is a title table.

This code my controller:

public function getExport(){
        Excel::create('Export data', function($excel) {

        $excel->sheet('Sheet 1', function($sheet) {

            ->select("log_patrols.*"," as nama_companies"," as nama_security")
                foreach($products as $product) {
                 $data[] = array(

this my problem result : result

and it should be :


my problem is how to change the number into text what i want in the header table.

what improvements do i have to make to the code to achieve my goal?

NB : i use maatwebsite/excel

  • 写回答

1条回答 默认 最新


      相关推荐 更多相似问题


      • ¥15 vba代出现莫须有错误,都是一个个复制下来的为啥出错呢?
      • ¥15 /etc/vsftpd/vsftp.conf配置文件加了一行utf8_filesystem=YES之后,启动vsftpd报错
      • ¥15 W5100可以收广播,但是无法发出广播
      • ¥100 PCD点云排序和分割
      • ¥15 GG-CNN抓取数据集
      • ¥15 C++类和对象,多态性,继承,虚函数虚基类
      • ¥15 使用VS2019和Dev c++按%p输出地址,结果相差很大
      • ¥30 有偿解惑TINA老报错,求解惑
      • ¥15 arduino esp8266 编译问题
      • ¥15 metawrap画图报错