gantt
This commit is contained in:
@ -423,6 +423,7 @@ export default function App() {
|
|||||||
groups={groups}
|
groups={groups}
|
||||||
sprintFieldId={sprintFieldResolved}
|
sprintFieldId={sprintFieldResolved}
|
||||||
ganttSprintRowMetric={dashboardCfg.ganttSprintRowMetric}
|
ganttSprintRowMetric={dashboardCfg.ganttSprintRowMetric}
|
||||||
|
ganttNonWorkingDates={dashboardCfg.ganttNonWorkingDates}
|
||||||
onGanttSprintRowMetricChange={setGanttSprintRowMetric}
|
onGanttSprintRowMetricChange={setGanttSprintRowMetric}
|
||||||
onOpenSettings={() => setSettingsOpen(true)}
|
onOpenSettings={() => setSettingsOpen(true)}
|
||||||
/>
|
/>
|
||||||
|
|||||||
@ -5,6 +5,7 @@ import {
|
|||||||
GANTT_SPRINT_METRIC_OPTIONS,
|
GANTT_SPRINT_METRIC_OPTIONS,
|
||||||
mergeImportedConfig,
|
mergeImportedConfig,
|
||||||
normalizeFunctionalGapsForSave,
|
normalizeFunctionalGapsForSave,
|
||||||
|
parseGanttNonWorkingDatesFromText,
|
||||||
sanitizeExcludedSprintIds,
|
sanitizeExcludedSprintIds,
|
||||||
type DashboardConfig,
|
type DashboardConfig,
|
||||||
type FunctionalGapBadge,
|
type FunctionalGapBadge,
|
||||||
@ -108,11 +109,18 @@ export function DashboardSettingsModal({ open, config, onClose, onSave, boardSpr
|
|||||||
const fileRef = useRef<HTMLInputElement>(null)
|
const fileRef = useRef<HTMLInputElement>(null)
|
||||||
const titleId = useId()
|
const titleId = useId()
|
||||||
const [draft, setDraft] = useState<DashboardConfig>(config)
|
const [draft, setDraft] = useState<DashboardConfig>(config)
|
||||||
|
const [ganttNonWorkInput, setGanttNonWorkInput] = useState('')
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (open) setDraft(config)
|
if (open) setDraft(config)
|
||||||
}, [open, config])
|
}, [open, config])
|
||||||
|
|
||||||
|
const configNonWorkKey = config.ganttNonWorkingDates.join('|')
|
||||||
|
useEffect(() => {
|
||||||
|
if (!open) return
|
||||||
|
setGanttNonWorkInput(config.ganttNonWorkingDates.join('\n'))
|
||||||
|
}, [open, configNonWorkKey])
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const el = dialogRef.current
|
const el = dialogRef.current
|
||||||
if (!el) return
|
if (!el) return
|
||||||
@ -146,8 +154,10 @@ export function DashboardSettingsModal({ open, config, onClose, onSave, boardSpr
|
|||||||
try {
|
try {
|
||||||
const parsed = JSON.parse(String(reader.result)) as unknown
|
const parsed = JSON.parse(String(reader.result)) as unknown
|
||||||
const merged = mergeImportedConfig(draft, parsed)
|
const merged = mergeImportedConfig(draft, parsed)
|
||||||
if (merged) setDraft(merged)
|
if (merged) {
|
||||||
else alert('Fichier JSON invalide (configuration v1 ou bundle Synology v1).')
|
setDraft(merged)
|
||||||
|
setGanttNonWorkInput(merged.ganttNonWorkingDates.join('\n'))
|
||||||
|
} else alert('Fichier JSON invalide (configuration v1 ou bundle Synology v1).')
|
||||||
} catch {
|
} catch {
|
||||||
alert('Impossible de lire ce fichier JSON.')
|
alert('Impossible de lire ce fichier JSON.')
|
||||||
}
|
}
|
||||||
@ -373,6 +383,21 @@ export function DashboardSettingsModal({ open, config, onClose, onSave, boardSpr
|
|||||||
</option>
|
</option>
|
||||||
))}
|
))}
|
||||||
</select>
|
</select>
|
||||||
|
<label className="mt-3 block text-[10px] font-semibold uppercase tracking-wide text-indigo-200/80">
|
||||||
|
Jours non travaillés (Gantt)
|
||||||
|
</label>
|
||||||
|
<p className="mt-1 text-[10px] leading-relaxed text-slate-500">
|
||||||
|
Une date par ligne au format <span className="font-mono text-slate-400">AAAA-MM-JJ</span> (fuseau
|
||||||
|
local du navigateur). Même style que sam. / dim. : fériés, ponts, fermeture.
|
||||||
|
</p>
|
||||||
|
<textarea
|
||||||
|
rows={4}
|
||||||
|
spellCheck={false}
|
||||||
|
placeholder={'2026-05-01\n2026-05-08'}
|
||||||
|
className="mt-1.5 w-full resize-y rounded-lg border border-white/10 bg-black/30 px-2 py-1.5 font-mono text-[11px] leading-relaxed text-slate-200 outline-none ring-indigo-500/20 focus:ring-1"
|
||||||
|
value={ganttNonWorkInput}
|
||||||
|
onChange={(e) => setGanttNonWorkInput(e.target.value)}
|
||||||
|
/>
|
||||||
<p className="mt-3 text-[10px] font-semibold uppercase tracking-wide text-indigo-200/80">
|
<p className="mt-3 text-[10px] font-semibold uppercase tracking-wide text-indigo-200/80">
|
||||||
Sprints à masquer
|
Sprints à masquer
|
||||||
</p>
|
</p>
|
||||||
@ -649,6 +674,7 @@ export function DashboardSettingsModal({ open, config, onClose, onSave, boardSpr
|
|||||||
...draft,
|
...draft,
|
||||||
functionalGaps: normalizeFunctionalGapsForSave(draft.functionalGaps),
|
functionalGaps: normalizeFunctionalGapsForSave(draft.functionalGaps),
|
||||||
excludedSprintIds: sanitizeExcludedSprintIds(draft.excludedSprintIds),
|
excludedSprintIds: sanitizeExcludedSprintIds(draft.excludedSprintIds),
|
||||||
|
ganttNonWorkingDates: parseGanttNonWorkingDatesFromText(ganttNonWorkInput),
|
||||||
})
|
})
|
||||||
onClose()
|
onClose()
|
||||||
}}
|
}}
|
||||||
|
|||||||
@ -31,6 +31,8 @@ type Props = {
|
|||||||
groups: StoryGroup[]
|
groups: StoryGroup[]
|
||||||
sprintFieldId: string | null
|
sprintFieldId: string | null
|
||||||
ganttSprintRowMetric: GanttSprintRowMetric
|
ganttSprintRowMetric: GanttSprintRowMetric
|
||||||
|
/** Dates yyyy-mm-dd (local) en plus des week-ends pour le fond du Gantt. */
|
||||||
|
ganttNonWorkingDates: string[]
|
||||||
onGanttSprintRowMetricChange: (m: GanttSprintRowMetric) => void
|
onGanttSprintRowMetricChange: (m: GanttSprintRowMetric) => void
|
||||||
onOpenSettings: () => void
|
onOpenSettings: () => void
|
||||||
}
|
}
|
||||||
@ -105,7 +107,7 @@ function GanttTimelineBackdrop({
|
|||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
{dayColumns
|
{dayColumns
|
||||||
.filter((c) => c.isWeekend)
|
.filter((c) => c.isGanttNonWork)
|
||||||
.map((c) => (
|
.map((c) => (
|
||||||
<div
|
<div
|
||||||
key={c.dayStartMs}
|
key={c.dayStartMs}
|
||||||
@ -145,6 +147,7 @@ export function SprintGanttView({
|
|||||||
groups,
|
groups,
|
||||||
sprintFieldId,
|
sprintFieldId,
|
||||||
ganttSprintRowMetric,
|
ganttSprintRowMetric,
|
||||||
|
ganttNonWorkingDates,
|
||||||
onGanttSprintRowMetricChange,
|
onGanttSprintRowMetricChange,
|
||||||
onOpenSettings,
|
onOpenSettings,
|
||||||
}: Props) {
|
}: Props) {
|
||||||
@ -187,9 +190,10 @@ export function SprintGanttView({
|
|||||||
[startMs, endMs, ppd],
|
[startMs, endMs, ppd],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
const nonWorkingSet = useMemo(() => new Set(ganttNonWorkingDates), [ganttNonWorkingDates])
|
||||||
const dayColumns = useMemo(
|
const dayColumns = useMemo(
|
||||||
() => ganttDayColumns(startMs, endMs, widthPx),
|
() => ganttDayColumns(startMs, endMs, widthPx, nonWorkingSet),
|
||||||
[startMs, endMs, widthPx],
|
[startMs, endMs, widthPx, nonWorkingSet],
|
||||||
)
|
)
|
||||||
const monthBands = useMemo(
|
const monthBands = useMemo(
|
||||||
() => ganttMonthBands(startMs, endMs, widthPx),
|
() => ganttMonthBands(startMs, endMs, widthPx),
|
||||||
@ -271,8 +275,9 @@ export function SprintGanttView({
|
|||||||
<p className="mt-1 max-w-3xl text-xs leading-relaxed text-slate-500">
|
<p className="mt-1 max-w-3xl text-xs leading-relaxed text-slate-500">
|
||||||
Échelle <span className="text-slate-400">jour / semaine / mois</span> et zoom (loupe) : la
|
Échelle <span className="text-slate-400">jour / semaine / mois</span> et zoom (loupe) : la
|
||||||
timeline s’étire en pixels par jour — faites défiler horizontalement. En-tête : mois puis
|
timeline s’étire en pixels par jour — faites défiler horizontalement. En-tête : mois puis
|
||||||
jours / repères ; week-ends en fond plus sombre. Barre = charge (champ Sprint) ou
|
jours (sans répéter le mois) ; week-ends et jours configurés en fond plus sombre. Remplissage
|
||||||
avancement calendaire. Losanges = jalons (survol pour le détail).
|
des barres = % de sous-tâches terminées (champ Sprint). Losanges = jalons (survol pour le
|
||||||
|
détail).
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<button
|
<button
|
||||||
@ -286,9 +291,10 @@ export function SprintGanttView({
|
|||||||
|
|
||||||
{!sprintFieldId && (
|
{!sprintFieldId && (
|
||||||
<p className="mb-3 rounded-lg border border-sky-500/20 bg-sky-500/10 px-3 py-2 text-xs text-sky-100/90">
|
<p className="mb-3 rounded-lg border border-sky-500/20 bg-sky-500/10 px-3 py-2 text-xs text-sky-100/90">
|
||||||
Sans champ Sprint, la barre reflète surtout l’
|
Sans champ Sprint, le <span className="font-medium text-sky-50">remplissage des barres reste à 0 %</span>{' '}
|
||||||
<span className="font-medium text-sky-50">avancement temporel</span>. Ajoutez{' '}
|
(aucune sous-tâche rattachée au sprint). Ajoutez{' '}
|
||||||
<code className="rounded bg-black/30 px-1 font-mono">customfield_…</code> pour la charge réelle.
|
<code className="rounded bg-black/30 px-1 font-mono">customfield_…</code> pour agréger les sous-tâches
|
||||||
|
par sprint.
|
||||||
</p>
|
</p>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
@ -457,8 +463,10 @@ export function SprintGanttView({
|
|||||||
)
|
)
|
||||||
const barTitle =
|
const barTitle =
|
||||||
sprintFieldId && delivery.total > 0
|
sprintFieldId && delivery.total > 0
|
||||||
? `${s.name}\n${formatSprintRangeFr(s)}\nSous-tâches : ${delivery.done} / ${delivery.total} (${delivery.percent} %)\n${subtitleLines.join('\n')}`
|
? `${s.name}\n${formatSprintRangeFr(s)}\nBarre : ${delivery.percent} % des sous-tâches terminées (${delivery.done} / ${delivery.total})\n${subtitleLines.join('\n')}`
|
||||||
: `${s.name}\n${formatSprintRangeFr(s)}\nAvancée calendaire : ${fill} %\n${subtitleLines.join('\n')}`
|
: sprintFieldId
|
||||||
|
? `${s.name}\n${formatSprintRangeFr(s)}\nBarre : 0 % — aucune sous-tâche (non annulée) dans ce sprint avec le champ Sprint.\n${subtitleLines.join('\n')}`
|
||||||
|
: `${s.name}\n${formatSprintRangeFr(s)}\nBarre : 0 % — configurez le champ Sprint dans les réglages.\n${subtitleLines.join('\n')}`
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div key={s.id} className="contents">
|
<div key={s.id} className="contents">
|
||||||
|
|||||||
@ -149,6 +149,28 @@ export function sanitizeExcludedSprintIds(raw: unknown): number[] {
|
|||||||
return [...new Set(out)]
|
return [...new Set(out)]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const ISO_DATE_RE = /^\d{4}-\d{2}-\d{2}$/
|
||||||
|
|
||||||
|
/** Jours fériés / ponts (clé locale yyyy-mm-dd) — même fond atténué que les week-ends sur le Gantt. */
|
||||||
|
export function sanitizeGanttNonWorkingDates(raw: unknown): string[] {
|
||||||
|
if (!Array.isArray(raw)) return []
|
||||||
|
const out: string[] = []
|
||||||
|
for (const x of raw) {
|
||||||
|
const s = typeof x === 'string' ? x.trim().slice(0, 10) : ''
|
||||||
|
if (ISO_DATE_RE.test(s)) out.push(s)
|
||||||
|
}
|
||||||
|
return [...new Set(out)].sort()
|
||||||
|
}
|
||||||
|
|
||||||
|
/** Parse une zone de texte (lignes ou séparateurs virgule / point-virgule). */
|
||||||
|
export function parseGanttNonWorkingDatesFromText(raw: string): string[] {
|
||||||
|
const parts = raw
|
||||||
|
.split(/[\n,;\t]+/)
|
||||||
|
.map((s) => s.trim())
|
||||||
|
.filter(Boolean)
|
||||||
|
return sanitizeGanttNonWorkingDates(parts)
|
||||||
|
}
|
||||||
|
|
||||||
export type DashboardConfig = {
|
export type DashboardConfig = {
|
||||||
version: 1
|
version: 1
|
||||||
milestones: Milestone[]
|
milestones: Milestone[]
|
||||||
@ -174,6 +196,8 @@ export type DashboardConfig = {
|
|||||||
excludedSprintIds: number[]
|
excludedSprintIds: number[]
|
||||||
/** Lignes d’info sous les barres de sprint (Gantt). */
|
/** Lignes d’info sous les barres de sprint (Gantt). */
|
||||||
ganttSprintRowMetric: GanttSprintRowMetric
|
ganttSprintRowMetric: GanttSprintRowMetric
|
||||||
|
/** Dates non travaillées (yyyy-mm-dd, fuseau local) — fond Gantt comme week-end. */
|
||||||
|
ganttNonWorkingDates: string[]
|
||||||
}
|
}
|
||||||
|
|
||||||
const STORAGE_KEY = 'dcc-dashboard-config-v1'
|
const STORAGE_KEY = 'dcc-dashboard-config-v1'
|
||||||
@ -189,6 +213,7 @@ export const defaultDashboardConfig = (): DashboardConfig => ({
|
|||||||
functionalGaps: defaultFunctionalGaps(),
|
functionalGaps: defaultFunctionalGaps(),
|
||||||
excludedSprintIds: [],
|
excludedSprintIds: [],
|
||||||
ganttSprintRowMetric: defaultGanttSprintRowMetric(),
|
ganttSprintRowMetric: defaultGanttSprintRowMetric(),
|
||||||
|
ganttNonWorkingDates: [],
|
||||||
})
|
})
|
||||||
|
|
||||||
/** Import : configuration seule, ou bundle Synology `{ bundleVersion, dashboard }`. */
|
/** Import : configuration seule, ou bundle Synology `{ bundleVersion, dashboard }`. */
|
||||||
@ -246,6 +271,7 @@ export function loadDashboardConfig(): DashboardConfig {
|
|||||||
functionalGaps: sanitizeFunctionalGapsArray(parsed.functionalGaps, defaultFunctionalGaps()),
|
functionalGaps: sanitizeFunctionalGapsArray(parsed.functionalGaps, defaultFunctionalGaps()),
|
||||||
excludedSprintIds: sanitizeExcludedSprintIds(parsed.excludedSprintIds),
|
excludedSprintIds: sanitizeExcludedSprintIds(parsed.excludedSprintIds),
|
||||||
ganttSprintRowMetric: sanitizeGanttSprintRowMetric(parsed.ganttSprintRowMetric),
|
ganttSprintRowMetric: sanitizeGanttSprintRowMetric(parsed.ganttSprintRowMetric),
|
||||||
|
ganttNonWorkingDates: sanitizeGanttNonWorkingDates(parsed.ganttNonWorkingDates),
|
||||||
}
|
}
|
||||||
} catch {
|
} catch {
|
||||||
return defaultDashboardConfig()
|
return defaultDashboardConfig()
|
||||||
@ -329,5 +355,9 @@ export function mergeImportedConfig(
|
|||||||
o.ganttSprintRowMetric !== undefined
|
o.ganttSprintRowMetric !== undefined
|
||||||
? sanitizeGanttSprintRowMetric(o.ganttSprintRowMetric)
|
? sanitizeGanttSprintRowMetric(o.ganttSprintRowMetric)
|
||||||
: current.ganttSprintRowMetric,
|
: current.ganttSprintRowMetric,
|
||||||
|
ganttNonWorkingDates:
|
||||||
|
o.ganttNonWorkingDates !== undefined
|
||||||
|
? sanitizeGanttNonWorkingDates(o.ganttNonWorkingDates)
|
||||||
|
: current.ganttNonWorkingDates,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -200,19 +200,33 @@ export function monthTicksBetween(startMs: number, endMs: number): { ms: number;
|
|||||||
return ticks
|
return ticks
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Colonne calendaire (jour) projetée sur la timeline — week-ends, grille jour. */
|
/** Colonne calendaire (jour) projetée sur la timeline — week-ends, jours configurés, grille. */
|
||||||
export type GanttDayColumn = {
|
export type GanttDayColumn = {
|
||||||
dayStartMs: number
|
dayStartMs: number
|
||||||
weekday: number
|
weekday: number
|
||||||
x0: number
|
x0: number
|
||||||
x1: number
|
x1: number
|
||||||
isWeekend: boolean
|
/** Fond atténué : samedi / dimanche ou date listée dans les réglages Gantt. */
|
||||||
|
isGanttNonWork: boolean
|
||||||
|
}
|
||||||
|
|
||||||
|
function localIsoDateKey(dayStartMs: number): string {
|
||||||
|
const d = new Date(dayStartMs)
|
||||||
|
const y = d.getFullYear()
|
||||||
|
const m = String(d.getMonth() + 1).padStart(2, '0')
|
||||||
|
const day = String(d.getDate()).padStart(2, '0')
|
||||||
|
return `${y}-${m}-${day}`
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Une entrée par jour local qui intersecte [startMs, endMs] (bornes en pixels pour le fond).
|
* Une entrée par jour local qui intersecte [startMs, endMs] (bornes en pixels pour le fond).
|
||||||
*/
|
*/
|
||||||
export function ganttDayColumns(startMs: number, endMs: number, widthPx: number): GanttDayColumn[] {
|
export function ganttDayColumns(
|
||||||
|
startMs: number,
|
||||||
|
endMs: number,
|
||||||
|
widthPx: number,
|
||||||
|
nonWorkingKeys?: ReadonlySet<string>,
|
||||||
|
): GanttDayColumn[] {
|
||||||
const cols: GanttDayColumn[] = []
|
const cols: GanttDayColumn[] = []
|
||||||
const iter = new Date(startMs)
|
const iter = new Date(startMs)
|
||||||
iter.setHours(0, 0, 0, 0)
|
iter.setHours(0, 0, 0, 0)
|
||||||
@ -229,12 +243,15 @@ export function ganttDayColumns(startMs: number, endMs: number, widthPx: number)
|
|||||||
const x0 = msToX(Math.max(dayStart, startMs), startMs, endMs, widthPx)
|
const x0 = msToX(Math.max(dayStart, startMs), startMs, endMs, widthPx)
|
||||||
const x1 = msToX(Math.min(dayEnd, endMs), startMs, endMs, widthPx)
|
const x1 = msToX(Math.min(dayEnd, endMs), startMs, endMs, widthPx)
|
||||||
if (x1 > x0 + 0.02) {
|
if (x1 > x0 + 0.02) {
|
||||||
|
const key = localIsoDateKey(dayStart)
|
||||||
|
const isWeekend = wd === 0 || wd === 6
|
||||||
|
const isConfigured = nonWorkingKeys?.has(key) ?? false
|
||||||
cols.push({
|
cols.push({
|
||||||
dayStartMs: dayStart,
|
dayStartMs: dayStart,
|
||||||
weekday: wd,
|
weekday: wd,
|
||||||
x0,
|
x0,
|
||||||
x1,
|
x1,
|
||||||
isWeekend: wd === 0 || wd === 6,
|
isGanttNonWork: isWeekend || isConfigured,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -308,10 +325,10 @@ export function ganttSubheaderTicks(
|
|||||||
for (let i = 0; i < cols.length; i += step) {
|
for (let i = 0; i < cols.length; i += step) {
|
||||||
const c = cols[i]!
|
const c = cols[i]!
|
||||||
const d = new Date(c.dayStartMs)
|
const d = new Date(c.dayStartMs)
|
||||||
|
const wdShort = d.toLocaleDateString('fr-FR', { weekday: 'short' }).replace(/\.$/, '')
|
||||||
|
const dom = d.getDate()
|
||||||
const label =
|
const label =
|
||||||
step === 1 && avgW >= 26
|
step === 1 && avgW >= 26 ? `${wdShort} ${dom}` : `${dom}`
|
||||||
? d.toLocaleDateString('fr-FR', { weekday: 'short', day: 'numeric', month: 'short' })
|
|
||||||
: d.toLocaleDateString('fr-FR', { day: '2-digit', month: 'short' })
|
|
||||||
const x = (c.x0 + c.x1) / 2
|
const x = (c.x0 + c.x1) / 2
|
||||||
const major = d.getDate() === 1 || d.getDay() === 1
|
const major = d.getDate() === 1 || d.getDay() === 1
|
||||||
out.push({ ms: c.dayStartMs, label, x, major })
|
out.push({ ms: c.dayStartMs, label, x, major })
|
||||||
@ -326,7 +343,8 @@ export function ganttSubheaderTicks(
|
|||||||
while (t <= endMs + MS_DAY && guard++ < 140) {
|
while (t <= endMs + MS_DAY && guard++ < 140) {
|
||||||
if (t + 6 * MS_DAY >= startMs) {
|
if (t + 6 * MS_DAY >= startMs) {
|
||||||
const d = new Date(t)
|
const d = new Date(t)
|
||||||
const label = d.toLocaleDateString('fr-FR', { day: 'numeric', month: 'short' })
|
const wdShort = d.toLocaleDateString('fr-FR', { weekday: 'short' }).replace(/\.$/, '')
|
||||||
|
const label = `${wdShort} ${d.getDate()}`
|
||||||
const x = msToX(t + 3.5 * MS_DAY, startMs, endMs, widthPx)
|
const x = msToX(t + 3.5 * MS_DAY, startMs, endMs, widthPx)
|
||||||
out.push({ ms: t, label, x, major: true })
|
out.push({ ms: t, label, x, major: true })
|
||||||
}
|
}
|
||||||
@ -427,8 +445,8 @@ export function sprintTimeElapsedPercent(s: JiraSprintSnapshot, nowMs = Date.now
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Remplissage de la barre : priorité au % sous-tâches terminées (périmètre + champ Sprint),
|
* Remplissage de la barre : uniquement le % de sous-tâches terminées (périmètre + champ Sprint).
|
||||||
* sinon avancement calendaire du sprint.
|
* Pas d’avancement calendaire : sans données, la barre reste à 0 %.
|
||||||
*/
|
*/
|
||||||
export function sprintBarFillPercent(
|
export function sprintBarFillPercent(
|
||||||
s: JiraSprintSnapshot,
|
s: JiraSprintSnapshot,
|
||||||
@ -437,8 +455,8 @@ export function sprintBarFillPercent(
|
|||||||
cfg: StatusBucketConfig,
|
cfg: StatusBucketConfig,
|
||||||
): number {
|
): number {
|
||||||
const delivery = epicScopeSprintProgress(groups, s.id, fieldId, cfg)
|
const delivery = epicScopeSprintProgress(groups, s.id, fieldId, cfg)
|
||||||
if (fieldId && delivery.total > 0) return Math.min(100, delivery.percent)
|
if (!fieldId || delivery.total === 0) return 0
|
||||||
return sprintTimeElapsedPercent(s)
|
return Math.min(100, delivery.percent)
|
||||||
}
|
}
|
||||||
|
|
||||||
export function milestoneTooltipText(m: Milestone): string {
|
export function milestoneTooltipText(m: Milestone): string {
|
||||||
|
|||||||
Reference in New Issue
Block a user