system-clients 4.0.4 → 4.0.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (208) hide show
  1. package/.eslintrc.js +16 -16
  2. package/SystemClient.iml +8 -8
  3. package/build/webpack.base.conf.js +85 -85
  4. package/build.gradle +6 -6
  5. package/examples/LoginPage/App.vue +21 -21
  6. package/examples/LoginPage/index.html +11 -11
  7. package/examples/LoginPage/main.js +15 -15
  8. package/index.html +21 -21
  9. package/package.json +1 -1
  10. package/src/App.vue +24 -24
  11. package/src/LodopFuncs.js +155 -155
  12. package/src/components/Main.vue +935 -935
  13. package/src/components/TabButton.vue +201 -201
  14. package/src/components/Tabs.vue +67 -67
  15. package/src/components/Util.js +343 -343
  16. package/src/components/addressManage/AddressCascadingMenu.vue +145 -145
  17. package/src/components/common/ProgressBase.vue +83 -83
  18. package/src/components/equipment/EquipmentManage.vue +83 -83
  19. package/src/components/equipment/PcAdd.vue +115 -115
  20. package/src/components/equipment/PcList.vue +119 -119
  21. package/src/components/equipment/PcManage.vue +61 -61
  22. package/src/components/equipment/PhoneAdd.vue +118 -118
  23. package/src/components/equipment/PhoneList.vue +113 -113
  24. package/src/components/equipment/PhoneManage.vue +61 -61
  25. package/src/components/equipment/PosAdd.vue +319 -319
  26. package/src/components/equipment/PosList.vue +292 -292
  27. package/src/components/equipment/PosManage.vue +138 -138
  28. package/src/components/equipment/PosManageBoth.vue +125 -125
  29. package/src/components/equipment/PosParamAdd.vue +236 -236
  30. package/src/components/equipment/PosParamList.vue +121 -121
  31. package/src/components/equipment/PosParamManage.vue +51 -51
  32. package/src/components/materialManage/materialData.vue +44 -44
  33. package/src/components/materialManage/materialList.vue +255 -255
  34. package/src/components/parammanage/ParamManage.vue +42 -42
  35. package/src/components/parammanage/ParamPage.vue +337 -337
  36. package/src/components/parammanage/ParamPages.vue +222 -222
  37. package/src/components/parammanage/SinglePage.vue +235 -235
  38. package/src/components/parammanage/SinglePages.vue +167 -167
  39. package/src/components/server/AddChangeMsg.vue +66 -66
  40. package/src/components/server/ChangeDeclare.vue +45 -45
  41. package/src/components/server/ImageVieweTest.vue +56 -56
  42. package/src/components/server/ImageViewer.vue +350 -350
  43. package/src/components/server/LeftTree.vue +111 -111
  44. package/src/components/server/LoadData.vue +55 -55
  45. package/src/components/server/Login.vue +615 -615
  46. package/src/components/server/LoginPage.vue +235 -235
  47. package/src/components/server/LoginView.vue +128 -128
  48. package/src/components/server/Menu.vue +188 -188
  49. package/src/components/server/ModifyPw.vue +126 -126
  50. package/src/components/server/PcdBuildingSelect.vue +243 -243
  51. package/src/components/server/ResSelect.vue +19 -7
  52. package/src/components/server/ResSelectGroup.vue +211 -211
  53. package/src/components/server/RightTree.vue +348 -348
  54. package/src/components/server/RoleSelector.vue +90 -90
  55. package/src/components/server/TestResSelect.vue +58 -58
  56. package/src/components/server/TestResSelectGroup.vue +388 -388
  57. package/src/filiale/baole/Login.vue +570 -570
  58. package/src/filiale/baole/system.js +5 -5
  59. package/src/filiale/bayan/PosAdd.vue +368 -368
  60. package/src/filiale/bayan/PosList.vue +341 -341
  61. package/src/filiale/bayan/PosManage.vue +138 -138
  62. package/src/filiale/bayan/system.js +6 -6
  63. package/src/filiale/chengtou/Login.vue +539 -539
  64. package/src/filiale/chengtou/system.js +5 -5
  65. package/src/filiale/dongguan/Login.vue +902 -902
  66. package/src/filiale/dongguan/Main.vue +717 -717
  67. package/src/filiale/dongguan/system.js +6 -6
  68. package/src/filiale/furuike/Login.vue +587 -587
  69. package/src/filiale/furuike/Main.vue +840 -840
  70. package/src/filiale/furuike/system.js +7 -7
  71. package/src/filiale/gehua/Main.vue +809 -809
  72. package/src/filiale/gehua/system.js +6 -6
  73. package/src/filiale/konggang/Login.vue +472 -472
  74. package/src/filiale/konggang/system.js +7 -7
  75. package/src/filiale/qianneng/Login.vue +584 -584
  76. package/src/filiale/qianneng/Main.vue +818 -818
  77. package/src/filiale/qianneng/ModifyPw.vue +108 -108
  78. package/src/filiale/qianneng/system.js +11 -11
  79. package/src/filiale/rizhao/LeftTree.vue +111 -111
  80. package/src/filiale/rizhao/Login.vue +793 -793
  81. package/src/filiale/rizhao/Main.vue +611 -611
  82. package/src/filiale/rizhao/system.js +14 -14
  83. package/src/filiale/ruihua/Login.vue +576 -576
  84. package/src/filiale/ruihua/Main.vue +977 -977
  85. package/src/filiale/ruihua/system.js +6 -6
  86. package/src/filiale/shiquan/Login.vue +566 -566
  87. package/src/filiale/shiquan/system.js +8 -8
  88. package/src/filiale/tianyi/Login.vue +573 -573
  89. package/src/filiale/tianyi/system.js +5 -5
  90. package/src/filiale/tongchuan/Login.vue +563 -563
  91. package/src/filiale/tongchuan/Main.vue +1021 -1021
  92. package/src/filiale/tongchuan/system.js +7 -7
  93. package/src/filiale/weinan/Main.vue +924 -924
  94. package/src/filiale/weinan/system.js +7 -7
  95. package/src/filiale/wenxi/Login.vue +537 -537
  96. package/src/filiale/wenxi/Main.vue +787 -787
  97. package/src/filiale/wenxi/system.js +10 -10
  98. package/src/filiale/wuhai/LeftTree.vue +141 -141
  99. package/src/filiale/wuhai/Main.vue +810 -810
  100. package/src/filiale/wuhai/system.js +10 -10
  101. package/src/filiale/yuchuan/Login.vue +891 -891
  102. package/src/filiale/yuchuan/Main.vue +866 -866
  103. package/src/filiale/yuchuan/system.js +10 -10
  104. package/src/filiale/zhoukou/Main.vue +809 -809
  105. package/src/filiale/zhoukou/system.js +6 -6
  106. package/src/plugins/EncryptUtil.js +53 -53
  107. package/src/plugins/GetLoginInfoService.js +480 -480
  108. package/src/plugins/HeatGetLoginInfoService.js +491 -491
  109. package/src/plugins/validation.js +15 -15
  110. package/src/project/State.js +17 -17
  111. package/src/stores/AppData.js +38 -38
  112. package/src/stores/HeatAppData.js +38 -38
  113. package/src/styles/fonts/glyphicons-halflings-regular.svg +288 -288
  114. package/src/styles/less/.csscomb.json +304 -304
  115. package/src/styles/less/.csslintrc +19 -19
  116. package/src/styles/less/alerts.less +73 -73
  117. package/src/styles/less/aofeng/animate.min.css +10 -10
  118. package/src/styles/less/aofeng/expandcss.less +569 -569
  119. package/src/styles/less/aofeng/login.less +367 -367
  120. package/src/styles/less/aofeng/standard.less +2507 -2507
  121. package/src/styles/less/aofeng/themeOne/BinaryTemplate.less +690 -690
  122. package/src/styles/less/aofeng/themeOne/loginStyle.less +1586 -1586
  123. package/src/styles/less/aofeng/themeOne/systemStyle.less +2650 -2650
  124. package/src/styles/less/aofeng/themeOne.less +17 -17
  125. package/src/styles/less/aofeng/themeTwo/newStyle1.less +415 -415
  126. package/src/styles/less/aofeng/themeTwo.less +3 -3
  127. package/src/styles/less/badges.less +66 -66
  128. package/src/styles/less/bootstrap.less +66 -66
  129. package/src/styles/less/breadcrumbs.less +26 -26
  130. package/src/styles/less/button-groups.less +247 -247
  131. package/src/styles/less/buttons.less +172 -172
  132. package/src/styles/less/carousel.less +269 -269
  133. package/src/styles/less/close.less +34 -34
  134. package/src/styles/less/code.less +69 -69
  135. package/src/styles/less/component-animations.less +33 -33
  136. package/src/styles/less/dropdowns.less +216 -216
  137. package/src/styles/less/fonts-list.less +25 -25
  138. package/src/styles/less/forms.less +626 -626
  139. package/src/styles/less/glyphicons.less +305 -305
  140. package/src/styles/less/grid.less +84 -84
  141. package/src/styles/less/input-groups.less +167 -167
  142. package/src/styles/less/jumbotron.less +52 -52
  143. package/src/styles/less/labels.less +64 -64
  144. package/src/styles/less/list-group.less +141 -141
  145. package/src/styles/less/manageStyle/manageChile.less +180 -180
  146. package/src/styles/less/manageStyle/manageStyle/manageChile.less +180 -180
  147. package/src/styles/less/manageStyle/manageStyle/manageStyle.less +1102 -1102
  148. package/src/styles/less/manageStyle/manageStyle/safeStyle.less +498 -498
  149. package/src/styles/less/manageStyle/manageStyle.less +1102 -1102
  150. package/src/styles/less/manageStyle/safeStyle.less +498 -498
  151. package/src/styles/less/media.less +66 -66
  152. package/src/styles/less/mixins/alerts.less +14 -14
  153. package/src/styles/less/mixins/background-variant.less +9 -9
  154. package/src/styles/less/mixins/border-radius.less +18 -18
  155. package/src/styles/less/mixins/buttons.less +69 -69
  156. package/src/styles/less/mixins/center-block.less +7 -7
  157. package/src/styles/less/mixins/clearfix.less +22 -22
  158. package/src/styles/less/mixins/forms.less +90 -90
  159. package/src/styles/less/mixins/gradients.less +59 -59
  160. package/src/styles/less/mixins/grid-framework.less +92 -92
  161. package/src/styles/less/mixins/grid.less +122 -122
  162. package/src/styles/less/mixins/hide-text.less +21 -21
  163. package/src/styles/less/mixins/image.less +33 -33
  164. package/src/styles/less/mixins/labels.less +12 -12
  165. package/src/styles/less/mixins/list-group.less +30 -30
  166. package/src/styles/less/mixins/nav-divider.less +10 -10
  167. package/src/styles/less/mixins/nav-vertical-align.less +9 -9
  168. package/src/styles/less/mixins/opacity.less +8 -8
  169. package/src/styles/less/mixins/pagination.less +24 -24
  170. package/src/styles/less/mixins/panels.less +24 -24
  171. package/src/styles/less/mixins/progress-bar.less +10 -10
  172. package/src/styles/less/mixins/reset-filter.less +8 -8
  173. package/src/styles/less/mixins/reset-text.less +18 -18
  174. package/src/styles/less/mixins/resize.less +6 -6
  175. package/src/styles/less/mixins/responsive-visibility.less +15 -15
  176. package/src/styles/less/mixins/size.less +10 -10
  177. package/src/styles/less/mixins/tab-focus.less +9 -9
  178. package/src/styles/less/mixins/table-row.less +44 -44
  179. package/src/styles/less/mixins/text-emphasis.less +9 -9
  180. package/src/styles/less/mixins/text-overflow.less +8 -8
  181. package/src/styles/less/mixins/vendor-prefixes.less +227 -227
  182. package/src/styles/less/mixins.less +40 -40
  183. package/src/styles/less/modals.less +151 -151
  184. package/src/styles/less/navbar.less +660 -660
  185. package/src/styles/less/navs.less +285 -285
  186. package/src/styles/less/normalize.less +424 -424
  187. package/src/styles/less/pager.less +76 -76
  188. package/src/styles/less/pagination.less +89 -89
  189. package/src/styles/less/panels.less +275 -275
  190. package/src/styles/less/popovers.less +131 -131
  191. package/src/styles/less/print.less +101 -101
  192. package/src/styles/less/progress-bars.less +87 -87
  193. package/src/styles/less/responsive-embed.less +35 -35
  194. package/src/styles/less/responsive-utilities.less +194 -194
  195. package/src/styles/less/scaffolding.less +161 -161
  196. package/src/styles/less/stand.less +207 -207
  197. package/src/styles/less/tables.less +312 -312
  198. package/src/styles/less/theme.less +291 -291
  199. package/src/styles/less/thumbnails.less +36 -36
  200. package/src/styles/less/tooltip.less +102 -102
  201. package/src/styles/less/type.less +316 -316
  202. package/src/styles/less/utilities.less +55 -55
  203. package/src/styles/less/variables.less +899 -899
  204. package/src/styles/less/wells.less +29 -29
  205. package/src/system.js +122 -122
  206. package/src/util/Daiban.json +12 -12
  207. package/yarn-error.log +6896 -0
  208. package/package-lock.json +0 -11773
