forked from github/dataease
Merge branch 'dev' of github.com:dataease/dataease into dev
This commit is contained in:
commit
fecdd28d2d
@ -6,15 +6,17 @@
|
||||
id="label-content"
|
||||
:style="content_class"
|
||||
>
|
||||
<span v-if="quotaShow" :style="label_space">
|
||||
<span v-if="quotaShow" :style="label_class">
|
||||
<p v-for="item in chart.data.series" :key="item.name" :style="label_content_class">
|
||||
{{ item.data[0] }}
|
||||
</p>
|
||||
</span>
|
||||
<p v-if="dimensionShow" :style="label_class">
|
||||
<!-- {{ chart.data.x[0] }}-->
|
||||
{{ chart.data.series[0].name }}
|
||||
</p>
|
||||
<span v-if="dimensionShow" :style="label_space">
|
||||
<p :style="label_class">
|
||||
<!-- {{ chart.data.x[0] }}-->
|
||||
{{ chart.data.series[0].name }}
|
||||
</p>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
@ -46,12 +46,12 @@
|
||||
</el-popover>
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item v-show="(chart.type && chart.type.includes('text')) || sourceType==='panelTable'" :label="$t('chart.dimension_color')" class="form-item">
|
||||
<el-color-picker v-model="colorForm.dimensionColor" class="color-picker-style" @change="changeColorCase" />
|
||||
</el-form-item>
|
||||
<el-form-item v-show="(chart.type && chart.type.includes('text')) || sourceType==='panelTable'" :label="$t('chart.quota_color')" class="form-item">
|
||||
<el-color-picker v-model="colorForm.quotaColor" class="color-picker-style" @change="changeColorCase" />
|
||||
</el-form-item>
|
||||
<el-form-item v-show="(chart.type && chart.type.includes('text')) || sourceType==='panelTable'" :label="$t('chart.dimension_color')" class="form-item">
|
||||
<el-color-picker v-model="colorForm.dimensionColor" class="color-picker-style" @change="changeColorCase" />
|
||||
</el-form-item>
|
||||
</div>
|
||||
<div v-if="sourceType==='view' || sourceType==='panelTable'">
|
||||
<el-form-item v-show="(chart.type && chart.type.includes('table')) || sourceType==='panelTable'" :label="$t('chart.table_header_bg')" class="form-item">
|
||||
|
@ -86,7 +86,7 @@
|
||||
:disabled="true"
|
||||
>
|
||||
<transition-group>
|
||||
<span v-for="item in dimensionData" :key="item.id" class="item-dimension" :title="item.name" @click="insertParamToCodeMirror('['+item.id+']')">
|
||||
<span v-for="item in dimensionData" :key="item.id" class="item-dimension" :title="item.name" @click="insertFieldToCodeMirror('['+item.id+']')">
|
||||
<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.deType === 3" icon-class="field_value" class="field-icon-value" />
|
||||
@ -106,7 +106,7 @@
|
||||
:disabled="true"
|
||||
>
|
||||
<transition-group>
|
||||
<span v-for="item in quotaData" :key="item.id" class="item-quota" :title="item.name" @click="insertParamToCodeMirror('['+item.id+']')">
|
||||
<span v-for="item in quotaData" :key="item.id" class="item-quota" :title="item.name" @click="insertFieldToCodeMirror('['+item.id+']')">
|
||||
<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.deType === 3" icon-class="field_value" class="field-icon-value" />
|
||||
@ -314,6 +314,13 @@ export default {
|
||||
pos2.ch = pos1.ch
|
||||
this.$refs.myCm.codemirror.replaceRange(param, pos2)
|
||||
},
|
||||
insertFieldToCodeMirror(param) {
|
||||
const pos1 = this.$refs.myCm.codemirror.getCursor()
|
||||
const pos2 = {}
|
||||
pos2.line = pos1.line
|
||||
pos2.ch = pos1.ch
|
||||
this.$refs.myCm.codemirror.replaceRange(param, pos2)
|
||||
},
|
||||
|
||||
initFunctions() {
|
||||
post('/dataset/function/listByTableId/' + this.param.id, null).then(response => {
|
||||
|
Loading…
Reference in New Issue
Block a user