aboutsummaryrefslogtreecommitdiff
path: root/src/ReplyForm.js
diff options
context:
space:
mode:
authorLibravatar Renard 2019-09-16 16:53:39 -0300
committerLibravatar Renard 2019-09-16 16:53:39 -0300
commit75824bd139423d527820c81b60e0c43a6348e56f (patch)
tree9751de27a18678d70d6a740c1d8ec7089c36e452 /src/ReplyForm.js
parent29d9f5ecad2261ed4e4f7712750cf2a126392d8e (diff)
downloadbai-client-75824bd139423d527820c81b60e0c43a6348e56f.tar.gz
bai-client-75824bd139423d527820c81b60e0c43a6348e56f.tar.xz
bai-client-75824bd139423d527820c81b60e0c43a6348e56f.zip
No mostrar formulario de respuesta si el hilo está cerrado
Diffstat (limited to 'src/ReplyForm.js')
-rw-r--r--src/ReplyForm.js10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/ReplyForm.js b/src/ReplyForm.js
index 70e5d49..1dab761 100644
--- a/src/ReplyForm.js
+++ b/src/ReplyForm.js
@@ -34,7 +34,7 @@ class ReplyForm extends Component {
() => {
const { submittedName, submittedEmail, submittedMessage } = this.state;
const data = {
- board: this.props.dir,
+ board: this.props.currentBoard.dir,
parent: this.props.parent,
name: "",
email: "",
@@ -67,6 +67,14 @@ class ReplyForm extends Component {
render() {
const { name, email, message, replyRes } = this.state;
+ if (this.props.locked === 1) {
+ return (
+ <Message negative>
+ <Message.Header>Hilo cerrado</Message.Header>
+ Este hilo ha sido cerrado y no admite nuevas respuestas.
+ </Message>
+ );
+ }
return (
<Segment>
{replyRes !== null ? (