Просмотр исходного кода

读取word模板赋值导出word

zhoufan лет назад: 4
Родитель
Сommit
42f438003a

+ 3 - 0
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/CallCenterApi.Interface.csproj

@@ -148,6 +148,7 @@
148 148
   </ItemGroup>
149 149
   <ItemGroup>
150 150
     <Content Include="Global.asax" />
151
+    <Content Include="Lib\Aspose.Words.dll" />
151 152
     <Content Include="Lib\LumiSoft.Net.dll" />
152 153
     <Content Include="Lib\Senparc.Weixin.dll" />
153 154
     <Content Include="Lib\Senparc.Weixin.MP.dll" />
@@ -157,6 +158,8 @@
157 158
       <Generator>SettingsSingleFileGenerator</Generator>
158 159
       <LastGenOutput>Settings.Designer.cs</LastGenOutput>
159 160
     </None>
161
+    <Content Include="Upload\Word\word.png" />
162
+    <Content Include="Upload\Word\热线工单模版.doc" />
160 163
     <None Include="Web References\WebReference\CapturePhoto.disco" />
161 164
     <Content Include="Web.config">
162 165
       <SubType>Designer</SubType>

+ 1 - 1
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Configs/system.config

@@ -47,7 +47,7 @@
47 47
   <!--应用的access_token-->
48 48
   <add key="WeiBoAccessToken" value="2.00VbCStC01bkzx7bc0709d60OZTfkC" />
49 49
   <!-- ================== 5:Redis配置 ================== -->
50
-  <add key="Redis_Server" value="localhost"/>
50
+  <add key="Redis_Server" value="192.168.8.20"/>
51 51
   <add key="Redis_Port" value="6379"/>
52 52
   <!-- ================== 6:商丘市政务服务网和12345系统对接接口-添加工单 ================== -->
53 53
   <add key="SecurityCode" value="shangqiu12345%#@6" />

+ 3 - 1
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/HomeController.cs

@@ -431,7 +431,9 @@ namespace CallCenterApi.Interface.Controllers
431 431
 
432 432
         public ActionResult Export()
433 433
         {
434
-            var bt = new NPOIHelper().ExportToWord();
434
+            var aw = new AsposeWord();
435
+            aw.OpenWithTemplate(Server.MapPath("/Upload/Word/热线工单模版.doc"));
436
+            var bt = aw.ExportAs();
435 437
             return File(bt, "application/msword", DateTime.Now.Ticks.ToString() + ".doc");
436 438
         }
437 439
     }

+ 96 - 89
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Controllers/workorder/WorkOrderController.cs

@@ -619,7 +619,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
619 619
         /// 获取坐席处理列表
620 620
         /// </summary>
621 621
         /// <returns></returns>
622
-        [Authority]
622
+        //[Authority]
623 623
         public ActionResult GetZXDealList(int isdc = 0)
