cy
2022-06-23 b83c40548208609d0d6826be13d742c28a784806
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
package cn.ksource.web.controller.business.pages.health;
 
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
 
import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
 
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.servlet.ModelAndView;
 
import cn.ksource.beans.GG_RECORD;
import cn.ksource.beans.HEALTH_CUSTOMER_COMMONS_CATEGORY;
import cn.ksource.beans.HEALTH_CUSTOMER_COMMONS_ITEM;
import cn.ksource.beans.SC_PARTNER_CUSTOMER_INFO;
import cn.ksource.beans.SC_WORKFLOW_CI_HEALTH;
import cn.ksource.beans.SC_WORKFLOW_CI_HEALTH_CIDETAIL;
import cn.ksource.beans.SC_WORKFLOW_ITEM_HEALTH_CIDETAIL;
import cn.ksource.beans.WORKFLOW_BASE;
import cn.ksource.beans.WORKFLOW_NODE;
import cn.ksource.core.page.PageInfo;
import cn.ksource.core.util.ConvertUtil;
import cn.ksource.core.util.DateUtil;
import cn.ksource.core.util.JsonUtil;
import cn.ksource.core.util.ParamsMapUtil;
import cn.ksource.core.util.StringUtil;
import cn.ksource.core.util.TreeUtil;
import cn.ksource.core.web.SysInfo;
import cn.ksource.core.web.SysInfoMsg;
import cn.ksource.core.web.WebUtil;
import cn.ksource.core.workflow.WorkflowCoreService;
import cn.ksource.web.Constants;
import cn.ksource.web.facade.health.HealthFacade;
import cn.ksource.web.facade.incident.IncidentFacade;
import cn.ksource.web.service.DataDictionaryService;
import cn.ksource.web.service.file.FileService;
import cn.ksource.web.service.record.RecordService;
import cn.ksource.web.service.workFlowSupport.WorkFlowSupportService;
 
@Controller
@RequestMapping("/business/pages/health")
@SuppressWarnings({"rawtypes"})
public class HealthController {
 
    @Resource
    private HealthFacade healthFacade;
    @Resource
    private DataDictionaryService dicService;
    @Resource
    private WorkflowCoreService workflowCoreService;
    @Resource
    private WorkFlowSupportService workFlowSupportService;
    @Resource
    private FileService fileService;
    @Resource
    private IncidentFacade incidentFacade;
    @Resource
    private RecordService recordService;
    
    /**
     * 计划列表
     * @param model
     * @param request
     * @return
     * @author chenlong
     */
    @RequestMapping("healthPlanList.html")
    public String healthPlanList(Model model,HttpServletRequest request) {
        return "/business/pages/health/healthPlanList";
    }
    
    @RequestMapping("healthPlanData.html")
    public String healthPlanData(PageInfo pageInfo,Model model,HttpServletRequest request) {
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        pageInfo = healthFacade.getHealthPlanData(pageInfo,params);
        model.addAttribute("pageInfo", pageInfo);
        return "/business/pages/health/healthPlanData";
    }
    
    @RequestMapping("healthPlanCount.html")
    public void healthPlanCount(Model model,HttpServletRequest request,HttpServletResponse response) {
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        WebUtil.write(response, healthFacade.getHealthPlanCount(params).toString());
    }
    
    
    /**
     * 新增/编辑计划
     * @return
     * @author chenlong
     */
    @RequestMapping(value="editHealthPlan.html",method=RequestMethod.GET)
    public String editHealthPlan(Model model,HttpServletRequest request){
        Map info = new HashMap();
        String id = request.getParameter("id");
        if(StringUtil.isNotBlank(id)){
            info = healthFacade.getHealthPlanById(id);
        }
        model.addAttribute("info", info);
        return "/business/pages/health/editHealthPlan";
    }
    
    @RequestMapping(value="editHealthPlan.html",method=RequestMethod.POST)
    public ModelAndView doEditHealthPlan(Model model,HttpServletRequest request){
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        healthFacade.saveHealthPlan(params);
        String js = "window.top.query();"
                + "window.top.hideDialog('0');";
        return WebUtil.sysInfoPage(request, "操作成功!",
                js,
                SysInfo.Success,"");
    }
    
    /**
     * 禁用/启用计划
     * @return
     * @author lixiang
     */
    @RequestMapping("delHealthPlan.html")
    public void delHealthPlan(HttpServletRequest request,HttpServletResponse response){
        Map<String, String> param = ParamsMapUtil.getParameterMap(request);
        healthFacade.delHealthPlan(param);
        WebUtil.write(response, "1");
    }
    
    /**
     * 健康检查配置列表
     * @param model
     * @param request
     * @return
     * @author chenlong
     */
    @RequestMapping("healthCfgList.html")
    public String healthCfgList(Model model,HttpServletRequest request) {
        return "/business/pages/health/healthCfgList";
    }
    
    @RequestMapping("healthCfgData.html")
    public String healthCfgData(PageInfo pageInfo,Model model,HttpServletRequest request) {
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        pageInfo = healthFacade.getHealthCfgData(pageInfo,params);
        model.addAttribute("pageInfo", pageInfo);
        return "/business/pages/health/healthCfgData";
    }
    
