我通过Reports创建了一个自定义SQL特殊报告 - >特别报道 - >添加报告。创建"订单概述"我去报告 - >特别报道 - >订单概述我可以看到从DB获取的结果。
当我点击导出以创建CSV或Excel时出现问题,它会给我一个HTTP 500错误。我还增加了我的.htaccess文件memory_limit 1024M和max_execution_time 18000.概述只提取了12条记录,所以我不认为它与内存限制有关。
当看到ngix的error.log时,我得到以下内容,我无法弄清楚这究竟是什么意思。谷歌搜索也没有特定的内容。
2018/06/18 10:30:07 [error] 5236#5236: *73 FastCGI sent in stderr: "PHP
message: PHP Fatal error: Uncaught Error: Call to a member function
getReportCollection() on null in
/var/www/dev/.modman/kalenjordan_custom-reports/app/code/community/Clean/SqlReports/Block/Adminhtml/Customreport/View/Grid.php:38
Stack trace:
#0 /var/www/dev/.modman/kalenjordan_customreports/app/code/community/Clean/SqlReports/Block/Adminhtml/Customreport/View/Grid.php(77):
Clean_SqlReports_Block_Adminhtml_Customreport_View_Grid->_createCollection()
#1 /var/www/dev/htdocs/app/code/core/Mage/Adminhtml/Block/Widget/Grid.php(641): Clean_SqlReports_Block_Adminhtml_Customreport_View_Grid->_prepareColumns()
#2 /var/www/dev/htdocs/app/code/core/Mage/Adminhtml/Block/Widget/Grid.php(1014): Mage_Adminhtml_Block_Widget_Grid->_prepareGrid()
#3 /var/www/dev/.modman/mage-eag_mage-enhanced-admin-grids/app/code/community/BL/CustomGrid/Model/Grid/Exporter.php(89): Mage_Adminhtml_Block_Widget_Grid->getCsvFile()
#4 /var/www/dev/.modman/mage-eag_mage-enhanced-admin-grids/app/code/community/BL/CustomGrid/Model/Grid/Exp" while reading response header from upstream, client:
xx.xxx.xx.xxx, server: ~^(((?<storeview>.*)\.)?((?<subdomain>.*)\.)(?<domain>[^.]+)\.(?<tld>[^.]+))$, request:
"POST /index.php/mgadmin/blcg_grid/exportCsv/grid_id/168/profile_id/183/grid_js_object_name/reportsGridJsObject/key/949c8b2a8e1a760908a306702da21465/?isAjax=true HTTP/1.1",
upstream: "fastcgi://unix:/var/run/php/php7.0-fpm.sock:", host: "site.dev.living.nl", referrer: "https://site.dev.living.nl/index.php/mgadmin/adminhtml_customreport/viewtable/report_id/4/key/28458b96842129888ba9428fa290b62e/"
有趣的是,当我接到报告时 - &gt;特殊报告,其中包含所有报告的列表,然后单击导出CSV / Excel,它确实有效。
如果有人可以帮助我一点点,或者指出我的方向,那会非常有帮助。
罗伊