Merge pull request #689 from dataease/pr@dev@feat_radar_size

feat: 雷达图大小
This commit is contained in:
XiaJunjie2020 2021-08-24 12:03:27 +08:00 committed by GitHub
commit 91a2a27b13
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 12 additions and 3 deletions

View File

@ -847,7 +847,8 @@ export default {
height: 'Height',
system_case: 'System',
custom_case: 'Custom',
last_layer: 'This Is The Last Layer'
last_layer: 'This Is The Last Layer',
radar_size: 'Size'
},
dataset: {
sheet_warn: 'There are multiple sheet pages, and the first one is extracted by default',

View File

@ -846,7 +846,8 @@ export default {
height: '高度',
system_case: '系統方案',
custom_case: '自定義',
last_layer: '當前已經是最後一級'
last_layer: '當前已經是最後一級',
radar_size: '大小'
},
dataset: {
sheet_warn: '有多個sheet頁面默認抽取第一個',

View File

@ -846,7 +846,8 @@ export default {
height: '高度',
system_case: '系统方案',
custom_case: '自定义',
last_layer: '当前已经是最后一级'
last_layer: '当前已经是最后一级',
radar_size: '大小'
},
dataset: {
sheet_warn: '有多个 Sheet 页,默认抽取第一个',

View File

@ -25,6 +25,7 @@ export const DEFAULT_SIZE = {
pieRoseRadius: 5,
funnelWidth: 80,
radarShape: 'polygon',
radarSize: 80,
tableTitleFontSize: 12,
tableItemFontSize: 12,
tableTitleHeight: 36,

View File

@ -12,6 +12,7 @@ export function baseRadarOption(chart_option, chart) {
// size
if (customAttr.size) {
chart_option.radar.shape = customAttr.size.radarShape
chart_option.radar.radius = (customAttr.size.radarSize ? customAttr.size.radarSize : 80) + '%'
}
// tooltip
if (customAttr.tooltip) {

View File

@ -78,6 +78,9 @@
<el-radio-button label="circle">{{ $t('chart.circle') }}</el-radio-button>
</el-radio-group>
</el-form-item>
<el-form-item :label="$t('chart.radar_size')" class="form-item form-item-slider">
<el-slider v-model="sizeForm.radarSize" show-input :show-input-controls="false" input-size="mini" :min="0" :max="100" @change="changeBarSizeCase" />
</el-form-item>
</el-form>
<el-form v-show="chart.type && chart.type.includes('table')" ref="sizeFormPie" :disabled="param && !hasDataPermission('manage',param.privileges)" :model="sizeForm" label-width="100px" size="mini">
@ -220,6 +223,7 @@ export default {
this.sizeForm = customAttr.size
this.sizeForm.treemapWidth = this.sizeForm.treemapWidth ? this.sizeForm.treemapWidth : 80
this.sizeForm.treemapHeight = this.sizeForm.treemapHeight ? this.sizeForm.treemapHeight : 80
this.sizeForm.radarSize = this.sizeForm.radarSize ? this.sizeForm.radarSize : 80
}
}
},