|
@@ -1,5 +1,22 @@
|
|
<template>
|
|
<template>
|
|
<div class="chartTheme-page">
|
|
<div class="chartTheme-page">
|
|
|
|
+ <!-- 全局配置 -->
|
|
|
|
+ <div class="setting-box" v-if="permissionBtn.isShowBtn('chartThemePermission','chartTheme_chartsource')">
|
|
|
|
+ <div class="setting-item">
|
|
|
|
+ <span>
|
|
|
|
+ {{$t('SystemManage.ChartSet.label00')}}
|
|
|
|
+ <el-tooltip class="item" effect="dark" :content="$t('SystemManage.ChartSet.label00_hint')" placement="top">
|
|
|
|
+ <i class="el-icon-warning"></i>
|
|
|
|
+ </el-tooltip>
|
|
|
|
+ </span>
|
|
|
|
+ <el-switch
|
|
|
|
+ @change="saveSetting"
|
|
|
|
+ v-model="ChartSourceDisplay"
|
|
|
|
+ active-value="true"
|
|
|
|
+ inactive-value="false"/>
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+
|
|
<div class="header">
|
|
<div class="header">
|
|
<div style="display: flex;gap:20px;">
|
|
<div style="display: flex;gap:20px;">
|
|
<div class="select-item">
|
|
<div class="select-item">
|
|
@@ -30,7 +47,9 @@
|
|
|
|
|
|
<el-button type="primary" v-permission="permissionBtn.chartThemePermission.chartTheme_edit" @click="setConfigTheme">{{$t('Dialog.confirm_save_btn')}}</el-button>
|
|
<el-button type="primary" v-permission="permissionBtn.chartThemePermission.chartTheme_edit" @click="setConfigTheme">{{$t('Dialog.confirm_save_btn')}}</el-button>
|
|
</div>
|
|
</div>
|
|
-
|
|
|
|
|
|
+ <div class="gap-box">
|
|
|
|
+ <span style="flex:1;background-color: #C8CDD9;"></span>
|
|
|
|
+ </div>
|
|
<!-- 主题列表 -->
|
|
<!-- 主题列表 -->
|
|
<div class="main">
|
|
<div class="main">
|
|
<ul class="list-wrap">
|
|
<ul class="list-wrap">
|
|
@@ -61,7 +80,6 @@
|
|
|
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
-
|
|
|
|
<!-- 弹窗 -->
|
|
<!-- 弹窗 -->
|
|
<m-dialog
|
|
<m-dialog
|
|
:title="`${addThemeForm.id?$t('SystemManage.ChartSet.edit_btn'):$t('SystemManage.ChartSet.edit_btn')}`"
|
|
:title="`${addThemeForm.id?$t('SystemManage.ChartSet.edit_btn'):$t('SystemManage.ChartSet.edit_btn')}`"
|
|
@@ -94,6 +112,7 @@
|
|
</template>
|
|
</template>
|
|
<script>
|
|
<script>
|
|
import * as chartThemeInterface from '@/api/modules/chartThemeApi';
|
|
import * as chartThemeInterface from '@/api/modules/chartThemeApi';
|
|
|
|
+import {etaBaseConfigInterence} from '@/api/modules/etaBaseConfigApi.js';
|
|
import mDialog from '@/components/mDialog.vue';
|
|
import mDialog from '@/components/mDialog.vue';
|
|
export default {
|
|
export default {
|
|
components: { mDialog },
|
|
components: { mDialog },
|
|
@@ -110,10 +129,13 @@ export default {
|
|
isOpenThemeDia: false,
|
|
isOpenThemeDia: false,
|
|
addThemeForm: {
|
|
addThemeForm: {
|
|
themeName: '',
|
|
themeName: '',
|
|
- }
|
|
|
|
|
|
+ },
|
|
|
|
+ ChartSourceDisplay:'true',
|
|
|
|
+ baseConfig:{}
|
|
};
|
|
};
|
|
},
|
|
},
|
|
mounted() {
|
|
mounted() {
|
|
|
|
+ this.getChartBaseSetting()
|
|
this.getChartType()
|
|
this.getChartType()
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
@@ -197,6 +219,23 @@ export default {
|
|
this.isOpenThemeDia = false;
|
|
this.isOpenThemeDia = false;
|
|
|
|
|
|
this.getThemeList()
|
|
this.getThemeList()
|
|
|
|
+ },
|
|
|
|
+ async getChartBaseSetting(){
|
|
|
|
+ //目前是用基本配置的接口,后续有多个配置再改
|
|
|
|
+ const res = await etaBaseConfigInterence.getBaseConfig()
|
|
|
|
+ if(res.Ret!==200) return
|
|
|
|
+ const {ChartSourceDisplay} = res.Data||{}
|
|
|
|
+ this.baseConfig = res.Data
|
|
|
|
+ this.ChartSourceDisplay = ChartSourceDisplay||'true'
|
|
|
|
+ },
|
|
|
|
+ async saveSetting(){
|
|
|
|
+ etaBaseConfigInterence.saveBaseConfig({
|
|
|
|
+ ...this.baseConfig,
|
|
|
|
+ ChartSourceDisplay:this.ChartSourceDisplay
|
|
|
|
+ }).then(res=>{
|
|
|
|
+ if(res.Ret!==200) return
|
|
|
|
+ this.$message.success(this.$t('MsgPrompt.saved_msg'))
|
|
|
|
+ })
|
|
}
|
|
}
|
|
},
|
|
},
|
|
};
|
|
};
|
|
@@ -210,22 +249,36 @@ export default {
|
|
display: flex;
|
|
display: flex;
|
|
align-items: center;
|
|
align-items: center;
|
|
}
|
|
}
|
|
- .header,.main {
|
|
|
|
|
|
+ .header,.main,.setting-box {
|
|
padding: 20px 30px;
|
|
padding: 20px 30px;
|
|
background: #fff;
|
|
background: #fff;
|
|
position: relative;
|
|
position: relative;
|
|
border: 1px solid #ececec;
|
|
border: 1px solid #ececec;
|
|
border-radius: 4px;
|
|
border-radius: 4px;
|
|
- box-shadow: 0 3px 6px rgba(0, 0, 0, 0.05);
|
|
|
|
|
|
+ /* box-shadow: 0 3px 6px rgba(0, 0, 0, 0.05); */
|
|
}
|
|
}
|
|
.header {
|
|
.header {
|
|
display: flex;
|
|
display: flex;
|
|
justify-content: space-between;
|
|
justify-content: space-between;
|
|
- margin-bottom: 30px;
|
|
|
|
|
|
+ /* margin-bottom: 30px; */
|
|
gap: 20px;
|
|
gap: 20px;
|
|
|
|
+ border-bottom: none;
|
|
|
|
+ border-bottom-left-radius: 0;
|
|
|
|
+ border-bottom-right-radius: 0;
|
|
|
|
+ }
|
|
|
|
+ .gap-box{
|
|
|
|
+ border-left: 1px solid #ececec;
|
|
|
|
+ border-right: 1px solid #ececec;
|
|
|
|
+ height:1px;
|
|
|
|
+ background-color: white;
|
|
|
|
+ display: flex;
|
|
|
|
+ padding:0 30px;
|
|
}
|
|
}
|
|
.main {
|
|
.main {
|
|
min-height: calc(100vh - 240px);
|
|
min-height: calc(100vh - 240px);
|
|
|
|
+ border-top: none;
|
|
|
|
+ border-top-right-radius: 0;
|
|
|
|
+ border-top-left-radius: 0;
|
|
}
|
|
}
|
|
.list-wrap {
|
|
.list-wrap {
|
|
display: flex;
|
|
display: flex;
|
|
@@ -274,6 +327,9 @@ export default {
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
+ .setting-box{
|
|
|
|
+ margin-bottom: 30px;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
</style>
|
|
</style>
|
|
<style lang="scss">
|
|
<style lang="scss">
|