浏览代码

websocket地址修改

wangziqian 4 年之前
父节点
当前提交
88999f7f45

+ 8 - 0
src/apiConfig/requestIP.js

@@ -15,3 +15,11 @@ if (location.host.indexOf('localhost') < 0) {
     envTag = 'online'
   }
 }
+
+export let ws = '10.78.128.20:10234'
+if (location.host.match(/localhost/) || location.host.match(/zhihui-test/)) {
+  ws = '10.78.128.20:10232'
+} else if (location.host.match(/zhihui-pre/)) {
+  ws = '10.78.128.20:10233'
+}
+

+ 0 - 3
src/views/workbench/components/statisticsSection.vue

@@ -248,9 +248,6 @@ export default {
       font-weight: 400;
       color: #666666;
       cursor:pointer;
-      i {
-        font-size: 12px;
-      }
     }
     .number {
       font-weight: 500;

+ 3 - 2
src/views/workbench/mixins/websocket.js

@@ -1,4 +1,4 @@
-import { requestIp } from '@/apiConfig/requestIP'
+import { ws } from '@/apiConfig/requestIP'
 export default {
   name: 'test',
   data() {
@@ -14,7 +14,7 @@ export default {
   },
   methods: {
     initWebSocket() { // 初始化weosocket
-      const wsUri = `${requestIp}/zhihui-websocket/self/remind?ename=${localStorage.getItem('username')}`.replace(/http/, 'ws')
+      const wsUri = `ws://${ws}/zhihui-websocket/self/remind?ename=${localStorage.getItem('username')}`
       this.websock = new WebSocket(wsUri)
       this.websock.onmessage = this.websocketonmessage
       this.websock.onopen = this.websocketonopen
@@ -25,6 +25,7 @@ export default {
 
     },
     websocketonerror() { // 连接建立失败重连
+      console.log('websocket断连')
       this.initWebSocket()
     },
     websocketsend(Data) { // 数据发送

+ 5 - 5
src/views/workbench/team/components/needsList.vue

@@ -69,20 +69,20 @@
           <span>{{ scope.row.pmMemberInfoResponse.name }}</span>
         </template>
       </el-table-column>
+      <el-table-column label="交付日期" min-width="200" align="center" show-overflow-tooltip>
+        <template slot-scope="scope">{{ scope.row.optionsObject === null? '' :scope.row.optionsObject.endTime }}</template>
+      </el-table-column>
       <el-table-column label="需求方向" min-width="150" align="center" show-overflow-tooltip>
         <template v-slot="scope">
           {{ scope.row.rqmtOrntNames }}
         </template>
       </el-table-column>
-      <el-table-column label="跟版客户端" width="200" align="center" prop="referredClientTypeName" show-overflow-tooltip />
-      <el-table-column label="PRD链接" width="300" align="left" prop="mrdUrl" show-overflow-tooltip>
+      <el-table-column label="跟版客户端" width="150" align="center" prop="referredClientTypeName" show-overflow-tooltip />
+      <el-table-column label="PRD链接" width="150" align="left" prop="mrdUrl" show-overflow-tooltip>
         <template v-slot="scope">
           <el-link :href="scope.row.mrdUrl" class="mrdUrl" target="_blank">{{ scope.row.mrdUrl }}</el-link>
         </template>
       </el-table-column>
-      <el-table-column label="交付日期" min-width="200" align="center" show-overflow-tooltip>
-        <template slot-scope="scope">{{ scope.row.optionsObject === null? '' :scope.row.optionsObject.endTime }}</template>
-      </el-table-column>
       <el-table-column label="任务数量" width="100" align="center" prop="taskCount" show-overflow-tooltip />
       <el-table-column label="缺陷数量" width="100" align="center" prop="bugCount" show-overflow-tooltip />
     </el-table>

+ 5 - 5
src/views/workbench/team/components/taskList.vue

@@ -60,7 +60,7 @@
           </div>
         </template>
       </el-table-column>
-      <el-table-column label="状态" width="100" align="center">
+      <el-table-column label="状态" width="150" align="center">
         <template slot-scope="scope">
           <el-select
             v-model="scope.row.status"
@@ -86,16 +86,16 @@
       <el-table-column label="测试负责人" width="100" align="center" show-overflow-tooltip>
         <template slot-scope="scope">{{ scope.row.qaObject ? scope.row.qaObject.name : '' }}</template>
       </el-table-column>
+      <el-table-column label="交付日期" width="150" align="center" show-overflow-tooltip>
+        <template slot-scope="scope">{{ scope.row.optionsObject ? scope.row.optionsObject.endTime : '' }}</template>
+      </el-table-column>
       <el-table-column label="所属模块" width="200" align="center" show-overflow-tooltip>
         <template slot-scope="scope">{{ scope.row.moduleInfoName }}</template>
       </el-table-column>
       <el-table-column label="跟版客户端" width="150" align="center" show-overflow-tooltip>
         <template slot-scope="scope">{{ scope.row.involveAppString || '无' }}</template>
       </el-table-column>
-      <el-table-column label="交付日期" width="150" align="center" show-overflow-tooltip>
-        <template slot-scope="scope">{{ scope.row.optionsObject ? scope.row.optionsObject.endTime : '' }}</template>
-      </el-table-column>
-      <el-table-column label="缺陷数量" width="50" align="center" show-overflow-tooltip>
+      <el-table-column label="缺陷数量" width="100" align="center" show-overflow-tooltip>
         <template slot-scope="scope">{{ scope.row.bugCount }}</template>
       </el-table-column>
       <el-table-column label="任务进度" width="150" align="center">