Javascript multiple or condition check

前端 未结 4 1685
暗喜
暗喜 2021-01-29 06:44

I have struck with some simple if else checking

var IsCompanyContacttitleUpdate = false;
var ContactStatus = -1;

if ((IsCompanyContacttitleUpdate == false) &am         


        
4条回答
  •  有刺的猬
    2021-01-29 07:12

    the problem is (ContactStatus == 2 || 3 || 4)

    the correct way should (ContactStatus == 2 || ContactStatus == 3 || ContactStatus == 4)

提交回复
热议问题