forked from github/dataease
Merge pull request #12397 from dataease/pr@dev-v2@refactor_3d
Pr@dev v2@refactor 3d
This commit is contained in:
commit
820bc785ce
@ -371,10 +371,7 @@ public class ChartDataManage {
|
||||
provider = ProviderFactory.getProvider(dsMap.entrySet().iterator().next().getValue().getType());
|
||||
}
|
||||
|
||||
if (ObjectUtils.isEmpty(view.getCalParams())) {
|
||||
view.setCalParams(Utils.getParams(transFields(allFields)));
|
||||
}
|
||||
|
||||
view.setCalParams(Utils.getParams(transFields(allFields)));
|
||||
SQLMeta sqlMeta = new SQLMeta();
|
||||
Table2SQLObj.table2sqlobj(sqlMeta, null, "(" + sql + ")", crossDs);
|
||||
CustomWhere2Str.customWhere2sqlObj(sqlMeta, fieldCustomFilter, transFields(allFields), crossDs, dsMap, Utils.getParams(transFields(allFields)), view.getCalParams(), pluginManage);
|
||||
|
@ -829,6 +829,30 @@ const commonBackgroundSvgInner = computed(() => {
|
||||
}
|
||||
})
|
||||
|
||||
const padding3D = computed(() => {
|
||||
const width = defaultStyle.value.width // 原始元素宽度
|
||||
const height = defaultStyle.value.height // 原始元素高度
|
||||
const rotateX = element.value['multiDimensional'].x // 旋转X角度
|
||||
const rotateY = element.value['multiDimensional'].y // 旋转Y角度
|
||||
|
||||
// 将角度转换为弧度
|
||||
const radX = (rotateX * Math.PI) / 180
|
||||
const radY = (rotateY * Math.PI) / 180
|
||||
|
||||
// 计算旋转后新宽度和高度
|
||||
const newWidth = Math.abs(width * Math.cos(radY)) + Math.abs(height * Math.sin(radX))
|
||||
const newHeight = Math.abs(height * Math.cos(radX)) + Math.abs(width * Math.sin(radY))
|
||||
|
||||
// 计算需要的 padding
|
||||
const paddingX = (newWidth - width) / 2
|
||||
const paddingY = (newHeight - height) / 2
|
||||
|
||||
return {
|
||||
paddingX: `${paddingX}px`,
|
||||
paddingY: `${paddingY}px`
|
||||
}
|
||||
})
|
||||
|
||||
const componentBackgroundStyle = computed(() => {
|
||||
if (element.value.commonBackground && element.value.component !== 'GroupArea') {
|
||||
const {
|
||||
|
@ -68,7 +68,7 @@
|
||||
</el-tree>
|
||||
</el-row>
|
||||
</el-col>
|
||||
<el-col :span="18" class="preview-show">
|
||||
<el-col :span="13" class="preview-show">
|
||||
<el-row v-if="state.curNodeId">
|
||||
<el-row class="new-params-title"> 选择参数关联组件 </el-row>
|
||||
<el-row class="new-params-filter" v-if="state.outerParamsInfo?.filterInfo?.length">
|
||||
@ -249,7 +249,7 @@
|
||||
<empty-background description="请配置参数" img-type="noneWhite" />
|
||||
</div>
|
||||
</el-col>
|
||||
<el-col :span="5" v-show="false" class="params-attach-setting">
|
||||
<el-col :span="5" class="params-attach-setting">
|
||||
<el-row v-if="state.curNodeId">
|
||||
<el-row class="new-params-title"> 参数配置 </el-row>
|
||||
<el-row class="params-attach-content">
|
||||
|
@ -183,6 +183,7 @@ const maintainRadioChange = () => {
|
||||
}
|
||||
const multiDimensionalChange = () => {
|
||||
// do change
|
||||
snapshotStore.recordSnapshotCache()
|
||||
}
|
||||
|
||||
const positionInit = () => {
|
||||
|
Loading…
Reference in New Issue
Block a user