mirror of
https://github.com/dataease/dataease.git
synced 2025-02-24 11:32:57 +08:00
refactor(数据大屏): 国际化适配
This commit is contained in:
parent
9224959a11
commit
06600f0b6c
@ -63,7 +63,7 @@
|
||||
</span>
|
||||
</div>
|
||||
</span>
|
||||
<span>
|
||||
<span :title="data.sourceFieldName">
|
||||
<span class="tree-select-field">
|
||||
<el-icon style="margin-right: 4px">
|
||||
<Icon
|
||||
@ -380,7 +380,7 @@
|
||||
>
|
||||
</template>
|
||||
<template v-else-if="state.linkJumpCurFilterFieldArray.length === 0">
|
||||
<span>当前图表无绑定的查询条件</span>
|
||||
<span>{{ t('visualization.jump_no_banding_tips') }}</span>
|
||||
</template>
|
||||
<template v-else-if="state.currentOutParams.length > 0">
|
||||
<el-row style="margin-bottom: 8px" :gutter="8">
|
||||
@ -867,7 +867,7 @@ const save = () => {
|
||||
}
|
||||
}
|
||||
if (subCheckCount > 0) {
|
||||
ElMessage.error('字段【' + linkJumpInfo.sourceFieldName + '】存在空配置,请先完善配置!')
|
||||
ElMessage.error(t('visualization.delete_warn', [linkJumpInfo.sourceFieldName]))
|
||||
}
|
||||
}
|
||||
})
|
||||
@ -878,7 +878,7 @@ const save = () => {
|
||||
updateJumpSet(state.linkJump)
|
||||
.then(() => {
|
||||
snapshotStore.recordSnapshotCache('updateJumpSet')
|
||||
ElMessage.success('保存成功')
|
||||
ElMessage.success(t('common.save_success'))
|
||||
// 刷新跳转信息
|
||||
queryVisualizationJumpInfo(dvInfo.value.id).then(rsp => {
|
||||
dvMainStore.setNowPanelJumpInfo(rsp.data)
|
||||
@ -1503,6 +1503,7 @@ span {
|
||||
font-size: 14px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.label-content-details {
|
||||
|
@ -70,7 +70,8 @@ const dvMainStore = dvMainStoreWithOut()
|
||||
const { canvasViewInfo, mobileInPc } = storeToRefs(dvMainStore)
|
||||
const isError = ref(false)
|
||||
const appearanceStore = useAppearanceStoreWithOut()
|
||||
|
||||
import { useI18n } from '@/hooks/web/useI18n'
|
||||
const { t } = useI18n()
|
||||
const props = defineProps({
|
||||
scale: {
|
||||
type: Number,
|
||||
@ -147,7 +148,7 @@ const curFontFamily = () => {
|
||||
})
|
||||
return result
|
||||
}
|
||||
|
||||
const outerPlaceholder = t('visualization.component_input_tips')
|
||||
const init = ref({
|
||||
selector: '#' + tinymceId,
|
||||
toolbar_items_size: 'small',
|
||||
@ -168,7 +169,7 @@ const init = ref({
|
||||
'12px 14px 16px 18px 20px 22px 24px 28px 32px 36px 42px 48px 56px 72px 80px 90px 100px 110px 120px 140px 150px 170px 190px 210px', // 字体大小
|
||||
menubar: false,
|
||||
placeholder: '',
|
||||
outer_placeholder: '双击输入文字',
|
||||
outer_placeholder: outerPlaceholder,
|
||||
inline: true, // 开启内联模式
|
||||
branding: false,
|
||||
icons: 'vertical-content',
|
||||
|
@ -2794,6 +2794,12 @@ Scatter chart (bubble) chart: {a} (series name), {b} (data name), {c} (value arr
|
||||
column_name: 'Field name'
|
||||
},
|
||||
visualization: {
|
||||
jump_null_tips:
|
||||
'The field [{0}] has empty configuration. Please complete the configuration first!',
|
||||
jump_no_banding_tips: 'The current chart has no bound query conditions.',
|
||||
set_as_tips: 'Set as',
|
||||
rich_text_tips: 'Double click to enter text',
|
||||
save_conflict_tips: 'has been updated by others, overwrite and save?',
|
||||
text_decoration: 'underline',
|
||||
select_target_resource: 'Please select the target resource',
|
||||
target_dashboard_dataV: 'Target Dashboard/Screen',
|
||||
|
@ -2726,6 +2726,11 @@ export default {
|
||||
column_name: '欄位名稱'
|
||||
},
|
||||
visualization: {
|
||||
jump_null_tips: '欄位【{0}】存在空配置,請先完善配置!',
|
||||
jump_no_banding_tips: '當前圖表無綁定的查詢條件',
|
||||
set_as_tips: '置為',
|
||||
rich_text_tips: '雙擊輸入文字',
|
||||
save_conflict_tips: '已被他人更新,是否要覆蓋並儲存?',
|
||||
text_decoration: '下劃線',
|
||||
select_target_resource: '請選擇目標資源',
|
||||
target_dashboard_dataV: '目標儀表板/數據大屏',
|
||||
|
@ -2728,6 +2728,11 @@ export default {
|
||||
column_name: '字段名称'
|
||||
},
|
||||
visualization: {
|
||||
jump_null_tips: '字段【{0}】存在空配置,请先完善配置!',
|
||||
jump_no_banding_tips: '当前图表无绑定的查询条件',
|
||||
set_as_tips: '置为',
|
||||
rich_text_tips: '双击输入文字',
|
||||
save_conflict_tips: '已被他人更新,是否覆盖保存?',
|
||||
text_decoration: '下滑线',
|
||||
select_target_resource: '请选择目标资源',
|
||||
target_dashboard_dataV: '目标仪表板/数据大屏',
|
||||
|
@ -11,7 +11,9 @@ import {
|
||||
} from '@/custom-component/component-list'
|
||||
import { createGroupStyle, getComponentRotatedStyle } from '@/utils/style'
|
||||
import eventBus from '@/utils/eventBus'
|
||||
import { canvasIdMapCheck, checkJoinGroup, isMainCanvas, isTabCanvas } from '@/utils/canvasUtils'
|
||||
import { canvasIdMapCheck, checkJoinGroup, isTabCanvas } from '@/utils/canvasUtils'
|
||||
import { useI18n } from '@/hooks/web/useI18n'
|
||||
const { t } = useI18n()
|
||||
|
||||
const dvMainStore = dvMainStoreWithOut()
|
||||
const { curComponent, componentData, curOriginThemes } = storeToRefs(dvMainStore)
|
||||
@ -173,8 +175,8 @@ export const composeStore = defineStore('compose', {
|
||||
id: newId,
|
||||
component: 'Group',
|
||||
canvasActive: false,
|
||||
name: '组合',
|
||||
label: '组合',
|
||||
name: t('visualization.view_group'),
|
||||
label: t('visualization.view_group'),
|
||||
icon: 'group',
|
||||
expand: true,
|
||||
commonBackground: {
|
||||
|
@ -516,7 +516,7 @@ export function checkCanvasChangePre(callBack) {
|
||||
const tips =
|
||||
(dvInfo.value.type === 'dashboard'
|
||||
? t('work_branch.dashboard')
|
||||
: t('work_branch.big_data_screen')) + '已被他人更新,是否覆盖保存?'
|
||||
: t('work_branch.big_data_screen')) + t('work_branch.save_conflict_tips')
|
||||
checkCanvasChange(params).then(rsp => {
|
||||
if (rsp && rsp.data === 'Repeat') {
|
||||
ElMessageBox.confirm(tips, {
|
||||
|
@ -195,9 +195,11 @@ onMounted(() => {
|
||||
@change="changeFunctionCfg"
|
||||
>
|
||||
<el-radio :effect="themes" :label="'breakLine'">
|
||||
{{ isRichText ? '置为"-"' : t('chart.break_line') }}
|
||||
{{ isRichText ? t('visualization.set_as_tips') + '"-"' : t('chart.break_line') }}
|
||||
</el-radio>
|
||||
<el-radio v-if="isRichText" :effect="themes" :label="'custom'">
|
||||
{{ t('visualization.custom') }}
|
||||
</el-radio>
|
||||
<el-radio v-if="isRichText" :effect="themes" :label="'custom'"> 自定义 </el-radio>
|
||||
<template v-if="!isRichText">
|
||||
<el-radio v-if="!isCirclePacking" :effect="themes" :label="'setZero'">{{
|
||||
t('chart.set_zero')
|
||||
|
@ -3361,7 +3361,7 @@ const deleteChartFieldItem = id => {
|
||||
}"
|
||||
>
|
||||
<el-icon
|
||||
:title="'数据集'"
|
||||
:title="$t('visualization.dataset')"
|
||||
class="custom-icon"
|
||||
size="20px"
|
||||
@click="collapseChange('datasetAreaCollapse')"
|
||||
@ -3414,7 +3414,11 @@ const deleteChartFieldItem = id => {
|
||||
<div class="dataset-search-label" :class="{ dark: themes === 'dark' }">
|
||||
<span>{{ t('chart.field') }}</span>
|
||||
<span>
|
||||
<el-tooltip :effect="toolTip" content="刷新" placement="top">
|
||||
<el-tooltip
|
||||
:effect="toolTip"
|
||||
:content="$t('visualization.refresh')"
|
||||
placement="top"
|
||||
>
|
||||
<el-icon
|
||||
class="field-search-icon-btn"
|
||||
:class="{ dark: themes === 'dark' }"
|
||||
@ -3444,7 +3448,7 @@ const deleteChartFieldItem = id => {
|
||||
:effect="themes"
|
||||
class="dataset-search-input"
|
||||
:class="{ dark: themes === 'dark' }"
|
||||
:placeholder="t('chart.search') + t('chart.field')"
|
||||
:placeholder="t('chart.search') + ' ' + t('chart.field')"
|
||||
clearable
|
||||
>
|
||||
<template #prefix>
|
||||
|
Loading…
Reference in New Issue
Block a user