0037319: Duplicated code in MantisGraph plugin's graph_api.php - MantisBT

View Issue Details

IDProjectCategoryView StatusDate SubmittedLast Update
0037319mantisbtcode cleanuppublic2026年07月20日 13:542026年09月03日 19:04
Reporterdregad Assigned Todregad  
PrioritynormalSeveritytweakReproducibilityN/A
Status resolvedResolutionfixed 
Target Version2.29.0Fixed in Version2.29.0 
Summary0037319: Duplicated code in MantisGraph plugin's graph_api.php
Description

create_developer_resolved_summary() and create_developer_open_summary() functions are nearly identical, differing only by a condition in the SQL query where clause.

Duplicated code should be factored out.

TagsNo tags attached.

Activities

There are no notes attached to this issue.

Related Changesets

MantisBT: master 0e9e169c

2026年07月20日 13:50

dregad


Details Diff Remove duplicated code in graph_api.php

create_developer_resolved_summary() and create_developer_open_summary()
MantisGraph plugin functions are nearly identical, differing only by
a condition in the SQL query where clause.

This commit combines them into a single one, leveraging DbQuery to
dynamically build the SQL based on the summary type (open/resolved).

Fixes 0037319 Affected Issues
0037319
mod - plugins/MantisGraph/core/graph_api.php Diff File
mod - plugins/MantisGraph/pages/developer_graph.php Diff File
Powered by MantisBT 2.29.0-dev-master-e4ff7ef87
Copyright © 2000 - 2026 MantisBT Team
Contact administrator for assistance
Page execution time: 0.1680 seconds    

AltStyle によって変換されたページ (->オリジナル) /