    @RequestMapping("healthCfgCount.html")
    public void healthCfgCount(Model model,HttpServletRequest request,HttpServletResponse response) {
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        WebUtil.write(response, healthFacade.getHealthCfgCount(params).toString());
    }
    
    
    /**
     * 跳转到指标分类列表
     * @param request
     * @return
     * @author liusen
     */
    @RequestMapping("getCommonsList.html")
    public ModelAndView getCommonsList(HttpServletRequest request){
        ModelAndView view = new ModelAndView("/business/pages/health/getCommonsList");
        return view;
    }
    /**
     * 指标分类列表数据
     * @param request
     * @return
     * @author liusen
     */
    @RequestMapping("healthCateData.html")
    public ModelAndView healthCateData(HttpServletRequest request){
        ModelAndView view = new ModelAndView("/business/pages/health/healthCateData");
        Map<String, String> param = ParamsMapUtil.getParameterMap(request);
        List commonsList=healthFacade.getCommonsList(param);
        view.addObject("commonsList", commonsList);
        return view;
    }
    
    /**
     * 跳转到添加指标分类页面
     * @param request
     * @return
     * @author liusen
     */
    @RequestMapping("addCommons.html")
    public ModelAndView addCommons(HttpServletRequest request){
        ModelAndView view = new ModelAndView("/business/pages/health/addCommons");
        return view;
    }
    
    /**
     * 跳转到修改指标分类页面
     * @param request
     * @return
     * @author liusen
     */
    @RequestMapping("updateCommons.html")
    public ModelAndView updateCommons(HttpServletRequest request){
        ModelAndView view = new ModelAndView("/business/pages/health/updateCommons");
        Map<String, String> param = ParamsMapUtil.getParameterMap(request);
        Map item=healthFacade.getCommons(param);
        view.addObject("item", item);
        return view;
    }
    
    /**
     * 添加(修改)指标分类
     * @param request
     * @return
     * @author liusen
     */
    @RequestMapping("saveOrUpdateCommons.html")
    public ModelAndView saveOrUpdateCommons(HttpServletRequest request,HEALTH_CUSTOMER_COMMONS_CATEGORY commons){
        Map<String, String> param = ParamsMapUtil.getParameterMap(request);
        String id=param.get("id");
        if(StringUtil.notEmpty(id)){
            commons.update();
        }else{
            healthFacade.saveCommons(param);
        }
        return WebUtil.sysInfoPage(request, "操作成功!",
                "window.top.hideDialog('0');window.top.query();",
                SysInfo.Success,"");
    }
    
    /**
     * 跳转到添加通用指标页面
     * @param request
     * @return
     * @author liusen
     */
    @RequestMapping("addCommonItem.html")
    public ModelAndView addCommonItem(HttpServletRequest request){
        ModelAndView view = new ModelAndView("/business/pages/health/addCommonItem");
        return view;
    }
    
    /**
     * 添加(修改)通用指标
     * @param request
     * @return
     * @author liusen
     */
    @RequestMapping("saveOrUpdateItem.html")
    public ModelAndView saveOrUpdateItem(HttpServletRequest request,HEALTH_CUSTOMER_COMMONS_ITEM item){
        Map<String, String> param = ParamsMapUtil.getParameterMap(request);
        String id =param.get("id");
        String categoryId=param.get("categoryId");
        if(StringUtil.notEmpty(id)){
            item.update();
        }else{
            healthFacade.saveCommonItem(param);
        }
        return WebUtil.sysInfoPage(request, "操作成功!",
                "window.top.query();window.top.hideDialog('1');",
                SysInfo.Success,"");
        }
    
    /**
     * 跳转到修改通用指标页面
     * @param request
     * @return
     * @author liusen
     */
    @RequestMapping("updateCommonItem.html")
    public  ModelAndView updateCommonItem(HttpServletRequest request){
        ModelAndView view = new ModelAndView("/business/pages/health/updateCommonItem");
        Map<String, String> param = ParamsMapUtil.getParameterMap(request);
        Map item=healthFacade.getCommonItem(param);
        view.addObject("item", item);
        return view;
    }
    
    /**
     * 启用/禁用指标分类
     * 
     * @author liusen
     */
    @RequestMapping("deleteCommons.html")
    public void deleteCommons(HttpServletRequest request,HttpServletResponse response){
        Map<String, String> param = ParamsMapUtil.getParameterMap(request);
        healthFacade.deleteCommons(param);
        WebUtil.write(response, "1");
    }
    
