liuyifan 4 anos atrás
pai
commit
c0c9544aef

+ 59 - 6
WebUI/CallCenterWeb.UI/Appeal/AddAppeal.html

@@ -227,9 +227,20 @@
227 227
                     <tr>
228 228
                         <th>事发区域:</th>
229 229
                         <td>
230
-                            <select class="form-control" id="sourcearea" style="display: inline-block;"></select>
230
+                            <select class="form-control" id="sourcearea"></select>
231 231
                         </td>
232
-                        <td colspan="2">
232
+                        <th>乡镇:</th>
233
+                        <td>
234
+                            <select class="form-control" id="township"></select>
235
+                        </td>
236
+                        <th>村:</th>
237
+                        <td>
238
+                            <select class="form-control" id="village"></select>
239
+                        </td>
240
+                    </tr>
241
+                    <tr>
242
+                        <th>详细地址:</th>
243
+                        <td colspan="3">
233 244
                             <input id="sourceaddress" class="form-control" type="text" placeholder="输入详细地址"
234 245
                                 style="padding-left: 15px;" />
235 246
                         </td>
@@ -260,6 +271,8 @@
260 271
         var submit;
261 272
         $(document).ready(function () {
262 273
             QY($("#sourcearea"));
274
+            // 获取乡镇,默认文峰区
275
+            getTownshipVillage($("#township"), 4965);
263 276
             LY($("#source"));
264 277
             LB($("#type"));
265 278
             ZT($("#keys"));
@@ -332,6 +345,10 @@
332 345
                 //     layer.msg("请选择事发区域");
333 346
             } else if (value == 1 && !$('#result').val()) {
334 347
                 layer.msg("请输入直办内容");
348
+            } else if (!$("#township").val()) {
349
+                layer.msg("请选择乡镇");
350
+            } else if (!$("#village").val()) {
351
+                layer.msg("请选择村");
335 352
             } else {
336 353
                 $.ajax({
337 354
                     type: "post",
@@ -357,6 +374,8 @@
357 374
                         content: $("#content").val(),
358 375
                         files: $("#file").val(), //(多个用英文逗号,隔开)
359 376
                         sourcearea: $("#sourcearea").val(), //=事发地域id
377
+                        township: $("#township").val(), // 乡镇
378
+                        village: $("#village").val(), // 村
360 379
                         sourceaddress: $('#sourceaddress').val(), //=事发详细地址
361 380
                         longitude: $('.store_Lng').val(),
362 381
                         latitude: $('.store_Lat').val(),
@@ -554,9 +573,11 @@
554 573
                         $(content).each(function (i, n) {
555 574
                             if (n.F_AreaName !== "市区") {
556 575
                                 if (n.F_AreaName === "文峰区") {
557
-                                    $("<option value='" + n.F_AreaId + "' selected='selected'>" + n.F_AreaName + "</option>").appendTo(obj);    
576
+                                    $("<option value='" + n.F_AreaId + "' selected='selected'>" + n
577
+                                        .F_AreaName + "</option>").appendTo(obj);
558 578
                                 } else {
559
-                                    $("<option value='" + n.F_AreaId + "'>" + n.F_AreaName + "</option>").appendTo(obj);    
579
+                                    $("<option value='" + n.F_AreaId + "'>" + n.F_AreaName +
580
+                                        "</option>").appendTo(obj);
560 581
                                 }
561 582
                             }
562 583
                         })
@@ -565,6 +586,37 @@
565 586
             });
566 587
         }
567 588
 
589
+        //获取乡镇、村
590
+        function getTownshipVillage(obj, parentid) {
591
+            obj.empty();
592
+            obj.append('<option selected="selected" value="">请选择</option>');
593
+            $.getJSON(
594
+                huayi.config.callcenter_url + "Area/GetAreaChildren", {
595
+                    token: $.cookie("token"),
596
+                    parentid: parentid
597
+                },
598
+                function (data) {
599
+                    if (data.state.toLowerCase() == "success") {
600
+                        var content = data.data;
601
+                        $(content).each(function (i, n) {
602
+                            $("<option value='" + n.F_AreaId + "'>" + n.F_AreaName + "</option>").appendTo(
603
+                                obj);
604
+                        });
605
+                    }
606
+                }
607
+            );
608
+        }
609
+
610
+        // 获取乡镇
611
+        $("#sourcearea").change(function () {
612
+            getTownshipVillage($("#township"), $("#sourcearea").val())
613
+        })
614
+
615
+        // 获取村
616
+        $("#township").change(function () {
617
+            getTownshipVillage($("#village"), $("#township").val())
618
+        })
619
+
568 620
         //电话类别
569 621
         function getPhoneType(obj) {
570 622
             obj.empty();
@@ -614,13 +666,14 @@
614 666
             $("#title").val('');
615 667
             $("#content").val('');
616 668
             $("#sourcearea").val(); //=事发地域id
669
+            $("#township").val(); // 乡镇
670
+            $("#village").val(); // 村
617 671
             $('#sourceaddress').val(''); //=事发详细地址
618 672
             $("input[name='baomi'][value='1']").prop("checked", true) //=(0转办1直办)
619 673
             $("#type option:first").prop("selected", 'selected');
620 674
             $("#level option:first").prop("selected", 'selected');
621 675
             $("#visittype option:first").prop("selected", "selected");
622 676
             $("#keys option:first").prop("selected", 'selected');
623
-            $("#sourcearea option:first").prop("selected", 'selected');
624 677
             $('#result').val('');
625 678
             $(".inps").val('');
626 679
             $("#PID").val('');
@@ -651,7 +704,7 @@
651 704
                                 $("#PID").val(obj.id)
652 705
                             },
653 706
                         });
654
-                        
707
+
655 708
                     });
656 709
                 }
657 710
             );

+ 132 - 52
WebUI/CallCenterWeb.UI/CommonHtml/AddAppealDCL.html

@@ -221,9 +221,17 @@
221 221
                         </td>
222 222
                     </tr>
223 223
                     <tr>
224
-                        <th class="Importent">事件地址:</th>
225
-                        <td colspan="7">
226
-                            <select class="select_ form-control" id="sourcearea"></select>
224
+                        <th>事件地址:</th>
225
+                        <td>
226
+                            <select class="form-control" id="sourcearea"></select>
227
+                        </td>
228
+                        <th>乡镇:</th>
229
+                        <td>
230
+                            <select class="form-control" id="township"></select>
231
+                        </td>
232
+                        <th>村:</th>
233
+                        <td>
234
+                            <select class="form-control" id="village"></select>
227 235
                         </td>
228 236
                     </tr>
229 237
                     <tr>
@@ -378,7 +386,8 @@
378 386
                     },
