Merge branch 'dev' of github.com:dataease/dataease into dev

This commit is contained in:
taojinlong 2021-08-19 10:10:36 +08:00
commit e1835b5326
34 changed files with 343 additions and 95 deletions

View File

@ -2,7 +2,6 @@ package io.dataease.auth.service.impl;
import io.dataease.auth.service.ExtAuthService;
import io.dataease.base.domain.SysAuth;
import io.dataease.base.domain.SysAuthExample;
import io.dataease.base.mapper.SysAuthMapper;
import io.dataease.base.mapper.ext.ExtAuthMapper;
import io.dataease.commons.model.AuthURD;

View File

@ -7,7 +7,6 @@ import javax.crypto.*;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
import java.security.MessageDigest;
import java.util.UUID;
/**
* 加密解密工具

View File

@ -2,7 +2,6 @@ package io.dataease.controller;
import io.dataease.commons.license.DefaultLicenseService;
import io.dataease.commons.license.F2CLicenseResponse;
import io.dataease.exception.DataEaseException;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;

View File

@ -5,9 +5,7 @@ import io.dataease.base.domain.ChartViewWithBLOBs;
import io.dataease.commons.utils.AuthUtils;
import io.dataease.controller.request.chart.ChartExtRequest;
import io.dataease.controller.request.chart.ChartViewRequest;
import io.dataease.controller.request.dataset.DataSetTableRequest;
import io.dataease.dto.chart.ChartViewDTO;
import io.dataease.dto.dataset.DataSetTableDTO;
import io.dataease.service.chart.ChartViewService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;

View File

@ -3,7 +3,6 @@ package io.dataease.controller.request.dataset;
import io.dataease.base.domain.DatasetGroup;
import lombok.Data;
import java.util.List;
import java.util.Set;
/**

View File

@ -4,7 +4,6 @@ import io.dataease.base.domain.SysUser;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import java.util.ArrayList;
import java.util.List;
@Data

View File

@ -3,7 +3,6 @@ package io.dataease.dto.chart;
import lombok.Getter;
import lombok.Setter;
import java.math.BigDecimal;
import java.util.List;
/**

View File

@ -5,7 +5,6 @@ import io.dataease.base.domain.DatasetTableField;
import io.dataease.base.domain.Datasource;
import io.dataease.controller.request.chart.ChartExtFilterRequest;
import io.dataease.datasource.dto.JdbcDTO;
import io.dataease.datasource.dto.SqlServerConfigration;
import io.dataease.dto.chart.ChartCustomFilterDTO;
import io.dataease.dto.chart.ChartViewFieldDTO;
import io.dataease.dto.sqlObj.SQLObj;

View File

@ -3,7 +3,6 @@ package io.dataease.provider.doris;
import io.dataease.provider.SQLConstants;
import static io.dataease.datasource.constants.DatasourceTypes.doris;
import static io.dataease.datasource.constants.DatasourceTypes.mysql;
/**
* @Author gin

View File

@ -8,8 +8,6 @@ import io.dataease.base.mapper.DatasetTableFieldMapper;
import io.dataease.commons.constants.DeTypeConstants;
import io.dataease.controller.request.chart.ChartExtFilterRequest;
import io.dataease.datasource.dto.JdbcDTO;
import io.dataease.datasource.dto.PgConfigration;
import io.dataease.datasource.dto.SqlServerConfigration;
import io.dataease.dto.chart.ChartCustomFilterDTO;
import io.dataease.dto.chart.ChartViewFieldDTO;
import io.dataease.dto.sqlObj.SQLObj;

View File

@ -8,7 +8,6 @@ import io.dataease.base.mapper.DatasetTableFieldMapper;
import io.dataease.commons.constants.DeTypeConstants;
import io.dataease.controller.request.chart.ChartExtFilterRequest;
import io.dataease.datasource.dto.JdbcDTO;
import io.dataease.datasource.dto.SqlServerConfigration;
import io.dataease.dto.chart.ChartCustomFilterDTO;
import io.dataease.dto.chart.ChartViewFieldDTO;
import io.dataease.dto.sqlObj.SQLObj;

View File

@ -12,7 +12,6 @@ import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.UUID;
/**
@ -35,7 +34,7 @@ public class DataSetTableFieldsService {
datasetTableField.setId(UUID.randomUUID().toString());
// 若dataeasename为空则用MD5(id)作为dataeasename
if (StringUtils.isEmpty(datasetTableField.getDataeaseName())) {
datasetTableField.setDataeaseName(DorisTableUtils.dorisFieldName(datasetTableField.getId()));
datasetTableField.setDataeaseName(DorisTableUtils.columnName(datasetTableField.getId()));
}
if (ObjectUtils.isEmpty(datasetTableField.getLastSyncTime())) {
datasetTableField.setLastSyncTime(System.currentTimeMillis());

View File

@ -2,9 +2,7 @@ package io.dataease.service.dataset;
import io.dataease.base.domain.*;
import io.dataease.base.mapper.DatasetTableFunctionMapper;
import io.dataease.commons.utils.DorisTableUtils;
import io.dataease.datasource.service.DatasourceService;
import org.apache.commons.lang3.ObjectUtils;
import org.apache.commons.lang3.StringUtils;
import org.springframework.stereotype.Service;
@ -35,6 +33,7 @@ public class DatasetFunctionService {
if (StringUtils.isNotEmpty(datasetTableFunction.getDbType())) {
criteria.andDbTypeEqualTo(datasetTableFunction.getDbType());
}
datasetTableFunctionExample.setOrderByClause("name asc");
return datasetTableFunctionMapper.selectByExampleWithBLOBs(datasetTableFunctionExample);
}

View File

@ -1,7 +1,6 @@
package io.dataease.service.panel;
import io.dataease.base.domain.PanelViewLinkage;
import io.dataease.base.domain.PanelViewLinkageExample;
import io.dataease.base.domain.PanelViewLinkageField;
import io.dataease.base.mapper.PanelViewLinkageFieldMapper;
import io.dataease.base.mapper.PanelViewLinkageMapper;
@ -10,7 +9,6 @@ import io.dataease.commons.utils.AuthUtils;
import io.dataease.controller.request.panel.PanelLinkageRequest;
import io.dataease.dto.LinkageInfoDTO;
import io.dataease.dto.PanelViewLinkageDTO;
import io.dataease.dto.PanelViewLinkageFieldDTO;
import org.apache.commons.collections4.CollectionUtils;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

View File

@ -8,7 +8,6 @@ import io.dataease.base.mapper.ext.query.GridExample;
import io.dataease.commons.utils.BeanUtils;
import io.dataease.commons.utils.CommonBeanFactory;
import io.dataease.controller.sys.base.BaseGridRequest;
import io.dataease.controller.sys.base.ConditionEntity;
import io.dataease.controller.sys.request.DeptCreateRequest;
import io.dataease.controller.sys.request.DeptDeleteRequest;
import io.dataease.controller.sys.request.DeptStatusRequest;
@ -19,7 +18,6 @@ import org.apache.commons.lang3.ObjectUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.*;
import java.util.stream.Collectors;

View File

@ -6,6 +6,7 @@
<div class="fu-operator-component__operator">
<el-select
v-model="value"
:disabled="disabled"
class="search-operator"
:placeholder="$t('fu.search_bar.please_select')"
:size="configSize"
@ -35,7 +36,11 @@ export default {
// eslint-disable-next-line vue/require-default-prop
operator: String,
// eslint-disable-next-line vue/require-default-prop
operators: Array
operators: Array,
disabled: {
type: Boolean,
default: false
}
},
data() {
return {

View File

@ -0,0 +1,101 @@
<template>
<de-complex-operator v-model="operator" :label="label" :operators="operators" :size="configSize" disabled>
<el-select
v-model="value"
class="fu-complex-select"
:placeholder="$t('fu.search_bar.please_select')"
:size="configSize"
clearable
v-bind="$attrs"
>
<el-option v-for="o in options" :key="o.value" :label="o.label" :value="o.value" />
</el-select>
</de-complex-operator>
</template>
<script>
import { ComplexCondition } from 'fit2cloud-ui/src/components/search-bar/model'
import DeComplexOperator from './DeComplexOperator.vue'
import Cookies from 'js-cookie'
const MULTIPLE_OPERATORS = [
{
label: 'fu.search_bar.in',
value: 'in'
}, {
label: 'fu.search_bar.not_in',
value: 'not in'
}
]
const OPERATORS = [
{
label: 'fu.search_bar.eq',
value: 'eq'
}, {
label: 'fu.search_bar.ne',
value: 'ne'
}
]
export default {
name: 'DeComplexSelect',
components: { DeComplexOperator },
props: {
// eslint-disable-next-line vue/require-default-prop
field: String,
// eslint-disable-next-line vue/require-default-prop
label: String,
// eslint-disable-next-line vue/require-default-prop
defaultOperator: String,
// eslint-disable-next-line vue/require-default-prop
options: Array
},
data() {
return {
operator: '',
value: ''
}
},
computed: {
isMultiple() {
const { multiple } = this.$attrs
return multiple !== undefined && multiple !== false
},
operators() {
return this.isMultiple ? MULTIPLE_OPERATORS : OPERATORS
},
valueLabel() {
if (this.isMultiple) {
const values = []
this.value.forEach(v => {
values.push(this.getValueLabel(v))
})
return values.join(', ')
}
return this.getValueLabel(this.value)
},
configSize() {
return Cookies.get('size') || 'medium'
}
},
methods: {
getValueLabel(value) {
for (const o of this.options) {
if (o.value === value) {
return o.label
}
}
return value
},
getCondition() {
if (!this.value) return
const { field, label, operator, operatorLabel, value, valueLabel } = this
return new ComplexCondition({ field, label, operator, operatorLabel, value, valueLabel })
},
init() {
this.operator = this.defaultOperator || this.operators[0].value
this.value = ''
}
}
}
</script>

View File

@ -1,7 +1,7 @@
<template>
<div v-show="existLinkage" class="bar-main">
<div>
<el-button size="mini" type="info" @click="clearAllLinkage">清除所有联动</el-button>
<el-button size="mini" type="warning" @click="clearAllLinkage"><i class="icon iconfont icon-quxiaoliandong" />{{ $t('panel.remove_all_linkage') }}</el-button>
</div>
</div>
</template>

View File

@ -7,10 +7,19 @@
</div>
<div v-else-if="!linkageSettingStatus">
<setting-menu v-if="activeModel==='edit'" style="float: right;height: 24px!important;">
<i slot="icon" class="icon iconfont icon-shezhi" />
<span slot="icon" :title="$t('panel.setting')">
<i class="icon iconfont icon-shezhi" style="margin-top:2px" />
</span>
</setting-menu>
<i v-if="activeModel==='edit'&&curComponent&&editFilter.includes(curComponent.type)" class="icon iconfont icon-edit" @click.stop="edit" />
<i v-if="curComponent.type==='view'" class="icon iconfont icon-fangda" @click.stop="showViewDetails" />
<span :title="$t('panel.edit')">
<i v-if="activeModel==='edit'&&curComponent&&editFilter.includes(curComponent.type)" class="icon iconfont icon-edit" @click.stop="edit" />
</span>
<span :title="$t('panel.details')">
<i v-if="curComponent.type==='view'" class="icon iconfont icon-fangda" @click.stop="showViewDetails" />
</span>
<span :title="$t('panel.cancel_linkage')">
<i v-if="curComponent.type==='view'&&existLinkage" class="icon iconfont icon-quxiaoliandong" @click.stop="clearLinkage" />
</span>
</div>
</div>
@ -53,6 +62,19 @@ export default {
}
},
computed: {
existLinkage() {
let linkageFiltersCount = 0
this.componentData.forEach(item => {
if (item.linkageFilters && item.linkageFilters.length > 0) {
item.linkageFilters.forEach(linkage => {
if (this.element.propValue.viewId === linkage.sourceViewId) {
linkageFiltersCount++
}
})
}
})
return linkageFiltersCount
},
linkageInfo() {
return this.targetLinkageInfo[this.element.propValue.viewId]
},
@ -93,6 +115,21 @@ export default {
},
linkageEdit() {
},
// sourceViewId
clearLinkage() {
this.componentData.forEach(item => {
if (item.linkageFilters && item.linkageFilters.length > 0) {
const newList = item.linkageFilters.filter(linkage => linkage.sourceViewId !== this.element.propValue.viewId)
item.linkageFilters.splice(0, item.linkageFilters.length)
// push watch
if (newList.length > 0) {
newList.forEach(newLinkage => {
item.linkageFilters.push(newLinkage)
})
}
}
})
}
}
}

View File

@ -3,6 +3,7 @@
<el-popover
width="400"
trigger="click"
style="max-height: 400px;overflow-y: auto"
>
<el-row>
<el-col :span="11">
@ -13,52 +14,55 @@
</el-col>
</el-row>
<el-row v-for="(item, index) in linkageInfo.linkageFields" :key="index">
<el-col :span="11">
<div class="select-filed">
<el-select v-model="item.sourceField" size="mini" placeholder="请选择">
<el-option
v-for="item in sourceLinkageInfo.targetViewFields"
:key="item.id"
:label="item.name"
:value="item.id"
>
<span style="float: left">
<svg-icon v-if="item.deType === 0" icon-class="field_text" class="field-icon-text" />
<svg-icon v-if="item.deType === 1" icon-class="field_time" class="field-icon-time" />
<svg-icon v-if="item.deType === 2 || item.value === 3" icon-class="field_value" class="field-icon-value" />
<svg-icon v-if="item.deType === 5" icon-class="field_location" class="field-icon-location" />
</span>
<span style="float: left; color: #8492a6; font-size: 12px">{{ item.name }}</span>
</el-option>
</el-select>
</div>
</el-col>
<el-col :span="11">
<div class="select-filed">
<el-select v-model="item.targetField" size="mini" placeholder="请选择">
<el-option
v-for="item in linkageInfo.targetViewFields"
:key="item.id"
:label="item.name"
:value="item.id"
>
<span style="float: left">
<svg-icon v-if="item.deType === 0" icon-class="field_text" class="field-icon-text" />
<svg-icon v-if="item.deType === 1" icon-class="field_time" class="field-icon-time" />
<svg-icon v-if="item.deType === 2 || item.value === 3" icon-class="field_value" class="field-icon-value" />
<svg-icon v-if="item.deType === 5" icon-class="field_location" class="field-icon-location" />
</span>
<span style="float: left; color: #8492a6; font-size: 12px">{{ item.name }}</span>
</el-option>
</el-select>
</div>
</el-col>
<el-col :span="2">
<div>
<el-button icon="el-icon-delete" type="text" size="small" style="float: left" @click="deleteLinkageField(index)" />
</div>
</el-col>
<el-row style="height: 120px;overflow-y: auto">
<el-row v-for="(item, index) in linkageInfo.linkageFields" :key="index">
<el-col :span="11">
<div class="select-filed">
<el-select v-model="item.sourceField" size="mini" placeholder="请选择">
<el-option
v-for="item in sourceLinkageInfo.targetViewFields"
:key="item.id"
:label="item.name"
:value="item.id"
>
<span style="float: left">
<svg-icon v-if="item.deType === 0" icon-class="field_text" class="field-icon-text" />
<svg-icon v-if="item.deType === 1" icon-class="field_time" class="field-icon-time" />
<svg-icon v-if="item.deType === 2 || item.value === 3" icon-class="field_value" class="field-icon-value" />
<svg-icon v-if="item.deType === 5" icon-class="field_location" class="field-icon-location" />
</span>
<span style="float: left; color: #8492a6; font-size: 12px">{{ item.name }}</span>
</el-option>
</el-select>
</div>
</el-col>
<el-col :span="11">
<div class="select-filed">
<el-select v-model="item.targetField" size="mini" placeholder="请选择">
<el-option
v-for="item in linkageInfo.targetViewFields"
:key="item.id"
:label="item.name"
:value="item.id"
>
<span style="float: left">
<svg-icon v-if="item.deType === 0" icon-class="field_text" class="field-icon-text" />
<svg-icon v-if="item.deType === 1" icon-class="field_time" class="field-icon-time" />
<svg-icon v-if="item.deType === 2 || item.value === 3" icon-class="field_value" class="field-icon-value" />
<svg-icon v-if="item.deType === 5" icon-class="field_location" class="field-icon-location" />
</span>
<span style="float: left; color: #8492a6; font-size: 12px">{{ item.name }}</span>
</el-option>
</el-select>
</div>
</el-col>
<el-col :span="2">
<div>
<el-button icon="el-icon-delete" type="text" size="small" style="float: left" @click="deleteLinkageField(index)" />
</div>
</el-col>
</el-row>
</el-row>
<el-row class="bottom">
@ -67,7 +71,6 @@
<!-- <el-button slot="reference">T</el-button>-->
<i slot="reference" class="icon iconfont icon-edit slot-class" />
</el-popover>
</template>
@ -183,5 +186,9 @@ export default {
height: 35px;
border-radius: 3px;
}
>>>.el-popover{
height: 200px;
overflow: auto;
}
</style>

View File

@ -76,10 +76,10 @@
<!--关闭弹框-->
<el-dialog :visible.sync="closePanelVisible" :title="$t('panel.panel_save_tips')" :show-close="false" width="30%" class="dialog-css">
<el-row style="height: 20px">
<el-col :span="6">
<el-col :span="4">
<svg-icon icon-class="warn-tre" style="width: 20px;height: 20px;float: right" />
</el-col>
<el-col :span="16">
<el-col :span="20">
<span style="font-size: 13px;margin-left: 10px;font-weight: bold;line-height: 20px">{{ $t('panel.panel_save_warn_tips') }}</span>
</el-col>
</el-row>
@ -320,6 +320,38 @@ export default {
this.close()
},
saveLinkage() {
//
// let checkCount = 0
for (const key in this.targetLinkageInfo) {
let subCheckCount = 0
const linkageInfo = this.targetLinkageInfo[key]
const linkageFields = linkageInfo['linkageFields']
if (linkageFields) {
linkageFields.forEach(function(linkage) {
if (!(linkage.sourceField && linkage.targetField)) {
subCheckCount++
}
})
}
if (subCheckCount > 0) {
this.$message({
message: this.$t('chart.datalist') + '【' + linkageInfo.targetViewName + '】' + this.$t('panel.exit_un_march_linkage_field'),
type: 'error',
showClose: true
})
return
}
}
// if (checkCount > 0) {
// this.$message({
// message: this.$t('panel.exit_un_march_linkage_field'),
// type: 'error',
// showClose: true
// })
// return
// }
const request = {
panelId: this.$store.state.panel.panelInfo.id,
sourceViewId: this.curLinkageView.propValue.viewId,

View File

@ -113,7 +113,7 @@ export default {
linkageFilters() {
// watch oldValuenewValue
if (!this.element.linkageFilters) return []
console.log('linkageFilters:' + JSON.stringify(this.element.linkageFilters))
// console.log('linkageFilters:' + JSON.stringify(this.element.linkageFilters))
return JSON.parse(JSON.stringify(this.element.linkageFilters))
},
trackMenu() {
@ -127,7 +127,7 @@ export default {
})
linkageCount && trackMenuInfo.push('linkage')
this.drillFields.length && trackMenuInfo.push('drill')
console.log('trackMenuInfo' + JSON.stringify(trackMenuInfo))
// console.log('trackMenuInfo' + JSON.stringify(trackMenuInfo))
return trackMenuInfo
},
chartType() {

View File

@ -77,7 +77,11 @@ export default {
const titleWidth = this.$refs.deTitle.offsetWidth
const deContentContainer = this.$refs.deContentContainer
this.$nextTick(() => {
if (height < 75) {
let min = 75
if (this.element.component === 'de-number-range') {
min = 105
}
if (height < min) {
// console.log(titleWidth)
this.mainClass = 'condition-main-line'
deContentContainer && (deContentContainer.style.inset = '0 0 0 ' + (titleWidth + 15) + 'px')
@ -121,6 +125,8 @@ export default {
.condition-title-absolute {
inset: 0px 0px;
position: absolute;
top: 15px;
left: 4px;
}
.span-container {

View File

@ -1210,7 +1210,12 @@ export default {
do_not_save: "Don't Save",
save_and_close: 'Save',
drill: 'drill',
linkage: 'linkage'
linkage: 'linkage',
cancel_linkage: 'Cancel Linkage',
remove_all_linkage: 'Remove All Linkage',
exit_un_march_linkage_field: 'Exit Un March Linkage Field',
details: 'Details',
setting: 'Setting'
},
plugin: {
local_install: 'Local installation',

View File

@ -1209,7 +1209,12 @@ export default {
do_not_save: '不保存',
save: '保存',
drill: '下钻',
linkage: '联动'
linkage: '联动',
cancel_linkage: '取消联动',
remove_all_linkage: '清除所有联动',
exit_un_march_linkage_field: '存在未匹配联动关系的字段',
details: '详情',
setting: '设置'
},
plugin: {
local_install: '本地安裝',

View File

@ -1211,7 +1211,12 @@ export default {
do_not_save: '不保存',
save: '保存',
drill: '下钻',
linkage: '联动'
linkage: '联动',
cancel_linkage: '取消联动',
remove_all_linkage: '清除所有联动',
exit_un_march_linkage_field: '存在未匹配联动关系的字段',
details: '详情',
setting: '设置'
},
plugin: {
local_install: '本地安装',

View File

@ -21,7 +21,7 @@ import Treeselect from '@riophae/vue-treeselect'
import '@riophae/vue-treeselect/dist/vue-treeselect.css'
import './utils/dialog'
import DeComplexInput from '@/components/business/condition-table/DeComplexInput'
import DeComplexSelect from '@/components/business/condition-table/DeComplexSelect'
import '@/components/canvas/custom-component' // 注册自定义组件
Vue.config.productionTip = false
Vue.use(VueClipboard)
@ -74,6 +74,7 @@ Vue.use(directives)
Vue.use(message)
Vue.component('Treeselect', Treeselect)
Vue.component('DeComplexInput', DeComplexInput)
Vue.component('DeComplexSelect', DeComplexSelect)
Vue.config.productionTip = false
Vue.prototype.hasDataPermission = function(pTarget, pSource) {

View File

@ -178,7 +178,7 @@ const data = {
if (element.propValue.viewId === targetViewId) { // 如果目标视图 和 当前循环组件id相等 则进行条件增减
const targetFieldId = targetInfoArray[1] // 目标视图列ID
const condition = new Condition('', targetFieldId, 'eq', [dimension.value], [targetViewId])
condition.sourceViewId = viewId
let j = currentFilters.length
while (j--) {
const filter = currentFilters[j]

View File

@ -715,6 +715,12 @@ export const BASE_TREEMAP = {
{
// name: '',
type: 'treemap',
itemStyle: {
gapWidth: 2
},
breadcrumb: {
show: false
},
// radius: ['0%', '60%'],
// avoidLabelOverlap: false,
// emphasis: {

View File

@ -1,6 +1,8 @@
import { hexColorToRGBA } from '@/views/chart/chart/util'
import { componentStyle } from '../common/common'
let bubbleArray = []
export function baseScatterOption(chart_option, chart) {
// 处理shape attr
let customAttr = {}
@ -21,6 +23,7 @@ export function baseScatterOption(chart_option, chart) {
if (chart.data) {
chart_option.title.text = chart.title
chart_option.xAxis.data = chart.data.x
bubbleArray = []
for (let i = 0; i < chart.data.series.length; i++) {
const y = chart.data.series[i]
// color
@ -33,6 +36,9 @@ export function baseScatterOption(chart_option, chart) {
const extBubble = JSON.parse(chart.extBubble)
if (extBubble && extBubble.length > 0) {
y.data.forEach(ele => {
bubbleArray.push(ele.value[2])
})
y.symbolSize = funcSize
} else {
y.symbolSize = customAttr.size.scatterSymbolSize ? customAttr.size.scatterSymbolSize : 20
@ -53,5 +59,7 @@ export function baseScatterOption(chart_option, chart) {
}
const funcSize = function(data) {
return data[2]
const k = 80
const max = Math.max(...bubbleArray)
return (data[2] / max) * k
}

View File

@ -28,9 +28,17 @@ export function baseTreemapOption(chart_option, chart) {
chart_option.series[0].height = (customAttr.size.treemapHeight ? customAttr.size.treemapHeight : 80) + '%'
}
// label
// if (customAttr.label) {
// chart_option.series[0].label = customAttr.label
// }
if (customAttr.label) {
// chart_option.series[0].label = customAttr.label
const l = {
show: true,
position: customAttr.label.position,
color: customAttr.label.color,
fontSize: customAttr.label.fontSize,
formatter: customAttr.label.show ? customAttr.label.formatter : ''
}
chart_option.series[0].label = l
}
const valueArr = chart.data.series[0].data
for (let i = 0; i < valueArr.length; i++) {
// const y = {

View File

@ -338,6 +338,12 @@
<span>{{ $t('chart.bubble_size') }}</span>
/
<span>{{ $t('chart.quota') }}</span>
<el-tooltip class="item" effect="dark" placement="bottom">
<div slot="content">
该指标生效时样式大小中的气泡大小属性将失效
</div>
<i class="el-icon-info" style="cursor: pointer;color: #606266;" />
</el-tooltip>
</span>
<draggable
v-model="view.extBubble"
@ -430,7 +436,7 @@
<el-collapse-item v-show="chart.type !== 'map'" name="size" :title="$t('chart.size')">
<size-selector :param="param" class="attr-selector" :chart="chart" @onSizeChange="onSizeChange" />
</el-collapse-item>
<el-collapse-item v-show="!view.type.includes('table') && !view.type.includes('text') && view.type !== 'treemap'" name="label" :title="$t('chart.label')">
<el-collapse-item v-show="!view.type.includes('table') && !view.type.includes('text')" name="label" :title="$t('chart.label')">
<label-selector :param="param" class="attr-selector" :chart="chart" @onLabelChange="onLabelChange" />
</el-collapse-item>
<el-collapse-item v-show="!view.type.includes('table') && !view.type.includes('text')" name="tooltip" :title="$t('chart.tooltip')">

View File

@ -56,7 +56,19 @@
</el-col>
<el-col :span="10" style="height: 100%;border-left: 1px solid #E6E6E6;">
<el-col :span="12" style="height: 100%" class="padding-lr">
<span>{{ $t('dataset.click_ref_field') }}</span>
<span>
{{ $t('dataset.click_ref_field') }}
<el-tooltip class="item" effect="dark" placement="bottom">
<div slot="content">
引用字段以 "[" 开始 "]" 结束
<br>
请勿修改引用内容否则将引用失败
<br>
若输入与引用字段相同格式的内容将被当作引用字段处理
</div>
<i class="el-icon-info" style="cursor: pointer;" />
</el-tooltip>
</span>
<el-input
v-model="searchField"
size="mini"
@ -106,7 +118,19 @@
</div>
</el-col>
<el-col :span="12" style="height: 100%" class="padding-lr">
<span>{{ $t('dataset.click_ref_function') }}</span>
<span>
{{ $t('dataset.click_ref_function') }}
<el-tooltip class="item" effect="dark" placement="bottom">
<div slot="content">
使用数据集对应数据库类型所支持的函数语法同对应数据库
<br>
如日期格式化MySQL使用DATE_FORMAT(date,format)Oracle使用TO_DATE(X,[,fmt])
<br>
非直连模式数据集使用Doris数据库函数可参考Doris官网 http://doris.apache.org/master/zh-CN/
</div>
<i class="el-icon-info" style="cursor: pointer;" />
</el-tooltip>
</span>
<el-input
v-model="searchFunction"
size="mini"
@ -127,7 +151,7 @@
<p class="pop-title">{{ item.name }}</p>
<p class="pop-info">{{ item.func }}</p>
<p class="pop-info">{{ item.desc }}</p>
<span slot="reference" class="function-style" :title="item.func" @click="insertParamToCodeMirror(item.func)">{{ item.func }}</span>
<span slot="reference" class="function-style" @click="insertParamToCodeMirror(item.func)">{{ item.func }}</span>
</el-popover>
</el-row>
</el-col>
@ -444,9 +468,13 @@ export default {
padding: 2px 4px;
cursor: pointer;
margin: 4px 0;
overflow-x: hidden;
white-space: nowrap;
text-overflow: ellipsis;
word-break: break-word;
border: solid 1px #eee;
}
.function-style:hover {
background: #e8f4ff;
border-color: #a3d3ff;
cursor: pointer;
}
.function-height{
height: calc(100% - 50px);

View File

@ -192,6 +192,10 @@ export default {
label: this.$t('member.edit_password'), icon: 'el-icon-s-tools', type: 'success', click: this.editPassword,
show: this.checkPermission(['user:editPwd'])
}
// , {
// label: '', icon: 'el-icon-lock', type: 'warning', click: this.showAuth,
// show: this.checkPermission(['user:editPwd'])
// }
],
searchConfig: {
useQuickSearch: true,
@ -202,7 +206,7 @@ export default {
{
field: 'u.enabled',
label: this.$t('commons.status'),
component: 'FuComplexSelect',
component: 'DeComplexSelect',
options: [
{ label: this.$t('commons.enable'), value: '1' },
{ label: this.$t('commons.disable'), value: '0' }
@ -352,6 +356,9 @@ export default {
edit(row) {
this.$router.push({ name: 'system-user-form', params: row })
},
showAuth(row) {
this.$router.push({ name: 'system-user-form', params: row })
},
// edit(row) {
// this.depts = null
// this.formType = 'modify'