    /**
     * 禁用/启用通用指标
     * @param request
     * @author liusen
     */
    @RequestMapping("deleteCommonItem.html")
    public void deleteCommonItem(HttpServletRequest request,HttpServletResponse response){
        Map<String, String> param = ParamsMapUtil.getParameterMap(request);
        healthFacade.deleteCommonItem(param);
        WebUtil.write(response, "1");
    }
    /**
     * 设备列表
     * @param request
     * @author peikezhan
     */
    @RequestMapping("selCfgList.html")
    public ModelAndView selCfgList(HttpServletRequest request){
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        ModelAndView view = new ModelAndView("/business/pages/health/selCfgList");
        List list=healthFacade.querySelCfgList(params);
        view.addObject("list", list);
        return view;
    }
    /**
     * 为计划添加设备
     * @author peikezhan
     */
    @RequestMapping("doAddDevice.html")
    public void doAddDevice(HttpServletRequest request,HttpServletResponse response){
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        try {
            healthFacade.doAddDevice(params);
            WebUtil.write(response, "1");
        } catch (Exception e) {
            WebUtil.write(response, "0");
            e.printStackTrace();
        }
    }
    /**
     * 健康体检项目列表
     * @param reqeust
     * @return
     * @author peikezhan
     */
    @RequestMapping("getCiHealthItem.html")
    public ModelAndView getCiHealthItem(HttpServletRequest request){
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        ModelAndView view = new ModelAndView("/business/pages/health/getCiHealthItem");
        //查询设备信息和指标
        Map itemMap=healthFacade.getHealthItemList(params);
        view.addObject("itemMap", itemMap);
        return view;
    }
    /**
     * 设备指标维护
     * @param request
     * @author peikezhan
     */
    @RequestMapping("doeditDeviceItem.html")
    public void doeditDeviceItem(HttpServletRequest request,HttpServletResponse response){
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        healthFacade.doeditDeviceItem(params);
        WebUtil.write(response, "1");
    }
    /**
     * 禁用(启用)设备
     * @param request
     * @param response
     * @author peikezhan
     */
    @RequestMapping("delCi.html")
    public void delCi(HttpServletRequest request,HttpServletResponse response){
        healthFacade.deleteCi(request);
        WebUtil.write(response, "1");
    }
    /**
     * 健康体检计划
     * @param request
     * @return
     * @author peikezhan
     */
    @RequestMapping("healthPlanTimer.html")
    public ModelAndView healthPlanTimer(HttpServletRequest request){
        ModelAndView view = new ModelAndView("/business/pages/health/healthPlanTimer");
        Map item=healthFacade.getHealthPlan(request);
        String planId = request.getParameter("planId");
        String cusId = request.getParameter("cusId");
        List plans = healthFacade.getPlanTimer(cusId,planId);
        view.addObject("plans", plans);
        String planName = ConvertUtil.obj2StrBlank(item.get("PLAN_NAME"));
        view.addObject("planName", planName);
        
        return view;
    }
    /**
     * 跳转到添加周期页面
     * @param request
     * @return
     * @author peikezhan
     */
    @RequestMapping("addLeix.html")
    public ModelAndView  addLeix(HttpServletRequest request){
        ModelAndView view = new ModelAndView("/business/pages/health/addLeix");
        Map plan = healthFacade.getHealthPlan(request);
        view.addObject("item", plan);
        //查看项目是否已经过期
        String cusId = request.getParameter("cusId");
        SC_PARTNER_CUSTOMER_INFO customer = new SC_PARTNER_CUSTOMER_INFO(cusId).getInstanceById();
        long beginTime = customer.getValid_begin_date();
        long endTime = customer.getValid_end_date();
        long today = DateUtil.getCurrentDate8();
        
        if(beginTime<=today) {
            beginTime = today+1;
        }
        
        view.addObject("beginTime", beginTime);
        view.addObject("endTime", endTime);
        return view;
    }
    /**
     * 添加/修改计划周期
     * @param request
     * @return
     * @author peikezhan
     */
    @RequestMapping("updateLeix.html")
    public ModelAndView updateLeix(HttpServletRequest request){
        healthFacade.updatePlanLeix(request);
        return WebUtil.sysInfoPage(request, "操作成功!",
                "window.top.hideDialog('0');window.top.back();",
                SysInfo.Success,"");
    }
    /**
     * 添加指定日期体检计划
     * @param request
     *  @author peikezhan
     */
    @RequestMapping("addPlanTimer.html")
    public void addPlanTimer(HttpServletRequest request,HttpServletResponse response){
        String type=request.getParameter("type");
        if(type.equals("1")){
            healthFacade.addPlanTimer(request);
        }else{
            healthFacade.deletePlanTimer(request);
        }
        WebUtil.write(response, "1");
    }
    //****************************************************前台健康检查列表**************************************************************
    /**
     * 跳转到我的例行维保列表
     */
    @RequestMapping("myHealthList.html")
    public String myHealthList(Model model,HttpServletRequest request) {
        Map num = healthFacade.queryOrderCountByCate(request, Constants.WORKFLOW_BASE_BUSINESS_TYPE_CI_HEALTH.toString());
        model.addAttribute("num", num);
        //客户列表
        List<Map> cusList = incidentFacade.getCustomerList();        
        model.addAttribute("customerList", cusList);
        return "/business/pages/health/myHealthList";
    }
    /**
     * 查询我的事件列表
     */
    @RequestMapping("myHealthListData.html")
    public ModelAndView myHealthListData(HttpServletRequest request,HttpServletResponse response) {
        ModelAndView modelAndView = new ModelAndView("/business/pages/health/myHealthListData");
        List incidents = healthFacade.getMyHealthListData(request);
        modelAndView.addObject("orders", incidents);
        return modelAndView;
    }
    