379 387
                     success: function (data) {
380 388
                         if (data.state.toLowerCase() == "success") {
381
-                            var index = parent.layer.getFrameIndex(window.name); //先得到当前iframe层的索引
389
+                            var index = parent.layer.getFrameIndex(window
390
+                                .name); //先得到当前iframe层的索引
382 391
                             parent.layer.close(index); //再执行关闭
383 392
                             parent.$("#orderlist").bootstrapTable("refresh");
384 393
                             parent.layer.msg("操作成功");
@@ -442,7 +451,21 @@
442 451
                             );
443 452
                             $("#sourcearea option:selected").text(
444 453
                                 Data[0].AreaName
445
-                            ); //事件地址
454
+                            );
455
+                            // 乡镇
456
+                            $("#township option:selected").val(
457
+                                Data[0].F_Township + ""
458
+                            );
459
+                            $("#township option:selected").text(
460
+                                // Data[0].AreaName
461
+                            );
462
+                            // 村
463
+                            $("#village option:selected").val(
464
+                                Data[0].F_Village + ""
465
+                            );
466
+                            $("#village option:selected").text(
467
+                                // Data[0].AreaName
468
+                            );
446 469
                             //主题词
447 470
                             $("#keys option:selected").val(
448 471
                                 Data[0].F_Key + ""
@@ -523,25 +546,11 @@
523 546
 
524 547
         ///修改工单
525 548
         function Add() {
526
-
527
-
528
-            var jbSelect = $("#jbSelect").val();
549
+            var jbSelect = $("#jbSelect").val().join(",").slice(0, -1);
529 550
             var startTime = $("#startTime").val();
530 551
             var limittimes = $("#limittimes").val();
531 552
             var limittimesCB = $("#limittimesCB").val();
532
-
533
-            //坐席
534
-            //              var usercodeID = "";
535
-            //              var usercode_ = $("#ZX").val(); //坐席
536
-            //              if (usercode_ != null) {
537
-            //                  $(usercode_).each(function (i, n) {
538
-            //                      var obj1 = "";
539
-            //                      obj1 = n + ",";
540
-            //                      usercodeID += obj1;
541
-            //                  });
542
-            //              } else {
543
-            //                  usercodeID = "";
544
-            //              }
553
+            var level = $("#level").val()
545 554
             var value = $(' input[name="banli"]:checked ').val();
546 555
             var content = $("#content").val();
547 556
             var threeWayCall;
@@ -613,26 +622,35 @@
613 622
                                 title: "重办工单",
614 623
                                 area: ["95%", "95%"], //宽高
615 624
                             });
616
-                        } else if (workType === "jb") {
617
-                            layer.open({
618
-                                type: 2,
619
-                                content: "../CommonHtml/jiaoban.html?wid=" + wid + "&jbSelect=" +
620
-                                    jbSelect + "&startTime=" + startTime + "&limittimes=" +
621
-                                    limittimes + "&level=" + $("#level").val() + "&workType=" +
622
-                                    workType, //iframe的url,no代表不显示滚动条
623
-                                title: "工单交办",
624
-                                area: ["95%", "95%"], //宽高
625
-                            });
626
-                        } else if (workType === "zzbl") {
627
-                            layer.open({
628
-                                type: 2,
629
-                                content: "../CommonHtml/jiaoban.html?wid=" + wid + "&jbSelect=" +
630
-                                    jbSelect + "&startTime=" + startTime + "&limittimes=" +
631
-                                    limittimes + "&level=" + $("#level").val() + "&workType=" +
632
-                                    workType, //iframe的url,no代表不显示滚动条
633
-                                title: "工单交办",
634
-                                area: ["95%", "95%"], //宽高
635
-                            });
625
+                        } else if (workType === "jb" || workType === "zzbl") {
626
+                            layer.confirm(
627
+                                "确定交办?", {
628
+                                    btn: ["是", "否"], //按钮
629
+                                },
630
+                                function () {
631
+                                    assign(workType, jbSelect, startTime, limittimes, level)
632
+                                }
633
+                            );
634
+
635
+                            // layer.open({
636
+                            // type: 2,
637
+                            // content: "../CommonHtml/jiaoban.html?wid=" + wid + "&jbSelect=" +
638
+                            //     jbSelect + "&startTime=" + startTime + "&limittimes=" +
639
+                            //     limittimes + "&level=" + $("#level").val() + "&workType=" +
640
+                            //     workType, //iframe的url,no代表不显示滚动条
641
+                            // title: "工单交办",
642
+                            // area: ["95%", "95%"], //宽高
643
+                            // });
644
+                            // } else if (workType === "zzbl") {
645
+                            //     layer.open({
646
+                            //         type: 2,
647
+                            //         content: "../CommonHtml/jiaoban.html?wid=" + wid + "&jbSelect=" +
648
+                            //             jbSelect + "&startTime=" + startTime + "&limittimes=" +
649
+                            //             limittimes + "&level=" + $("#level").val() + "&workType=" +
650
+                            //             workType, //iframe的url,no代表不显示滚动条
651
+                            //         title: "工单交办",
652
+                            //         area: ["95%", "95%"], //宽高
653
+                            //     });
636 654
                         } else {
637 655
                             var index = parent.layer.getFrameIndex(
638 656
                                 window.name
@@ -806,6 +824,38 @@
806 824
                 },
807 825
             });
808 826
         }
