feat: 🎸 simulation
fix dps and add the push and DPS strategy
This commit is contained in:
@@ -21,10 +21,16 @@ const NUMBER_OF_SIMULATION = 1000
|
||||
</button>
|
||||
<button
|
||||
class="button button-outline"
|
||||
@click="simulationStore.simulate('problem-solving')"
|
||||
@click="simulationStore.simulate('pull-dps')"
|
||||
>
|
||||
simulate pull and problem solving
|
||||
</button>
|
||||
<button
|
||||
class="button button-outline"
|
||||
@click="simulationStore.simulate('push-dps')"
|
||||
>
|
||||
simulate push and problem solving
|
||||
</button>
|
||||
</div>
|
||||
<div class="row">
|
||||
<button
|
||||
@@ -42,14 +48,19 @@ const NUMBER_OF_SIMULATION = 1000
|
||||
<button
|
||||
class="button button-outline"
|
||||
@click="
|
||||
simulationStore.multiSimulation(
|
||||
NUMBER_OF_SIMULATION,
|
||||
'problem-solving'
|
||||
)
|
||||
simulationStore.multiSimulation(NUMBER_OF_SIMULATION, 'pull-dps')
|
||||
"
|
||||
>
|
||||
simulate {{ NUMBER_OF_SIMULATION }} pull and problem solving
|
||||
</button>
|
||||
<button
|
||||
class="button button-outline"
|
||||
@click="
|
||||
simulationStore.multiSimulation(NUMBER_OF_SIMULATION, 'push-dps')
|
||||
"
|
||||
>
|
||||
simulate {{ NUMBER_OF_SIMULATION }} push and problem solving
|
||||
</button>
|
||||
<button
|
||||
class="button button-clear"
|
||||
@click="simulationStore.clearDashboard()"
|
||||
|
||||
@@ -6,7 +6,7 @@ const simulationStore = useSimulationStore()
|
||||
|
||||
<template>
|
||||
<div class="simulation-dashboard">
|
||||
<h3>Dashboard</h3>
|
||||
<h3>Simulation dashboard</h3>
|
||||
<h4>
|
||||
({{ simulationStore.simulationsDone }} /
|
||||
{{ simulationStore.requestedSimulation }}
|
||||
@@ -19,6 +19,7 @@ const simulationStore = useSimulationStore()
|
||||
<th>push</th>
|
||||
<th>pull</th>
|
||||
<th>pull and DPS</th>
|
||||
<th>push and DPS</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -33,6 +34,9 @@ const simulationStore = useSimulationStore()
|
||||
<td class="numeric">
|
||||
{{ simulationStore.meanPullDPSLeadTime }}
|
||||
</td>
|
||||
<td class="numeric">
|
||||
{{ simulationStore.meanPushDPSLeadTime }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Complexity</td>
|
||||
@@ -45,6 +49,9 @@ const simulationStore = useSimulationStore()
|
||||
<td class="numeric">
|
||||
{{ simulationStore.meanPullDPSComplexity }}
|
||||
</td>
|
||||
<td class="numeric">
|
||||
{{ simulationStore.meanPushDPSComplexity }}
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>Quality issue</td>
|
||||
@@ -57,6 +64,9 @@ const simulationStore = useSimulationStore()
|
||||
<td class="numeric">
|
||||
{{ simulationStore.meanPullDPSQuality }}
|
||||
</td>
|
||||
<td class="numeric">
|
||||
{{ simulationStore.meanPushDPSQuality }}
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
@@ -4,6 +4,8 @@ import { Dashboard, Meta } from '@/store-type'
|
||||
import { getRound } from '@/utils'
|
||||
import { defineStore } from 'pinia'
|
||||
|
||||
// Get features done per day to plot it
|
||||
|
||||
type Mean = {
|
||||
leadTimeSum: number
|
||||
complexitySum: number
|
||||
@@ -35,7 +37,8 @@ const resetMeta = (): Meta => ({
|
||||
strategy: {
|
||||
push: 0,
|
||||
pull: 0,
|
||||
'problem-solving': 0
|
||||
'pull-dps': 0,
|
||||
'push-dps': 0
|
||||
}
|
||||
})
|
||||
|
||||
@@ -48,7 +51,8 @@ export const useSimulationStore = defineStore('dashboard', {
|
||||
mean: {
|
||||
push: newMean(),
|
||||
pull: newMean(),
|
||||
'problem-solving': newMean()
|
||||
'pull-dps': newMean(),
|
||||
'push-dps': newMean()
|
||||
}
|
||||
}
|
||||
},
|
||||
@@ -106,7 +110,8 @@ export const useSimulationStore = defineStore('dashboard', {
|
||||
this.dashboards = []
|
||||
this.mean.push = newMean()
|
||||
this.mean.pull = newMean()
|
||||
this.mean['problem-solving'] = newMean()
|
||||
this.mean['pull-dps'] = newMean()
|
||||
this.mean['push-dps'] = newMean()
|
||||
}
|
||||
},
|
||||
getters: {
|
||||
@@ -118,8 +123,14 @@ export const useSimulationStore = defineStore('dashboard', {
|
||||
},
|
||||
meanPullDPSLeadTime: (state) => {
|
||||
return getRound(
|
||||
state.mean['problem-solving'].leadTimeSum,
|
||||
state.mean['problem-solving'].simulations
|
||||
state.mean['pull-dps'].leadTimeSum,
|
||||
state.mean['pull-dps'].simulations
|
||||
)
|
||||
},
|
||||
meanPushDPSLeadTime: (state) => {
|
||||
return getRound(
|
||||
state.mean['push-dps'].leadTimeSum,
|
||||
state.mean['push-dps'].simulations
|
||||
)
|
||||
},
|
||||
meanPushComplexity: (state) => {
|
||||
@@ -136,8 +147,14 @@ export const useSimulationStore = defineStore('dashboard', {
|
||||
},
|
||||
meanPullDPSComplexity: (state) => {
|
||||
return getRound(
|
||||
state.mean['problem-solving'].complexitySum,
|
||||
state.mean['problem-solving'].simulations
|
||||
state.mean['pull-dps'].complexitySum,
|
||||
state.mean['pull-dps'].simulations
|
||||
)
|
||||
},
|
||||
meanPushDPSComplexity: (state) => {
|
||||
return getRound(
|
||||
state.mean['push-dps'].complexitySum,
|
||||
state.mean['push-dps'].simulations
|
||||
)
|
||||
},
|
||||
meanPushQuality: (state) => {
|
||||
@@ -154,8 +171,14 @@ export const useSimulationStore = defineStore('dashboard', {
|
||||
},
|
||||
meanPullDPSQuality: (state) => {
|
||||
return getRound(
|
||||
state.mean['problem-solving'].qualityIssueSum,
|
||||
state.mean['problem-solving'].simulations
|
||||
state.mean['pull-dps'].qualityIssueSum,
|
||||
state.mean['pull-dps'].simulations
|
||||
)
|
||||
},
|
||||
meanPushDPSQuality: (state) => {
|
||||
return getRound(
|
||||
state.mean['push-dps'].qualityIssueSum,
|
||||
state.mean['push-dps'].simulations
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user