mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-26 16:52:41 +01:00
Make the new synthetic burnup chart data respect the "Project" filter
Summary: See PHI273. Third time's the charm? This page has a "Project" filter which lets you view data for only one project, but the synthetic data currently ignores it. Test Plan: Filtered burnup chart by various projects, saw sensible-looking data. Reviewers: amckinley Reviewed By: amckinley Differential Revision: https://secure.phabricator.com/D18860
This commit is contained in:
parent
5543592034
commit
adbd7d4fd8
1 changed files with 10 additions and 2 deletions
|
@ -75,6 +75,7 @@ final class ManiphestReportController extends ManiphestController {
|
||||||
$conn = $table->establishConnection('r');
|
$conn = $table->establishConnection('r');
|
||||||
|
|
||||||
$joins = '';
|
$joins = '';
|
||||||
|
$create_joins = '';
|
||||||
if ($project_phid) {
|
if ($project_phid) {
|
||||||
$joins = qsprintf(
|
$joins = qsprintf(
|
||||||
$conn,
|
$conn,
|
||||||
|
@ -84,6 +85,12 @@ final class ManiphestReportController extends ManiphestController {
|
||||||
PhabricatorEdgeConfig::TABLE_NAME_EDGE,
|
PhabricatorEdgeConfig::TABLE_NAME_EDGE,
|
||||||
PhabricatorProjectObjectHasProjectEdgeType::EDGECONST,
|
PhabricatorProjectObjectHasProjectEdgeType::EDGECONST,
|
||||||
$project_phid);
|
$project_phid);
|
||||||
|
$create_joins = qsprintf(
|
||||||
|
$conn,
|
||||||
|
'JOIN %T p ON p.src = t.phid AND p.type = %d AND p.dst = %s',
|
||||||
|
PhabricatorEdgeConfig::TABLE_NAME_EDGE,
|
||||||
|
PhabricatorProjectObjectHasProjectEdgeType::EDGECONST,
|
||||||
|
$project_phid);
|
||||||
}
|
}
|
||||||
|
|
||||||
$data = queryfx_all(
|
$data = queryfx_all(
|
||||||
|
@ -113,8 +120,9 @@ final class ManiphestReportController extends ManiphestController {
|
||||||
// default value.
|
// default value.
|
||||||
$create_rows = queryfx_all(
|
$create_rows = queryfx_all(
|
||||||
$conn,
|
$conn,
|
||||||
'SELECT dateCreated FROM %T',
|
'SELECT t.dateCreated FROM %T t %Q',
|
||||||
id(new ManiphestTask())->getTableName());
|
id(new ManiphestTask())->getTableName(),
|
||||||
|
$create_joins);
|
||||||
foreach ($create_rows as $key => $create_row) {
|
foreach ($create_rows as $key => $create_row) {
|
||||||
$create_rows[$key] = array(
|
$create_rows[$key] = array(
|
||||||
'transactionType' => 'status',
|
'transactionType' => 'status',
|
||||||
|
|
Loading…
Reference in a new issue