Merge remote-tracking branch 'refs/remotes/origin/feature/task-report' into feature/task-report

This commit is contained in:
caoyanyi
2025-06-03 13:34:31 +08:00
2 changed files with 19 additions and 0 deletions
+2
View File
@@ -42,6 +42,7 @@ $config->screen->chartConfig['table'] = '{"category" : "Tables", "category
$config->screen->chartConfig['card'] = '{"category" : "Texts", "categoryName" : "文本", "chartFrame" : "common", "chartKey" : "VTextCommon", "conKey" : "VCTextCommon", "image" : "text_static.png", "key" : "TextCommon", "package" : "Informations", "title" : "文字", "dataset" : {}}';
$config->screen->chartConfig['text'] = '{"category" : "Texts", "categoryName" : "文本", "chartFrame" : "common", "chartKey" : "VTextCommon", "conKey" : "VCTextCommon", "image" : "text_static.png", "key" : "TextCommon", "package" : "Informations", "title" : "文字", "dataset" : {}}';
$config->screen->chartConfig['waterpolo'] = '{"category" : "Mores", "categoryName" : "更多", "chartFrame" : "common", "chartKey" : "VWaterPolo", "conKey" : "VCWaterPolo", "image" : "water_WaterPolo.png", "key" : "WaterPolo", "package" : "Charts", "title" : "水球图", "dataset" : {}}';
$config->screen->chartConfig['sunburst'] = '{"category" : "Mores", "categoryName" : "更多", "chartFrame" : "common", "chartKey" : "VSunBurst", "conKey" : "VCSunBurst", "image" : "pie.png", "key" : "SunBurst", "package" : "Charts", "title" : "旭日图", "dataset" : {}}';
$config->screen->chartConfig['box'] = '{"category" : "Mores", "categoryName" : "更多", "chartFrame" : "plotlys", "chartKey" : "VBox", "conKey" : "VCBox", "image" : "line.png", "key" : "Box", "package" : "Charts", "title" : "箱线图", "dataset" : {}}';
$config->screen->chartConfig['metric'] = '{"category" : "Metrics", "categoryName" : "度量项", "chartFrame" : "common", "chartKey" : "VMetrics", "conKey" : "VCMetrics", "image" : "bar_x.png", "key" : "Metrics", "package" : "Metrics", "title" : "度量项", "dataset" : {}}';
$config->screen->chartConfig['help'] = '{"category" : "Informations", "categoryName" : "信息", "chartFrame" : "common", "chartKey" : "VHint", "conKey" : "VCHint", "image" : "./static/png/hint.png", "key" : "Hint", "package" : "Decorates", "title" : "提示"}';
@@ -56,6 +57,7 @@ $config->screen->chartOption['line'] = '{"legend":{"show":true,"top":40,"
$config->screen->chartOption['table'] = '{}';
$config->screen->chartOption['text'] = '{"fontSize":20,"fontColor":"#fff","textAlign":"center","fontWeight":"normal","borderWidth":0,"borderColor":"#fff","borderRadius":5}';
$config->screen->chartOption['waterpolo'] = '{"type":"nomal","series":[{"type":"liquidFill","radius":"90%","roseType":false}],"backgroundColor":"rgba(0,0,0,0)"}';
$config->screen->chartOption['sunburst'] = '{"series":{"type":"sunburst","data": [], "radius": [0, "90%"], "label": {"rotate": "radial"}}}';
$config->screen->chartOption['box'] = '{"data": [], "layout": {"title": {"text": ""}}, "config": {}}';
$config->screen->chartOption['help'] = '{"text": "", "icon": "", "textSize": 30, "textColor": "#ffffff", "textWeight": "bold", "placement": "right-bottom", "distance": 8, "hint": "提示文本", "width": 0, "height": 0, "paddingX": 16, "paddingY": 8, "borderWidth": 1, "borderStyle": "solid", "borderColor": "#1a77a5", "borderRadius": 6, "color": "#ffffff", "textAlign": "left", "fontWeight": "normal", "backgroundColor": "rgba(89, 196, 230, .2)", "fontSize": 24}';
$config->screen->fieldConfig = new stdclass();
+17
View File
@@ -446,6 +446,8 @@ class screenModel extends model
return $this->prepareCardDataset($component, $data);
case 'waterpolo':
return $this->prepareWaterPoloDataset($component, $data);
case 'sunburst':
return $this->prepareSunburstDataset($component, $data);
case 'group':
return $this->prepareGroupDataset($component, $data);
case 'text':
@@ -1035,6 +1037,21 @@ class screenModel extends model
return $this->setComponentDefaults($component);
}
/**
* 准备旭日图数据集。
* Prepare sunburst dataset.
*
* @param object $component
* @param array $data
* @access public
* @return object
*/
public function prepareSunburstDataset(object $component, array $data): object
{
$component->option->series->data = $data;
return $this->setComponentDefaults($component);
}
/**
* Get bar chart option.
*