Options
All
  • Public
  • Public/Protected
  • All
Menu

图表组件-饼状图

Hierarchy

Index

Constructors

constructor

Properties

backgroundImage

backgroundImage: string

背景图

css

css: any

echartId

echartId: string

interval

interval: number

legendField

legendField: string

图列绑定字段

legendOrient

legendOrient: EchartToolboxOrient

图列朝向

onRefreshTimeScript

onRefreshTimeScript: string

刷新的脚本

optionsScript

optionsScript: string

保存了个性的配置

radius

radius: string

饼图的半径

refreshTime

refreshTime: number

图表刷新时间(毫秒) 如果为空或者0 不是实时刷新 注意不能设置太低的值会导致性能问题 默认:0

seriesCenter

seriesCenter: string

饼图坐标

seriesName

seriesName: string

系列名称,用于tooltip的显示,legend 的图例筛选,在 setOption 更新数据和配置项时用于指定对应的系列。

seriesNameField

seriesNameField: string

系列项的名称字段

seriesValueField

seriesValueField: string

系列的值字段

themeId

themeId: string

管理的主题组件Id

titleLeft

titleLeft: EchartAlignment

标题组件离容器左侧的距离。

titleShow

titleShow: boolean

标题名称是否显示

titleText

titleText: string

标题名称

toolboxOrient

toolboxOrient: EchartToolboxOrient

工具栏 icon 的布局朝向。

toolboxShow

toolboxShow: boolean

工具栏是否显示

width

width: string

图表的宽,不设置就是100%

Methods

Protected doClear

  • doClear(): void

Protected doDataChanged

  • doDataChanged(ds: DataSourceBase): void

doDataParser

  • doDataParser(): any

Protected doGetClassName

  • doGetClassName(): string

doGetCss

  • doGetCss(): any

Protected doGetDefalutOptions

  • doGetDefalutOptions(): { legend: {}; series: { center: string[]; name: string; radius: string | string[]; type: string }[]; title: { left: EchartAlignment; show: boolean; text: string }; toolbox: { feature: { saveAsImage: {} }; orient: EchartToolboxOrient; show: boolean }; tooltip: { formatter: string; show: boolean } }
  • Returns { legend: {}; series: { center: string[]; name: string; radius: string | string[]; type: string }[]; title: { left: EchartAlignment; show: boolean; text: string }; toolbox: { feature: { saveAsImage: {} }; orient: EchartToolboxOrient; show: boolean }; tooltip: { formatter: string; show: boolean } }

    • legend: {}
    • series: { center: string[]; name: string; radius: string | string[]; type: string }[]
    • title: { left: EchartAlignment; show: boolean; text: string }
    • toolbox: { feature: { saveAsImage: {} }; orient: EchartToolboxOrient; show: boolean }
    • tooltip: { formatter: string; show: boolean }
      • formatter: string
      • show: boolean

doGetElemtHtml

  • doGetElemtHtml(): string
  • Returns string

Protected doGetNewEchartInsc

  • doGetNewEchartInsc(): any

Protected doGetOptions

  • doGetOptions(): any
  • 得到图表的配置项,如果存在自定义的配置项就加载自定义的. 子类可覆盖改函数自定义

    Returns any

Protected doLoadData

  • doLoadData(isReload?: boolean): void
  • 刷新数据源加载数据

    Parameters

    • isReload: boolean = true

      重新加载

    Returns void

doRender

  • doRender(): void

doRenderWidthHeight

  • doRenderWidthHeight(): void

Protected doRequestLibJs

  • doRequestLibJs(callback: any): void

getAttrEditors

  • getAttrEditors(): AttributeEditorBase[]

getAxisData

  • getAxisData(rows: Row[], fieldName: string, axisType?: AxisType): any[]
  • 组装各个轴的对象

    Parameters

    • rows: Row[]
    • fieldName: string
    • axisType: AxisType = ...

    Returns any[]

getDataSet

  • getDataSet(): { dimensions: any[]; source: any[] }
  • 把数据源ds转化到Echar的dataSet

    Returns { dimensions: any[]; source: any[] }

    • dimensions: any[]
    • source: any[]

getDefalutOptions

  • getDefalutOptions(): any

getEchart

  • getEchart(): any
  • 获取Echart实例对象

    Returns any

    成功返回图标实例,否则返回null

getLegendData

  • getLegendData(rows: Row[], fieldName: string, type?: string): any[]
  • 组装图例的对象

    Parameters

    • rows: Row[]
    • fieldName: string
    • type: string = "scroll"

    Returns any[]

getPieCenter

  • getPieCenter(): string[]
  • 获取饼图坐标

    Returns string[]

getPieRadius

  • getPieRadius(): string | string[]
  • 获取饼图坐标

    Returns string | string[]

getSeriesObj

  • getSeriesObj(rows: Row[], valueFieldName: string, groupFieldName: string, type?: string): any[]
  • 分组组装series数组

    Parameters

    • rows: Row[]

      行数组

    • valueFieldName: string

      值的字段名

    • groupFieldName: string

      分组字段名

    • type: string = 'pie'

    Returns any[]

    series数组

getTheme

Protected isOptionScript

  • isOptionScript(): boolean

onRefreshTime

  • onRefreshTime(callback: onRefreshTimeHandle): void
  • 注册间隔时间刷新事件

    Parameters

    • callback: onRefreshTimeHandle

      onChooseHandel事件处理函数

    Returns void

raiseOnRefreshTime

  • raiseOnRefreshTime(): void

reLoadData

  • reLoadData(): void

render

  • render(): void

Protected startLoadData

  • startLoadData(): void

Generated using TypeDoc