zhulizhen1111 5 年之前
父节点
当前提交
b9579cdcda

+ 7 - 33
config/index.js

@@ -13,45 +13,19 @@ module.exports = {
       '/api': {
           target:"http://192.168.20.225:8080",//设置你调用的接口域名和端口号 别忘了加http
           changeOrigin: true,
-          pathRewrite: {
-              '^/api': '/' // 这里理解成用‘/api’代替target里面的地址,后面组件中我们掉接口时直接用api代替 比如我要调用'http://40.00.100.100:3002/user/add',直接写‘/api/user/add’即可
-          }
       },
       '/data-platform-3':{
-        target:"http://101.200.32.13:28888",
-        changeOrigin:true, 
-        pathRewrite:{
-          '^/data-platform-3': '/'
-        }
-      },
-      '/alarm-system':{
-        target:"http://47.93.33.207:8889",
-        changeOrigin:true,
-        pathRewrite:{
-          '^/alarm-system': '/'
-        }
-      },
-      '/workorder':{
-        target:"http://47.94.89.44:8081",
-        changeOrigin:true,
-        pathRewrite:{
-          '^/workorder': '/'
-        }
+        target:"http://api.sagacloud.cn/",
+        changeOrigin:true 
       },
       '/info-mng-backend': {
-        target:"http://192.168.20.33:8080",//故障代理
+        target:" http://hyy.sagacloud.cn",//故障代理
         changeOrigin: true,
-        pathRewrite: {
-          '^/info-mng-backend': '/' // 这里理解成用‘/api’代替target里面的地址,后面组件中我们掉接口时直接用api代替 比如我要调用'http://40.00.100.100:3002/user/add',直接写‘/api/user/add’即可
-        }
       },
-      '/image-service': {
-        target:"http://service.sagacloud.cn:28888",
-        changeOrigin:true,
-        pathRewrite:{
-          '^/image-service': '/'
-        }
-      }
+      '/dp-auxiliary':{
+        target:"http://api.sagacloud.cn/",
+        changeOrigin:true 
+      },
   },
 
     // Various Dev Server settings

+ 1 - 1
src/common/swipe.vue

@@ -5,7 +5,7 @@
 
        <div class="loop-content">
             <div class="contanier" :style="`transform: translateX(-${index * 104}px)`">
-                <img v-for="(item, index) in list" :key="index" :src="item.key?`/image-service/common/image_get?systemId=dataPlatform&key=${item.key}&width=96&height=95`:``">
+                <img v-for="(item, index) in list" :key="index" :src="item.key?`/dp-auxiliary/image-service/common/image_get?systemId=dataPlatform&key=${item.key}&width=96&height=95`:``">
             </div>
         </div>
 

+ 1 - 1
src/store/index.js

