Commit 27e47122 by 付振洋

Merge branch 'feat/updata' into 'dataEase源码(勿删)'

# Conflicts:
#   src/components/canvas/customComponent/UserView.vue
#   src/lang/en.js
#   src/lang/tw.js
#   src/lang/zh.js
#   src/views/chart/group/Group.vue
#   src/views/chart/view/ChartEdit.vue
parents 74bb62a4 3cb8a57b
...@@ -3,7 +3,8 @@ ENV = 'development' ...@@ -3,7 +3,8 @@ ENV = 'development'
EDITOR=code EDITOR=code
# base api # base api
# VUE_APP_BASE_API = '/dev-api' # VUE_APP_BASE_API = '/dev-api'
VUE_APP_BASE_API = 'http://192.168.1.100:8081/' VUE_APP_BASE_API = 'http://222.212.91.59:6191/'
VUE_APP_BASE = 'http://222.212.91.59:6192'
# vue-cli uses the VUE_CLI_BABEL_TRANSPILE_MODULES environment variable, # vue-cli uses the VUE_CLI_BABEL_TRANSPILE_MODULES environment variable,
# to control whether the babel-plugin-dynamic-import-node plugin is enabled. # to control whether the babel-plugin-dynamic-import-node plugin is enabled.
# It only does one thing by converting all import() to require(). # It only does one thing by converting all import() to require().
......
...@@ -3,5 +3,6 @@ ENV = 'production' ...@@ -3,5 +3,6 @@ ENV = 'production'
# base api # base api
# VUE_APP_BASE_API = 'http://localhost:8081/' # VUE_APP_BASE_API = 'http://localhost:8081/'
VUE_APP_BASE_API = '/' VUE_APP_BASE_API = 'http://222.212.91.59:6191/'
VUE_APP_BASE = 'http://222.212.91.59:6192'
...@@ -7,19 +7,19 @@ module.exports = { ...@@ -7,19 +7,19 @@ module.exports = {
env: { env: {
browser: true, browser: true,
node: true, node: true,
es6: true, es6: true
}, },
extends: ['plugin:vue/recommended', 'eslint:recommended'], extends: ['plugin:vue/recommended', 'eslint:recommended'],
// add your custom rules here // add your custom rules here
//it is base on https://github.com/vuejs/eslint-config-vue // it is base on https://github.com/vuejs/eslint-config-vue
rules: { rules: {
"vue/singleline-html-element-content-newline": "off", 'vue/singleline-html-element-content-newline': 'off',
"vue/multiline-html-element-content-newline": "off", 'vue/multiline-html-element-content-newline': 'off',
"vue/no-mutating-props": "off", 'vue/no-mutating-props': 'off',
"vue/multi-word-component-names": "off", 'vue/multi-word-component-names': 'off',
"vue/require-default-prop": "off", 'vue/require-default-prop': 'off',
"vue/no-v-html": "off", 'vue/no-v-html': 'off',
'accessor-pairs': 2, 'accessor-pairs': 2,
'arrow-spacing': [2, { 'arrow-spacing': [2, {
'before': true, 'before': true,
...@@ -42,8 +42,8 @@ module.exports = { ...@@ -42,8 +42,8 @@ module.exports = {
'curly': [2, 'multi-line'], 'curly': [2, 'multi-line'],
'dot-location': [2, 'property'], 'dot-location': [2, 'property'],
'eol-last': 2, 'eol-last': 2,
'eqeqeq': ["error", "always", { 'eqeqeq': ['error', 'always', {
"null": "ignore" 'null': 'ignore'
}], }],
'generator-star-spacing': [2, { 'generator-star-spacing': [2, {
'before': true, 'before': true,
...@@ -191,8 +191,8 @@ module.exports = { ...@@ -191,8 +191,8 @@ module.exports = {
objectsInObjects: false objectsInObjects: false
}], }],
'array-bracket-spacing': [2, 'never'], 'array-bracket-spacing': [2, 'never'],
"vue/no-use-v-if-with-v-for": ["error", { 'vue/no-use-v-if-with-v-for': ['error', {
"allowUsingIterationVar": true 'allowUsingIterationVar': true
}] }]
} }
} }
.DS_Store .DS_Store
node_modules/ node_modules/
dist/ dist/
dist.zip
npm-debug.log* npm-debug.log*
yarn-debug.log* yarn-debug.log*
yarn-error.log* yarn-error.log*
...@@ -14,3 +15,4 @@ tests/**/coverage/ ...@@ -14,3 +15,4 @@ tests/**/coverage/
*.ntvs* *.ntvs*
*.njsproj *.njsproj
*.sln *.sln
yarn.lock
...@@ -34,6 +34,7 @@ ...@@ -34,6 +34,7 @@
"@antv/l7-renderer": "2.15.0", "@antv/l7-renderer": "2.15.0",
"@antv/l7-scene": "2.15.0", "@antv/l7-scene": "2.15.0",
"@antv/l7-source": "2.15.0", "@antv/l7-source": "2.15.0",
"@antv/l7-three": "2.15.0",
"@antv/l7-utils": "2.15.0", "@antv/l7-utils": "2.15.0",
"@antv/s2": "1.49.1", "@antv/s2": "1.49.1",
"@antv/util": "^2.0.17", "@antv/util": "^2.0.17",
...@@ -65,14 +66,17 @@ ...@@ -65,14 +66,17 @@
"lodash.isstring": "^4.0.1", "lodash.isstring": "^4.0.1",
"normalize.css": "7.0.0", "normalize.css": "7.0.0",
"nprogress": "0.2.0", "nprogress": "0.2.0",
"popmotion": "^11.0.5",
"screenfull": "4.2.0", "screenfull": "4.2.0",
"sockjs-client": "^1.6.0", "sockjs-client": "^1.6.0",
"stompjs": "^2.3.3", "stompjs": "^2.3.3",
"svg-sprite-loader": "4.1.3", "svg-sprite-loader": "4.1.3",
"svgo": "1.2.2", "svgo": "1.2.2",
"three": "^0.115.0",
"tinymce": "^5.8.2", "tinymce": "^5.8.2",
"umy-ui": "^1.1.6", "umy-ui": "^1.1.6",
"vue": "2.6.10", "vue": "2.6.10",
"vue-amap": "^0.5.10",
"vue-clipboard2": "0.3.1", "vue-clipboard2": "0.3.1",
"vue-codemirror": "^4.0.6", "vue-codemirror": "^4.0.6",
"vue-friendly-iframe": "^0.20.0", "vue-friendly-iframe": "^0.20.0",
......
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<artifactId>dataease-server</artifactId>
<groupId>io.dataease</groupId>
<version>${dataease.version}</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>frontend</artifactId>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
<frontend-maven-plugin.version>1.9.1</frontend-maven-plugin.version>
</properties>
<build>
<plugins>
<plugin>
<groupId>com.github.eirslett</groupId>
<artifactId>frontend-maven-plugin</artifactId>
<version>${frontend-maven-plugin.version}</version>
<executions>
<execution>
<id>install node and npm</id>
<goals>
<goal>install-node-and-npm</goal>
</goals>
<configuration>
<!-- See https://nodejs.org/en/download/ for latest node and npm (lts) versions -->
<nodeVersion>v16.20.2</nodeVersion>
<npmVersion>7.6.3</npmVersion>
</configuration>
</execution>
<execution>
<id>npm install</id>
<goals>
<goal>npm</goal>
</goals>
<!-- Optional configuration which provides for running any npm command -->
<configuration>
<arguments>install</arguments>
</configuration>
</execution>
<execution>
<id>npm run build</id>
<goals>
<goal>npm</goal>
</goals>
<configuration>
<arguments>run build</arguments>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
No preview for this file type
...@@ -13,7 +13,7 @@ ...@@ -13,7 +13,7 @@
:title="$t('user.change_password')" :title="$t('user.change_password')"
:show-close="false" :show-close="false"
> >
<PasswordUpdateForm oldPwd="dataease" /> <PasswordUpdateForm old-pwd="dataease" />
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
...@@ -28,7 +28,7 @@ export default { ...@@ -28,7 +28,7 @@ export default {
components: { PluginCom, PasswordUpdateForm }, components: { PluginCom, PasswordUpdateForm },
computed: { computed: {
...mapState('user', [ ...mapState('user', [
'passwordModified', 'passwordModified'
]) ])
}, },
data() { data() {
...@@ -36,12 +36,6 @@ export default { ...@@ -36,12 +36,6 @@ export default {
showPasswordModifiedDialog: false showPasswordModifiedDialog: false
} }
}, },
mounted() {
const passwordModified = JSON.parse(localStorage.getItem('passwordModified'))
if (typeof passwordModified === 'boolean') {
this.$store.commit('user/SET_PASSWORD_MODIFIED', passwordModified)
}
},
watch: { watch: {
passwordModified: { passwordModified: {
handler(val) { handler(val) {
...@@ -49,6 +43,12 @@ export default { ...@@ -49,6 +43,12 @@ export default {
}, },
immediate: true immediate: true
} }
},
mounted() {
const passwordModified = JSON.parse(localStorage.getItem('passwordModified'))
if (typeof passwordModified === 'boolean') {
this.$store.commit('user/SET_PASSWORD_MODIFIED', passwordModified)
}
} }
} }
</script> </script>
...@@ -153,7 +153,6 @@ export const viewOptions = panelId => { ...@@ -153,7 +153,6 @@ export const viewOptions = panelId => {
}) })
} }
export function getDatasourceRelationship(id) { export function getDatasourceRelationship(id) {
return request({ return request({
url: `/api/relation/datasource/${id}`, url: `/api/relation/datasource/${id}`,
...@@ -162,7 +161,6 @@ export function getDatasourceRelationship(id) { ...@@ -162,7 +161,6 @@ export function getDatasourceRelationship(id) {
}) })
} }
export function getDatasetRelationship(id) { export function getDatasetRelationship(id) {
return request({ return request({
url: `/api/relation/dataset/${id}`, url: `/api/relation/dataset/${id}`,
...@@ -171,7 +169,6 @@ export function getDatasetRelationship(id) { ...@@ -171,7 +169,6 @@ export function getDatasetRelationship(id) {
}) })
} }
export function getPanelRelationship(id) { export function getPanelRelationship(id) {
return request({ return request({
url: `/api/relation/panel/${id}`, url: `/api/relation/panel/${id}`,
......
...@@ -138,7 +138,7 @@ export function fieldList(id, showLoading = true) { ...@@ -138,7 +138,7 @@ export function fieldList(id, showLoading = true) {
} }
export function fieldListWithPermission(id, showLoading = true) { export function fieldListWithPermission(id, showLoading = true) {
//初始模板中的过滤组件无需走后台 // 初始模板中的过滤组件无需走后台
if (id.indexOf('no_auth') > -1) { if (id.indexOf('no_auth') > -1) {
return new Promise(function(resolve) { return new Promise(function(resolve) {
resolve({ resolve({
......
...@@ -66,9 +66,9 @@ export function loadGenerate(resourceId) { ...@@ -66,9 +66,9 @@ export function loadGenerate(resourceId) {
}) })
} }
export function loadResource(resourceId,userId) { export function loadResource(resourceId, userId) {
return request({ return request({
url: 'api/link/resourceDetail/' + resourceId+'/'+ userId, url: 'api/link/resourceDetail/' + resourceId + '/' + userId,
method: 'get' method: 'get'
}) })
} }
......
...@@ -192,7 +192,7 @@ export function initPanelData(panelId, useCache = false, callback) { ...@@ -192,7 +192,7 @@ export function initPanelData(panelId, useCache = false, callback) {
watermarkOpen: response.data.watermarkOpen, watermarkOpen: response.data.watermarkOpen,
watermarkInfo: watermarkInfo watermarkInfo: watermarkInfo
}) })
const targetPanelId = response.data.panelType==='system'?response.data.source:panelId const targetPanelId = response.data.panelType === 'system' ? response.data.source : panelId
// 刷新联动信息 // 刷新联动信息
getPanelAllLinkageInfo(targetPanelId).then(rsp => { getPanelAllLinkageInfo(targetPanelId).then(rsp => {
store.commit('setNowPanelTrackInfo', rsp.data) store.commit('setNowPanelTrackInfo', rsp.data)
......

272 KB | W: | H:

251 KB | W: | H:

src/assets/login-desc.png
src/assets/login-desc.png
src/assets/login-desc.png
src/assets/login-desc.png
  • 2-up
  • Swipe
  • Onion skin
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
> >
<el-tooltip :content="item.tooltip"> <el-tooltip :content="item.tooltip">
<span style="float: left;"> <span style="float: left;">
<i :class="item.icon"/> <i :class="item.icon" />
</span> </span>
</el-tooltip> </el-tooltip>
</el-radio-button> </el-radio-button>
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
:value="item.value" :value="item.value"
> >
<span style="float: left;"> <span style="float: left;">
<i :class="item.icon"/> <i :class="item.icon" />
</span> </span>
<span style="float: right; color: #8492a6; font-size: 12px">{{ item.label }}</span> <span style="float: right; color: #8492a6; font-size: 12px">{{ item.label }}</span>
</el-option> </el-option>
...@@ -257,7 +257,7 @@ ...@@ -257,7 +257,7 @@
@click="goColor" @click="goColor"
/> />
</el-tooltip> </el-tooltip>
<div :style="letterDivColor"/> <div :style="letterDivColor" />
<el-color-picker <el-color-picker
ref="colorPicker" ref="colorPicker"
v-model="styleInfo.color" v-model="styleInfo.color"
...@@ -279,7 +279,7 @@ ...@@ -279,7 +279,7 @@
@click="goBoardColor" @click="goBoardColor"
/> />
</el-tooltip> </el-tooltip>
<div :style="boardDivColor"/> <div :style="boardDivColor" />
<el-color-picker <el-color-picker
ref="boardColorPicker" ref="boardColorPicker"
v-model="styleInfo.borderColor" v-model="styleInfo.borderColor"
...@@ -302,7 +302,7 @@ ...@@ -302,7 +302,7 @@
@click="goBackgroundColor" @click="goBackgroundColor"
/> />
</el-tooltip> </el-tooltip>
<div :style="backgroundDivColor"/> <div :style="backgroundDivColor" />
<el-color-picker <el-color-picker
ref="backgroundColorPicker" ref="backgroundColorPicker"
v-model="styleInfo.backgroundColor" v-model="styleInfo.backgroundColor"
...@@ -318,7 +318,7 @@ ...@@ -318,7 +318,7 @@
style="width: 20px;float: left;margin-top: 2px;margin-left: 2px;" style="width: 20px;float: left;margin-top: 2px;margin-left: 2px;"
> >
<el-tooltip :content="$t('panel.video_info')"> <el-tooltip :content="$t('panel.video_info')">
<VideoLinks :link-info="curComponent.videoLinks"/> <VideoLinks :link-info="curComponent.videoLinks" />
</el-tooltip> </el-tooltip>
</div> </div>
...@@ -327,7 +327,7 @@ ...@@ -327,7 +327,7 @@
style="width: 20px;float: left;margin-top: 2px;margin-left: 2px;" style="width: 20px;float: left;margin-top: 2px;margin-left: 2px;"
> >
<el-tooltip :content="$t('panel.stream_media_info')"> <el-tooltip :content="$t('panel.stream_media_info')">
<StreamMediaLinks :link-info="curComponent.streamMediaLinks"/> <StreamMediaLinks :link-info="curComponent.streamMediaLinks" />
</el-tooltip> </el-tooltip>
</div> </div>
...@@ -336,7 +336,7 @@ ...@@ -336,7 +336,7 @@
style="width: 20px;float: left;margin-top: 2px;margin-left: 2px;" style="width: 20px;float: left;margin-top: 2px;margin-left: 2px;"
> >
<el-tooltip :content="$t('panel.web_addr')"> <el-tooltip :content="$t('panel.web_addr')">
<FrameLinks :link-info="curComponent.frameLinks"/> <FrameLinks :link-info="curComponent.frameLinks" />
</el-tooltip> </el-tooltip>
</div> </div>
<div <div
...@@ -356,7 +356,7 @@ ...@@ -356,7 +356,7 @@
style="width: 20px;float: left;margin-top: 2px;margin-left: 10px;" style="width: 20px;float: left;margin-top: 2px;margin-left: 10px;"
> >
<el-tooltip :content="$t('panel.tab_inner_style')"> <el-tooltip :content="$t('panel.tab_inner_style')">
<tab-style :style-info="styleInfo"/> <tab-style :style-info="styleInfo" />
</el-tooltip> </el-tooltip>
</div> </div>
......
...@@ -76,19 +76,19 @@ ...@@ -76,19 +76,19 @@
</template> </template>
<script> <script>
import {getStyle} from '@/components/canvas/utils/style' import { getStyle } from '@/components/canvas/utils/style'
import runAnimation from '@/components/canvas/utils/runAnimation' import runAnimation from '@/components/canvas/utils/runAnimation'
import {mixins} from '@/components/canvas/utils/events' import { mixins } from '@/components/canvas/utils/events'
import {mapState} from 'vuex' import { mapState } from 'vuex'
import DeOutWidget from '@/components/dataease/DeOutWidget' import DeOutWidget from '@/components/dataease/DeOutWidget'
import EditBar from '@/components/canvas/components/editor/EditBar' import EditBar from '@/components/canvas/components/editor/EditBar'
import MobileCheckBar from '@/components/canvas/components/editor/MobileCheckBar' import MobileCheckBar from '@/components/canvas/components/editor/MobileCheckBar'
import CloseBar from '@/components/canvas/components/editor/CloseBar' import CloseBar from '@/components/canvas/components/editor/CloseBar'
import {hexColorToRGBA} from '@/views/chart/chart/util' import { hexColorToRGBA } from '@/views/chart/chart/util'
import {imgUrlTrans} from '@/components/canvas/utils/utils' import { imgUrlTrans } from '@/components/canvas/utils/utils'
export default { export default {
components: {CloseBar, MobileCheckBar, DeOutWidget, EditBar}, components: { CloseBar, MobileCheckBar, DeOutWidget, EditBar },
mixins: [mixins], mixins: [mixins],
props: { props: {
canvasId: { canvasId: {
...@@ -135,7 +135,7 @@ export default { ...@@ -135,7 +135,7 @@ export default {
canvasStyleData: { canvasStyleData: {
type: Object, type: Object,
required: false, required: false,
default: function () { default: function() {
return {} return {}
} }
}, },
...@@ -163,7 +163,7 @@ export default { ...@@ -163,7 +163,7 @@ export default {
}, },
chart() { chart() {
if (this.config.propValue?.viewId) { if (this.config.propValue?.viewId) {
const viewInfo = this.panelViewDetailsInfo[this.config.propValue.viewId]; const viewInfo = this.panelViewDetailsInfo[this.config.propValue.viewId]
return viewInfo ? JSON.parse(viewInfo) : null return viewInfo ? JSON.parse(viewInfo) : null
} }
return null return null
...@@ -324,7 +324,7 @@ export default { ...@@ -324,7 +324,7 @@ export default {
e.stopPropagation() e.stopPropagation()
const _this = this const _this = this
setTimeout(() => { setTimeout(() => {
_this.$store.commit('setCurComponent', {component: _this.config, index: _this.index}) _this.$store.commit('setCurComponent', { component: _this.config, index: _this.index })
}, 200) }, 200)
}, },
showViewDetails(params) { showViewDetails(params) {
......
...@@ -126,7 +126,7 @@ ...@@ -126,7 +126,7 @@
:canvas-id="canvasId" :canvas-id="canvasId"
/> />
<!-- 右击菜单 --> <!-- 右击菜单 -->
<ContextMenu/> <ContextMenu />
<!-- 对齐标线 --> <!-- 对齐标线 -->
<span <span
...@@ -1144,7 +1144,7 @@ export default { ...@@ -1144,7 +1144,7 @@ export default {
return this.$refs['wrapperChild'] return this.$refs['wrapperChild']
}, },
getAllWrapperChildRefs() { getAllWrapperChildRefs() {
let allChildRefs = [] const allChildRefs = []
const currentChildRefs = this.getWrapperChildRefs() const currentChildRefs = this.getWrapperChildRefs()
if (currentChildRefs && currentChildRefs.length > 0) { if (currentChildRefs && currentChildRefs.length > 0) {
allChildRefs.push.apply(allChildRefs, currentChildRefs) allChildRefs.push.apply(allChildRefs, currentChildRefs)
......
<template> <template>
<div @mousedown="fieldsAreaDown" class="field-main"> <div
class="field-main"
@mousedown="fieldsAreaDown"
>
<el-button <el-button
v-for="(field) in fields" v-for="(field) in fields"
:key="field.id" :key="field.id"
......
...@@ -66,8 +66,8 @@ export default { ...@@ -66,8 +66,8 @@ export default {
} }
}, },
onSubmit() { onSubmit() {
this.curComponent.style.carouselEnable = this.carouselEnable this.curComponent.style.carouselEnable = this.carouselEnable
this.curComponent.style.switchTime = this.switchTime this.curComponent.style.switchTime = this.switchTime
this.$store.commit('canvasChange') this.$store.commit('canvasChange')
this.onClose() this.onClose()
}, },
......
<template> <template>
<div> <div>
<el-dropdown <el-dropdown
trigger="click"> trigger="click"
>
<input <input
id="input" id="input"
ref="trackButton" ref="trackButton"
......
...@@ -45,7 +45,7 @@ ...@@ -45,7 +45,7 @@
class="info-class" class="info-class"
> >
<span>{{ $t('panel.link_add_tips_pre') }}</span> <span>{{ $t('panel.link_add_tips_pre') }}</span>
<i class="icon iconfont icon-chaolianjie"/> <i class="icon iconfont icon-chaolianjie" />
<span>{{ $t('panel.web_add_tips_suf') }}</span> <span>{{ $t('panel.web_add_tips_suf') }}</span>
</div> </div>
</el-row> </el-row>
......
...@@ -156,11 +156,11 @@ export default { ...@@ -156,11 +156,11 @@ export default {
bus.$off('fieldSelect-' + this.element.propValue.viewId) bus.$off('fieldSelect-' + this.element.propValue.viewId)
}, },
methods: { methods: {
changeRightDrawOpen(param){ changeRightDrawOpen(param) {
if(param){ if (param) {
this.drawLeft = 'auto!important' this.drawLeft = 'auto!important'
this.drawRight = '380px' this.drawRight = '380px'
}else{ } else {
this.drawLeft = 'none' this.drawLeft = 'none'
this.drawRight = 'auto' this.drawRight = 'auto'
} }
...@@ -302,4 +302,3 @@ export default { ...@@ -302,4 +302,3 @@ export default {
} }
</style> </style>
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
class="info-stream-class" class="info-stream-class"
> >
<span>{{ $t('panel.link_add_tips_pre') }}</span> <span>{{ $t('panel.link_add_tips_pre') }}</span>
<i class="icon iconfont icon-chaolianjie"/> <i class="icon iconfont icon-chaolianjie" />
<span>{{ $t('panel.stream_media_add_tips') }}</span> <span>{{ $t('panel.stream_media_add_tips') }}</span>
</div> </div>
</el-row> </el-row>
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
class="info-class" class="info-class"
> >
<span>{{ $t('panel.link_add_tips_pre') }}</span> <span>{{ $t('panel.link_add_tips_pre') }}</span>
<i class="icon iconfont icon-chaolianjie"/> <i class="icon iconfont icon-chaolianjie" />
<span>{{ $t('panel.video_add_tips') }}</span> <span>{{ $t('panel.video_add_tips') }}</span>
</div> </div>
</el-row> </el-row>
......
...@@ -123,7 +123,7 @@ export default { ...@@ -123,7 +123,7 @@ export default {
if (data.type === 'view') { if (data.type === 'view') {
chartCopy(data.propValue.viewId, state.panel.panelInfo.id).then(res => { chartCopy(data.propValue.viewId, state.panel.panelInfo.id).then(res => {
const newView = deepCopy(data) const newView = deepCopy(data)
Vue.set(newView, 'needAdaptor', store.state.multiplexingStyleAdapt?needAdaptor:false) Vue.set(newView, 'needAdaptor', store.state.multiplexingStyleAdapt ? needAdaptor : false)
newView.id = uuid.v1() newView.id = uuid.v1()
newView.propValue.viewId = res.data newView.propValue.viewId = res.data
newView['canvasId'] = data.canvasId newView['canvasId'] = data.canvasId
...@@ -131,7 +131,7 @@ export default { ...@@ -131,7 +131,7 @@ export default {
if (newView.filters && newView.filters.length) { if (newView.filters && newView.filters.length) {
newView.filters = [] newView.filters = []
} }
if(needAdaptor && store.state.multiplexingStyleAdapt){ if (needAdaptor && store.state.multiplexingStyleAdapt) {
adaptCurThemeCommonStyle(newView) adaptCurThemeCommonStyle(newView)
} }
store.commit('addComponent', { component: newView }) store.commit('addComponent', { component: newView })
...@@ -145,23 +145,23 @@ export default { ...@@ -145,23 +145,23 @@ export default {
const newViewId = uuid.v1() const newViewId = uuid.v1()
sourceAndTargetIds[item.content.propValue.viewId] = newViewId sourceAndTargetIds[item.content.propValue.viewId] = newViewId
item.content.propValue.viewId = newViewId item.content.propValue.viewId = newViewId
Vue.set(item.content, 'needAdaptor', store.state.multiplexingStyleAdapt?needAdaptor:false) Vue.set(item.content, 'needAdaptor', store.state.multiplexingStyleAdapt ? needAdaptor : false)
if (item.content.filters && item.content.filters.length) { if (item.content.filters && item.content.filters.length) {
item.content.filters = [] item.content.filters = []
} }
} }
}) })
chartBatchCopy({ 'sourceAndTargetIds': sourceAndTargetIds }, state.panel.panelInfo.id).then((rsp) => { chartBatchCopy({ 'sourceAndTargetIds': sourceAndTargetIds }, state.panel.panelInfo.id).then((rsp) => {
if(needAdaptor && store.state.multiplexingStyleAdapt){ if (needAdaptor && store.state.multiplexingStyleAdapt) {
adaptCurThemeCommonStyle(newCop,'copy') adaptCurThemeCommonStyle(newCop, 'copy')
} }
store.commit('addComponent', { component: newCop }) store.commit('addComponent', { component: newCop })
}) })
} else { } else {
const newCop = deepCopy(data) const newCop = deepCopy(data)
newCop.id = uuid.v1() newCop.id = uuid.v1()
if(needAdaptor && store.state.multiplexingStyleAdapt) { if (needAdaptor && store.state.multiplexingStyleAdapt) {
adaptCurThemeCommonStyle(newCop,'copy') adaptCurThemeCommonStyle(newCop, 'copy')
} }
store.commit('addComponent', { component: newCop }) store.commit('addComponent', { component: newCop })
} }
......
...@@ -47,7 +47,7 @@ export default { ...@@ -47,7 +47,7 @@ export default {
data() { data() {
return { return {
asideHidden: false, asideHidden: false,
currentWidth: '', currentWidth: ''
} }
}, },
computed: { computed: {
......
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
@mousedown.stop.prevent="handleDown(handlei, $event)" @mousedown.stop.prevent="handleDown(handlei, $event)"
@touchstart.stop.prevent="handleTouchDown(handlei, $event)" @touchstart.stop.prevent="handleTouchDown(handlei, $event)"
> >
<slot :name="handlei"/> <slot :name="handlei" />
</div> </div>
<div <div
:id="componentCanvasId" :id="componentCanvasId"
...@@ -74,22 +74,22 @@ ...@@ -74,22 +74,22 @@
class="main-background" class="main-background"
> >
<div <div
v-show="!this.element.editing" v-show="!element.editing"
class="de-drag-area de-drag-top" class="de-drag-area de-drag-top"
@mousedown="elementMouseDown" @mousedown="elementMouseDown"
/> />
<div <div
v-show="!this.element.editing && this.element.type !=='de-tabs'" v-show="!element.editing && element.type !=='de-tabs'"
class="de-drag-area de-drag-right" class="de-drag-area de-drag-right"
@mousedown="elementMouseDown" @mousedown="elementMouseDown"
/> />
<div <div
v-show="!this.element.editing && this.element.type !=='de-tabs'" v-show="!element.editing && element.type !=='de-tabs'"
class="de-drag-area de-drag-bottom" class="de-drag-area de-drag-bottom"
@mousedown="elementMouseDown" @mousedown="elementMouseDown"
/> />
<div <div
v-show="!this.element.editing && this.element.type !=='de-tabs'" v-show="!element.editing && element.type !=='de-tabs'"
class="de-drag-area de-drag-left" class="de-drag-area de-drag-left"
@mousedown="elementMouseDown" @mousedown="elementMouseDown"
/> />
...@@ -99,7 +99,7 @@ ...@@ -99,7 +99,7 @@
class="svg-background" class="svg-background"
:icon-class="mainSlotSvgInner" :icon-class="mainSlotSvgInner"
/> />
<slot/> <slot />
</div> </div>
</div> </div>
</div> </div>
......
...@@ -42,7 +42,7 @@ export default { ...@@ -42,7 +42,7 @@ export default {
}) })
}, },
withLink(options, confirmButtonTextInfo) { withLink(options, confirmButtonTextInfo) {
const h = this.$createElement; const h = this.$createElement
const that = this const that = this
const { title, content, type = 'danger', cb, confirmButtonText = confirmButtonTextInfo || this.$t('commons.delete'), showCancelButton = true, cancelButtonText = this.$t('commons.cancel'), cancelCb = () => {}, finallyCb = () => {}, link = '', templateDel, linkTo } = options const { title, content, type = 'danger', cb, confirmButtonText = confirmButtonTextInfo || this.$t('commons.delete'), showCancelButton = true, cancelButtonText = this.$t('commons.cancel'), cancelCb = () => {}, finallyCb = () => {}, link = '', templateDel, linkTo } = options
const customClass = `de-confirm de-confirm-fail de-use-html` const customClass = `de-confirm de-confirm-fail de-use-html`
...@@ -55,14 +55,14 @@ export default { ...@@ -55,14 +55,14 @@ export default {
title, title,
content, content,
link link
}, }
}, },
on: { on: {
change: () => { change: () => {
linkTo() linkTo()
} }
} }
}), })
]), ]),
duration: 0, duration: 0,
confirmButtonText, confirmButtonText,
...@@ -71,18 +71,18 @@ export default { ...@@ -71,18 +71,18 @@ export default {
cancelButtonClass: 'de-confirm-btn de-confirm-plain-cancel', cancelButtonClass: 'de-confirm-btn de-confirm-plain-cancel',
confirmButtonClass, confirmButtonClass,
customClass, customClass,
iconClass: 'el-icon-warning', iconClass: 'el-icon-warning'
}).then(action => { }).then(action => {
if ('confirm' === action) { if (action === 'confirm') {
cb() cb()
} }
}) })
.catch((action) => { .catch((action) => {
cancelCb(action) cancelCb(action)
}) })
.finally(() => { .finally(() => {
finallyCb() finallyCb()
}) })
} }
} }
} }
...@@ -16,8 +16,8 @@ ...@@ -16,8 +16,8 @@
:key-word="keyWord" :key-word="keyWord"
popper-class="coustom-de-select" popper-class="coustom-de-select"
:list="data" :list="data"
@resetKeyWords="filterMethod"
:custom-style="customStyle" :custom-style="customStyle"
@resetKeyWords="filterMethod"
@change="changeValue" @change="changeValue"
@focus="setOptionWidth" @focus="setOptionWidth"
@blur="onBlur" @blur="onBlur"
......
...@@ -75,8 +75,8 @@ ...@@ -75,8 +75,8 @@
style="width: 100%;height:100%" style="width: 100%;height:100%"
> >
<Preview <Preview
:component-data="tabCanvasComponentData(item.name)"
:ref="'canvasTabRef-'+item.name" :ref="'canvasTabRef-'+item.name"
:component-data="tabCanvasComponentData(item.name)"
:canvas-style-data="canvasStyleData" :canvas-style-data="canvasStyleData"
:canvas-id="element.id+'-'+item.name" :canvas-id="element.id+'-'+item.name"
:panel-info="panelInfo" :panel-info="panelInfo"
...@@ -313,9 +313,9 @@ export default { ...@@ -313,9 +313,9 @@ export default {
return Boolean(this.$store.state.dragComponentInfo) return Boolean(this.$store.state.dragComponentInfo)
}, },
headClass() { headClass() {
if(this.tabsAreaScroll){ if (this.tabsAreaScroll) {
return 'tab-head-left' return 'tab-head-left'
}else{ } else {
return 'tab-head-' + this.element.style.headPosition return 'tab-head-' + this.element.style.headPosition
} }
}, },
...@@ -464,7 +464,7 @@ export default { ...@@ -464,7 +464,7 @@ export default {
bus.$on('add-new-tab', this.addNewTab) bus.$on('add-new-tab', this.addNewTab)
this.$nextTick(() => { this.$nextTick(() => {
this.activeTabName = this.element.options.tabList[0].name this.activeTabName = this.element.options.tabList[0].name
}); })
this.$store.commit('setTabActiveTabNameMap', { tabId: this.element.id, activeTabName: this.activeTabName }) this.$store.commit('setTabActiveTabNameMap', { tabId: this.element.id, activeTabName: this.activeTabName })
this.setContentThemeStyle() this.setContentThemeStyle()
}, },
...@@ -476,12 +476,12 @@ export default { ...@@ -476,12 +476,12 @@ export default {
bus.$off('add-new-tab', this.addNewTab) bus.$off('add-new-tab', this.addNewTab)
}, },
methods: { methods: {
calcTabLength(){ calcTabLength() {
this.$nextTick(()=>{ this.$nextTick(() => {
if(this.element.options.tabList.length>1){ if (this.element.options.tabList.length > 1) {
const containerDom = document.getElementById("tab-"+this.element.options.tabList[this.element.options.tabList.length -1].name) const containerDom = document.getElementById('tab-' + this.element.options.tabList[this.element.options.tabList.length - 1].name)
this.tabsAreaScroll = containerDom.parentNode.scrollWidth > containerDom.parentNode.parentNode.scrollWidth this.tabsAreaScroll = containerDom.parentNode.scrollWidth > containerDom.parentNode.parentNode.scrollWidth
}else{ } else {
this.tabsAreaScroll = false this.tabsAreaScroll = false
} }
}) })
...@@ -490,7 +490,7 @@ export default { ...@@ -490,7 +490,7 @@ export default {
return this.element.type return this.element.type
}, },
getWrapperChildRefs() { getWrapperChildRefs() {
let refsSubAll = [] const refsSubAll = []
const _this = this const _this = this
this.element.options.tabList.forEach(tabItem => { this.element.options.tabList.forEach(tabItem => {
const refsSub = _this.$refs['canvasTabRef-' + tabItem.name] const refsSub = _this.$refs['canvasTabRef-' + tabItem.name]
...@@ -530,7 +530,7 @@ export default { ...@@ -530,7 +530,7 @@ export default {
if (targetRef) { if (targetRef) {
targetRef[0]?.restore() targetRef[0]?.restore()
} }
}); })
}, switchTime) }, switchTime)
} }
}, },
......
<svg width="881" height="225" viewBox="0 0 881 225" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M97.24 3.0199L191.9 57.6599V166.94L97.24 221.59L2.59 166.94V57.6399L97.24 3V3.0199ZM97.24 0L0 56.1399V168.42L97.24 224.56L194.48 168.42V56.1699L97.24 0.0299072V0Z" fill="#426DF2"/>
<path d="M599.14 100.66H629.87L625.87 122.06H599.14V147.27H635.82L637.46 170.42H568.96V53.0599H637.5L635.86 75.7599H599.14V100.66Z" fill="#426DF2"/>
<path d="M409.65 118.75V170.25H387.14L387.04 165.04C379.167 169.133 371.477 171.177 363.97 171.17H361.74C354.027 171.17 347.897 168.207 343.35 162.28C340.339 157.654 338.766 152.239 338.83 146.72V146.11C338.83 135.99 342.38 129.27 349.48 125.95C352.387 124.01 359.77 123.04 371.63 123.04H383.74V120.21C383.74 114.383 382.897 111.05 381.21 110.21C379.37 108.83 376.127 108.14 371.48 108.14H347.34L347.75 87.5L375.54 86.75C392.04 86.75 402.26 90.8399 406.2 99.0199C408.5 103.747 409.65 110.323 409.65 118.75ZM366.31 140.14C365.54 141.05 364.73 144.02 364.73 146.14C364.73 150.74 367.063 153.04 371.73 153.04C374.537 153.04 378.537 151.89 383.73 149.59V138.34C383.73 138.34 369.1 136.81 366.31 140.14Z" fill="#426DF2"/>
<path d="M559.82 118.75V170.25H537.32L537.21 165.04C529.344 169.133 521.654 171.177 514.14 171.17H511.92C504.2 171.17 498.067 168.207 493.52 162.28C490.513 157.652 488.94 152.239 489 146.72V146.11C489 135.99 492.55 129.27 499.65 125.95C502.57 124.01 509.954 123.04 521.8 123.04H533.91V120.21C533.91 114.383 533.067 111.05 531.38 110.21C529.54 108.83 526.297 108.14 521.65 108.14H497.55L497.96 87.5L525.75 86.75C542.264 86.75 552.484 90.8399 556.41 99.0199C558.684 103.747 559.82 110.323 559.82 118.75ZM516.52 140.14C515.75 141.05 514.95 144.02 514.95 146.14C514.95 150.74 517.284 153.04 521.95 153.04C524.764 153.04 528.764 151.89 533.95 149.59V138.34C533.95 138.34 519.32 136.81 516.52 140.14Z" fill="#426DF2"/>
<path d="M716.951 118.75V170.25H694.451L694.341 165.04C686.467 169.133 678.777 171.177 671.271 171.17H669.051C661.331 171.17 655.197 168.207 650.651 162.28C647.643 157.652 646.071 152.239 646.131 146.72V146.11C646.131 135.99 649.684 129.27 656.791 125.95C659.704 124.01 667.087 123.04 678.941 123.04H691.041V120.21C691.041 114.383 690.201 111.05 688.521 110.21C686.681 108.83 683.434 108.14 678.781 108.14H654.641L655.051 87.5L682.841 86.75C699.347 86.75 709.567 90.8399 713.501 99.0199C715.801 103.747 716.951 110.323 716.951 118.75ZM673.611 140.14C672.841 141.05 672.041 144.02 672.041 146.14C672.041 150.74 674.374 153.04 679.041 153.04C681.854 153.04 685.854 151.89 691.041 149.59V138.34C691.041 138.34 676.411 136.81 673.611 140.14Z" fill="#426DF2"/>
<path d="M477.43 170.42H464.43C461.79 170.42 459.53 170.35 457.65 170.19C453.394 170.023 449.206 169.067 445.3 167.37C441.463 165.56 438.331 162.533 436.39 158.76C434.097 154.393 432.953 148.55 432.96 141.23L432.81 108.31H420.31V86.9399H432.82V60.34L458.42 65.2699V86.9399H477.93L475.26 108.35H458.38V139.83C458.38 140.54 458.38 141.15 458.46 141.66C458.518 142.772 458.723 143.872 459.07 144.93C459.478 145.99 460.133 146.937 460.979 147.693C461.826 148.45 462.841 148.994 463.94 149.28C466.57 150.273 469.309 150.944 472.1 151.28C472.71 151.38 473.34 151.46 474 151.51L475.6 151.66L477.43 151.74V170.42Z" fill="#426DF2"/>
<path d="M878.59 121.25V136.05H831.47L831.37 138.74C831.37 144.38 833.62 147.65 837.08 148.87C840.067 149.667 843.149 150.05 846.24 150.01H848.3C857.46 150.01 870.84 147.95 880.45 146.01H880.6L876.73 166.92C876.73 167.18 872.23 169.09 863.48 170.51C857.195 171.161 850.879 171.469 844.56 171.43C826.247 171.43 814.42 165.247 809.08 152.88C807.08 148 805.26 142.88 805.26 137.57V117.57C805.26 102.92 812.26 93.1599 824.57 88.3199C830.215 86.5087 836.112 85.6074 842.04 85.6499C859.294 85.6499 870.487 91.2732 875.62 102.52C877.6 106.913 878.59 113.157 878.59 121.25ZM853.9 117.35C853.9 111.56 852.17 107.68 849.68 106.61C847.8 105.34 844.89 105.15 842.19 105.15C835.33 105.15 831.897 108.38 831.89 114.84L831.47 118.73H853.9V117.35Z" fill="#426DF2"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M276.98 51.8799H231.71V170.42H276.98C305.82 170.42 329.21 150.88 329.21 126.79V95.5199C329.21 71.4299 305.82 51.9399 276.98 51.8799ZM300.12 127.81C300.12 138.5 289.77 147.16 276.98 147.17H261.87V75.1699H276.98C289.77 75.1699 300.12 83.8499 300.12 94.5299V127.81Z" fill="#426DF2"/>
<path d="M758.75 172.74C753.95 172.74 748.683 172.463 742.95 171.91C740.75 171.69 738.49 171.44 736.17 171.14L730.74 170.37L727.74 147.75L733.57 150L740.76 151.82C743.61 152.22 746.29 152.53 748.82 152.75C751.827 153.01 754.55 153.14 756.99 153.14C765.86 153.14 770.99 152.93 772.37 149.3C773.14 147.79 773.1 143.68 772.25 142.3C771.4 140.92 769.58 139.36 766.82 138.23C765.64 137.75 764.15 137.23 762.36 136.74L757.11 135.31C754.8 134.8 752.72 134.31 750.89 133.77C748.53 133.103 746.373 132.407 744.42 131.68C740.3 130.257 736.475 128.095 733.13 125.3C730.595 122.881 728.87 119.737 728.19 116.3C727.652 113.45 727.591 110.53 728.01 107.66C729.11 98.3266 733.523 91.9266 741.25 88.46C744.558 86.9462 748.073 85.9351 751.68 85.46C753.27 85.24 755.08 85.0599 757.11 84.9099L762.36 84.58H765.9C769.9 84.58 774.333 84.8 779.2 85.24L785.12 85.84L790.12 86.5L792.2 106.83C788.91 106.065 785.568 105.55 782.2 105.29C777.517 104.798 772.807 104.618 768.1 104.75C758.82 104.75 753.37 104.24 751.74 108.02C751.436 108.737 751.29 109.511 751.313 110.289C751.335 111.068 751.525 111.832 751.87 112.53C752.763 114.183 754.713 115.633 757.72 116.88C758.98 117.4 760.567 117.95 762.48 118.53L774.56 121.78C776.88 122.447 778.957 123.113 780.79 123.78C784.479 125.024 787.887 126.981 790.82 129.54C793.484 131.926 795.302 135.112 796 138.62C796.532 142.304 796.596 146.04 796.19 149.74C795.09 158.98 790.673 165.38 782.94 168.94C779.643 170.483 776.123 171.496 772.51 171.94C770.92 172.16 769.11 172.35 767.08 172.49L762.38 172.77L758.75 172.74Z" fill="#426DF2"/>
<path d="M97.2405 36.2899L163.08 74.2899V150.29L97.2405 188.29L31.4105 150.29V74.2899L97.2405 36.2899ZM97.2405 15.8799L13.7305 64.09V160.53L97.2405 208.74L180.76 160.53V64.09L97.2405 15.8799Z" fill="#426DF2"/>
<path d="M56.82 113.31C55.1193 113.318 53.464 112.762 52.1135 111.729C50.7631 110.695 49.7939 109.242 49.3581 107.598C48.9222 105.954 49.0443 104.212 49.7052 102.645C50.3662 101.078 51.5285 99.7752 53.01 98.94L80.22 83.24C81.9814 82.2591 84.0579 82.0102 86.0013 82.547C87.9447 83.0839 89.599 84.3633 90.6072 86.1093C91.6154 87.8553 91.8966 89.9277 91.3901 91.8792C90.8836 93.8307 89.63 95.5047 87.9 96.5399L60.68 112.24C59.5115 112.934 58.179 113.303 56.82 113.31Z" fill="#00BFFF"/>
<path d="M104.99 85.5399C103.3 85.5395 101.657 84.9815 100.316 83.9524C98.9752 82.9233 98.0113 81.4805 97.5737 79.8478C97.1362 78.2151 97.2496 76.4837 97.8962 74.922C98.5428 73.3603 99.6866 72.0555 101.15 71.21L111.15 65.47C112.025 64.9301 112.999 64.5713 114.015 64.4148C115.031 64.2583 116.068 64.3074 117.064 64.5591C118.061 64.8108 118.997 65.2599 119.817 65.8799C120.636 66.4999 121.323 67.2782 121.837 68.1686C122.35 69.059 122.68 70.0434 122.806 71.0635C122.932 72.0836 122.852 73.1187 122.571 74.1073C122.289 75.0959 121.812 76.0181 121.168 76.819C120.524 77.6199 119.726 78.2833 118.82 78.7699L108.82 84.5099C107.657 85.1848 106.335 85.5402 104.99 85.5399Z" fill="#00BFFF"/>
<path d="M68.2004 136.75C66.5092 136.752 64.8648 136.195 63.5222 135.167C62.1796 134.139 61.214 132.696 60.7752 131.063C60.3364 129.429 60.449 127.697 61.0954 126.134C61.7418 124.572 62.886 123.266 64.3504 122.42L64.6104 122.27C66.3687 121.314 68.4306 121.083 70.3571 121.625C72.2835 122.167 73.9223 123.44 74.9246 125.172C75.9269 126.904 76.2135 128.959 75.7233 130.899C75.2332 132.839 74.005 134.512 72.3004 135.56L72.0404 135.71C70.8745 136.389 69.5497 136.748 68.2004 136.75Z" fill="#00BFFF"/>
<path d="M89.1303 124.94C87.4407 124.942 85.7974 124.387 84.455 123.361C83.1127 122.335 82.1463 120.895 81.7054 119.264C81.2646 117.632 81.374 115.901 82.0167 114.339C82.6594 112.776 83.7995 111.469 85.2604 110.62L122.43 88.94C123.303 88.4097 124.272 88.0586 125.281 87.9071C126.291 87.7557 127.32 87.807 128.309 88.058C129.299 88.3091 130.228 88.7549 131.043 89.3693C131.858 89.9837 132.543 90.7544 133.057 91.6364C133.57 92.5184 133.903 93.494 134.036 94.5061C134.168 95.5183 134.097 96.5466 133.828 97.531C133.558 98.5155 133.095 99.4364 132.465 100.24C131.835 101.043 131.052 101.713 130.16 102.21L92.9903 123.86C91.8223 124.556 90.4901 124.929 89.1303 124.94Z" fill="#00BFFF"/>
<path d="M79.5502 160.18C77.8599 160.18 76.217 159.622 74.8761 158.592C73.5352 157.563 72.5713 156.121 72.1338 154.488C71.6963 152.855 71.8096 151.124 72.4562 149.562C73.1028 148 74.2466 146.696 75.7102 145.85L133.82 112.34C135.585 111.323 137.682 111.049 139.649 111.577C141.617 112.106 143.293 113.395 144.31 115.16C145.327 116.925 145.602 119.022 145.073 120.989C144.544 122.956 143.255 124.633 141.49 125.65L83.3902 159.15C82.2237 159.827 80.8987 160.182 79.5502 160.18Z" fill="#426DF2"/>
</svg>
<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><g id="SVGRepo_bgCarrier" stroke-width="0"></g><g id="SVGRepo_tracerCarrier" stroke-linecap="round" stroke-linejoin="round"></g><g id="SVGRepo_iconCarrier"> <g clip-path="url(#clip0_15_90)"> <rect width="24" height="24" fill="white"></rect> <path d="M20 12C20 16.4183 16.4183 20 12 20C10.5937 20 9.27223 19.6372 8.12398 19C7.53267 18.6719 4.48731 20.4615 3.99998 20C3.44096 19.4706 5.4583 16.6708 5.07024 16C4.38956 14.8233 3.99999 13.4571 3.99999 12C3.99999 7.58172 7.58171 4 12 4C16.4183 4 20 7.58172 20 12Z" stroke="#000000" stroke-linejoin="round"></path> </g> <defs> <clipPath id="clip0_15_90"> <rect width="24" height="24" fill="white"></rect> </clipPath> </defs> </g></svg>
\ No newline at end of file
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1690265919057" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="14240" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M491.52 76.8h37.888v111.616l53.76 66.56 74.24 91.648h-296.96l74.24-91.648 56.32-69.632V76.8h0.512zM289.792 886.272h59.392V382.464h323.072v504.32h57.856V486.4H870.4v399.872h93.184V957.44H83.456V353.792l206.336 118.272v414.208z m231.936-143.36V798.72h44.544v-55.808h-44.544z m-409.6-84.992v33.792h27.136v-33.792h-27.136z m130.048 59.392v33.792h27.136v-33.792h-27.136z m0-119.808v33.792h27.136v-33.792h-27.136z m0-59.392v33.792h27.136v-33.792h-27.136z m-43.008 119.808v33.792h27.136v-33.792h-27.136z m0-119.808v33.792h27.136v-33.792h-27.136z m-44.544 119.808v33.792h27.136v-33.792h-27.136z m0 59.392v33.792h27.136v-33.792h-27.136z m0-119.808v33.792h27.136v-33.792h-27.136z m-42.496-59.392v33.792h27.136v-33.792h-27.136z m642.048 130.048v41.984h33.792v-41.984h-33.792z m0 73.216v41.984h33.792v-41.984h-33.792z m0-222.208v41.984h33.792v-41.984h-33.792z m52.736 73.216v41.984h33.28v-41.984h-33.28z m0-73.216v41.984h33.28v-41.984h-33.28z m-421.376 223.744V798.72H430.08v-55.808h-44.544z m0-198.656v55.808H430.08v-55.808h-44.544z m203.264 0v55.808h44.544v-55.808H588.8z m-67.072 0v55.808h44.544v-55.808h-44.544z m-67.072 0v55.808h44.544v-55.808h-44.544zM385.536 446.464v55.808H430.08V446.464h-44.544z m203.264 0v55.808h44.544V446.464H588.8z m-67.072 0v55.808h44.544V446.464h-44.544zM385.536 645.12v55.808H430.08V645.12h-44.544z m203.264 0v55.808h44.544V645.12H588.8z" fill="#2c2c2c" p-id="14241"></path></svg>
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1690265990298" class="icon" viewBox="0 0 1038 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="16350" xmlns:xlink="http://www.w3.org/1999/xlink" width="202.734375" height="200"><path d="M522.666667 0c282.766222 0 512 229.233778 512 512s-229.233778 512-512 512-512-229.233778-512-512 229.233778-512 512-512z m-35.029334 213.333333h-126.791111a14.222222 14.222222 0 0 0-14.222222 14.222223v47.018666H312.888889a28.444444 28.444444 0 0 0-28.444445 28.444445V782.222222a28.444444 28.444444 0 0 0 28.444445 28.444445h426.666667a28.444444 28.444444 0 0 0 28.444444-28.444445V471.893333a28.444444 28.444444 0 0 0-19.555556-27.022222l-125.013333-41.173333a14.222222 14.222222 0 0 0-18.673778 13.511111v299.52a13.240889 13.240889 0 1 1-26.481777 0V303.004444a28.444444 28.444444 0 0 0-28.444445-28.444444h-33.749333V241.777778a28.444444 28.444444 0 0 0-28.444445-28.444445z m232.945778 407.352889v60.373334h-68.408889v-60.373334h68.408889z m-230.926222 0v60.373334h-116.593778v-60.373334h116.593778z m230.926222-126.663111v60.387556h-68.408889v-60.387556h68.408889z m-230.926222 0v60.387556h-116.593778v-60.387556h116.593778z m0-126.663111v60.387556h-116.593778V367.36h116.593778z" fill="#2c2c2c" p-id="16351"></path></svg>
<svg t="1692175494268" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="13238" width="200" height="200"><path d="M926.6 422.9C895 277.9 802 166.5 657.9 100.8c-8.4-3.8-17.5-4.1-25.6-0.7-16 6.6-22.5 24.2-28.3 39.6-1.7 4.5-4.4 11.8-6.2 14.8-18.2 12-26.4 37.1-19.1 59.9 4.4 13.7 13.9 23.9 26.2 29.4-0.3 10.7 1.2 24.2 5.9 41.4 5 18.2 13.6 40.4 34.8 50.9 24.5 12.1 55.6 2.7 82.9-8.1 5.4-1.9 9.3-2.7 11.8-2.9v0.6c-1.9 14.3-6.7 23.2-12.3 33.5-15.1 28.2-24.2 52.8-2.9 113.5 11.9 34.2 33.2 55.7 52 74.7 13.7 13.8 25.5 25.7 32.2 40.7 11.9 29 48.4 48.5 80.5 65.7l6.1 3.3c3.3 1.8 6.9 2.7 10.6 2.7 3.2 0 6.5-0.7 9.5-2.1 6.4-3 11-8.9 12.4-15.8l0.1-0.7c5.5-25.2 20.7-114.7-1.9-218.3z m-36.5 179.9c-17.7-10.2-35.4-21.9-39.4-31.9-0.1-0.3-0.2-0.5-0.3-0.8-10-22.5-26-38.7-41.4-54.2-17-17.1-33-33.3-41.6-58v-0.1c-16.5-46.8-9.9-59.1 0.1-77.7 6.4-11.9 14.3-26.6 17.3-49.3 0-0.3 0.1-0.6 0.1-0.9 2.1-22.6-7.2-34.8-15.3-41-5.8-4.5-14.6-8.6-27.4-8.6-8 0-17.6 1.6-28.9 5.7-0.2 0.1-0.4 0.2-0.7 0.3-32.1 12.8-43.2 11.6-47 9.7-2.8-1.4-7.1-6.5-11.7-22.9-6.3-22.7-4.1-32.3-3.5-34.4 4.8-6.6 5.7-15.3 2-22.8-4.1-8.5-13.2-13.5-22.6-12.4-7.1 0.8-8-1.3-8.4-2.2-1.6-3.5-0.3-8.7 0.9-9.7l1.5-0.9c11.6-7.7 16.9-21.9 21.9-35.5 1-2.6 2.3-6.1 3.6-9.3C906.8 269.4 902.8 509 890.1 602.8zM610.8 597.1c-12.2-10.5-20.8-19.3-28.4-27.1-24.7-25.4-40-38.7-93.1-38.7-33.9 0-71.6 3.6-93.9 30.3-18 21.6-22.5 52.8-14.1 98.3 10 54.4 32.3 70.2 47.1 80.6 10 7.1 12.1 8.6 10.8 27.7-4.3 59.6 7.3 83.7 20.7 105.1 1.1 1.8 2.2 3.5 3.2 5.2 9.4 16.4 28.1 42.6 52.4 42.6 1.9 0 3.9-0.2 5.8-0.5 28.2-4.9 34.4-40 36.5-51.5 11.5-64.4 32.6-98.2 53.7-125 18.8-24 68.7-87.5-0.7-147z m-34.3 119.4C553 746.4 527.2 787 514 861.2c-0.7 4-1.5 7.2-2.2 9.7-3.1-3.6-6.7-8.6-10.1-14.5-1.2-2.2-2.6-4.4-4-6.7-8.3-13.3-17.6-28.3-14-78.4 2.9-40.8-11.6-54.6-29.4-67.2-11.5-8.1-22.3-15.8-29-52.4-5.6-30.6-4.1-51.4 4.5-61.7 8.2-9.9 26.6-14.3 59.6-14.3 36.7 0 41.4 4.8 61.1 25.2 7.8 8.1 17.6 18.1 31.3 29.9 28 24.1 26.7 44.9-5.3 85.7zM306.5 485.2c0.4-0.5 1.6-1.5 3.8-2.7l0.9-0.5c11.1-5.9 27.5-14.7 34.5-15.6 0.6 1.1 1.4 3.1 2.2 6.5 5.9 23.4 23.5 38.5 46 39.4 26.8 1 54.3-19 63.5-46.6 5.1-15.3 9-16.2 27.5-20.2 9.9-2.2 22.2-4.9 36-10.9 34.1-14.9 69.9-34.8 62-81.9l-0.5-3.2c-4.5-27.4-11.2-68.8-83.8-68.8-31.5 0-48.4 13.7-58.6 21.9-1.2 0.9-2.6 2.1-3.8 3-2.2-1.4-6.6-4.5-13.8-11.7-2.2-2.2-4-4.1-5.5-5.8 2.2-0.5 4.5-1 6.3-1.4 9.3-2 18.9-4.1 27.4-8.3 23.8-11.9 47.7-51.4 41.7-80.6-3.9-19.2-19-31.4-40.3-32.6-24.3-1.4-36.7 4.6-44.9 8.5-5.2 2.5-5.6 2.7-14-0.3-34.1-12.2-56.2 20.3-69.5 39.8-1.9 2.7-4.2 6.1-6.4 9.1-1.5-1.8-3-3.7-4.3-5.3-15.7-19.6-39.5-49.2-74.3-48.2-7.9 0.2-26.5 0.8-71.4 62.3-24.3 33.2-47.3 72.5-60 102.5-1.4 3.4-2 7-1.7 10.6 6.6 74.7 41.9 118.1 52.7 129.7 8.6 15.6 43.3 64.6 162.3 121 2.4 1.1 4.9 1.8 7.5 2.1 1.1 0.1 2.2 0.1 3.3 0.1 10.2 0 22.8-4.2 28.5-16.5 9.8-21-10.2-41-18.7-49.5-31-31.3-34.7-42.4-34.6-45.9z m-17.1-42c-19.5 10.4-25.4 24.8-26.9 35.1-2 13.4 2.4 26.8 10.1 39.8-58.7-36.8-73.9-63.4-75.5-66.3-1.1-3.1-2.7-5-5.1-7.4-1.4-1.4-34.1-33.9-41.5-99 24.4-54.6 74.6-121.9 91.8-132.3 12.2 1.7 26.4 19.4 36 31.4 9.4 11.7 16.9 21.1 27.3 25.1 25.9 10.8 43.3-14.7 54.9-31.6 4.8-7.1 13.6-20 18.5-22.6 23.6 8.2 36 3.8 47.7-1.9 5.5-2.7 9.9-4.8 22.2-4.2-1 8.5-10.4 25.2-18 29-3.4 1.7-10.6 3.2-16.9 4.6-16.7 3.6-39.6 8.6-45.8 29.6-6 20.3 9.1 38.8 22.9 52.6 34.1 34.1 54.8 29.9 77 11.9 8.3-6.7 14.8-12 30.6-12 34.7 0 35.8 6.7 39.8 31.5l0.6 3.4c1.6 9.4 2.8 16.9-35.9 33.8-9.8 4.3-18.9 6.3-27.7 8.2-21 4.6-47.1 10.3-60.2 49.6-3.5 10.6-13.5 16.2-19.3 16.2h-0.3c-1.4-0.1-3.1-0.1-4.5-5.7-4.6-18.5-13.6-30.9-26.8-36.7-22.7-10.1-46.5 2.6-74.1 17.4l-0.9 0.5z" fill="#231815" p-id="13239"></path><path d="M512 0C229.7 0 0 229.7 0 512s229.7 512 512 512 512-229.7 512-512S794.3 0 512 0z m0 979.5C254.2 979.5 44.5 769.8 44.5 512S254.2 44.5 512 44.5 979.5 254.2 979.5 512 769.8 979.5 512 979.5z" fill="#231815" p-id="13240"></path></svg>
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1689841504633" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1855" xmlns:xlink="http://www.w3.org/1999/xlink" width="48" height="48"><path d="M781.981888 1014.033538C649.277769 945.497049 431.312619 990.61918 298.608501 972.93895 165.904382 955.25872 80.23377 832.725854 35.111639 706.301971-80.32183 383.00634 113.136746 295.287826 270.483965 302.387223 427.899447 309.691411 362.093496 148.180122 582.720919 27.558632 803.348343-93.062859 862.874059 217.126192 838.367485 287.574057 813.792648 358.021923 796.863316 425.32967 963.357836 601.858915 1129.852355 778.456422 914.686006 1082.706555 781.981888 1014.033538ZM891.408175 606.432565C745.66574 458.778754 743.413046 396.044657 768.397464 329.692597 789.900446 272.214785 777.886081 13.22331 589.478999 113.229243 401.071917 213.30344 457.730569 374.746465 324.207289 370.650659 190.615746 366.554852 7.601475 440.279363 102.28286 701.250477 139.281642 803.236049 225.976205 884.810855 338.474347 897.644381 450.972489 910.54617 634.259813 878.735409 746.211847 932.868314 858.163882 987.069481 1031.0069 747.874403 891.408175 606.432565ZM650.09693 792.51869C581.014333 766.646848 565.723324 679.337914 586.270618 607.388253 606.886175 535.302065 543.947288 435.773976 514.730537 379.866222 485.58205 323.753678 553.708959 197.671113 626.068201 178.352561 743.549573 146.95138 684.365175 331.7405 689.280142 455.092528 694.331636 578.444556 870.314773 658.79062 868.47166 734.28998 866.628548 809.789339 719.111263 818.458796 650.09693 792.51869ZM471.997627 693.058865C411.379696 748.01093 334.105487 776.886363 255.943853 750.604941 177.918747 724.255255 125.902009 596.124786 186.519939 541.991882 310.076758 431.541643 323.04681 547.179903 423.803641 498.098493 524.492209 449.085346 532.547294 638.106799 471.997627 693.058865Z" p-id="1856"></path></svg>
\ No newline at end of file
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1689905026346" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="1736" xmlns:xlink="http://www.w3.org/1999/xlink" width="200" height="200"><path d="M955 99h-32c-2.8 0-5 2.2-5 5v62c-173-7.8-345 33.2-494.3 118.4-36.4 22.1-74.2 42-113.2 59.6-57.6-53.2-127.9-91.5-204.4-112.1V104c0-2.8-2.2-5-5-5H69c-2.8 0-5 2.2-5 5v816c0 2.8 2.2 5 5 5h32c2.8 0 5-2.2 5-5v-64.3c146.4-13.8 288.5-55.9 417.7-123.8 39.1-20.8 79.4-39.5 120.7-56 85.9 41.2 178.4 68.2 273.5 79.9V920c0 2.8 2.2 5 5 5H955c2.8 0 5-2.2 5-5V104c0-2.8-2.2-5-5-5zM106 294.4c51 16.2 98.5 41.9 139.4 75.9C200.1 387 153.5 399.9 106 409V294.4z m327 282c-101.5 52.9-212.5 86.7-327 99.7v-206c66.3-11.7 131.1-30.3 193.2-55.7 20 17.9 40.7 37.5 62.5 59.6 29.6 32.3 61.8 62.4 96.3 90l-25 12.4z m86.4-42.3c-40.2-29.4-77.5-62.3-111.3-98.3-16.3-17.3-31.9-33.4-47.5-47.7 33-15.5 65.1-32.6 96.3-51.3C596.4 258.1 756.7 220.1 918 226.7v208.2c-138.5 6-274.4 39.7-398.6 99.2z m208.8 113.8c61.6-18.9 125.3-30.3 189.7-34v82.5c-65.1-8-128.9-24.3-189.7-48.5z" p-id="1737"></path></svg>
\ No newline at end of file
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
> >
<notification class="right-menu-item hover-effect" /> <notification class="right-menu-item hover-effect" />
<lang-select class="right-menu-item hover-effect" /> <lang-select class="right-menu-item hover-effect" />
<div <!-- <div
style="height: 100%;padding: 0 8px;" style="height: 100%;padding: 0 8px;"
class="right-menu-item hover-effect" class="right-menu-item hover-effect"
> >
...@@ -58,7 +58,7 @@ ...@@ -58,7 +58,7 @@
> >
<svg-icon icon-class="docs" /> <svg-icon icon-class="docs" />
</a> </a>
</div> </div> -->
<el-dropdown <el-dropdown
ref="my-drop" ref="my-drop"
......
import Vue from 'vue' import Vue from "vue";
import Cookies from 'js-cookie' import Cookies from "js-cookie";
import '@/styles/index.scss' // global css import "@/styles/index.scss"; // global css
import ElementUI from 'element-ui' import ElementUI from "element-ui";
import Vuetify from 'vuetify' import Vuetify from "vuetify";
import Fit2CloudUI from 'fit2cloud-ui' import Fit2CloudUI from "fit2cloud-ui";
import i18n from './lang' // internationalization import i18n from "./lang"; // internationalization
import App from './App' import App from "./App";
import store from './store' import store from "./store";
import router from './router' import router from "./router";
import message from './utils/message' import message from "./utils/message";
import '@/icons' // icon import "@/icons"; // icon
import '@/permission' // permission control import "@/permission"; // permission control
import api from '@/api/index.js' import api from "@/api/index.js";
import filter from '@/filter/filter' import filter from "@/filter/filter";
import directives from './directive' import directives from "./directive";
import VueClipboard from 'vue-clipboard2' import VueClipboard from "vue-clipboard2";
import widgets from '@/components/widget' import widgets from "@/components/widget";
import Treeselect from '@riophae/vue-treeselect' import Treeselect from "@riophae/vue-treeselect";
import '@riophae/vue-treeselect/dist/vue-treeselect.css' import "@riophae/vue-treeselect/dist/vue-treeselect.css";
import './utils/dialog' import "./utils/dialog";
import DeComplexInput from '@/components/business/conditionTable/DeComplexInput' import DeComplexInput from "@/components/business/conditionTable/DeComplexInput";
import DeComplexSelect from '@/components/business/conditionTable/DeComplexSelect' import DeComplexSelect from "@/components/business/conditionTable/DeComplexSelect";
import DeViewSelect from '@/components/deViewSelect' import DeViewSelect from "@/components/deViewSelect";
import RemarkEditor from '@/views/chart/components/componentStyle/dialog/RemarkEditor' import RemarkEditor from "@/views/chart/components/componentStyle/dialog/RemarkEditor";
import TitleRemark from '@/views/chart/view/TitleRemark' import TitleRemark from "@/views/chart/view/TitleRemark";
import '@/components/canvas/customComponent' // 注册自定义组件 import "@/components/canvas/customComponent"; // 注册自定义组件
import deBtn from '@/components/deCustomCm/DeBtn.vue' import deBtn from "@/components/deCustomCm/DeBtn.vue";
import '@/utils/DateUtil' import "@/utils/DateUtil";
import draggable from 'vuedraggable' import draggable from "vuedraggable";
import deWebsocket from '@/websocket' import deWebsocket from "@/websocket";
import { GaodeMap } from '@antv/l7-maps' import { GaodeMap } from "@antv/l7-maps";
import * as echarts from 'echarts' import * as echarts from "echarts";
import UmyUi from 'umy-ui' import UmyUi from "umy-ui";
// 全屏插件 // 全屏插件
import fullscreen from 'vue-fullscreen' import fullscreen from "vue-fullscreen";
import VueFriendlyIframe from 'vue-friendly-iframe' import VueFriendlyIframe from "vue-friendly-iframe";
import vueToPdf from 'vue-to-pdf' import vueToPdf from "vue-to-pdf";
import VueVideoPlayer from 'vue-video-player' import VueVideoPlayer from "vue-video-player";
import 'video.js/dist/video-js.css' import "video.js/dist/video-js.css";
import '@antv/s2/dist/style.min.css' import "@antv/s2/dist/style.min.css";
import VueAMap from "vue-amap";
// 控制标签宽高成比例的指令 // 控制标签宽高成比例的指令
import proportion from 'vue-proportion-directive' import proportion from "vue-proportion-directive";
import xss from 'xss' import xss from "xss";
// 定义全局XSS解决方法 // 定义全局XSS解决方法
Object.defineProperty(Vue.prototype, '$xss', { Object.defineProperty(Vue.prototype, "$xss", {
value: xss value: xss,
}) });
window._AMapSecurityConfig = {
Vue.config.productionTip = false securityJsCode: "1b336198f587a2a6e3a723f72db8358f",
Vue.use(VueClipboard) };
Vue.use(widgets) Vue.config.productionTip = false;
Vue.component('Draggable', draggable) Vue.use(VueClipboard);
Vue.prototype.$api = api Vue.use(widgets);
Vue.component("Draggable", draggable);
Vue.prototype.$echarts = echarts Vue.prototype.$api = api;
Vue.prototype.$gaodeMap = GaodeMap
Vue.prototype.$echarts = echarts;
Vue.use(UmyUi) Vue.prototype.$gaodeMap = GaodeMap;
Vue.use(fullscreen) Vue.use(UmyUi);
Vue.use(VueFriendlyIframe) Vue.use(fullscreen);
Vue.use(Vuetify)
Vue.use(VueFriendlyIframe);
Vue.use(Vuetify);
Vue.use(VueAMap);
VueAMap.initAMapApiLoader({
key: "9e49146176f7e9153ffe8a982638fae6",
plugin: [
"AMap.Scale",
"AMap.OverView",
"AMap.ToolBar",
"AMap.MapType",
"AMap.PlaceSearch",
"AMap.Geolocation",
"AMap.Geocoder",
"AMap.DistrictSearch",
"AMap.Polygon",
],
v: "2.0",
});
// import TEditor from '@/components/Tinymce/index.vue' // import TEditor from '@/components/Tinymce/index.vue'
// Vue.component('TEditor', TEditor) // Vue.component('TEditor', TEditor)
...@@ -76,80 +97,83 @@ Vue.use(Vuetify) ...@@ -76,80 +97,83 @@ Vue.use(Vuetify)
* Currently MockJs will be used in the production environment, * Currently MockJs will be used in the production environment,
* please remove it before going online ! ! ! * please remove it before going online ! ! !
*/ */
if (process.env.NODE_ENV === 'production') { if (process.env.NODE_ENV === "production") {
// const { mockXHR } = require('../mock') // const { mockXHR } = require('../mock')
// mockXHR() // mockXHR()
} }
// set ElementUI lang to EN // set ElementUI lang to EN
// Vue.use(ElementUI, { locale }) // Vue.use(ElementUI, { locale })
// 如果想要中文版 element-ui,按如下方式声明 // 如果想要中文版 element-ui,按如下方式声明
ElementUI.Dialog.props.closeOnClickModal.default = false ElementUI.Dialog.props.closeOnClickModal.default = false;
ElementUI.Dialog.props.closeOnPressEscape.default = false ElementUI.Dialog.props.closeOnPressEscape.default = false;
Vue.use(ElementUI, { Vue.use(ElementUI, {
size: Cookies.get('size') || 'medium', // set element-ui default size size: Cookies.get("size") || "medium", // set element-ui default size
i18n: (key, value) => i18n.t(key, value) i18n: (key, value) => i18n.t(key, value),
}) });
Vue.use(Fit2CloudUI, { Vue.use(Fit2CloudUI, {
i18n: (key, value) => i18n.t(key, value) i18n: (key, value) => i18n.t(key, value),
}) });
// Vue.use(VueAxios, axios) // Vue.use(VueAxios, axios)
Vue.use(filter) Vue.use(filter);
Vue.use(directives) Vue.use(directives);
Vue.use(message) Vue.use(message);
Vue.component('Treeselect', Treeselect) Vue.component("Treeselect", Treeselect);
Vue.component('DeComplexInput', DeComplexInput) Vue.component("DeComplexInput", DeComplexInput);
Vue.component('DeComplexSelect', DeComplexSelect) Vue.component("DeComplexSelect", DeComplexSelect);
Vue.component('DeViewSelect', DeViewSelect) Vue.component("DeViewSelect", DeViewSelect);
Vue.component('RemarkEditor', RemarkEditor) Vue.component("RemarkEditor", RemarkEditor);
Vue.component('TitleRemark', TitleRemark) Vue.component("TitleRemark", TitleRemark);
Vue.component('DeBtn', deBtn) Vue.component("DeBtn", deBtn);
Vue.config.productionTip = false Vue.config.productionTip = false;
Vue.use(vueToPdf) Vue.use(vueToPdf);
Vue.use(VueVideoPlayer) Vue.use(VueVideoPlayer);
Vue.use(proportion) Vue.use(proportion);
Vue.prototype.hasDataPermission = function(pTarget, pSource) { Vue.prototype.hasDataPermission = function (pTarget, pSource) {
if (this.$store.state.user.user.isAdmin || pSource === 'ignore') { if (this.$store.state.user.user.isAdmin || pSource === "ignore") {
return true return true;
} }
if (pSource && pTarget) { if (pSource && pTarget) {
return pSource.indexOf(pTarget) > -1 return pSource.indexOf(pTarget) > -1;
} }
return false return false;
} };
Vue.prototype.checkPermission = function(pers) { Vue.prototype.checkPermission = function (pers) {
const permissions = store.getters.permissions const permissions = store.getters.permissions;
const hasPermission = pers.every(needP => { const hasPermission = pers.every((needP) => {
const result = permissions.includes(needP) const result = permissions.includes(needP);
return result return result;
}) });
return hasPermission return hasPermission;
} };
Vue.use(deWebsocket) Vue.use(deWebsocket);
Vue.prototype.$currentHttpRequestList = new Map() Vue.prototype.$currentHttpRequestList = new Map();
Vue.prototype.$cancelRequest = function(cancelkey) { Vue.prototype.$cancelRequest = function (cancelkey) {
if (cancelkey) { if (cancelkey) {
if (cancelkey.indexOf('/**') > -1) { if (cancelkey.indexOf("/**") > -1) {
Vue.prototype.$currentHttpRequestList.forEach((item, key) => { Vue.prototype.$currentHttpRequestList.forEach((item, key) => {
key.indexOf(cancelkey.split('/**')[0]) > -1 && item('Operation canceled by the user.') key.indexOf(cancelkey.split("/**")[0]) > -1 &&
}) item("Operation canceled by the user.");
});
} else { } else {
Vue.prototype.$currentHttpRequestList.get(cancelkey) && Vue.prototype.$currentHttpRequestList.get(cancelkey)('Operation canceled by the user.') Vue.prototype.$currentHttpRequestList.get(cancelkey) &&
Vue.prototype.$currentHttpRequestList.get(cancelkey)(
"Operation canceled by the user."
);
} }
} }
} };
new Vue({ new Vue({
router, router,
store, store,
i18n, i18n,
render: h => h(App) render: (h) => h(App),
}).$mount('#app') }).$mount("#app");
...@@ -2,7 +2,8 @@ module.exports = { ...@@ -2,7 +2,8 @@ module.exports = {
TokenKey: 'Authorization', TokenKey: 'Authorization',
RefreshTokenKey: 'refreshauthorization', RefreshTokenKey: 'refreshauthorization',
LinkTokenKey: 'LINK-PWD-TOKEN', LinkTokenKey: 'LINK-PWD-TOKEN',
title: 'DataEase', // title: 'DataEase',
title: 'DataGalaxy',
/* for sso */ /* for sso */
IdTokenKey: 'IdToken', IdTokenKey: 'IdToken',
AccessTokenKey: 'AccessToken', AccessTokenKey: 'AccessToken',
......
...@@ -70,7 +70,7 @@ const mutations = { ...@@ -70,7 +70,7 @@ const mutations = {
}, },
SET_PASSWORD_MODIFIED: (state, passwordModified) => { SET_PASSWORD_MODIFIED: (state, passwordModified) => {
state.passwordModified = passwordModified state.passwordModified = passwordModified
}, }
} }
const actions = { const actions = {
...@@ -110,8 +110,8 @@ const actions = { ...@@ -110,8 +110,8 @@ const actions = {
reject('Verification failed, please Login again.') reject('Verification failed, please Login again.')
} }
const historyUserId = localStorage.getItem('userId') const historyUserId = localStorage.getItem('userId')
if(historyUserId && historyUserId !== data.userId+''){ if (historyUserId && historyUserId !== data.userId + '') {
const clearLocalStorage = [ 'panel-main-tree', 'panel-default-tree','chart-tree','dataset-tree'] const clearLocalStorage = ['panel-main-tree', 'panel-default-tree', 'chart-tree', 'dataset-tree']
clearLocalStorage.forEach((item) => { clearLocalStorage.forEach((item) => {
localStorage.removeItem(item) localStorage.removeItem(item)
}) })
......
...@@ -800,6 +800,9 @@ div:focus { ...@@ -800,6 +800,9 @@ div:focus {
.amap-container { .amap-container {
// position: inherit !important; // position: inherit !important;
right: 0px; right: 0px;
.amap-copyright{
opacity: 0;
}
} }
.l7-scene { .l7-scene {
...@@ -1760,4 +1763,8 @@ div:focus { ...@@ -1760,4 +1763,8 @@ div:focus {
.el-table__fixed-right::before { .el-table__fixed-right::before {
display: none; display: none;
}
.l7-control-logo {
display: none;
} }
\ No newline at end of file
...@@ -51,12 +51,12 @@ ...@@ -51,12 +51,12 @@
> >
<el-color-picker <el-color-picker
ref="colorPicker" ref="colorPicker"
@change="colorChange"
v-model="curComponent.commonBackground.color" v-model="curComponent.commonBackground.color"
:disabled="!curComponent.commonBackground.backgroundColorSelect" :disabled="!curComponent.commonBackground.backgroundColorSelect"
size="mini" size="mini"
class="color-picker-style" class="color-picker-style"
:predefine="predefineColors" :predefine="predefineColors"
@change="colorChange"
/> />
</el-col> </el-col>
<el-col :span="3"> <el-col :span="3">
......
import { Scene, PointLayer } from '@antv/l7'
import { GaodeMap } from '@antv/l7-maps'
import { getLanguage } from '@/lang'
export function baseBubbleMapOption(chartDom, chartId, chart, action) {
const xAxis = JSON.parse(chart.xaxis)
const yAxis = JSON.parse(chart.yaxis)
let customAttr
if (chart.customAttr) {
customAttr = JSON.parse(chart.customAttr)
}
const size = customAttr.size
const color = customAttr.color
const mapStyle = `amap://styles/${color.mapStyle ? color.mapStyle : 'normal'}`
const lang = getLanguage().includes('zh') ? 'zh' : 'en'
let init = false
if (!chartDom?.map) {
try {
chartDom.destroy()
} catch (e) {
// ignore
}
chartDom = new Scene({
id: chartId,
map: new GaodeMap({
lang: lang,
// pitch: size.mapPitch,
style: mapStyle,
// style: 'dark',
center: [104.58631, 30.71882], // 成阿中心经纬度
zoom: 2.194613775109773,
maxZoom: 10
}),
logoVisible: false
})
init = true
} else {
if (chartDom.map) {
chartDom.setPitch(size.mapPitch)
chartDom.setMapStyle(mapStyle)
}
}
if (xAxis?.length < 2 || yAxis?.lang < 1) {
chartDom.removeAllLayer()
return chartDom
}
const newTableRow = chart.data.tableRow.map((item, index) => {
return {
type: 'Feature',
geometry: {
type: 'Point',
coordinates: [item[xAxis[0].dataeaseName], item[xAxis[1].dataeaseName]]
},
properties: {
capacity: item[yAxis[0].dataeaseName]
}
}
})
const mapData = { type: 'FeatureCollection', features: newTableRow }
chartDom.removeAllLayer()
.then(() => {
const pointLayer = new PointLayer({})
.source(mapData)
.shape('circle')
.size('capacity', [0, 16])
.color('capacity', color?.colors)
.active(true)
.style({
opacity: 0.5,
strokeWidth: 0
})
if (!init) {
chartDom.addLayer(pointLayer)
}
chartDom.on('loaded', () => {
chartDom.addLayer(pointLayer)
})
})
return chartDom
}
import { Scene } from '@antv/l7'
import { GaodeMap } from '@antv/l7-maps'
import { ThreeLayer, ThreeRender } from '@antv/l7-three'
import * as THREE from 'three'
import { GLTFLoader } from 'three/examples/jsm/loaders/GLTFLoader'
export function baseBuildingOptionAntV(scene, container, chart, action) {
scene = new Scene({
id: container,
map: new GaodeMap({
center: [111.4453125, 32.84267363195431],
pitch: 45,
rotation: 30,
zoom: 12
})
})
scene.on('loaded', () => {
scene.registerRenderService(ThreeRender)
const threeJSLayer = new ThreeLayer({
enableMultiPassRenderer: false,
onAddMeshes: (threeScene, layer) => {
threeScene.add(new THREE.AmbientLight(0xffffff))
const sunlight = new THREE.DirectionalLight(0xffffff, 0.25)
sunlight.position.set(0, 80000000, 100000000)
sunlight.matrixWorldNeedsUpdate = true
threeScene.add(sunlight)
const center = scene.getCenter()
const cubeGeometry = new THREE.BoxBufferGeometry(10000, 10000, 10000)
const cubeMaterial = new THREE.MeshNormalMaterial({ side: THREE.DoubleSide })
const cube = new THREE.Mesh(cubeGeometry, cubeMaterial)
layer.setObjectLngLat(cube, [center.lng + 0.05, center.lat], 0)
threeScene.add(cube)
// 使用 Three.js glTFLoader 加载模型
const loader = new GLTFLoader()
loader.load(
`${process.env.VUE_APP_BASE}/gift/dujiangyan.gltf`,
gltf => {
debugger
const gltfScene = gltf.scene
setDouble(gltfScene)
layer.adjustMeshToMap(gltfScene)
// gltfScene.scale.set(1000, 1000, 1000)
layer.setMeshScale(gltfScene, 1000, 1000, 1000)
layer.setObjectLngLat(
gltfScene,
[center.lng, center.lat],
0
)
const animations = gltf.animations
if (animations && animations.length) {
const mixer = new THREE.AnimationMixer(gltfScene)
const animation = animations[2]
const action = mixer.clipAction(animation)
action.play()
layer.addAnimateMixer(mixer)
}
// layer.setObjectLngLat(gltfScene, [center.lng + 0.05, center.lat] as ILngLat, 0)
let t = 0
setInterval(() => {
t += 0.01
layer.setObjectLngLat(
gltfScene,
[center.lng, center.lat + Math.sin(t) * 0.1],
0
)
}, 16)
// 向场景中添加模型
threeScene.add(gltfScene)
// 重绘图层
layer.render()
}
)
}
}).animate(true)
scene.addLayer(threeJSLayer)
})
function setDouble(object) {
if (object.children && object.children.length && object.children.length > 0) {
object.children.map(child => setDouble(child))
} else if (object.material) {
object.material.side = THREE.DoubleSide
}
}
// 开始渲染
if (scene) {
scene.destroy()
}
return scene
}
...@@ -35,7 +35,7 @@ export const DEFAULT_COLOR_CASE = { ...@@ -35,7 +35,7 @@ export const DEFAULT_COLOR_CASE = {
mapStyle: 'normal', mapStyle: 'normal',
mapLineGradient: false, mapLineGradient: false,
mapLineSourceColor: '#146C94', mapLineSourceColor: '#146C94',
mapLineTargetColor: '#576CBC', mapLineTargetColor: '#576CBC'
} }
export const DEFAULT_COLOR_CASE_DARK = { export const DEFAULT_COLOR_CASE_DARK = {
...@@ -57,7 +57,7 @@ export const DEFAULT_COLOR_CASE_DARK = { ...@@ -57,7 +57,7 @@ export const DEFAULT_COLOR_CASE_DARK = {
mapStyle: 'darkblue', mapStyle: 'darkblue',
mapLineGradient: false, mapLineGradient: false,
mapLineSourceColor: '#2F58CD', mapLineSourceColor: '#2F58CD',
mapLineTargetColor: '#3795BD', mapLineTargetColor: '#3795BD'
} }
export const DEFAULT_SIZE = { export const DEFAULT_SIZE = {
barDefault: true, barDefault: true,
......
import { Scene, PointLayer } from '@antv/l7'
import { GaodeMap } from '@antv/l7-maps'
import { getLanguage } from '@/lang'
export function baseCityBrightnessMapOptionAntV(chartDom, chartId, chart, action) {
// console.log('亮度===', chart)
const xAxis = JSON.parse(chart.xaxis)
const yAxis = JSON.parse(chart.yaxis)
// console.log('chart==chart.data.tableRow==', chart, chart.data.tableRow)
// console.log('xAxis,yAxis', xAxis, yAxis)
let customAttr
if (chart.customAttr) {
customAttr = JSON.parse(chart.customAttr)
}
const size = customAttr.size
const color = customAttr.color
const mapStyle = `amap://styles/${color.mapStyle ? color.mapStyle : 'normal'}`
const lang = getLanguage().includes('zh') ? 'zh' : 'en'
let init = false
if (!chartDom?.map) {
try {
chartDom.destroy()
} catch (e) {
// ignore
}
chartDom = new Scene({
id: chartId,
map: new GaodeMap({
lang: lang,
pitch: size.mapPitch,
// pitch: 64.88, // 地图倾角
style: mapStyle,
// style: 'dark'
// center: [116.41667, 39.91667], // 地图中心经纬度-北京
zoom: 12,
// maxZoom: 20
center: [114.060288, 22.53684] // 数据集是深圳市区的点,中心先设为深圳
// center: [104.58631, 30.71882] // 成阿中心经纬度
}),
logoVisible: false
})
init = true
} else {
if (chartDom.map) {
chartDom.setPitch(size.mapPitch)
chartDom.setMapStyle(mapStyle)
}
}
if (xAxis?.length < 2 || yAxis?.length < 1) {
chartDom.removeAllLayer()
return chartDom
}
const newTableRow = chart.data.tableRow.map((item, index) => {
return {
type: 'Feature',
properties: {
h8: item[yAxis[0].dataeaseName]// 0到6
},
geometry: {
type: 'Point',
coordinates: [item[xAxis[0].dataeaseName], item[xAxis[1].dataeaseName]]
},
// bbox 参数: 使用边界框(bbox)指定静态图像的整个视口
bbox: [item[xAxis[0].dataeaseName], item[xAxis[1].dataeaseName], item[xAxis[0].dataeaseName], item[xAxis[1].dataeaseName]]
}
})
const mapData = { type: 'FeatureCollection', features: newTableRow }
// console.log('mapData', mapData)
chartDom.removeAllLayer()
.then(() => {
const pointLayer = new PointLayer({})
.source(mapData)
.size(2)
.color('h8', color?.colors)
// .color('h8', [
// '#0A3663',
// '#1558AC',
// '#3771D9',
// '#4D89E5',
// '#64A5D3',
// '#72BED6',
// '#83CED6',
// '#A6E1E0',
// '#B8EFE2',
// '#D7F9F0'
// ])
if (!init) {
chartDom.addLayer(pointLayer)
}
chartDom.on('loaded', () => {
chartDom.addLayer(pointLayer)
})
})
return chartDom
}
This source diff could not be displayed because it is too large. You can view the blob instead.
import { Scene, PointLayer, PolygonLayer, LineLayer } from '@antv/l7'
import { GaodeMap } from '@antv/l7-maps'
import { getLanguage } from '@/lang'
export function baseFloatMapOption(chartDom, chartId, chart, action) {
const xAxis = JSON.parse(chart.xaxis)
let customAttr
if (chart.customAttr) {
customAttr = JSON.parse(chart.customAttr)
}
const size = customAttr.size
const color = customAttr.color
const mapStyle = `amap://styles/${color.mapStyle ? color.mapStyle : 'normal'}`
const lang = getLanguage().includes('zh') ? 'zh' : 'en'
let init = false
if (!chartDom?.map) {
try {
chartDom.destroy()
} catch (e) {
// ignore
}
chartDom = new Scene({
id: chartId,
map: new GaodeMap({
lang: lang,
pitch: size.mapPitch,
// style: mapStyle,
style: 'dark',
// pitch: 60,
// center: [104.58631, 30.71882], // 成阿中心经纬度
zoom: 6.2,
maxZoom: 10
}),
logoVisible: false
})
init = true
} else {
if (chartDom.map) {
chartDom.setPitch(size.mapPitch)
// chartDom.setMapStyle(mapStyle)
}
}
if (xAxis?.length < 3) {
chartDom.removeAllLayer()
return chartDom
}
const texts = []
const newTableRow = chart.data.tableRow.map((item, index) => {
const name = item[xAxis[0].dataeaseName]
const center = JSON.parse(item[xAxis[1].dataeaseName])
const [lng, lat] = center
texts.push({ name, lng, lat })
return {
type: 'Feature',
geometry: {
type: 'MultiPolygon',
coordinates: JSON.parse(item[xAxis[2].dataeaseName])
},
properties: {
name: item[xAxis[0].dataeaseName],
center: JSON.parse(item[xAxis[1].dataeaseName])
}
}
})
const mapData = { type: 'FeatureCollection', features: newTableRow }
const proData = { type: 'FeatureCollection', features: [newTableRow[0]] }
console.log(mapData, proData, texts)
chartDom.removeAllLayer()
.then(() => {
const textLayer = new PointLayer({ zIndex: 2 })
.source(texts, {
parser: {
type: 'json',
x: 'lng',
y: 'lat'
}
})
.shape('name', 'text')
.size(14)
.color('#0ff')
.style({
textAnchor: 'center', // 文本相对锚点的位置 center|left|right|top|bottom|top-left
spacing: 2, // 字符间距
padding: [1, 1], // 文本包围盒 padding [水平,垂直],影响碰撞检测结果,避免相邻文本靠的太近
stroke: '#0ff', // 描边颜色
strokeWidth: 0.2, // 描边宽度
raisingHeight: 200000 + 150000 + 10000,
textAllowOverlap: true
})
const lineDown = new LineLayer()
.source(mapData)
.shape('line')
.color('#0DCCFF')
.size(1)
.style({
raisingHeight: 200000
})
const lineUp = new LineLayer({ zIndex: 1 })
.source(mapData)
.shape('line')
.color('#0DCCFF')
.size(1)
.style({
raisingHeight: 200000 + 150000
})
const lineLayer = new LineLayer()
.source(proData)
.shape('wall')
.size(150000)
.style({
heightfixed: true,
opacity: 0.6,
sourceColor: '#0DCCFF',
targetColor: 'rbga(255,255,255, 0)'
})
const provincelayer = new PolygonLayer({})
.source(proData)
.size(150000)
.shape('extrude')// shape 为 extrude 几何图层用于绘制 3D 的几何体
.color('#0DCCFF')
.active({
color: 'rgb(100,230,255)'
})
.style({
heightfixed: true, // heightFixed 设置 3D 填充图的高度时候固定
pickLight: true, // pickLight 设置 3D 填充图的拾取高亮色是否计算光照。
raisingHeight: 200000,
opacity: 0.8
})
provincelayer.on('mousemove', () => {
provincelayer.style({
raisingHeight: 200000 + 100000
})
lineDown.style({
raisingHeight: 200000 + 100000
})
lineUp.style({
raisingHeight: 200000 + 150000 + 100000
})
textLayer.style({
raisingHeight: 200000 + 150000 + 10000 + 100000
})
})
provincelayer.on('unmousemove', () => {
provincelayer.style({
raisingHeight: 200000
})
lineDown.style({
raisingHeight: 200000
})
lineUp.style({
raisingHeight: 200000 + 150000
})
textLayer.style({
raisingHeight: 200000 + 150000 + 10000
})
})
if (!init) {
chartDom.addLayer(textLayer)// 地图文字
chartDom.addLayer(lineDown)// 漂浮块底部
chartDom.addLayer(lineUp)// 漂浮块顶部线
chartDom.addLayer(lineLayer)
chartDom.addLayer(provincelayer)
}
chartDom.on('loaded', () => {
chartDom.addLayer(textLayer)// 地图文字
chartDom.addLayer(lineDown)// 漂浮块底部
chartDom.addLayer(lineUp)// 漂浮块顶部线
chartDom.addLayer(lineLayer)
chartDom.addLayer(provincelayer)
})
})
return chartDom
}
import { Scene, HeatmapLayer } from '@antv/l7'
import { GaodeMap } from '@antv/l7-maps'
import { getLanguage } from '@/lang'
export function baseHeatMapOptionAntV(chartDom, chartId, chart, action) {
console.log('baseHeatMapOptionAntV', chart)
const xAxis = JSON.parse(chart.xaxis)
const yAxis = JSON.parse(chart.yaxis)
let customAttr
if (chart.customAttr) {
customAttr = JSON.parse(chart.customAttr)
}
const size = customAttr.size
const color = customAttr.color
const mapStyle = `amap://styles/${color.mapStyle ? color.mapStyle : 'normal'}`
const lang = getLanguage().includes('zh') ? 'zh' : 'en'
let init = false
if (!chartDom?.map) {
try {
chartDom.destroy()
} catch (e) {
// ignore
}
chartDom = new Scene({
id: chartId,
map: new GaodeMap({
lang: lang,
pitch: size.mapPitch,
style: mapStyle,
zoom: 3
}),
logoVisible: false
})
init = true
} else {
if (chartDom.map) {
chartDom.setPitch(size.mapPitch)
chartDom.setMapStyle(mapStyle)
}
}
if (xAxis?.length < 1 || yAxis?.length < 1) {
chartDom.removeAllLayer()
return chartDom
}
chartDom.removeAllLayer()
.then(() => {
const layer = new HeatmapLayer({})
.source(chart.data.tableRow, {
parser: {
type: 'json',
x: xAxis[0].dataeaseName,
y: xAxis[1].dataeaseName
}
})
.shape('heatmap')
.style({
intensity: 2,
radius: 20,
rampColors: {
colors: [
'#206C7C',
'#2EA9A1',
'#91EABC',
'#FFF598',
'#F7B74A',
'#FF4818'
],
positions: [0, 0.2, 0.4, 0.6, 0.8, 1.0]
}
})
.size('mag', [1, 80])
.scale('mag', {
type: 'linear',
domain: [1, 50]
})
if (!init) {
chartDom.addLayer(layer)
}
chartDom.on('loaded', () => {
chartDom.addLayer(layer)
})
})
return chartDom
}
...@@ -64,8 +64,8 @@ export async function baseFlowMapOption(chartDom, chartId, chart, action) { ...@@ -64,8 +64,8 @@ export async function baseFlowMapOption(chartDom, chartId, chart, action) {
.animate({ .animate({
enable: size.mapLineAnimate, enable: size.mapLineAnimate,
duration: size.mapLineAnimateDuration, duration: size.mapLineAnimateDuration,
interval: 1, interval: size.mapLineAnimateInterval,
trailLength: 1 trailLength: size.mapLineAnimateTrailLength
}) })
if (color.mapLineGradient) { if (color.mapLineGradient) {
lineLayer.style({ lineLayer.style({
......
import { getLabel, getLegend, getPadding, getTheme, getTooltip, getXAxis } from '@/views/chart/chart/common/common_antv'
import { Sankey } from '@antv/g2plot'
import { antVCustomColor } from '@/views/chart/chart/util'
export function baseSankeyOptionAntV(plot, container, chart, action) {
// theme
const theme = getTheme(chart)
// data
const data = chart.data.tableRow
const sankeyData = []
const valueName = chart.data.fields.find((item) => { return item.originName === 'value' })
const keys = chart.data.fields.map((v) => {
if (v.originName !== 'value') {
return v.dataeaseName
}
}).filter((i) => i)
if (data && keys.length > 0) {
data.forEach((d) => {
keys.reduce((a, b) => {
if (a && b) {
sankeyData.push({
source: d[a],
target: d[b],
value: d[valueName.dataeaseName],
path: keys.map((item) => {
const num = []
num.push(d[item])
return num
}).join('->')
})
}
return b
})
}
)
}
// options
const options = {
theme: theme,
data: sankeyData,
sourceField: 'source',
targetField: 'target',
weightField: 'value',
nodeWidthRatio: 0.01,
nodePaddingRatio: 0.03,
nodeDraggable: true,
rawFields: ['path'],
tooltip: {
fields: ['path', 'value'],
formatter: ({ path, value }) => {
return {
name: path,
value: value
}
}
}
}
// custom color
options.color = antVCustomColor(chart)
// 开始渲染
if (plot) {
plot.destroy()
}
plot = new Sankey(container, options)
// plot.off('interval:click')
// plot.on('interval:click', action)
return plot
}
import { Scene, PointLayer } from '@antv/l7'
import { GaodeMap } from '@antv/l7-maps'
import { getLanguage } from '@/lang'
export function base3DColumnOptionAntV(chartDom, chartId, chart, action) {
console.log('base3DColumnOptionAntV', chart)
const xAxis = JSON.parse(chart.xaxis)
const yAxis = JSON.parse(chart.yaxis)
let customAttr
if (chart.customAttr) {
customAttr = JSON.parse(chart.customAttr)
}
const size = customAttr.size
const color = customAttr.color
const mapStyle = `amap://styles/${color.mapStyle ? color.mapStyle : 'normal'}`
const lang = getLanguage().includes('zh') ? 'zh' : 'en'
let init = false
if (!chartDom?.map) {
try {
chartDom.destroy()
} catch (e) {
// ignore
}
chartDom = new Scene({
id: chartId,
map: new GaodeMap({
lang: lang,
pitch: size.mapPitch,
center: [104.288144, 31.239692],
style: mapStyle,
zoom: 4
}),
logoVisible: false
})
init = true
} else {
if (chartDom.map) {
chartDom.setPitch(size.mapPitch)
chartDom.setMapStyle(mapStyle)
}
}
// if (xAxis?.length < 1 || yAxis?.length < 1) {
// chartDom.removeAllLayer()
// return chartDom
// }
chartDom.removeAllLayer()
.then(() => {
const layer = new PointLayer({})
.source(chart.data.tableRow, {
parser: {
type: 'json',
x: xAxis[0].dataeaseName, // 经度
y: xAxis[1].dataeaseName // 纬度
}
})
.shape('cylinder')
.size(yAxis[0].dataeaseName, function(level) {
return [2, 2, level]
})
.animate(true)
.active(true)
.color(yAxis[0].dataeaseName, color?.colors)
if (!init) {
chartDom.addLayer(layer)
}
chartDom.on('loaded', () => {
chartDom.addLayer(layer)
})
})
return chartDom
}
<template>
<el-amap
:vid="mapId"
default-cursor="default"
/>
</template>
<script>
import { lazyAMapApiLoaderInstance } from 'vue-amap'
import { uuid } from 'vue-uuid'
import { baseAMapData, hazardLevel, calculateCenter } from './aMap/aMap'
import { log } from '@antv/g2plot/lib/utils'
export default {
props: {
chart: {
type: Object,
required: true
}
},
data() {
return {
map: {},
AMap: {},
layers: [],
text: [],
allParkList: [],
center: [116.400586, 39.903475],
mapStyle: 'amap://styles/6ee1c8252c951da095d5e4eaf9c65a1f',
zoom: 14,
mapId: uuid.v1()
}
},
watch: {
chart: {
handler(newVal, oldVal) {
// this.drawLayer()
console.log(9999)
this.initMap()
},
deep: true
}
},
mounted() {
this.initMap()
},
destroyed() {},
methods: {
initMap() {
const _this = this
lazyAMapApiLoaderInstance.load().then(() => {
const colorAttr = JSON.parse(this.chart.customAttr)
this.map = new AMap.Map(_this.mapId, {
center: this.center, // 地图中心点的经纬度位置配置
zoom: this.zoom, // 地图缩放比例配置
mapStyle: colorAttr?.color?.theme === 'dark' ? this.mapStyle : ''
})
this.drawLayer()
})
},
renderMarker(color) {
return `<div style='width: 30px;height: 30px;overflow: hidden;'>
<img style='width: 30px;filter: drop-shadow(${color} 100px 0); transform: translateX(-100px);' src='/static/svg/marker.svg'></img>
</div>`
},
drawLayer() {
const data = baseAMapData(this.chart)
this.allParkList = JSON.parse(JSON.stringify(data))
this.layers = []
data.map((item) => {
const color = item.hazardLevel.includes('#')
? item.hazardLevel
: hazardLevel[item.hazardLevel]?.color
let layer = null
let text = null
let center = []
const path = item.path ? JSON.parse(item.path) : []
if (item.areaType === '1') {
layer = new AMap.Marker({
position: new AMap.LngLat(item.longitude, item.latitude),
content: this.renderMarker(color),
offset: new AMap.Pixel(-15, -30),
zIndex: 53,
extData: {
...item
}
})
center = [item.longitude, item.latitude]
} else if (item.areaType === '2') {
layer = new AMap.Polygon({
path: path,
fillColor: color,
strokeColor: 'transparent',
fillOpacity: 0.6,
zIndex: 51,
extData: {
...item
}
})
center = calculateCenter(path)
} else if (item.areaType === '3') {
layer = new AMap.Polyline({
path: path,
borderWeight: 3,
strokeColor: color,
strokeOpacity: 1,
strokeStyle: 'solid',
zIndex: 52,
extData: {
...item
}
})
center = calculateCenter(path)
}
if (center && center.length === 2) {
text = new AMap.Text({
position: center,
anchor: 'bottom-center',
text: item.name,
offset: [0, 26],
style: { 'background-color': '#fff', 'font-size': '12px' },
extData: {
...item
}
})
}
if (layer) {
this.layers.push(layer)
this.text.push(text)
const extData = layer.getExtData()
const extTextData = text.getExtData()
layer.on('click', (obj) => {
this.parkClick(extData)
})
text.on('click', (obj) => {
this.parkClick(extTextData)
})
}
})
this.map.add([...this.layers, ...this.text])
this.map.setFitView()
},
parkClick(item) {
console.log(item)
const id = item.id
const highLightColor = '#AF24FF'
const allPolyline = this.layers
this.allParkList.forEach((it, index) => {
if (allPolyline[index]) {
const color = item.hazardLevel.includes('#')
? item.hazardLevel
: hazardLevel[item.hazardLevel]?.color
if (it.areaType === '1') {
allPolyline[index].setContent(this.renderMarker(color))
if (it.id === id) {
this.map.setCenter([item.longitude, item.latitude])
this.map.setZoom(15)
allPolyline[index].setContent(this.renderMarker(highLightColor))
}
} else {
allPolyline[index].setOptions({
[it.areaType === '3' ? 'strokeColor' : 'fillColor']: color
})
if (it.id === id) {
if (item.path && typeof item.path === 'string') {
const path = JSON.parse(item.path)
if (path[0]) {
this.map.setCenter([path[0][0], path[0][1]])
this.map.setZoom(15)
}
}
allPolyline[index].setOptions({
[it.areaType === '3' ? 'strokeColor' : 'fillColor']:
highLightColor
})
}
}
}
})
// const currentDom = document.querySelector(`#${id}`)
// currentDom?.scrollIntoView({ behavior: 'smooth' })
}
}
}
</script>
<style>
#container {
padding: 0px;
margin: 0px;
width: 100%;
height: 100%;
}
</style>
...@@ -54,6 +54,8 @@ import { baseTreemapOptionAntV } from '@/views/chart/chart/treemap/treemap_antv' ...@@ -54,6 +54,8 @@ import { baseTreemapOptionAntV } from '@/views/chart/chart/treemap/treemap_antv'
import { baseRadarOptionAntV } from '@/views/chart/chart/radar/radar_antv' import { baseRadarOptionAntV } from '@/views/chart/chart/radar/radar_antv'
import { baseWaterfallOptionAntV } from '@/views/chart/chart/waterfall/waterfall' import { baseWaterfallOptionAntV } from '@/views/chart/chart/waterfall/waterfall'
import { baseWordCloudOptionAntV } from '@/views/chart/chart/wordCloud/word_cloud' import { baseWordCloudOptionAntV } from '@/views/chart/chart/wordCloud/word_cloud'
import { baseHeatMapOptionAntV } from '@/views/chart/chart/heatMap/heat_map'
import { base3DColumnOptionAntV } from '@/views/chart/chart/threeDColumnChartMap/threeDColumn_antv'
import TitleRemark from '@/views/chart/view/TitleRemark' import TitleRemark from '@/views/chart/view/TitleRemark'
import { CHART_CONT_FAMILY_MAP, DEFAULT_TITLE_STYLE } from '@/views/chart/chart/chart' import { CHART_CONT_FAMILY_MAP, DEFAULT_TITLE_STYLE } from '@/views/chart/chart/chart'
import { baseMixOptionAntV } from '@/views/chart/chart/mix/mix_antv' import { baseMixOptionAntV } from '@/views/chart/chart/mix/mix_antv'
...@@ -61,7 +63,14 @@ import ChartTitleUpdate from './ChartTitleUpdate.vue' ...@@ -61,7 +63,14 @@ import ChartTitleUpdate from './ChartTitleUpdate.vue'
import { equalsAny } from '@/utils/StringUtils' import { equalsAny } from '@/utils/StringUtils'
import { mapState } from 'vuex' import { mapState } from 'vuex'
import { baseFlowMapOption } from '@/views/chart/chart/map/map_antv' import { baseFlowMapOption } from '@/views/chart/chart/map/map_antv'
import { baseBubbleMapOption } from '@/views/chart/chart/bubble/bubble_antv'
import { baseCityBrightnessMapOptionAntV } from '@/views/chart/chart/cityBrightness/cityBrightness_antv'
import { baseFloatMapOption } from '@/views/chart/chart/float/float_antv'
import { baseCitySweepMapOptionAntV } from '@/views/chart/chart/citySweep/citySweep_antv'
import { clear } from 'size-sensor' import { clear } from 'size-sensor'
import { baseSankeyOptionAntV } from '@/views/chart/chart/sankey/sankey_antv'
import { baseBuildingOptionAntV } from '@/views/chart/chart/building/building'
export default { export default {
name: 'ChartComponentG2', name: 'ChartComponentG2',
components: { TitleRemark, ViewTrackBar, ChartTitleUpdate }, components: { TitleRemark, ViewTrackBar, ChartTitleUpdate },
...@@ -301,14 +310,29 @@ export default { ...@@ -301,14 +310,29 @@ export default {
this.myChart = await baseFlowMapOption(this.myChart, this.chartId, chart, this.antVAction) this.myChart = await baseFlowMapOption(this.myChart, this.chartId, chart, this.antVAction)
} else if (chart.type === 'bidirectional-bar') { } else if (chart.type === 'bidirectional-bar') {
this.myChart = baseBidirectionalBarOptionAntV(this.myChart, this.chartId, chart, this.antVAction) this.myChart = baseBidirectionalBarOptionAntV(this.myChart, this.chartId, chart, this.antVAction)
} else if (chart.type === 'heat-map') {
this.myChart = baseHeatMapOptionAntV(this.myChart, this.chartId, chart, this.antVAction)
} else if (chart.type === 'bubble') {
this.myChart = baseBubbleMapOption(this.myChart, this.chartId, chart, this.antVAction)
} else if (chart.type === 'city-brightness') {
this.myChart = baseCityBrightnessMapOptionAntV(this.myChart, this.chartId, chart, this.antVAction)
} else if (chart.type === 'city-sweep') {
this.myChart = baseCitySweepMapOptionAntV(this.myChart, this.chartId, chart, this.antVAction)
} else if (chart.type === 'chart_sankey') {
this.myChart = baseSankeyOptionAntV(this.myChart, this.chartId, chart, this.antVAction)
} else if (chart.type === 'threeDColumn') {
this.myChart = base3DColumnOptionAntV(this.myChart, this.chartId, chart, this.antVAction)
} else if (chart.type === 'float') {
this.myChart = baseFloatMapOption(this.myChart, this.chartId, chart, this.antVAction)
} else if (chart.type === 'chart_building') {
this.myChart = baseBuildingOptionAntV(this.myChart, this.chartId, chart, this.antVAction)
} else { } else {
if (this.myChart) { if (this.myChart) {
this.antVRenderStatus = false this.antVRenderStatus = false
this.myChart.destroy() this.myChart.destroy()
} }
} }
if (this.myChart && !equalsAny(chart.type, 'liquid', 'flow-map', 'bubble', 'city-brightness', 'city-sweep', 'float') && this.searchCount > 0) {
if (this.myChart && !equalsAny(chart.type, 'liquid', 'flow-map') && this.searchCount > 0) {
this.myChart.options.animation = false this.myChart.options.animation = false
} }
if (this.myChart?.options?.legend) { if (this.myChart?.options?.legend) {
...@@ -441,7 +465,15 @@ export default { ...@@ -441,7 +465,15 @@ export default {
this.title_class.background = hexColorToRGBA(customStyle.background.color, customStyle.background.alpha) this.title_class.background = hexColorToRGBA(customStyle.background.color, customStyle.background.alpha)
this.borderRadius = (customStyle.background.borderRadius || 0) + 'px' this.borderRadius = (customStyle.background.borderRadius || 0) + 'px'
} }
if (this.chart.type === 'flow-map') { if (this.chart.type === 'flow-map' || this.chart.type === 'heat-map') {
this.title_class.zIndex = 4
this.title_class.position = 'absolute'
}
if (this.chart.type === 'city-brightness') {
this.title_class.zIndex = 4
this.title_class.position = 'absolute'
}
if (this.chart.type === 'city-sweep') {
this.title_class.zIndex = 4 this.title_class.zIndex = 4
this.title_class.position = 'absolute' this.title_class.position = 'absolute'
} }
......
...@@ -67,8 +67,8 @@ ...@@ -67,8 +67,8 @@
> >
{{ $t('chart.total') }} {{ $t('chart.total') }}
<span>{{ <span>{{
(chart.datasetMode === 0 && !not_support_page_dataset.includes(chart.datasourceType)) ? chart.totalItems : ((chart.data && chart.data.tableRow) ? chart.data.tableRow.length : 0) (chart.datasetMode === 0 && !not_support_page_dataset.includes(chart.datasourceType)) ? chart.totalItems : ((chart.data && chart.data.tableRow) ? chart.data.tableRow.length : 0)
}}</span> }}</span>
{{ $t('chart.items') }} {{ $t('chart.items') }}
</span> </span>
<de-pagination <de-pagination
......
export function baseAMapData(chart) {
const data = chart.data.tableRow;
const fields = chart.data.fields;
let layerData = [];
layerData = data.map((a, index) => {
const obj = {
id: index + 1,
};
fields.map((b) => {
for (const key in a) {
if (b.dataeaseName === key) {
obj[b.originName] = a[key];
}
}
});
return obj;
});
return layerData;
}
export const hazardLevel = {
0: {
text: "非重大危险源",
color: "#52c41a",
},
1: {
text: "一级危险源",
color: "#FF4D4F",
},
2: {
text: "二级危险源",
color: "#FF7A45",
},
3: {
text: "三级危险源",
color: "#FAAD14",
},
4: {
text: "四级危险源",
color: "#1890FF",
},
};
// 多边形中心点
export const calculateCenter = (lnglatarr) => {
var x = lnglatarr.map(function (a) {
return a[0];
});
var y = lnglatarr.map(function (a) {
return a[1];
});
var minX = Math.min.apply(null, x);
var maxX = Math.max.apply(null, x);
var minY = Math.min.apply(null, y);
var maxY = Math.max.apply(null, y);
const arr = [(minX + maxX) / 2, (minY + maxY) / 2];
return arr;
};
...@@ -1363,7 +1363,7 @@ ...@@ -1363,7 +1363,7 @@
/> />
</el-form-item> </el-form-item>
<el-form-item <el-form-item
v-show="false" v-show="showProperty('mapLineAnimateInterval')"
:label="$t('chart.map_line_animate_interval')" :label="$t('chart.map_line_animate_interval')"
class="form-item form-item-slider" class="form-item form-item-slider"
> >
...@@ -1376,7 +1376,7 @@ ...@@ -1376,7 +1376,7 @@
/> />
</el-form-item> </el-form-item>
<el-form-item <el-form-item
v-show="false" v-show="showProperty('mapLineAnimateTrailLength')"
:label="$t('chart.map_line_animate_trail_length')" :label="$t('chart.map_line_animate_trail_length')"
class="form-item form-item-slider" class="form-item form-item-slider"
> >
...@@ -1491,7 +1491,8 @@ export default { ...@@ -1491,7 +1491,8 @@ export default {
lineTypeOptions: [ lineTypeOptions: [
{ name: this.$t('chart.map_line_type_line'), value: 'line' }, { name: this.$t('chart.map_line_type_line'), value: 'line' },
{ name: this.$t('chart.map_line_type_arc'), value: 'arc' }, { name: this.$t('chart.map_line_type_arc'), value: 'arc' },
{ name: this.$t('chart.map_line_type_arc_3d'), value: 'arc3d' } { name: this.$t('chart.map_line_type_arc_3d'), value: 'arc3d' },
{ name: this.$t('chart.map_line_type_great_circle'), value: 'greatcircle' }
] ]
} }
}, },
......
<template> <template>
<div class="de-dataset-form"> <div class="de-dataset-form">
<div class="top" v-loading="loading"> <div
v-loading="loading"
class="top"
>
<span class="name"> <span class="name">
<i <i
class="el-icon-arrow-left" class="el-icon-arrow-left"
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
class="arrow-right" class="arrow-right"
@click="showLeft = true" @click="showLeft = true"
> >
<i class="el-icon-d-arrow-right"/> <i class="el-icon-d-arrow-right" />
</p> </p>
<div <div
v-show="showLeft" v-show="showLeft"
...@@ -172,8 +172,8 @@ ...@@ -172,8 +172,8 @@
class="data" class="data"
> >
<span class="result-num">{{ <span class="result-num">{{
`${$t('dataset.preview_show')} 1000 ${$t('dataset.preview_item')}` `${$t('dataset.preview_show')} 1000 ${$t('dataset.preview_item')}`
}}</span> }}</span>
<div class="table-grid"> <div class="table-grid">
<ux-grid <ux-grid
ref="plxTable" ref="plxTable"
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
</el-button> </el-button>
</el-row> </el-row>
</el-row> </el-row>
<el-divider/> <el-divider />
<el-row> <el-row>
<el-form :inline="true"> <el-form :inline="true">
<el-form-item <el-form-item
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
class="arrow-right" class="arrow-right"
@click="showLeft = true" @click="showLeft = true"
> >
<i class="el-icon-d-arrow-right"/> <i class="el-icon-d-arrow-right" />
</p> </p>
<div <div
v-show="showLeft" v-show="showLeft"
...@@ -179,8 +179,8 @@ ...@@ -179,8 +179,8 @@
class="data" class="data"
> >
<span class="result-num">{{ <span class="result-num">{{
`${$t('dataset.preview_show')} 1000 ${$t('dataset.preview_item')}` `${$t('dataset.preview_show')} 1000 ${$t('dataset.preview_item')}`
}}</span> }}</span>
<div class="table-grid"> <div class="table-grid">
<ux-grid <ux-grid
ref="plxTable" ref="plxTable"
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
class="arrow-right" class="arrow-right"
@click="showLeft = true" @click="showLeft = true"
> >
<i class="el-icon-d-arrow-right"/> <i class="el-icon-d-arrow-right" />
</p> </p>
<div <div
v-show="showLeft" v-show="showLeft"
...@@ -21,16 +21,16 @@ ...@@ -21,16 +21,16 @@
effect="dark" effect="dark"
placement="right" placement="right"
> >
<div slot="content"> <div slot="content">
{{ $t('dataset.excel_info_1') }}<br> {{ $t('dataset.excel_info_1') }}<br>
{{ $t('dataset.excel_info_2') }}<br> {{ $t('dataset.excel_info_2') }}<br>
{{ $t('dataset.excel_info_3') }} {{ $t('dataset.excel_info_3') }}
</div> </div>
<svg-icon icon-class="icon_info_outlined" /></el-tooltip></span> <svg-icon icon-class="icon_info_outlined" /></el-tooltip></span>
<i <i
class="el-icon-d-arrow-left" class="el-icon-d-arrow-left"
@click="showLeft = false" @click="showLeft = false"
/> />
</p> </p>
<el-upload <el-upload
:action="baseUrl + 'dataset/table/excel/upload'" :action="baseUrl + 'dataset/table/excel/upload'"
...@@ -150,14 +150,14 @@ ...@@ -150,14 +150,14 @@
min-width="200px" min-width="200px"
:field="field.fieldName" :field="field.fieldName"
:title="field.remarks" :title="field.remarks"
:fieldType="field.fieldType" :field-type="field.fieldType"
:resizable="true" :resizable="true"
> >
<template #header> <template #header>
<el-dropdown <el-dropdown
:key="field.fieldName + field.fieldType"
placement="bottom-start" placement="bottom-start"
trigger="click" trigger="click"
:key="field.fieldName + field.fieldType"
@command="(type) => handleCommand(type, field)" @command="(type) => handleCommand(type, field)"
> >
<span class="type-switch"> <span class="type-switch">
...@@ -179,7 +179,7 @@ ...@@ -179,7 +179,7 @@
icon-class="field_value" icon-class="field_value"
class="field-icon-value" class="field-icon-value"
/> />
<i class="el-icon-arrow-down el-icon--right"/></span> <i class="el-icon-arrow-down el-icon--right" /></span>
<el-dropdown-menu <el-dropdown-menu
slot="dropdown" slot="dropdown"
style="width: 178px" style="width: 178px"
...@@ -237,7 +237,7 @@ import { $alert } from '@/utils/message' ...@@ -237,7 +237,7 @@ import { $alert } from '@/utils/message'
import store from '@/store' import store from '@/store'
import msgCfm from '@/components/msgCfm/index' import msgCfm from '@/components/msgCfm/index'
import cancelMix from './cancelMix' import cancelMix from './cancelMix'
import Config from "@/settings"; import Config from '@/settings'
import { updateCacheTree } from '@/components/canvas/utils/utils' import { updateCacheTree } from '@/components/canvas/utils/utils'
const token = getToken() const token = getToken()
......
...@@ -53,8 +53,8 @@ ...@@ -53,8 +53,8 @@
<div class="sql-title"> <div class="sql-title">
{{ $t('deDataset.data_preview') }} {{ $t('deDataset.data_preview') }}
<span class="result-num">{{ <span class="result-num">{{
`(${$t('dataset.preview_show')} 1000 ${$t('dataset.preview_item')})` `(${$t('dataset.preview_show')} 1000 ${$t('dataset.preview_item')})`
}}</span> }}</span>
<span <span
class="drag" class="drag"
@mousedown="mousedownDrag" @mousedown="mousedownDrag"
...@@ -96,8 +96,8 @@ ...@@ -96,8 +96,8 @@
secondary secondary
@click="closeSelectDs()" @click="closeSelectDs()"
>{{ >{{
$t('dataset.cancel') $t('dataset.cancel')
}} }}
</deBtn> </deBtn>
<deBtn <deBtn
:disabled="!tempDs.id" :disabled="!tempDs.id"
...@@ -122,21 +122,21 @@ ...@@ -122,21 +122,21 @@
size="840px" size="840px"
direction="rtl" direction="rtl"
> >
<union-edit :union-param="unionParam"/> <union-edit :union-param="unionParam" />
<div class="de-foot"> <div class="de-foot">
<deBtn <deBtn
secondary secondary
@click="closeEditUnion()" @click="closeEditUnion()"
>{{ >{{
$t('dataset.cancel') $t('dataset.cancel')
}} }}
</deBtn> </deBtn>
<deBtn <deBtn
type="primary" type="primary"
@click="confirmEditUnion()" @click="confirmEditUnion()"
>{{ >{{
$t('dataset.confirm') $t('dataset.confirm')
}} }}
</deBtn> </deBtn>
</div> </div>
</el-drawer> </el-drawer>
......
import pyjs from 'js-pinyin' import pyjs from 'js-pinyin'
export function zh2py(str) { export function zh2py(str) {
return pyjs.getFullChars(str).toLowerCase().charCodeAt() return pyjs.getFullChars(str).toLowerCase().charCodeAt()
} }
export function pySort(arr = []) { export function pySort(arr = []) {
arr.sort((a, b) => { arr.sort((a, b) => {
return zh2py(a.name[0]) - zh2py(b.name[0]) return zh2py(a.name[0]) - zh2py(b.name[0])
}) })
return arr return arr
} }
\ No newline at end of file
...@@ -17,14 +17,14 @@ ...@@ -17,14 +17,14 @@
v-if="table.mode === 0" v-if="table.mode === 0"
class="de-tag primary" class="de-tag primary"
>{{ >{{
$t('dataset.direct_connect') $t('dataset.direct_connect')
}}</span> }}</span>
<span <span
v-if="table.mode === 1" v-if="table.mode === 1"
class="de-tag warning" class="de-tag warning"
>{{ >{{
$t('dataset.sync_data') $t('dataset.sync_data')
}}</span> }}</span>
</template> </template>
<span <span
v-if="syncStatus === 'Underway'" v-if="syncStatus === 'Underway'"
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
> >
{{ $t('dataset.dataset_sync') }} {{ $t('dataset.dataset_sync') }}
</span> </span>
<el-divider direction="vertical"/> <el-divider direction="vertical" />
<span class="create-by">{{ $t('dataset.create_by') }}</span> <span class="create-by">{{ $t('dataset.create_by') }}</span>
<span class="create-by">:{{ table.creatorName || 'N/A' }}</span> <span class="create-by">:{{ table.creatorName || 'N/A' }}</span>
<el-popover <el-popover
...@@ -48,7 +48,11 @@ ...@@ -48,7 +48,11 @@
:data="table" :data="table"
:tab-status="tabStatus" :tab-status="tabStatus"
/> />
<svg-icon slot="reference" class="detail" icon-class="icon_info_outlined" /> <svg-icon
slot="reference"
class="detail"
icon-class="icon_info_outlined"
/>
</el-popover> </el-popover>
</el-col> </el-col>
<el-col <el-col
...@@ -77,11 +81,11 @@ ...@@ -77,11 +81,11 @@
</deBtn> </deBtn>
<el-dropdown-menu slot="dropdown"> <el-dropdown-menu slot="dropdown">
<el-dropdown-item command="0"> <el-dropdown-item command="0">
<svg-icon icon-class="icon_add-entry_outlined"/> <svg-icon icon-class="icon_add-entry_outlined" />
{{ $t('dataset.excel_replace') + $t('chart.chart_data') }} {{ $t('dataset.excel_replace') + $t('chart.chart_data') }}
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item command="1"> <el-dropdown-item command="1">
<svg-icon icon-class="icon_doc-replace_outlined"/> <svg-icon icon-class="icon_doc-replace_outlined" />
{{ $t('dataset.excel_add') + $t('chart.chart_data') }} {{ $t('dataset.excel_add') + $t('chart.chart_data') }}
</el-dropdown-item> </el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
...@@ -218,7 +222,7 @@ ...@@ -218,7 +222,7 @@
> >
<div class="tree-cont"> <div class="tree-cont">
<div class="content"> <div class="content">
<rowAuth ref="rowAuth"/> <rowAuth ref="rowAuth" />
</div> </div>
</div> </div>
</el-form-item> </el-form-item>
......
...@@ -18,7 +18,7 @@ ...@@ -18,7 +18,7 @@
:label="$t('dataset.name')" :label="$t('dataset.name')"
prop="name" prop="name"
> >
<el-input v-model="datasetForm.name"/> <el-input v-model="datasetForm.name" />
</el-form-item> </el-form-item>
<el-form-item <el-form-item
:label="$t('deDataset.folder')" :label="$t('deDataset.folder')"
...@@ -45,7 +45,7 @@ ...@@ -45,7 +45,7 @@
class="custom-tree-node-dataset" class="custom-tree-node-dataset"
> >
<span v-if="data.modelInnerType === 'group'"> <span v-if="data.modelInnerType === 'group'">
<svg-icon icon-class="scene"/> <svg-icon icon-class="scene" />
</span> </span>
<span <span
style=" style="
......
...@@ -111,8 +111,8 @@ ...@@ -111,8 +111,8 @@
class="no-tdata-new" class="no-tdata-new"
@click="() => clickAdd()" @click="() => clickAdd()"
>{{ >{{
$t('deDataset.create') $t('deDataset.create')
}}</span> }}</span>
</div> </div>
<el-tree <el-tree
v-else v-else
...@@ -134,7 +134,7 @@ ...@@ -134,7 +134,7 @@
> >
<span style="display: flex; flex: 1; width: 0"> <span style="display: flex; flex: 1; width: 0">
<span> <span>
<svg-icon icon-class="scene"/> <svg-icon icon-class="scene" />
</span> </span>
<span <span
style=" style="
...@@ -242,15 +242,15 @@ ...@@ -242,15 +242,15 @@
class="de-card-dropdown" class="de-card-dropdown"
> >
<el-dropdown-item command="rename"> <el-dropdown-item command="rename">
<svg-icon icon-class="de-ds-rename"/> <svg-icon icon-class="de-ds-rename" />
{{ $t('dataset.rename') }} {{ $t('dataset.rename') }}
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item command="move"> <el-dropdown-item command="move">
<svg-icon icon-class="de-ds-move"/> <svg-icon icon-class="de-ds-move" />
{{ $t('dataset.move_to') }} {{ $t('dataset.move_to') }}
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item command="delete"> <el-dropdown-item command="delete">
<svg-icon icon-class="de-ds-trash"/> <svg-icon icon-class="de-ds-trash" />
{{ $t('dataset.delete') }} {{ $t('dataset.delete') }}
</el-dropdown-item> </el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
...@@ -353,15 +353,15 @@ ...@@ -353,15 +353,15 @@
class="de-card-dropdown" class="de-card-dropdown"
> >
<el-dropdown-item command="editTable"> <el-dropdown-item command="editTable">
<svg-icon icon-class="de-ds-rename"/> <svg-icon icon-class="de-ds-rename" />
{{ $t('dataset.rename') }} {{ $t('dataset.rename') }}
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item command="moveDs"> <el-dropdown-item command="moveDs">
<svg-icon icon-class="de-ds-move"/> <svg-icon icon-class="de-ds-move" />
{{ $t('dataset.move_to') }} {{ $t('dataset.move_to') }}
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item command="deleteTable"> <el-dropdown-item command="deleteTable">
<svg-icon icon-class="de-ds-trash"/> <svg-icon icon-class="de-ds-trash" />
{{ $t('dataset.delete') }} {{ $t('dataset.delete') }}
</el-dropdown-item> </el-dropdown-item>
</el-dropdown-menu> </el-dropdown-menu>
...@@ -434,7 +434,7 @@ ...@@ -434,7 +434,7 @@
:label="$t('dataset.name')" :label="$t('dataset.name')"
prop="name" prop="name"
> >
<el-input v-model="tableForm.name"/> <el-input v-model="tableForm.name" />
</el-form-item> </el-form-item>
</el-form> </el-form>
<div <div
...@@ -445,8 +445,8 @@ ...@@ -445,8 +445,8 @@
secondary secondary
@click="closeTable()" @click="closeTable()"
>{{ >{{
$t('dataset.cancel') $t('dataset.cancel')
}} }}
</deBtn> </deBtn>
<deBtn <deBtn
type="primary" type="primary"
...@@ -469,8 +469,8 @@ ...@@ -469,8 +469,8 @@
:title="moveDialogTitle" :title="moveDialogTitle"
class="text-overflow" class="text-overflow"
>{{ >{{
moveDialogTitle moveDialogTitle
}}</span> }}</span>
{{ $t('dataset.m2') }} {{ $t('dataset.m2') }}
</template> </template>
<group-move-selector <group-move-selector
...@@ -483,8 +483,8 @@ ...@@ -483,8 +483,8 @@
secondary secondary
@click="closeMoveGroup()" @click="closeMoveGroup()"
>{{ >{{
$t('dataset.cancel') $t('dataset.cancel')
}} }}
</deBtn> </deBtn>
<deBtn <deBtn
:disabled="groupMoveConfirmDisabled" :disabled="groupMoveConfirmDisabled"
...@@ -508,8 +508,8 @@ ...@@ -508,8 +508,8 @@
:title="moveDialogTitle" :title="moveDialogTitle"
class="text-overflow" class="text-overflow"
>{{ >{{
moveDialogTitle moveDialogTitle
}}</span> }}</span>
{{ $t('dataset.m2') }} {{ $t('dataset.m2') }}
</template> </template>
<group-move-selector <group-move-selector
...@@ -521,8 +521,8 @@ ...@@ -521,8 +521,8 @@
secondary secondary
@click="closeMoveDs()" @click="closeMoveDs()"
>{{ >{{
$t('dataset.cancel') $t('dataset.cancel')
}} }}
</deBtn> </deBtn>
<deBtn <deBtn
:disabled="dsMoveConfirmDisabled" :disabled="dsMoveConfirmDisabled"
...@@ -534,7 +534,7 @@ ...@@ -534,7 +534,7 @@
</el-drawer> </el-drawer>
<!-- 新增数据集文件夹 --> <!-- 新增数据集文件夹 -->
<CreatDsGroup ref="CreatDsGroup"/> <CreatDsGroup ref="CreatDsGroup" />
</el-col> </el-col>
</template> </template>
...@@ -890,8 +890,7 @@ export default { ...@@ -890,8 +890,7 @@ export default {
_this.expandedArray.push(table.sceneId) _this.expandedArray.push(table.sceneId)
_this.$refs.datasetTreeRef.setCurrentKey(table.id) _this.$refs.datasetTreeRef.setCurrentKey(table.id)
const renameNode = { id: table.id, name: table.name, label: table.name } const renameNode = { id: table.id, name: table.name, label: table.name }
updateCacheTree('rename', 'dataset-tree', renameNode, this.tData) updateCacheTree('rename', 'dataset-tree', renameNode, this.tData)('rename', 'dataset-tree', response.data, this.tData)
('rename', 'dataset-tree', response.data, this.tData)
this.$emit('switchComponent', { name: '' }) this.$emit('switchComponent', { name: '' })
}) })
} else { } else {
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
> >
<span style="display: flex; flex: 1; width: 0"> <span style="display: flex; flex: 1; width: 0">
<span v-if="data.modelInnerType === 'group'"> <span v-if="data.modelInnerType === 'group'">
<svg-icon icon-class="scene"/> <svg-icon icon-class="scene" />
</span> </span>
<span <span
style=" style="
......
...@@ -178,7 +178,7 @@ export default { ...@@ -178,7 +178,7 @@ export default {
}, },
computed: { computed: {
origin() { origin() {
return window.location.origin return process.env.VUE_APP_BASE
} }
}, },
created() { created() {
......
...@@ -202,7 +202,7 @@ ...@@ -202,7 +202,7 @@
<div <div
v-if="showFoot" v-if="showFoot"
class="dynamic-login-foot" class="dynamic-login-foot"
v-html="footContent" v-html="$xss(footContent)"
/> />
</div> </div>
</template> </template>
......
...@@ -77,7 +77,7 @@ ...@@ -77,7 +77,7 @@
:label="dialogTitleLabel" :label="dialogTitleLabel"
prop="name" prop="name"
> >
<el-input v-model="templateEditForm.name"/> <el-input v-model="templateEditForm.name" />
</el-form-item> </el-form-item>
<el-form-item <el-form-item
:label="$t('app_template.app_group_icon')" :label="$t('app_template.app_group_icon')"
...@@ -95,7 +95,7 @@ ...@@ -95,7 +95,7 @@
:http-request="upload" :http-request="upload"
:file-list="fileList" :file-list="fileList"
> >
<i class="el-icon-plus"/> <i class="el-icon-plus" />
</el-upload> </el-upload>
<el-dialog <el-dialog
top="25vh" top="25vh"
...@@ -161,8 +161,7 @@ ...@@ -161,8 +161,7 @@
:source-template-info="currentMoveItem" :source-template-info="currentMoveItem"
@closeDialog="moveItemDialogShow=false" @closeDialog="moveItemDialogShow=false"
@templateMoveClose="templateMoveClose" @templateMoveClose="templateMoveClose"
> />
</template-move-list>
</el-dialog> </el-dialog>
</div> </div>
</template> </template>
......
...@@ -29,18 +29,18 @@ ...@@ -29,18 +29,18 @@
trigger="click" trigger="click"
@command="handleCommand" @command="handleCommand"
> >
<i class="el-icon-more"/> <i class="el-icon-more" />
<el-dropdown-menu <el-dropdown-menu
slot="dropdown" slot="dropdown"
class="de-card-dropdown" class="de-card-dropdown"
> >
<slot> <slot>
<el-dropdown-item command="update"> <el-dropdown-item command="update">
<i class="el-icon-edit"/> <i class="el-icon-edit" />
{{ $t('commons.update') }} {{ $t('commons.update') }}
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item command="delete"> <el-dropdown-item command="delete">
<i class="el-icon-delete"/> <i class="el-icon-delete" />
{{ $t('commons.uninstall') }} {{ $t('commons.uninstall') }}
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item <el-dropdown-item
......
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
@command="(type) => clickMore(type, ele)" @command="(type) => clickMore(type, ele)"
> >
<span class="el-dropdown-link"> <span class="el-dropdown-link">
<i class="el-icon-more"/> <i class="el-icon-more" />
</span> </span>
<el-dropdown-menu <el-dropdown-menu
slot="dropdown" slot="dropdown"
......
...@@ -43,16 +43,16 @@ ...@@ -43,16 +43,16 @@
secondary secondary
@click="cancel()" @click="cancel()"
>{{ >{{
$t('commons.cancel') $t('commons.cancel')
}} }}
</deBtn> </deBtn>
<deBtn <deBtn
type="primary" type="primary"
@click="save()"
:disabled="!activeTemplate" :disabled="!activeTemplate"
@click="save()"
>{{ >{{
$t('commons.confirm') $t('commons.confirm')
}} }}
</deBtn> </deBtn>
</el-row> </el-row>
</div> </div>
......
...@@ -165,12 +165,12 @@ ...@@ -165,12 +165,12 @@
v-show=" show &&showIndex===1" v-show=" show &&showIndex===1"
:canvas-id="canvasId" :canvas-id="canvasId"
/> />
<subject-setting v-show=" show &&showIndex===2"/> <subject-setting v-show=" show &&showIndex===2" />
<assist-component v-show=" show &&showIndex===3"/> <assist-component v-show=" show &&showIndex===3" />
</div> </div>
</el-drawer> </el-drawer>
<!--PC端画布区域--> <!--PC端画布区域-->
<canvas-opt-bar v-if="!previewVisible&&!mobileLayoutStatus"/> <canvas-opt-bar v-if="!previewVisible&&!mobileLayoutStatus" />
<de-canvas <de-canvas
v-if="!previewVisible&&!mobileLayoutStatus" v-if="!previewVisible&&!mobileLayoutStatus"
ref="canvasMainRef" ref="canvasMainRef"
...@@ -196,7 +196,7 @@ ...@@ -196,7 +196,7 @@
:style="customCanvasMobileStyle" :style="customCanvasMobileStyle"
class="this_mobile_canvas" class="this_mobile_canvas"
> >
<el-row class="this_mobile_canvas_top"/> <el-row class="this_mobile_canvas_top" />
<el-row class="this_mobile_canvas_inner_top"> <el-row class="this_mobile_canvas_inner_top">
{{ panelInfo.name }} {{ panelInfo.name }}
</el-row> </el-row>
...@@ -206,7 +206,7 @@ ...@@ -206,7 +206,7 @@
class="this_mobile_canvas_main" class="this_mobile_canvas_main"
:style="mobileCanvasStyle" :style="mobileCanvasStyle"
> >
<canvas-opt-bar v-if="!previewVisible&&mobileLayoutStatus"/> <canvas-opt-bar v-if="!previewVisible&&mobileLayoutStatus" />
<de-canvas <de-canvas
v-if="!previewVisible&&mobileLayoutStatus" v-if="!previewVisible&&mobileLayoutStatus"
ref="canvasMainRef" ref="canvasMainRef"
...@@ -245,14 +245,14 @@ ...@@ -245,14 +245,14 @@
/> />
</el-col> </el-col>
</el-row> </el-row>
<el-row class="this_mobile_canvas_bottom"/> <el-row class="this_mobile_canvas_bottom" />
</div> </div>
</el-col> </el-col>
<el-col <el-col
:span="16" :span="16"
class="this_mobile_canvas_cell this_mobile_canvas_wait_cell" class="this_mobile_canvas_cell this_mobile_canvas_wait_cell"
> >
<component-wait/> <component-wait />
</el-col> </el-col>
</el-row> </el-row>
</de-main-container> </de-main-container>
...@@ -270,7 +270,7 @@ ...@@ -270,7 +270,7 @@
/> />
</div> </div>
<div v-if="showBatchViewToolsAside"> <div v-if="showBatchViewToolsAside">
<chart-style-batch-set/> <chart-style-batch-set />
</div> </div>
<div v-if="!showViewToolsAside&&!showBatchViewToolsAside"> <div v-if="!showViewToolsAside&&!showBatchViewToolsAside">
<el-row style="height: 40px"> <el-row style="height: 40px">
...@@ -289,7 +289,7 @@ ...@@ -289,7 +289,7 @@
>{{ $t('panel.position_adjust') }}</span> >{{ $t('panel.position_adjust') }}</span>
</el-row> </el-row>
<el-row> <el-row>
<position-adjust v-if="curComponent&&!curComponent.auxiliaryMatrix"/> <position-adjust v-if="curComponent&&!curComponent.auxiliaryMatrix" />
<div <div
v-else v-else
class="view-selected-message-class" class="view-selected-message-class"
...@@ -431,8 +431,8 @@ ...@@ -431,8 +431,8 @@
<span style="float: right;"> <span style="float: right;">
<span class="adapt-text"> 样式适配: </span> <span class="adapt-text"> 样式适配: </span>
<el-select <el-select
style="width: 120px;margin-right: 16px"
v-model="multiplexingStyleAdaptSelf" v-model="multiplexingStyleAdaptSelf"
style="width: 120px;margin-right: 16px"
placeholder="Select" placeholder="Select"
placement="top-start" placement="top-start"
size="mini" size="mini"
...@@ -555,7 +555,7 @@ import TextAttr from '@/components/canvas/components/TextAttr' ...@@ -555,7 +555,7 @@ import TextAttr from '@/components/canvas/components/TextAttr'
import { userLoginInfo } from '@/api/systemInfo/userLogin' import { userLoginInfo } from '@/api/systemInfo/userLogin'
import { activeWatermark } from '@/components/canvas/tools/watermark' import { activeWatermark } from '@/components/canvas/tools/watermark'
import PositionAdjust from '@/views/chart/view/PositionAdjust' import PositionAdjust from '@/views/chart/view/PositionAdjust'
import {hexColorToRGBA} from "@/views/chart/chart/util"; import { hexColorToRGBA } from '@/views/chart/chart/util'
export default { export default {
name: 'PanelEdit', name: 'PanelEdit',
components: { components: {
...@@ -652,7 +652,7 @@ export default { ...@@ -652,7 +652,7 @@ export default {
{ label: '适应新主题', value: true }, { label: '适应新主题', value: true },
{ label: '保持源样式', value: false } { label: '保持源样式', value: false }
], ],
multiplexingStyleAdaptSelf : true multiplexingStyleAdaptSelf: true
} }
}, },
...@@ -776,7 +776,7 @@ export default { ...@@ -776,7 +776,7 @@ export default {
curCanvasScaleSelf() { curCanvasScaleSelf() {
return this.curCanvasScaleMap[this.canvasId] return this.curCanvasScaleMap[this.canvasId]
}, },
selectComponentCount(){ selectComponentCount() {
return Object.keys(this.curMultiplexingComponents).length return Object.keys(this.curMultiplexingComponents).length
}, },
...mapState([ ...mapState([
...@@ -1476,8 +1476,8 @@ export default { ...@@ -1476,8 +1476,8 @@ export default {
this.$store.commit('recordSnapshot') this.$store.commit('recordSnapshot')
this.$store.commit('canvasChange') this.$store.commit('canvasChange')
}, },
multiplexingStyleAdaptChange(value){ multiplexingStyleAdaptChange(value) {
this.$store.commit('setMultiplexingStyleAdapt',value) this.$store.commit('setMultiplexingStyleAdapt', value)
} }
} }
} }
......
...@@ -302,7 +302,7 @@ ...@@ -302,7 +302,7 @@
clearable clearable
/> />
<div class="field-height"> <div class="field-height">
<el-divider/> <el-divider />
<draggable <draggable
v-model="linkJumpInfoArray" v-model="linkJumpInfoArray"
:options="{group:{name: 'drag',pull:'clone'},sort: true}" :options="{group:{name: 'drag',pull:'clone'},sort: true}"
......
...@@ -174,7 +174,7 @@ ...@@ -174,7 +174,7 @@
/> />
</span> </span>
<span v-if="data.nodeType === 'folder'"> <span v-if="data.nodeType === 'folder'">
<svg-icon icon-class="scene"/> <svg-icon icon-class="scene" />
</span> </span>
<span <span
:class="data.status" :class="data.status"
...@@ -211,7 +211,7 @@ ...@@ -211,7 +211,7 @@
<el-dropdown-item <el-dropdown-item
:command="beforeClickEdit('folder', 'new', data, node)" :command="beforeClickEdit('folder', 'new', data, node)"
> >
<svg-icon icon-class="scene"/> <svg-icon icon-class="scene" />
<span style="margin-left: 5px">{{ $t('panel.groupAdd') }}</span> <span style="margin-left: 5px">{{ $t('panel.groupAdd') }}</span>
</el-dropdown-item> </el-dropdown-item>
<el-dropdown-item <el-dropdown-item
...@@ -334,7 +334,7 @@ ...@@ -334,7 +334,7 @@
:label="$t('commons.name')" :label="$t('commons.name')"
prop="name" prop="name"
> >
<el-input v-model="groupForm.name"/> <el-input v-model="groupForm.name" />
</el-form-item> </el-form-item>
</el-form> </el-form>
<div <div
...@@ -345,8 +345,8 @@ ...@@ -345,8 +345,8 @@
size="mini" size="mini"
@click="close()" @click="close()"
>{{ >{{
$t('panel.cancel') $t('panel.cancel')
}} }}
</el-button> </el-button>
<el-button <el-button
type="primary" type="primary"
...@@ -422,8 +422,8 @@ ...@@ -422,8 +422,8 @@
size="mini" size="mini"
@click="closeMoveGroup()" @click="closeMoveGroup()"
>{{ >{{
$t('dataset.cancel') $t('dataset.cancel')
}} }}
</el-button> </el-button>
<el-button <el-button
:disabled="groupMoveConfirmDisabled" :disabled="groupMoveConfirmDisabled"
...@@ -591,8 +591,9 @@ export default { ...@@ -591,8 +591,9 @@ export default {
? this.defaultData.slice(0, 3) ? this.defaultData.slice(0, 3)
: this.defaultData : this.defaultData
}, },
...mapState(['nowPanelTrackInfo']) ...mapState(['nowPanelTrackInfo', 'user'])
}, },
// ...mapState('user'),
watch: { watch: {
// 切换展示页面后 重新点击一下当前节点 // 切换展示页面后 重新点击一下当前节点
'$store.state.panel.mainActiveName': function(newVal, oldVal) { '$store.state.panel.mainActiveName': function(newVal, oldVal) {
...@@ -895,14 +896,16 @@ export default { ...@@ -895,14 +896,16 @@ export default {
}, },
tree(cache = false) { tree(cache = false) {
const modelInfo = localStorage.getItem('panel-main-tree') const modelInfo = localStorage.getItem('panel-main-tree')
const { username } = this.user.user
const userCache = modelInfo && cache const userCache = modelInfo && cache
if (userCache) { if (userCache) {
this.tData = JSON.parse(modelInfo) this.tData = JSON.parse(modelInfo)
?.filter(item => item.createBy === username) // 只显示创建人的数据
} }
groupTree(this.groupForm, !userCache).then((res) => { groupTree(this.groupForm, !userCache).then((res) => {
localStorage.setItem('panel-main-tree', JSON.stringify(res.data || [])) localStorage.setItem('panel-main-tree', JSON.stringify(res.data || []))
if (!userCache) { if (!userCache) {
this.tData = res.data || [] this.tData = res.data?.filter(item => item.createBy === username) || [] // 只显示创建人的数据
} }
if (this.responseSource === 'appApply') { if (this.responseSource === 'appApply') {
this.fromAppActive() this.fromAppActive()
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
@tab-click="handleClick" @tab-click="handleClick"
> >
<el-tab-pane name="PanelList"> <el-tab-pane name="PanelList">
<span slot="label"><i class="el-icon-document tablepanel-i"/>{{ $t('panel.panel_list') }}</span> <span slot="label"><i class="el-icon-document tablepanel-i" />{{ $t('panel.panel_list') }}</span>
<panel-list <panel-list
v-show="activeName==='PanelList'" v-show="activeName==='PanelList'"
ref="panelList" ref="panelList"
...@@ -18,14 +18,14 @@ ...@@ -18,14 +18,14 @@
name="panels_star" name="panels_star"
:lazy="true" :lazy="true"
> >
<span slot="label"><i class="el-icon-star-off tablepanel-i"/>{{ $t('panel.store') }}</span> <span slot="label"><i class="el-icon-star-off tablepanel-i" />{{ $t('panel.store') }}</span>
<enshrine v-if="activeName==='panels_star'"/> <enshrine v-if="activeName==='panels_star'" />
</el-tab-pane> </el-tab-pane>
<el-tab-pane <el-tab-pane
name="panels_share" name="panels_share"
:lazy="true" :lazy="true"
> >
<span slot="label"><i class="el-icon-share tablepanel-i"/>{{ $t('panel.share') }}</span> <span slot="label"><i class="el-icon-share tablepanel-i" />{{ $t('panel.share') }}</span>
<share-tree <share-tree
v-if="showShare" v-if="showShare"
ref="share_tree" ref="share_tree"
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
style="border-bottom: 1px solid;border-bottom-color:#E6E6E6;" style="border-bottom: 1px solid;border-bottom-color:#E6E6E6;"
> >
<div style="height: 100%;"> <div style="height: 100%;">
<share-head/> <share-head />
</div> </div>
</el-row> </el-row>
<el-row <el-row
...@@ -31,10 +31,13 @@ ...@@ -31,10 +31,13 @@
:span="12" :span="12"
style="font-size: 14px;display: flex" style="font-size: 14px;display: flex"
> >
<div :title="showName" style="text-overflow:ellipsis;overflow: hidden;white-space: nowrap;font-size: 14px;max-width: 300px"><span <div
class="panel-name" :title="showName"
> style="text-overflow:ellipsis;overflow: hidden;white-space: nowrap;font-size: 14px;max-width: 300px"
{{ panelInfo.name || '测试仪表板' }}</span> ><span
class="panel-name"
>
{{ panelInfo.name || '测试仪表板' }}</span>
<span <span
v-if="panelInfo.isDefault" v-if="panelInfo.isDefault"
style="color: green;font-size: 12px" style="color: green;font-size: 12px"
...@@ -49,41 +52,47 @@ ...@@ -49,41 +52,47 @@
v-if="!hasStar && panelInfo && showType !== 1&&panelInfo.status==='publish'" v-if="!hasStar && panelInfo && showType !== 1&&panelInfo.status==='publish'"
style="margin-left: 9px" style="margin-left: 9px"
> >
<el-tooltip :content="$t('panel.store')"> <el-tooltip :content="$t('panel.store')">
<i <i
class="el-icon-star-off" class="el-icon-star-off"
@click="star" @click="star"
/> />
</el-tooltip> </el-tooltip>
</span> </span>
<span <span
v-if="hasStar && panelInfo && showType !== 1&&panelInfo.status==='publish'" v-if="hasStar && panelInfo && showType !== 1&&panelInfo.status==='publish'"
style="margin-left: 9px" style="margin-left: 9px"
> >
<el-tooltip :content="$t('commons.cancel') + $t('panel.store')"> <el-tooltip :content="$t('commons.cancel') + $t('panel.store')">
<i <i
class="el-icon-star-on" class="el-icon-star-on"
@click="unstar" @click="unstar"
/> />
</el-tooltip> </el-tooltip>
</span> </span>
<template v-if="panelInfo.creatorName"> <template v-if="panelInfo.creatorName">
<el-divider <el-divider
style="margin: 0 16px;" style="margin: 0 16px;"
direction="vertical" direction="vertical"
/> />
<span :title="panelInfo.creatorName" class="panel-create"> <span
{{ $t('panel.create_by') + ':' + panelInfo.creatorName }} :title="panelInfo.creatorName"
</span> class="panel-create"
>
{{ $t('panel.create_by') + ':' + panelInfo.creatorName }}
</span>
</template> </template>
<el-popover <el-popover
placement="right-start" placement="right-start"
width="400" width="400"
trigger="click" trigger="click"
> >
<panel-detail-info/> <panel-detail-info />
<svg-icon slot="reference" style="margin-left: 4px;cursor: pointer;font-size: 14px;" class="icon-class" <svg-icon
icon-class="icon_info_outlined" slot="reference"
style="margin-left: 4px;cursor: pointer;font-size: 14px;"
class="icon-class"
icon-class="icon_info_outlined"
/> />
</el-popover> </el-popover>
</div> </div>
...@@ -436,14 +445,14 @@ export default { ...@@ -436,14 +445,14 @@ export default {
} }
}, },
computed: { computed: {
showName(){ showName() {
let name = this.panelInfo.name || '测试仪表板' let name = this.panelInfo.name || '测试仪表板'
if(this.panelInfo.isDefault){ if (this.panelInfo.isDefault) {
name = name +'('+ this.$t('panel.default_panel_name') +':'+ this.panelInfo.defaultPanelName +')' name = name + '(' + this.$t('panel.default_panel_name') + ':' + this.panelInfo.defaultPanelName + ')'
} }
if(this.panelInfo.sourcePanelName){ if (this.panelInfo.sourcePanelName) {
name = name +'('+ this.$t('panel.source_panel_name') +':'+ this.panelInfo.sourcePanelName +')' name = name + '(' + this.$t('panel.source_panel_name') + ':' + this.panelInfo.sourcePanelName + ')'
} }
return name return name
}, },
......
...@@ -47,7 +47,7 @@ ...@@ -47,7 +47,7 @@
@command="(type) => clickMore(type, ele)" @command="(type) => clickMore(type, ele)"
> >
<span class="el-dropdown-link"> <span class="el-dropdown-link">
<i class="el-icon-more"/> <i class="el-icon-more" />
</span> </span>
<el-dropdown-menu <el-dropdown-menu
slot="dropdown" slot="dropdown"
......
...@@ -37,23 +37,34 @@ ...@@ -37,23 +37,34 @@
</el-tab-pane> </el-tab-pane>
<!--query 参数--> <!--query 参数-->
<el-tab-pane :label="$t('datasource.query_param')" name="parameters"> <el-tab-pane
<el-tooltip class="item-tabs" effect="dark" :content="$t('datasource.query_info')" :label="$t('datasource.query_param')"
placement="top-start" slot="label"> name="parameters"
<span>{{ $t('datasource.query_param') }} >
<div class="el-step__icon is-text ms-api-col ms-header" v-if="request.arguments.length>1"> <el-tooltip
<div class="el-step__icon-inner">{{ request.arguments.length - 1 }}</div> slot="label"
</div> class="item-tabs"
</span> effect="dark"
:content="$t('datasource.query_info')"
placement="top-start"
>
<span>{{ $t('datasource.query_param') }}
<div
v-if="request.arguments.length>1"
class="el-step__icon is-text ms-api-col ms-header"
>
<div class="el-step__icon-inner">{{ request.arguments.length - 1 }}</div>
</div>
</span>
</el-tooltip> </el-tooltip>
<api-variable <api-variable
@editScenarioAdvance="editScenarioAdvance"
:scenario-definition="scenarioDefinition" :scenario-definition="scenarioDefinition"
v-if="activeName === 'parameters'"
:with-more-setting="true" :with-more-setting="true"
:is-read-only="isReadOnly" :is-read-only="isReadOnly"
:isShowEnable="isShowEnable" :is-show-enable="isShowEnable"
:parameters="request.arguments" :parameters="request.arguments"
v-if="activeName === 'parameters'" @editScenarioAdvance="editScenarioAdvance"
/> />
</el-tab-pane> </el-tab-pane>
......
...@@ -800,7 +800,7 @@ export default { ...@@ -800,7 +800,7 @@ export default {
data.request = JSON.stringify(data.request) data.request = JSON.stringify(data.request)
this.loading = true this.loading = true
this.disabledNext = true this.disabledNext = true
checkApiDatasource({'data': Base64.encode(JSON.stringify(data))}).then(res => { checkApiDatasource({ 'data': Base64.encode(JSON.stringify(data)) }).then(res => {
this.loading = false this.loading = false
this.disabledNext = false this.disabledNext = false
this.apiItem.status = 'Success' this.apiItem.status = 'Success'
...@@ -858,7 +858,7 @@ export default { ...@@ -858,7 +858,7 @@ export default {
const data = JSON.parse(JSON.stringify(this.apiItem)) const data = JSON.parse(JSON.stringify(this.apiItem))
data.request = JSON.stringify(data.request) data.request = JSON.stringify(data.request)
this.loading = true this.loading = true
checkApiDatasource({'data': Base64.encode(JSON.stringify(data))}).then(res => { checkApiDatasource({ 'data': Base64.encode(JSON.stringify(data)) }).then(res => {
this.loading = false this.loading = false
this.$success(i18n.t('commons.success')) this.$success(i18n.t('commons.success'))
this.apiItem.fields = res.data.fields this.apiItem.fields = res.data.fields
......
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论