@ecan-bi/tools 1.0.29 → 1.0.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/indicator.ts +4 -6
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ecan-bi/tools",
3
- "version": "1.0.29",
3
+ "version": "1.0.31",
4
4
  "description": "General tools",
5
5
  "main": "lib/index.es.js",
6
6
  "module": "lib/index.es.js",
package/src/indicator.ts CHANGED
@@ -883,11 +883,9 @@ export const formatIndicatorParams = (props: any, otherParams: any = {}) => {
883
883
  })
884
884
 
885
885
  let indicatorsData = indicators
886
- if (otherParams?.pivotTableCal) {
886
+ if (otherParams?.pivotTableCal?.indicators?.length) {
887
887
  // 透视表全设计模式,替换设计态拖拽的指标
888
- indicatorsData = otherParams.pivotTableCal?.indicators || []
889
- // @ts-ignore
890
- window.logFunc && window.logFunc(indicatorsData)
888
+ indicatorsData = otherParams.pivotTableCal.indicators
891
889
  }
892
890
  indicatorsData?.forEach((indicator: { [key:string]: any }) => {
893
891
  indicator.location = 'LEFT'
@@ -899,9 +897,9 @@ export const formatIndicatorParams = (props: any, otherParams: any = {}) => {
899
897
  if (['ecanList', 'ecanCirculate'].includes(type) && classificationList?.length > 1) {
900
898
  queryColumnList = classificationList
901
899
  }
902
- if (otherParams?.pivotTableCal) {
900
+ if (otherParams?.pivotTableCal?.dimensions?.length) {
903
901
  // 透视表全设计模式,替换设计态拖拽的维度
904
- queryColumnList = otherParams.pivotTableCal?.dimensions || []
902
+ queryColumnList = otherParams.pivotTableCal.dimensions
905
903
  }
906
904
  queryColumnList?.forEach((queryColumn: { [key:string]: any }) => {
907
905
  const { label, name, location, show, indexCode, sort, typeGuid, indexCodeNum, dateFormat, conditions } = queryColumn