Analysis of the problem in the use of json_encode in php and inarray in jQuery!
If the array is an sequential array and starts from 0, such as:
public static $service_gid = array(11430, 11431, 11432);
Then

Check whether there are special products in the product list, if there is, a dialog box will pop up: Whether you need to arrange after-sales personnel, please select Yes
Now
At this time, through InArray, it will detect whether 11430 is in the array, and it will return 0;
If
public static $service_gid = array(2=>11430, 3=>11431, 4=>11432);
Then
At this time, through InArray, it will detect whether 11430 is in the array, and it will return -1;
Therefore, it can be explained that there is still a difference between inArray and Array_search in PHP. The array index must start from 0 to retrieve whether it contains this value, otherwise it is not possible!