Browse Source

修改peojectId

chuwu 5 năm trước cách đây
mục cha
commit
b43bf8941e

+ 6 - 4
src/framework/layout/layout-store.js

@@ -12,9 +12,11 @@ export default {
         sidebarSelected: '', // sidebar选中的选项
         userInfo: { username: 'admin' },
         permissions: { "system:role:delete": true, "system:role:create": true, "system:role:query": true, "system:role:setOpts": true },
-        currentProjectId: null,
-        projects: [{ name: '新华创新大厦', id: 'Pj1101080002' }],
-        breadcrumb: []
+        currentProjectId: 'Pj4201050001',
+        projects: [{ name: '新华创新大厦', id: 'Pj1101080002' }, { name: '亚心医院', id: 'Pj4201050001' }],
+        breadcrumb: [],
+        secret: "saga123456", //密码
+        userId: "test", //用户id
     },
     getters: {
         sidebarClosed: state => state.sidebarClosed,
@@ -97,4 +99,4 @@ export default {
             }
         }
     }
-}
+}

+ 4 - 4
src/views/data_admin/buildAssets/NoMap.vue

@@ -71,14 +71,14 @@ export default {
         SagaStation
     },
     computed: {
-        ...mapGetters('peojMess', ['projectId', 'userId', 'secret'])
+        ...mapGetters('layout', ['currentProjectId', 'userId', 'secret'])
     },
     methods: {
         look(row) {
             this.iframeSrc =
                 process.env.BASE_URL +
                 ':8889/#/details?perjectId=' +
-                this.projectId +
+                this.currentProjectId +
                 '&secret=' +
                 this.secret +
                 '&FmId=' +
@@ -100,7 +100,7 @@ export default {
             })
                 .then(() => {
                     let param = {
-                        ProjId: this.projectId,
+                        ProjId: this.currentProjectId,
                         UserId: this.userId
                     }
                     let paramList = [row.FmId]
@@ -136,7 +136,7 @@ export default {
                 PageNum: this.pageNum,
                 PageSize: this.pageSize,
                 Type: 3,
-                ProjId: this.projectId,
+                ProjId: this.currentProjectId,
                 UserId: this.userId
             }
             getErrAssets(param).then(res => {

+ 4 - 4
src/views/data_admin/buildAssets/Nofind.vue

@@ -62,14 +62,14 @@ export default {
         SagaDialog
     },
     computed: {
-        ...mapGetters('peojMess', ['projectId', 'userId', 'secret'])
+        ...mapGetters('layout', ['currentProjectId', 'userId', 'secret'])
     },
     methods: {
         look(row) {
             this.iframeSrc =
                 process.env.BASE_URL +
                 ':8889/#/details?perjectId=' +
-                this.projectId +
+                this.currentProjectId +
                 '&secret=' +
                 this.secret +
                 '&FmId=' +
@@ -86,7 +86,7 @@ export default {
             })
                 .then(() => {
                     let param = {
-                        ProjId: this.projectId,
+                        ProjId: this.currentProjectId,
                         UserId: this.userId
                     }
                     let paramList = [row.FmId]
@@ -119,7 +119,7 @@ export default {
                 PageNum: this.pageNum,
                 PageSize: this.pageSize,
                 Type: 1,
-                ProjId: this.projectId,
+                ProjId: this.currentProjectId,
                 UserId: this.userId
             }
             getErrAssets(param).then(res => {

+ 4 - 4
src/views/data_admin/buildAssets/Nopaint.vue

@@ -61,14 +61,14 @@ export default {
         SagaDialog
     },
     computed: {
-        ...mapGetters('peojMess', ['projectId', 'userId', 'secret'])
+        ...mapGetters('layout', ['currentProjectId', 'userId', 'secret'])
     },
     methods: {
         look(row) {
             this.iframeSrc =
                 process.env.BASE_URL +
                 ':8889/#/details?perjectId=' +
-                this.projectId +
+                this.currentProjectId +
                 '&secret=' +
                 this.secret +
                 '&FmId=' +
@@ -85,7 +85,7 @@ export default {
             })
                 .then(() => {
                     let param = {
-                        ProjId: this.projectId,
+                        ProjId: this.currentProjectId,
                         UserId: this.userId
                     }
                     let paramList = [row.FmId]
@@ -118,7 +118,7 @@ export default {
                 PageNum: this.pageNum,
                 PageSize: this.pageSize,
                 Type: 2,
-                ProjId: this.projectId,
+                ProjId: this.currentProjectId,
                 UserId: this.userId
             }
             getErrAssets(param).then(res => {

+ 4 - 4
src/views/data_admin/buildAssets/Noverify.vue

@@ -89,14 +89,14 @@ export default {
         SagaDialog
     },
     computed: {
-        ...mapGetters('peojMess', ['projectId', 'userId', 'secret'])
+        ...mapGetters('layout', ['currentProjectId', 'userId', 'secret'])
     },
     methods: {
         look(row) {
             this.iframeSrc =
                 process.env.BASE_URL +
                 ':8889/#/details?perjectId=' +
-                this.projectId +
+                this.currentProjectId +
                 '&secret=' +
                 this.secret +
                 '&FmId=' +
@@ -109,7 +109,7 @@ export default {
             this.iframeSrc =
                 process.env.BASE_URL +
                 ':8889/#/details?perjectId=' +
-                this.projectId +
+                this.currentProjectId +
                 '&secret=' +
                 this.secret +
                 '&FmId=' +
@@ -143,7 +143,7 @@ export default {
             })
                 .then(() => {
                     let param = {
-                        ProjId: this.projectId,
+                        ProjId: this.currentProjectId,
                         UserId: this.userId
                     }
                     delErrAssets(param, paramList).then(result => {

+ 3 - 3
src/views/data_admin/buildAssets/Station.vue

@@ -27,7 +27,7 @@ export default {
         }
     },
     computed: {
-        ...mapGetters('peojMess', ['projectId', 'secret', 'userId'])
+        ...mapGetters('layout', ['currentProjectId', 'secret', 'userId'])
     },
     props: {
         options: {
@@ -47,7 +47,7 @@ export default {
                     BuildId: this.itemObj.BuildId,
                     category: this.value,
                     secret: this.secret,
-                    perjectId: this.projectId,
+                    perjectId: this.currentProjectId,
                     BIMID: this.itemObj.FloorId,
                     BIMLocation: (this.itemObj.X || 0) + ',' + (this.itemObj.Y || 0) + ',' + (this.itemObj.Z || 0)
                 }
@@ -84,7 +84,7 @@ export default {
         //关联资产
         upDateTableMain(id) {
             let param = {
-                    ProjId: this.projectId,
+                    ProjId: this.currentProjectId,
                     UserId: this.userId
                 },
                 paramList = {}

+ 9 - 4
src/views/data_admin/buildAssets/index.vue

@@ -55,7 +55,7 @@ export default {
         }
     },
     computed: {
-        ...mapGetters('peojMess', ['projectId', 'userId', 'secret'])
+        ...mapGetters('layout', ['currentProjectId', 'userId', 'secret'])
     },
     components: {
         SagaNofind,
@@ -68,7 +68,7 @@ export default {
         //获取建筑列表
         getBuilding() {
             let param = {
-                ProjId: this.projectId,
+                ProjId: this.currentProjectId,
                 UserId: this.userId
             }
             getBuildSelect(param).then(res => {
@@ -82,9 +82,9 @@ export default {
         //获取所有楼层
         getFloors() {
             let param = {
-                ProjId: this.projectId,
+                ProjId: this.currentProjectId,
                 secret: this.secret,
-                id: this.projectId,
+                id: this.currentProjectId,
                 type: ['Fl']
             }
             getAllbusiness(param).then(res => {
@@ -127,6 +127,11 @@ export default {
     },
     created() {
         this.init()
+    },
+    watch: {
+        currentProjectId(){
+            this.init()
+        }
     }
 }
 </script>

+ 4 - 4
src/views/data_admin/buildGraphy/buildGraphy.vue

@@ -42,12 +42,12 @@ export default {
   data() {
     return {
       param: {
-        ProjId: this.projectId, //项目id
+        ProjId: this.currentProjectId, //项目id
         UserId: this.userId //用户id
       },
       pointParam: {
         //point请求参数
-        ProjId: this.projectId, //项目id
+        ProjId: this.currentProjectId, //项目id
         UserId: this.userId, //用户id
         fllorName: ""
       },
@@ -56,8 +56,8 @@ export default {
     };
   },
   computed: {
-        ...mapGetters("peojMess", [
-        "projectId",
+        ...mapGetters("layout", [
+        "currentProjectId",
         "userId",
         "secret"
     ])

+ 2 - 6
src/views/data_admin/buildGraphy/graphyCanvas.vue

@@ -126,14 +126,10 @@ export default {
     };
   },
   computed: {
-      ...mapGetters("peojMess", [
-          "projectId",
-          "secret",
-          "userId"
-      ])
+      ...mapGetters('layout', ['currentProjectId', 'secret', 'userId'])
   },
   created() {
-    this.param.ProjId = this.projectId
+    this.param.ProjId = this.currentProjectId
     this.param.secret = this.secret
     this.param.UserId = this.userId
    },

+ 3 - 7
src/views/data_admin/buildGraphy/graphyTabs.vue

@@ -43,7 +43,7 @@ getLocation 定位
       <div class="qrcode">
         <div class="qrcode-view">
           <img
-            :src="'/ScanBuilding/service/qrcode/point?projectId=' + projectId + '&pointId=' + pointDetails.PointId + '&FloorId=' + pointDetails.FloorId + '&width=200&height=200'"
+            :src="'/ScanBuilding/service/qrcode/point?projectId=' + currentProjectId + '&pointId=' + pointDetails.PointId + '&FloorId=' + pointDetails.FloorId + '&width=200&height=200'"
             alt="点位标签二维码"
           >
         </div>
@@ -203,11 +203,7 @@ getLocation 定位
             };
         },
         computed: {
-            ...mapGetters("peojMess", [
-                "projectId",
-                "userId",
-                "secret"
-            ])
+            ...mapGetters('layout', ['currentProjectId', 'secret', 'userId'])
         },
         methods: {
             //tabs被点击
@@ -296,7 +292,7 @@ getLocation 定位
             },
             getDetails(item) {
                 let params = {
-                    ProjId: this.projectId,
+                    ProjId: this.currentProjectId,
                     UserId: this.userId,
                     PointId: item.Id
                 };

+ 5 - 9
src/views/data_admin/buildGraphy/index.vue

@@ -47,12 +47,12 @@
         data() {
             return {
                 param: {
-                    ProjId: this.projectId, //项目id
+                    ProjId: this.currentProjectId, //项目id
                     UserId: this.userId //用户id
                 },
                 pointParam: {
                     //point请求参数
-                    ProjId: this.projectId, //项目id
+                    ProjId: this.currentProjectId, //项目id
                     UserId: this.userId, //用户id
                     fllorName: ""
                 },
@@ -68,11 +68,7 @@
             this.getList()
         },
         computed: {
-            ...mapGetters("peojMess", [
-                "projectId",
-                "userId",
-                "secret"
-            ])
+            ...mapGetters('layout', ['currentProjectId', 'secret', 'userId'])
         },
         methods: {
             //修改楼层
@@ -140,9 +136,9 @@
                 }
             },
             changeValue() {
-                this.$set(this.param, 'ProjId', this.projectId)
+                this.$set(this.param, 'ProjId', this.currentProjectId)
                 this.$set(this.param, 'UserId', this.userId)
-                this.$set(this.pointParam, 'ProjId', this.projectId)
+                this.$set(this.pointParam, 'ProjId', this.currentProjectId)
                 this.$set(this.pointParam, 'UserId', this.userId)
                 this.show = true
             },