    /**
     * 查询我的事件数量
     */
    @RequestMapping("myHealthListCount.html")
    public void myHealthListCount(HttpServletRequest request,HttpServletResponse response) {
        int count = healthFacade.getMyHealthListCount(request);
        WebUtil.write(response, String.valueOf(count));
    }
    /**
     * 健康检查流程
     */
    @RequestMapping("orderJumpPage.html")
    public String orderJumpPage(Model model,HttpServletRequest request,HttpServletResponse response){
        String orderId = request.getParameter("orderId");
        String flowId = request.getParameter("flowId");
        String userId=WebUtil.getUserId(request);
        String nodeId=healthFacade.queryNodeidByFlowId(flowId,userId);
        //String nodeId = request.getParameter("nodeId");
        model.addAttribute("orderId",orderId);
        model.addAttribute("flowId",flowId);
        model.addAttribute("nodeId",nodeId);
        String url = "";
        WORKFLOW_NODE node = new WORKFLOW_NODE(nodeId).getInstanceById();
        String nodeTemplateId = node.getNode_template_id();
        if(nodeTemplateId.equals(Constants.HEALTH_DISPATCH)){
            url =  "redirect:/business/pages/health/managerDispatch.html";  
        }else if(nodeTemplateId.equals(Constants.HEALTH_PATROL)){
            url =  "redirect:/business/pages/health/engineerDeal.html";  
        }else if(nodeTemplateId.equals(Constants.HEALTH_APPROVE)){
            url =  "redirect:/business/pages/health/managerApprove.html";  
        }
        return url;
    }
    /**
     * 获取表单信息
     * @param request
     */
    private void getOrderInfo(HttpServletRequest request,Model model){
        String orderId = request.getParameter("orderId");
        String nodeId = request.getParameter("nodeId");
        String flowId = request.getParameter("flowId");
        
        if(!StringUtil.notEmpty(flowId)) {
            SC_WORKFLOW_CI_HEALTH health = new SC_WORKFLOW_CI_HEALTH(orderId).getInstanceById();
            flowId = health.getFlow_id();
        }
        
        //是否已响应
        if(StringUtil.isNotBlank(nodeId)){
            WORKFLOW_NODE node = new WORKFLOW_NODE(nodeId).getInstanceById();
            model.addAttribute("isAdmin",node.getIs_admin());
            if(node.getFlowstate()==1){
                model.addAttribute("isAnswer","true");
            }
            //是否可发送到下一环节
            WORKFLOW_BASE base = new WORKFLOW_BASE(flowId).getInstanceById();
            boolean isCanFinish = workflowCoreService.isCanToNextNode(base, new WORKFLOW_NODE(nodeId).getInstanceById());
            model.addAttribute("isCanFinish",isCanFinish);
        }
 
        //流程信息
        Map orderFlowInfo = workFlowSupportService.getOrderFlowInfo(flowId);
        model.addAttribute("orderFlowInfo",orderFlowInfo);
    }
    
