Ajax request returned data do not see the callback function is not executed, where there is no error, there are similar cases of friends can refer to the following article
The project is SSH, using jquery's $.post to access Struts2 's action, where there is no error, but no results.
Now $.post to return the collection collection with the permission, the permission class privilege is associated with the user class user, which means that privilege uses the set collection to hold the user set with this permission , and user users also use the The set collection holds the permissions set for the user . The data went to the action, but the callback function was not executed, and the data returned was not seen using browser debugging, and it was finally found for a long time, for the following reasons:
When jquery parses the returned collection collection, it sees that there is a set in it, it goes to the data in the collection, but the collection is returned by a method in the service, and this time the SPR ING's transaction is over, and the data in the set is not found. jquery resolves an empty collection and then fails, so no data is available.
Workaround: The GetUser () method in privilege adds this annotation @json (serialize=false) so that jquery ignores the data in the collection when parsing it. Of course, if the data is to be used, it is necessary to check the data in the service and put it in the collection.