|
|
@@ -315,6 +315,7 @@ namespace CallCenterApi.Interface.Controllers.Wiki
|
|
315
|
315
|
return Error("删除失败");
|
|
316
|
316
|
}
|
|
317
|
317
|
|
|
|
318
|
+
|
|
318
|
319
|
/// <summary>
|
|
319
|
320
|
/// 导出word
|
|
320
|
321
|
/// </summary>
|
|
|
@@ -322,12 +323,12 @@ namespace CallCenterApi.Interface.Controllers.Wiki
|
|
322
|
323
|
public ActionResult ExportWord(int id)
|
|
323
|
324
|
{
|
|
324
|
325
|
var aw = new AsposeWord();
|
|
325
|
|
- aw.OpenWithTemplate(Server.MapPath("/Upload/Word/部门职能模板.doc"));
|
|
326
|
|
- var dt = DB.DbHelperSQL.Query("select a.*,(select stuff((select ',' + F_FileName from T_Sys_Accessories where F_FileId in (a.F_File) for xml path('')),1,1,'')) as fileurl from T_Wiki_Functions a with(nolock) where a.F_Id=" + id).Tables[0];
|
|
|
326
|
+ aw.OpenWithTemplate(Server.MapPath("/Upload/Word/政策法规模板.doc"));
|
|
|
327
|
+ var dt = DB.DbHelperSQL.Query("select a.*,(select stuff((select ',' + F_FileName from T_Sys_Accessories where F_FileId in (a.F_File) for xml path('')),1,1,'')) as fileurl from T_Wiki_Policy a with(nolock) where a.F_Id=" + id).Tables[0];
|
|
327
|
328
|
string F_key = dt.Rows[0]["F_key"].ToString();
|
|
328
|
329
|
var dt2 = DB.DbHelperSQL.Query("SELECT * FROM View_KeysSplit WHERE id=" + F_key).Tables[0];
|
|
329
|
330
|
aw.Builder();
|
|
330
|
|
- aw.CreateDepartmentFunctionsWord(dt,dt2);
|
|
|
331
|
+ aw.CreateDepartmentFunctionsWord(dt, dt2);
|
|
331
|
332
|
var bt = aw.ExportAs();
|
|
332
|
333
|
Response.AppendHeader("Access-Control-Expose-Headers", "Content-Disposition");
|
|
333
|
334
|
return File(bt, "application/msword", DateTime.Now.Ticks.ToString() + ".doc");
|