智慧农业大数据平台
shuishen
2022-08-05 e63bdfe9d9bac1b5f0f672f9924acee3c6a06188
遥感
3 files modified
182 ■■■■ changed files
src/components/remote/index.vue 147 ●●●●● patch | view | raw | blame | history
src/components/selectTime/index.vue 25 ●●●●● patch | view | raw | blame | history
src/router/axios.js 10 ●●●●● patch | view | raw | blame | history
src/components/remote/index.vue
@@ -2,11 +2,21 @@
<template>
    <div style="height: 100%; width: 100%; position: relative;">
        <div v-show="SelectTimeFlag">
            <select-time ref="leftRoller" :leftOrRight="'left'" class="l-time"></select-time>
            <select-time
                ref="leftRoller"
                :leftOrRight="'left'"
                class="l-time"
                :selectList="leftRollerLayers"
            ></select-time>
        </div>
        <div v-show="SelectTimeFlag">
            <select-time ref="rightRoller" :leftOrRight="'right'" class="r-time"></select-time>
            <select-time
                ref="rightRoller"
                :leftOrRight="'right'"
                class="r-time"
                :selectList="rightRollerLayers"
            ></select-time>
        </div>
        <div class="location-box" v-show="!rollerCloseShow && !screenShow">
@@ -103,6 +113,11 @@
    data () {
        return {
            // 左边集合
            leftRollerLayers: [],
            // 右边集合
            rightRollerLayers: [],
            SelectTimeFlag: false,
            rollerCloseShow: false,
            screenShow: false,
@@ -110,8 +125,134 @@
        }
    },
    computed: {
    created () {
        this.leftRollerLayers = [{
            title: '2022年5月影像',
            url: 'http://arcgis.jxpskj.com:6080/arcgis/rest/services/nanchengdom/MapServer/WMTS',
            layer: 'nanchengdom',
            style: 'default',
            tileMatrixSetID: 'default028mm',
            format: 'image/png',
            tilingScheme: new global.DC.Namespace.Cesium.GeographicTilingScheme(),
            maximumLevel: 19,
            tileMatrixLabels: [
                '0',
                '1',
                '2',
                '3',
                '4',
                '5',
                '6',
                '7',
                '8',
                '9',
                '10',
                '11',
                '12',
                '13',
                '14',
                '15',
                '16',
                '17',
                '18',
                '19'
            ]
        }, {
            title: '2022年7月影像',
            url: 'http://arcgis.jxpskj.com:6080/arcgis/rest/services/nanchengdomjuly/MapServer/WMTS',
            layer: 'nanchengdomjuly',
            style: 'default',
            tileMatrixSetID: 'default028mm',
            format: 'image/png',
            tilingScheme: new global.DC.Namespace.Cesium.GeographicTilingScheme(),
            maximumLevel: 19,
            tileMatrixLabels: [
                '0',
                '1',
                '2',
                '3',
                '4',
                '5',
                '6',
                '7',
                '8',
                '9',
                '10',
                '11',
                '12',
                '13',
                '14',
                '15',
                '16',
                '17',
                '18',
                '19'
            ]
        }]
        this.rightRollerLayers = [{
            title: '2022年5月影像',
            url: 'http://arcgis.jxpskj.com:6080/arcgis/rest/services/nanchengdom/MapServer/WMTS',
            layer: 'nanchengdom',
            style: 'default',
            tileMatrixSetID: 'default028mm',
            format: 'image/png',
            tilingScheme: new global.DC.Namespace.Cesium.GeographicTilingScheme(),
            maximumLevel: 19,
            tileMatrixLabels: [
                '0',
                '1',
                '2',
                '3',
                '4',
                '5',
                '6',
                '7',
                '8',
                '9',
                '10',
                '11',
                '12',
                '13',
                '14',
                '15',
                '16',
                '17',
                '18',
                '19'
            ]
        }, {
            title: '2022年7月影像',
            url: 'http://arcgis.jxpskj.com:6080/arcgis/rest/services/nanchengdomjuly/MapServer/WMTS',
            layer: 'nanchengdomjuly',
            style: 'default',
            tileMatrixSetID: 'default028mm',
            format: 'image/png',
            tilingScheme: new global.DC.Namespace.Cesium.GeographicTilingScheme(),
            maximumLevel: 19,
            tileMatrixLabels: [
                '0',
                '1',
                '2',
                '3',
                '4',
                '5',
                '6',
                '7',
                '8',
                '9',
                '10',
                '11',
                '12',
                '13',
                '14',
                '15',
                '16',
                '17',
                '18',
                '19'
            ]
        }]
    },
    mounted () {
        if (global.viewer != null) {
src/components/selectTime/index.vue
@@ -29,32 +29,9 @@
export default {
    name: 'selectTime',
    props: ['leftOrRight', 'type'],
    props: ['leftOrRight', 'type', 'selectList'],
    data () {
        return {
            selectList: [{
                title: '2012-2M第一季度'
            }, {
                title: '2013-2M第一季度'
            }, {
                title: '2014-2M第一季度'
            }, {
                title: '2015-2M第一季度'
            }, {
                title: '2016-2M第一季度'
            }, {
                title: '2017-2M第一季度'
            }, {
                title: '2018-2M第一季度'
            }, {
                title: '2019-2M第一季度'
            }, {
                title: '2020-2M第一季度'
            }, {
                title: '2021-2M第一季度'
            }, {
                title: '2022-2M第一季度'
            }],
            listFlag: false,
            currentTitle: null,
            currentIndex: null
src/router/axios.js
@@ -1,3 +1,11 @@
/*
 * @Author: shuishen 1109946754@qq.com
 * @Date: 2022-07-29 15:19:13
 * @LastEditors: shuishen 1109946754@qq.com
 * @LastEditTime: 2022-08-05 10:38:40
 * @FilePath: \zhny-dsj\src\router\axios.js
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
/**
 * 全站http配置
 *
@@ -43,6 +51,8 @@
    (res) => {
        const code = res.data.code
        console.log(code, 555)
        if (code === -1) {
            sessionStorage.removeItem('token')
            router.push('/login')