    /**
     * 工单分发
     * @param model
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="managerDispatch.html",method=RequestMethod.GET)
    public String managerDispatch(Model model,HttpServletRequest request, HttpServletResponse response){
        getOrderInfo(request,model);
        return "/business/pages/health/managerDispatch";
        
    } 
    
    /**
     * 提交(第一步)
     */
    @RequestMapping(value="managerDispatch.html",method=RequestMethod.POST)
    public ModelAndView doManagerDispatch(SC_WORKFLOW_CI_HEALTH health,HttpServletRequest request, HttpServletResponse response){
        SysInfoMsg msg = healthFacade.doDispatch(health,request);
        String flowId = request.getParameter("flowId");
        String nodeId = request.getParameter("nodeId");
        String userId=WebUtil.getLoginedUserId(request);
        String userName=WebUtil.getUserName(request);
        GG_RECORD record = new GG_RECORD();
        record.setDeal_content("指派人员:"+userName+"进行了人员指派");
        record.setDeal_time(DateUtil.getCurrentDate14());
        record.setDeal_user_id(userId);
        record.setDeal_user_name(userName);
        record.setBusiness_id(flowId);
        record.setNode_id(nodeId);
        recordService.addRecord(record);
        return WebUtil.sysInfoPage(request, "操作成功!",
                "",
                SysInfo.Success,"/business/pages/health/myHealthList.html",msg);
    } 
    /**
     * 工程师巡检
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="engineerDeal.html",method=RequestMethod.GET)
    public String engineerDeal(Model model,HttpServletRequest request, HttpServletResponse response){
        getOrderInfo(request,model);
        return "/business/pages/health/engineerDeal";
    }
    /**
     * 项目经理审批
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="managerApprove.html",method=RequestMethod.GET)
    public String managerApprove(Model model,HttpServletRequest request, HttpServletResponse response){
        getOrderInfo(request,model);
        return "/business/pages/health/managerApprove";
    }
    /**
     * 工单响应
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="nodeAnswer.html",method = RequestMethod.GET)
    public String nodeAnswer(Model model,HttpServletRequest request, HttpServletResponse response) {
        String nodeId = request.getParameter("nodeId");
        String flowId = request.getParameter("flowId");
        
        WORKFLOW_BASE base = new WORKFLOW_BASE(flowId).getInstanceById();
        WORKFLOW_NODE node = new WORKFLOW_NODE(nodeId).getInstanceById();
        String orderId = base.getBusiness_id();
        Map nodeMsgMap = new HashMap();
        model.addAttribute("orderName", base.getWfname());
        model.addAttribute("orderCode", base.getOrder_code());
        model.addAttribute("customerName", base.getCustomer_name());
        model.addAttribute("subCustomerName", base.getSub_customer_name());
        model.addAttribute("nodeName", node.getNodename());
        Map health = healthFacade.getHealthInfo(orderId);
        model.addAttribute("planDate", health.get("PLAN_EXE_DATE"));
        if(node.getFlow_type()==2){
            WORKFLOW_NODE backNode = new WORKFLOW_NODE(node.getSource_node_instance_id()).getInstanceById();
            model.addAttribute("backNote", backNode.getDeal_note());
        }
        return "/business/pages/health/nodeAnswer";
    }
    @RequestMapping(value="nodeAnswer.html", method=RequestMethod.POST)
    public void doAsnwer(HttpServletRequest request, HttpServletResponse response) {
        boolean flag = workFlowSupportService.nodeAnswer(request);
        if(flag){
            WebUtil.write(response, "1");
        }else{
            WebUtil.write(response, "2");
        }
    }
    /**
     * 基本信息(健康检查-人员指派,第一步提交)
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("dispatchHealthInfo.html")
    public String dispatchHealthInfo(Model model,HttpServletRequest request,HttpServletResponse response) {
        String orderId = request.getParameter("orderId");
        //基本信息
        if(StringUtil.isNotBlank(orderId)){
            Map health = healthFacade.getHealthInfo(orderId);
            model.addAttribute("health",health);
        }
        //需要查询设备peikezhan
        List<Map> ciList = healthFacade.getPatrolCiList(orderId);
        //查询该工单下的指标list
        List<Map> itemList = healthFacade.getPatrolIteamsList(orderId);
        //拼装设备和指标tree
        TreeUtil treeUtil = new TreeUtil();
        List treelist=treeUtil.createTreeByCate(ciList, itemList);
        model.addAttribute("ciList",treelist);
        return "/business/pages/health/dispatchHealthInfo";
    }
    /**
     * 人员指派提交页面
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("dispatchCommit.html")
    public ModelAndView serverCommit(HttpServletRequest request, HttpServletResponse response) {
        ModelAndView view = new ModelAndView("/business/pages/health/dispatchCommit");
        List<Map> resList = workFlowSupportService.getAllExecutors();
        view.addObject("resList",resList);
        return view;
    }
    /**
     * 增加巡检设备页面
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("addCiDialog.html")
    public ModelAndView addCiDialog(HttpServletRequest request, HttpServletResponse response) {
        ModelAndView view = new ModelAndView("/business/pages/health/addCiDialog");
        //查询设备
        List<Map> ciList = healthFacade.getHealthCiList(request);
        //查询该客户的所有可选item进行匹配
        List<Map> itemsList=healthFacade.getAllItemOfCus(request);
        TreeUtil treeUtil = new TreeUtil();
        List treeList=treeUtil.createTreeByLvlId(ciList, itemsList);
        view.addObject("ciList",treeList);
        return view;
    }
    /**
     * 查询设备下的item
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("selectItem.html")
    public ModelAndView selectItem(HttpServletRequest request, HttpServletResponse response) {
        Map<String, String> params = ParamsMapUtil.getParameterMap(request);
        ModelAndView view = new ModelAndView("/business/pages/health/editCiHealthItem");
        //查询该客户的所有可选item进行匹配
        Map itemMap=healthFacade.getAllItemOfDevice(params);
        view.addObject("itemMap",itemMap);
        return view;
    }
    /**
     * 健康检查明细
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="healthDetail.html",method=RequestMethod.GET)
    public String healthDetail(Model model,HttpServletRequest request, HttpServletResponse response){
        getOrderInfo(request,model);
        return "/business/pages/health/healthDetail";
    }
    /**
     * 处理信息(经理)
     * @param model
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("healthDealInfoRead.html")
    public String healthDealInfoRead(Model model,HttpServletRequest request, HttpServletResponse response) {
        String orderId = request.getParameter("orderId");
        Map health = healthFacade.getHealthInfo(orderId);
        List<Map> ciList = healthFacade.getCiPatrolItem(orderId);
        model.addAttribute("ciList", ciList);
        model.addAttribute("health", health);
        return "/business/pages/health/healthDealInfoRead";
    }
    
    /**
     * 处理信息(工程师)
     * @param model
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("healthDealInfo.html")
    public String healthDealInfo(Model model,HttpServletRequest request, HttpServletResponse response) {
        String orderId = request.getParameter("orderId");
        Map health = healthFacade.getHealthInfo(orderId);
        List<Map> ciList = healthFacade.getCiPatrolItem(orderId);
        model.addAttribute("ciList", ciList);
        model.addAttribute("health", health);
        return "/business/pages/health/healthDealInfo";
    }
    /**
     *工程师指标巡检
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="healthItemPatrol.html",method=RequestMethod.GET)
    public String healthItemPatrol(Model model,HttpServletRequest request, HttpServletResponse response) {
        String patrolItemId = request.getParameter("patrolItemId");
        String flowId = request.getParameter("flowId");
        Map info = healthFacade.getPatrolItemInfo(patrolItemId);
        List fileList = fileService.getFileList(patrolItemId);
        model.addAttribute("info", info);
        model.addAttribute("fileList", fileList);
        return "/business/pages/health/healthItemPatrol";
    }
    /**
     * 工程师巡检
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="healthItemPatrol.html",method=RequestMethod.POST)
    public ModelAndView doHealthItemPatrol(SC_WORKFLOW_ITEM_HEALTH_CIDETAIL ciItem,HttpServletRequest request, HttpServletResponse response) {
        String patrolItemId = request.getParameter("patrolItemId");
        String flowId = request.getParameter("flowId");
        
        Map user =     WebUtil.getLoginUser(request).getLoginUser();
        ciItem.setId(patrolItemId)
            .setUser_id(user.get("ID").toString())
            .setUser_name(user.get("ZSXM").toString())
            .update();
        //更新巡检数据
        fileService.uploadFile(request,patrolItemId,flowId,null,null,Constants.GG_FOLDERS_JKJCFOLDERS,Constants.FILE_STATE_SHTG,null);
        return WebUtil.sysInfoPage(request, "操作成功!",
                "window.top.hideDialog(1);window.top.document.getElementById('baseInfo').contentWindow.location.reload();",
                SysInfo.Success,"");
    }
    /**
     * 工程师设备巡检
     * @param model
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="healthCiPatrol.html",method=RequestMethod.GET)
    public String healthCiPatrol(Model model,HttpServletRequest request, HttpServletResponse response) {
        String patrolCiId = request.getParameter("patrolCiId");
        String flowId = request.getParameter("flowId");
        SC_WORKFLOW_CI_HEALTH_CIDETAIL info = new SC_WORKFLOW_CI_HEALTH_CIDETAIL(patrolCiId).getInstanceById();
        model.addAttribute("info", info);
        return "/business/pages/health/healthCiPatrol";
    }
    @RequestMapping(value="healthCiPatrol.html",method=RequestMethod.POST)
    public ModelAndView doHealthCiPatrol(SC_WORKFLOW_CI_HEALTH_CIDETAIL ciItem,HttpServletRequest request, HttpServletResponse response) {
        String patrolCiId = request.getParameter("patrolCiId");
        String flowId = request.getParameter("flowId");
        
        Map user =     WebUtil.getLoginUser(request).getLoginUser();
        ciItem.setId(patrolCiId)
            .setUser_id(user.get("ID").toString())
            .setUser_name(user.get("ZSXM").toString())
            .update();
        return WebUtil.sysInfoPage(request, "操作成功!",
                "window.top.hideDialog(1);",
                SysInfo.Success,"");
    }
    /**
     * 工程师提交页面
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("engineerCommit.html")
    public String engineerCommit(Model model,HttpServletRequest request, HttpServletResponse response) {
        String orderId = request.getParameter("orderId");
        String isAdmin = request.getParameter("isAdmin");
        if(isAdmin!=null&&isAdmin.equals("1")){
            List<Map> commonList = healthFacade.getCommonPatrolItem(orderId);
            model.addAttribute("commonList", commonList);
        }
        return "/business/pages/health/engineerCommit";
    }
    /**
     * 工程师巡检
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("doEngineerPatrol.html")
    public ModelAndView doEngineerPatrol(HttpServletRequest request, HttpServletResponse response) {
        SysInfoMsg msg = healthFacade.doSendToManager(request);
        String flowId = request.getParameter("flowId");
        String nodeId = request.getParameter("nodeId");
        String userId=WebUtil.getLoginedUserId(request);
        String userName=WebUtil.getUserName(request);
        GG_RECORD record = new GG_RECORD();
        record.setDeal_content("工程师巡检:"+userName+"进行了巡检");
        record.setDeal_time(DateUtil.getCurrentDate14());
        record.setDeal_user_id(userId);
        record.setDeal_user_name(userName);
        record.setBusiness_id(flowId);
        record.setNode_id(nodeId);
        recordService.addRecord(record);
        return WebUtil.sysInfoPage(request, "操作成功!",
                "window.top.hideDialog('0');",
                SysInfo.Success,"/business/pages/health/myHealthList.html",msg);
    }
    /**
     * 获取环节未执行人列表
     * @param request
     * @param response
     */
    @RequestMapping("getNotDealList.html")
    public void getNotDealList(HttpServletRequest request, HttpServletResponse response){
        String flowId = request.getParameter("flowId");
        List<Map> list = workFlowSupportService.getNotDealList(flowId);
        WebUtil.write(response, JsonUtil.list2Json(list));
    }
    /**
     *工程师指标巡检
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="healthItemPatrolRead.html",method=RequestMethod.GET)
    public String healthItemPatrolRead(Model model,HttpServletRequest request, HttpServletResponse response) {
        String patrolItemId = request.getParameter("patrolItemId");
        String flowId = request.getParameter("flowId");
        Map info = healthFacade.getPatrolItemInfo(patrolItemId);
        List fileList = fileService.getFileList(patrolItemId);
        model.addAttribute("info", info);
        model.addAttribute("fileList", fileList);
        return "/business/pages/health/healthItemPatrolRead";
    }
    @RequestMapping(value="healthCiPatrolRead.html",method=RequestMethod.GET)
    public String healthCiPatrolRead(Model model,HttpServletRequest request, HttpServletResponse response) {
        String patrolCiId = request.getParameter("patrolCiId");
        String flowId = request.getParameter("flowId");
        SC_WORKFLOW_CI_HEALTH_CIDETAIL info = new SC_WORKFLOW_CI_HEALTH_CIDETAIL(patrolCiId).getInstanceById();
        model.addAttribute("info", info);
        return "/business/pages/health/healthCiPatrolRead";
    }
    /**
     * 项目经理审批提交页面
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("ApproveCommit.html")
    public String ApproveCommit(HttpServletRequest request, HttpServletResponse response) {
        return "/business/pages/health/ApproveCommit";
    }
    /**
     * 结束流程
     * @param request
     * @param response
     * @return
     */
    @RequestMapping("doEndHealthFlow.html")
    public ModelAndView doEndHealthFlow(HttpServletRequest request, HttpServletResponse response) {
        healthFacade.doEndHealthFlow(request);
        String flowId = request.getParameter("flowId");
        String nodeId = request.getParameter("nodeId");
        String userId=WebUtil.getLoginedUserId(request);
        String userName=WebUtil.getUserName(request);
        GG_RECORD record = new GG_RECORD();
        record.setDeal_content("流程结束:"+userName+"进行了巡检审核");
        record.setDeal_time(DateUtil.getCurrentDate14());
        record.setDeal_user_id(userId);
        record.setDeal_user_name(userName);
        record.setBusiness_id(flowId);
        record.setNode_id(nodeId);
        recordService.addRecord(record);
        return WebUtil.sysInfoPage(request, "操作成功!",
                "window.top.hideDialog('0');",
                SysInfo.Success,"/business/pages/health/myHealthList.html");
    }
    /**
     * 回退
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="healthSendback.html",method=RequestMethod.GET)
    public ModelAndView healthSendback(HttpServletRequest request,HttpServletResponse response){
        ModelAndView view = new ModelAndView("/business/pages/health/remindSendback");
        String orderId = request.getParameter("orderId");
        String nodeId = request.getParameter("nodeId");
        String flowId = request.getParameter("flowId");
        String lastNodeTemplateId = "";
        lastNodeTemplateId = Constants.HEALTH_PATROL;
        view.addObject("lastNodeTemplateId",lastNodeTemplateId);
        view.addObject("orderId",orderId);
        view.addObject("flowId",flowId);
        view.addObject("nodeId",nodeId);
        
        return view;
    }
    @RequestMapping(value="healthSendback.html",method=RequestMethod.POST)
    public ModelAndView doHealthSendback(HttpServletRequest request,HttpServletResponse response){
        healthFacade.doSendback(request);
        String flowId = request.getParameter("flowId");
        String nodeId = request.getParameter("nodeId");
        String userId=WebUtil.getLoginedUserId(request);
        String userName=WebUtil.getUserName(request);
        GG_RECORD record = new GG_RECORD();
        record.setDeal_content("回退:"+userName+"进行了回退操作");
        record.setDeal_time(DateUtil.getCurrentDate14());
        record.setDeal_user_id(userId);
        record.setDeal_user_name(userName);
        record.setBusiness_id(flowId);
        record.setNode_id(nodeId);
        recordService.addRecord(record);
        return WebUtil.sysInfoPage(request, "操作成功!",
                "window.top.hideDialog('0');",
                SysInfo.Success,"/business/pages/health/myHealthList.html");
    }
    //***************************************************健康检查管理*************************************************************************
    /**
     * 服务台健康检查列表
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="healthList.html", method=RequestMethod.GET)
    public ModelAndView healthList(HttpServletRequest request, HttpServletResponse response) {
        List customerList = incidentFacade.getCustomerList();
        ModelAndView view = new ModelAndView("/business/pages/health/healthList");
        
        
        //查询进行中例行维护工单数量
        int jxzCount = healthFacade.queryJxzHealthOrderCount(request);
        
        //查询例行维护每个环节例行维护工单的数量
        Map nodeCount = healthFacade.queryHealthNodeCount(request);
        
        
        view.addObject("jxzCount", jxzCount);
        
        String ryzp = "0";
        String ggscl = "0";
        String zgsh = "0";
        if(null!=nodeCount && nodeCount.size()>0) {
            if(nodeCount.containsKey(Constants.HEALTH_DISPATCH)) {
                ryzp = ConvertUtil.obj2StrBlank(nodeCount.get(Constants.HEALTH_DISPATCH));
            }
            
            if(nodeCount.containsKey(Constants.HEALTH_PATROL)) {    
                ggscl = ConvertUtil.obj2StrBlank(nodeCount.get(Constants.HEALTH_PATROL));
            }
            
            if(nodeCount.containsKey(Constants.HEALTH_APPROVE)) {    
                zgsh = ConvertUtil.obj2StrBlank(nodeCount.get(Constants.HEALTH_APPROVE));
            }
        }
        view.addObject("ryzp", ryzp);
        view.addObject("ggscl", ggscl);
        view.addObject("zgsh", zgsh);
        view.addObject("customerList",customerList);
        
        
        
        return view;
    }
    /**
     * 查询工单列表
     */
    @RequestMapping(value="healthListData.html",method=RequestMethod.POST)
    public ModelAndView healthListData(HttpServletRequest request) {
        ModelAndView modelAndView = new ModelAndView("/business/pages/health/healthListData");
        List list = healthFacade.queryHealthOrderList(request);
        modelAndView.addObject("orders", list);
        return modelAndView;
    }
    