827
+
828
+        //获取乡镇、村
829
+        function getTownshipVillage(obj, parentid) {
830
+            obj.empty();
831
+            obj.append('<option selected="selected" value="">请选择</option>');
832
+            $.getJSON(
833
+                huayi.config.callcenter_url + "Area/GetAreaChildren", {
834
+                    token: $.cookie("token"),
835
+                    parentid: parentid
836
+                },
837
+                function (data) {
838
+                    if (data.state.toLowerCase() == "success") {
839
+                        var content = data.data;
840
+                        $(content).each(function (i, n) {
841
+                            $("<option value='" + n.F_AreaId + "'>" + n.F_AreaName + "</option>").appendTo(
842
+                                obj);
843
+                        });
844
+                    }
845
+                }
846
+            );
847
+        }
848
+
849
+        // 获取乡镇
850
+        $("#sourcearea").change(function () {
851
+            getTownshipVillage($("#township"), $("#sourcearea").val())
852
+        })
853
+
854
+        // 获取村
855
+        $("#township").change(function () {
856
+            getTownshipVillage($("#village"), $("#township").val())
857
+        })
858
+
809 859
         $("#source").click(function () {
810 860
             if ($("#source").val() === "4") {
811 861
                 $(".leaderCharge-wrapper").show()
@@ -897,17 +947,6 @@
897 947
             parent.layer.msg("操作成功");
898 948
         }
899 949
 
900
-        // $("#jbSelectText").click(function() {
901
-        //     var jbSelect = $("#jbSelect").val();
902
-        //     var jbSelectText = encodeURIComponent($("#jbSelectText").val());
903
-        //     layer.open({
904
-        //         type: 2,
905
-        //         content: "../CommonHtml/organizer.html?jbSelect=" + jbSelect + "&jbSelectText=" + jbSelectText, //iframe的url,no代表不显示滚动条
906
-        //         title: '承办单位',
907
-        //         area: ['60%', '80%'], //宽高
908
-        //     });
909
-        // })
910
-
911 950
         function jbSelect(obj) {
912 951
             obj.empty();
913 952
             $.getJSON(huayi.config.callcenter_url + "Department/GetDeptList", {
@@ -1022,6 +1061,47 @@
1022 1061
                 }, delay);
1023 1062
             };
1024 1063
         }
1064
+
1065
+        function assign(workType, jbSelect, startTime, limittimes, level) {
1066
+            var assignedopinion = ""; // 交办意见
1067
+            if (workType === "zzbl") {
1068
+                assignAPI = "WorkOrder/HandleAssign"
1069
+            } else {
1070
+                assignAPI = "WorkOrder/AssignWorkOrderNew"
1071
+            }
1072
+            if (String(level) === "1") {
1073
+                var assignedopinion = "请于1小时内与来电人取得联系(匿名除外),并于" + startTime +
1074
+                    "内将办理情况反馈来电人,并将办理结果报市长便民公开电话受理中心,同时做好来电人信息保密工作。(若超期将进行通报;若无故不回复,将转交市委市政府督查局。)"
1075
+            } else if (String(level) === "2") {
1076
+                var assignedopinion = "请于1小时内与来电人取得联系(匿名除外),并于" + limittimes +
1077
+                    "内将办理情况反馈来电人,并将办理结果报市长便民公开电话受理中心,同时做好来电人信息保密工作。(若超期将进行通报;若无故不回复,将转交市委市政府督查局。)"
1078
+            }
1079
+            $.ajax({
1080
+                type: "post",
1081
+                url: huayi.config.callcenter_url + assignAPI,
1082
+                dataType: 'json',
1083
+                async: true,
1084
+                data: {
1085
+                    workorderid: wid,
1086
+                    maindeptid: jbSelect, //承办单位
1087
+                    limittime: startTime, //办理时限
1088
+                    limittimes: limittimes, // 紧急办理时限
1089
+                    assignedopinion: assignedopinion, //交办意见
1090
+                    state: 1, // 0保存,1保存并提交
1091
+                    assignid: "",
1092
+                    token: $.cookie("token"),
1093
+                },
1094
+                success: function (result) {
1095
+                    if (result.state.toLowerCase() == "success") {
1096
+                        var index = parent.layer.getFrameIndex(
1097
+                            window.name); //先得到当前iframe层的索引
1098
+                        parent.layer.close(index); //再执行关闭
1099
+                        parent.parent.$("#orderlist")
1100
+                            .bootstrapTable("refresh");
1101
+                    }
1102
+                }
1103
+            })
1104
+        }
1025 1105
     </script>
1026 1106
 </body>
1027 1107
 

+ 4 - 4
WebUI/CallCenterWeb.UI/CommonHtml/WorkDatil.html

@@ -21,7 +21,7 @@
21 21
             color: #000;
22 22
             padding: 5px 15px;
23 23
             cursor: pointer;
24
-        }
24
+        } 
25 25
 
