1.
General application Scenarios:
Used to quickly toggle the display of the list content, such as the switch to the employee.
It is necessary to search by Department for this kind of situation, and now my practice is to load all the employee lists that the user can view for the first time, select the department and then hide the other employees who are not in the department.
However, after selecting the left and right toggle buttons cannot be clicked or the upper and lower page switching sequence is incorrect.
Reason: The plug-in will be based on the width of each item and the width of the entire container to calculate the display of a few, when we hide a few of them, it seems to be right, but in fact, the page is not reflected in the plug-in calculation results, resulting in the subsequent switching problems, because the hidden item is actually involved in the calculation, The hidden item is not processed in the source code.
Solution:
Incidentally: It's important to view the document
A description of the settings for the items parameter in the document
Set the items parameter to the item you really want to show
My wording:
function () { var allwidth = $ (". Jcarousel"). Width (); var itemwidth = Ul.find ("Li:first"). Outerwidth (); = parseint (Allwidth/ itemwidth); }). Jcarousel ({ items: $ ("#empul li:visible") });
2, or the above scene, if you can search by name, etc.
When you switch to a page greater than 1, that is, you switch to the second page, the third page and so on, this is the input name to search, there may be empty results, or incomplete results (assuming that the logic code is not a problem), depressed it!
Actually this is you can click on the Pre toggle button to try and be hidden
Solution:
$ ('. Jcarousel '). Jcarousel (' scroll ', 0);
The structure of my page in the case:
<Divclass= "Jcarousel col-md-10 col-sm-10 col-xs-10"> <ulID= "Empul"> <Li> </Li> </ul> </Div>
Carousel Plugin hides a few items in the list cause left and right toggle error