    /**
     * 查询例行维保工单总数量
     */
    @RequestMapping(value="healthListCount.html",method=RequestMethod.POST)
    public void healthListCount(HttpServletRequest request,HttpServletResponse response) {
        int count = healthFacade.queryHealthOrderCount(request);
        WebUtil.write(response, String.valueOf(count));
    }
    /**
     * 跳转到所属单位页面
     */
    @RequestMapping("cusHealthPlan.html")
    public ModelAndView cusItemPlan(HttpServletRequest request,HttpServletResponse response) {
        ModelAndView modelAndView = new ModelAndView("/business/pages/health/cusHealthPlan");
        List customerList = incidentFacade.getCustomerList();
        modelAndView.addObject("customersList", customerList);
        return modelAndView;
    }
    /**
     * 查询该项目下所有的例行维护指标数据
     */
    @RequestMapping("cusHealthPlanData.html")
    public ModelAndView cusItemPlanData(HttpServletRequest request) {
        ModelAndView modelAndView = new ModelAndView("/business/pages/health/cusHealthPlanData");
        List customers = healthFacade.queryCustomers(request);
        String customerId = request.getParameter("customerId");
        modelAndView.addObject("customerId", customerId);
        modelAndView.addObject("customers", customers);
        return modelAndView;
    }
    /**
     * 获取指标各个下属单位的执行计划
     */
    @RequestMapping("cusHealthPlanReport.html")
    public ModelAndView cusItemPlanReport(HttpServletRequest request){
        ModelAndView view=  new ModelAndView("/business/pages/health/cusHealthPlanReport");
        String customerId = request.getParameter("customerId");
        String month = request.getParameter("month");
        String subCustomerId = request.getParameter("subCustomerId");
        if(!StringUtil.notEmpty(month)) {
            month = DateUtil.getCurrentDate6().toString(); 
        }
        Map map = healthFacade.queryCusHealthPlanReport(customerId,subCustomerId, month);
        System.out.println(JsonUtil.map2Json(map));
        view.addObject("subList", map.get("rs"));
        view.addObject("days", map.get("days"));
        view.addObject("month", month);
        if(StringUtil.notEmpty(customerId)) {
            SC_PARTNER_CUSTOMER_INFO customer = new SC_PARTNER_CUSTOMER_INFO(customerId).getInstanceById();
            view.addObject("customerName", customer.getCustomer_name());
        }
        
        String year = DateUtil.format("yyyy", month);
        String mon = DateUtil.format("MM", month);
        
        view.addObject("mon", mon);
        
        //查询最新五年
        int nowYear = DateUtil.getYear();
        List years = new ArrayList();
        for(int i=5; i>=0; i--) {
            years.add(nowYear-i);
        }
        
        view.addObject("years",years);
        view.addObject("year",year);
        view.addObject("mon",mon);
        
        view.addObject("customerId", customerId);
        view.addObject("subCustomerId",subCustomerId);
        
        return view;
    }
    