26 26
         .cr-click {
27 27
             border-bottom: 2px solid #00a1cb;
@@ -763,8 +763,8 @@
763 763
                         <theard>
764 764
                             <tr>
765 765
                                 <td class="text-center" style="min-width:50px;">序号</td>
766
-                                <td class="text-center" data-align="left" style="min-width: 100px;">事项</td>
767 766
                                 <td class="text-center" style="min-width: 200px;">操作时间</td>
767
+                                <td class="text-center" data-align="left" style="min-width: 100px;">事项</td>
768 768
                             </tr>
769 769
                         </theard>
770 770
                         <tbody id="BLGC_">
@@ -2025,10 +2025,10 @@
2025 2025
                                     $(result.data).each(function (i, n) {
2026 2026
                                         var html = '<tr>' +
2027 2027
                                             '<td class="text-center">' + (i + 1) + '</td>' +
2028
-                                            '<td class="">' + n.F_Message +
2029
-                                            '</td>' +
2030 2028
                                             '<td class="text-center">' + n.F_CreateTime +
2031 2029
                                             '</td>' +
2030
+                                            '<td class="text-center">' + n.F_Message +
2031
+                                            '</td>' +
2032 2032
                                             '</tr>';
2033 2033
                                         $(html).appendTo($("#BLGC_"));
2034 2034
                                     });

+ 1 - 1
WebUI/CallCenterWeb.UI/SuperviseManagement/superviseReturnReview.html

@@ -862,7 +862,7 @@
862 862
             var type = $("#type").val() //=工单类型
863 863
             var sourcearea = $("#sourceAreas").val() //区域
864 864
             var keyid = $("#keyid").val() == undefined ? "" : $("#keyid").val(); //=关键词id
865
-            var state = 10;
865
+            var state = 3;
866 866
             var tab = 1;
867 867
             Supervisor = Supervisor;
868 868
 

+ 1 - 1
WebUI/CallCenterWeb.UI/SystemManager/css/yongHuManger.css

@@ -140,5 +140,5 @@ dl {
140 140
     margin: 0px 10px 0 0 !important;
141 141
 }
142 142
 .radio-inline input[type="radio"] {
143
-    margin-top: 5px !important;
143
+    margin-top: 8px !important;
144 144
 }

+ 8 - 0
WebUI/CallCenterWeb.UI/SystemManager/js/yongHuManger.js

@@ -188,6 +188,7 @@ $(document).ready(function () {
188 188
                 isseat: $('.change_hwb input[name="huwu"]:checked ').val(),
189 189
                 searright: $('.change_zxqx input[name="zxqx"]:checked ').val(),
190 190
                 sex: $('.changeSex input[name="sex"]:checked ').val(),
191
+                F_IsSms: $('.changeIsSms input[name="IsSms"]:checked').val(),
191 192
                 mobile: $(".change_mobile").val(),
192 193
                 telphone: $(".change_telphone").val(),
193 194
                 birth: $("#chan_ygbirth").val(),
@@ -474,6 +475,7 @@ function addCun() {
474 475
             isseat: $('.addhwb input[name="huwu"]:checked ').val(),
475 476
             searright: $('.addzxqx input[name="zxqx"]:checked ').val(),
476 477
             sex: $('.addSex input[name="sex"]:checked ').val(),
478
+            F_IsSms: $('.addIsSms input[name="IsSms"]:checked').val(),
477 479
             mobile: $(".add_mobile").val(),
478 480
             telphone: $(".add_telphone").val(),
479 481
             birth: $(".add_birth").val(),
@@ -497,6 +499,7 @@ function addCun() {
497 499
                 $(".addhwb input").removeAttr("checked");
498 500
                 $(".addzxqx input").removeAttr("checked");
499 501
                 $(".addSex input").removeAttr("checked");
502
+                $(".addIsSms input").removeAttr("checked");
500 503
                 layer.msg("添加成功!");
501 504
                 table.bootstrapTable("refresh");
502 505
                 $(".addModel").css("display", "none");
@@ -541,6 +544,11 @@ function getYG() {
541 544
                         ygcon.F_SexFlag +
542 545
                         '"]'
543 546
                 ).prop("checked", "checked"); //性别
547
+                $(
548
+                    '.changeIsSms input[name="IsSms"][value="' +
549
+                        ygcon.F_IsSms +
550
+                        '"]'
551
+                ).prop("checked", "checked"); //性别
544 552
                 if (ygcon.F_Birthday && ygcon.F_Birthday != "0001-01-01") {
545 553
                     $("#chan_ygbirth").val(ygcon.F_Birthday); //生日
546 554
                 }

+ 28 - 2
WebUI/CallCenterWeb.UI/SystemManager/yongHuManger.html

@@ -185,12 +185,10 @@
185 185
                                 <label class="radio-inline">
186 186
                                     <input type="radio" checked="true" name="sex" value="男"
187 187
                                         style="vertical-align: middle;display: inline-block;">男
188
-
189 188
                                 </label>
190 189
                                 <label class="radio-inline">
191 190
                                     <input type="radio" name="sex" value="女"
192 191
                                         style="vertical-align: middle;display: inline-block;">女
193
-
194 192
                                 </label>
195 193
                             </td>
196 194
                             <th>用户生日:</th>
@@ -205,6 +203,20 @@
205 203
                             <td><input type="text" class="add_mobile" /></td>
206 204
                         </tr>
207 205
                         <tr>
206
+                            <th>短信提醒:</th>
207
+                            <td class="addIsSms">
208
+                                <label class="radio-inline">
209
+                                    <input type="radio" checked="true" name="IsSms" value="0"
210
+                                        style="vertical-align: middle;display: inline-block;">发送
211
+                                </label>
212
+                                <label class="radio-inline">
213
+                                    <input type="radio" name="IsSms" value="1"
214
+                                        style="vertical-align: middle;display: inline-block;">不发送
215
+
216
+                                </label>
217
+                            </td>
218
+                        </tr>
219
+                        <tr>
208 220
                             <th>用户备注:</th>
209 221
                             <td colspan="3">
210 222
                                 <textarea class="add_remark" style="width: 100%;height: 50px;"></textarea>
@@ -348,6 +360,20 @@
348 360
                             <td><input type="text" class="change_mobile" /></td>
349 361
                         </tr>
350 362
                         <tr>
363
+                            <th>短信提醒:</th>
364
+                            <td class="changeIsSms">
365
+                                <label class="radio-inline">
366
+                                    <input type="radio" checked="true" name="IsSms" value="0"
367
+                                        style="vertical-align: middle;display: inline-block;" checked="checked">发送
368
+                                </label>
369
+                                <label class="radio-inline">
370
+                                    <input type="radio" name="IsSms" value="1"
371
+                                        style="vertical-align: middle;display: inline-block;">不发送
372
+
373
+                                </label>
374
+                            </td>
375
+                        </tr>
376
+                        <tr>
351 377
                             <th>用户备注:</th>
352 378
                             <td colspan="3">
353 379
                                 <textarea class="change_remark" style="width: 100%;height: 50px;"></textarea>

+ 14 - 2
WebUI/CallCenterWeb.UI/TelCall/CallRecord.html

@@ -261,8 +261,8 @@
261 261
             <table id="list" data-row-style="rowStyle" data-query-params="queryParams" data-pagination="true">
262 262
                 <thead>
263 263
                     <tr>
264
-                        <th data-field="CallNumber" data-align="center" data-formatter="Code">编号</th>
265
-                        <th data-field="CallNumber" data-align="center">电话号码</th>
264
+                        <th data-field="" data-align="center" data-formatter="Code">编号</th>
265
+                        <th data-field="CallNumber" data-align="center" data-formatter="formatterCallNum">电话号码</th>
266 266
                         <th data-field="FilePath" data-formatter="setCode" data-align="center">录音</th>
267 267
                         <th data-field="CallType" data-formatter="callType" data-align="center">呼叫方向</th>
268 268
                         <!--<th data-field="DealType" data-formatter="dealType" data-align="center">是否回访</th>-->
@@ -520,6 +520,18 @@
520 520
         function Code(val, row, index) {
521 521
             return index + 1;
522 522
         }
523
+
524
+        // 电话号码
525
+        function formatterCallNum(val, row) {
526
+          if (val.length === 12) {
527
+            return val.slice(1)
528
+          } else if (val.length === 13) {
529
+            return val.slice(2)
530
+          } else {
531
+            return val
532
+          }
533
+        }
534
+
523 535
         //方向呼出
524 536
         function callType(val) {
525 537
             if (val == 0) {

+ 162 - 0
WebUI/CallCenterWeb.UI/YeWu/SeatRecords.html

@@ -0,0 +1,162 @@
1
+<!DOCTYPE html>
2
+<html>
3
+
4
+<head>
5
+    <meta charset="UTF-8">
6
+    <title>坐席记录报表</title>
7
+    <meta name="viewport" content="width=device-width, initial-scale=1.0">
8
+    <script src="../Script/Common/huayi.load.js"></script>
9
+    <script src="../Script/Common/huayi.config.js"></script>
10
+    <link rel="stylesheet" href="../js/zTree/zTreeStyle.css" />
11
+    <link href="../css/WorkOrder/Search.css" rel="stylesheet">
12
+    <link href="../css/init.css" rel="stylesheet" />
13
+    <script src="../My97DatePicker/WdatePicker.js"></script>
14
+    <script src="../js/laydate/laydate.js"></script>
15
+    <style>
16
+        table td {
17
+            word-break: break-all;
18
+            word-wrap: break-word;
19
+        }
20
+
21
+        .toolBar input,
22
+        .toolBar select {
23
+            width: 200px;
24
+        }
25
+
26
+        th {
27
+            padding: 5px;
28
+            text-align: center;
29
+        }
30
+
31
+        .daoHang {
32
+            margin-bottom: 15px;
33
+        }
34
+
35
+    </style>
36
+</head>
37
+
38
+<body class="gray-bg">
39
+    <div class="wrapper wrapper-content animated fadeInRight">
40
+        <div class="daoHang clearfix">
41
+            <div class="dhLeft">
42
+                <sapn>
43
+                    <i class="syIcon"></i>位置:
44
+                    <a href="javaScript:;" id="ReIndex">首页</a>&gt;
45
+                    <a href="javaScript:;">业务统计</a>&gt;
46
+                    <a href="" class="nowPosition">坐席记录报表</a>
47
+                </sapn>
48
+            </div>
49
+            <div class="dhRight">
50
+                <a href="" title="刷新"><i class="fa fa-refresh"></i></a>
51
+            </div>
52
+        </div>
53
+
54
+        <div class="Content_box">
55
+            <div class="complain">
56
+                <div class="toolBar clearfix">
57
+                    <div class="toolLeft">
58
+                        开始日期:
59
+                        <input class="photo x-color inputs" type="text" id="squeryTime" autocomplete="off" />
60
+                        结束时间:
61
+                        <input class="photo x-color inputs" type="text" id="equeryTime" autocomplete="off" />
62
+                        <!-- 坐席工号:
63
+                        <input class="photo x-color inputs" type="text" id="usercode" autocomplete="off" />
64
+                        坐席状态:
65
+                        <select class="photo x-color inputs" type="text" id="state">
66
+                            <option value="">请选择</option>
67
+                            <option value="0">签入</option>
68
+                            <option value="1">签出</option>
69
+                            <option value="2">置闲</option>
70
+                            <option value="3">置忙</option>
71
+                        </select> -->
72
+                        <button class="btns search">查询</button>
73
+                        <!-- <button class="btns exportFile">导出</button> -->
74
+                    </div>
75
+                </div>
76
+
77
+                <div class="tab-content">
78
+                    <div class="tab-pane fade active in" id="import_from_file">
79
+                        <div style="width: 100%;padding: 10px;">
80
+                            <table id="table1" class="tables" data-row-style="rowStyle" data-query-params="queryParams"
81
+                                data-pagination="true">
82
+                                <thead>
83
+                                    <tr>
84
+                                        <th data-field="" data-formatter="serialNumber" data-align="center">序号</th>
85
+                                        <th data-field="AgentId" data-align="center">坐席工号</th>
86
+                                        <th data-field="UserName" data-align="center">坐席姓名</th>
87
+                                        <th data-field="签入" data-align="center">签入</th>
88
+                                        <th data-field="签出" data-align="center">签出</th>
89
+                                        <th data-field="置忙" data-align="center">置忙</th>
90
+                                        <th data-field="置闲" data-align="center">置闲</th>
91
+                                    </tr>
92
+                                </thead>
93
+                            </table>
94
+                        </div>
95
+                    </div>
96
+                </div>
97
+            </div>
98
+        </div>
99
+    </div>
100
+    <script>
101
+        $(document).ready(function () {
102
+            laydate.render({
103
+                elem: '#squeryTime',
104
+                theme: '#00a1cb',
105
+                type: 'datetime',
106
+            });
107
+            laydate.render({
108
+                elem: '#equeryTime',
109
+                theme: '#00a1cb',
110
+                type: 'datetime',
111
+            });
112
+            initTable();
113
+        });
114
+        //表格
115
+        function initTable() {
116
+            $.ajax({
117
+                url: huayi.config.callcenter_url + 'WorkOrderReport/GetZuoXiState',
118
+                type: 'get',
119
+                data: {
120
+                    starttime: $("#squeryTime").val(),
121
+                    endtime: $("#equeryTime").val(),
122
+                    usercode: $("#usercode").val(),
123
+                    state: $("#state").val(),
124
+                    token: $.cookie("token")
125
+                },
126
+                dataType: "json",
127
+                async: true,
128
+                success: function (returnValue) {
129
+                    // if (returnValue.state.toLowerCase() == "success") {
130
+                        var resultData = returnValue;
131
+                        $('#table1').bootstrapTable('load', resultData);
132
+                    // }
133
+                    //异步获取数据
134
+                }
135
+            });
136
+            $('#table1').bootstrapTable('destroy').bootstrapTable({
137
+                striped: true
138
+            });
139
+        }
140
+
141
+        //序号
142
+        function serialNumber(val, row, index) {
143
+            return index + 1;
144
+        }
145
+        //搜索
146
+        $(".search").click(function() {
147
+            initTable();
148
+        });
149
+
150
+        //导出
151
+        $(".exportFile").click(function() {
152
+            var start = $("#squeryTime").val();
153
+            var end = $("#equeryTime").val();
154
+
155
+            var url = huayi.config.callcenter_url + "WorkOrderReport/GetUserReturn?token=" + $.cookie("token");
156
+            url += "&start=" + start + "&end=" + end + "&isExport=true";
157
+            window.location.href = url;
158
+        })
159
+    </script>
160
+</body>
161
+
162
+</html>

+ 40 - 39
WebUI/CallCenterWeb.UI/home.html

@@ -645,7 +645,7 @@
645 645
         .lblcount {
646 646
             position: absolute;
647 647
             right: 5px;
648
-            top: 7px;
648
+            top: 8px;
649 649
         }
650 650
 
651 651
         .first {
@@ -1035,10 +1035,6 @@
1035 1035
             display: none !important;
1036 1036
         }
1037 1037
 
1038
-        .source_area input[type="text"] {
1039
-            width: 392px;
1040
-        }
1041
-
1042 1038
         .source_area {
1043 1039
             position: relative;
1044 1040
         }
@@ -1291,16 +1287,6 @@
1291 1287
             float: right;
1292 1288
         }
1293 1289
 
1294
-        #sourcearea {
1295
-            display: inline-block;
1296
-            width: 30%;
1297
-        }
1298
-
1299
-        #sourceaddress {
1300
-            display: inline-block;
1301
-            width: 50%;
1302
-        }
1303
-
1304 1290
         .reflectCategory-wrapper {
1305 1291
             position: relative;
1306 1292
         }
@@ -1981,32 +1967,47 @@
1981 1967
                                         <span class="col-sm-1">
1982 1968
                                             事发区域:
1983 1969
                                         </span>
1984
-                                        <span class="col-sm-11 source_area">
1985
-                                            <select name="sourcearea" id="sourcearea" class="form-control"
1986
-                                                style="display: inline-block; width: 20%;">
1970
+                                        <span class="col-sm-3 source_area">
1971
+                                            <select name="sourcearea" id="sourcearea" class="form-control">
1987 1972
                                                 <option value="0">
1988 1973
                                                     请选择
1989 1974
                                                 </option>
1990
-                                                <!-- <option value="0">
1991
-                                                    安阳
1992
-                                                </option> -->
1993 1975
                                             </select>
1994
-                                            <!--<img src="img/map_nav.png"/>-->
1995
-                                            <input id="sourceaddress" type="text" placeholder="输入详细地址"
1996
-                                                class="form-control" style="display: inline-block; width: 40%;" />
1997 1976
                                         </span>
1998
-                                        <div class="mapBJ" style="
1999
-                                                    width: 100%;
2000
-                                                    height: 100%;
2001
-                                                "></div>
2002
-                                        <div class="mapPos" style="
2003
-                                                    width: 710px;
2004
-                                                    height: 400px;
2005
-                                                ">
2006
-                                            <div id="myMap" style="
2007
-                                                        width: 710px;
2008
-                                                        height: 400px;
2009
-                                                    "></div>
1977
+                                        <span class="col-sm-1">
1978
+                                            乡镇:
1979
+                                        </span>
1980
+                                        <span class="col-sm-3 source_area">
1981
+                                            <select id="township" class="form-control">
1982
+                                                <option value="">
1983
+                                                    请选择
1984
+                                                </option>
1985
+                                            </select>
1986
+                                        </span>
1987
+                                        <span class="col-sm-1">
1988
+                                            村:
1989
+                                        </span>
1990
+                                        <span class="col-sm-3 source_area">
1991
+                                            <select id="village" class="form-control">
1992
+                                                <option value="">
1993
+                                                    请选择
1994
+                                                </option>
1995
+                                            </select>
1996
+                                        </span>
1997
+                                    </div>
1998
+                                    <div class="form-group clearfix">
1999
+                                        <span class="col-sm-1">
2000
+                                            详细地址:
2001
+                                        </span>
2002
+                                        <span class="col-sm-11 source_area">
2003
+                                            <input id="sourceaddress" type="text" placeholder="输入详细地址"
2004
+                                                class="form-control" />
2005
+                                        </span>                                    
2006
+                                    </div>
2007
+                                    <div class="form-group clearfix">
2008
+                                        <div class="mapBJ" style="width: 100%; height: 100%"></div>
2009
+                                        <div class="mapPos" style="width: 710px; height: 400px;">
2010
+                                            <div id="myMap" style="width: 710px; height: 400px;"></div>
2010 2011
                                             <input type="hidden" class="store_Lng" value="114.352482" />
2011 2012
                                             <input type="hidden" class="store_Lat" value="36.103442" />
2012 2013
                                         </div>
@@ -2203,12 +2204,12 @@
2203 2204
                                         <th data-field="TalkEndTime">
2204 2205
                                             通话结束时间
2205 2206
                                         </th>
2206
-                                        <th data-field="TalkLongTime" data-formatter="ftime">
2207
+                                        <!-- <th data-field="TalkLongTime" data-formatter="ftime">
2207 2208
                                             通话时长
2208 2209
                                         </th>
2209 2210
                                         <th data-field="FilePath" data-formatter="setCode">
2210 2211
                                             录音
2211
-                                        </th>
2212
+                                        </th> -->
2212 2213
                                     </tr>
2213 2214
                                 </thead>
2214 2215
                                 <tbody class="list"></tbody>
@@ -2491,7 +2492,7 @@
2491 2492
                             <table class="table" id="zxTable">
2492 2493
                                 <thead>
2493 2494
                                     <tr>
2494
-                                        <!-- <th>姓名</th> -->
2495
+                                        <th>姓名</th>
2495 2496
                                         <th>工号</th>
2496 2497
                                         <th>分机号</th>
2497 2498
                                         <th>状态</th>

+ 4 - 4
WebUI/CallCenterWeb.UI/index.html

@@ -33,11 +33,11 @@
33 33
 					$.cookie("messageTime", res.data.messageTime);
34 34
 					$.cookie("socket_ip", res.data.socket_ip);
35 35
 					$.cookie("socket_port", res.data.socket_port);
36
-					if ($.cookie("token") == null) {
36
+					// if ($.cookie("token") == null) {
37 37
 				        window.location.href = "login.html";
38
-				    }else{
39
-				    	window.location.href = "home.html";
40
-				    }
38
+				    // }else{
39
+				    	// window.location.href = "home.html";
40
+				    // }
41 41
 				} else {
42 42
 					layer.confirm(res.message, {
43 43
 						icon: 2,

+ 122 - 33
WebUI/CallCenterWeb.UI/js/index.js

@@ -335,7 +335,11 @@ $(document).ready(function () {
335 335
                             m.F_OptUrl +
336 336
                             '">' +
337 337
                             m.F_FunctionName +
338
-                            "</a></li>";
338
+                            '</a>' + 
339
+                            '<span class="label label-warning pull-right lblcount ' + 
340
+                            m.F_FunctionCode + 
341
+                            '"></span>' +
342
+                            '</li>';
339 343
                     });
340 344
                     html += "</ul></li>";
341 345
                     $(html).appendTo($("#side-menu"));
@@ -565,44 +569,42 @@ $(document).ready(function () {
565 569
     //创建投诉工单
566 570
     $(".addt_").click(function () {
567 571
         Statess = 0;
568
-        var value = $(' input[name="banli"]:checked ').val();
569
-        // if (!$("#cusname").val()) {
570
-        //     layer.msg("请输入来电人姓名");
571
-        // } else
572
-        if (!$("#cusphone").val()) {
573
-            layer.msg("请输入来电号码");
574
-        } else if (!$("#title").val()) {
575
-            layer.msg("请输入标题");
576
-        } else if (!$("#content").val()) {
577
-            layer.msg("请输入内容");
578
-        } else if (!$("#PID").val()) {
579
-            layer.msg("请选择反映类别");
580
-        } else if (value == 1 && !$("#result").val()) {
581
-            layer.msg("请输入直办内容");
582
-        } else {
572
+        // var value = $(' input[name="banli"]:checked ').val();
573
+        // if (!$("#cusphone").val()) {
574
+        //     layer.msg("请输入来电号码");
575
+        // } else if (!$("#title").val()) {
576
+        //     layer.msg("请输入标题");
577
+        // } else if (!$("#content").val()) {
578
+        //     layer.msg("请输入内容");
579
+        // } else if (!$("#PID").val()) {
580
+        //     layer.msg("请选择反映类别");
581
+        // } else if (value == 1 && !$("#result").val()) {
582
+        //     layer.msg("请输入直办内容");
583
+        // } else if ($("township").val() == "") {
584
+        //     layer.msg("请选择乡镇");
585
+        // } else if ($("village").val() == "") {
586
+        //     layer.msg("请选择村");
587
+        // } else {
583 588
             Adds();
584
-        }
589
+        // }
585 590
     });
586 591
     //创建投诉工单
587 592
     $(".addts").click(function () {
588 593
         Statess = 1;
589 594
         var values = $(' input[name="banli"]:checked ').val();
590
-        // if (!$("#cusname").val()) {
591
-        //     layer.msg("请输入来电人姓名");
592
-        // } else
593
-        if (!$("#cusphone").val()) {
594
-            layer.msg("请输入来电号码");
595
-        } else if (!$("#title").val()) {
596
-            layer.msg("请输入标题");
597
-        } else if (!$("#content").val()) {
598
-            layer.msg("请输入内容");
599
-        } else if (!$("#PID").val()) {
600
-            layer.msg("请选择反映类别");
601
-        } else if (values == 1 && !$("#result").val()) {
602
-            layer.msg("请输入直办内容");
603
-        } else {
595
+        // if (!$("#cusphone").val()) {
596
+        //     layer.msg("请输入来电号码");
597
+        // } else if (!$("#title").val()) {
598
+        //     layer.msg("请输入标题");
599
+        // } else if (!$("#content").val()) {
600
+        //     layer.msg("请输入内容");
601
+        // } else if (!$("#PID").val()) {
602
+        //     layer.msg("请选择反映类别");
603
+        // } else if (values == 1 && !$("#result").val()) {
604
+        //     layer.msg("请输入直办内容");
605
+        // } else {
604 606
             Adds();
605
-        }
607
+        // }
606 608
     });
607 609
     $(".mapBJ").click(function () {
608 610
         $(".mapPos").hide();
@@ -904,6 +906,8 @@ $(document).ready(function () {
904 906
     //区县,主干道、乡镇,路社区村三级联动(目前在来电弹屏中使用)
905 907
     // helper.getDropList.getLocations($("#sourcearea"));
906 908
     QY($("#sourcearea"));
909
+    // 获取乡镇,默认文峰区
910
+    getTownshipVillage($("#township"), 4965);
907 911
     LB($("#type"));
908 912
     ZT($("#keys"));
909 913
     //加载来电类型 默认是 已受理并发送id
@@ -1016,16 +1020,42 @@ $(document).ready(function () {
1016 1020
         $("#reflectCategory").val($(this).attr("indexName"));
1017 1021
         $("#PID").val($(this).attr("index"));
1018 1022
     });
1023
+    // 获取工单数量
1024
+    workcount()
1019 1025
 });
1020 1026
 
1021 1027
 function Adds() {
1022 1028
     var callid = $(".hidCallID").val();
1029
+    var value = $(' input[name="banli"]:checked ').val();
1023 1030
     var threeWayCall;
1024 1031
     if ($("#threeWayCall").is(":checked")) {
1025 1032
         threeWayCall = 1;
1026 1033
     } else {
1027 1034
         threeWayCall = 0;
1028 1035
     }
1036
+    if (!$("#cusphone").val()) {
1037
+        layer.msg("请输入来电号码");
1038
+        return;
1039
+    } else if (!$("#title").val()) {
1040
+        layer.msg("请输入标题");
1041
+        return;
1042
+    } else if (!$("#content").val()) {
1043
+        layer.msg("请输入内容");
1044
+        return;
1045
+    } else if (!$("#PID").val()) {
1046
+        layer.msg("请选择反映类别");
1047
+        return;
1048
+    } else if (value == 1 && !$("#result").val()) {
1049
+        layer.msg("请输入直办内容");
1050
+        return;
1051
+    } else if (!$("#township").val()) {
1052
+        layer.msg("请选择乡镇");
1053
+        return;
1054
+    } else if (!$("#village").val()) {
1055
+        layer.msg("请选择村");
1056
+        return;
1057
+    }
1058
+
1029 1059
     $.ajax({
1030 1060
         type: "post",
1031 1061
         url: huayi.config.callcenter_url + "/WorkOrder/AddWorkOrder",
@@ -1050,6 +1080,8 @@ function Adds() {
1050 1080
             callid: callid,
1051 1081
             //files:$("#file").val(),//(多个用英文逗号,隔开)
1052 1082
             sourcearea: $("#sourcearea").val(), //=事发地域id
1083
+            township: $("#township").val(), // 乡镇
1084
+            village: $("#village").val(), // 村
1053 1085
             sourceaddress: $("#sourceaddress").val(), //=事发详细地址
1054 1086
             source: 1, //=来源
1055 1087
             phonetype: $("#phonetype").val(), // 电话类别
@@ -1118,6 +1150,8 @@ function Clean() {
1118 1150
     $("#keys option:first").prop("selected", "selected");
1119 1151
     $("#sourcearea").val("0").trigger("change"); //=事发地域id
1120 1152
     $("#sourcearea option:first").prop("selected", "selected");
1153
+    $("#township").val(""); // 乡镇
1154
+    $("#village").val(""); // 村
1121 1155
     $("#result").val("");
1122 1156
     $(".inps").val("");
1123 1157
     $("#PID").val("");
@@ -2086,6 +2120,16 @@ function Jumps() {
2086 2120
 //	top.$("iframe:visible")[0].src = "widgets.html";
2087 2121
 //}
2088 2122
 
2123
+// 获取乡镇
2124
+$("#sourcearea").change(function() {
2125
+    getTownshipVillage($("#township"), $("#sourcearea").val())
2126
+})
2127
+
2128
+// 获取村
2129
+$("#township").change(function() {
2130
+    getTownshipVillage($("#village"), $("#township").val())
2131
+})
2132
+
2089 2133
 //区域
2090 2134
 function QY(obj) {
2091 2135
     obj.empty();
@@ -2103,7 +2147,7 @@ function QY(obj) {
2103 2147
                         if (n.F_AreaName === "文峰区") {
2104 2148
                             $(
2105 2149
                                 "<option value='" + n.F_AreaId + "' selected='selected'>" + n.F_AreaName + "</option>"
2106
-                            ).appendTo(obj);    
2150
+                            ).appendTo(obj);
2107 2151
                         } else {
2108 2152
                             $(
2109 2153
                                 "<option value='" + n.F_AreaId + "'>" + n.F_AreaName + "</option>"
@@ -2115,6 +2159,28 @@ function QY(obj) {
2115 2159
         }
2116 2160
     );
2117 2161
 }
2162
+
2163
+//获取乡镇,村
2164
+function getTownshipVillage(obj, parentid) {
2165
+    obj.empty();
2166
+    obj.append('<option selected="selected" value="">请选择</option>');
2167
+    $.getJSON(
2168
+        huayi.config.callcenter_url + "Area/GetAreaChildren",
2169
+        {
2170
+            token: $.cookie("token"),
2171
+            parentid: parentid
2172
+        },
2173
+        function (data) {
2174
+            if (data.state.toLowerCase() == "success") {
2175
+                var content = data.data;
2176
+                $(content).each(function (i, n) {
2177
+                    $("<option value='" + n.F_AreaId + "'>" + n.F_AreaName + "</option>").appendTo(obj);    
2178
+                });
2179
+            }
2180
+        }
2181
+    );
2182
+}
2183
+
2118 2184
 //来源
2119 2185
 function LY(obj) {
2120 2186
     obj.empty();
@@ -2909,6 +2975,29 @@ function Read(signid, e) {
2909 2975
     });
2910 2976
 }
2911 2977
 
2978
+// 获取工单数量
2979
+function workcount() {
2980
+    $.getJSON(
2981
+        huayi.config.callcenter_url + "WorkOrder/GetDWCount",
2982
+        {
2983
+            token: $.cookie("token"),
2984
+        },
2985
+        function (result) {
2986
+            if (result.state.toLowerCase() == "success") {
2987
+                var data = result.data.DWCount[0];
2988
+                $(".YWJD_DCLS").text(data.DaiBan); // 待办事项
2989
+                $(".WorkTHCB").text(data.TuiHui); // 退回重办
2990
+                $(".workOverdue").text(data.ChaoQi); // 超期工单
2991
+                $(".WorkXJDWTH").text(data.XiaJiTH); // 下级单位退回
2992
+                $(".WorkYBLTJ").text(data.DaiShenHen); // 待审核下级单位
2993
+                $(".WorkTHBJJ").text(data.TuiHuiJuJue); // 退回被拒绝
2994
+                $(".WorkYSBJJ").text(data.YanShiJuJue); // 延时被拒绝
2995
+                $(".UnsuccessfulLevel2").text(data.YiBsnWeiGuo); // 已办未果
2996
+            }
2997
+        }
2998
+    );
2999
+}
3000
+
2912 3001
 function domainPrompt() {
2913 3002
     var content =
2914 3003
         '<div style="padding: 20px; font-size: 30px; line-height: 40px;">为了系统平台的安全考虑,系统登录地址改为:<a href="http://12345rx.zwfw.anyang.gov.cn:9999/home.html" target="block">http://12345rx.zwfw.anyang.gov.cn:9999/home.html</a>,新系统地址5月28日开始正式使用,老系统将于6月5日正式停止访问,请互相转告,谢谢!</div>';

+ 3 - 3
WebUI/CallCenterWeb.UI/js/main.js

@@ -27,7 +27,7 @@ function createWebSocket() {
27 27
 function Connect() {
28 28
 	if($.cookie("code")!="spdbzy"){
29 29
 		ws = new WebSocket("ws://" + huayi.config.socket_ip + ":" + huayi.config.socket_port);
30
-	} else{
30
+	} else {
31 31
 		ws = new WebSocket("wss://" + huayi.config.videoSocket_ip + ":" + huayi.config.videoSocket_port);
32 32
 	}
33 33
     console.log(ws)
@@ -721,8 +721,8 @@ function GetAgentListBack(data) {
721 721
                         break; //注销
722 722
                 }
723 723
                 var html = '<tr fjh="' + m.AgentExten + '">' +
724
-                    // '<td>' + (m.userName == undefined ? '' : m.userName) + '</td>' //姓名
725
-                    // +
724
+                    '<td>' + (m.UserName == undefined ? '' : m.UserName) + '</td>' //姓名
725
+                    +
726 726
                     '<td>' + m.AgentID + '</td>' //工号
727 727
                     +
728 728
                     '<td>' + m.AgentExten + '</td>'//分机号

+ 5 - 4
anyangWebAPP/pages/myTask/myTask.vue

@@ -40,6 +40,8 @@
40 40
 </template>
41 41
 <script>
42 42
 import { mapGetters } from "vuex"
43
+import store from '@/store';
44
+
43 45
 
44 46
 export default {
45 47
   data() {
@@ -58,7 +60,8 @@ export default {
58 60
     ...mapGetters(["State"]),
59 61
   },
60 62
   onLoad() {
61
-    this.getNowUser()
63
+    // this.getNowUser()
64
+    store.dispatch("GetNowUser")
62 65
     this.getMenuPermissions()
63 66
     //banner数据
64 67
     this.bannnerData = this.$mConstDataConfig.bannnerData
@@ -66,6 +69,7 @@ export default {
66 69
     // this.orderListData = this.$mConstDataConfig.roleListData.auditorList
67 70
     // 公告数据
68 71
     //this.noticListData = this.$mConstDataConfig.noticListData
72
+
69 73
   },
70 74
   methods: {
71 75
     changeStore() {
@@ -84,9 +88,6 @@ export default {
84 88
       this.$http.get("UserAccount/GetNowUser", params).then((response) => {
85 89
           if (response.state.toLowerCase() === "success") {
86 90
             let data = response.data
87
-            uni.setStorageSync('roleCode', data.role.F_RoleCode)
88
-            uni.setStorageSync('roleCode', data.role.F_RoleCode)   
89
-            uni.setStorageSync('roleCode', data.role.F_RoleCode)   
90 91
           }
91 92
         })
92 93
         .catch((e) => {

+ 12 - 5
anyangWebAPP/pages/setting/setting.vue

@@ -5,8 +5,8 @@
5 5
         <image src="../../static/person.png" mode=""></image>
6 6
       </view>
7 7
       <view class="userInfoRight">
8
-        <view>{{  }}</view>
9
-        <view>{{  }}</view>
8
+        <view>{{ userName }}</view>
9
+        <view>{{ userCode }}</view>
10 10
       </view>
11 11
     </view>
12 12
     <view class="userList">
@@ -29,6 +29,9 @@
29 29
 </template>
30 30
 
31 31
 <script>
32
+	import { mapGetters	} from 'vuex';
33
+  import store from '@/store';
34
+
32 35
   export default{
33 36
     data(){
34 37
       return{
@@ -49,9 +52,8 @@
49 52
       // #ifdef APP-PLUS
50 53
         console.log(plus.runtime)
51 54
       // #endif
52
-    
53 55
     },
54
-    methods:{
56
+    methods: {
55 57
       btnExit(){
56 58
         uni.showModal({
57 59
             title: '确定退出吗?',
@@ -65,7 +67,6 @@
65 67
                     uni.reLaunch({
66 68
                     	url: '/pages/login/login'
67 69
                     });
68
-                   
69 70
                 } else if (res.cancel) {
70 71
                     console.log('用户点击取消');
71 72
                 }
@@ -73,6 +74,12 @@
73 74
         });
74 75
         
75 76
       }
77
+    },
78
+    computed: {
79
+      ...mapGetters([
80
+        "userCode", // 用户工号
81
+        "userName", // 用户名称
82
+      ])
76 83
     }
77 84
     
78 85
   }

+ 2 - 1
anyangWebAPP/store/getters.js

@@ -1,6 +1,7 @@
1 1
 const getters = {
2 2
   
3 3
   State: state => state.modules.State, // 电话号码
4
-
4
+  userName: state => state.modules.userName, // 用户名称
5
+  userCode: state => state.modules.userCode, // 用户工号
5 6
 }
6 7
 export default getters

+ 1 - 0
anyangWebAPP/store/index.js

@@ -2,6 +2,7 @@ import Vue from 'vue'
2 2
 import Vuex from 'vuex'
3 3
 import modules from './modules/modules'
4 4
 import getters from './getters'
5
+
5 6
 Vue.use(Vuex)
6 7
 
7 8
 const store = new Vuex.Store({

+ 33 - 2
anyangWebAPP/store/modules/modules.js

@@ -1,20 +1,51 @@
1
+import { http } from '@/utils/request';
1 2
 
2 3
 const modules = {
3 4
   state: {
4
-    State:'1'
5
+    State:'1',
6
+    userName: "",
7
+    userCode: "",
5 8
   },
6 9
   mutations: {
7 10
     
8 11
     STATE(state, message) {
9 12
       state.State = message
13
+    },
14
+
15
+    SET_USERCODE(state, userCode) {
16
+      state.userCode = userCode
17
+    },
18
+
19
+    SET_USERNAME(state, userName) {
20
+      state.userName = userName
10 21
     }
11 22
     
12 23
   },
13 24
   actions: {
14
-   
15 25
     // 顶部电话号码
16 26
     STATE({ commit }, msg) {
17 27
       commit('SOCKET_SCREENPOPUP', msg)
28
+    },
29
+
30
+    // 获取用户信息
31
+    GetNowUser({ commit }) {
32
+      return new Promise((resolve, reject) => {
33
+        const params = {
34
+          token: uni.getStorageSync("token"),
35
+        }
36
+        http.get("UserAccount/GetNowUser", params).then((response) => {
37
+            if (response.state.toLowerCase() === "success") {
38
+              let data = response.data
39
+              uni.setStorageSync('roleCode', data.role.F_RoleCode)
40
+              commit('SET_USERCODE', data.user.F_UserCode)
41
+              commit('SET_USERNAME', data.user.F_UserName)
42
+            }
43
+            resolve(response)
44
+          })
45
+          .catch((e) => {
46
+            console.log(e)
47
+          })
48
+      })
18 49
     }
19 50
   }
20 51
 }