|
@@ -106,6 +106,10 @@
|
|
|
<h3>新增趋势图</h3>
|
|
|
<tendency-chart :chart-data="tendencyData" />
|
|
|
</div>
|
|
|
+ <div class="chart-item">
|
|
|
+ <h3>所属需求方向分布图</h3>
|
|
|
+ <belong-requirement-chart :chart-data="belongRequirementData" />
|
|
|
+ </div>
|
|
|
<div class="chart-item">
|
|
|
<h3>周期统计<span>(根据排期计算)</span></h3>
|
|
|
<div class="chart-item-tip">
|
|
@@ -144,6 +148,10 @@
|
|
|
<h3>排期发生变更的任务({{ changeTotal }})</h3>
|
|
|
<change-require-chart :chart-data="changeTaskData" />
|
|
|
</div>
|
|
|
+ <div class="chart-item">
|
|
|
+ <h3>报告统计</h3>
|
|
|
+ <cycle-statistic :chart-data="reportSummaryData" child-data="relativeRatio" />
|
|
|
+ </div>
|
|
|
<div class="chart-item">
|
|
|
<h3>缺陷统计</h3>
|
|
|
<bug-list :chart-data="bugListData" />
|
|
@@ -160,16 +168,19 @@ import {
|
|
|
getSummary,
|
|
|
getCumulativeFlowDiagram,
|
|
|
getTaskCountTrend,
|
|
|
+ getRequirementOrientationDistributeData,
|
|
|
getTaskPeriodicData,
|
|
|
getTaskRdDeliveryPeriodicData,
|
|
|
getDistributeData,
|
|
|
getStatusStayData,
|
|
|
getModuleDistributeData,
|
|
|
getTaskUnlockData,
|
|
|
+ getReportSummary,
|
|
|
getBugStatisticData
|
|
|
} from '@/api/statisticsApi/taskStatistics'
|
|
|
import statusChart from './components/statusChart'
|
|
|
import tendencyChart from './components/tendencyChart'
|
|
|
+import belongRequirementChart from './components/belongRequirementChart'
|
|
|
import cycleStatistic from './components/cycleStatistic'
|
|
|
import developmentCycle from './components/developmentCycle'
|
|
|
import distributionChart from './components/distributionChart'
|
|
@@ -181,6 +192,7 @@ export default {
|
|
|
components: {
|
|
|
statusChart,
|
|
|
tendencyChart,
|
|
|
+ belongRequirementChart,
|
|
|
cycleStatistic,
|
|
|
developmentCycle,
|
|
|
distributionChart,
|
|
@@ -206,6 +218,7 @@ export default {
|
|
|
activeTab: '1', // tab标签
|
|
|
cumulativeData: null, // 任务状态累计流数据
|
|
|
tendencyData: null, // 趋势图数据
|
|
|
+ belongRequirementData: null, // 所属需求方向分布图
|
|
|
cycleData: [], // 周期统计数据
|
|
|
developmentCycleData: [], // 研发交付周期分布数据
|
|
|
distributeStatus: 1, // 任务分布图任务状态
|
|
@@ -223,6 +236,7 @@ export default {
|
|
|
moduleDistribute: null, // 模块分布图数据
|
|
|
changeTaskData: null, // 排期变更任务数据
|
|
|
changeTotal: 0, // 变更总数
|
|
|
+ reportSummaryData: null, // 报告统计数据
|
|
|
bugListData: {} // 缺陷统计数据
|
|
|
}
|
|
|
},
|
|
@@ -276,12 +290,14 @@ export default {
|
|
|
this.getSummary()
|
|
|
this.getCumulativeFlowDiagram()
|
|
|
this.getTaskCountTrend()
|
|
|
+ this.getBelongRequirementData()
|
|
|
this.getCycleData()
|
|
|
this.getDevelopmentCycle()
|
|
|
this.getModuleDistributeData()
|
|
|
this.getDistributeData()
|
|
|
this.getStatusStayData()
|
|
|
this.getTaskUnlockData()
|
|
|
+ this.getReportSummary()
|
|
|
this.getBugStatisticData()
|
|
|
},
|
|
|
setDate(type) { // 日期筛选
|
|
@@ -342,6 +358,14 @@ export default {
|
|
|
const res = await getTaskCountTrend(params)
|
|
|
if (res.code === 200) this.tendencyData = res.data
|
|
|
},
|
|
|
+ async getBelongRequirementData() { // 所属需求方向分布图
|
|
|
+ const params = {
|
|
|
+ ...this.globalParams,
|
|
|
+ type: Number(this.activeTab)
|
|
|
+ }
|
|
|
+ const res = await getRequirementOrientationDistributeData(params)
|
|
|
+ if (res.code === 200) this.belongRequirementData = res.data
|
|
|
+ },
|
|
|
async getCumulativeFlowDiagram() { // 任务状态累计流图
|
|
|
const params = {
|
|
|
...this.globalParams,
|
|
@@ -364,7 +388,11 @@ export default {
|
|
|
type: Number(this.activeTab)
|
|
|
}
|
|
|
const res = await getTaskRdDeliveryPeriodicData(params)
|
|
|
- if (res.code === 200) this.developmentCycleData = res.data
|
|
|
+ if (res.code === 200) {
|
|
|
+ res.data.length > 0
|
|
|
+ ? this.developmentCycleData = res.data
|
|
|
+ : this.developmentCycleData = [moment().format('YYYY-MM-DD'), '0']
|
|
|
+ }
|
|
|
},
|
|
|
async getDistributeData() { // 获取任务分布图
|
|
|
const params = {
|
|
@@ -419,6 +447,14 @@ export default {
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
+ async getReportSummary() { // 报告统计
|
|
|
+ const params = {
|
|
|
+ ...this.globalParams,
|
|
|
+ type: Number(this.activeTab)
|
|
|
+ }
|
|
|
+ const res = await getReportSummary(params)
|
|
|
+ if (res.code === 200) this.reportSummaryData = res.data
|
|
|
+ },
|
|
|
async getBugStatisticData() { // 缺陷统计
|
|
|
const params = {
|
|
|
...this.globalParams,
|