Browse Source

adm:feat > 空间详情显示,台账详情接口

shaun-sheep 4 năm trước cách đây
mục cha
commit
a78da36267

+ 1 - 1
src/api/scan/request.js

@@ -1924,7 +1924,7 @@ export function linkSysEq(param, success) {
 
 //竖井的贯通,竖井一对多,此方法不会覆盖以前的记录
 export function linkShaft(param, success) {
-  let url = `${baseUrl}${dataCenter}/sh-through-sh/link-shaft`;
+  let url = `${baseUrl}${rel}/sh-through-sh/link-shaft`;
   http.postJson(url, param, success)
 }
 

+ 10 - 7
src/components/business_space/newGraphy/unRelateBSP.vue

@@ -12,11 +12,12 @@
       </el-col>
     </el-row>
     <div class="table-box">
-      <el-table :data="tableData" style="width: 100%" height="100%" v-loading="loading" :header-cell-style="headerStyle">
+      <el-table :data="tableData" style="width: 100%" height="100%" v-loading="loading"
+                :header-cell-style="headerStyle">
         <el-table-column :label="`${inSpaceType}名称`" show-overflow-tooltip min-width="100">
           <template slot-scope="scope">
             <div>
-              {{scope.row.localName||scope.row.name||''}}
+              {{ scope.row.localName || scope.row.name || '' }}
             </div>
           </template>
         </el-table-column>
@@ -29,9 +30,11 @@
         </el-table-column>
       </el-table>
       <!-- 分页 -->
-      <el-pagination class="fr" v-show="tableData && tableData.length" @size-change="handleSizeChange" @current-change="handleCurrentChange"
-        :current-page="page.pageNumber" :page-sizes="page.pageSizes" :page-size="page.pageSize" layout="total, sizes, prev, pager, next, jumper"
-        :total="page.total"></el-pagination>
+      <el-pagination class="fr" v-show="tableData && tableData.length" @size-change="handleSizeChange"
+                     @current-change="handleCurrentChange"
+                     :current-page="page.pageNumber" :page-sizes="page.pageSizes" :page-size="page.pageSize"
+                     layout="total, sizes, prev, pager, next, jumper"
+                     :total="page.total"></el-pagination>
     </div>
   </el-dialog>
 </template>
@@ -126,8 +129,6 @@ export default {
           t.floor.unshift({ id: 'all', localName: '全部' }, { id: 'isNull', localName: '未明确楼层' })
           return t;
         })
-        console.log(this.options);
-        console.log(8888888888);
         this.options.unshift({ id: 'all', localName: '全部' }, { id: 'isNull', localName: '未明确建筑' })
       })
     },
