X-Git-Url: https://gerrit.fd.io/r/gitweb?p=csit.git;a=blobdiff_plain;f=resources%2Ftools%2Fdash%2Fapp%2Fpal%2Fnews%2Ftables.py;h=62728141655bc082c602e8f9ba9200aabee1a6a5;hp=53b24608d51a0af1985af4195611c0d1ea88769b;hb=ae1fe880286d7b0414664bce2b2c7c91c3f543f3;hpb=739e01de7a65045dc42e6c16406a6d054da72f7b diff --git a/resources/tools/dash/app/pal/news/tables.py b/resources/tools/dash/app/pal/news/tables.py index 53b24608d5..6272814165 100644 --- a/resources/tools/dash/app/pal/news/tables.py +++ b/resources/tools/dash/app/pal/news/tables.py @@ -17,9 +17,7 @@ import pandas as pd import dash_bootstrap_components as dbc - -# Time period for regressions and progressions. -TIME_PERIOD = 21 # [days] +from ..utils.constants import Constants as C def table_news(data: pd.DataFrame, job: str) -> list: @@ -57,7 +55,7 @@ def table_news(data: pd.DataFrame, job: str) -> list: class_name="p-0", size="lg", children=( - f"Regressions during the last {TIME_PERIOD} days " + f"Regressions during the last {C.NEWS_TIME_PERIOD} days " f"({len(regressions['Test Name'])})" ) ), @@ -68,7 +66,7 @@ def table_news(data: pd.DataFrame, job: str) -> list: class_name="p-0", size="lg", children=( - f"Progressions during the last {TIME_PERIOD} days " + f"Progressions during the last {C.NEWS_TIME_PERIOD} days " f"({len(progressions['Test Name'])})" ) ),