@@ -33,7 +33,7 @@ const store = new Vuex.Store({
   },
   actions: {
     loadEquipmentAll (context) {
-      axios.get(`/data-platform-3/data-platform-3/dict/query/equipment_all`).then(res => {
+      axios.get(`/data-platform-3/dict/query/equipment_all`).then(res => {
         let data = res.data
         if (data.Result === 'success') {
           // context.state.equipmentAll = data.Content

+ 3 - 3
src/views/asset/index.vue

@@ -8,7 +8,7 @@
               <tr class="RQ">
                 <td>资产二维码</td>
                 <td class="qr-code">
-                  <img :src="Info.infos.EquipQRCode?`/image-service/image-service/common/file_get?systemId=dataPlatform&key=${Info.infos.EquipQRCode}`:'/static/img/noimg.png'">
+                  <img :src="Info.infos.EquipQRCode?`/dp-auxiliary/image-service/common/file_get?systemId=dataPlatform&key=${Info.infos.EquipQRCode}`:'/static/img/noimg.png'">
                    <p class="download" v-if="Info.infos.EquipQRCode"   @click="downloadFile(Info.infos.EquipQRCode)">下载</p>
                 </td>
                 <td><p v-if="Info.infos.InsuranceNum_his">保险保单 <span >{{Info.infos.InsuranceNum_his.length || 0 }}份</span></p><p v-if="Info.infos.InstallDrawing_his">资产图纸 <span>{{Info.infos.InstallDrawing_his.length || 0 }}份</span></p></td>
@@ -79,7 +79,7 @@
               </div>
              </div>
              <div class="image-content" v-if="Info.infos.Pic && keySrc">
-               <img :src="`/image-service/image-service/common/image_get?systemId=dataPlatform&key=${keySrc}`">
+               <img :src="`/dp-auxiliary/image-service/common/image_get?systemId=dataPlatform&key=${keySrc}`">
              </div>
 
                <div class="no-right" v-else>
@@ -270,7 +270,7 @@ export default {
       var photosphere = document.getElementById('container')
       // eslint-disable-next-line
       var PSV = new PhotoSphereViewer({
-        panorama: `/image-service/image-service/common/image_get?systemId=dataPlatform&key=${key}`,
+        panorama: `/dp-auxiliary/image-service/common/image_get?systemId=dataPlatform&key=${key}`,
         container: photosphere,
         time_anim: false,
         navbar: true,

+ 1 - 1
src/views/equipment/Handle.vue

@@ -96,7 +96,7 @@ export default {
       let params = {
         objectId: this.objectId
       }
-      axios.post(`/alarm-system/alarm-system/alarm/manualHandle/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/manualHandle/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.lists = Array.from(data.Content)

+ 9 - 7
src/views/equipment/index.vue

@@ -108,11 +108,13 @@ export default {
     // 根据路由得到设备名称和id
     getEqNameAndId () {
       let hostUrl = location.search
-      let pid = hostUrl.split('&')[1].toString().split('=')[1]
-      this.$store.commit('setProId', pid)
-      this.$store.commit(`setSecret`, '')
-      this.eqName = decodeURI(location.hash)
-      this.objectId = hostUrl.split("&")[2]
+      if(hostUrl){
+        let pid = hostUrl.split('&')[1].toString().split('=')[1]
+        this.$store.commit('setProId', pid)
+        this.$store.commit(`setSecret`, '')
+        this.eqName = decodeURI(location.hash)
+        this.objectId = hostUrl.split("&")[2]
+      }
       this.getDataList()
       this.saveAlarmName()
       this.show = true
@@ -132,7 +134,7 @@ export default {
         objectId: this.objectId,
         ctime: ctime
       }
-      axios.post(`/alarm-system/alarm-system/alarm/alarmName/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/alarmName/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.alarmNameList = data.Content
@@ -255,7 +257,7 @@ export default {
         }
       }
       // 请求表格数据
-      axios.post(`/alarm-system/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params)
+      axios.post(`/dp-auxiliary/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params)
         .then(res => {
           let data = res.data
           //   let vm = this

+ 1 - 1
src/views/main/HistoryTable.vue

@@ -298,7 +298,7 @@ export default {
       let params = {
         id: row.id
       }
-      axios.post(`/alarm-system/alarm-system/alarm/detail/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/detail/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.detailData = data.Content

+ 4 - 4
src/views/main/PompBox.vue

@@ -240,11 +240,11 @@ export default {
         if (i.type.toString().split("/")[0] == 'image') {
           type = 'image'
           url = `${baseUrl}/image-service/common/image_upload?systemId=dataPlatform&secret=9e0891a7a8c8e885&key=${fileName}`
-          url1 = `/image-service/image-service/common/image_get?systemId=dataPlatform&key=${fileName}`
+          url1 = `/dp-auxiliary/image-service/common/image_get?systemId=dataPlatform&key=${fileName}`
         } else {
           type = "file"
           url = `${baseUrl}/image-service/common/file_upload?systemId=dataPlatform&secret=9e0891a7a8c8e885&key=${fileName}`
-          url1 = `/image-service/image-service/common/file_get?systemId=dataPlatform&key=${fileName}`
+          url1 = `/dp-auxiliary/image-service/common/file_get?systemId=dataPlatform&key=${fileName}`
         }
         let obj = {
           fileName: fileName,
@@ -289,7 +289,7 @@ export default {
         note: this.note, // 备注,选填
         attachment: this.attachment
       }
-      axios.post(`/alarm-system/alarm-system/alarm/manualHandle/create?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/manualHandle/create?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         let vm = this
         if (data.Result == 'success') {
@@ -316,7 +316,7 @@ export default {
         objectId: this.detailData.objectId,
         typeCode: this.detailData.typeCode
       }
-      axios.post(`/alarm-system/alarm-system/alarm/manualHandle/recentSameQuery/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/manualHandle/recentSameQuery/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.RecentAlarm = data.Content

+ 1 - 1
src/views/main/Select.vue

@@ -201,7 +201,7 @@ export default {
   methods: {
     // 得到空间列表
     getRoomLists () {
-      axios.get(`/alarm-system/alarm-system/alarm/buildingHierarchy?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`).then(res => {
+      axios.get(`/dp-auxiliary/alarm-system/alarm/buildingHierarchy?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.positionList = data.Content

+ 1 - 1
src/views/main/StatusTable.vue

@@ -268,7 +268,7 @@ export default {
       let params = {
         id: row.id
       }
-      axios.post(`/alarm-system/alarm-system/alarm/detail/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/detail/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.detailData = data.Content

+ 1 - 1
src/views/main/TableAlarm.vue

@@ -255,7 +255,7 @@ export default {
       let params = {
         id: row.id
       }
-      axios.post(`/alarm-system/alarm-system/alarm/detail/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/detail/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.detailData = data.Content

+ 2 - 2
src/views/main/index.vue

@@ -166,7 +166,7 @@ export default {
     },
     // 查询3个tab中涉及到的数据
     query_statistics () {
-      axios.get(`/alarm-system/alarm-system/alarm/statistics/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`)
+      axios.get(`/dp-auxiliary/alarm-system/alarm/statistics/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`)
         .then(res => {
           let data = res.data
           if (data.Result == 'success') {
@@ -236,7 +236,7 @@ export default {
         order: order
       }
       // 请求表格数据
-      axios.post(`/alarm-system/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params)
+      axios.post(`/dp-auxiliary/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params)
         .then(res => {
           let data = res.data
           if (data.Result == 'success') {

+ 2 - 2
src/views/rooms/RoomEq.vue

@@ -8,7 +8,7 @@
               <p class="eq-type">设备型号: <span>{{item.specification}}</span></p>
           </div>
           <div class="box-right">
-              <img :src="`/image-service/image-service/common/file_get?systemId=dataPlatform&key=${item.equipQRCode}`">
+              <img :src="`/dp-auxiliary/image-service/common/file_get?systemId=dataPlatform&key=${item.equipQRCode}`">
           </div>
 
           <div class="box-bottom">
@@ -83,7 +83,7 @@ export default {
       let params = {
         spaceId: 'Sp1101080001dbba0f04aa8b11e8bd139b854ebc9e7b' // 空间id
       }
-      axios.post(`/alarm-system/alarm-system/alarm/equipInSpace/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/equipInSpace/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.content = data.Content

+ 4 - 2
src/views/rooms/index.vue

@@ -133,6 +133,7 @@ export default {
     },
     // 存储条目数
     saveAlarmName (objectId) {
+      console.log(objectId)
       let ctime = {}
       if (Object.values(this.selectParams.selectedStartTime).some(i => i.length)) {
         ctime = {
@@ -146,7 +147,7 @@ export default {
         objectId: objectId,
         ctime: ctime
       }
-      axios.post(`/alarm-system/alarm-system/alarm/alarmName/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/alarmName/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.alarmNameList = data.Content
@@ -199,6 +200,7 @@ export default {
         this.autoHandle = false
         this.dateLimitDays = Number.MAX_SAFE_INTEGER
       } else if (status == 1) {
+        debugger
         this.status = null
         this.autoHandle = null
         this.dateLimitDays = 30
@@ -267,7 +269,7 @@ export default {
         }
       }
       // 请求表格数据
-      axios.post(`/alarm-system/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params)
+      axios.post(`/dp-auxiliary/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params)
         .then(res => {
           let data = res.data
           if (data.Result == 'success') {

+ 2 - 2
src/views/spread/MessageModal.vue

@@ -6,7 +6,7 @@
           <button class="my-btn" @click="exportData">下载</button>
       </div>
        <div class="mod-content" v-else>
-            <img v-if="isQR" :src="`/image-service/image-service/common/file_get?systemId=dataPlatform&key=${isQR}`" alt="">
+            <img v-if="isQR" :src="`/dp-auxiliary/image-service/common/file_get?systemId=dataPlatform&key=${isQR}`" alt="">
             <button class="my-btn" @click="downQR">下载</button>
      </div>
   </div>
@@ -71,7 +71,7 @@ export default {
       this.$emit('close')
     },
     downQR () {
-      const url = `/image-service/image-service/common/file_get?systemId=dataPlatform&key=${this.isQR}`
+      const url = `/dp-auxiliary/image-service/common/file_get?systemId=dataPlatform&key=${this.isQR}`
       download(url, 'qr.png')
     },
     exportData () {

+ 3 - 3
src/views/spread/index.vue

@@ -9,7 +9,7 @@
               <tr class="RQ">
                 <td>设备二维码</td>
                 <td class="qr-code">
-                  <img :src="Info.infos.EquipQRCode?`/image-service/image-service/common/file_get?systemId=dataPlatform&key=${Info.infos.EquipQRCode}`:'/static/img/noimg.png'">
+                  <img :src="Info.infos.EquipQRCode?`/dp-auxiliary/image-service/common/file_get?systemId=dataPlatform&key=${Info.infos.EquipQRCode}`:'/static/img/noimg.png'">
                   <p class="download" v-if="Info.infos.EquipQRCode" @click="downloadFile(Info.infos.EquipQRCode)">下载</p>
                 </td>
                 <td><p v-if="Info.infos.InsuranceNum_his">保险保单 <span>{{Info.infos.InsuranceNum_his.length || 0 }}份</span></p><p v-if="Info.infos.InstallDrawing_his">安装图纸 <span>{{Info.infos.InstallDrawing_his.length || 0 }}份</span></p><p v-if="Info.infos.Drawing_his">设备图纸 <span>{{Info.infos.Drawing_his.length || 0 }}份</span></p></td>
@@ -253,7 +253,7 @@ export default {
           "status": "alarm"
         }
       }
-      axios.post(`/alarm-system/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         this.noAlarmNum = data.Count
       })
@@ -416,7 +416,7 @@ export default {
       var div = document.getElementById('container')
       // eslint-disable-next-line
       var PSV = new PhotoSphereViewer({
-        panorama: `/image-service/image-service/common/image_get?systemId=dataPlatform&key=${key}`,
+        panorama: `/dp-auxiliary/image-service/common/image_get?systemId=dataPlatform&key=${key}`,
         container: div,
         time_anim: false,
         navbar: true,

+ 1 - 1
src/views/system/index.vue

@@ -169,7 +169,7 @@ export default {
           status: 'alalrm'
         }
       }
-      axios.post(`/alarm-system/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.noAlarmNum = data.Count

+ 21 - 20
src/views/verit/index.vue

@@ -9,7 +9,7 @@
               <tr class="RQ">
                 <td>空间二维码</td>
                 <td class="qr-code">
-                  <img :src="Info.infos.RoomQRCode?`/image-service/image-service/common/file_get?systemId=dataPlatform&key=${Info.infos.RoomQRCode}`:'/static/img/noimg.png'">
+                  <img :src="Info.infos.RoomQRCode?`/dp-auxiliary/image-service/common/file_get?systemId=dataPlatform&key=${Info.infos.RoomQRCode}`:'/static/img/noimg.png'">
                   <p class="download" v-if="Info.infos.RoomQRCode"  @click="downloadFile(Info.infos.RoomQRCode)">下载</p>
                 </td>
               </tr>
@@ -204,22 +204,23 @@ export default {
   methods: {
     getEqNameAndId () {
       let hostUrl = location.search
-      this.objectId = hostUrl.split("&")[0].toString().split("=")[1]
-      let pid = hostUrl.split("&")[1].toString().split("=")[1]
-      let secret = ''
-      if(hostUrl.split("&")[2]){
-         secret =  hostUrl.split("&")[2].toString().split("=")[1]
+      if(hostUrl){
+        this.objectId = hostUrl.split("&")[0].toString().split("=")[1]
+        let pid = hostUrl.split("&")[1].toString().split("=")[1]
+        let secret = ''
+        if(hostUrl.split("&")[2]){
+          secret =  hostUrl.split("&")[2].toString().split("=")[1]
+        }
+         this.$store.commit('setProId', pid)
+        this.$store.commit(`setSecret`, secret)
+        this.initData(this.objectId)
+        this.searchBuildingName(this.objectId)
+        this.noRecoverAlarm(this.objectId)
+        this.envInfo(this.objectId)
+        this.getCurrentData(this.objectId)
+        this.underwayOrder(this.objectId)
+        this.getMoniCount(this.objectId)
       }
-      console.log(pid, this.$store.state.projId)
-      this.$store.commit('setProId', pid)
-      this.$store.commit(`setSecret`, secret)
-      this.initData(this.objectId)
-      this.searchBuildingName(this.objectId)
-      this.noRecoverAlarm(this.objectId)
-      this.envInfo(this.objectId)
-      this.getCurrentData(this.objectId)
-      this.underwayOrder(this.objectId)
-      this.getMoniCount(this.objectId)
     },
     // 右侧耗电功率和累计用电量的统计
     getCurrentData (objectId) {
@@ -306,7 +307,7 @@ export default {
           status: 'alalrm'
         }
       }
-      axios.post(`/alarm-system/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/list?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           this.noAlarmNum = data.Count
@@ -435,7 +436,7 @@ export default {
       let params = {
         spaceId: this.objectId // 空间id
       }
-      axios.post(`/alarm-system/alarm-system/alarm/equipInSpace/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/equipInSpace/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           let alarm = data.Content
@@ -464,7 +465,7 @@ export default {
       let params = {
         spaceId: this.objectId // 空间id
       }
-      axios.post(`/alarm-system/alarm-system/alarm/equipForSpace/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
+      axios.post(`/dp-auxiliary/alarm-system/alarm/equipForSpace/query?projectId=${this.$store.state.projId}&secret=${this.$store.state.secret}`, params).then(res => {
         let data = res.data
         if (data.Result == 'success') {
           let alarm = data.Content
@@ -490,7 +491,7 @@ export default {
       // let baseUrl = this.$store.state.baseUrl
       // eslint-disable-next-line
       var PSV = new PhotoSphereViewer({
-        panorama: `/image-service/image-service/common/image_get?systemId=dataPlatform&key=${key}`,
+        panorama: `/dp-auxiliary/image-service/common/image_get?systemId=dataPlatform&key=${key}`,
         container: div,
         time_anim: false,
         navbar: true,

+ 1 - 1
src/views/verit/picSwipe.vue

@@ -6,7 +6,7 @@
        <div class="loop-content">
             <div class="contanier" :style="`transform: translateX(-${index * 180}px)`">
                 <span  v-for="(item, index) in list" :key="index">
-                    <img :src="item.key?`/image-service/image-service/common/image_get?systemId=dataPlatform&key=${item.key}&width=96&height=95`:``" @click="onClick(item)">
+                    <img :src="item.key?`/dp-auxiliary/image-service/common/image_get?systemId=dataPlatform&key=${item.key}&width=96&height=95`:``" @click="onClick(item)">
                     <span class="alt-name">{{item.name}}</span>
                 </span>