Skip to content

Commit 41c3477

Browse files
authored
Fix(Dashboard): fix 'pending' and 'To be validated' counter (#3584)
1 parent 5c41af7 commit 41c3477

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

hook.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -309,6 +309,10 @@ function plugin_formcreator_addWhere($link, $nott, $itemtype, $ID, $val, $search
309309
$tocheck = $item->getPendingStatusArray();
310310
break;
311311

312+
case PluginFormcreatorFormAnswer::STATUS_WAITING:
313+
$tocheck = $item->getPendingValidationStatusArray();
314+
break;
315+
312316
case Ticket::CLOSED:
313317
$tocheck = $item->getClosedStatusArray();
314318
break;

inc/formanswer.class.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -75,9 +75,9 @@ class PluginFormcreatorFormAnswer extends CommonDBTM
7575

7676
public static function getStatuses() {
7777
return [
78-
self::STATUS_WAITING => __('Waiting', 'formcreator'),
79-
self::STATUS_REFUSED => __('Refused', 'formcreator'),
80-
self::STATUS_ACCEPTED => __('Accepted', 'formcreator'),
78+
self::STATUS_WAITING => __('To validate', 'formcreator'),
79+
self::STATUS_REFUSED => __('Validation Refused', 'formcreator'),
80+
self::STATUS_ACCEPTED => __('Validation Accepted', 'formcreator'),
8181
];
8282
}
8383

inc/issue.class.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1135,7 +1135,11 @@ static function getNewStatusArray() {
11351135
}
11361136

11371137
static function getPendingStatusArray() {
1138-
return [Ticket::WAITING, PluginFormcreatorFormAnswer::STATUS_WAITING];
1138+
return [Ticket::WAITING];
1139+
}
1140+
1141+
static function getPendingValidationStatusArray() {
1142+
return [PluginFormcreatorFormAnswer::STATUS_WAITING];
11391143
}
11401144

11411145
static function getProcessStatusArray() {

0 commit comments

Comments
 (0)