2011-11-01 69 views
1

我想retrun使用RestEasy的文件,所以我有以下方法:RestEasy的:返回文件

@Path("/export/{id}/list.xlsx") 
@Produces("application/vnd.openxmlformats-officedocument.spreadsheetml.sheet") 
@GET 
@NoCache 
public Response exportList(
     @PathParam(value = "id") Long m, 
     @QueryParam("p1") String p1, 
     @QueryParam("p2") String p2, 
      ...... 
     ){...body...} 

的方法接受很多參數。 所以..它工作正常,但只在Mozila或Chrome。 IE建議我用一個奇怪的名字保存文件(不是list..xslx但整個url string)!當我按下「另存爲」時,我得到「SocketWriteError」。 有沒有人遇到過這樣的問題?也許它連接到巨大的參數列表? 謝謝。

回答

0

問題解決。刪除NoCache註釋)