-1
 {this.state.accordian === "Updated Port Entry" || "Updated Shipper Updates" ||  "Updated MT Container Details" ? 

    <li className="remove">
            <a role="button" className="boxs-close" onClick={this.Depottoggle.bind(this)}><i className="zmdi zmdi-plus collapseColor"></i></a>
    </li> : null}

In the state this.state.accordian having "Updated Truck Details". As I am checking based on a) Updated Port Entry b) Updated Shipper Updates c) Updated MT Container Details

as It is not matched It should not be shown but I am able to see the Icon.

Please guide me.

user9883888
  • 389
  • 1
  • 8
  • 17
  • 1
    you have to check each one against `accordian` – Daniel A. White Jul 19 '18 at 19:51
  • 2
    That should be `this.state.accordian === "Updated Port Entry" || this.state.accordian === "Updated Shipper Updates" || this.state.accordian === "Updated MT Container Details" ` – Igor Jul 19 '18 at 19:51

1 Answers1

0

You need to use this.state.accordian each time you compare it.

this.state.accordian === "Updated Port Entry" || this.state.accordian === "Updated Shipper Updates" || this.state.accordian === "Updated MT Container Details"

Jimenemex
  • 3,104
  • 3
  • 24
  • 56