From 7405d5a8e718ad302bbfc0a5e5a56832ca45fceb Mon Sep 17 00:00:00 2001 From: Tanveer Chowdhury Date: Fri, 11 Oct 2024 20:11:38 +0600 Subject: [PATCH 1/2] added and refactored milestone card; fixed htmx --- app/Domain/Dashboard/Templates/show.blade.php | 15 +++------------ .../Templates/components/milestone-card.blade.php | 11 +++++++++++ .../Templates/partials/milestoneCard.blade.php | 2 +- 3 files changed, 15 insertions(+), 13 deletions(-) create mode 100644 app/Domain/Tickets/Templates/components/milestone-card.blade.php diff --git a/app/Domain/Dashboard/Templates/show.blade.php b/app/Domain/Dashboard/Templates/show.blade.php index 79145c26c..ea42350ba 100644 --- a/app/Domain/Dashboard/Templates/show.blade.php +++ b/app/Domain/Dashboard/Templates/show.blade.php @@ -424,18 +424,9 @@ class="fa fa-reply"> {{ __('links.reply') }} @if ($row->percentDone >= 100 && new \DateTime($row->editTo) < new \DateTime()) @break @endif - - - -
-
- __("label.loading_milestone") ?> -
-
- -
+ @endforeach diff --git a/app/Domain/Tickets/Templates/components/milestone-card.blade.php b/app/Domain/Tickets/Templates/components/milestone-card.blade.php new file mode 100644 index 000000000..43e55336e --- /dev/null +++ b/app/Domain/Tickets/Templates/components/milestone-card.blade.php @@ -0,0 +1,11 @@ +@props([ + 'milestone' => '' +]) + +
+ + + + +
\ No newline at end of file diff --git a/app/Domain/Tickets/Templates/partials/milestoneCard.blade.php b/app/Domain/Tickets/Templates/partials/milestoneCard.blade.php index 9e15df587..91240aff6 100644 --- a/app/Domain/Tickets/Templates/partials/milestoneCard.blade.php +++ b/app/Domain/Tickets/Templates/partials/milestoneCard.blade.php @@ -1,4 +1,4 @@ -
+
{{ $milestone->headline }} From db07dfa7cf4cfe5b4c7e31f663d71c91f9b41ee0 Mon Sep 17 00:00:00 2001 From: Tanveer Chowdhury Date: Fri, 11 Oct 2024 20:28:20 +0600 Subject: [PATCH 2/2] replaced milestone card in reports module --- app/Domain/Reports/Templates/show.blade.php | 63 +++++++-------------- 1 file changed, 20 insertions(+), 43 deletions(-) diff --git a/app/Domain/Reports/Templates/show.blade.php b/app/Domain/Reports/Templates/show.blade.php index 19d44f8ef..375e712f9 100644 --- a/app/Domain/Reports/Templates/show.blade.php +++ b/app/Domain/Reports/Templates/show.blade.php @@ -164,49 +164,26 @@ class="mainSprintSelector"
__("headline.milestones") ?>
-
    - get('milestones')) == 0) { - echo"

    " . $tpl->__("headlines.no_milestones") . "

    - " . $tpl->__("text.milestones_help_organize_projects") . "

    " . $tpl->__("links.goto_milestones") . ""; - } - ?> - get('milestones') as $row) { - - ?> -
  • -
    - - -
    - -
    - __("label.due") ?> - editTo)->date( $tpl->__("text.no_date_defined")); ?> -
    -
    - __("text.percent_complete"), $row->percentDone)?> -
    -
    -
    -
    -
    -
    - __("text.percent_complete"), $row->percentDone)?> -
    -
    -
    -
    -
    -
  • - - -
+ + @if (count($milestones) == 0) +
+
+

{{ __('headlines.no_milestones') }}

+ {{ __('text.milestones_help_organize_projects') }} +

+ {!! __('links.goto_milestones') !!} +
+ @endif + + @foreach ($milestones as $row) + @if ($row->percentDone >= 100 && new \DateTime($row->editTo) < new \DateTime()) + @break + @endif + + @endforeach +