if
(Object.prototype.toString.call(options.fiexdRowHeight).slice(8, -1) ===
'Boolean'
&& options.fiexdRowHeight) {
var
p_ = $(
"[lay-id='"
+ options.id +
"']"
)
var
tr_len = p_.find(ELEM_MAIN).find(
"tr"
).length
if
(tr_len > 10){
if
(Object.prototype.toString.call(options.fiexdRowHeight_rows).slice(8, -1) !==
'Number'
) {
options.fiexdRowHeight_rows = 10
}
var
height_main = (options.fiexdRowHeight_rows * 39) +
'px'
var
height_fixed = (options.fiexdRowHeight_rows * 39) +
'px'
if
(p_[0].parentNode.clientWidth < document.getElementsByClassName(
'layui-table-main'
)[0].getElementsByClassName(
'layui-table'
)[0].clientWidth) {
height_main = ((options.fiexdRowHeight_rows * 39) + 18) +
'px'
}
p_.find(ELEM_MAIN).css(
"height"
, height_main);
p_.find(ELEM_FIXL).find(ELEM_BODY).css(
"height"
, height_fixed);
p_.find(ELEM_FIXR).find(ELEM_BODY).css(
"height"
, height_fixed);
}
else
{
p_.find(ELEM_MAIN).css(
"height"
,
"auto"
);
p_.find(ELEM_FIXL).find(ELEM_BODY).css(
"height"
,
"auto"
);
p_.find(ELEM_FIXR).find(ELEM_BODY).css(
"height"
,
"auto"
);
}
}