@@ -1,977 +1,977 @@
1
- <template>
2
- <div @click="hindsetting1()" :class="{'with-watermark':showwatermakeflag}">
3
- <span class="newTip" transition="newTip" @click="tipClick" v-if="newTipShow">
4
- <span>您有一条新提醒</span>
5
- </span>
6
- <div class='flex-row system-main' id="box" v-el:box v-if="!isManger">
7
- <div class="auto login-operator1" v-if="$refs.mic.tabs.length === 0">
8
- <span>
9
- <img
10
- src="../../assets/people.png" height="15" width="15">
11
- 登录人:</span>
12
- <label>{{ orgpathnames }}</label>
13
- </div>
14
- <div class="system-left tree-flex" :class="{'tree-flex-icon': !treeOrIcon}" id="top" v-el:top>
15
- <div class="system-left-chi" :class="{'system-left-icon': !treeOrIcon}">
16
- <div class="span system-left-tree " style="height:85%">
17
- <h3>{{ systemname }}</h3>
18
- <!-- <div class="span" style="margin-bottom:10px;padding-bottom:5px;padding-top:5px;flex: 1;border-top: 1px solid #e5e5e5;border-bottom: 1px solid #e5e5e5;">-->
19
- <left-tree :functions='functions.functions' :userid='userid' @isnodo="isnodo" v-show="treeOrIcon"
20
- :tabs="tabs" v-ref:tree></left-tree>
21
- <!--&lt;!&ndash; <icon-tree :functions='functions.functions' :userid='userid' v-show="!treeOrIcon"></icon-tree>&ndash;&gt;-->
22
- </div>
23
-
24
- <div class="tree-flex-footer">
25
- <!-- <a @click="changeShow()"><img :src="imgs.open" alt=""><span v-if="treeOrIcon">菜单伸缩</span></a>-->
26
- <!-- <a><img src="../../../static/treeset.png" alt="">系统设置</a> -->
27
- <dropdown class="auto">
28
- <button type="button" data-toggle="dropdown">
29
- <img :src="imgs.set" alt=""><span v-if="treeOrIcon">系统设置</span>
30
- </button>
31
- <ul slot="dropdown-menu" class="dropdown-menu dropdown-menu-up">
32
- <li>系统信息及设置</li>
33
- <!-- <li>{{name}}</li> -->
34
- <li>{{ date }}</li>
35
- <li @click="openUrl()">售后服务</li>
36
- <li @click="qrCode=true">APP二维码</li>
37
- <li @click="show=true">修改密码</li>
38
- <li @click="AddChangeMsgShow=true">系统版本:V3.0</li>
39
- </ul>
40
-
41
- </dropdown>
42
- <a href="index.html" @click.prevent="logOut">
43
- <img :src="imgs.out" alt=""><span v-if="treeOrIcon">退出系统</span>
44
- </a>
45
- </div>
46
- </div>
47
- </div>
48
- <!-- <div class="line" id="line" v-show="treeOrIcon" v-el:line></div> -->
49
-
50
- <div class="flex right-bg system-right" id="bottom" v-el:bottom>
51
- <!-- <operator-badge></operator-badge> -->
52
- <div class="span">
53
- <echarts-box v-if="$refs.mic.tabs.length === 0"></echarts-box>
54
- <dynamic :comps='[]' name='main' :selecttab.sync="selecttab" :orgpathnames="orgpathnames"
55
- @tab-changed="tabChange" @tabscg="tabcg" v-ref:mic v-show="!($refs.mic.tabs.length === 0)"></dynamic>
56
- </div>
57
- </div>
58
- </div>
59
- <div v-show="isManger">
60
- <route v-ref:route></route>
61
- </div>
62
- <modal v-if="newTipContextShow" :show.sync="newTipContextShow" :backdrop="false">
63
- <header slot="modal-header" style="display:none"> </header>
64
- <article slot="modal-body" class="modal-body">
65
- <form class="form-horizontal">
66
- <div class="row">
67
- <div class="col-sm-12 " v-if="AppDaiBan !==''">
68
- <label class="col-sm-2">报装待办:</label>
69
- <span style="font-weight:normal">{{AppDaiBan}}</span>
70
- </div>
71
- <div class="col-sm-12 " v-if="OrderDaiBan !==''">
72
- <label class="col-sm-2">预约待办:</label>
73
- <span style="font-weight:normal">{{OrderDaiBan}}</span>
74
- </div>
75
- <div class="col-sm-12 " v-if="flowDaiBan !==''">
76
- <label class="col-sm-2">流程审核待办:</label>
77
- <span style="font-weight:normal">{{flowDaiBan}}</span>
78
- </div>
79
- </div>
80
- </form>
81
- </article>
82
- <footer slot="modal-footer" style="height: 8vh" class="modal-footer">
83
- <button class="button_search" @click="newTipContextShow = false">确认</button>
84
- </footer>
85
- </modal>
86
-
87
- <modal v-show="showRemind" :show.sync="showRemind" :backdrop="false">
88
- <header slot="modal-header" class="text-center"><h3>卡表动态库到期</h3></header>
89
- <article slot="modal-body" class="modal-body">
90
- <form class="form-horizontal">
91
- <div class="row">
92
- <div class="col-sm-3 " v-for="item in dataRemind">
93
- <label class="col-sm-3">{{ item.type }}:</label>
94
- <span style="font-weight:normal">{{item.brand}}</span>
95
- </div>
96
- <div class="col-sm-12 text-right">
97
- <span style="font-weight:normal">卡表动态库到期,请联系售后尽快注册!</span>
98
- </div>
99
- </div>
100
- </form>
101
- </article>
102
- <footer slot="modal-footer" style="height: 8vh" class="modal-footer">
103
- <button class="button_search" @click="showRemind = false">确认</button>
104
- </footer>
105
- </modal>
106
-
107
- <!-- 变更录入 模态框 -->
108
- <add-changemsg :show="AddChangeMsgShow" v-on:toggle="AddChangeMsgShow = false"></add-changemsg>
109
- <!-- 修改密码组件 -->
110
- <modify-pw :show.sync="show" v-if="show"></modify-pw>
111
- <!-- 手机扫描二维码 -->
112
- <modal :show.sync="qrCode" v-if="qrCode" v-ref:qrmodal backdrop="false">
113
- <header slot="modal-header" class="modal-header">
114
- 请打开手机扫一扫功能进行扫描下载App
115
- </header>
116
- <article slot="modal-body" class="modal-body">
117
- <img style="width: 300px;height: 300px;display: block;margin: auto" src="/images/DownLoadQRCode.png"/>
118
- </article>
119
- <footer slot="modal-footer" class="modal-footer">
120
- <button type="button" class="btn btn-success" @click='qrCode=false'>关闭</button>
121
- </footer>
122
- </modal>
123
- </div>
124
- </template>
125
-
126
- <script>
127
- import vue from 'vue'
128
- import co from 'co'
129
- import {HttpResetClass} from "vue-client";
130
-
131
- let getwartermakr = async function (self) {
132
- let param = {
133
- tablename: 't_singlevalue',
134
- condition: " 1=1 and name=\'水印内容\'"
135
- };
136
- let result = await self.$resetpost('rs/sql/saleSingleTable', {data: param}, {resolveMsg: null, rejectMsg: null});
137
- if (result && result.data.length > 0) {
138
- self.showwatermakeflag = true;
139
- createWaterMark(`${result.data[0].value}${self.$login.f.ename}`);
140
- } else {
141
- self.showwatermakeflag = false;
142
- }
143
- }
144
-
145
- let createWaterMark = function (userName) {
146
- let style;
147
- if (style) style.remove();
148
- let width = window.parseInt(document.body.clientWidth);
149
- let canvasWidth = width / window.parseInt(width / 320);
150
- let fontFamily = window.getComputedStyle(document.body)["font-family"];
151
- let canvas = document.createElement("canvas");
152
- canvas.width = canvasWidth;
153
- canvas.height = 200;
154
- let ctx = canvas.getContext("2d");
155
- ctx.rotate((-20 * Math.PI) / 180);
156
- ctx.font = `20px ${fontFamily}`;
157
- ctx.fillStyle = "rgba(8,8,8,.1)";
158
- ctx.fillText(userName, 50, 200);
159
- let imgSrc = canvas.toDataURL("image/png");
160
- style = document.createElement("style");
161
- style.innerHTML = `.with-watermark:before{
162
- pointer-events: none;
163
- content: "";
164
- width: 100%;
165
- height: 100%;
166
- display: block;
167
- position: absolute;
168
- background-image: url("${imgSrc}");
169
- }`;
170
- (document.head.append || document.head.appendChild).apply(document.head, [style]);
171
- }
172
-
173
- window.onunload = () => {
174
- vue.http({url: `rs/user/update/${this.$login.f.ename}`, method: 'GET'})
175
- }
176
- window.onbeforeunload = () => {
177
- vue.http({url: `rs/user/update/${this.$login.f.ename}`, method: 'GET'})
178
- }
179
- export default {
180
- title: '主界面',
181
- props: ['functions', 'userid', 'config'],
182
- data() {
183
- return {
184
- // 页面提示信息定时器
185
- interval: null,
186
- intervaltx: null,
187
- newTipShow: false,
188
- newTipContextShow: false,
189
- AppDaiBan: '',
190
- OrderDaiBan: '',
191
- flowDaiBan: '',
192
- // 左侧树下部三个小图标
193
- imgs: {
194
- open: '/images/lefticon/菜单伸缩.png',
195
- set: '/images/lefticon/系统设置.png',
196
- out: '/images/lefticon/退出系统.png',
197
- img1: '/images/newStyle/login-user.png',
198
- logoimg: '/static/newStyle/fife.png'
199
- // img2: '/images/lefticon/退出系统.png',
200
- },
201
- treeOrIcon: false,
202
- qrCode:false,
203
- isManger: false,
204
- show: false,
205
- orgpathnames: `${this.$login.f.orgs}-${this.$login.f.deps}-${this.$login.f.name}`,
206
- systemname: '客服系统',
207
- date: this.$login.toStandardDateString(),
208
- tabs: [], //已初始化页签数组
209
- selecttab: '',
210
- setting: true,
211
- srcsetting: '../../static/newStyle/setting.png',
212
- showwatermakeflag: false,
213
- gasbrandIdData: [],
214
- showRemind: false,
215
- dataRemind: [],
216
- connectNumber:10,
217
- timeout: 5000,
218
- // headerHint: true, // 右侧顶部提示信息
219
- // value: 25645.26,
220
- // AddChangeMsgShow: false,
221
- // showsum: false
222
- }
223
- },
224
- ready() {
225
- //使用socket发送代办消息提醒
226
- vue.prototype.$connectNumber = this.connectNumber
227
- // this.initWebSocket()
228
- getwartermakr(this);
229
- let component = this.$login.getUrlCompileParames('component')
230
- if (component) {
231
- this.isManger = true
232
- this.$refs.route.init(component, {data: this.functions.functions})
233
- }
234
- if (this.$login.f.password == '1') {
235
- this.$showMessage('本地登录系统为此账户的初始密码,请确认修改密码!!!', ['confirm', 'cancel']).then((res) => {
236
- if (res == 'confirm')
237
- this.show = true
238
- })
239
- }
240
- console.log("系统名称", this.$appdata.getSingleValue("系统名称"))
241
- this.systemname = this.$appdata.getSingleValue("系统名称") ? this.$appdata.getSingleValue("系统名称") : '客服系统'
242
- // let oBox = this.getElement("box")
243
- // let oTop = this.getElement("top")
244
- // let oBottom = this.getElement("bottom")
245
- // let oLine = this.getElement("line")
246
- // let that = this
247
- // oLine.onmousedown = function(e) {
248
- // let disX = (e || event).clientX
249
- // oLine.left = oLine.offsetLeft
250
- // document.onmousemove = function(e) {
251
- // let iT = oLine.left + ((e || event).clientX - disX)
252
- // var e = e || window.event
253
- // let tarnameb = e.target || e.srcElement
254
- // let maxT = oBox.clientWight - oLine.offsetWidth
255
- // oLine.style.margin = 0
256
- // iT < 0 && (iT = 0)
257
- // iT > maxT && (iT = maxT)
258
- // oLine.style.left = oTop.style.width = iT + "px"
259
- // oBottom.style.width = oBox.clientWidth - iT + "px"
260
- // that.$set('treeWidth', iT)
261
- // return false
262
- // }
263
- // document.onmouseup = function() {
264
- // document.onmousemove = null
265
- // document.onmouseup = null
266
- // oLine.releaseCapture && oLine.releaseCapture()
267
- // }
268
- // oLine.setCapture && oLine.setCapture()
269
- // return false
270
- // }
271
- this.changeShow()
272
- const istelRemindTimes =this.$appdata.getSingleValue("是否开启工单提醒定时器")
273
- if(istelRemindTimes=='是'){
274
- this.getTimesgotoWorkOrderSite()
275
- }
276
- const isapplyRemind =this.$appdata.getSingleValue("是否开启提醒")
277
- const times =this.$appdata.getSingleValue("提示间隔分钟")
278
- if(isapplyRemind=='是'){
279
- this.config.isTip = true
280
- this.config.times = times
281
- }
282
- // 获取预约列表
283
- this.functions.f_role_name && this.functions.f_role_name.includes(this.config.msgRole) && this.config.isTip && this.getOrderList()
284
- if (this.config.approve) {
285
- this.getFlowList()
286
- }
287
- // 获取卡表动态库到期时间
288
- this.getExpireDate()
289
- this.getApplynum()
290
- },
291
- methods: {
292
- // 清除
293
- reset () {
294
- clearTimeout(this.timeoutObj)
295
- clearTimeout(this.serverTimeoutObj)
296
- },
297
- //每隔几分钟发送一个固定信息给服务端,服务端收到后回复一个固定信息
298
- //如果服务端在一定时间内没有收到信息,就认为客户端断开了,服务端就会断开连接
299
- // 发送心跳--确保连接有效
300
- start () {
301
- // 重置
302
- vue.prototype.$connectNumber = this.connectNumber // 重置重连次数
303
- this.timeoutObj = setTimeout(() => {
304
- this.$socket.send('ping')
305
- console.log('ping!')
306
- this.serverTimeoutObj = setTimeout(() => {
307
- this.$socket.close()
308
- }, this.timeout)
309
- }, this.timeout)
310
- },
311
- // 重连
312
- reconnect () {
313
- if (this.lockReconnect) return
314
- // if (this.$connectNumber <= 0) {
315
- // vue.showMessage('连接已断开,将无法接收消息,请重新登录', ['confirm']).then((res) => {
316
- // if (res === 'confirm') {
317
- // location.reload()
318
- // }
319
- // })
320
- // return
321
- // }
322
- // this.$connectNumber--
323
- setTimeout(() => {
324
- console.log('连接异常,尝试重新连接。。。。')
325
- this.initWebSocket()
326
- this.lockReconnect = false
327
- }, 1000 * 60)
328
- },
329
- // 初始化
330
- initWebSocket () {
331
- let path = `ws://${location.host}/ws?token=${this.$login.f.id}`
332
- try {
333
- if ('WebSocket' in window) {
334
- // 创建对象
335
- vue.prototype.$socket = new WebSocket(path)
336
- } else {
337
- this.$showMessage('您的浏览器不支持websocket的协议,建议使用新版谷歌浏览器,请勿使用IE浏览器,360浏览器请使用极速模式,不要使用兼容模式!"')
338
- }
339
- } catch (e) {
340
- this.reconnect()
341
- }
342
-
343
- this.$socket.onopen = this.onOpen // 连接成功
344
- this.$socket.onmessage = this.onMessage // 收到消息时回调
345
- this.$socket.onclose = this.onClose // 连接关闭时回调
346
- this.$socket.onerror = this.onError // 通讯异常
347
- },
348
- // 通讯异常
349
- onError () {
350
- console.log('通讯异常')
351
- this.reconnect()
352
- },
353
- // 连接成功
354
- onOpen () {
355
- console.log('webSocket连接成功')
356
- this.start()//每十秒发送心跳包,确保连接状态有效
357
- },
358
- // 收到消息时回调函数
359
- onMessage (event) {
360
- if (event.data === 'pong') { //建立心跳机制发送ping,返回pong
361
- this.reset() // 重置心跳
362
- this.start() // 重新开始心跳
363
- return
364
- }
365
- //不是pong消息,就是服务器返回的消息(提示消息)
366
- let data = JSON.parse(event.data)
367
- this.$showMessage(data.message)
368
- },
369
- // 关闭连接时回调函数
370
- onClose () {
371
- console.log('webSocket连接断开')
372
- this.reset()
373
- this.reconnect() // 重连
374
- },
375
- getOrderList(){
376
- let times = this.config.times * 60 * 1000
377
- console.log("=定时提示间隔=", times)
378
- try {
379
- this.interval = setInterval(() => {
380
- this.getDaiBan()
381
- }, times)
382
- } catch (error) {
383
- console.log('捕获到异常', error)
384
- }
385
- },
386
- getFlowList(){
387
- console.log('======获取流程审核待办=====')
388
- let times = this.config.approveTimes * 60 * 1000
389
- console.log("=定时提示间隔=", times)
390
- try {
391
- this.interval = setInterval(() => {
392
- this.getFlowDaiBan()
393
- }, times)
394
- } catch (error) {
395
- console.log('捕获到异常', error)
396
- }
397
- },
398
- async getFlowDaiBan(){
399
- this.flowDaiBan = ''
400
- let http = new HttpResetClass()
401
- let data = {
402
- condition: `f_handler = '${this.$login.f.name}'`
403
- }
404
- await http.load('POST', 'rs/sql/future_getMyWorkFlowList', {data: data}, {
405
- resolveMsg: null,
406
- rejectMsg: null
407
- }).then((res) => {
408
- if (res.data.length > 0){
409
- this.flowDaiBan = `您有${res.data.length}条需要处理的审核流程业务!`
410
- }
411
- }).catch((e)=>{
412
- console.log('报错了!!')
413
- console.error(e)
414
- })
415
- if(this.flowDaiBan){
416
- this.newTipShow = true
417
- }
418
- },
419
- getTimesgotoWorkOrderSite(){
420
- let teltimes = 2*60*1000 // 两分钟
421
- try {
422
- this.intervaltx =setInterval(()=>{
423
- this.gotoWorkOrderSite()
424
- },teltimes)
425
- }catch (e) {
426
- console.log('捕获到异常', e)
427
- }
428
- },
429
- async getDaiBan(){
430
- this.OrderDaiBan = ''
431
- this.AppDaiBan = ''
432
- let http = new HttpResetClass()
433
- await http.load('POST', '/rs/sql/singleTable', {data: {
434
- tablename:'t_order_center',
435
- condition:` (f_orderstate != '预约成功' and f_orgstr ='${this.$login.f.orgid}' and f_orderstate != '预约失败' ) or f_orderstate is null`
436
- }}, {
437
- resolveMsg: null,
438
- rejectMsg: null
439
- }).then((res) => {
440
- let OrderDaiBan = {}
441
- res.data.forEach(item=>{
442
- OrderDaiBan[item.f_ordertype] = OrderDaiBan[item.f_ordertype] || []
443
- OrderDaiBan[item.f_ordertype].push(item)
444
- })
445
- if (res.data.length> 0){
446
- this.OrderDaiBan = `您有${res.data.length}条需要处理的微信预约业务!`
447
- this.OrderDaiBan += `其中 ${Object.keys(OrderDaiBan).map(key=>`${key}:${OrderDaiBan[key].length}条`).join(', ')}`
448
- }
449
- })
450
- let data = {
451
- condition: '1 = 1',
452
- data: {
453
- orgid: this.$login.f.orgid,
454
- id: this.$login.f.id
455
- }
456
- }
457
- await http.load('POST', '/rs/sql/checkuser', {data: data}, {
458
- resolveMsg: null,
459
- rejectMsg: null
460
- }).then((res) => {
461
- let AppDaiBan = {}
462
- res.data.forEach(item=>{
463
- AppDaiBan[item.defname] = AppDaiBan[item.defname] || []
464
- AppDaiBan[item.defname].push(item)
465
- })
466
- if (res.data.length> 0){
467
- this.AppDaiBan = `您有${res.data.length}条需要处理的报建待办业务!`
468
- this.AppDaiBan += `其中 ${Object.keys(AppDaiBan).map(key=>`${key}:${AppDaiBan[key].length}条`).join(', ')}`
469
- }
470
- }).catch((e)=>{
471
- console.error(e)
472
- })
473
- if(this.AppDaiBan || this.OrderDaiBan){
474
- this.newTipShow = true
475
- }
476
- },
477
- // 获取动态库卡表到期日
478
- async getExpireDate(){
479
- // 获取分公司的表品牌id
480
- let http = new HttpResetClass()
481
- await http.load('POST', '/rs/sql/singleTable', {data: {
482
- tablename:'t_gasbrand_orgid',
483
- condition:`f_using_orgid ='${this.$login.f.orgid}'`
484
- }}, {
485
- resolveMsg: null,
486
- rejectMsg: null
487
- }).then((res) => {
488
- if (res.data.length > 0) {
489
- res.data.forEach(item => {
490
- this.gasbrandIdData.push(item.f_gasbrand_id)
491
- })
492
- }
493
- if (this.gasbrandIdData.length > 0) {
494
- // 获取卡表到期时间
495
- http.load('POST', '/rs/sql/singleTable', {data: {
496
- tablename:'t_gasbrand',
497
- condition:`id in (${this.gasbrandIdData}) and f_meter_type like '%卡表%'`
498
- }}, {
499
- resolveMsg: null,
500
- rejectMsg: null
501
- }).then((res) => {
502
- if (res.data.length > 0) {
503
- res.data.forEach(itre => {
504
- let band = null
505
- if ('f_dynamic_expire' in itre) {
506
- console.log(itre.f_dynamic_expire)
507
- if (itre.f_dynamic_expire !== null && itre.f_dynamic_expire !== '') {
508
- let todayold = new Date(itre.f_dynamic_expire)
509
- todayold.setDate(todayold.getDate() - parseInt(this.$appdata.getSingleValue('动态库提醒天数设置')))
510
- let today = new Date()
511
- if (today > todayold) {
512
- band = {type:'卡表',brand:itre.f_meter_brand}
513
- this.dataRemind.push(band)
514
- }
515
- }
516
- }
517
- })
518
-
519
- }
520
- if (this.dataRemind.length > 0) {
521
- this.showRemind = true
522
- // this.$showMessage(band + '。' +
523
- // '卡表动态库到期,请联系售后尽快注册!')
524
- }
525
- })
526
- }
527
- })
528
- },
529
- // 提醒框被点击
530
- tipClick(){
531
- this.newTipShow = false
532
- this.newTipContextShow = true
533
- },
534
- getApplynum(){
535
- const isRemind =this.$appdata.getSingleValue("报建代办提醒")
536
- if(isRemind=='是'){
537
- var data={
538
- condition: " 1=1 ",
539
- condValue: [],
540
- data: {
541
- id: this.$login.f.id,
542
- orgid: this.$login.f.orgid
543
- }
544
- }
545
- debugger
546
- new HttpResetClass().load('POST','rs/sql/checkuser/n',
547
- {data}, {resolveMsg: null, rejectMsg: null}).then(res=>{
548
- if(res.data && res.data.n !== 0){
549
- this.$showMessage('你有'+res.data.n+'个报建待处理,请尽快前往报建流程面进行处理')
550
- }
551
- })
552
-
553
- }
554
- },
555
- gotoWorkOrderSite(){
556
- const isRemind =this.$appdata.getSingleValue("站点工单提醒")
557
- console.log('站点工单是否提醒',isRemind)
558
- if(isRemind && isRemind !== '是'){
559
- return
560
- }
561
- if(this.functions && this.functions.f_role_name && this.functions.f_role_name.indexOf('派单员') !== -1){
562
- const data = {
563
- "condition":
564
- {
565
- "condition":" 1=1 and processins.activities[ state='开始活动' and (defname in('站点接单'))].count(*) > 0 ",
566
- "sign":"1=1"
567
- },
568
- "userid":this.functions.name
569
- }
570
- new HttpResetClass().load('POST','rs/path/operatorService/n', {data}, {resolveMsg: null, rejectMsg: null}).then(res=>{
571
- if(res.data && res.data.n !== 0){
572
- this.$showMessage('你有'+res.data.n+'个工单待处理,请尽快前往站点工单页面进行处理')
573
- }
574
- })
575
- }
576
- },
577
- openUrl() {
578
- var url = `http://123.60.214.109:8406/submitTicket?contact=${this.$login.f.name}&orgName=${this.$login.f.orgs}&phone=${this.$login.f.f_user_telephone}`
579
- window.open(url, '_blank')
580
- },
581
- hindsetting() {
582
- this.setting = !this.setting
583
- if (this.setting) {
584
- this.srcsetting = '../../static/newStyle/setting.png'
585
- } else {
586
- this.srcsetting = '../../static/newStyle/setting1.png'
587
- }
588
-
589
- },
590
- hindsetting1() {
591
-
592
- if (!this.setting) {
593
- this.srcsetting = '../../static/newStyle/setting.png'
594
- this.setting = true
595
- }
596
-
597
- },
598
- isnodo(val) {
599
- console.log(val, 'ss')
600
- this.selecttab = val
601
- },
602
- unfurl() {
603
- if (this.showsum) {
604
- this.showsum = false
605
- } else {
606
- this.showsum = true
607
- }
608
- },
609
- // getElement(id) {
610
- // return document.getElementById(id)
611
- // },
612
- changeShow() {
613
- // this.treeOrIcon = !this.treeOrIcon
614
- // let oBox = this.getElement("box")
615
- // let oTop = this.getElement("top")
616
- // let oBottom = this.getElement("bottom")
617
- // let oLine = this.getElement("line")
618
- // if (this.treeOrIcon) {
619
- // // oLine.style.left = oTop.style.width = 300 + "px"
620
- // oTop.style.width = 150 + "px"
621
- // oBottom.style.width = oBox.clientWidth - 150 + "px"
622
- // }else {
623
- // oLine.style.left = oTop.style.width = 50 + "px"
624
- // oBottom.style.width = oBox.clientWidth - 50 + "px"
625
- // }
626
- // }
627
- this.treeOrIcon = !this.treeOrIcon
628
- // if (this.treeOrIcon) {
629
- // this.$els.top.style.width = 14 + "%"
630
- // this.$els.bottom.style.width = this.$els.box.clientWidth - 14 + "%"
631
- // }else {
632
- // this.$els.top.style.width = 8 + "%"
633
- // this.$els.bottom.style.width = this.$els.box.clientWidth - 8 + "%"
634
- // }
635
- },
636
- changeMain(userid) {
637
- this.$goto('res-main', {userid: this.userid}, 'self')
638
- },
639
- tabChange(name) {
640
- console.log(name, 'tabchanage')
641
- this.selecttab = name
642
- this.$refs.tree.changeSelect(name)
643
- },
644
- tabcg(val) {
645
- console.log(val)
646
- this.tabs = val
647
- },
648
- logOut() {
649
- console.log(this.$login.f)
650
- this.$showMessage('您确定要退出系统吗?', ['confirm', 'cancel']).then(async (res) => {
651
- if (res == 'confirm') {
652
- let data = {
653
- userid: this.$login.f.id,
654
- username: this.$login.f.name,
655
- usertelephone: this.$login.f.f_user_telephone
656
- }
657
- await this.$resetpost('rs/logic/logOut', data, {resolveMsg: '退出成功', rejectMsg: null})
658
- window.location.reload()
659
- }
660
- })
661
- }
662
- },
663
- computed: {
664
- nowDate() {
665
- return this.$login.getNowDate()
666
- }
667
- }
668
- }
669
- </script>
670
- <style lang="less">
671
- .newTip-transition {
672
- transition: all .4s ease;
673
- }
674
- .newTip-enter, .newTip-leave {
675
- height: 0;
676
- padding: 0 10px;
677
- opacity: 0;
678
- }
679
- .newTip a {
680
- color: #333;
681
- }
682
- .newTip {
683
- cursor: pointer;
684
- text-align: center;
685
- position: absolute;
686
- top: 3em;
687
- margin: 0 auto;
688
- width: 200px;
689
- left: 48%;
690
- line-height: 2;
691
- z-index: 10010;
692
- box-shadow: 0 4px 12px rgba(0,0,0,0.38);
693
- pointer-events: all;
694
- border-radius: 4px;
695
- background-color: whitesmoke;
696
- }
697
- /* 组件内通用样式 */
698
- .select-error {
699
- button {
700
- border-bottom: 1px solid #a94442 !important;
701
- }
702
- }
703
-
704
- // input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{
705
- // -webkit-appearance:textfield;
706
- // }
707
- /* 表单输入框组 */
708
- .form-input-group {
709
- display: flex;
710
-
711
- label {
712
- width: 100px;
713
- text-align: right;
714
-
715
- + * {
716
- flex: 1;
717
- }
718
- }
719
- }
720
-
721
- // 日期组件在表单中沾满
722
- .form-horizontal .datepicker {
723
- width: 100%;
724
- }
725
-
726
- // 下拉选择框占据剩余全部空间
727
- .select-overspread {
728
- .form-group {
729
- // margin: 0px 5px 10px 0px;
730
- .form-control {
731
- margin-right: 0px;
732
- }
733
- }
734
-
735
- .btn-group, .btn-group-vertical {
736
- width: 100%;
737
- // padding-right: 5px;
738
- button {
739
- width: 100%;
740
- display: flex;
741
- justify-content: space-between;
742
- align-items: center;
743
- }
744
- }
745
-
746
- .dropdown-menu {
747
- width: 100%
748
- }
749
- }
750
-
751
- // 需要特定宽度的的样式
752
- .width-60 {
753
- width: 60px;
754
- }
755
-
756
- .userpanel {
757
- font-weight: 300;
758
- color: #333;
759
- position: fixed;
760
- right: 30px;
761
- top: 45px;
762
- background-color: white;
763
- box-shadow: darkgrey 0.5px 0.5px 0.5px 0.5px;
764
- padding: 4px 10px 4px 10px;
765
- border-radius: 2px;
766
- }
767
-
768
- .width-80 {
769
- width: 80px;
770
- }
771
-
772
- .width-100 {
773
- width: 100px;
774
- }
775
-
776
-
777
- /*右侧区域的背景*/
778
- .right-bg {
779
- width: 100%;
780
- flex: 1;
781
- color: #304A66;
782
- }
783
-
784
- .tree-flex {
785
- height: 100%;
786
- // width: 150px;
787
- /*width: 60px;*/
788
- background: #4a7cae;
789
- color: #fff;
790
-
791
- }
792
-
793
- .tree-flex-icon {
794
- width: 50px;
795
- /*transition: 0.5s;*/
796
-
797
- > .span {
798
- overflow-x: visible;
799
- }
800
- }
801
-
802
- .tree-flex h3 {
803
- text-align: center;
804
- margin: 1em 0;
805
- }
806
-
807
- .tree-flex-footer {
808
- height: 50px;
809
- display: flex;
810
- flex-direction: column;
811
- color: #fff;
812
- }
813
-
814
- .tree-flex-footer a, .tree-flex-footer button {
815
- flex: 1;
816
- padding: 8px 5px;
817
- font-size: 1.2em;
818
- // border-top: 1px solid #697D93;
819
- border-top: 1px solid #4a7cae;
820
- text-decoration: none;
821
- color: #fff;
822
- cursor: pointer;
823
- }
824
-
825
- .tree-flex-footer button {
826
- height: auto;
827
- width: 100%;
828
- border-radius: 0px;
829
- background-color: rgba(255, 255, 255, 0);
830
- border: none;
831
- border-top: 1px solid #4a7cae;
832
- // border-top: 1px solid #697D93;
833
- text-align: left;
834
- }
835
-
836
- .tree-flex-footer button:hover {
837
- outline: none;
838
- background-color: rgba(255, 255, 255, 0.2);
839
- }
840
-
841
- .tree-flex-footer button:focus {
842
- outline: none;
843
- background-color: rgba(255, 255, 255, 0.5);
844
- }
845
-
846
- .tree-flex-footer a:hover {
847
- color: #FFF;
848
- background-color: rgba(255, 255, 255, 0.2);
849
- }
850
-
851
- .tree-flex .btn-group {
852
- height: 50px !important;
853
- }
854
-
855
- .tree-flex .dropdown-menu {
856
- /* 控制显示列表的样式 */
857
- background: #4a7cae;
858
- border-radius: 0px;
859
- color: #fff;
860
- width: auto;
861
- margin: 0px;
862
- padding: 0px;
863
- }
864
-
865
- .tree-flex .dropdown-menu-up {
866
- /* bottom,top控制上下,left和right控制左右*/
867
- left: 100% !important;
868
- top: auto !important;
869
- bottom: 0;
870
- }
871
-
872
- .tree-flex .dropdown-menu-down {
873
- /* bottom,top控制上下,left和right控制左右*/
874
- left: 100% !important;
875
- top: 0 !important;
876
- }
877
-
878
- .tree-flex .dropdown-menu li {
879
- text-align: center;
880
- line-height: 50px;
881
- border-bottom: 1px solid #697D93;
882
- font-size: 1.2em;
883
- width: auto;
884
- white-space: nowrap;
885
- cursor: default;
886
-
887
- }
888
-
889
- .tree-flex .dropdown-menu li + li {
890
- text-align: left;
891
- border: 0;
892
- line-height: 40px;
893
- padding-left: 15px;
894
- padding-right: 15px;
895
- font-size: 1em;
896
- cursor: pointer;
897
- }
898
-
899
- .tree-flex .dropdown-menu li + li:hover {
900
- background-color: rgba(255, 255, 255, 0.2);
901
- }
902
-
903
- .tree-flex .dropdown-menu li a {
904
- border: none;
905
- color: #fff;
906
- height: 40px;
907
- line-height: 40px;
908
- font-size: 1em;
909
- padding: 0px;
910
- }
911
-
912
- .tree-flex .dropdown-menu li a:hover {
913
- color: #fff;
914
- background-color: rgba(255, 255, 255, 0);
915
- }
916
-
917
- .tree-flex img {
918
- height: 1.2em;
919
- width: 1.2em;
920
- margin-right: 15px;
921
- margin-left: 5px;
922
- }
923
-
924
- .line {
925
- height: 100%;
926
- width: 5px;
927
- background: #4C637B;
928
- cursor: e-resize;
929
- }
930
-
931
- /*为树(tree)组件写的样式*/
932
- .tree-img {
933
- font-size: 1.2em;
934
- }
935
-
936
- /*将较长信息截断显示,鼠标悬停显示全部信息*/
937
- .cutout50 {
938
- max-width: 50px;
939
- overflow: hidden;
940
- text-overflow: ellipsis;
941
- white-space: nowrap;
942
- }
943
-
944
- /* 滚动条样式 */
945
- /*---滚动条默认显示样式--*/
946
- ::-webkit-scrollbar-thumb {
947
- // display: none;
948
- background-color: rgba(0, 0, 0, 0.4);
949
- /*background-color:red;*/
950
- height: 50px;
951
- outline-offset: -2px;
952
- /*outline:2px solid #fff;*/
953
- -webkit-border-radius: 4px;
954
- /*border: 2px solid #fff;*/
955
- }
956
-
957
- /*---鼠标点击滚动条显示样式--*/
958
- ::-webkit-scrollbar-thumb:hover {
959
- // display: inherit;
960
- background-color: rgba(0, 0, 0, 0.4);
961
- height: 50px;
962
- -webkit-border-radius: 4px;
963
- }
964
-
965
- /*---滚动条大小--*/
966
- ::-webkit-scrollbar {
967
- width: 8px;
968
- height: 8px;
969
- }
970
-
971
- /*---滚动框背景样式--*/
972
- ::-webkit-scrollbar-track-piece {
973
- /* 全透明,不显示 */
974
- background-color: rgba(255, 255, 255, 0);
975
- -webkit-border-radius: 0;
976
- }
977
- </style>
1
+ <template>
2
+ <div @click="hindsetting1()" :class="{'with-watermark':showwatermakeflag}">
3
+ <span class="newTip" transition="newTip" @click="tipClick" v-if="newTipShow">
4
+ <span>您有一条新提醒</span>
5
+ </span>
6
+ <div class='flex-row system-main' id="box" v-el:box v-if="!isManger">
7
+ <div class="auto login-operator1" v-if="$refs.mic.tabs.length === 0">
8
+ <span>
9
+ <img
10
+ src="../../assets/people.png" height="15" width="15">
11
+ 登录人:</span>
12
+ <label>{{ orgpathnames }}</label>
13
+ </div>
14
+ <div class="system-left tree-flex" :class="{'tree-flex-icon': !treeOrIcon}" id="top" v-el:top>
15
+ <div class="system-left-chi" :class="{'system-left-icon': !treeOrIcon}">
16
+ <div class="span system-left-tree " style="height:85%">
17
+ <h3>{{ systemname }}</h3>
18
+ <!-- <div class="span" style="margin-bottom:10px;padding-bottom:5px;padding-top:5px;flex: 1;border-top: 1px solid #e5e5e5;border-bottom: 1px solid #e5e5e5;">-->
19
+ <left-tree :functions='functions.functions' :userid='userid' @isnodo="isnodo" v-show="treeOrIcon"
20
+ :tabs="tabs" v-ref:tree></left-tree>
21
+ <!--&lt;!&ndash; <icon-tree :functions='functions.functions' :userid='userid' v-show="!treeOrIcon"></icon-tree>&ndash;&gt;-->
22
+ </div>
23
+
24
+ <div class="tree-flex-footer">
25
+ <!-- <a @click="changeShow()"><img :src="imgs.open" alt=""><span v-if="treeOrIcon">菜单伸缩</span></a>-->
26
+ <!-- <a><img src="../../../static/treeset.png" alt="">系统设置</a> -->
27
+ <dropdown class="auto">
28
+ <button type="button" data-toggle="dropdown">
29
+ <img :src="imgs.set" alt=""><span v-if="treeOrIcon">系统设置</span>
30
+ </button>
31
+ <ul slot="dropdown-menu" class="dropdown-menu dropdown-menu-up">
32
+ <li>系统信息及设置</li>
33
+ <!-- <li>{{name}}</li> -->
34
+ <li>{{ date }}</li>
35
+ <li @click="openUrl()">售后服务</li>
36
+ <li @click="qrCode=true">APP二维码</li>
37
+ <li @click="show=true">修改密码</li>
38
+ <li @click="AddChangeMsgShow=true">系统版本:V3.0</li>
39
+ </ul>
40
+
41
+ </dropdown>
42
+ <a href="index.html" @click.prevent="logOut">
43
+ <img :src="imgs.out" alt=""><span v-if="treeOrIcon">退出系统</span>
44
+ </a>
45
+ </div>
46
+ </div>
47
+ </div>
48
+ <!-- <div class="line" id="line" v-show="treeOrIcon" v-el:line></div> -->
49
+
50
+ <div class="flex right-bg system-right" id="bottom" v-el:bottom>
51
+ <!-- <operator-badge></operator-badge> -->
52
+ <div class="span">
53
+ <echarts-box v-if="$refs.mic.tabs.length === 0"></echarts-box>
54
+ <dynamic :comps='[]' name='main' :selecttab.sync="selecttab" :orgpathnames="orgpathnames"
55
+ @tab-changed="tabChange" @tabscg="tabcg" v-ref:mic v-show="!($refs.mic.tabs.length === 0)"></dynamic>
56
+ </div>
57
+ </div>
58
+ </div>
59
+ <div v-show="isManger">
60
+ <route v-ref:route></route>
61
+ </div>
62
+ <modal v-if="newTipContextShow" :show.sync="newTipContextShow" :backdrop="false">
63
+ <header slot="modal-header" style="display:none"> </header>
64
+ <article slot="modal-body" class="modal-body">
65
+ <form class="form-horizontal">
66
+ <div class="row">
67
+ <div class="col-sm-12 " v-if="AppDaiBan !==''">
68
+ <label class="col-sm-2">报装待办:</label>
69
+ <span style="font-weight:normal">{{AppDaiBan}}</span>
70
+ </div>
71
+ <div class="col-sm-12 " v-if="OrderDaiBan !==''">
72
+ <label class="col-sm-2">预约待办:</label>
73
+ <span style="font-weight:normal">{{OrderDaiBan}}</span>
74
+ </div>
75
+ <div class="col-sm-12 " v-if="flowDaiBan !==''">
76
+ <label class="col-sm-2">流程审核待办:</label>
77
+ <span style="font-weight:normal">{{flowDaiBan}}</span>
78
+ </div>
79
+ </div>
80
+ </form>
81
+ </article>
82
+ <footer slot="modal-footer" style="height: 8vh" class="modal-footer">
83
+ <button class="button_search" @click="newTipContextShow = false">确认</button>
84
+ </footer>
85
+ </modal>
86
+
87
+ <modal v-show="showRemind" :show.sync="showRemind" :backdrop="false">
88
+ <header slot="modal-header" class="text-center"><h3>卡表动态库到期</h3></header>
89
+ <article slot="modal-body" class="modal-body">
90
+ <form class="form-horizontal">
91
+ <div class="row">
92
+ <div class="col-sm-3 " v-for="item in dataRemind">
93
+ <label class="col-sm-3">{{ item.type }}:</label>
94
+ <span style="font-weight:normal">{{item.brand}}</span>
95
+ </div>
96
+ <div class="col-sm-12 text-right">
97
+ <span style="font-weight:normal">卡表动态库到期,请联系售后尽快注册!</span>
98
+ </div>
99
+ </div>
100
+ </form>
101
+ </article>
102
+ <footer slot="modal-footer" style="height: 8vh" class="modal-footer">
103
+ <button class="button_search" @click="showRemind = false">确认</button>
104
+ </footer>
105
+ </modal>
106
+
107
+ <!-- 变更录入 模态框 -->
108
+ <add-changemsg :show="AddChangeMsgShow" v-on:toggle="AddChangeMsgShow = false"></add-changemsg>
109
+ <!-- 修改密码组件 -->
110
+ <modify-pw :show.sync="show" v-if="show"></modify-pw>
111
+ <!-- 手机扫描二维码 -->
112
+ <modal :show.sync="qrCode" v-if="qrCode" v-ref:qrmodal backdrop="false">
113
+ <header slot="modal-header" class="modal-header">
114
+ 请打开手机扫一扫功能进行扫描下载App
115
+ </header>
116
+ <article slot="modal-body" class="modal-body">
117
+ <img style="width: 300px;height: 300px;display: block;margin: auto" src="/images/DownLoadQRCode.png"/>
118
+ </article>
119
+ <footer slot="modal-footer" class="modal-footer">
120
+ <button type="button" class="btn btn-success" @click='qrCode=false'>关闭</button>
121
+ </footer>
122
+ </modal>
123
+ </div>
124
+ </template>
125
+
126
+ <script>
127
+ import vue from 'vue'
128
+ import co from 'co'
129
+ import {HttpResetClass} from "vue-client";
130
+
131
+ let getwartermakr = async function (self) {
132
+ let param = {
133
+ tablename: 't_singlevalue',
134
+ condition: " 1=1 and name=\'水印内容\'"
135
+ };
136
+ let result = await self.$resetpost('rs/sql/saleSingleTable', {data: param}, {resolveMsg: null, rejectMsg: null});
137
+ if (result && result.data.length > 0) {
138
+ self.showwatermakeflag = true;
139
+ createWaterMark(`${result.data[0].value}${self.$login.f.ename}`);
140
+ } else {
141
+ self.showwatermakeflag = false;
142
+ }
143
+ }
144
+
145
+ let createWaterMark = function (userName) {
146
+ let style;
147
+ if (style) style.remove();
148
+ let width = window.parseInt(document.body.clientWidth);
149
+ let canvasWidth = width / window.parseInt(width / 320);
150
+ let fontFamily = window.getComputedStyle(document.body)["font-family"];
151
+ let canvas = document.createElement("canvas");
152
+ canvas.width = canvasWidth;
153
+ canvas.height = 200;
154
+ let ctx = canvas.getContext("2d");
155
+ ctx.rotate((-20 * Math.PI) / 180);
156
+ ctx.font = `20px ${fontFamily}`;
157
+ ctx.fillStyle = "rgba(8,8,8,.1)";
158
+ ctx.fillText(userName, 50, 200);
159
+ let imgSrc = canvas.toDataURL("image/png");
160
+ style = document.createElement("style");
161
+ style.innerHTML = `.with-watermark:before{
162
+ pointer-events: none;
163
+ content: "";
164
+ width: 100%;
165
+ height: 100%;
166
+ display: block;
167
+ position: absolute;
168
+ background-image: url("${imgSrc}");
169
+ }`;
170
+ (document.head.append || document.head.appendChild).apply(document.head, [style]);
171
+ }
172
+
173
+ window.onunload = () => {
174
+ vue.http({url: `rs/user/update/${this.$login.f.ename}`, method: 'GET'})
175
+ }
176
+ window.onbeforeunload = () => {
177
+ vue.http({url: `rs/user/update/${this.$login.f.ename}`, method: 'GET'})
178
+ }
179
+ export default {
180
+ title: '主界面',
181
+ props: ['functions', 'userid', 'config'],
182
+ data() {
183
+ return {
184
+ // 页面提示信息定时器
185
+ interval: null,
186
+ intervaltx: null,
187
+ newTipShow: false,
188
+ newTipContextShow: false,
189
+ AppDaiBan: '',
190
+ OrderDaiBan: '',
191
+ flowDaiBan: '',
192
+ // 左侧树下部三个小图标
193
+ imgs: {
194
+ open: '/images/lefticon/菜单伸缩.png',
195
+ set: '/images/lefticon/系统设置.png',
196
+ out: '/images/lefticon/退出系统.png',
197
+ img1: '/images/newStyle/login-user.png',
198
+ logoimg: '/static/newStyle/fife.png'
199
+ // img2: '/images/lefticon/退出系统.png',
200
+ },
201
+ treeOrIcon: false,
202
+ qrCode:false,
203
+ isManger: false,
204
+ show: false,
205
+ orgpathnames: `${this.$login.f.orgs}-${this.$login.f.deps}-${this.$login.f.name}`,
206
+ systemname: '客服系统',
207
+ date: this.$login.toStandardDateString(),
208
+ tabs: [], //已初始化页签数组
209
+ selecttab: '',
210
+ setting: true,
211
+ srcsetting: '../../static/newStyle/setting.png',
212
+ showwatermakeflag: false,
213
+ gasbrandIdData: [],
214
+ showRemind: false,
215
+ dataRemind: [],
216
+ connectNumber:10,
217
+ timeout: 5000,
218
+ // headerHint: true, // 右侧顶部提示信息
219
+ // value: 25645.26,
220
+ // AddChangeMsgShow: false,
221
+ // showsum: false
222
+ }
223
+ },
224
+ ready() {
225
+ //使用socket发送代办消息提醒
226
+ vue.prototype.$connectNumber = this.connectNumber
227
+ // this.initWebSocket()
228
+ getwartermakr(this);
229
+ let component = this.$login.getUrlCompileParames('component')
230
+ if (component) {
231
+ this.isManger = true
232
+ this.$refs.route.init(component, {data: this.functions.functions})
233
+ }
234
+ if (this.$login.f.password == '1') {
235
+ this.$showMessage('本地登录系统为此账户的初始密码,请确认修改密码!!!', ['confirm', 'cancel']).then((res) => {
236
+ if (res == 'confirm')
237
+ this.show = true
238
+ })
239
+ }
240
+ console.log("系统名称", this.$appdata.getSingleValue("系统名称"))
241
+ this.systemname = this.$appdata.getSingleValue("系统名称") ? this.$appdata.getSingleValue("系统名称") : '客服系统'
242
+ // let oBox = this.getElement("box")
243
+ // let oTop = this.getElement("top")
244
+ // let oBottom = this.getElement("bottom")
245
+ // let oLine = this.getElement("line")
246
+ // let that = this
247
+ // oLine.onmousedown = function(e) {
248
+ // let disX = (e || event).clientX
249
+ // oLine.left = oLine.offsetLeft
250
+ // document.onmousemove = function(e) {
251
+ // let iT = oLine.left + ((e || event).clientX - disX)
252
+ // var e = e || window.event
253
+ // let tarnameb = e.target || e.srcElement
254
+ // let maxT = oBox.clientWight - oLine.offsetWidth
255
+ // oLine.style.margin = 0
256
+ // iT < 0 && (iT = 0)
257
+ // iT > maxT && (iT = maxT)
258
+ // oLine.style.left = oTop.style.width = iT + "px"
259
+ // oBottom.style.width = oBox.clientWidth - iT + "px"
260
+ // that.$set('treeWidth', iT)
261
+ // return false
262
+ // }
263
+ // document.onmouseup = function() {
264
+ // document.onmousemove = null
265
+ // document.onmouseup = null
266
+ // oLine.releaseCapture && oLine.releaseCapture()
267
+ // }
268
+ // oLine.setCapture && oLine.setCapture()
269
+ // return false
270
+ // }
271
+ this.changeShow()
272
+ const istelRemindTimes =this.$appdata.getSingleValue("是否开启工单提醒定时器")
273
+ if(istelRemindTimes=='是'){
274
+ this.getTimesgotoWorkOrderSite()
275
+ }
276
+ const isapplyRemind =this.$appdata.getSingleValue("是否开启提醒")
277
+ const times =this.$appdata.getSingleValue("提示间隔分钟")
278
+ if(isapplyRemind=='是'){
279
+ this.config.isTip = true
280
+ this.config.times = times
281
+ }
282
+ // 获取预约列表
283
+ this.functions.f_role_name && this.functions.f_role_name.includes(this.config.msgRole) && this.config.isTip && this.getOrderList()
284
+ if (this.config.approve) {
285
+ this.getFlowList()
286
+ }
287
+ // 获取卡表动态库到期时间
288
+ this.getExpireDate()
289
+ this.getApplynum()
290
+ },
291
+ methods: {
292
+ // 清除
293
+ reset () {
294
+ clearTimeout(this.timeoutObj)
295
+ clearTimeout(this.serverTimeoutObj)
296
+ },
297
+ //每隔几分钟发送一个固定信息给服务端,服务端收到后回复一个固定信息
298
+ //如果服务端在一定时间内没有收到信息,就认为客户端断开了,服务端就会断开连接
299
+ // 发送心跳--确保连接有效
300
+ start () {
301
+ // 重置
302
+ vue.prototype.$connectNumber = this.connectNumber // 重置重连次数
303
+ this.timeoutObj = setTimeout(() => {
304
+ this.$socket.send('ping')
305
+ console.log('ping!')
306
+ this.serverTimeoutObj = setTimeout(() => {
307
+ this.$socket.close()
308
+ }, this.timeout)
309
+ }, this.timeout)
310
+ },
311
+ // 重连
312
+ reconnect () {
313
+ if (this.lockReconnect) return
314
+ // if (this.$connectNumber <= 0) {
315
+ // vue.showMessage('连接已断开,将无法接收消息,请重新登录', ['confirm']).then((res) => {
316
+ // if (res === 'confirm') {
317
+ // location.reload()
318
+ // }
319
+ // })
320
+ // return
321
+ // }
322
+ // this.$connectNumber--
323
+ setTimeout(() => {
324
+ console.log('连接异常,尝试重新连接。。。。')
325
+ this.initWebSocket()
326
+ this.lockReconnect = false
327
+ }, 1000 * 60)
328
+ },
329
+ // 初始化
330
+ initWebSocket () {
331
+ let path = `ws://${location.host}/ws?token=${this.$login.f.id}`
332
+ try {
333
+ if ('WebSocket' in window) {
334
+ // 创建对象
335
+ vue.prototype.$socket = new WebSocket(path)
336
+ } else {
337
+ this.$showMessage('您的浏览器不支持websocket的协议,建议使用新版谷歌浏览器,请勿使用IE浏览器,360浏览器请使用极速模式,不要使用兼容模式!"')
338
+ }
339
+ } catch (e) {
340
+ this.reconnect()
341
+ }
342
+
343
+ this.$socket.onopen = this.onOpen // 连接成功
344
+ this.$socket.onmessage = this.onMessage // 收到消息时回调
345
+ this.$socket.onclose = this.onClose // 连接关闭时回调
346
+ this.$socket.onerror = this.onError // 通讯异常
347
+ },
348
+ // 通讯异常
349
+ onError () {
350
+ console.log('通讯异常')
351
+ this.reconnect()
352
+ },
353
+ // 连接成功
354
+ onOpen () {
355
+ console.log('webSocket连接成功')
356
+ this.start()//每十秒发送心跳包,确保连接状态有效
357
+ },
358
+ // 收到消息时回调函数
359
+ onMessage (event) {
360
+ if (event.data === 'pong') { //建立心跳机制发送ping,返回pong
361
+ this.reset() // 重置心跳
362
+ this.start() // 重新开始心跳
363
+ return
364
+ }
365
+ //不是pong消息,就是服务器返回的消息(提示消息)
366
+ let data = JSON.parse(event.data)
367
+ this.$showMessage(data.message)
368
+ },
369
+ // 关闭连接时回调函数
370
+ onClose () {
371
+ console.log('webSocket连接断开')
372
+ this.reset()
373
+ this.reconnect() // 重连
374
+ },
375
+ getOrderList(){
376
+ let times = this.config.times * 60 * 1000
377
+ console.log("=定时提示间隔=", times)
378
+ try {
379
+ this.interval = setInterval(() => {
380
+ this.getDaiBan()
381
+ }, times)
382
+ } catch (error) {
383
+ console.log('捕获到异常', error)
384
+ }
385
+ },
386
+ getFlowList(){
387
+ console.log('======获取流程审核待办=====')
388
+ let times = this.config.approveTimes * 60 * 1000
389
+ console.log("=定时提示间隔=", times)
390
+ try {
391
+ this.interval = setInterval(() => {
392
+ this.getFlowDaiBan()
393
+ }, times)
394
+ } catch (error) {
395
+ console.log('捕获到异常', error)
396
+ }
397
+ },
398
+ async getFlowDaiBan(){
399
+ this.flowDaiBan = ''
400
+ let http = new HttpResetClass()
401
+ let data = {
402
+ condition: `f_handler = '${this.$login.f.name}'`
403
+ }
404
+ await http.load('POST', 'rs/sql/future_getMyWorkFlowList', {data: data}, {
405
+ resolveMsg: null,
406
+ rejectMsg: null
407
+ }).then((res) => {
408
+ if (res.data.length > 0){
409
+ this.flowDaiBan = `您有${res.data.length}条需要处理的审核流程业务!`
410
+ }
411
+ }).catch((e)=>{
412
+ console.log('报错了!!')
413
+ console.error(e)
414
+ })
415
+ if(this.flowDaiBan){
416
+ this.newTipShow = true
417
+ }
418
+ },
419
+ getTimesgotoWorkOrderSite(){
420
+ let teltimes = 2*60*1000 // 两分钟
421
+ try {
422
+ this.intervaltx =setInterval(()=>{
423
+ this.gotoWorkOrderSite()
424
+ },teltimes)
425
+ }catch (e) {
426
+ console.log('捕获到异常', e)
427
+ }
428
+ },
429
+ async getDaiBan(){
430
+ this.OrderDaiBan = ''
431
+ this.AppDaiBan = ''
432
+ let http = new HttpResetClass()
433
+ await http.load('POST', '/rs/sql/singleTable', {data: {
434
+ tablename:'t_order_center',
435
+ condition:` (f_orderstate != '预约成功' and f_orgstr ='${this.$login.f.orgid}' and f_orderstate != '预约失败' ) or f_orderstate is null`
436
+ }}, {
437
+ resolveMsg: null,
438
+ rejectMsg: null
439
+ }).then((res) => {
440
+ let OrderDaiBan = {}
441
+ res.data.forEach(item=>{
442
+ OrderDaiBan[item.f_ordertype] = OrderDaiBan[item.f_ordertype] || []
443
+ OrderDaiBan[item.f_ordertype].push(item)
444
+ })
445
+ if (res.data.length> 0){
446
+ this.OrderDaiBan = `您有${res.data.length}条需要处理的微信预约业务!`
447
+ this.OrderDaiBan += `其中 ${Object.keys(OrderDaiBan).map(key=>`${key}:${OrderDaiBan[key].length}条`).join(', ')}`
448
+ }
449
+ })
450
+ let data = {
451
+ condition: '1 = 1',
452
+ data: {
453
+ orgid: this.$login.f.orgid,
454
+ id: this.$login.f.id
455
+ }
456
+ }
457
+ await http.load('POST', '/rs/sql/checkuser', {data: data}, {
458
+ resolveMsg: null,
459
+ rejectMsg: null
460
+ }).then((res) => {
461
+ let AppDaiBan = {}
462
+ res.data.forEach(item=>{
463
+ AppDaiBan[item.defname] = AppDaiBan[item.defname] || []
464
+ AppDaiBan[item.defname].push(item)
465
+ })
466
+ if (res.data.length> 0){
467
+ this.AppDaiBan = `您有${res.data.length}条需要处理的报建待办业务!`
468
+ this.AppDaiBan += `其中 ${Object.keys(AppDaiBan).map(key=>`${key}:${AppDaiBan[key].length}条`).join(', ')}`
469
+ }
470
+ }).catch((e)=>{
471
+ console.error(e)
472
+ })
473
+ if(this.AppDaiBan || this.OrderDaiBan){
474
+ this.newTipShow = true
475
+ }
476
+ },
477
+ // 获取动态库卡表到期日
478
+ async getExpireDate(){
479
+ // 获取分公司的表品牌id
480
+ let http = new HttpResetClass()
481
+ await http.load('POST', '/rs/sql/singleTable', {data: {
482
+ tablename:'t_gasbrand_orgid',
483
+ condition:`f_using_orgid ='${this.$login.f.orgid}'`
484
+ }}, {
485
+ resolveMsg: null,
486
+ rejectMsg: null
487
+ }).then((res) => {
488
+ if (res.data.length > 0) {
489
+ res.data.forEach(item => {
490
+ this.gasbrandIdData.push(item.f_gasbrand_id)
491
+ })
492
+ }
493
+ if (this.gasbrandIdData.length > 0) {
494
+ // 获取卡表到期时间
495
+ http.load('POST', '/rs/sql/singleTable', {data: {
496
+ tablename:'t_gasbrand',
497
+ condition:`id in (${this.gasbrandIdData}) and f_meter_type like '%卡表%'`
498
+ }}, {
499
+ resolveMsg: null,
500
+ rejectMsg: null
501
+ }).then((res) => {
502
+ if (res.data.length > 0) {
503
+ res.data.forEach(itre => {
504
+ let band = null
505
+ if ('f_dynamic_expire' in itre) {
506
+ console.log(itre.f_dynamic_expire)
507
+ if (itre.f_dynamic_expire !== null && itre.f_dynamic_expire !== '') {
508
+ let todayold = new Date(itre.f_dynamic_expire)
509
+ todayold.setDate(todayold.getDate() - parseInt(this.$appdata.getSingleValue('动态库提醒天数设置')))
510
+ let today = new Date()
511
+ if (today > todayold) {
512
+ band = {type:'卡表',brand:itre.f_meter_brand}
513
+ this.dataRemind.push(band)
514
+ }
515
+ }
516
+ }
517
+ })
518
+
519
+ }
520
+ if (this.dataRemind.length > 0) {
521
+ this.showRemind = true
522
+ // this.$showMessage(band + '。' +
523
+ // '卡表动态库到期,请联系售后尽快注册!')
524
+ }
525
+ })
526
+ }
527
+ })
528
+ },
529
+ // 提醒框被点击
530
+ tipClick(){
531
+ this.newTipShow = false
532
+ this.newTipContextShow = true
533
+ },
534
+ getApplynum(){
535
+ const isRemind =this.$appdata.getSingleValue("报建代办提醒")
536
+ if(isRemind=='是'){
537
+ var data={
538
+ condition: " 1=1 ",
539
+ condValue: [],
540
+ data: {
541
+ id: this.$login.f.id,
542
+ orgid: this.$login.f.orgid
543
+ }
544
+ }
545
+ debugger
546
+ new HttpResetClass().load('POST','rs/sql/checkuser/n',
547
+ {data}, {resolveMsg: null, rejectMsg: null}).then(res=>{
548
+ if(res.data && res.data.n !== 0){
549
+ this.$showMessage('你有'+res.data.n+'个报建待处理,请尽快前往报建流程面进行处理')
550
+ }
551
+ })
552
+
553
+ }
554
+ },
555
+ gotoWorkOrderSite(){
556
+ const isRemind =this.$appdata.getSingleValue("站点工单提醒")
557
+ console.log('站点工单是否提醒',isRemind)
558
+ if(isRemind && isRemind !== '是'){
559
+ return
560
+ }
561
+ if(this.functions && this.functions.f_role_name && this.functions.f_role_name.indexOf('派单员') !== -1){
562
+ const data = {
563
+ "condition":
564
+ {
565
+ "condition":" 1=1 and processins.activities[ state='开始活动' and (defname in('站点接单'))].count(*) > 0 ",
566
+ "sign":"1=1"
567
+ },
568
+ "userid":this.functions.name
569
+ }
570
+ new HttpResetClass().load('POST','rs/path/operatorService/n', {data}, {resolveMsg: null, rejectMsg: null}).then(res=>{
571
+ if(res.data && res.data.n !== 0){
572
+ this.$showMessage('你有'+res.data.n+'个工单待处理,请尽快前往站点工单页面进行处理')
573
+ }
574
+ })
575
+ }
576
+ },
577
+ openUrl() {
578
+ var url = `http://123.60.214.109:8406/submitTicket?contact=${this.$login.f.name}&orgName=${this.$login.f.orgs}&phone=${this.$login.f.f_user_telephone}`
579
+ window.open(url, '_blank')
580
+ },
581
+ hindsetting() {
582
+ this.setting = !this.setting
583
+ if (this.setting) {
584
+ this.srcsetting = '../../static/newStyle/setting.png'
585
+ } else {
586
+ this.srcsetting = '../../static/newStyle/setting1.png'
587
+ }
588
+
589
+ },
590
+ hindsetting1() {
591
+
592
+ if (!this.setting) {
593
+ this.srcsetting = '../../static/newStyle/setting.png'
594
+ this.setting = true
595
+ }
596
+
597
+ },
598
+ isnodo(val) {
599
+ console.log(val, 'ss')
600
+ this.selecttab = val
601
+ },
602
+ unfurl() {
603
+ if (this.showsum) {
604
+ this.showsum = false
605
+ } else {
606
+ this.showsum = true
607
+ }
608
+ },
609
+ // getElement(id) {
610
+ // return document.getElementById(id)
611
+ // },
612
+ changeShow() {
613
+ // this.treeOrIcon = !this.treeOrIcon
614
+ // let oBox = this.getElement("box")
615
+ // let oTop = this.getElement("top")
616
+ // let oBottom = this.getElement("bottom")
617
+ // let oLine = this.getElement("line")
618
+ // if (this.treeOrIcon) {
619
+ // // oLine.style.left = oTop.style.width = 300 + "px"
620
+ // oTop.style.width = 150 + "px"
621
+ // oBottom.style.width = oBox.clientWidth - 150 + "px"
622
+ // }else {
623
+ // oLine.style.left = oTop.style.width = 50 + "px"
624
+ // oBottom.style.width = oBox.clientWidth - 50 + "px"
625
+ // }
626
+ // }
627
+ this.treeOrIcon = !this.treeOrIcon
628
+ // if (this.treeOrIcon) {
629
+ // this.$els.top.style.width = 14 + "%"
630
+ // this.$els.bottom.style.width = this.$els.box.clientWidth - 14 + "%"
631
+ // }else {
632
+ // this.$els.top.style.width = 8 + "%"
633
+ // this.$els.bottom.style.width = this.$els.box.clientWidth - 8 + "%"
634
+ // }
635
+ },
636
+ changeMain(userid) {
637
+ this.$goto('res-main', {userid: this.userid}, 'self')
638
+ },
639
+ tabChange(name) {
640
+ console.log(name, 'tabchanage')
641
+ this.selecttab = name
642
+ this.$refs.tree.changeSelect(name)
643
+ },
644
+ tabcg(val) {
645
+ console.log(val)
646
+ this.tabs = val
647
+ },
648
+ logOut() {
649
+ console.log(this.$login.f)
650
+ this.$showMessage('您确定要退出系统吗?', ['confirm', 'cancel']).then(async (res) => {
651
+ if (res == 'confirm') {
652
+ let data = {
653
+ userid: this.$login.f.id,
654
+ username: this.$login.f.name,
655
+ usertelephone: this.$login.f.f_user_telephone
656
+ }
657
+ await this.$resetpost('rs/logic/logOut', data, {resolveMsg: '退出成功', rejectMsg: null})
658
+ window.location.reload()
659
+ }
660
+ })
661
+ }
662
+ },
663
+ computed: {
664
+ nowDate() {
665
+ return this.$login.getNowDate()
666
+ }
667
+ }
668
+ }
669
+ </script>
670
+ <style lang="less">
671
+ .newTip-transition {
672
+ transition: all .4s ease;
673
+ }
674
+ .newTip-enter, .newTip-leave {
675
+ height: 0;
676
+ padding: 0 10px;
677
+ opacity: 0;
678
+ }
679
+ .newTip a {
680
+ color: #333;
681
+ }
682
+ .newTip {
683
+ cursor: pointer;
684
+ text-align: center;
685
+ position: absolute;
686
+ top: 3em;
687
+ margin: 0 auto;
688
+ width: 200px;
689
+ left: 48%;
690
+ line-height: 2;
691
+ z-index: 10010;
692
+ box-shadow: 0 4px 12px rgba(0,0,0,0.38);
693
+ pointer-events: all;
694
+ border-radius: 4px;
695
+ background-color: whitesmoke;
696
+ }
697
+ /* 组件内通用样式 */
698
+ .select-error {
699
+ button {
700
+ border-bottom: 1px solid #a94442 !important;
701
+ }
702
+ }
703
+
704
+ // input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{
705
+ // -webkit-appearance:textfield;
706
+ // }
707
+ /* 表单输入框组 */
708
+ .form-input-group {
709
+ display: flex;
710
+
711
+ label {
712
+ width: 100px;
713
+ text-align: right;
714
+
715
+ + * {
716
+ flex: 1;
717
+ }
718
+ }
719
+ }
720
+
721
+ // 日期组件在表单中沾满
722
+ .form-horizontal .datepicker {
723
+ width: 100%;
724
+ }
725
+
726
+ // 下拉选择框占据剩余全部空间
727
+ .select-overspread {
728
+ .form-group {
729
+ // margin: 0px 5px 10px 0px;
730
+ .form-control {
731
+ margin-right: 0px;
732
+ }
733
+ }
734
+
735
+ .btn-group, .btn-group-vertical {
736
+ width: 100%;
737
+ // padding-right: 5px;
738
+ button {
739
+ width: 100%;
740
+ display: flex;
741
+ justify-content: space-between;
742
+ align-items: center;
743
+ }
744
+ }
745
+
746
+ .dropdown-menu {
747
+ width: 100%
748
+ }
749
+ }
750
+
751
+ // 需要特定宽度的的样式
752
+ .width-60 {
753
+ width: 60px;
754
+ }
755
+
756
+ .userpanel {
757
+ font-weight: 300;
758
+ color: #333;
759
+ position: fixed;
760
+ right: 30px;
761
+ top: 45px;
762
+ background-color: white;
763
+ box-shadow: darkgrey 0.5px 0.5px 0.5px 0.5px;
764
+ padding: 4px 10px 4px 10px;
765
+ border-radius: 2px;
766
+ }
767
+
768
+ .width-80 {
769
+ width: 80px;
770
+ }
771
+
772
+ .width-100 {
773
+ width: 100px;
774
+ }
775
+
776
+
777
+ /*右侧区域的背景*/
778
+ .right-bg {
779
+ width: 100%;
780
+ flex: 1;
781
+ color: #304A66;
782
+ }
783
+
784
+ .tree-flex {
785
+ height: 100%;
786
+ // width: 150px;
787
+ /*width: 60px;*/
788
+ background: #4a7cae;
789
+ color: #fff;
790
+
791
+ }
792
+
793
+ .tree-flex-icon {
794
+ width: 50px;
795
+ /*transition: 0.5s;*/
796
+
797
+ > .span {
798
+ overflow-x: visible;
799
+ }
800
+ }
801
+
802
+ .tree-flex h3 {
803
+ text-align: center;
804
+ margin: 1em 0;
805
+ }
806
+
807
+ .tree-flex-footer {
808
+ height: 50px;
809
+ display: flex;
810
+ flex-direction: column;
811
+ color: #fff;
812
+ }
813
+
814
+ .tree-flex-footer a, .tree-flex-footer button {
815
+ flex: 1;
816
+ padding: 8px 5px;
817
+ font-size: 1.2em;
818
+ // border-top: 1px solid #697D93;
819
+ border-top: 1px solid #4a7cae;
820
+ text-decoration: none;
821
+ color: #fff;
822
+ cursor: pointer;
823
+ }
824
+
825
+ .tree-flex-footer button {
826
+ height: auto;
827
+ width: 100%;
828
+ border-radius: 0px;
829
+ background-color: rgba(255, 255, 255, 0);
830
+ border: none;
831
+ border-top: 1px solid #4a7cae;
832
+ // border-top: 1px solid #697D93;
833
+ text-align: left;
834
+ }
835
+
836
+ .tree-flex-footer button:hover {
837
+ outline: none;
838
+ background-color: rgba(255, 255, 255, 0.2);
839
+ }
840
+
841
+ .tree-flex-footer button:focus {
842
+ outline: none;
843
+ background-color: rgba(255, 255, 255, 0.5);
844
+ }
845
+
846
+ .tree-flex-footer a:hover {
847
+ color: #FFF;
848
+ background-color: rgba(255, 255, 255, 0.2);
849
+ }
850
+
851
+ .tree-flex .btn-group {
852
+ height: 50px !important;
853
+ }
854
+
855
+ .tree-flex .dropdown-menu {
856
+ /* 控制显示列表的样式 */
857
+ background: #4a7cae;
858
+ border-radius: 0px;
859
+ color: #fff;
860
+ width: auto;
861
+ margin: 0px;
862
+ padding: 0px;
863
+ }
864
+
865
+ .tree-flex .dropdown-menu-up {
866
+ /* bottom,top控制上下,left和right控制左右*/
867
+ left: 100% !important;
868
+ top: auto !important;
869
+ bottom: 0;
870
+ }
871
+
872
+ .tree-flex .dropdown-menu-down {
873
+ /* bottom,top控制上下,left和right控制左右*/
874
+ left: 100% !important;
875
+ top: 0 !important;
876
+ }
877
+
878
+ .tree-flex .dropdown-menu li {
879
+ text-align: center;
880
+ line-height: 50px;
881
+ border-bottom: 1px solid #697D93;
882
+ font-size: 1.2em;
883
+ width: auto;
884
+ white-space: nowrap;
885
+ cursor: default;
886
+
887
+ }
888
+
889
+ .tree-flex .dropdown-menu li + li {
890
+ text-align: left;
891
+ border: 0;
892
+ line-height: 40px;
893
+ padding-left: 15px;
894
+ padding-right: 15px;
895
+ font-size: 1em;
896
+ cursor: pointer;
897
+ }
898
+
899
+ .tree-flex .dropdown-menu li + li:hover {
900
+ background-color: rgba(255, 255, 255, 0.2);
901
+ }
902
+
903
+ .tree-flex .dropdown-menu li a {
904
+ border: none;
905
+ color: #fff;
906
+ height: 40px;
907
+ line-height: 40px;
908
+ font-size: 1em;
909
+ padding: 0px;
910
+ }
911
+
912
+ .tree-flex .dropdown-menu li a:hover {
913
+ color: #fff;
914
+ background-color: rgba(255, 255, 255, 0);
915
+ }
916
+
917
+ .tree-flex img {
918
+ height: 1.2em;
919
+ width: 1.2em;
920
+ margin-right: 15px;
921
+ margin-left: 5px;
922
+ }
923
+
924
+ .line {
925
+ height: 100%;
926
+ width: 5px;
927
+ background: #4C637B;
928
+ cursor: e-resize;
929
+ }
930
+
931
+ /*为树(tree)组件写的样式*/
932
+ .tree-img {
933
+ font-size: 1.2em;
934
+ }
935
+
936
+ /*将较长信息截断显示,鼠标悬停显示全部信息*/
937
+ .cutout50 {
938
+ max-width: 50px;
939
+ overflow: hidden;
940
+ text-overflow: ellipsis;
941
+ white-space: nowrap;
942
+ }
943
+
944
+ /* 滚动条样式 */
945
+ /*---滚动条默认显示样式--*/
946
+ ::-webkit-scrollbar-thumb {
947
+ // display: none;
948
+ background-color: rgba(0, 0, 0, 0.4);
949
+ /*background-color:red;*/
950
+ height: 50px;
951
+ outline-offset: -2px;
952
+ /*outline:2px solid #fff;*/
953
+ -webkit-border-radius: 4px;
954
+ /*border: 2px solid #fff;*/
955
+ }
956
+
957
+ /*---鼠标点击滚动条显示样式--*/
958
+ ::-webkit-scrollbar-thumb:hover {
959
+ // display: inherit;
960
+ background-color: rgba(0, 0, 0, 0.4);
961
+ height: 50px;
962
+ -webkit-border-radius: 4px;
963
+ }
964
+
965
+ /*---滚动条大小--*/
966
+ ::-webkit-scrollbar {
967
+ width: 8px;
968
+ height: 8px;
969
+ }
970
+
971
+ /*---滚动框背景样式--*/
972
+ ::-webkit-scrollbar-track-piece {
973
+ /* 全透明,不显示 */
974
+ background-color: rgba(255, 255, 255, 0);
975
+ -webkit-border-radius: 0;
976
+ }
977
+ </style>