Quellcode durchsuchen

Merge branch 'develop' of git.sagacloud.cn:web/wanda-bm-guide into develop

guoxiaohuan vor 4 Jahren
Ursprung
Commit
34279fda0d

+ 10 - 6
src/lib/items/SImageLegendItem.ts

@@ -85,11 +85,11 @@ export class SImageLegendItem extends SIconTextItem {
         if (data.Properties && data.Properties.Url) {
             this.img.url = data.Properties.Url;
         }
-        if (data.Properties && data.Properties.sWidth) {
-            this.sWidth = data.Properties.sWidth;
+        if (data.Properties && data.Properties.Size && data.Properties.Size.Width) {
+            this.sWidth = data.Properties.Size.Width;
         }
-        if (data.Properties && data.Properties.sHeight) {
-            this.sHeight = data.Properties.sHeight;
+        if (data.Properties && data.Properties.Size && data.Properties.Size.Height) {
+            this.sHeight = data.Properties.Size.Height;
         }
         if (data.Properties.ImgPos) {
             this.img.moveTo(data.Properties.ImgPos.X, data.Properties.ImgPos.Y);
@@ -125,10 +125,14 @@ export class SImageLegendItem extends SIconTextItem {
         this.data.Properties.Url = this.img.url;
         this.data.Properties.TextPos = { X: this.textItem.x, Y: this.textItem.y };
         this.data.Properties.ImgPos = { X: this.img.x, Y: this.img.y };
-        this.data.Properties.sWidth = this.sWidth;
-        this.data.Properties.sHeight = this.sHeight;
+        this.data.Properties.Size = {
+            Width: this.sWidth,
+            Height: this.sHeight
+        };
         this.data.Properties.font = this.font.size;
         this.data.Properties.color = this.color.value;
+        this.data.Properties.Font = this.font.size;
+        this.data.Properties.Coler = this.color.value;
         this.data.Properties.FrameColor = this.activeColor.value;
         this.data.Properties.IsActive = this.isActive;
         this.data.AnchorList = this.anchorList.map(t => {

+ 4 - 0
src/utils/format.js

@@ -3,6 +3,9 @@ const formatTime = (time) => {
     return time > 10 ? time : "0" + time
 }
 const formatter = (date) => {
+    return moment.unix(date / 1000).format("YYYY.MM.DD")
+}
+const formatterTime = (date) => {
     return moment.unix(date / 1000).format("YYYY.MM.DD hh:mm")
 }
 const number_format = (number, decimals, dec_point, thousands_sep) => {
@@ -39,5 +42,6 @@ const number_format = (number, decimals, dec_point, thousands_sep) => {
 module.exports = {
     formatTime,
     formatter,
+    formatterTime,
     number_format,
 }

+ 4 - 4
src/views/equipment/table/wbTable.vue

@@ -107,10 +107,10 @@
                     </template>
                 </el-table-column>
                 <el-table-column prop='reportdate' label='填报时间' width='140'>
-                    <template slot-scope='{row}'>{{row.reportdate?formatter(row.reportdate):'--'}}</template>
+                    <template slot-scope='{row}'>{{row.reportdate?formatterTime(row.reportdate):'--'}}</template>
                 </el-table-column>
                 <el-table-column prop='sjjssj' label='验收时间' width='140'>
-                    <template slot-scope='{row}'>{{row.sjjssj?formatter(row.sjjssj): '--'}}</template>
+                    <template slot-scope='{row}'>{{row.sjjssj?formatterTime(row.sjjssj): '--'}}</template>
                 </el-table-column>
                 <el-table-column prop='wonum' label='任务编号' show-overflow-tooltip resizable width='90'>
                     <template slot-scope='{row}'>
@@ -139,7 +139,7 @@ import { queryWbsms } from '@/api/equipmentList.js'
 import { mapGetters } from 'vuex'
 import { Select } from 'meri-design'
 import inputDialog from './inputDIalog'
-import { formatter, number_format } from '@/utils/format.js'
+import { formatterTime, number_format } from '@/utils/format.js'
 export default {
     components: { Select, inputDialog },
     data() {
@@ -152,7 +152,7 @@ export default {
             reportdate: '',
             ischange: '2',
             sbjc: '',
-            formatter,
+            formatterTime,
             number_format,
             changeOption: [
                 {

+ 4 - 4
src/views/equipment/table/wxTable.vue

@@ -107,10 +107,10 @@
                     </template>
                 </el-table-column>
                 <el-table-column prop='reportdate' label='填报时间' width='140'>
-                    <template slot-scope='{row}'>{{row.reportdate?formatter(row.reportdate): '--'}}</template>
+                    <template slot-scope='{row}'>{{row.reportdate?formatterTime(row.reportdate): '--'}}</template>
                 </el-table-column>
                 <el-table-column prop='sjjssj' label='验收时间' width='140'>
-                    <template slot-scope='{row}'>{{row.sjjssj?formatter(row.sjjssj): '--'}}</template>
+                    <template slot-scope='{row}'>{{row.sjjssj?formatterTime(row.sjjssj): '--'}}</template>
                 </el-table-column>
                 <el-table-column prop='wonum' label='工单编号' show-overflow-tooltip resizable width='80'>
                     <template slot-scope='{row}'>
@@ -139,7 +139,7 @@ import { queryWx } from '@/api/equipmentList.js'
 import { mapGetters } from 'vuex'
 import inputDialog from './inputDIalog'
 import { Select } from 'meri-design'
-import { formatter, number_format } from '@/utils/format.js'
+import { formatterTime, number_format } from '@/utils/format.js'
 export default {
     components: { Select, inputDialog },
     data() {
@@ -154,7 +154,7 @@ export default {
             sbjc: '',
             matters: '',
             wonum: '',
-            formatter,
+            formatterTime,
             number_format,
             imgUrl: [],
             changeOption: [

+ 1 - 1
src/views/equipment/table/zwTable.vue

@@ -275,7 +275,7 @@ export default {
                     smsxt: this.smsxt,
                     plazaId: this.$store.state.plazaId,
                     page: this.currentPage,
-                    diff: this.diff,
+                    difference: this.diff,
                     size: this.size
                 }
             }

+ 6 - 0
src/views/legendLibrary/addForm.vue

@@ -520,12 +520,18 @@ export default {
 
         //位置/设备
         treeConfirmDevice(id, info) {
+            console.log('%ctreeConfirmDevice=============','color:blue')
+            console.log(id, info)
+            console.log('%ctreeConfirmDevice=============','color:blue')
             let InfoSystem = [],
                 InfoSystems = [],
                 InfoLocal = []
             this.deviceList.forEach(i => {
                 i.children.length > 0 &&
                     i.children.forEach(j => {
+                          console.log('%this.deviceList.forEach=============','color:blue')
+                          console.log(id)
+                          console.log('%this.deviceList.forEach=============','color:blue')
                         if (id.includes(j.id)) {
                             InfoSystems.push(i)
                         }