Compare commits
6 Commits
3408ce0415
...
1c0c39ae8f
Author | SHA1 | Date | |
---|---|---|---|
1c0c39ae8f | |||
e638b99060 | |||
c38566e76b | |||
fff66a799d | |||
ea3c35afb8 | |||
593222567a |
@ -22,7 +22,7 @@
|
|||||||
</el-upload>
|
</el-upload>
|
||||||
|
|
||||||
<el-dialog :visible.sync="dialogVisible" title="预览" width="500" append-to-body>
|
<el-dialog :visible.sync="dialogVisible" title="预览" width="500" append-to-body>
|
||||||
<video controls autoplay :src="'/dev-api' + dialogImageUrl" style="display: block; max-width: 100%; margin: 0 auto; height: 400px"></video>
|
<video controls autoplay :src="dialogImageUrl" style="display: block; max-width: 100%; margin: 0 auto; height: 400px"></video>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
@ -70,7 +70,10 @@ import {
|
|||||||
|
|
||||||
//日历组建
|
//日历组建
|
||||||
import VCalendar from 'v-calendar';
|
import VCalendar from 'v-calendar';
|
||||||
|
import { fileUrl } from '@/utils/filesAssist';
|
||||||
|
if (fileUrl) {
|
||||||
|
Vue.prototype.$fileUrl = fileUrl;
|
||||||
|
}
|
||||||
// datav组件 ,会导致生成文件无法打开
|
// datav组件 ,会导致生成文件无法打开
|
||||||
Vue.use(loading);
|
Vue.use(loading);
|
||||||
Vue.use(borderBox13);
|
Vue.use(borderBox13);
|
||||||
|
13
src/utils/filesAssist.js
Normal file
13
src/utils/filesAssist.js
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
/**
|
||||||
|
* @param {String | null |undefined}}
|
||||||
|
* @return {String}
|
||||||
|
*/
|
||||||
|
|
||||||
|
export function fileUrl(url = '') {
|
||||||
|
console.log('_url', url);
|
||||||
|
let _url = url;
|
||||||
|
if (!_url.startsWith('http')) {
|
||||||
|
_url = window.location.origin + _url;
|
||||||
|
}
|
||||||
|
return _url;
|
||||||
|
}
|
@ -43,12 +43,12 @@
|
|||||||
<!-- 添加设备按钮 -->
|
<!-- 添加设备按钮 -->
|
||||||
<el-popover v-if="!isAdmin" placement="right-start" width="100" trigger="click" v-model="isShow2">
|
<el-popover v-if="!isAdmin" placement="right-start" width="100" trigger="click" v-model="isShow2">
|
||||||
<div v-for="item in product" :key="item.productId" class="product flex aic" @click="addDevice(item)">
|
<div v-for="item in product" :key="item.productId" class="product flex aic" @click="addDevice(item)">
|
||||||
<img :src="baseUrl + item.imgUrl" alt="" />{{ item.productName }}
|
<img :src="item.imgUrl" alt="" />{{ item.productName }}
|
||||||
</div>
|
</div>
|
||||||
<i class="btn el-icon-bangzhu" slot="reference"></i>
|
<i class="btn el-icon-bangzhu" slot="reference"></i>
|
||||||
</el-popover>
|
</el-popover>
|
||||||
</div>
|
</div>
|
||||||
<img class="followPoint" v-show="followPointShow" :src="baseUrl + deviceImgUrl" alt="" />
|
<img class="followPoint" v-show="followPointShow" :src="deviceImgUrl" alt="" />
|
||||||
<!-- 地图工具按钮 -->
|
<!-- 地图工具按钮 -->
|
||||||
<div class="tool">
|
<div class="tool">
|
||||||
<el-tooltip transition="el-zoom-in-center" class="item" effect="dark" content="尺子" placement="left">
|
<el-tooltip transition="el-zoom-in-center" class="item" effect="dark" content="尺子" placement="left">
|
||||||
@ -95,9 +95,7 @@
|
|||||||
<div class="label"><i class="el-icon-printer el_icon"></i>设备</div>
|
<div class="label"><i class="el-icon-printer el_icon"></i>设备</div>
|
||||||
<li class="control_item" v-for="(item, index) in deviceProduct" :key="index">
|
<li class="control_item" v-for="(item, index) in deviceProduct" :key="index">
|
||||||
<div class="icon">
|
<div class="icon">
|
||||||
<img :src="baseUrl + item.imgUrl" alt="" />{{
|
<img :src="item.imgUrl" alt="" />{{ item.productName.length > 7 ? `${item.productName.substring(0, 7)}...` : item.productName }}
|
||||||
item.productName.length > 7 ? `${item.productName.substring(0, 7)}...` : item.productName
|
|
||||||
}}
|
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<el-checkbox v-model="item.show" @change="show(item)"></el-checkbox>
|
<el-checkbox v-model="item.show" @change="show(item)"></el-checkbox>
|
||||||
@ -164,7 +162,6 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
baseUrl: process.env.VUE_APP_BASE_API,
|
|
||||||
drawer: false, //抽屉控制
|
drawer: false, //抽屉控制
|
||||||
drawer2: false, //抽屉控制
|
drawer2: false, //抽屉控制
|
||||||
drawer3: false,
|
drawer3: false,
|
||||||
@ -396,7 +393,7 @@ export default {
|
|||||||
this.marker = [];
|
this.marker = [];
|
||||||
var markerContent = document.createElement('div');
|
var markerContent = document.createElement('div');
|
||||||
var markerImg = document.createElement('img');
|
var markerImg = document.createElement('img');
|
||||||
markerImg.src = this.baseUrl + this.deviceImgUrl;
|
markerImg.src = this.deviceImgUrl;
|
||||||
markerImg.setAttribute('width', '20px');
|
markerImg.setAttribute('width', '20px');
|
||||||
markerImg.setAttribute('height', '20px');
|
markerImg.setAttribute('height', '20px');
|
||||||
markerContent.appendChild(markerImg);
|
markerContent.appendChild(markerImg);
|
||||||
@ -543,7 +540,7 @@ export default {
|
|||||||
item.children.forEach((device) => {
|
item.children.forEach((device) => {
|
||||||
let marker = new this.AMap.Marker({
|
let marker = new this.AMap.Marker({
|
||||||
icon: new this.AMap.Icon({
|
icon: new this.AMap.Icon({
|
||||||
image: this.baseUrl + device.imgUrl,
|
image: device.imgUrl,
|
||||||
imageSize: new this.AMap.Size(26, 26),
|
imageSize: new this.AMap.Size(26, 26),
|
||||||
}),
|
}),
|
||||||
position: [device.longitude, device.latitude],
|
position: [device.longitude, device.latitude],
|
||||||
@ -889,18 +886,10 @@ export default {
|
|||||||
opacity: 1;
|
opacity: 1;
|
||||||
-webkit-transform: scaleX(1);
|
-webkit-transform: scaleX(1);
|
||||||
transform: scaleX(1);
|
transform: scaleX(1);
|
||||||
-webkit-transition:
|
-webkit-transition: opacity 0.3s cubic-bezier(0.23, 1, 0.32, 1), -webkit-transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
|
||||||
opacity 0.3s cubic-bezier(0.23, 1, 0.32, 1),
|
transition: opacity 0.3s cubic-bezier(0.23, 1, 0.32, 1), -webkit-transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
|
||||||
-webkit-transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
|
transition: transform 0.3s cubic-bezier(0.23, 1, 0.32, 1), opacity 0.3s cubic-bezier(0.23, 1, 0.32, 1);
|
||||||
transition:
|
transition: transform 0.3s cubic-bezier(0.23, 1, 0.32, 1), opacity 0.3s cubic-bezier(0.23, 1, 0.32, 1),
|
||||||
opacity 0.3s cubic-bezier(0.23, 1, 0.32, 1),
|
|
||||||
-webkit-transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
|
|
||||||
transition:
|
|
||||||
transform 0.3s cubic-bezier(0.23, 1, 0.32, 1),
|
|
||||||
opacity 0.3s cubic-bezier(0.23, 1, 0.32, 1);
|
|
||||||
transition:
|
|
||||||
transform 0.3s cubic-bezier(0.23, 1, 0.32, 1),
|
|
||||||
opacity 0.3s cubic-bezier(0.23, 1, 0.32, 1),
|
|
||||||
-webkit-transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
|
-webkit-transform 0.3s cubic-bezier(0.23, 1, 0.32, 1);
|
||||||
-webkit-transform-origin: center right;
|
-webkit-transform-origin: center right;
|
||||||
transform-origin: center right;
|
transform-origin: center right;
|
||||||
|
@ -29,7 +29,7 @@
|
|||||||
@click="moveTo(item, 2)"
|
@click="moveTo(item, 2)"
|
||||||
>
|
>
|
||||||
<div>
|
<div>
|
||||||
<img class="height-20 width-20 margin-right-6" :src="baseUrl + item.imgUrl.split(',')[1]" alt="" />{{
|
<img class="height-20 width-20 margin-right-6" :src="item.imgUrl.split(',')[1]" alt="" />{{
|
||||||
item.deviceName.length > 10 ? `${item.deviceName.substring(0, 10)}...` : item.deviceName
|
item.deviceName.length > 10 ? `${item.deviceName.substring(0, 10)}...` : item.deviceName
|
||||||
}}
|
}}
|
||||||
</div>
|
</div>
|
||||||
@ -72,7 +72,6 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
baseUrl: process.env.VUE_APP_BASE_API,
|
|
||||||
activeIndex1: null,
|
activeIndex1: null,
|
||||||
activeName: 'area',
|
activeName: 'area',
|
||||||
total: 0,
|
total: 0,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user