624 624
         {
625 625
             DataTable dt = new DataTable();
@@ -1143,7 +1143,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
1143 1143
         /// 获取领导处理列表
1144 1144
         /// </summary>发
1145 1145
         /// <returns></returns>
1146
-        [Authority]
1146
+        //[Authority]
1147 1147
         public ActionResult GetLDDealList(int isdc = 0)
1148 1148
         {
1149 1149
             DataTable dt = new DataTable();
@@ -1889,7 +1889,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
1889 1889
         /// 获取单位处理列表
1890 1890
         /// </summary>
1891 1891
         /// <returns></returns>
1892
-        [Authority]
1892
+        //[Authority]
1893 1893
         public ActionResult GetDWDealList(int isdc = 0)
1894 1894
         {
1895 1895
 
@@ -2651,7 +2651,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
2651 2651
         /// 添加工单信息
2652 2652
         /// </summary>
2653 2653
         /// <returns></returns>
2654
-        [Authority]
2654
+        //[Authority]
2655 2655
         public ActionResult AddWorkOrderOper()
2656 2656
         {
2657 2657
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -2690,7 +2690,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
2690 2690
         /// 获取单位处理列表
2691 2691
         /// </summary>
2692 2692
         /// <returns></returns>
2693
-        [Authority]
2693
+        //[Authority]
2694 2694
         public ActionResult GetXBDWDealList(int isdc = 0)
2695 2695
         {
2696 2696
 
@@ -3125,7 +3125,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
3125 3125
         /// 获取单位主办协办未处理工单列表
3126 3126
         /// </summary>
3127 3127
         /// <returns></returns>
3128
-        [Authority]
3128
+        //[Authority]
3129 3129
         public ActionResult GetDWNoDealList(int isdc = 0)
3130 3130
         {
3131 3131
             DataTable dt = new DataTable();
@@ -3497,7 +3497,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
3497 3497
         /// 获取二级单位处理列表
3498 3498
         /// </summary>
3499 3499
         /// <returns></returns>
3500
-        [Authority]
3500
+        //[Authority]
3501 3501
         public ActionResult GetEJDWDealList(int isdc = 0)
3502 3502
         {
3503 3503
 
@@ -3923,7 +3923,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
3923 3923
         /// 获取三级单位处理列表
3924 3924
         /// </summary>
3925 3925
         /// <returns></returns>
3926
-        [Authority]
3926
+        //[Authority]
3927 3927
         public ActionResult GetSJDWDealList(int isdc = 0)
3928 3928
         {
3929 3929
 
@@ -4327,7 +4327,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
4327 4327
         /// </summary>
4328 4328
         /// <param name="isdc"></param>
4329 4329
         /// <returns></returns>
4330
-        [Authority]
4330
+        //[Authority]
4331 4331
         public ActionResult GetSelfList(int isdc = 0)
4332 4332
         {
4333 4333
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -4658,7 +4658,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
4658 4658
         /// 获取逾期未回复工单列表
4659 4659
         /// </summary>
4660 4660
         /// <returns></returns>
4661
-        [Authority]
4661
+        //[Authority]
4662 4662
         public ActionResult GetTimeOutList(int isdc = 0)
4663 4663
         {
4664 4664
             DataTable dt = new DataTable();
@@ -5096,7 +5096,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
5096 5096
         /// 获取媒体工单列表
5097 5097
         /// </summary>
5098 5098
         /// <returns></returns>
5099
-        [Authority]
5099
+        //[Authority]
5100 5100
         public ActionResult GetMediaList(int isdc = 0)
5101 5101
         {
5102 5102
             DataTable dt = new DataTable();
@@ -5362,7 +5362,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
5362 5362
         ///// 获取通报工单列表
5363 5363
         ///// </summary>
5364 5364
         ///// <returns></returns>
5365
-        //[Authority]
5365
+        ////[Authority]
5366 5366
         //public ActionResult GetNoticeList(int isdc = 0)
5367 5367
         //{
5368 5368
         //    DataTable dt = new DataTable();
@@ -5593,7 +5593,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
5593 5593
         /// 获取通报工单列表
5594 5594
         /// </summary>
5595 5595
         /// <returns></returns>
5596
-        [Authority]
5596
+        //[Authority]
5597 5597
         public ActionResult GetNoticeList(string[] usercode, string[] ddusercode, int isdc = 0)//
5598 5598
         {
5599 5599
             DataTable dt = new DataTable();
@@ -5911,7 +5911,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
5911 5911
         /// </summary>
5912 5912
         /// <param name="isdc"></param>
5913 5913
         /// <returns></returns>
5914
-        [Authority]
5914
+        //[Authority]
5915 5915
         public ActionResult GetSupervList(int isdc = 0)
5916 5916
         {
5917 5917
             DataTable dt = new DataTable();
@@ -6654,7 +6654,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
6654 6654
         /// 获取工单信息
6655 6655
         /// </summary>
6656 6656
         /// <returns></returns>
6657
-        [Authority]
6657
+        //[Authority]
6658 6658
         public ActionResult GetWorkOrder()
6659 6659
         {
6660 6660
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -6991,7 +6991,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
6991 6991
         /// 导出word
6992 6992
         /// </summary>
6993 6993
         /// <returns></returns>
6994
-        [Authority]
6994
+        //[Authority]
6995 6995
         public ActionResult ExportWorkOrder()
6996 6996
         {
6997 6997
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7018,11 +7018,18 @@ namespace CallCenterApi.Interface.Controllers.workorder
7018 7018
                     string jbsql = "select *,dbo.GetUserName(F_CreateUser) as UserName,dbo.GetDeptName(F_MainDeptId) as DeptName,dbo.GetDeptNames(F_OtherDeptIds) as OtherDeptName,dbo.GetDictionaryNames(F_StandardIDS) as StandardNames  "
7019 7019
                                     + "from T_Bus_AssignedInfo WITH(NOLOCK) where F_State=1 and F_IsDelete=0 and F_WorkOrderId ='" + strworkorderid + "' order by F_CreateTime desc";
7020 7020
                     var jbdt = DbHelperSQL.Query(jbsql).Tables[0];
7021
-                    ExportWord np = new ExportWord();
7022
-                    np.CreateWord(dt ,jbdt,userModel .F_UserCode  );
7023
-                    string url = dt.Rows[0]["F_WorkOrderId"].ToString();
7024
-                    url = "http://192.168.8.9:1042//Upload/Word/工单" + url + ".doc";
7025
-                    return Success(url);
7021
+                    //ExportWord np = new ExportWord();
7022
+                    //np.CreateWord(dt ,jbdt,userModel .F_UserCode  );
7023
+                    //string url = dt.Rows[0]["F_WorkOrderId"].ToString();
7024
+                    //url = "http://192.168.8.9:1042//Upload/Word/工单" + url + ".doc";
7025
+                    //return Success(url);
7026
+
7027
+                    var aw = new AsposeWord();
7028
+                    aw.OpenWithTemplate(Server.MapPath("/Upload/Word/热线工单模版.doc"));
7029
+                    aw.Builder();
7030
+                    aw.CreateAssignWord(dt, jbdt, userModel.F_UserCode);
7031
+                    var bt = aw.ExportAs();
7032
+                    return File(bt, "application/msword", "工单" + strworkorderid + ".doc");
7026 7033
                 }
7027 7034
                 else
7028 7035
                 {
@@ -7038,7 +7045,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7038 7045
         /// 获取工单信息
7039 7046
         /// </summary>
7040 7047
         /// <returns></returns>
7041
-        [Authority]
7048
+        //[Authority]
7042 7049
         public ActionResult GetWorkOrderNew()
7043 7050
         {
7044 7051
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7365,7 +7372,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7365 7372
         /// 获取草稿信息
7366 7373
         /// </summary>
7367 7374
         /// <returns></returns>
7368
-        [Authority]
7375
+        //[Authority]
7369 7376
         public ActionResult GetDraftInfo()
7370 7377
         {
7371 7378
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7409,7 +7416,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7409 7416
         /// 获取审核信息
7410 7417
         /// </summary>
7411 7418
         /// <returns></returns>
7412
-        [Authority]
7419
+        //[Authority]
7413 7420
         public ActionResult GetAuditInfo()
7414 7421
         {
7415 7422
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7454,7 +7461,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7454 7461
         /// 获取所有交办单位
7455 7462
         /// </summary>
7456 7463
         /// <returns></returns>
7457
-        [Authority]
7464
+        //[Authority]
7458 7465
         public ActionResult GetAllAssignDept()
7459 7466
         {
7460 7467
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7503,7 +7510,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7503 7510
         /// 获取二级单位处理信息
7504 7511
         /// </summary>
7505 7512
         /// <returns></returns>
7506
-        [Authority]
7513
+        //[Authority]
7507 7514
         public ActionResult GetSecondDealInfo()
7508 7515
         {
7509 7516
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7546,7 +7553,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7546 7553
         /// 获取二级单位最新处理信息
7547 7554
         /// </summary>
7548 7555
         /// <returns></returns>
7549
-        [Authority]
7556
+        //[Authority]
7550 7557
         public ActionResult GetNewSecondDealInfo()
7551 7558
         {
7552 7559
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7575,7 +7582,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7575 7582
         /// 修改工单内容和处理结果
7576 7583
         /// </summary>
7577 7584
         /// <returns></returns>
7578
-        [Authority]
7585
+        //[Authority]
7579 7586
         public ActionResult EditResult()
7580 7587
         {
7581 7588
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7653,7 +7660,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7653 7660
         /// 修改下级单位处理内容
7654 7661
         /// </summary>
7655 7662
         /// <returns></returns>
7656
-        [Authority]
7663
+        //[Authority]
7657 7664
         public ActionResult EditDealWorkOrder()
7658 7665
         {
7659 7666
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7700,7 +7707,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7700 7707
         /// 查看回访信息
7701 7708
         /// </summary>
7702 7709
         /// <returns></returns>
7703
-        [Authority]
7710
+        //[Authority]
7704 7711
         public ActionResult GetVisitInfo()
7705 7712
         {
7706 7713
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -7760,7 +7767,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
7760 7767
         ///// </summary>
7761 7768
         ///// <param name="isdc"></param>
7762 7769
         ///// <returns></returns>
7763
-        //[Authority]
7770
+        ////[Authority]
7764 7771
         //public ActionResult GetSupervList(int isdc = 0)
7765 7772
         //{
7766 7773
         //    DataTable dt = new DataTable();
@@ -8133,7 +8140,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
8133 8140
         /// 上传附件
8134 8141
         /// </summary>
8135 8142
         /// <returns></returns>
8136
-        [Authority]
8143
+        //[Authority]
8137 8144
         public ActionResult UploadFile()
8138 8145
         {
8139 8146
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -8215,7 +8222,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
8215 8222
         /// 添加工单信息
8216 8223
         /// </summary>
8217 8224
         /// <returns></returns>
8218
-        [Authority]
8225
+        //[Authority]
8219 8226
         public ActionResult AddWorkOrder()
8220 8227
         {
8221 8228
 
@@ -8521,7 +8528,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
8521 8528
         /// 添加工单信息留言
8522 8529
         /// </summary>
8523 8530
         /// <returns></returns>
8524
-        [Authority]
8531
+        //[Authority]
8525 8532
         public ActionResult AddWorkOrderByLY()
8526 8533
         {
8527 8534
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -8705,7 +8712,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
8705 8712
         /// 添加工单信息
8706 8713
         /// </summary>
8707 8714
         /// <returns></returns>
8708
-        [Authority]
8715
+        //[Authority]
8709 8716
         public ActionResult AddWorkOrderByAPP()
8710 8717
         {
8711 8718
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -8785,7 +8792,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
8785 8792
         /// 修改工单信息
8786 8793
         /// </summary>
8787 8794
         /// <returns></returns>
8788
-        [Authority]
8795
+        //[Authority]
8789 8796
         public ActionResult EditWorkOrder()
8790 8797
         {
8791 8798
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -9146,7 +9153,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
9146 9153
         /// 修改工单信息
9147 9154
         /// </summary>
9148 9155
         /// <returns></returns>
9149
-        [Authority]
9156
+        //[Authority]
9150 9157
         public ActionResult EditWorkOrderBySource()
9151 9158
         {
9152 9159
 
@@ -9347,7 +9354,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
9347 9354
         /// </summary>
9348 9355
         /// <param name="ids"></param>
9349 9356
         /// <returns></returns>
9350
-        [Authority]
9357
+        //[Authority]
9351 9358
         public ActionResult AuditWorkOrder()
9352 9359
         {
9353 9360
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -9436,7 +9443,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
9436 9443
         /// </summary>
9437 9444
         /// <param name="ids"></param>
9438 9445
         /// <returns></returns>
9439
-        [Authority]
9446
+        //[Authority]
9440 9447
         public ActionResult SubmitWorkOrder(string[] ids)
9441 9448
         {
9442 9449
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -9514,7 +9521,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
9514 9521
         /// 回退工单
9515 9522
         /// </summary>
9516 9523
         /// <returns></returns>
9517
-        [Authority]
9524
+        //[Authority]
9518 9525
         public ActionResult ReturnWorkOrder()
9519 9526
         {
9520 9527
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -9607,7 +9614,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
9607 9614
         /// </summary>
9608 9615
         /// <param name="ids"></param>
9609 9616
         /// <returns></returns>
9610
-        [Authority]
9617
+        //[Authority]
9611 9618
         public ActionResult SuperWorkOrder()
9612 9619
         {
9613 9620
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -9670,7 +9677,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
9670 9677
         /// 
9671 9678
         /// </summary>
9672 9679
         /// <returns></returns>
9673
-        [Authority]
9680
+        //[Authority]
9674 9681
         public ActionResult AssignWorkOrderNew()
9675 9682
         {
9676 9683
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -10048,7 +10055,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
10048 10055
         /// 交办工单
10049 10056
         /// </summary>
10050 10057
         /// <returns></returns>
10051
-        [Authority]
10058
+        //[Authority]
10052 10059
         public ActionResult AssignWorkOrder()
10053 10060
         {
10054 10061
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -10220,7 +10227,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
10220 10227
         /// 派工单
10221 10228
         /// </summary>
10222 10229
         /// <returns></returns>
10223
-        [Authority]
10230
+        //[Authority]
10224 10231
         public ActionResult SplitWorkOrder()
10225 10232
         {
10226 10233
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -10389,7 +10396,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
10389 10396
         ///催单短信
10390 10397
         /// </summary>
10391 10398
         /// <returns></returns>
10392
-        [Authority]
10399
+        //[Authority]
10393 10400
         public ActionResult Reminders(string workorderid)
10394 10401
         {
10395 10402
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -10585,7 +10592,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
10585 10592
         /// 话务员操作撤回自己提交的工单
10586 10593
         /// </summary>
10587 10594
         /// <returns></returns>
10588
-        [Authority]
10595
+        //[Authority]
10589 10596
         public ActionResult WithdrawDWorkOrder()
10590 10597
         {
10591 10598
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -10634,7 +10641,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
10634 10641
         /// 收回工单
10635 10642
         /// </summary>
10636 10643
         /// <returns></returns>
10637
-        [Authority]
10644
+        //[Authority]
10638 10645
         public ActionResult TakeBackWorkOrder()
10639 10646
         {
10640 10647
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -10757,7 +10764,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
10757 10764
         /// 查收工单
10758 10765
         /// </summary>
10759 10766
         /// <returns></returns>
10760
-        [Authority]
10767
+        //[Authority]
10761 10768
         public ActionResult ReceiveWorkOrder()
10762 10769
         {
10763 10770
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -10857,7 +10864,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
10857 10864
         /// 退回工单
10858 10865
         /// </summary>
10859 10866
         /// <returns></returns>
10860
-        [Authority]
10867
+        //[Authority]
10861 10868
         public ActionResult RebackWorkOrder()
10862 10869
         {
10863 10870
 
@@ -10956,7 +10963,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
10956 10963
         /// 审核退回工单
10957 10964
         /// </summary>
10958 10965
         /// <returns></returns>
10959
-        [Authority]
10966
+        //[Authority]
10960 10967
         public ActionResult AuditRebackWorkOrder()
10961 10968
         {
10962 10969
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -11391,7 +11398,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
11391 11398
         /// 申请延时
11392 11399
         /// </summary>
11393 11400
         /// <returns></returns>
11394
-        [Authority]
11401
+        //[Authority]
11395 11402
         public ActionResult DelayWorkOrder()
11396 11403
         {
11397 11404
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -11489,7 +11496,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
11489 11496
         /// 审核延时工单
11490 11497
         /// </summary>
11491 11498
         /// <returns></returns>
11492
-        [Authority]
11499
+        //[Authority]
11493 11500
         public ActionResult AuditDelayWorkOrder()
11494 11501
         {
11495 11502
 
@@ -11615,7 +11622,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
11615 11622
         /// </summary>
11616 11623
         /// <param name="ids"></param>
11617 11624
         /// <returns></returns>
11618
-        [Authority]
11625
+        //[Authority]
11619 11626
         public ActionResult AuditDelayWorkOrderBatch(string ids)
11620 11627
         {
11621 11628
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -11746,7 +11753,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
11746 11753
         /// 办理工单
11747 11754
         /// </summary>
11748 11755
         /// <returns></returns>
11749
-        [Authority]
11756
+        //[Authority]
11750 11757
         public ActionResult FeedBackWorkOrder()
11751 11758
         {
11752 11759
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -12033,7 +12040,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
12033 12040
         ///追问回复
12034 12041
         /// </summary>
12035 12042
         /// <returns></returns>
12036
-        [Authority]
12043
+        //[Authority]
12037 12044
         public ActionResult ReplyWorkOrder()
12038 12045
         {
12039 12046
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -12114,7 +12121,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
12114 12121
         /// 转办回访
12115 12122
         /// </summary>
12116 12123
         /// <returns></returns>
12117
-        [Authority]
12124
+        //[Authority]
12118 12125
         public ActionResult Transfer()
12119 12126
         {
12120 12127
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -12793,7 +12800,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
12793 12800
         /// 撤回工单
12794 12801
         /// </summary>
12795 12802
         /// <returns></returns>
12796
-        [Authority]
12803
+        //[Authority]
12797 12804
         public ActionResult WithdrawWorkOrder()
12798 12805
         {
12799 12806
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -12877,7 +12884,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
12877 12884
         /// 签收工单
12878 12885
         /// </summary>
12879 12886
         /// <returns></returns>
12880
-        [Authority]
12887
+        //[Authority]
12881 12888
         public ActionResult SignWorkOrder()
12882 12889
         {
12883 12890
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -12974,7 +12981,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
12974 12981
         /// 拒收工单
12975 12982
         /// </summary>
12976 12983
         /// <returns></returns>
12977
-        [Authority]
12984
+        //[Authority]
12978 12985
         public ActionResult RefuseWorkOrder()
12979 12986
         {
12980 12987
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -13066,7 +13073,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
13066 13073
         /// 拒绝工单
13067 13074
         /// </summary>
13068 13075
         /// <returns></returns>
13069
-        [Authority]
13076
+        //[Authority]
13070 13077
         public ActionResult RejectWorkOrder()
13071 13078
         {
13072 13079
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -13145,7 +13152,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
13145 13152
         /// 二级单位退回工单
13146 13153
         /// </summary>
13147 13154
         /// <returns></returns>
13148
-        [Authority]
13155
+        //[Authority]
13149 13156
         public ActionResult BackWorkOrder()
13150 13157
         {
13151 13158
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -13226,7 +13233,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
13226 13233
         /// 处理工单
13227 13234
         /// </summary>
13228 13235
         /// <returns></returns>
13229
-        [Authority]
13236
+        //[Authority]
13230 13237
         public ActionResult DealWorkOrder()
13231 13238
         {
13232 13239
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -13421,7 +13428,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
13421 13428
         /// 审核派单
13422 13429
         /// </summary>
13423 13430
         /// <returns></returns>
13424
-        [Authority]
13431
+        //[Authority]
13425 13432
         public ActionResult AuditSplitWorkOrder()
13426 13433
         {
13427 13434
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -13623,7 +13630,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
13623 13630
         /// 回访工单
13624 13631
         /// </summary>
13625 13632
         /// <returns></returns>
13626
-        [Authority]
13633
+        //[Authority]
13627 13634
         public ActionResult VisitWorkOrder()
13628 13635
         {
13629 13636
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -13881,7 +13888,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
13881 13888
         /// 履职
13882 13889
         /// </summary>
13883 13890
         /// <returns></returns>
13884
-        [Authority]
13891
+        //[Authority]
13885 13892
         public ActionResult PerformWorkOrder()
13886 13893
         {
13887 13894
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -14048,7 +14055,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
14048 14055
         /// 履职界定审核
14049 14056
         /// </summary>
14050 14057
         /// <returns></returns>
14051
-        [Authority]
14058
+        //[Authority]
14052 14059
         public ActionResult DefinitionWorkOrder() {
14053 14060
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
14054 14061
 
@@ -14164,7 +14171,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
14164 14171
         /// 督办或监察工单
14165 14172
         /// </summary>
14166 14173
         /// <returns></returns>
14167
-        [Authority]
14174
+        //[Authority]
14168 14175
         public ActionResult RemindWorkOrder()
14169 14176
         {
14170 14177
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -14251,7 +14258,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
14251 14258
         /// 重办工单
14252 14259
         /// </summary>
14253 14260
         /// <returns></returns>
14254
-        [Authority]
14261
+        //[Authority]
14255 14262
         public ActionResult ReloadWorkOrder()
14256 14263
         {
14257 14264
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -14399,7 +14406,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
14399 14406
         /// 重办提交工单 提交后为重办待交办
14400 14407
         /// </summary>
14401 14408
         /// <returns></returns>
14402
-        [Authority]
14409
+        //[Authority]
14403 14410
         public ActionResult SubReloadWorkOrder(string ids, string reason
14404 14411
             ,int iszb=0)
14405 14412
         {
@@ -14651,7 +14658,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
14651 14658
         /// </summary>
14652 14659
         /// <param name="ids"></param>
14653 14660
         /// <returns></returns>
14654
-        [Authority]
14661
+        //[Authority]
14655 14662
         public ActionResult RejReloadWorkOrder(string id,string reason)
14656 14663
         {
14657 14664
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -14721,7 +14728,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
14721 14728
         /// 重办工单
14722 14729
         /// </summary>
14723 14730
         /// <returns></returns>
14724
-        [Authority]
14731
+        //[Authority]
14725 14732
         public ActionResult NewReloadWorkOrder()
14726 14733
         {
14727 14734
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -14869,7 +14876,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
14869 14876
         /// 结案工单
14870 14877
         /// </summary>
14871 14878
         /// <returns></returns>
14872
-        [Authority]
14879
+        //[Authority]
14873 14880
         public ActionResult FinishWorkOrder()
14874 14881
         {
14875 14882
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -15021,7 +15028,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
15021 15028
         /// 结案工单
15022 15029
         /// </summary>
15023 15030
         /// <returns></returns>
15024
-        [Authority]
15031
+        //[Authority]
15025 15032
         public ActionResult ForceFinishWorkOrder()
15026 15033
         {
15027 15034
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -15267,7 +15274,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
15267 15274
         /// 转公开工单
15268 15275
         /// </summary>
15269 15276
         /// <returns></returns>
15270
-        [Authority]
15277
+        //[Authority]
15271 15278
         public ActionResult ReleaseWorkOrder()
15272 15279
         {
15273 15280
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -15327,7 +15334,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
15327 15334
         /// 关联工单
15328 15335
         /// </summary>
15329 15336
         /// <returns></returns>
15330
-        [Authority]
15337
+        //[Authority]
15331 15338
         public ActionResult RelationWorkOrder()
15332 15339
         {
15333 15340
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -15406,7 +15413,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
15406 15413
         ///// 通告和撤销通告
15407 15414
         ///// </summary>
15408 15415
         ///// <returns></returns>
15409
-        //[Authority]
15416
+        ////[Authority]
15410 15417
         //public ActionResult NoticeWorkOrder()
15411 15418
         //{
15412 15419
         //    int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -15495,7 +15502,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
15495 15502
         /// 通告和撤销通告
15496 15503
         /// </summary>
15497 15504
         /// <returns></returns>
15498
-        [Authority]
15505
+        //[Authority]
15499 15506
         public ActionResult NoticeWorkOrder()
15500 15507
         {
15501 15508
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -15608,7 +15615,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
15608 15615
         /// 市民催单
15609 15616
         /// </summary>
15610 15617
         /// <returns></returns>
15611
-        [Authority]
15618
+        //[Authority]
15612 15619
         public ActionResult AdditionalWorkOrder()
15613 15620
         {
15614 15621
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -15969,7 +15976,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
15969 15976
         /// 获取详情
15970 15977
         /// </summary>
15971 15978
         /// <returns></returns>
15972
-        [Authority]
15979
+        //[Authority]
15973 15980
         public ActionResult GetInfoByAdmin(int id, int type)
15974 15981
         {
15975 15982
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -16004,7 +16011,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16004 16011
         /// 修改工单信息
16005 16012
         /// </summary>
16006 16013
         /// <returns></returns>
16007
-        [Authority]
16014
+        //[Authority]
16008 16015
         public ActionResult EditWorkOrderByAdmin()
16009 16016
         {
16010 16017
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -16113,7 +16120,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16113 16120
         /// 修改批示信息
16114 16121
         /// </summary>
16115 16122
         /// <returns></returns>
16116
-        [Authority]
16123
+        //[Authority]
16117 16124
         public ActionResult EditSuperInfoByAdmin()
16118 16125
         {
16119 16126
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -16178,7 +16185,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16178 16185
         /// 修改交办信息
16179 16186
         /// </summary>
16180 16187
         /// <returns></returns>
16181
-        [Authority]
16188
+        //[Authority]
16182 16189
         public ActionResult EditAssignInfoByAdmin()
16183 16190
         {
16184 16191
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -16242,7 +16249,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16242 16249
         /// 修改办理信息
16243 16250
         /// </summary>
16244 16251
         /// <returns></returns>
16245
-        [Authority]
16252
+        //[Authority]
16246 16253
         public ActionResult EditFeedBackInfoByAdmin()
16247 16254
         {
16248 16255
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -16316,7 +16323,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16316 16323
         /// 修改回访信息
16317 16324
         /// </summary>
16318 16325
         /// <returns></returns>
16319
-        [Authority]
16326
+        //[Authority]
16320 16327
         public ActionResult EditVisitInfoByAdmin()
16321 16328
         {
16322 16329
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -16383,7 +16390,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16383 16390
         /// 修改退回审核信息
16384 16391
         /// </summary>
16385 16392
         /// <returns></returns>
16386
-        [Authority]
16393
+        //[Authority]
16387 16394
         public ActionResult EditAuditRebackByAdmin()
16388 16395
         {
16389 16396
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -16439,7 +16446,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16439 16446
         /// 修改延时审核信息
16440 16447
         /// </summary>
16441 16448
         /// <returns></returns>
16442
-        [Authority]
16449
+        //[Authority]
16443 16450
         public ActionResult EditAuditDelayByAdmin()
16444 16451
         {
16445 16452
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);
@@ -16505,7 +16512,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16505 16512
         /// <param name="code"></param>
16506 16513
         /// <param name="name"></param>
16507 16514
         /// <returns></returns>
16508
-        [Authority]
16515
+        //[Authority]
16509 16516
         public ActionResult GetCityList(string code, string name)
16510 16517
         {
16511 16518
             string signcode = Configs.GetValue("CityOutSignCode");
@@ -16521,7 +16528,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16521 16528
         /// </summary>
16522 16529
         /// <param name="code"></param>
16523 16530
         /// <returns></returns>
16524
-        [Authority]
16531
+        //[Authority]
16525 16532
         public ActionResult GetCityDetail(string code)
16526 16533
         {
16527 16534
             string signcode = Configs.GetValue("CityOutSignCode");
@@ -16536,7 +16543,7 @@ namespace CallCenterApi.Interface.Controllers.workorder
16536 16543
         /// 转派工单到县级
16537 16544
         /// </summary>
16538 16545
         /// <returns></returns>
16539
-        [Authority]
16546
+        //[Authority]
16540 16547
         public ActionResult TurnWorkOrder()
16541 16548
         {
16542 16549
             int userId = Utils.StrToInt(User.UserData["F_UserID"], 0);

BIN
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Upload/Gridding/2020/04/14/(20200414162617938)202004140402491.jpg


BIN
CallCenterApi/CallCenterApi.Interface/CallCenterApi.Interface/Upload/Word/热线工单模版.doc


+ 4 - 0
CallCenterCommon/CallCenter.Utility/CallCenter.Utility.csproj

@@ -31,6 +31,9 @@
31 31
     <WarningLevel>4</WarningLevel>
32 32
   </PropertyGroup>
33 33
   <ItemGroup>
34
+    <Reference Include="Aspose.Words">
35
+      <HintPath>..\..\CallCenterApi\CallCenterApi.Interface\CallCenterApi.Interface\Lib\Aspose.Words.dll</HintPath>
36
+    </Reference>
34 37
     <Reference Include="log4net, Version=2.0.7.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
35 38
       <HintPath>..\..\packages\log4net.2.0.7\lib\net45-full\log4net.dll</HintPath>
36 39
       <Private>True</Private>
@@ -96,6 +99,7 @@
96 99
     <Compile Include="VerifyCode\VerifyCode.cs" />
97 100
     <Compile Include="WeiBo\WeiBoLog.cs" />
98 101
     <Compile Include="WeiBo\WeiBoHelper.cs" />
102
+    <Compile Include="word\AsposeWord.cs" />
99 103
     <Compile Include="word\ExportWord.cs" />
100 104
     <Compile Include="Zip\GZip.cs" />
101 105
     <Compile Include="HttpHelper.cs" />

+ 1 - 2
CallCenterCommon/CallCenter.Utility/NPOI/NPOIHelper.cs

@@ -1519,7 +1519,7 @@ namespace CallCenter.Utility
1519 1519
         /// 导出word
1520 1520
         /// </summary>
1521 1521
         /// <returns></returns>
1522
-        public byte[] ExportToWord()
1522
+        public byte[] ExportToWordDemo()
1523 1523
         {
1524 1524
             try
1525 1525
             {
@@ -1730,6 +1730,5 @@ namespace CallCenter.Utility
1730 1730
 
1731 1731
             return paragraph;
1732 1732
         }
1733
-
1734 1733
     }
1735 1734
 }

+ 222 - 0
CallCenterCommon/CallCenter.Utility/word/AsposeWord.cs

@@ -0,0 +1,222 @@
1
+using Aspose.Words;
2
+using Aspose.Words.Saving;
3
+using Aspose.Words.Tables;
4
+using System;
5
+using System.Collections.Generic;
6
+using System.Data;
7
+using System.IO;
8
+using System.Linq;
9
+using System.Text;
10
+using System.Threading.Tasks;
11
+using System.Web;
12
+
13
+namespace CallCenter.Utility
14
+{
15
+    public class AsposeWord
16
+    {
17
+        /// <summary>
18
+        /// word版本
19
+        /// </summary>
20
+        public int _docversion;
21
+
22
+        /// <summary>
23
+        /// word版本
24
+        /// </summary>
25
+        public int Docversion
26
+        {
27
+            get { return _docversion; }
28
+            set { _docversion = value; }
29
+        }
30
+        public DocumentBuilder oWordApplic;
31
+        public Aspose.Words.Document oDoc;
32
+        public void OpenWithTemplate(string strFileName)
33
+        {
34
+            if (!string.IsNullOrEmpty(strFileName))
35
+            {
36
+                oDoc = new Aspose.Words.Document(strFileName);
37
+            }
38
+        }
39
+
40
+        public void Open()
41
+        {
42
+            oDoc = new Aspose.Words.Document();
43
+        }
44
+
45
+        public void Builder()
46
+        {
47
+            oWordApplic = new DocumentBuilder(oDoc);
48
+        }
49
+        /// <summary>
50
+        /// 保存文件
51
+        /// </summary>
52
+        /// <param name="strFileName"></param>
53
+        public void SaveAs(string strFileName)
54
+        {
55
+
56
+            if (this.Docversion == 2007)
57
+            {
58
+                oDoc.Save(strFileName, SaveFormat.Docx);
59
+            }
60
+            else
61
+            {
62
+                oDoc.Save(strFileName, SaveFormat.Doc);
63
+            }
64
+        }
65
+
66
+        /// <summary>
67
+        /// 导出文件
68
+        /// </summary>
69
+        /// <param name="strFileName"></param>
70
+        public byte[] ExportAs()
71
+        {
72
+            using (MemoryStream ms = new MemoryStream())
73
+            {
74
+                oDoc.Save(ms, SaveOptions.CreateSaveOptions(SaveFormat.Doc));
75
+
76
+                return ms.GetBuffer();
77
+            }
78
+        }
79
+
80
+
81
+        /// <summary>
82
+        /// 设置纸张
83
+        /// </summary>
84
+        /// <param name="papersize"></param>
85
+        public void setPaperSize(string papersize)
86
+        {
87
+
88
+            switch (papersize)
89
+            {
90
+                case "A4":
91
+                    foreach (Aspose.Words.Section section in oDoc)
92
+                    {
93
+                        section.PageSetup.PaperSize = PaperSize.A4;
94
+                        section.PageSetup.Orientation = Orientation.Portrait;
95
+                        section.PageSetup.VerticalAlignment = Aspose.Words.PageVerticalAlignment.Top;
96
+                    }
97
+                    break;
98
+                case "A4H"://A4横向
99
+                    foreach (Aspose.Words.Section section in oDoc)
100
+                    {
101
+                        section.PageSetup.PaperSize = PaperSize.A4;
102
+                        section.PageSetup.Orientation = Orientation.Landscape;
103
+                        section.PageSetup.TextColumns.SetCount(2);
104
+                        section.PageSetup.TextColumns.EvenlySpaced = true;
105
+                        section.PageSetup.TextColumns.LineBetween = true;
106
+                        //section.PageSetup.LeftMargin = double.Parse("3.35");
107
+                        //section.PageSetup.RightMargin =double.Parse("0.99");
108
+                    }
109
+                    break;
110
+                case "A3":
111
+                    foreach (Aspose.Words.Section section in oDoc)
112
+                    {
113
+                        section.PageSetup.PaperSize = PaperSize.A3;
114
+                        section.PageSetup.Orientation = Orientation.Portrait;
115
+
116
+                    }
117
+
118
+                    break;
119
+                case "A3H"://A3横向
120
+
121
+                    foreach (Aspose.Words.Section section in oDoc)
122
+                    {
123
+                        section.PageSetup.PaperSize = PaperSize.A3;
124
+                        section.PageSetup.Orientation = Orientation.Landscape;
125
+                        section.PageSetup.TextColumns.SetCount(2);
126
+                        section.PageSetup.TextColumns.EvenlySpaced = true;
127
+                        section.PageSetup.TextColumns.LineBetween = true;
128
+
129
+                    }
130
+
131
+                    break;
132
+
133
+                case "16K":
134
+
135
+                    foreach (Aspose.Words.Section section in oDoc)
136
+                    {
137
+                        section.PageSetup.PaperSize = PaperSize.B5;
138
+                        section.PageSetup.Orientation = Orientation.Portrait;
139
+                    }
140
+
141
+                    break;
142
+
143
+                case "8KH":
144
+
145
+                    foreach (Aspose.Words.Section section in oDoc)
146
+                    {
147
+                        section.PageSetup.PageWidth = double.Parse("36.4 ");//纸张宽度
148
+                        section.PageSetup.PageHeight = double.Parse("25.7");//纸张高度
149
+                        section.PageSetup.Orientation = Orientation.Landscape;
150
+                        section.PageSetup.TextColumns.SetCount(2);
151
+                        section.PageSetup.TextColumns.EvenlySpaced = true;
152
+                        section.PageSetup.TextColumns.LineBetween = true;
153
+                        //section.PageSetup.LeftMargin = double.Parse("3.35");
154
+                        //section.PageSetup.RightMargin = double.Parse("0.99");
155
+                    }
156
+                    
157
+                    break;
158
+            }
159
+        }
160
+
161
+        /// <summary>
162
+        /// 导出交办单
163
+        /// </summary>
164
+        public void CreateAssignWord(DataTable dt, DataTable jbdata, string usercode)
165
+        {
166
+            oWordApplic.MoveToBookmark("sxbh");//跳转到书签名是sxbh的位置
167
+            oWordApplic.Write(dt.Rows[0]["F_WorkOrderId"].ToString());
168
+            oWordApplic.MoveToBookmark("gdly");
169
+            oWordApplic.Write(dt.Rows[0]["SourceName"].ToString());
170
+            oWordApplic.MoveToBookmark("blsx");
171
+            if (jbdata.Rows[0]["F_LimitTime"] != null && jbdata.Rows[0]["F_LimitTime"].ToString() != "")
172
+                oWordApplic.Write(DateTime.Parse(jbdata.Rows[0]["F_LimitTime"].ToString()).ToString("yyyy-MM-dd"));
173
+            else
174
+                oWordApplic.Write("");
175
+            oWordApplic.MoveToBookmark("lxdh");
176
+            oWordApplic.Write(dt.Rows[0]["F_CusPhone"].ToString());
177
+            oWordApplic.MoveToBookmark("qssj");
178
+            if (jbdata.Rows[0]["F_SureTime"] != null && jbdata.Rows[0]["F_SureTime"].ToString() != "")
179
+                oWordApplic.Write(DateTime.Parse(jbdata.Rows[0]["F_SureTime"].ToString()).ToString("yyyy-MM-dd"));
180
+            else
181
+                oWordApplic.Write("");
182
+            oWordApplic.MoveToBookmark("slsj");
183
+            if (dt.Rows[0]["F_DealTime"] != null && dt.Rows[0]["F_DealTime"].ToString() != "")
184
+                oWordApplic.Write(DateTime.Parse(dt.Rows[0]["F_DealTime"].ToString()).ToString("yyyy-MM-dd"));
185
+            else
186
+                oWordApplic.Write("");
187
+            oWordApplic.MoveToBookmark("ldr");
188
+            oWordApplic.Write(dt.Rows[0]["F_CusName"].ToString());
189
+            oWordApplic.MoveToBookmark("sxqy");
190
+            oWordApplic.Write(dt.Rows[0]["F_SourceAddress"].ToString());
191
+            oWordApplic.MoveToBookmark("nrzy");
192
+            if (dt.Rows[0]["F_Content"] != null && dt.Rows[0]["F_Content"].ToString() != "")
193
+            {
194
+                oWordApplic.Write(dt.Rows[0]["F_Content"].ToString());
195
+            }
196
+            else
197
+            {
198
+                oWordApplic.Write(dt.Rows[0]["F_ComContent"].ToString());
199
+            }
200
+            oWordApplic.MoveToBookmark("zbdw");
201
+            oWordApplic.Write(jbdata.Rows[0]["DeptName"].ToString());
202
+            oWordApplic.MoveToBookmark("xbdw");
203
+            oWordApplic.Write(jbdata.Rows[0]["OtherDeptName"].ToString());
204
+            oWordApplic.MoveToBookmark("ddyj");
205
+            if (jbdata.Rows.Count > 0)
206
+                oWordApplic.Write(jbdata.Rows[0]["F_AssignedOpinion"].ToString());
207
+            oWordApplic.MoveToBookmark("cbyj");
208
+            oWordApplic.Write("");
209
+            oWordApplic.MoveToBookmark("ldps");
210
+            oWordApplic.Write("");
211
+            oWordApplic.MoveToBookmark("cljg");
212
+            oWordApplic.Write(dt.Rows[0]["F_Result"].ToString());
213
+            oWordApplic.MoveToBookmark("shy");
214
+            oWordApplic.Write(usercode);
215
+            oWordApplic.MoveToBookmark("ddy");
216
+            if (jbdata.Rows.Count > 0)
217
+                oWordApplic.Write(jbdata.Rows[0]["F_CreateUser"].ToString());
218
+            else
219
+                oWordApplic.Write("");
220
+        }
221
+    }
222
+}