    /**
     * 跳转到健康检查计划查看页面
     * @param request
     * @return
     */
    @RequestMapping("healthPlan.html")
    public ModelAndView healthPlan(HttpServletRequest request){
        ModelAndView view=  new ModelAndView("/business/pages/health/healthPlan");
        List customerList = incidentFacade.getCustomerList();
        view.addObject("customersList", customerList);
        return view;
    }
    /**
     * 查看健康检查计划报表
     * @param request
     * @return
     */
    @RequestMapping("healthPlanReport.html")
    public ModelAndView getRemindItemSubTimerTaskData(HttpServletRequest request){
        ModelAndView view=  new ModelAndView("/business/pages/health/healthPlanReport");
        String customerId = request.getParameter("customer_id");
        String month = request.getParameter("month");
        if(!StringUtil.notEmpty(month)) {
            month = DateUtil.getCurrentDate6().toString(); 
        }
        Map map =healthFacade.queryHealthPlanData(customerId, month);
        view.addObject("subList", map.get("subList"));
        view.addObject("days", map.get("days"));
        if(StringUtil.notEmpty(customerId)) {
            SC_PARTNER_CUSTOMER_INFO customer = new SC_PARTNER_CUSTOMER_INFO(customerId).getInstanceById();
            view.addObject("customerName", customer.getCustomer_name());
        }
        view.addObject("month", month);
        
        
        
        String year = DateUtil.format("yyyy", month);
        String mon = DateUtil.format("MM", month);
        
        view.addObject("mon", mon);
        
        //查询最新五年
        int nowYear = DateUtil.getYear();
        List years = new ArrayList();
        for(int i=5; i>=0; i--) {
            years.add(nowYear-i);
        }
        
        view.addObject("years",years);
        view.addObject("year",year);
        view.addObject("mon",mon);
        
        view.addObject("customerId", customerId);
        
        return view;
    }
    @RequestMapping(value="healthReport.html",method=RequestMethod.GET)
    public String getHealthReport(Model model,HttpServletRequest request,HttpServletResponse response){
        String orderId = request.getParameter("orderId");
        String flowId = request.getParameter("flowId");
        Map healthInfo = healthFacade.getHealthReportInfo(orderId,flowId);
        model.addAttribute("healthInfo", healthInfo);
        return "/business/pages/health/healthReport";
    }
    /**
     * 查询执行计划列表
     */
    @RequestMapping("healthPlanListRead.html")
    public ModelAndView healthPlanListRead(HttpServletRequest request) {
        ModelAndView modelAndView = new ModelAndView("/business/pages/health/healthPlanListRead");
        List<Map> plans = healthFacade.querySubCustomerHealthPlanForDay(request);
        modelAndView.addObject("plans",plans);
        return modelAndView;
    }
    /**
     * 关闭流程
     * @param request
     * @param response
     * @return
     */
    @RequestMapping(value="closeWorkFlow.html",method=RequestMethod.GET)
    public String closeWorkFlow(HttpServletRequest request,HttpServletResponse response){
        return "/business/pages/health/closeWorkFlow";
    }
    @RequestMapping(value="closeWorkFlow.html",method=RequestMethod.POST)
    public ModelAndView closeWorkFlowSubmit(HttpServletRequest request,HttpServletResponse response){
        healthFacade.doCloseWorkFlow(request);
        return WebUtil.sysInfoPage(request, "操作成功!",
                "window.top.hideDialog('0');",
                SysInfo.Success,"/business/pages/health/myHealthList.html");
    }
}