问题描述
我使用来自 https://github.com/rap2hpoutre/fast-excel 的 Fast Excel 库,我可以将返回 ->download('file.xlsx') 返回到 Guzzle 发布请求吗?使用此代码我什么也得不到
$httpClient = new \GuzzleHttp\Client([
'headers' => [
'Authorization' => mdmTokenGenerate($token),'Accept' => 'application/json'
],'verify' => false
]);
$response = $httpClient->post(
"{$client->domain}/api/push",[
'multipart' => [
[
'name' => 'file','contents' => (new FastExcel(MasterNumbers::limit(1000)->get()))->download('file.xlsx')
]
]
]
);
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)