Home > Article > Web Front-end > Solution to the problem that the shrink layer in easyui-layout cannot display the title
This article will introduce to you the analysis and solutions to the reasons why the shrinking layer in easyui-layout cannot display the title. Interested friends can refer to the following
The problem that the shrinking layer in easyui-layout cannot display the title Cause analysis:
Set the panel initialization in easyui-layout to be foldable, and then find that the title and icon are gone
Well, the results list is completely blank. If there is a problem, you need to solve it. After checking the information on the Internet, I decided to modify the jquery.easyui.min.js
version to : jQuery EasyUI 1.4.1
There is a _39d method in line 5105, in which two variables _Cstitle and _CsIcon are set. Add the code as follows:
var _Cstitle; var _closedTitle = p.panel("options").title; if(_closedTitle){ _Cstitle = _closedTitle; } else{ _Cstitle = ''; }
In this way we get a title variable, and the icon can be obtained in the same way.
Next, just set the panel’s title attribute and iconCls attribute to the variables defined above in the next method (line number 5162) and it’s OK~(≧▽≦)/~
p.panel($.extend({}, $.fn.layout.paneldefaults, { cls: ("layout-expand layout-expand-" + dir), title: _Cstitle, iconCls: _CsIcon, closed: true, minWidth: 0, minHeight: 0, doSize: false, tools: [{ iconCls: icon, handler: function () { _3ad(_39e, _39f); return false; } }] }));
That’s it~~
The above content is easyui introduced by the editor to you -The solution to the problem that the shrink layer in layout cannot display the title. I hope it will be helpful to everyone!