add open data for pm project statistics

This commit is contained in:
呱呱呱 2024-01-30 11:40:56 +08:00
parent f39b83692b
commit 53083d3030
1 changed files with 7 additions and 1 deletions

View File

@ -45,9 +45,15 @@ class Api::Pm::ProjectsController < Api::Pm::BaseController
end
}
end
open_data = {
"1": type_status_data[1][1] + type_status_data[1][2],
"2": type_status_data[2][1] + type_status_data[2][2],
"3": type_status_data[3][1] + type_status_data[3][2],
}
data = {
pie_chart: type_count_data,
bar_chart: type_status_data
bar_chart: type_status_data,
open_data: open_data
}
render_ok(data: data)
end