@@ -170,10 +171,12 @@ export default {
 #unRelateBSP {
   .filters {
     margin-bottom: 10px;
+
     /deep/ .el-input__inner {
       vertical-align: baseline;
     }
   }
+
   .table-box {
     height: 350px;
   }

+ 3 - 3
src/components/ledger/cenote/dialog/addCenoteDialog.vue

@@ -149,9 +149,9 @@ export default {
     savaRelation() {
       if (this.selections.length) {
         let params = {
-          ShaftId: this.params.ShaftID,
-          ShaftOtherIdList: this.selections.map(item => {
-            return item.ShaftID
+          shaftId: this.params.ShaftID,
+          shaftOtherIdList: this.selections.map(item => {
+            return item.id
           })
         }
         linkShaft(params, res => {

+ 12 - 10
src/components/ledger/cenote/dialog/addSystemDialog.vue

@@ -7,12 +7,12 @@
         <el-table-column :label="`${inSpaceType}名称`" show-overflow-tooltip min-width="100">
           <template slot-scope="scope">
             <div>
-              {{scope.row.SysLocalName||scope.row.SysName||''}}
+              {{scope.row.localName||scope.row.name ||''}}
             </div>
           </template>
         </el-table-column>
-        <el-table-column prop="SysLocalId" :label="`${inSpaceType}本地编码`" show-overflow-tooltip min-width="100"></el-table-column>
-        <el-table-column prop="CategoryNames.CategoryName" :label="`${inSpaceType}类`" show-overflow-tooltip min-width="100"></el-table-column>
+        <el-table-column prop="localId" :label="`${inSpaceType}本地编码`" show-overflow-tooltip min-width="100"></el-table-column>
+        <el-table-column prop="categoryNames.name" :label="`${inSpaceType}类`" show-overflow-tooltip min-width="100"></el-table-column>
         <el-table-column prop="action" label="操作" min-width="100">
           <template slot-scope="scope">
             <el-button size="mini" @click="toDetail(scope.$index, scope.row)" plain>查看详情</el-button>
@@ -79,16 +79,18 @@ export default {
     getTableData() {
       let params = {
         data: {
-          Cascade: [{ Name: 'categoryNames' }],
-          Orders: "createTime desc, SysID desc",
-          PageNumber: this.page.pageNumber,
-          PageSize: this.page.pageSize,
+          cascade: [{ name: 'categoryNames' }],
+          orders: "createTime desc, id desc",
+          pageNumber: this.page.pageNumber,
+          pageSize: this.page.pageSize,
         },
         shaftId: this.params.ShaftID
       }
       unshaftInSys(params, res => {
-        this.tableData = res.Content
-        this.page.total = res.Total
+        this.tableData = res.content
+        debugger
+
+        this.page.total = res.total
       })
     },
     //选中项修改
@@ -144,4 +146,4 @@ export default {
     }
   }
 }
-</style>
+</style>

+ 4 - 5
src/components/ledger/cenote/table/cenoteTable.vue

@@ -12,16 +12,16 @@
         <el-table-column :label="`${inSpaceType}名称`" show-overflow-tooltip min-width="100">
           <template slot-scope="scope">
             <div>
-              {{ scope.row.ShaftLocalName || scope.row.ShaftName || '' }}
+              {{ scope.row.localName || scope.row.name || '' }}
             </div>
           </template>
         </el-table-column>
-        <el-table-column prop="ShaftLocalID" :label="`${inSpaceType}本地编码`" show-overflow-tooltip
+        <el-table-column prop="localId" :label="`${inSpaceType}本地编码`" show-overflow-tooltip
                          min-width="100"></el-table-column>
         <el-table-column :label="`${inSpaceType}类型`" show-overflow-tooltip min-width="100">
           <template slot-scope="scope">
             <div>
-              {{ scope.row.StructureInfo.ShaftFuncType }}
+              {{ scope.row.structureInfo.shaftFuncType }}
             </div>
           </template>
         </el-table-column>
@@ -106,10 +106,9 @@ export default {
         ]
       }
       queryCenoteTableData(params, res => {
-        debugger
         this.tableData = res.content[0].shaftThroughList || []
         this.tableData.forEach(item => {
-          if (item.structureInfo && item.structureInfo.ShaftFuncType) {
+          if (item.structureInfo && item.structureInfo.shaftFuncType) {
             item.structureInfo.shaftFuncType = this.shaftType[item.structureInfo.shaftFuncType]
           }
         })

+ 81 - 81
src/views/ledger/spacelist/spaceDetail/index.vue

@@ -193,8 +193,8 @@ export default {
         pageSize: 1000,
         type: this.params.zone
       }, params2 = {
-        Filters: `id='${this.params.RoomID}'`,
-        ZoneType: this.params.zone
+        filters: `id='${this.params.RoomID}'`,
+        zoneType: this.params.zone
       };
       let promise1 = new Promise((resolve, reject) => {
         getDataDictionary(params1, res => {
@@ -212,8 +212,8 @@ export default {
 
       Promise.all([promise1, promise2]).then(values => {
         this.pointData = values[0].content;
-        this.exampleData = values[1].Content[0];
-        let obj = values[1].Content[0] ? this.deepCopy(values[1].Content[0]) : values[1].Content[0];
+        this.exampleData = values[1].content[0];
+        let obj = values[1].content[0] ? this.deepCopy(values[1].content[0]) : values[1].content[0];
 
         obj = tools.flattenKeys(obj);
         for (let key in obj) {
@@ -227,7 +227,7 @@ export default {
             let cur = tools.dataForKey(this.exampleData, item.path);
             if (cur) {
               this.criterias.push({
-                id: this.exampleData.RoomID,
+                id: this.exampleData.id,
                 code: item.code
               })
             }
@@ -318,25 +318,24 @@ export default {
     },
     handlePicList(arr) {
       let picObject = {}
-      debugger
       //处理数据格式
       arr.map(i => {
-        if (i.InputMode == 'F2') {
+        if (i.inputMode == 'F2') {
           switch (i.Path) {
-            case 'LedgerParam.PhotoDoc.Drawing':
-            case 'LedgerParam.Siteinstall.InstallPic':
-            case 'LedgerParam.Siteinstall.InstallDrawing':
-            case 'LedgerParam.PhotoDoc.Nameplate':
-            case 'LedgerParam.PhotoDoc.Pic':
-            case 'Pic' :
-              if (this.instance && this.instance.hasOwnProperty(i.Path)) {
-                i.PicList = this.instance[i.Path]
+            case 'infos.drawing':
+            case 'infos.installPic':
+            case 'infos.installDrawing':
+            case 'infos.nameplate':
+            case 'infos.pic':
+            case 'pic' :
+              if (this.instance && this.instance.hasOwnProperty(i.path)) {
+                i.PicList = this.instance[i.path]
               }
-              if (picObject[i.InfoPointName]) {
+              if (picObject[i.name]) {
               } else {
-                picObject[i.InfoPointName] = []
+                picObject[i.name] = []
               }
-              picObject[i.InfoPointName].push({
+              picObject[i.name].push({
                 ...i,
               })
               break;
@@ -371,21 +370,21 @@ export default {
       let picObject = {}
       //处理数据格式
       arr.map(i => {
-        if (i.InputMode == 'F2') {
-          switch (i.Path) {
-            case 'LedgerParam.InsuranceDoc.InsuranceFile':
-            case 'LedgerParam.PhotoDoc.Archive':
-            case 'LedgerParam.Siteinstall.CheckReport':
-              if (this.instance && this.instance.hasOwnProperty(i.Path)) {
-                i.fileList = this.instance[i.Path]
+        if (i.inputMode == 'F2') {
+          switch (i.path) {
+            case 'infos.insuranceFile':
+            case 'infos.archive':
+            case 'infos.checkReport':
+              if (this.instance && this.instance.hasOwnProperty(i.path)) {
+                i.fileList = this.instance[i.path]
               }
-              if (picObject[i.InfoPointName]) {
+              if (picObject[i.name]) {
 
               } else {
-                picObject[i.InfoPointName] = []
+                picObject[i.name] = []
               }
 
-              picObject[i.InfoPointName].push({
+              picObject[i.name].push({
                 ...i,
               })
               break
@@ -428,99 +427,100 @@ export default {
       const result = {}
       const resultEnergy = {};
       arr.forEach(i => {
-        if (this.instance && this.instance.hasOwnProperty(i.Path) && this.currentRadio != 2) {
-          i.value = this.instance[i.Path]
+        if (this.instance && this.instance.hasOwnProperty(i.path) && this.currentRadio != 2) {
+          i.value = this.instance[i.path]
         }
-        if (i.InputMode == 'C5') {
-          if (this.instance && this.instance.hasOwnProperty(i.Path)) {
-            let time = this.instance[i.Path]
+        if (i.inputMode == 'C5') {
+          if (this.instance && this.instance.hasOwnProperty(i.path)) {
+            let time = this.instance[i.path]
             i.value = this.formatDate(time)
           }
         }
-        if (i.DataSource && i.DataSource.length) {
-          let source = JSON.parse(i.DataSource)
+        if (i.dataSource && i.dataSource.length) {
+          // let source = JSON.parse(i.DataSource)
+          let source = i.dataSource
           //判断输入类型
-          if (i.InputMode == 'D1L') {
-            let d1l = tools.formatDataSource(i.DataSource)
+          if (i.inputMode == 'D1L') {
+            let d1l = tools.formatDataSource(i.dataSource)
             d1l.forEach(k => {
-              if (k.Code == this.instance[i.Path]) {
-                i.value = k.Name
+              if (k.code == this.instance[i.path]) {
+                i.value = k.name
               }
             })
-          } else if (i.InputMode == 'D2' || i.InputMode == 'C6') {
-            if (this.instance && this.instance.hasOwnProperty(i.Path)) {
-              if (!Array.isArray(this.instance[i.Path])) {
-                let transArray = this.instance[i.Path].split(',')
-                i.value = source.filter(item => transArray.includes(item.Code)).map(item => item.Name).join(',')
+          } else if (i.inputMode == 'D2' || i.inputMode == 'C6') {
+            if (this.instance && this.instance.hasOwnProperty(i.path)) {
+              if (!Array.isArray(this.instance[i.path])) {
+                let transArray = this.instance[i.path].split(',')
+                i.value = source.filter(item => transArray.includes(item.code)).map(item => item.name).join(',')
               }
             }
           }
           source.forEach(j => {
-            if (this.instance && j.Code == this.instance[i.Path]) {
-              i.value = j.Name
+            if (this.instance && j.code == this.instance[i.path]) {
+              i.value = j.name
             }
           })
         }
-        switch (i.InputMode) {
+        switch (i.inputMode) {
           case "L":
           case "L1":
           case "L2":
           case "M":
-            if (resultEnergy[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`]) {
-              resultEnergy[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`].paths.push({
-                Path: i.Path,
-                InfoPointName: i.InfoPointName,
-                InfoPointCode: i.InfoPointCode,
+            if (resultEnergy[`${i.firstName}${i.secondName ? '/' + i.secondName : ''}`]) {
+              resultEnergy[`${i.firstName}${i.secondName ? '/' + i.secondName : ''}`].paths.push({
+                Path: i.path,
+                InfoPointName: i.name,
+                InfoPointCode: i.code,
                 value: i.svalue,
-                Visible: i.Visible,
-                KeyWord: i.KeyWord,
-                InputMode: i.InputMode,
+                Visible: i.visible,
+                KeyWord: i.keyWord,
+                InputMode: i.inputMode,
                 data: i.data,
                 receivetime: i.receivetime,
                 error: i.error,
-                Unit: i.Unit,
-                FirstName: i.FirstName,
+                Unit: i.unit,
+                FirstName: i.firstName,
               })
             } else {
-              resultEnergy[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`] = {
+              resultEnergy[`${i.firstName}${i.secondName ? '/' + i.secondName : ''}`] = {
                 paths: [{
-                  Path: i.Path,
-                  InfoPointName: i.InfoPointName,
-                  InfoPointCode: i.InfoPointCode,
+                  Path: i.path,
+                  InfoPointName: i.name,
+                  InfoPointCode: i.code,
                   value: i.svalue,
-                  Visible: i.Visible,
-                  KeyWord: i.KeyWord,
-                  InputMode: i.InputMode,
+                  Visible: i.visible,
+                  KeyWord: i.keyWord,
+                  InputMode: i.inputMode,
                   data: i.data,
                   receivetime: i.receivetime,
                   error: i.error,
-                  Unit: i.Unit,
-                  FirstName: i.FirstName,
+                  Unit: i.unit,
+                  FirstName: i.firstName,
                 }]
               }
             }
             break;
           default:
-            if (result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`]) {
-              result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`].paths.push({
-                Path: i.Path,
-                InfoPointName: i.InfoPointName,
-                InfoPointCode: i.InfoPointCode,
+            if (result[`${i.firstName}${i.secondName ? '/' + i.secondName : ''}`]) {
+              result[`${i.firstName}${i.secondName ? '/' + i.secondName : ''}`].paths.push({
+                Path: i.path,
+                InfoPointName: i.name,
+                InfoPointCode: i.code,
                 Value: i.value,
-                Visible: i.Visible,
-                KeyWord: i.KeyWord,
-                InputMode: i.InputMode
+                Visible: i.visible,
+                KeyWord: i.keyWord,
+                InputMode: i.inputMode,
               })
             } else {
-              result[`${i.FirstName}${i.SecondName ? '/' + i.SecondName : ''}`] = {
+              result[`${i.firstName}${i.secondName ? '/' + i.secondName : ''}`] = {
                 paths: [{
-                  Path: i.Path,
-                  InfoPointName: i.InfoPointName,
-                  InfoPointCode: i.InfoPointCode,
+                  Path: i.path,
+                  InfoPointName: i.name,
+                  InfoPointCode: i.code,
                   Value: i.value,
-                  Visible: i.Visible,
-                  KeyWord: i.KeyWord,
-                  InputMode: i.InputMode
+                  Visible: i.visible,
+                  KeyWord: i.keyWord,
+                  InputMode: i.inputMode,
                 }]
               }
             }