BryanDavis has uploaded a new change for review.
https://gerrit.wikimedia.org/r/218998
Change subject: Fix proposal creation
......................................................................
Fix proposal creation
Change from requireInArray to expectInArray for the status field so that
the default value will be applied to new proposals.
Change-Id: I91502b562973a8587512aec6302873b509c4ee1e
---
M src/Controllers/Proposals/Edit.php
1 file changed, 2 insertions(+), 2 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/wikimedia/iegreview
refs/changes/98/218998/1
diff --git a/src/Controllers/Proposals/Edit.php
b/src/Controllers/Proposals/Edit.php
index 3d0dfc5..e872c9e 100644
--- a/src/Controllers/Proposals/Edit.php
+++ b/src/Controllers/Proposals/Edit.php
@@ -69,13 +69,12 @@
'default' => $defaults['notes'],
) );
- $this->form->requireInArray( 'status',
+ $this->form->expectInArray( 'status',
array( 'open', 'abandoned', 'accepted', 'rejected' ),
array(
'default' => $defaults['status'],
) );
- $this->log->debug( print_r( $this->form, true ) );
$this->view->setData( 'form', $this->form );
}
@@ -133,6 +132,7 @@
} else {
// TODO: save input to be shown in get screen
+ $this->flash( 'error', $this->msg(
'proposals-edit-error' ) );
}
$this->redirect( $redir );
}
--
To view, visit https://gerrit.wikimedia.org/r/218998
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I91502b562973a8587512aec6302873b509c4ee1e
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/iegreview
Gerrit-Branch: master
Gerrit-Owner: BryanDavis <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits