mirror of
https://gitee.com/dromara/go-view.git
synced 2026-04-23 00:00:12 +08:00
fix: 修改引入方式,去除config文件上的node指向
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import { echartOptionProfixHandle, publicConfig } from '@/packages/public'
|
||||
import { BarCommonConfig } from './index'
|
||||
import { CreateComponentType } from '@/packages/index.d'
|
||||
import omit from 'lodash/omit'
|
||||
import cloneDeep from 'lodash/cloneDeep'
|
||||
|
||||
export const includes = ['legend', 'xAxis', 'yAxis']
|
||||
@@ -54,7 +53,7 @@ export const option = {
|
||||
export default class Config extends publicConfig
|
||||
implements CreateComponentType {
|
||||
public key = BarCommonConfig.key
|
||||
public chartConfig = omit(cloneDeep(BarCommonConfig), ['node', 'conNode'])
|
||||
public chartConfig = cloneDeep(BarCommonConfig)
|
||||
// 图表配置项
|
||||
public option = echartOptionProfixHandle(option, includes)
|
||||
}
|
||||
|
||||
@@ -1,17 +1,14 @@
|
||||
import BarCommon from './index.vue'
|
||||
import Configuration from './config.vue'
|
||||
import image from '@/assets/images/chart/charts/bar_x.png'
|
||||
import { ConfigType, PackagesCategoryEnum } from '@/packages/index.d'
|
||||
import { ChatCategoryEnum, ChatCategoryEnumName } from '../../index.d'
|
||||
|
||||
export const BarCommonConfig: ConfigType = {
|
||||
key: 'VBarCommon',
|
||||
key: 'BarCommon',
|
||||
chartKey: 'VBarCommon',
|
||||
conKey: 'VCBarCommon',
|
||||
title: '柱状图',
|
||||
category: ChatCategoryEnum.BAR,
|
||||
categoryName: ChatCategoryEnumName.BAR,
|
||||
package: PackagesCategoryEnum.CHARTS,
|
||||
node: () => BarCommon,
|
||||
conNode: () => Configuration,
|
||||
image: image,
|
||||
image
|
||||
}
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
import { echartOptionProfixHandle, publicConfig } from '@/packages/public'
|
||||
import { BarCrossrangefig } from './index'
|
||||
import { BarCrossrangeConfig } from './index'
|
||||
import { CreateComponentType } from '@/packages/index.d'
|
||||
import omit from 'lodash/omit'
|
||||
import cloneDeep from 'lodash/cloneDeep'
|
||||
|
||||
export const includes = ['legend', 'xAxis', 'yAxis']
|
||||
@@ -53,8 +52,8 @@ export const option = {
|
||||
|
||||
export default class Config extends publicConfig
|
||||
implements CreateComponentType {
|
||||
public key: string = BarCrossrangefig.key
|
||||
public chartConfig = omit(cloneDeep(BarCrossrangefig), ['node', 'conNode'])
|
||||
public key: string = BarCrossrangeConfig.key
|
||||
public chartConfig = cloneDeep(BarCrossrangeConfig)
|
||||
// 图表配置项
|
||||
public option = echartOptionProfixHandle(option, includes)
|
||||
}
|
||||
|
||||
@@ -1,17 +1,14 @@
|
||||
import BarCrossrange from './index.vue'
|
||||
import Configuration from './config.vue'
|
||||
import image from '@/assets/images/chart/charts/bar_y.png'
|
||||
import { ConfigType, PackagesCategoryEnum } from '@/packages/index.d'
|
||||
import { ChatCategoryEnum, ChatCategoryEnumName } from '../../index.d'
|
||||
|
||||
export const BarCrossrangefig: ConfigType = {
|
||||
key: 'VBarCrossrange',
|
||||
export const BarCrossrangeConfig: ConfigType = {
|
||||
key: 'BarCrossrange',
|
||||
chartKey: 'VBarCrossrange',
|
||||
conKey: 'VCBarCrossrange',
|
||||
title: '横向柱状图',
|
||||
category: ChatCategoryEnum.BAR,
|
||||
categoryName: ChatCategoryEnumName.BAR,
|
||||
package: PackagesCategoryEnum.CHARTS,
|
||||
node: () => BarCrossrange,
|
||||
conNode: () => Configuration,
|
||||
image: image
|
||||
image
|
||||
}
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { BarCommonConfig } from './BarCommon/index'
|
||||
import { BarCrossrangefig } from './BarCrossrange/index'
|
||||
import { BarCrossrangeConfig } from './BarCrossrange/index'
|
||||
|
||||
export default [BarCommonConfig, BarCrossrangefig]
|
||||
export default [BarCommonConfig, BarCrossrangeConfig]
|
||||
|
||||
Reference in New Issue
Block a user